From: CRDGW2::CRDGW2::MRGATE::"SMTP::PREP.AI.MIT.EDU::HELP-GCC-REQUEST" 24-FEB-1992 06:16:11.68 To: ARISIA::EVERHART CC: Subj: shared libraries and gcc2 From: help-gcc-request@prep.ai.mit.edu@SMTP@CRDGW2 To: Everhart@Arisia@MRGATE Received: by crdgw1.ge.com (5.57/GE 1.123) id AA02630; Mon, 24 Feb 92 05:28:22 EST Received: by life.ai.mit.edu (4.1/AI-4.10) id AA08715; Sun, 23 Feb 92 23:33:45 EST Return-Path: Received: from frob.eng.umd.edu by life.ai.mit.edu (4.1/AI-4.10) id AA08709; Sun, 23 Feb 92 23:33:23 EST Received: by frob.eng.umd.edu (5.65c/IDA-1.4.4) id AA11966; Sun, 23 Feb 1992 23:33:19 -0500 mailed to help-gcc@prep.ai.mit.edu Date: Sun, 23 Feb 1992 23:33:19 -0500 From: "David J. MacKenzie" Message-Id: <199202240433.AA11966@frob.eng.umd.edu> To: help-gcc@prep.ai.mit.edu Subject: shared libraries and gcc2 On our Suns, I have gcc1 set up to use Sun's ld so it can produce dynamically linked executables. By editing gcc.c, I set up g++1 to use "ld++" (the name under which I installed the GNU ld) since Sun's ld can't handle C++. For gcc2, the best way I can think of to get the same effect is to make g++ a shell script along the lines of: exec gcc -B "$@" so that it gets the GNU "ld" instead of Sun's /bin/ld, but gcc invoked normally still gets Sun's ld. Can anyone think of a cleaner way? Also, how does gcc2 determine in which directory to look for C++ header files? The file INSTALL doesn't mention, except for VMS.