[wx-dev] Supporting MacOS X frameworks

Anders F Björklund afb at algonet.se
Tue Jan 30 03:43:14 PST 2007


Etienne Samson wrote:

> I tried installing wxWidgets on my MacOS X, and I was a little  
> disapointed by the current "configure / make" way of doing things on  
> OS X.

The suggested approach is to use DarwinPorts, if you want it installed  
UNIX-style.
However, that's complicated by their move over to MacPorts and the  
broken ports...

http://trac.macports.org/projects/macports/ticket/10595
http://trac.macports.org/projects/macports/ticket/11234

I totally agree with the desire to have a Mac OS X native shared  
library packaging.
Suggested /Library/Frameworks/wx.framework, only for automatic  
<wx/wx.h> includes ?

My workaround for the Mac OS X 10.3 vs Mac OS X 10.4 issue was to use  
ANSI for Panther and UNICODE for Tiger, I'm sure it could be solved in  
another way (e.g. build two and lipo)

> I posted (http://wxforum.shadonet.com/viewtopic.php?t=12316) on the  
> forums a couple of days ago, asking about a possible Framework for  
> MacOS X, and I was directed to a thread in this mailing list  
> (http://thread.gmane.org/gmane.comp.lib.wxwidgets.devel/78464/ 
> focus=78464).

I summarized the details on what I had so far, at  
http://www.algonet.se/~afb/wx/

Note: I'm using the same "./configure && make" for the frameworks as  
the libraries,
the difference is in wx-config and in how the files are organized in  
the install.

My "latest idea" is linking to the usual library name, but inside of a  
framework:
@executable_path/../Frameworks/wx.framework/Versions/2.6.3/libwx_macu 
-2.6.0.dylib

In theory that should make it pick up bundled frameworks, user  
frameworks, local frameworks, system frameworks, local libraries,  
system libraries, Fink libraries, DarwinPorts libraries ?

> I've been trying to build my own (partially succeeding, see below),  
> and I wanted to know what was the status of this to know what is the  
> current trend on supporting OS X frameworks.

The current trend is to link wxWidgets statically, bundle the dylib  
files inside the app bundle, or just link to the Fink or MacPorts  
libraries. I don't think anyone (but me?) is using frameworks...

If one absolutely doesn't want frameworks, I guess there *could* be an  
installer PKG done that would install the includes and dylibs in /usr  
(like how Apple does it for their Tiger installation).

--anders





More information about the wx-dev mailing list