include $(TREE)/release-info
+# Set TIME to time to get timings. Not done by default because time
+# ignores the exit status.
+TIME :=
-TIME := time
CONFIG_SHELL :=
-GCC := $(host)-gcc -O
+GCC := $(host)-gcc -O2
GNUC := CC="$(GCC)"
CFLAGS := -g
-CXXFLAGS := -g -O
+CXXFLAGS := -g -O2
GNU_MAKE := /usr/latest/bin/make -w
MAKEINFOFLAGS :=
target := $(host)
endif
+ifeq ($(patsubst %-lynx,lynx,$(host)),lynx)
+SHELL := /bin/bash
+GNU_MAKE := $(MAKE)
+CONFIG_SHELL := /bin/bash
+endif
+
+ifeq ($(patsubst %-m68k-hp-hpux,m68k-hp-hpux,$(host)),m68k-hp-hpux)
+SHELL := /usr/unsupported/bin/bash
+GNU_MAKE := $(MAKE)
+CONFIG_SHELL := /usr/unsupported/bin/bash
+endif
+
ifneq ($(build),$(host))
# We are building on a machine other than the host. We rely upon
CC := $(host)-gcc
CC_FOR_BUILD := gcc
CC_FOR_TARGET := $(target)-gcc
-CXX := $(host)-c++
-CXX_FOR_TARGET := $(target)-c++
-GCC := $(host)-gcc -O
+CXX := $(host)-gcc
+CXX_FOR_TARGET := $(target)-gcc
+GCC := $(host)-gcc -O2
GXX := $(host)-g++
GXX_FOR_TARGET := $(target)-g++
HOST_PREFIX := $(build)-
RANLIB_FOR_TARGET := $(target)-ranlib
YACC := $(BISON)
-ifeq ($(build),hppa1.1-hp-hpux)
-CC_FOR_BUILD := cc
+ifeq ($(host),i386-go32)
+MAKEINFOFLAGS = --no-split
endif
FLAGS_TO_PASS := \
"TIME=$(TIME)" \
"MAKEINFOFLAGS=$(MAKEINFOFLAGS)" \
"MF=$(MF)" \
- "SHELL=$(SHELL)" \
"host=$(host)" \
- "RELEASE_TAG=$(RELEASE_TAG)"
+ "RELEASE_TAG=$(RELEASE_TAG)" \
+ "SHELL=$(SHELL)"
configenv :=
endif
ifeq ($(host),mips-sgi-irix4)
-CC := cc -cckr -Wf,-XNg1500 -Wf,-XNk1000 -Wf,-XNh1500
+CC := cc -cckr -Wf,-XNg1500 -Wf,-XNk1000 -Wf,-XNh2000
endif
-ifeq ($(host),mips-mips-riscos5)
+ifeq ($(host),hppa1.1-hp-hpux)
+CC := cc -Wp,-H256000
+endif
+
+ifeq ($(host),mips-mips-riscos5sysv)
CC := cc -non_shared -systype sysv
endif
CC := cc -J
endif
+# We want to use stabs for MIPS targets.
+ifeq ($(target),mips-idt-ecoff)
+configargs = -with-stabs
+endif
+
+ifeq ($(target),mips-dec-ultrix)
+configargs = -with-stabs
+endif
+
+ifeq ($(target),mips-sgi-irix4)
+configargs = -with-stabs
+endif
+
+ifeq ($(target),mips-sgi-irix5.2)
+configargs = -with-stabs
+endif
+
+ifeq ($(target),alpha-dec-osf1.3)
+configargs = -with-stabs
+endif
+
+# We must use stabs for SVR4 targets.
+ifeq ($(target),i386-sysv4.2)
+configargs = -with-stabs
+endif
+
ifneq ($(CC), 'cc')
FLAGS_TO_PASS := "CC=$(CC)" $(FLAGS_TO_PASS)
endif
+#### and on some, we need CONFIG_SHELL
+ifeq ($(patsubst %-lynxos,lynxos,$(host)),lynxos)
+FLAGS_TO_PASS := "CONFIG_SHELL=$(CONFIG_SHELL)" $(FLAGS_TO_PASS)
+endif
# These are the prefixes used for Cygnus builds.
prefixes = --prefix=$(release_root) --exec-prefix=$(release_root)/H-$(host)
config = -host=$(host) -target=$(target)
FLAGS_TO_PASS := $(FLAGS_TO_PASS) "target=$(target)"
+ifeq ($(patsubst %-lynx,lynx,$(target)),lynx)
+configargs := $(configargs) --with-headers=/s1/cygnus/dejagnu/$(target)/include \
+ --with-libs=/s1/cygnus/dejagnu/$(target)/lib
+endif
+
+ifeq ($(patsubst %-i386-sysv4.2,i386-sysv4.2,$(target)),i386-sysv4.2)
+configargs := $(configargs) --with-headers=/s1/cygnus/dejagnu/$(target)/include \
+ --with-libs=/s1/cygnus/dejagnu/$(target)/lib
+endif
+
+ifeq ($(patsubst %-sparc-sun-sunos4.1.3,sparc-sun-sunos4.1.3,$(target)),sparc-sun-sunos4.1.3)
+configargs := $(configargs) --with-headers=/s1/cygnus/dejagnu/$(target)/include \
+ --with-libs=/s1/cygnus/dejagnu/$(target)/lib
+endif
+
+ifeq ($(patsubst %-sparc-sun-solaris2,sparc-sun-solaris2,$(target)),sparc-sun-solaris2)
+configargs := $(configargs) --with-headers=/s1/cygnus/dejagnu/$(target)/include \
+ --with-libs=/s1/cygnus/dejagnu/$(target)/lib
+endif
+
ifneq ($(build),$(host))
all: do-cygnus do-latest
build-all: build-cygnus build-latest
$(SET_CYGNUS_PATH) cd $(CYGNUSDIR) ; $(TIME) $(MAKE) $(FLAGS_TO_PASS) $(GNUC) install-info
if [ -f VAULT-INSTALL ] ; then \
$(SET_CYGNUS_PATH) cd $(CYGNUSDIR) ; $(MAKE) $(FLAGS_TO_PASS) $(GNUC) vault-install ; \
- fi
+ else true ; fi
touch $@
$(arch)-stamp-cygnus-checked: $(HOLESSTAMP) $(arch)-stamp-cygnus-built
touch $@
+# The SunOS make program gets confused when it is deleted while running.
+# The signal handlers return to the wrong place, or something, and the
+# program dumps core. To avoid trouble with installing make over itself,
+# we delete the installed make program.
$(host)-stamp-stage2-installed: $(host)-stamp-stage2-checked
- $(SET_CYGNUS_PATH) cd $(WORKING_DIR) ; $(TIME) $(MAKE) -w $(FLAGS_TO_PASS) $(GNUC) "CFLAGS=$(CFLAGS)" install host=$(host)
+ -rm -f $(relbindir)/make
+ $(SET_CYGNUS_PATH) cd $(WORKING_DIR) ; $(TIME) $(GNU_MAKE) -w $(FLAGS_TO_PASS) $(GNUC) "CFLAGS=$(CFLAGS)" install host=$(host)
$(SET_CYGNUS_PATH) cd $(WORKING_DIR) ; $(TIME) $(MAKE) -w $(FLAGS_TO_PASS) $(GNUC) "CFLAGS=$(CFLAGS)" install-info host=$(host)
touch $@
touch $@
+# The SunOS make program gets confused when it is deleted while running.
+# The signal handlers return to the wrong place, or something, and the
+# program dumps core. To avoid trouble with installing make over itself,
+# we delete the installed make program.
$(host)-stamp-stage3-installed: $(host)-stamp-stage3-checked
- $(SET_CYGNUS_PATH) cd $(WORKING_DIR) ; $(TIME) $(MAKE) -w $(FLAGS_TO_PASS) $(GNUC) "CFLAGS=$(CFLAGS)" install host=$(host)
+ -rm -f $(relbindir)/make
+ $(SET_CYGNUS_PATH) cd $(WORKING_DIR) ; $(TIME) $(GNU_MAKE) -w $(FLAGS_TO_PASS) $(GNUC) "CFLAGS=$(CFLAGS)" install host=$(host)
$(SET_CYGNUS_PATH) cd $(WORKING_DIR) ; $(TIME) $(MAKE) -w $(FLAGS_TO_PASS) $(GNUC) "CFLAGS=$(CFLAGS)" install-info host=$(host)
if [ -f VAULT-INSTALL ] ; then \
$(SET_CYGNUS_PATH) cd $(CYGNUSDIR) ; $(MAKE) $(FLAGS_TO_PASS) $(GNUC) vault-install ; \
- fi
+ else true ; fi
touch $@
$(host)-stamp-stage3-checked: $(host)-stamp-stage3-built
# $(SET_CYGNUS_PATH) cd $(WORKING_DIR) ; $(TIME) $(MAKE) -w $(FLAGS_TO_PASS) $(GNUC) "CFLAGS=$(CFLAGS)" check host=$(host)
touch $@
+$(host)-check-3stage: $(host)-stamp-stage3
+ $(SET_CYGNUS_PATH) cd $(STAGE3DIR) ; $(TIME) $(MAKE) -w $(FLAGS_TO_PASS) $(GNUC) "CFLAGS=$(CFLAGS)" check host=$(host)
+ touch $@
+
$(host)-stamp-stage3-built: $(host)-stamp-stage3-configured
$(SET_CYGNUS_PATH) cd $(WORKING_DIR) ; $(TIME) $(MAKE) -w $(FLAGS_TO_PASS) $(GNUC) "CFLAGS=$(CFLAGS)" all host=$(host)
$(SET_CYGNUS_PATH) cd $(WORKING_DIR) ; $(TIME) $(MAKE) -w $(FLAGS_TO_PASS) $(GNUC) "CFLAGS=$(CFLAGS)" info host=$(host)
rmdir \
sed \
sh \
+ sleep \
sort \
tar \
test \
DOS_HOLES := aout2exe doschk file
endif
+ifeq ($(host),i386-lynx)
+MAKE_HOLE := make
+endif
+
+ifeq ($(host),m68k-lynx)
+MAKE_HOLE := make
+endif
+
+ifeq ($(host),sparc-lynx)
+MAKE_HOLE := make
+endif
+
+ifeq ($(host),rs6000-lynx)
+MAKE_HOLE := make
+endif
+
### These things are also needed by a three-stage, but in this case, the GNU version of the tool is required.
PARTIAL_HOLES := \
$(MAKE_HOLE) \
/usr/progressive/bin \
$(PARTIAL_HOLE_DIRS) \
/usr/vintage/bin \
- /usr/unsupported/bin
+ /usr/unsupported/bin \
+ $(HOLE_DIRS)
$(HOLESDIR): $(holesys)-stamp-holes
$(host)-stamp-3stage-compared:
rm -f .bad-compare
-ifeq ($(patsubst %-lynxos,mips-sgi-irix4,$(subst i386-sco3.2v4,mips-sgi-irix4,$(subst rs6000-ibm-aix,mips-sgi-irix4,$(subst mips-dec-ultrix,mips-sgi-irix4,$(host))))),mips-sgi-irix4)
+ifeq ($(patsubst %-lynx,mips-sgi-irix4,$(subst i386-sco3.2v4,mips-sgi-irix4,$(subst rs6000-ibm-aix,mips-sgi-irix4,$(subst mips-dec-ultrix,mips-sgi-irix4,$(host))))),mips-sgi-irix4)
for i in `cd $(STAGE3DIR) ; find . -name \*.o -print` ; do \
tail +10c $(STAGE2DIR)/$$i > foo1 ; \
tail +10c $(STAGE3DIR)/$$i > foo2 ; \
$(host)-stamp-4stage-compared:
rm -f .bad-compare
-ifeq ($(patsubst %-lynxos,mips-sgi-irix4,$(subst i386-sco3.2v4,mips-sgi-irix4,$(subst rs6000-ibm-aix,mips-sgi-irix4,$(subst mips-dec-ultrix,mips-sgi-irix4,$(host))))),mips-sgi-irix4)
+ifeq ($(patsubst %-lynx,mips-sgi-irix4,$(subst i386-sco3.2v4,mips-sgi-irix4,$(subst rs6000-ibm-aix,mips-sgi-irix4,$(subst mips-dec-ultrix,mips-sgi-irix4,$(host))))),mips-sgi-irix4)
for i in `cd $(STAGE4DIR) ; find . -name \*.o -print` ; do \
tail +10c $(STAGE3DIR)/$$i > foo1 ; \
tail +10c $(STAGE4DIR)/$$i > foo2 ; \