head	1.9;
access;
symbols
	libc-5-4-46:1.9
	libc-5-4-45:1.9
	libc-5-4-44:1.9
	libc-5-4-43:1.9
	libc-5-4-42:1.9
	libc-5-4-41:1.9
	libc-5-4-40:1.9
	libc-5-4-39:1.9
	libc-5-4-38:1.9
	libc-5-4-37:1.9
	libc-5-4-36:1.9
	libc-5-4-35:1.9
	libc-5-4-34:1.9
	libc-5-4-33:1.9
	libc-5-4-32:1.9
	libc-5-4-31:1.9
	libc-5-4-30:1.9
	libc-5-4-29:1.9
	libc-5-4-28:1.9
	libc-5-4-27:1.9
	libc-5-4-26:1.9
	libc-5-4-25:1.9
	libc-5-4-24:1.9
	libc-5-4-23:1.9
	libc-5-4-22:1.9
	libc-5-4-21:1.9
	libc-5-4-20:1.9
	libc-5-4-19:1.9
	libc-5-4-18:1.9
	libc-5-4-17-public:1.9
	libc-5-4-17:1.9
	libc-5-4-16:1.9
	libc-5-4-15:1.9
	libc-5-4-14:1.9
	libc-5-4-13:1.9
	libc-5-4-12:1.9
	libc-5-4-11:1.9
	libc-5-4-10:1.9
	libc-5-4-9:1.9
	libc-5-4-8:1.9
	libc-5-4-7-public:1.9
	libc-5-4-7:1.9
	libc-5-4-6:1.9
	libc-5-4-5:1.9
	libc-5-4-4:1.9
	libc-5-4-3:1.9
	libc-5-4-2:1.9
	libc-5-4-1:1.8
	libc-5-4-0:1.8
	libc-5-3-12:1.8
	libc-5-3-11:1.8
	libc-5-3-10:1.8
	libc-5-3-9:1.8
	libc-5-3-8:1.8
	libc-5-3-7:1.8
	libc-5-3-7-pre:1.8
	libc-5-3-6:1.8
	libc-5-3-5:1.8
	libc-5-3-4:1.8
	libc-5-3-3:1.8
	libc-5-3-2:1.8
	libc-5-3-1:1.8
	libc-5-3-0:1.8
	libc-5-2-19:1.8
	libc-5-2-18:1.8
	libc-5-2-17:1.8
	libc-5-2-16:1.8
	libc-5-2-15:1.8
	libc-5-2-14:1.8
	libc-5-2-13:1.7
	libc-5-2-12:1.7
	libc-5-2-11:1.7
	libc-5-2-10:1.7
	libc-5-2-9:1.6
	libc-5-2-8-1:1.5
	libc-5-2-8:1.5
	libc-5-2-7:1.5
	libc-5-2-6:1.5
	libc-5-2-5:1.5
	libc-5-2-4:1.5
	libc-5-2-3:1.5
	libc-5-2-2:1.5
	libc-5-2-1:1.5
	libc-5-2-0:1.5
	libc-4-7-4:1.1.1.1.2.1
	libc-5-1-4:1.5
	libc-5-1-3:1.5
	libc-5-1-2:1.5
	libc-5-1-1:1.5
	libc-5-1-0:1.5
	libc-4-7-3:1.1.1.1.2.1
	libc-5-0-12-stable:1.5
	libc-5-0-11:1.5
	libc-5-0-10:1.5
	libc-5-0-9:1.4
	libc-5-0-8:1.4
	libc-5-0-7:1.4
	libc-5-0-6:1.4
	libc-5-0-5:1.4
	libc-5-0-4:1.4
	libc-5-0-3:1.4
	libc-4-7-2:1.1.1.1.2.1
	libc-4-7-1-b:1.1.1.1.2.1.0.2
	libc-5-0-2:1.4
	libc-5-0-1-1:1.4
	libc-5-0-1:1.3
	libc-4-7-1:1.1.1.1.2.1
	libc-5-0-0:1.3
	libc-4-7-0:1.1.1.1.2.1
	libc-4-8-0:1.3
	libc-4-6-27-patches:1.1.1.1.0.2
	libc-4-6-30:1.2
	libc-4-6-29:1.1.1.1
	libc-4-6-28-6:1.1.1.1
	libc-4-6-28-5:1.1.1.1
	libc-4-6-28-4:1.1.1.1
	libc-4-6-28-3:1.1.1.1
	libc-4-6-28-2:1.1.1.1
	libc-4-6-28-1:1.1.1.1
	libc-4-6-28:1.1.1.1
	libc-4-6-27:1.1.1.1
	linux:1.1.1;
locks; strict;
comment	@# @;


1.9
date	96.06.05.16.07.38;	author hjl;	state Exp;
branches;
next	1.8;

1.8
date	95.11.18.23.42.03;	author hjl;	state Exp;
branches;
next	1.7;

1.7
date	95.09.28.04.01.24;	author hjl;	state Exp;
branches;
next	1.6;

1.6
date	95.09.13.02.09.59;	author hjl;	state Exp;
branches;
next	1.5;

1.5
date	95.05.25.05.22.43;	author hjl;	state Exp;
branches;
next	1.4;

1.4
date	95.04.19.02.37.59;	author hjl;	state Exp;
branches;
next	1.3;

1.3
date	95.03.16.04.37.10;	author hjl;	state Exp;
branches;
next	1.2;

1.2
date	95.03.05.00.27.09;	author hjl;	state Exp;
branches;
next	1.1;

1.1
date	95.02.18.05.33.18;	author hjl;	state Exp;
branches
	1.1.1.1;
next	;

1.1.1.1
date	95.02.18.05.33.19;	author hjl;	state Exp;
branches
	1.1.1.1.2.1;
next	;

1.1.1.1.2.1
date	95.03.16.04.54.46;	author hjl;	state Exp;
branches;
next	;


desc
@@


1.9
log
@Update for libc 5.4.2.
@
text
@#
# This is Makefile for libgcc.a
#

override STATIC=false
override DEBUG=false
override PROFILE=false
#override CHECKER=false

JUMP_LIB=libgcc

TOPDIR=..

include $(TOPDIR)/Makeconfig
include $(TOPDIR)/Makerules

srcdir=.

ifeq ($(CHECKER),true)
LIBGCC=$(CHECKER_DIR)/libgcc/libgcc3.a
else
LIBGCCDIR=$(SHARED_DIR)/libgcc
endif

LIBGCC1=#libgcc1.a
LIBGCC2=libgcc2.a

CFLAGS = $(WFLAGS) $(OPT_CFLAGS) $(INC_CFLAGS) $(XCFLAGS)

INCLUDES =$(SYSTEM_INC_CFLAGS) -I. -I$(srcdir) -I$(srcdir)/config
INC_CFLAGS=$(INCLUDES)

CCLIBFLAGS= $(OPT_CFLAGS)
LIBGCC2_CFLAGS=$(OPT_CFLAGS) $(DEBUGFLAGS)

DIRS=

ifeq ($(STATIC_SHARED),true)
SHARED=true
endif

ifeq ($(SHARED),true)

SHARED=FALSE

include $(TOPDIR)/Maketargets

ifeq ($(ELF),true)

LIB2FUNCS = _udivdi3 _umoddi3 _udivmoddi4 \
	_op_new _op_vnew _new_handler _op_delete _op_vdel \
	_eh __gcc_bcmp _varargs _shtab _clear_cache \
	_trampoline _pure

LIBGCC2_CFLAGS=$(BASE_OPTFLAGS) $(PIC_OPT_CFLAGS)
else

LIB2FUNCS = _eprintf __main _exit _ctors _op_new _op_delete \
         _new_handler _udivdi3 _umoddi3 _udivmoddi4
# _muldi3 _udivdi3 _umoddi3 _udivmoddi4

LIBGCC2_CFLAGS=$(BASE_OPTFLAGS) $(DEBUGFLAGS) -B$(JUMPAS)

LIBGCCALIASES=$(SHARED_DIR)/$(SUBDIR)/aliases.o

endif

lib::
	@@if [ -d $(SHARED_DIR)/$(SUBDIR) ]; then \
	  true; else \
	  $(RM) -f $(SHARED_DIR)/$(SUBDIR); \
	  $(MKDIR) $(SHARED_DIR)/$(SUBDIR); \
	fi
	$(RM) -f libgcc1.a	# safer (it can be the checkered one)

lib all:: libgcc

else

ifeq ($(CHECKER),true)

include $(TOPDIR)/Maketargets

LIB2FUNCS = _eprintf __main _exit _ctors _op_new _op_delete \
         _new_handler _muldi3 _udivdi3 _umoddi3 _udivmoddi4

LIBGCCALIASES=$(CHECKER_DIR)/$(SUBDIR)/aliases.o

LIBGCC2_CFLAGS=$(BASE_OPTFLAGS) $(DEBUGFLAGS) $(CHECKER_OPT_CFLAGS)

lib::
	@@if [ -d $(CHECKER_DIR)/$(SUBDIR) ]; then \
	  true; else \
	  $(RM) -f $(CHECKER_DIR)/$(SUBDIR); \
	  $(MKDIR) $(CHECKER_DIR)/$(SUBDIR); \
	fi
	$(RM) -f libgcc1.a	# safer (it can be the static one)

lib all:: libgcc

else

lib all:
	@@true

endif
endif

libgcc:: config.h  hconfig.h tconfig.h tm.h

ifeq ($(CANONICAL_TARGET_MACHINE),ix86-linux)

config.h: config/i386/xm-linux.h
	ln -s $? $@@

hconfig.h: config/i386/xm-linux.h
	ln -s $? $@@

tconfig.h: config/i386/xm-linux.h
	ln -s $? $@@

tm.h: config/i386/linux.h
	ln -s $? $@@

endif

ifeq ($(CANONICAL_TARGET_MACHINE),m68k-linux)

config.h: config/m68k/xm-linux.h
	ln -s $? $@@

hconfig.h: config/m68k/xm-linux.h
	ln -s $? $@@

tconfig.h: config/m68k/xm-linux.h
	ln -s $? $@@

tm.h: config/m68k/linux.h
	ln -s $? $@@

endif

libgcc1.a: libgcc1.c
	-$(RM) -fr tmplibgcc1.a tmpcopy
# Actually build it in tmplibgcc1.a, then rename at end,
# so that libgcc1.a itself remains nonexistent if compilation is aborted.
# -e causes any failing command to make this rule fail.
# -e doesn't work in certain shells, so we test $$? as well.
	-set -e; \
	mkdir tmpcopy; \
	for name in .. $(LIB1FUNCS); \
	do \
	  if [ x$${name} != x.. ]; then \
	    echo $${name}; \
	    $(CC) $(CCLIBFLAGS) $(INCLUDES) -c -DL$${name} \
	    	$(srcdir)/libgcc1.c -o ./tmpcopy/$${name}.o; \
	    if [ $$? -eq 0 ] ; then true; else exit 1; fi; \
	  else true; fi; \
	done
	(cd ./tmpcopy; $(AR) $(AR_FLAGS) ../tmplibgcc1.a *.o)
	$(RM) -rf ./tmpcopy
# Some shells crash when a loop has no items.
# So make sure there is always at least one--`..'.
# Then ignore it.
# We don't use -e here because there are if statements
# that should not make the command give up when the if condition is false.
# Instead, we test for failure after each command where it matters.
	-for file in .. $(LIB1FUNCS_EXTRA); \
	do \
	  if [ x$${file} != x.. ]; then \
	    name=`echo $${file} | sed -e 's/[.]c$$//' -e 's/[.]asm$$//'`; \
	    echo $${name}; \
	    if [ $${name}.asm = $${file} ]; then \
	      cp $${file} $${name}.s || exit 1; file=$${name}.s; \
	    else true; fi; \
	    $(CC) $(CCLIBFLAGS) $(INCLUDES) -c $${file}; \
	    if [ $$? -eq 0 ] ; then true; else exit 1; fi; \
	    $(AR) $(AR_FLAGS) tmplibgcc1.a $${name}.o; \
	    if [ $$? -eq 0 ] ; then true; else exit 1; fi; \
	    rm -f $${name}.[so]; \
	  else true; \
	  fi; \
	done
	if [ -f tmplibgcc1.a ]; then \
	  mv tmplibgcc1.a libgcc1.a; \
	else true; fi

# Compiling libgcc2.a requires making sure that cc1, etc. have been compiled.
# But recompiling cc1 should not force recompilation of libgcc2.a.
# If you want to force recompilation, delete libgcc2.a.
# Depend on install-cross-tools to make sure we set up properly 
# to run the assembler before we try compiling anything.
# install-cross-tools does nothing if not cross compiling.
libgcc2.ready: $(GCC_PASSES) $(CROSS_TOOLS)
	-if [ -f libgcc2.ready ] ; then \
		true; \
	else \
		touch libgcc2.ready; \
	fi

libgcc2.a: libgcc2.c
#libgcc2.ready $(CONFIG_H) $(LIB2FUNCS_EXTRA) \
#   machmode.h longlong.h gbl-ctors.h config.status
# Actually build it in tmplibgcc2.a, then rename at end,
# so that libgcc2.a itself remains nonexistent if compilation is aborted.
	-$(RM) -fr tmplibgcc2.a tmpcopy
# -e causes any failing command to make this rule fail.
# -e doesn't work in certain shells, so we test $$? as well.
	set -e; \
	mkdir tmpcopy; \
	for name in $(LIB2FUNCS); \
	do \
	  echo $${name}; \
	  $(CC) $(LIBGCC2_CFLAGS) $(INCLUDES) -c -DL$${name} \
	      $(srcdir)/libgcc2.c -o ./tmpcopy/$${name}.o; \
	  if [ $$? -eq 0 ] ; then true; else exit 1; fi; \
	done
	(cd ./tmpcopy; $(AR) $(AR_FLAGS) ../tmplibgcc2.a *.o)
	$(RM) -rf ./tmpcopy
# Some shells crash when a loop has no items.
# So make sure there is always at least one--`..'.
# Then ignore it.
# We don't use -e here because there are if statements
# that should not make the command give up when the if condition is false.
# Instead, we test for failure after each command where it matters.
	-for file in .. $(LIB2FUNCS_EXTRA); \
	do \
	  if [ x$${file} != x.. ]; then \
	    name=`echo $${file} | sed -e 's/[.]c$$//' -e 's/[.]asm$$//'`; \
	    echo $${name}; \
	    if [ $${name}.asm = $${file} ]; then \
	      cp $${file} $${name}.s || exit 1; file=$${name}.s; \
	    else true; fi; \
	    $(CC) $(LIBGCC2_CFLAGS) $(INCLUDES) -c $${file}; \
	    if [ $$? -eq 0 ] ; then true; else exit 1; fi; \
	    $(AR) $(AR_FLAGS) tmplibgcc2.a $${name}.o; \
	    rm -f $${name}.[so]; \
	  else true; \
	  fi; \
	done
	mv tmplibgcc2.a libgcc2.a
# These lines were deleted from above the mv command
# because ranlibing libgcc.a itself should suffice.
#	-if [ x${HPUX_GAS} = x ] ; then \
#	  if $(RANLIB_TEST) ; then $(RANLIB) tmplibgcc2.a; else true; fi \
#	else true; fi

# Combine the various libraries into a single library, libgcc.a.
libgcc:: $(LIBGCC1) $(LIBGCC2) $(LIBGCCALIASES)
	-$(RM) -rf tmplibgcc.a $(LIBGCC) tmpcopy
	mkdir tmpcopy
	-if [ x$(LIBGCC1) != x ];			\
	then (cd tmpcopy; $(AR) x ../$(LIBGCC1));	\
	else true;					\
	fi
	(cd tmpcopy; $(AR) x ../$(LIBGCC2))
	(cd tmpcopy; $(AR) $(AR_FLAGS) ../tmplibgcc.a *.o)
	$(RM) -rf tmpcopy $(LIBGCC2)
# Actually build it in tmplibgcc.a, then rename at end,
# so that libgcc.a itself remains nonexistent if compilation is aborted.
	$(AR) $(AR_FLAGS) tmplibgcc.a $(LIBGCCALIASES)
	$(REALRANLIB) tmplibgcc.a
	mv tmplibgcc.a $(LIBGCCDIR)/../libgcc.a
	(cd $(LIBGCCDIR); $(AR) -x ../libgcc.a)

clean::
	-rm -f config.h  hconfig.h tconfig.h tm.h

depend::
@


1.8
log
@Update for libc 5.2.14.
@
text
@d263 2
a264 2
	mv tmplibgcc.a $(LIBGCCDIR)/libgcc.a
	(cd $(LIBGCCDIR); $(AR) -x libgcc.a)
@


1.7
log
@Update for libc 5.2.10.
@
text
@d30 1
a30 1
INCLUDES = -I. -I$(srcdir) -I$(srcdir)/config
@


1.6
log
@Update for libc 5.2.9.
@
text
@d268 2
@


1.5
log
@Update for threads.
@
text
@d127 16
@


1.4
log
@Fix libelf.h and add support to shared C++ libraries
@
text
@d111 1
a111 1
ifeq ($(TARGET_MACHINE),i486-linux)
@


1.3
log
@Make symlinks in elf/crt and gcc
@
text
@d22 1
a22 1
LIBGCC=$(SHARED_DIR)/libgcc/libgcc3.a
d50 4
a53 1
LIB2FUNCS = _udivdi3 _umoddi3 _udivmoddi4
d111 2
d125 2
d247 5
a251 1
	mv tmplibgcc.a $(LIBGCC)
@


1.2
log
@Update the changes for 4.6.30
@
text
@d106 14
d226 1
a226 1
libgcc: $(LIBGCC1) $(LIBGCC2) $(LIBGCCALIASES)
@


1.1
log
@Initial revision
@
text
@d48 7
d56 1
a56 1
         _new_handler
d59 2
d63 1
a63 1
LIBGCC2_CFLAGS=$(BASE_OPTFLAGS) $(DEBUGFLAGS) -B$(JUMPAS)
@


1.1.1.1
log
@The Linux C library 4.6.27 (source files).
@
text
@@


1.1.1.1.2.1
log
@Create symlinks if needed.
@
text
@a47 7
ifeq ($(ELF),true)

LIB2FUNCS = _udivdi3 _umoddi3 _udivmoddi4

LIBGCC2_CFLAGS=$(BASE_OPTFLAGS) $(PIC_OPT_CFLAGS)
else

d49 1
a49 1
         _new_handler _udivdi3 _umoddi3 _udivmoddi4
a51 2
LIBGCC2_CFLAGS=$(BASE_OPTFLAGS) $(DEBUGFLAGS) -B$(JUMPAS)

d54 1
a54 1
endif
a96 14
libgcc:: config.h  hconfig.h tconfig.h tm.h

config.h: config/i386/xm-linux.h
	ln -s $? $@@

hconfig.h: config/i386/xm-linux.h
	ln -s $? $@@

tconfig.h: config/i386/xm-linux.h
	ln -s $? $@@

tm.h: config/i386/linux.h
	ln -s $? $@@

d203 1
a203 1
libgcc:: $(LIBGCC1) $(LIBGCC2) $(LIBGCCALIASES)
@

