Adding configure options when installing a port

Ryan Schmidt ryandesign at macports.org
Wed Jun 16 14:09:22 PDT 2010


On Jun 16, 2010, at 15:28, Stephen Langer wrote:

> The problem is that the ImageMagick port is configured to use OpenMP, which is incompatible with posix threads.  Our program uses both threads and the Magick++ library, and crashes when it makes any ImageMagick call
> on a subthread.  ImageMagick can be configured with --disable-openmp, and then it works.

ImageMagick maintainer here. I admit I had not paid attention to the ticket. Here's the situation.

I received ticket #15945 requesting OpenMP be enabled in ImageMagick [1]. I did nothing because I did not know what OpenMP was, it was said to require a newer gcc than Leopard provided (Snow Leopard was not out) and thus required a MacPorts gcc port, and ImageMagick seemed to work fine without it.

Now I have the request in #24944 to disable OpenMP [2] presumably because on Snow Leopard the included gcc is new enough and it gets used automatically.

So what is OpenMP? It seems it is some kind of multiprocessing library that allows some ImageMagick operations to be faster on multi-processor/multi-core systems. That sounds good, but in #15945 it is implied that no benefit is achieved unless the user sets the OMP_NUM_THREADS environment variable to something useful. Is that still the case or have they now automated that?

I think I'm inclined to modify the ImageMagick port to disable openmp in the global configure args, and to provide an openmp variant like in #15945 except I would use the Snow Leopard gcc. I might either dispense entirely with the part that uses MacPorts gcc (thus making this variant require Snow Leopard or newer), or I might retain it for older Mac OS.

What are your opinions?


[1] http://trac.macports.org/ticket/15945

[2] http://trac.macports.org/ticket/24944



More information about the macports-users mailing list