2020-12-14 17:30:00 +00:00
|
|
|
# Makefile for c++tools
|
2024-01-03 11:19:35 +00:00
|
|
|
# Copyright (C) 2020-2024 Free Software Foundation, Inc.
|
2020-12-14 17:30:00 +00:00
|
|
|
#
|
|
|
|
# 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/>.
|
|
|
|
|
|
|
|
srcdir := @srcdir@
|
|
|
|
prefix := @prefix@
|
|
|
|
bindir := @bindir@
|
|
|
|
libexecdir := @libexecdir@
|
|
|
|
target_noncanonical := @target_noncanonical@
|
2020-12-17 13:31:05 +00:00
|
|
|
gcc_version := $(shell @get_gcc_base_ver@ $(srcdir)/../gcc/BASE-VER)
|
|
|
|
libexecsubdir := $(libexecdir)/gcc/$(target_noncanonical)/$(gcc_version)
|
2023-03-30 12:03:11 +00:00
|
|
|
INSTALL := @INSTALL@
|
2020-12-16 19:44:42 +00:00
|
|
|
INSTALL_PROGRAM := @INSTALL_PROGRAM@
|
|
|
|
INSTALL_STRIP_PROGRAM := $(srcdir)/../install-sh -c -s
|
2020-12-14 17:30:00 +00:00
|
|
|
AUTOCONF := @AUTOCONF@
|
|
|
|
AUTOHEADER := @AUTOHEADER@
|
|
|
|
CXX := @CXX@
|
|
|
|
CXXFLAGS := @CXXFLAGS@
|
configure: Implement --enable-host-pie
[ This is my third attempt to add this configure option. The first
version was approved but it came too late in the development cycle.
The second version was also approved, but I had to revert it:
<https://gcc.gnu.org/pipermail/gcc-patches/2022-November/607082.html>.
I've fixed the problem (by moving $(PICFLAG) from INTERNAL_CFLAGS to
ALL_COMPILERFLAGS). Another change is that since r13-4536 I no longer
need to touch Makefile.def, so this patch is simplified. ]
This patch implements the --enable-host-pie configure option which
makes the compiler executables PIE. This can be used to enhance
protection against ROP attacks, and can be viewed as part of a wider
trend to harden binaries.
It is similar to the option --enable-host-shared, except that --e-h-s
won't add -shared to the linker flags whereas --e-h-p will add -pie.
It is different from --enable-default-pie because that option just
adds an implicit -fPIE/-pie when the compiler is invoked, but the
compiler itself isn't PIE.
Since r12-5768-gfe7c3ecf, PCH works well with PIE, so there are no PCH
regressions.
When building the compiler, the build process may use various in-tree
libraries; these need to be built with -fPIE so that it's possible to
use them when building a PIE. For instance, when --with-included-gettext
is in effect, intl object files must be compiled with -fPIE. Similarly,
when building in-tree gmp, isl, mpfr and mpc, they must be compiled with
-fPIE.
With this patch and --enable-host-pie used to configure gcc:
$ file gcc/cc1{,plus,obj,gm2} gcc/f951 gcc/lto1 gcc/cpp gcc/go1 gcc/rust1 gcc/gnat1
gcc/cc1: ELF 64-bit LSB pie executable, x86-64, version 1 (GNU/Linux), dynamically linked, interpreter /lib64/ld-linux-x86-64.so.2, BuildID[sha1]=98e22cde129d304aa6f33e61b1c39e144aeb135e, for GNU/Linux 3.2.0, with debug_info, not stripped
gcc/cc1plus: ELF 64-bit LSB pie executable, x86-64, version 1 (GNU/Linux), dynamically linked, interpreter /lib64/ld-linux-x86-64.so.2, BuildID[sha1]=859d1ea37e43dfe50c18fd4e3dd9a34bb1db8f77, for GNU/Linux 3.2.0, with debug_info, not stripped
gcc/cc1obj: ELF 64-bit LSB pie executable, x86-64, version 1 (GNU/Linux), dynamically linked, interpreter /lib64/ld-linux-x86-64.so.2, BuildID[sha1]=1964f8ecee6163182bc26134e2ac1f324816e434, for GNU/Linux 3.2.0, with debug_info, not stripped
gcc/cc1gm2: ELF 64-bit LSB pie executable, x86-64, version 1 (GNU/Linux), dynamically linked, interpreter /lib64/ld-linux-x86-64.so.2, BuildID[sha1]=a396672c7ff913d21855829202e7b02ecf42ff4c, for GNU/Linux 3.2.0, with debug_info, not stripped
gcc/f951: ELF 64-bit LSB pie executable, x86-64, version 1 (GNU/Linux), dynamically linked, interpreter /lib64/ld-linux-x86-64.so.2, BuildID[sha1]=59c523db893186547ac75c7a71f48be0a461c06b, for GNU/Linux 3.2.0, with debug_info, not stripped
gcc/lto1: ELF 64-bit LSB pie executable, x86-64, version 1 (GNU/Linux), dynamically linked, interpreter /lib64/ld-linux-x86-64.so.2, BuildID[sha1]=084a7b77df7be2d63c2d4c655b5bbc3fcdb6038d, for GNU/Linux 3.2.0, with debug_info, not stripped
gcc/cpp: ELF 64-bit LSB pie executable, x86-64, version 1 (GNU/Linux), dynamically linked, interpreter /lib64/ld-linux-x86-64.so.2, BuildID[sha1]=3503bf8390d219a10d6653b8560aa21158132168, for GNU/Linux 3.2.0, with debug_info, not stripped
gcc/go1: ELF 64-bit LSB pie executable, x86-64, version 1 (GNU/Linux), dynamically linked, interpreter /lib64/ld-linux-x86-64.so.2, BuildID[sha1]=988cc673af4fba5dcb482f4b34957b99050a68c5, for GNU/Linux 3.2.0, with debug_info, not stripped
gcc/rust1: ELF 64-bit LSB pie executable, x86-64, version 1 (GNU/Linux), dynamically linked, interpreter /lib64/ld-linux-x86-64.so.2, BuildID[sha1]=b6a5d3d514446c4dcdee0707f086ab9b274a8a3c, for GNU/Linux 3.2.0, with debug_info, not stripped
gcc/gnat1: ELF 64-bit LSB pie executable, x86-64, version 1 (GNU/Linux), dynamically linked, interpreter /lib64/ld-linux-x86-64.so.2, BuildID[sha1]=bb11ccdc2c366fe3fe0980476bcd8ca19b67f9dc, for GNU/Linux 3.2.0, with debug_info, not stripped
I plan to add an option to link with -Wl,-z,now.
Bootstrapped on x86_64-pc-linux-gnu with --with-included-gettext
--enable-host-pie as well as without --enable-host-pie. Also tested
on a Debian system where the system gcc was configured with
--enable-default-pie.
Co-Authored by: Iain Sandoe <iain@sandoe.co.uk>
ChangeLog:
* configure.ac (--enable-host-pie): New check. Set PICFLAG after this
check.
* configure: Regenerate.
c++tools/ChangeLog:
* Makefile.in: Rename PIEFLAG to PICFLAG. Set LD_PICFLAG. Use it.
Use pic/libiberty.a if PICFLAG is set.
* configure.ac (--enable-default-pie): Set PICFLAG instead of PIEFLAG.
(--enable-host-pie): New check.
* configure: Regenerate.
fixincludes/ChangeLog:
* Makefile.in: Set and use PICFLAG and LD_PICFLAG. Use the "pic"
build of libiberty if PICFLAG is set.
* configure.ac:
* configure: Regenerate.
gcc/ChangeLog:
* Makefile.in: Set LD_PICFLAG. Use it. Set enable_host_pie.
Remove NO_PIE_CFLAGS and NO_PIE_FLAG. Pass LD_PICFLAG to
ALL_LINKERFLAGS. Use the "pic" build of libiberty if --enable-host-pie.
* configure.ac (--enable-host-shared): Don't set PICFLAG here.
(--enable-host-pie): New check. Set PICFLAG and LD_PICFLAG after this
check.
* configure: Regenerate.
* doc/install.texi: Document --enable-host-pie.
gcc/ada/ChangeLog:
* gcc-interface/Make-lang.in (ALL_ADAFLAGS): Remove NO_PIE_CFLAGS. Add
PICFLAG. Use PICFLAG when building ada/b_gnat1.o and ada/b_gnatb.o.
* gcc-interface/Makefile.in: Use pic/libiberty.a if PICFLAG is set.
Remove NO_PIE_FLAG.
gcc/m2/ChangeLog:
* Make-lang.in: New var, GM2_PICFLAGS. Use it.
gcc/d/ChangeLog:
* Make-lang.in: Remove NO_PIE_CFLAGS.
intl/ChangeLog:
* Makefile.in: Use @PICFLAG@ in COMPILE as well.
* configure.ac (--enable-host-shared): Don't set PICFLAG here.
(--enable-host-pie): New check. Set PICFLAG after this check.
* configure: Regenerate.
libcody/ChangeLog:
* Makefile.in: Pass LD_PICFLAG to LDFLAGS.
* configure.ac (--enable-host-shared): Don't set PICFLAG here.
(--enable-host-pie): New check. Set PICFLAG and LD_PICFLAG after this
check.
* configure: Regenerate.
libcpp/ChangeLog:
* configure.ac (--enable-host-shared): Don't set PICFLAG here.
(--enable-host-pie): New check. Set PICFLAG after this check.
* configure: Regenerate.
libdecnumber/ChangeLog:
* configure.ac (--enable-host-shared): Don't set PICFLAG here.
(--enable-host-pie): New check. Set PICFLAG after this check.
* configure: Regenerate.
libiberty/ChangeLog:
* configure.ac: Also set shared when enable_host_pie.
* configure: Regenerate.
zlib/ChangeLog:
* configure.ac (--enable-host-shared): Don't set PICFLAG here.
(--enable-host-pie): New check. Set PICFLAG after this check.
* configure: Regenerate.
2023-05-03 21:06:13 +00:00
|
|
|
PICFLAG := @PICFLAG@
|
|
|
|
LD_PICFLAG := @LD_PICFLAG@
|
|
|
|
CXXOPTS := $(CXXFLAGS) $(PICFLAG) -fno-exceptions -fno-rtti
|
2020-12-23 12:50:00 +00:00
|
|
|
LDFLAGS := @LDFLAGS@
|
2020-12-21 13:32:28 +00:00
|
|
|
exeext := @EXEEXT@
|
2020-12-14 17:30:00 +00:00
|
|
|
LIBIBERTY := ../libiberty/libiberty.a
|
|
|
|
VERSION.O := ../gcc/version.o
|
|
|
|
|
|
|
|
all::
|
|
|
|
|
|
|
|
mostlyclean::
|
|
|
|
rm -f $(MAPPER.O)
|
|
|
|
|
2023-03-30 12:03:11 +00:00
|
|
|
clean:: mostlyclean
|
2020-12-16 13:14:57 +00:00
|
|
|
rm -f g++-mapper-server$(exeext)
|
2020-12-14 17:30:00 +00:00
|
|
|
|
2023-03-30 12:03:11 +00:00
|
|
|
distclean:: clean
|
|
|
|
rm -f config.log config.status config.h config.cache Makefile
|
|
|
|
rm -f $(MAPPER.O:%.o=%.d)
|
2020-12-14 17:30:00 +00:00
|
|
|
|
2023-03-30 12:03:11 +00:00
|
|
|
maintainer-clean:: distclean
|
2020-12-14 17:30:00 +00:00
|
|
|
|
|
|
|
install::
|
|
|
|
|
2020-12-16 19:44:42 +00:00
|
|
|
check::
|
|
|
|
installcheck::
|
|
|
|
dvi::
|
|
|
|
pdf::
|
|
|
|
html::
|
|
|
|
info::
|
|
|
|
install-info::
|
|
|
|
install-pdf::
|
2021-10-22 22:24:15 +00:00
|
|
|
install-dvi::
|
2020-12-16 19:44:42 +00:00
|
|
|
install-man::
|
|
|
|
install-html::
|
|
|
|
|
|
|
|
install-strip: override INSTALL_PROGRAM = $(INSTALL_STRIP_PROGRAM)
|
|
|
|
ifneq ($(STRIP),)
|
|
|
|
install-strip: STRIPPROG = $(STRIP)
|
|
|
|
export STRIPPROG
|
|
|
|
endif
|
|
|
|
install-strip: install
|
2020-12-14 17:30:00 +00:00
|
|
|
|
|
|
|
vpath %.cc $(srcdir)
|
|
|
|
vpath %.in $(srcdir)
|
|
|
|
.SUFFIXES:
|
|
|
|
.SUFFIXES: .cc .o
|
|
|
|
|
|
|
|
# Per-source & per-directory compile flags (warning: recursive)
|
|
|
|
SRC_CXXFLAGS = $(CXXFLAGS$(patsubst $(srcdir)%,%,$1)) \
|
|
|
|
$(if $(filter-out $(srcdir)/,$1),\
|
|
|
|
$(call $0,$(dir $(patsubst %/,%,$1))))
|
|
|
|
|
|
|
|
%.o: %.cc
|
|
|
|
$(CXX) $(strip $(CXXOPTS) $(call SRC_CXXFLAGS,$<) $(CXXINC)) \
|
|
|
|
-MMD -MP -MF ${@:.o=.d} -c -o $@ $<
|
|
|
|
|
|
|
|
ifeq (@CXX_AUX_TOOLS@,yes)
|
|
|
|
|
|
|
|
all::g++-mapper-server$(exeext)
|
|
|
|
|
configure: Implement --enable-host-pie
[ This is my third attempt to add this configure option. The first
version was approved but it came too late in the development cycle.
The second version was also approved, but I had to revert it:
<https://gcc.gnu.org/pipermail/gcc-patches/2022-November/607082.html>.
I've fixed the problem (by moving $(PICFLAG) from INTERNAL_CFLAGS to
ALL_COMPILERFLAGS). Another change is that since r13-4536 I no longer
need to touch Makefile.def, so this patch is simplified. ]
This patch implements the --enable-host-pie configure option which
makes the compiler executables PIE. This can be used to enhance
protection against ROP attacks, and can be viewed as part of a wider
trend to harden binaries.
It is similar to the option --enable-host-shared, except that --e-h-s
won't add -shared to the linker flags whereas --e-h-p will add -pie.
It is different from --enable-default-pie because that option just
adds an implicit -fPIE/-pie when the compiler is invoked, but the
compiler itself isn't PIE.
Since r12-5768-gfe7c3ecf, PCH works well with PIE, so there are no PCH
regressions.
When building the compiler, the build process may use various in-tree
libraries; these need to be built with -fPIE so that it's possible to
use them when building a PIE. For instance, when --with-included-gettext
is in effect, intl object files must be compiled with -fPIE. Similarly,
when building in-tree gmp, isl, mpfr and mpc, they must be compiled with
-fPIE.
With this patch and --enable-host-pie used to configure gcc:
$ file gcc/cc1{,plus,obj,gm2} gcc/f951 gcc/lto1 gcc/cpp gcc/go1 gcc/rust1 gcc/gnat1
gcc/cc1: ELF 64-bit LSB pie executable, x86-64, version 1 (GNU/Linux), dynamically linked, interpreter /lib64/ld-linux-x86-64.so.2, BuildID[sha1]=98e22cde129d304aa6f33e61b1c39e144aeb135e, for GNU/Linux 3.2.0, with debug_info, not stripped
gcc/cc1plus: ELF 64-bit LSB pie executable, x86-64, version 1 (GNU/Linux), dynamically linked, interpreter /lib64/ld-linux-x86-64.so.2, BuildID[sha1]=859d1ea37e43dfe50c18fd4e3dd9a34bb1db8f77, for GNU/Linux 3.2.0, with debug_info, not stripped
gcc/cc1obj: ELF 64-bit LSB pie executable, x86-64, version 1 (GNU/Linux), dynamically linked, interpreter /lib64/ld-linux-x86-64.so.2, BuildID[sha1]=1964f8ecee6163182bc26134e2ac1f324816e434, for GNU/Linux 3.2.0, with debug_info, not stripped
gcc/cc1gm2: ELF 64-bit LSB pie executable, x86-64, version 1 (GNU/Linux), dynamically linked, interpreter /lib64/ld-linux-x86-64.so.2, BuildID[sha1]=a396672c7ff913d21855829202e7b02ecf42ff4c, for GNU/Linux 3.2.0, with debug_info, not stripped
gcc/f951: ELF 64-bit LSB pie executable, x86-64, version 1 (GNU/Linux), dynamically linked, interpreter /lib64/ld-linux-x86-64.so.2, BuildID[sha1]=59c523db893186547ac75c7a71f48be0a461c06b, for GNU/Linux 3.2.0, with debug_info, not stripped
gcc/lto1: ELF 64-bit LSB pie executable, x86-64, version 1 (GNU/Linux), dynamically linked, interpreter /lib64/ld-linux-x86-64.so.2, BuildID[sha1]=084a7b77df7be2d63c2d4c655b5bbc3fcdb6038d, for GNU/Linux 3.2.0, with debug_info, not stripped
gcc/cpp: ELF 64-bit LSB pie executable, x86-64, version 1 (GNU/Linux), dynamically linked, interpreter /lib64/ld-linux-x86-64.so.2, BuildID[sha1]=3503bf8390d219a10d6653b8560aa21158132168, for GNU/Linux 3.2.0, with debug_info, not stripped
gcc/go1: ELF 64-bit LSB pie executable, x86-64, version 1 (GNU/Linux), dynamically linked, interpreter /lib64/ld-linux-x86-64.so.2, BuildID[sha1]=988cc673af4fba5dcb482f4b34957b99050a68c5, for GNU/Linux 3.2.0, with debug_info, not stripped
gcc/rust1: ELF 64-bit LSB pie executable, x86-64, version 1 (GNU/Linux), dynamically linked, interpreter /lib64/ld-linux-x86-64.so.2, BuildID[sha1]=b6a5d3d514446c4dcdee0707f086ab9b274a8a3c, for GNU/Linux 3.2.0, with debug_info, not stripped
gcc/gnat1: ELF 64-bit LSB pie executable, x86-64, version 1 (GNU/Linux), dynamically linked, interpreter /lib64/ld-linux-x86-64.so.2, BuildID[sha1]=bb11ccdc2c366fe3fe0980476bcd8ca19b67f9dc, for GNU/Linux 3.2.0, with debug_info, not stripped
I plan to add an option to link with -Wl,-z,now.
Bootstrapped on x86_64-pc-linux-gnu with --with-included-gettext
--enable-host-pie as well as without --enable-host-pie. Also tested
on a Debian system where the system gcc was configured with
--enable-default-pie.
Co-Authored by: Iain Sandoe <iain@sandoe.co.uk>
ChangeLog:
* configure.ac (--enable-host-pie): New check. Set PICFLAG after this
check.
* configure: Regenerate.
c++tools/ChangeLog:
* Makefile.in: Rename PIEFLAG to PICFLAG. Set LD_PICFLAG. Use it.
Use pic/libiberty.a if PICFLAG is set.
* configure.ac (--enable-default-pie): Set PICFLAG instead of PIEFLAG.
(--enable-host-pie): New check.
* configure: Regenerate.
fixincludes/ChangeLog:
* Makefile.in: Set and use PICFLAG and LD_PICFLAG. Use the "pic"
build of libiberty if PICFLAG is set.
* configure.ac:
* configure: Regenerate.
gcc/ChangeLog:
* Makefile.in: Set LD_PICFLAG. Use it. Set enable_host_pie.
Remove NO_PIE_CFLAGS and NO_PIE_FLAG. Pass LD_PICFLAG to
ALL_LINKERFLAGS. Use the "pic" build of libiberty if --enable-host-pie.
* configure.ac (--enable-host-shared): Don't set PICFLAG here.
(--enable-host-pie): New check. Set PICFLAG and LD_PICFLAG after this
check.
* configure: Regenerate.
* doc/install.texi: Document --enable-host-pie.
gcc/ada/ChangeLog:
* gcc-interface/Make-lang.in (ALL_ADAFLAGS): Remove NO_PIE_CFLAGS. Add
PICFLAG. Use PICFLAG when building ada/b_gnat1.o and ada/b_gnatb.o.
* gcc-interface/Makefile.in: Use pic/libiberty.a if PICFLAG is set.
Remove NO_PIE_FLAG.
gcc/m2/ChangeLog:
* Make-lang.in: New var, GM2_PICFLAGS. Use it.
gcc/d/ChangeLog:
* Make-lang.in: Remove NO_PIE_CFLAGS.
intl/ChangeLog:
* Makefile.in: Use @PICFLAG@ in COMPILE as well.
* configure.ac (--enable-host-shared): Don't set PICFLAG here.
(--enable-host-pie): New check. Set PICFLAG after this check.
* configure: Regenerate.
libcody/ChangeLog:
* Makefile.in: Pass LD_PICFLAG to LDFLAGS.
* configure.ac (--enable-host-shared): Don't set PICFLAG here.
(--enable-host-pie): New check. Set PICFLAG and LD_PICFLAG after this
check.
* configure: Regenerate.
libcpp/ChangeLog:
* configure.ac (--enable-host-shared): Don't set PICFLAG here.
(--enable-host-pie): New check. Set PICFLAG after this check.
* configure: Regenerate.
libdecnumber/ChangeLog:
* configure.ac (--enable-host-shared): Don't set PICFLAG here.
(--enable-host-pie): New check. Set PICFLAG after this check.
* configure: Regenerate.
libiberty/ChangeLog:
* configure.ac: Also set shared when enable_host_pie.
* configure: Regenerate.
zlib/ChangeLog:
* configure.ac (--enable-host-shared): Don't set PICFLAG here.
(--enable-host-pie): New check. Set PICFLAG after this check.
* configure: Regenerate.
2023-05-03 21:06:13 +00:00
|
|
|
ifneq ($(PICFLAG),)
|
|
|
|
override LIBIBERTY := ../libiberty/pic/libiberty.a
|
|
|
|
endif
|
|
|
|
|
2020-12-14 17:30:00 +00:00
|
|
|
MAPPER.O := server.o resolver.o
|
|
|
|
CODYLIB = ../libcody/libcody.a
|
2021-04-20 14:56:07 +00:00
|
|
|
CXXINC += -I$(srcdir)/../libcody -I$(srcdir)/../include -I$(srcdir)/../gcc -I. -I../gcc
|
2020-12-14 17:30:00 +00:00
|
|
|
g++-mapper-server$(exeext): $(MAPPER.O) $(CODYLIB)
|
Remove obsolete Solaris 11.3 support
Support for Solaris 11.3 had already been obsoleted in GCC 13. However,
since the only Solaris system in the cfarm was running 11.3, I've kept
it in tree until now when both Solaris 11.4/SPARC and x86 systems have
been added.
This patch actually removes the Solaris 11.3 support. Apart from
several minor simplifications, there are two more widespread changes:
* In Solaris 11.4, libsocket and libnsl were folded into libc, so
there's no longer a need to link them explictly.
* Since Solaris 11.4, Solaris includes all crts needed by gcc (like
crt1.o and gcrt1.o) with the base system. All workarounds to provide
fallbacks can thus go.
Bootstrapped without regressions on i386-pc-solaris2.11 and
sparc-sun-solaris2.11 (as/ld, gas/ld, and gas/gld) as well as Solaris
11.3/x86 to ascertain that version is actually rejected.
2024-04-30 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
c++tools:
* configure.ac (ax_lib_socket_nsl.m4): Don't sinclude.
(AX_LIB_SOCKET_NSL): Don't call.
(NETLIBS): Remove.
* configure: Regenerate.
* Makefile.in (NETLIBS): Remove.
(g++-mapper-server$(exeext)): Remove $(NETLIBS).
gcc:
* config.gcc: Move *-*-solaris2.11.[0-3]* to unsupported list.
<*-*-solaris2*> (default_use_cxa_atexit): Set unconditionally.
* configure.ac (AX_LIB_SOCKET_NSL): Don't call.
(NETLIBS): Remove.
(gcc_cv_ld_aligned_shf_merge): Remove.
(hidden_linkonce) <i?86-*-solaris2* | x86_64-*-solaris2*>: Remove.
(gcc_cv_target_dl_iterate_phdr) <*-*-solaris2*>: Always set to yes.
* Makefile.in (NETLIBS): Remove.
* configure, config.in, aclocal.m4: Regenerate.
* config/sol2.h: Don't check HAVE_SOLARIS_CRTS.
(STARTFILE_SPEC): Remove !HAVE_SOLARIS_CRTS case.
[USE_GLD] (LINK_EH_SPEC): Remove TARGET_DL_ITERATE_PHDR guard.
* config/i386/i386.cc (USE_HIDDEN_LINKONCE): Remove guard.
* varasm.cc (mergeable_string_section): Remove
HAVE_LD_ALIGNED_SHF_MERGE handling.
(mergeable_constant_section): Likewise.
* doc/install.texi (Specific,i?86-*-solaris2*): Reference Solaris
11.4 only.
(Specific, *-*-solaris2*): Document Solaris 11.3 removal. Remove
11.3 references and caveats. Update for 11.4.
gcc/cp:
* Make-lang.in (cc1plus$(exeext)): Remove $(NETLIBS).
gcc/objcp:
* Make-lang.in (cc1objplus$(exeext)): Remove $(NETLIBS).
gcc/testsuite:
* lib/target-supports.exp (check_effective_target_pie): Always
enable on *-*-solaris2*.
libgcc:
* configure.ac <*-*-solaris2*> (libgcc_cv_solaris_crts): Remove.
* config.host <*-*-solaris2*>: Remove !libgcc_cv_solaris_crts
support.
* configure, config.in: Regenerate.
* config/sol2/gmon.c (internal_mcount) [!HAVE_SOLARIS_CRTS]: Remove.
* config/i386/sol2-c1.S, config/sparc/sol2-c1.S: Remove.
* config/sol2/t-sol2 (crt1.o, gcrt1.o): Remove.
libstdc++-v3:
* testsuite/lib/dg-options.exp (add_options_for_net_ts)
<*-*-solaris2*>: Don't link with -lsocket -lnsl.
2024-05-07 08:45:55 +00:00
|
|
|
+$(CXX) $(LDFLAGS) $(PICFLAG) $(LD_PICFLAG) -o $@ $^ $(LIBIBERTY)
|
2020-12-14 17:30:00 +00:00
|
|
|
|
|
|
|
# copy to gcc dir so tests there can run
|
|
|
|
all::../gcc/g++-mapper-server$(exeext)
|
|
|
|
|
|
|
|
../gcc/g++-mapper-server$(exeext): g++-mapper-server$(exeext)
|
2020-12-16 13:14:57 +00:00
|
|
|
$(INSTALL) $< $@
|
2020-12-14 17:30:00 +00:00
|
|
|
|
|
|
|
install::
|
2020-12-16 13:14:57 +00:00
|
|
|
$(SHELL) $(srcdir)/../mkinstalldirs $(DESTDIR)$(libexecsubdir)
|
2020-12-16 19:44:42 +00:00
|
|
|
$(INSTALL_PROGRAM) g++-mapper-server$(exeext) $(DESTDIR)$(libexecsubdir)
|
2020-12-14 17:30:00 +00:00
|
|
|
endif
|
|
|
|
|
|
|
|
ifneq ($(MAINTAINER),)
|
|
|
|
override MAINTAINER += $1
|
|
|
|
endif
|
|
|
|
ifeq (@MAINTAINER@,yes)
|
|
|
|
MAINTAINER = $2
|
|
|
|
else
|
|
|
|
MAINTAINER = \# --enable-maintainer-mode to rebuild $1, or make MAINTAINER=touch
|
|
|
|
endif
|
|
|
|
|
|
|
|
all:: Makefile
|
|
|
|
|
|
|
|
Makefile: $(srcdir)/Makefile.in config.status
|
|
|
|
$(SHELL) ./config.status Makefile
|
|
|
|
|
|
|
|
$(srcdir)/configure: $(srcdir)/configure.ac
|
|
|
|
$(call MAINTAINER,$@,cd $(@D) && $(AUTOCONF) -W all,error)
|
|
|
|
|
|
|
|
$(srcdir)/config.h.in: $(srcdir)/configure.ac
|
|
|
|
$(call MAINTAINER,$@,cd $(@D) && $(AUTOHEADER) -f -W all,error)
|
|
|
|
|
|
|
|
config.h: config.status config.h.in
|
|
|
|
./$< --header=$@
|
|
|
|
touch $@
|
|
|
|
|
|
|
|
config.status: $(srcdir)/configure $(srcdir)/config.h.in
|
|
|
|
if test -x $@; then ./$@ -recheck; else $< @configure_args@; fi
|
|
|
|
|
2023-03-30 12:03:11 +00:00
|
|
|
.PHONY: all check mostlyclean clean distclean maintainer-clean
|
2020-12-14 17:30:00 +00:00
|
|
|
|
|
|
|
-include $(MAPPER.O:.o=.d)
|