A few weeks ago I updated my MacBook Pro to OS X 10.6.5 from scratch, however it took me a while before getting everything back in place. I updated Xcode to the latest version and didn’t have any trouble until some days ago when I wanted to install ImageMagick via macports. The error I was getting was something like an error while trying to install db46. It took me quite a while, surfing through the web and reading a bunch of crap, before I came to a solution. There it is,
First go to:
You have to change the permission on the file “makefile” for the admin to be able to read and write. You can do this in the finder, right-click->get info ->enable the lock ->change privilege to “read and write”
Then open the Makefile with the texteditor and modify the following line:
CPPFLAGS= -I$(builddir) -I$(srcdir) -I/opt/local/include
CPPFLAGS= -I$(builddir) -I$(srcdir) -I/opt/local/include -I/System/Library/Frameworks/JavaVM.framework/Headers
Save the file and try again sudo port install db46, it should work flawlessly.