Opened 14 years ago
Last modified 7 years ago
#27528 reopened defect
ImageMagick: expected '#pragma omp' clause before 'omp_throttle'
Reported by: | michael.himmelsbach@… | Owned by: | ryandesign (Ryan Carsten Schmidt) |
---|---|---|---|
Priority: | Normal | Milestone: | |
Component: | ports | Version: | 1.9.2 |
Keywords: | Cc: | neverpanic (Clemens Lang), luis.beca@… | |
Port: | ImageMagick |
Description
ImageMagick fails to compile with an error in magic/composite.c:2757 on Snow Leopard 10.6.5 using Apples GCC 4.2.1: "error: expected '#pragma omp' clause before 'omp_throttle'". Please see attached log.
Attachments (2)
Change History (18)
Changed 14 years ago by michael.himmelsbach@…
Attachment: | im-err.log added |
---|
comment:1 Changed 14 years ago by jmroot (Joshua Root)
Keywords: | Compile error removed |
---|---|
Owner: | changed from macports-tickets@… to ryandesign@… |
Port: | ImageMagick added; Image Magick removed |
Please remember to cc the maintainer.
comment:2 Changed 14 years ago by ryandesign (Ryan Carsten Schmidt)
Summary: | ImageMagick fails to build on 10.6.5 → ImageMagick: expected '#pragma omp' clause before 'omp_throttle' |
---|
Hmm, it builds fine for me on Snow Leopard. "omp" here refers to OpenMP but I'm not sure what to do with this.
comment:3 Changed 14 years ago by ryandesign (Ryan Carsten Schmidt)
If you attach your config.log I could compare it with mine, see what's different.
comment:4 Changed 14 years ago by michael.himmelsbach@…
I did not find a config.log, but in my macports.conf I found that I had recently enabled the use of ccache (ie, it contained "configureccache yes"). Setting "configureccache no" and doing a "port clean/configure/build/install imagemagick" then worked for me. I am up to date now, which also means that I will never use ccache again. Or is this a MacPorts-only ccache problem?
Changed 14 years ago by neverpanic (Clemens Lang)
Attachment: | config.log added |
---|
comment:6 Changed 14 years ago by michael.himmelsbach@…
neverpanic, have you tried disabling ccache for MacPorts? This worked for me, and as I can see from your config.log in line 12929 (CC= ccache /usr/bin/gcc-4.2 -std=gnu99 -std=gnu99), you also have ccache enabled for building ImageMagick.
comment:7 Changed 14 years ago by neverpanic (Clemens Lang)
Yes I have and it did work, but maybe we can still get to the bottom of this or at least add a message that building ImageMagick with ccache will fail.
comment:8 follow-up: 9 Changed 14 years ago by michael.himmelsbach@…
Just a note: Building ImageMagick with ccache will probably only fail if another version of it was build with ccache before. If I find some time I will clear my ccache cache and see if it works then.
comment:9 Changed 14 years ago by nstanger (Nigel Stanger)
Same problem here too. "sudo ccache -C" followed by "port clean/upgrade imagemagick" failed with the same error. Disabling ccache completely followed by "port clean/upgrade imagemagick" worked fine.
comment:10 Changed 14 years ago by ryandesign (Ryan Carsten Schmidt)
Hmm. I had never used ccache before, but I've now installed it and configured MacPorts to use it, and ImageMagick still built fine for me.
comment:12 Changed 14 years ago by raimue (Rainer Müller)
First it failed in the same way for me as described above. It looks like the omp_throttle(1)
macro was not pre-processed and was not expanded. Therefore the compiler chokes on the unknown directive.
But it works now with a clean ccache. My guess is that ccache was unable to detect changes for whatever reason and used old pre-processed input (old headers?) from the cache.
comment:13 Changed 14 years ago by ryandesign (Ryan Carsten Schmidt)
Cc: | luis.beca@… added |
---|---|
Status: | new → assigned |
Has duplicate #27873. I guess I should disable ccache for ImageMagick.
comment:14 Changed 14 years ago by ryandesign (Ryan Carsten Schmidt)
Resolution: | → fixed |
---|---|
Status: | assigned → closed |
comment:15 Changed 13 years ago by dhruvahuja@…
Resolution: | fixed |
---|---|
Status: | closed → reopened |
Replying to michael.himmelsbach@…:
ImageMagick fails to compile with an error in magic/composite.c:2757 on Snow Leopard 10.6.5 using Apples GCC 4.2.1: "error: expected '#pragma omp' clause before 'omp_throttle'". Please see attached log.
Setting the CCACHE_CPP2 environment variable changes the preprocessing behaviour making it compatible with ImageMagick. Not all ccache performance is lost. More information on usage at: http://workin.gs/compiling-imagemagick-ccache and on the explanation of the behaviour at: http://ccache.samba.org/manual.html#_environment_variables . I tested this on SLES 11.1 x86_64 , though.
comment:16 Changed 7 years ago by raimue (Rainer Müller)
Cc: | raimue removed |
---|
MacPorts error log for "port upgrade imagemagick"