Path: utzoo!utgpu!watmath!iuvax!cica!tut.cis.ohio-state.edu!G.OSWEGO.EDU!dl From: dl@G.OSWEGO.EDU (Doug Lea) Newsgroups: gnu.g++.bug Subject: installing g++.xtar Message-ID: <8910031152.AA13388@g.oswego.edu> Date: 3 Oct 89 11:52:57 GMT Reply-To: dl@oswego.oswego.edu Distribution: gnu Organization: GNUs Not Usenet Lines: 127 The installation instructions for g++.xtar (2 Oct 89 version on labrea) were less than complete. Here are some tentative answers to things that have come up in the past day or so. 0. Unlike it's advertised version number, this g++ is based on gcc-1.36, which should be used to compile g++, and as the $(DIR) (i.e., ../gcc) in the g++ Makefile. 1. You should `make' and install g++/gcc to replace gcc in your $(bindir). 2. You should `make' ld++, and install it as $(libdir)/gcc-ld This will cause ld++ to be used for C compiles as well, but that is OK. 3. Remember that you must *explicitly* link in -lg++ these days. You might want to make your life easier by installing the following little shellscript as $(bindir)/g++ #!/bin/sh gcc $* -lg++ Better might be to glance through the libg++ Makefile and/or the g++.texinfo file, and hard-wire into the g++ script some of the options you always need to use from those listed there. 4. g++ can put out .stabs that don't correspond to actual asm labels. On the sparc, at least, this gives /bin/as problems. You should use GNU as (gas), installed as $(bindir)/as and/or $(libdir)/gcc-as. I just placed the version of gas I've been successfully using (which includes a few additional sparc opcodes than the currently distributed version) as labrea.stanford.edu:pub/gnu/gas.xtar.Z 5. libg++/g++-include/setjmp.h has been giving people problems. The replacement below ought to fare better. 6. I don't know what is necessary for people who *need* to use `collect'. See Dirk Grunwald's note about setting things up for the PMAX at least. 7. Also below is a g++/expr.c patch needed to handle some uses of const functions that don't appear in anything released in libg++. 8. If any System 5 users encounter any problems at all with this libg++, please let me know! (directly or via bug-lib-g++). 9. Michael and I will be at OOPSLA the rest of the week. `Official' 1.36 releases of g++ and libg++ should be out `soon' thereafter. Thanks to everyone for helping to test things. -Doug ------------------- libg++/g++-include/setjmp.h #ifndef _setjmp_h #pragma once extern "C" { #define setjmp C_header_setjmp #define longjmp C_header_longjmp #include "/usr/include/setjmp.h" #undef setjmp #undef longjmp #ifndef _setjmp_h #define _setjmp_h 1 #endif extern int setjmp(jmp_buf); extern void longjmp(jmp_buf, int); } #endif ------------------------------- arkesden% diff -c2 expr.c~ expr.c *** expr.c~ Sun Sep 24 19:32:36 1989 --- expr.c Mon Oct 2 07:49:32 1989 *************** *** 4816,4834 **** rtx note = 0; ! /* Construct an "equal form" for the value ! which mentions all the arguments in order ! as well as the function name. */ ! for (i = 0; i < num_actuals; i++) ! if (args[i].reg != 0 || is_const) ! note = gen_rtx (EXPR_LIST, VOIDmode, args[i].value, note); ! note = gen_rtx (EXPR_LIST, VOIDmode, XEXP (DECL_RTL (fndecl), 0), note); ! REG_NOTES (insn_last) ! = gen_rtx (EXPR_LIST, REG_EQUAL, note, ! gen_rtx (INSN_LIST, REG_RETVAL, insn_first, ! REG_NOTES (insn_last))); ! REG_NOTES (insn_first) ! = gen_rtx (INSN_LIST, REG_LIBCALL, insn_last, ! REG_NOTES (insn_first)); } --- 4816,4838 ---- rtx note = 0; ! if (GET_CODE (insn_first) == INSN ! && GET_CODE (insn_last) == INSN) ! { ! /* Construct an "equal form" for the value ! which mentions all the arguments in order ! as well as the function name. */ ! for (i = 0; i < num_actuals; i++) ! if (args[i].reg != 0 || is_const) ! note = gen_rtx (EXPR_LIST, VOIDmode, args[i].value, note); ! note = gen_rtx (EXPR_LIST, VOIDmode, XEXP (DECL_RTL (fndecl), 0), note); ! REG_NOTES (insn_last) ! = gen_rtx (EXPR_LIST, REG_EQUAL, note, ! gen_rtx (INSN_LIST, REG_RETVAL, insn_first, ! REG_NOTES (insn_last))); ! REG_NOTES (insn_first) ! = gen_rtx (INSN_LIST, REG_LIBCALL, insn_last, ! REG_NOTES (insn_first)); ! } }