[Qgis-developer] Mac OSX - Clean machine setup issues

William Kyngesburye woklist at kyngchaos.com
Sat Feb 3 12:03:25 EST 2007


On Feb 3, 2007, at 4:03 AM, Tim Sutton wrote:

> The notes document what I have done so far. Now when I run cmake .. I
> get the following:
>
> tims-computer:~/dev/cpp/qgis/build tim$ cmake ..
> -- Found Proj: /Library/Frameworks/proj.framework
> -- Found Sqlite3: /Library/Frameworks/sqlite3.framework
> -- Found GEOS: /Library/Frameworks/geos.framework

Is that cmake changing those to lowercase, or is it the way you  
configured it?  It doesn't really matter on OSX with a normal HFS+  
file system, but it would if someone was foolish enough to try using  
a HFS+ case sensitive file system, or UFS.

> So my questions are:
>
> 1) What was the trick for getting cmake to find gdal properly?

I've been afraid to dive into this new cmake thing, so I don't know  
how to configure it.  The GDAL framework 'unix' style path is / 
Library/Frameworks/GDAL.framework/unix, so gdal-config is /Library/ 
Frameworks/GDAL.framework/unix/bin/gdal-config.

I tried to make gdal-config as unix-friendly, like the original, as  
possible, but there is one -framework flag in the --dep-libs for  
SQLite3 (I did that so it wouldn't accidentally pick up the system's  
sqlite).  If the new cmake configure uses dep-libs to test link GDAL  
(it probably shouldn't), and can't handle -framework flags, it could  
fail to find GDAL.

I've been considering making a second, purely OSX-savvy, gdal- 
config.  It would return all framework flags where available for  
dependencies and linking.

> 2) Do you know if GSL is available as a framework?

I haven't made one.  It's one of those one-off things - only Qgis  
uses it in all the software I package and/or use - so I just bundle a  
dylib with Qgis.

> 3) If I install your (Williams) Grass installler without X will cmake
> pick it up and will Grass work properly in QGIS?

That should work fine - the only direct X11 dependencies in GRASS are  
the XDRIVER and the bundled TclTk, and Qgis doesn't use GRASS display  
drivers.  Only NVIZ will not work without X11, as that uses the TclTk  
libraries directly.

> 4) Whats the neatest way to get SIP support?
>
New to Qgis?  I don't think I've heard of it.

> My goal is for everything to be done with maximum ease for potential
> new developers of QGIS on mac, avoiding building dependencies from
> source and leaving minimum clutter / duplication of libs on the
> system. Ie it should look nothing like my last development environment
> looked :-p

Ah, the eternal quest to organize one's Mac ^_^


A question on cmake - how well does it handle universal flags?  That  
is, how easy is it to add the flags the the right compile and link  
commands?  (ie GCC complains if there are multiple -isysroot flags,  
which could easily happen if CFLAGS and LDFLAGS were included in  
linking.  Then, depending on the libtool version, you had to do weird  
prefixing so it wouldn't drop those flags.)

Or are you adding a builtin universal build option to Qgis?

I don't know if you've seen this trick, but I use this now to get  
universal builds (besides making Xcode projects):

http://www.macosxhints.com/article.php?story=20061025213851279

No need to mess with CFLAGS/LDFLAGS or hacking makefiles.  You can  
customize the source to leave out the -isysroot flag if you are on  
Intel, where it's not needed.

-----
William Kyngesburye <kyngchaos at kyngchaos.com>
http://www.kyngchaos.com/

"This is a question about the past, is it? ... How can I tell that  
the past isn't a fiction designed to account for the discrepancy  
between my immediate physical sensations and my state of mind?"

- The Ruler of the Universe





More information about the Qgis-developer mailing list