πŸš€ go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: alt.comp.lang.learn.c-c++
Article #641

Re: Link error CW8 mac compile for windows

#641
From: Guy Harrison
Date: Thu, 12 Jun 2003 14:12
52 lines
3648 bytes
Alexander Cohen wrote:

> Hi, im compiling an application for windows from codewarrior 8 mac.
> All compiles fine but at the end I get 6 link errors wich I donοΏ½t
> understand since the libraries needed are there in my project. The
> project has c and c++ files and I am compiling as C++. The parts that
> need to be compiled as C are bracketed with extern "C" and have .c
> extensions. Here are the errors:

Without info stating explicitly to the contrary, the parts that need to
be compiled as C ought to be compiled by a C compiler (hint: macro
__cplusplus and/or other vendor specific definitions).
 
> Link Error   : Undefined symbol: 'double fabs(double) (?fabs@@YANN@Z)'
> referenced from '_MAT3inverse' in cmsmtrx.c
> referenced from 'double Convert15Fixed16(long)
> (?Convert15Fixed16@@YANJ@Z)' in cmsio1.c
> referenced from '_MAT3inverse' in cmsmtrx.c
> 
> Link Error   : Undefined symbol: 'double floor(double)
> (?floor@@YANN@Z)' referenced from '_cmsBuildParametricGamma' in
> cmsgamma.c referenced from '__cmsQuantizeVal' in cmssamp.c
> referenced from '_cmsBuildGamma' in cmsgamma.c
> 
> Link Error   : Undefined symbol: 'double pow(double, double)
> (?pow@@YANNN@Z)'
> referenced from '_cmsBuildParametricGamma' in cmsgamma.c
> referenced from '_cmsBuildParametricGamma' in cmsgamma.c
> referenced from '_cmsBuildParametricGamma' in cmsgamma.c
> referenced from '_cmsBuildParametricGamma' in cmsgamma.c
> referenced from '_cmsBuildParametricGamma' in cmsgamma.c
> referenced from '_cmsBuildParametricGamma' in cmsgamma.c
> referenced from '_cmsBuildParametricGamma' in cmsgamma.c
> referenced from '_cmsBuildParametricGamma' in cmsgamma.c
> ...
> 
> I have a feeling that I have a name mangling problem but im really not
> sure how to fix it.

If the parenthesised text represents mangled names on your compiler then
yes.

> Any help is greatly appreciated.

<gut feeling>
Change the parts responsible for invoking the compiler upon *.c files
such that said files get a C compilation.
</gut feeling>


-- 
Guy Harrison
Technical Details
Message-ID: <8hlmr-9403.ln1@sd.swampdog>
Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!newsfeed.stanford.edu!news-spur1.maxwell.syr.edu!news.maxwell.syr.edu!newsfeed.icl.net!newsfeed.fjserv.net!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newspeer1-gui.server.ntli.net!ntli.net!newsfep4-glfd.server.ntli.net.POSTED!53ab2750!not-for-mail
References: <BB0CC289.E8%alex@toomuchspace.com>

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII
X-Google-Thread: 10bcce,8730a56750ded940
X-Google-Attributes: gid10bcce,public
X-Google-Thread: 1014db,8730a56750ded940
X-Google-Attributes: gid1014db,public
X-Google-Thread: fd047,8730a56750ded940
X-Google-Attributes: gidfd047,public
X-Google-Thread: 114592,8730a56750ded940
X-Google-Attributes: gid114592,public
X-Google-Thread: 109fba,8730a56750ded940
X-Google-Attributes: gid109fba,public
X-Google-ArrivalTime: 2003-06-12 09:20:05 PST
Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!newsfeed.stanford.edu!news-spur1.maxwell.syr.edu!news.maxwell.syr.edu!newsfeed.icl.net!newsfeed.fjserv.net!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!newspeer1-gui.server.ntli.net!ntli.net!newsfep4-glfd.server.ntli.net.POSTED!53ab2750!not-for-mail
Message-ID: <8hlmr-9403.ln1@sd.swampdog>
From: Guy Harrison <swamp-DEL-dog@ntlworld.com>
Subject: Re: Link error CW8 mac compile for windows
Newsgroups: alt.comp.lang.learn.c-c++,codewarrior.mac,codewarrior.windows,comp.lang.c,comp.lang.c++
Followup-To: alt.comp.lang.learn.c-c++
References: <BB0CC289.E8%alex@toomuchspace.com>
Lines: 52
User-Agent: KNode/0.7.6
MIME-Version: 1.0
Content-Type: text/plain; charset=iso-8859-1
Content-Transfer-Encoding: 8Bit
Date: Thu, 12 Jun 2003 15:12:56 +0100
NNTP-Posting-Host: 80.4.128.98
X-Complaints-To: abuse@ntlworld.com
X-Trace: newsfep4-glfd.server.ntli.net 1055434805 80.4.128.98 (Thu, 12 Jun 2003 17:20:05 BST)
NNTP-Posting-Date: Thu, 12 Jun 2003 17:20:05 BST
Organization: ntlworld News Service