• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: What should be a simple linking problem
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: What should be a simple linking problem


  • Subject: Re: What should be a simple linking problem
  • From: "Richard L. Aurbach" <email@hidden>
  • Date: Thu, 9 Apr 2009 15:18:57 -0500

I did, indeed, include the header file in the compilation of SSCE_TempLexName.cpp and the result was an unmangled name. Indeed, using nm, I see that the name is "_SSCE_TempLexName".

Unfortunately, it appears that the C-language library is looking for "SSCE_TempLexName" (i.e., without the leading '_'). So there IS an incompatibility between the C-language library and the object file from my C++ project.

How do I combat this problem? Have I built the libSCCE.a file incorrectly?? I have sources and can make changes if appropriate, but I don't know what changes to make.


I'm having a problem with an undefined symbol during linking which has me perplexed.

My application uses an external C-language library (built as a static library with a .a extension [ libSCCE.a ]). The library calls an external function SCCE_TempLexName(char*) which it expects the host application to provide.

My (host) application implements this function as follows:

in SSCE_TempLexName.h :
#if defined(__cplusplus)
extern "C" {
#endif

void	SSCE_TempLexName (
			char * 			outPath );

#if defined(__cplusplus)
}
#endif

in SSCE_TempLexName.cpp:

Cheers,

Rick Aurbach



_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


  • Follow-Ups:
    • Re: What should be a simple linking problem
      • From: "Richard L. Aurbach" <email@hidden>
References: 
 >What should be a simple linking problem (From: "Richard L. Aurbach" <email@hidden>)
 >Re: What should be a simple linking problem (From: Tommy Nordgren <email@hidden>)

  • Prev by Date: Re: What should be a simple linking problem
  • Next by Date: Re: Which installer?
  • Previous by thread: Re: What should be a simple linking problem
  • Next by thread: Re: What should be a simple linking problem
  • Index(es):
    • Date
    • Thread