openexr-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Openexr-devel] notes: OpenEXR-1.0.6 + OSX + ProjectBuilder


From: Scott Frankel
Subject: Re: [Openexr-devel] notes: OpenEXR-1.0.6 + OSX + ProjectBuilder
Date: Mon, 20 Oct 2003 10:35:12 -0700


Thanks for the suggestions!  I'll give'em a go.

Scott


On Monday, October 20, 2003, at 10:25 AM, Paul Schneider wrote:


    - API header hacks: disable win32 compatibility
      Comment-out the win32 compatibility term, "restrict," from
      ImathMatrix.h; i.e.:
      [near line 2356]

You could also do what the OS X Makefile does, and add -Drestrict= to your compiler settings. I don't actually know what the "restrict" keyword does, but I think it's not a Win32 thing, since it's also #ifdef'd out on that platform.


    - example program header hacks: explicit casts to float
      <no matching function for call to 'max(float, double)'>
      Explicitly cast 2nd arg to float in drawImage.cpp:
     [line 92]

I don't think you need to do this if you have PLATFORM_DARWIN_PPC defined, since that will find the copies of floor in the Imath namespace that return doubles. You can verify this by building IlmImfExamples from the command line - no source modification necessary.


For ProjectBuilder

- In a shell window, make a symbolic link to /usr/ in the project's
      working directory.  The MacOSX file Open|Save browser can't find
BSD-specific directories. The symlink lets you navigate to /usr/lib and /usr/local/OpenEXR from the cwd to import headers and lib files.

          % ln -s /usr/ yoozer

You can get there in the Open/Save dialog if you type the path in the "location" field - i.e. type "/usr/lib" in the "Go To:" edit field. Note that this feature might not be there in future versions of the OS, though, but such a hypothetical OS will probably let you see invisible directories such as /usr in the file dialog.


- To prevent ImathMath.h float variable errors, this string must be added to the Target's GCC Compiler Settings tab's "Other C Compiler Flags"
      field.  Note that the "-" is significant.

          -DPLATFORM_DARWIN_PPC

Change this to -DPLATFORM_DARWIN_PPC -Drestrict= as mentioned above, and a lot of problems go away. It's best to follow the Makefile's example in situations like this.


Good work, Scott! Thanks for braving these uncharted waters. I'll try to improve the Xcode support for OpenEXR in the coming weeks.

- Paul






reply via email to

[Prev in Thread] Current Thread [Next in Thread]