xref: /netbsd-src/external/gpl3/gcc.old/dist/gcc/config/ia64/t-hpux (revision 230b95665bbd3a9d1a53658a36b1053f8382a519)
1# Copyright (C) 2001, 2002, 2003, 2004, 2005,
2# 2006 Free Software Foundation, Inc.
3#
4# This file is part of GCC.
5#
6# GCC is free software; you can redistribute it and/or modify
7# it under the terms of the GNU General Public License as published by
8# the Free Software Foundation; either version 3, or (at your option)
9# any later version.
10#
11# GCC is distributed in the hope that it will be useful,
12# but WITHOUT ANY WARRANTY; without even the implied warranty of
13# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
14# GNU General Public License for more details.
15#
16# You should have received a copy of the GNU General Public License
17# along with GCC; see the file COPYING3.  If not see
18# <http://www.gnu.org/licenses/>.
19
20# We need multilib support for HPUX's ILP32 & LP64 modes.
21
22LIBGCC = stmp-multilib
23INSTALL_LIBGCC = install-multilib
24
25MULTILIB_OPTIONS = milp32/mlp64
26MULTILIB_DIRNAMES = hpux32 hpux64
27MULTILIB_MATCHES =
28
29# On HP-UX we do not want _fixtfdi, _fixunstfdi, or _floatditf from
30# LIB1ASMSRC.  These functions map the 128 bit conversion function names
31# to 80 bit conversions and were done for Linux backwards compatibility.
32
33LIB1ASMFUNCS := $(filter-out _fixtfdi _fixunstfdi _floatditf,$(LIB1ASMFUNCS))
34
35# Support routines for HP-UX 128 bit floats.
36
37LIB2FUNCS_EXTRA=quadlib.c $(srcdir)/config/floatunsitf.c
38
39quadlib.c: $(srcdir)/config/ia64/quadlib.c
40	cat $(srcdir)/config/ia64/quadlib.c > quadlib.c
41
42# We get an undefined main when building a cross compiler because our
43# linkspec has "-u main" and we want that for linking but it makes
44# LIBGCC1_TEST fail because it uses -nostdlib -nostartup.
45
46LIBGCC1_TEST =
47
48# We do not want to include the EH stuff that linux uses, we want to use
49# the HP-UX libunwind library.
50
51T_CFLAGS += -DUSE_LIBUNWIND_EXCEPTIONS
52
53LIB2ADDEH =
54
55SHLIB_EXT = .so
56# Must include -lunwind in the link, so that libgcc_s.so has the necessary
57# DT_NEEDED entry for libunwind.
58SHLIB_LINK = $(GCC_FOR_TARGET) $(LIBGCC2_CFLAGS) -shared -nodefaultlibs \
59	-Wl,+h,@shlib_base_name@.so.0 \
60	-o @multilib_dir@/@shlib_base_name@.so @multilib_flags@ \
61	@shlib_objs@ -lunwind -lc && \
62	rm -f @multilib_dir@/@shlib_base_name@.so.0 && \
63	$(LN_S) @shlib_base_name@.so @multilib_dir@/@shlib_base_name@.so.0
64# $(slibdir) double quoted to protect it from expansion while building
65# libgcc.mk.  We want this delayed until actual install time.
66SHLIB_INSTALL = \
67        $$(mkinstalldirs) $$(DESTDIR)$$(slibdir)@shlib_slibdir_qual@; \
68	$(INSTALL_DATA) @multilib_dir@/@shlib_base_name@.so \
69	$$(DESTDIR)$$(slibdir)@shlib_slibdir_qual@/@shlib_base_name@.so.0; \
70	rm -f $$(DESTDIR)$$(slibdir)@shlib_slibdir_qual@/@shlib_base_name@.so; \
71	$(LN_S) @shlib_base_name@.so.0 \
72	$$(DESTDIR)$$(slibdir)@shlib_slibdir_qual@/@shlib_base_name@.so; \
73	chmod +x $$(DESTDIR)$$(slibdir)@shlib_slibdir_qual@/@shlib_base_name@.so
74
75SHLIB_MKMAP = $(srcdir)/mkmap-flat.awk
76