From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 9921 invoked by alias); 12 Mar 2004 18:00:54 -0000 Mailing-List: contact gcc-help-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Archive: List-Post: List-Help: Sender: gcc-help-owner@gcc.gnu.org Received: (qmail 9894 invoked from network); 12 Mar 2004 18:00:52 -0000 Received: from unknown (HELO amer-mta01.csc.com) (20.137.2.247) by sources.redhat.com with SMTP; 12 Mar 2004 18:00:52 -0000 Received: from csc.com (va-fch32.csc.com [20.6.39.233]) by amer-mta01.csc.com (Switch-3.1.2/Switch-3.1.0) with ESMTP id i2CI3XZB027537 for ; Fri, 12 Mar 2004 13:03:34 -0500 (EST) Subject: Undefined symbol error when linking with g++. To: gcc-help@gcc.gnu.org Message-ID: From: Kenneth R Leach Date: Fri, 12 Mar 2004 18:58:00 -0000 MIME-Version: 1.0 Content-type: text/plain; charset=US-ASCII X-SW-Source: 2004-03/txt/msg00127.txt.bz2 We recently upgraded our GNU GCC compiler from 2.95.2 to 3.2.3. When attempting to compile one of our system libraries, the following error is reported. Undefined symbol _XmStrings21 first reference in file window_lib.a(color_util.o) ld: fatal: Symbol referencing errors. No output written to demo collect2: ld returned 1 exit status However, this library builds fine with our 2.95.2 version. The differences are that the 2.95.2 compiler was prebuilt for our OS and the 3.2.3, we built. Plus the binutils are part of the 2.95.2 version, where as we built ours and installed them in a separate directory. In the makefile, the linker is called by the $(LINK) macro, which is evaluating to g++. I performed a test and found that if I replace the $(LINK) macro with "ld", which is the binutils "ld", the library compiles. Any ideas why the new GCC is having a problem, where the old one did not? Any assistance would be greatly appreciated. Thanks. ---------------------------------------------------------------------------------------- This is a PRIVATE message. If you are not the intended recipient, please delete without copying and kindly advise us by e-mail of the mistake in delivery. NOTE: Regardless of content, this e-mail shall not operate to bind CSC to any order or other contract unless pursuant to explicit written agreement or government initiative expressly permitting the use of e-mail for such purpose. ----------------------------------------------------------------------------------------