MacPorts : When you found out that a library you want to use was not built as you wanted.

Today I ran into a situation that I had to rebuild a library which was used in my project.
It was the GraphicsMagick. Because most consumer displays don’t support more than 8 bits per pixel, the project was configured to be built with 8 bits per pixel, i.e. –with-quantum-depth=8.

So, instead of obtaining source codes for yourself, how to tell Mac Ports to rebuild it with newer option?
It depends. If the port maintainers support such option for specific ports, you can.
To check what options (they call it variants) are available, try this :

port variants GraphicsMagick

It will display available options and option names like q8, q16.

Then to upgrade installed port ( GraphicsMagick 8 bit quantum depth ) by uninstalling q8 option and installing q16 option

sudo port -n upgrade –enforce-variants GraphicsMagick -q8 +q16

Leave a Reply

Please log in using one of these methods to post your comment:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: