• 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: Question about symbol visibility link warning
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Question about symbol visibility link warning


  • Subject: Re: Question about symbol visibility link warning
  • From: John Mikros <email@hidden>
  • Date: Thu, 19 Feb 2009 14:00:32 -0800

It means that you are compiling your project with the GCC flag - fvisibility=hidden, (Symbols Hidden by Default in Xcode), but the static library was not.

This will usually happen when there are inlined functions in headers that are shared by your project and the static library.

I've found it best to leave that build setting as default (ie, off), otherwise you'll have tons of problems with 3rd party libraries.

-john

On Feb 19, 2009, at 10:29 AM, Brant Sears wrote:

I'm seeing the same link warning about symbol visibility many times when my project links to a static library for wxWidgets version 2.8 that was built with XCode.

ld warning: wxDCBase::DrawBitmap(wxBitmap const&, int, int, bool)has different visibility (default) in /Users/brant/src/projects/initial/ src/mac/lib/libwx_mac_static.a(renderg.o) and (hidden) in /Users/ brant/src/projects/initial/src/mac/build/initial.build/Development/ static.build/Objects-normal/i386/BackgroundPanel.o

I do not completely understand this warning. My project is trying to import a symbol as "hidden"? And the static library has it as "default".

I read something on the GCC wiki about this symbol visibility stuff being for the purpose of making applications load dlls faster - and some other benefits.

Can an application load a "hidden" symbol? What exactly does hidden mean?

And how can I fix these warnings properly? I checking the box "Symbols Hidden by Default" in the XCode project to build the wxWidgets static library, recompiled the project, and double checked to make sure I was linking against that version. This did not have an effect on the behavior when compiling my application.

I would appreciate any advice.
_______________________________________________
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

_______________________________________________ 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
References: 
 >Question about symbol visibility link warning (From: Brant Sears <email@hidden>)

  • Prev by Date: parse error before "__AVAILABILITY_INTERNAL__MAC_10_5"
  • Next by Date: Re: Shark not profiling correctly on command-line tool
  • Previous by thread: Question about symbol visibility link warning
  • Next by thread: Shark not profiling correctly on command-line tool
  • Index(es):
    • Date
    • Thread