[MacPorts] #40692: p5.12-perlmagick fails to build on 10.5/ppc (-fopenmp)
#40692: p5.12-perlmagick fails to build on 10.5/ppc (-fopenmp) ---------------------+--------------------------- Reporter: dluke@… | Owner: astricker@… Type: defect | Status: new Priority: Normal | Milestone: Component: ports | Version: 2.2.0 Keywords: | Port: p5-perlmagick ---------------------+--------------------------- With #40447 fixed, I upgraded ImageMagick on my 10.5/ppc system, but p5.12-perlmagick failed to build with: {{{ :info:build cc1: error: unrecognized command line option "-fopenmp" }}} As a quick hack, I edited the Main.PL files in /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_ports_perl_p5-perlmagick/p5.12-perlmagick/work/ImageMagick-6.8.7-0/PerlMagick that had -fopenmp and removed it (which allowed the build to succeed). I'll attach my main.log for reference. -- Ticket URL: <https://trac.macports.org/ticket/40692> MacPorts <http://www.macports.org/> Ports system for OS X
#40692: p5.12-perlmagick fails to build on 10.5/ppc (-fopenmp) ----------------------------+------------------------- Reporter: dluke@… | Owner: astricker@… Type: defect | Status: new Priority: Normal | Milestone: Component: ports | Version: 2.2.0 Resolution: | Keywords: Port: p5-perlmagick | ----------------------------+------------------------- Comment (by astricker@…): Obviously your 10.5 ppc system doesn't support OpenMP. It should be deactivated by adding {{{configure.args-append --disable-openmp}}} in configure phase. But this should only be applied to ppc architecture. I've found the following solution: {{{ --- a/graphics/ImageMagick/Portfile +++ b/graphics/ImageMagick/Portfile @@ -112,6 +112,10 @@ test.run yes test.target check test.env DYLD_LIBRARY_PATH=${worksrcpath}/magick/.libs +platform darwin ppc { + configure.args-append --disable-openmp +} + variant graphviz description {Support Graphviz} { depends_lib-append path:bin/dot:graphviz configure.args-delete --without-gvc }}} Can you apply this to your Portfile and check if it works? -- Ticket URL: <https://trac.macports.org/ticket/40692#comment:1> MacPorts <http://www.macports.org/> Ports system for OS X
#40692: p5.12-perlmagick fails to build on 10.5/ppc (-fopenmp) ----------------------------+------------------------- Reporter: dluke@… | Owner: astricker@… Type: defect | Status: new Priority: Normal | Milestone: Component: ports | Version: 2.2.0 Resolution: | Keywords: Port: p5-perlmagick | ----------------------------+------------------------- Comment (by dluke@…): I can try it, but FYI - ImageMagick installs fine, it's p5.12-perlmagic that has -fopenmp and fails to install. -- Ticket URL: <https://trac.macports.org/ticket/40692#comment:2> MacPorts <http://www.macports.org/> Ports system for OS X
#40692: p5.12-perlmagick fails to build on 10.5/ppc (-fopenmp) ----------------------------+------------------------- Reporter: dluke@… | Owner: astricker@… Type: defect | Status: new Priority: Normal | Milestone: Component: ports | Version: 2.2.0 Resolution: | Keywords: Port: p5-perlmagick | ----------------------------+------------------------- Comment (by astricker@…): Woops, my fault. Of course it's not the ImageMagick Port but the p5-perlmagick port. But as they build from the same source it looks similar: {{{ --- a/perl/p5-perlmagick/Portfile +++ b/perl/p5-perlmagick/Portfile @@ -33,6 +33,10 @@ distname ${my_name}-${version} checksums rmd160 90032fae2b82155e80daed94f6556fc7de566845 \ sha256 2b9c4097c727a25ffe1523d8158feea2d50517061e047f1ccbd8a11d531e132e +platform darwin ppc { + configure.args-append --disable-openmp +} + if {${perl5.major} != ""} { depends_lib-append port:ImageMagick }}} Can you try this and ignore the first post from tomorrow when it really was too early in the morning? -- Ticket URL: <https://trac.macports.org/ticket/40692#comment:3> MacPorts <http://www.macports.org/> Ports system for OS X
#40692: p5.12-perlmagick fails to build on 10.5/ppc (-fopenmp) ----------------------------+------------------------- Reporter: dluke@… | Owner: astricker@… Type: defect | Status: new Priority: Normal | Milestone: Component: ports | Version: 2.2.0 Resolution: | Keywords: Port: p5-perlmagick | ----------------------------+------------------------- Comment (by ryandesign@…): The correct wording would be `platform darwin powerpc`. However we may need to instead check build_arch or universal_archs. Note that we have several other tickets open about ImageMagick requesting that OpenMP be either enabled or disabled. Currently ImageMagick decides for itself when OpenMP should be used, and it varies at least by compiler and possibly OS version. -- Ticket URL: <https://trac.macports.org/ticket/40692#comment:4> MacPorts <http://www.macports.org/> Ports system for OS X
#40692: p5.12-perlmagick fails to build on 10.5/ppc (-fopenmp) ----------------------------+------------------------- Reporter: dluke@… | Owner: astricker@… Type: defect | Status: new Priority: Normal | Milestone: Component: ports | Version: 2.2.0 Resolution: | Keywords: Port: p5-perlmagick | ----------------------------+------------------------- Comment (by astricker@…): The we may introduce an user variant to enable openmp and keep it disabled by default? -- Ticket URL: <https://trac.macports.org/ticket/40692#comment:5> MacPorts <http://www.macports.org/> Ports system for OS X
#40692: p5.12-perlmagick fails to build on 10.5/ppc (-fopenmp) ----------------------------+------------------------- Reporter: dluke@… | Owner: astricker@… Type: defect | Status: new Priority: Normal | Milestone: Component: ports | Version: 2.2.0 Resolution: | Keywords: Port: p5-perlmagick | ----------------------------+------------------------- Comment (by ryandesign@…): I'm not sure yet whether I'll want it on or off by default. But yes, I think making the ImageMagick portfile control openmp is a good idea. See the other tickets. As for p5-perlmagick, I'm surprised it cares or needs to know. Can't I just always tell p5-perlmagick to disable openmp? Would that be a problem? -- Ticket URL: <https://trac.macports.org/ticket/40692#comment:6> MacPorts <http://www.macports.org/> Ports system for OS X
#40692: p5.12-perlmagick fails to build on 10.5/ppc (-fopenmp) ----------------------------+------------------------- Reporter: dluke@… | Owner: astricker@… Type: defect | Status: new Priority: Normal | Milestone: Component: ports | Version: 2.2.0 Resolution: | Keywords: Port: p5-perlmagick | ----------------------------+------------------------- Comment (by astricker@…): I don't see either why p5-perlmagick needs openmp. So I guess disabling it always is the best solution. -- Ticket URL: <https://trac.macports.org/ticket/40692#comment:7> MacPorts <http://www.macports.org/> Ports system for OS X
#40692: p5.12-perlmagick fails to build on 10.5/ppc (-fopenmp) ----------------------------+------------------------- Reporter: dluke@… | Owner: astricker@… Type: defect | Status: closed Priority: Normal | Milestone: Component: ports | Version: 2.2.0 Resolution: fixed | Keywords: Port: p5-perlmagick | ----------------------------+------------------------- Changes (by ryandesign@…): * status: new => closed * resolution: => fixed Comment: Ok, let's try that. r111988 -- Ticket URL: <https://trac.macports.org/ticket/40692#comment:8> MacPorts <http://www.macports.org/> Ports system for OS X
#40692: p5.12-perlmagick fails to build on 10.5/ppc (-fopenmp) ----------------------------+------------------------- Reporter: dluke@… | Owner: astricker@… Type: defect | Status: closed Priority: Normal | Milestone: Component: ports | Version: 2.2.0 Resolution: fixed | Keywords: Port: p5-perlmagick | ----------------------------+------------------------- Comment (by dluke@…): I can confirm that this fixes it on m 10.5/ppc machine. -- Ticket URL: <https://trac.macports.org/ticket/40692#comment:9> MacPorts <http://www.macports.org/> Ports system for OS X
participants (1)
-
MacPorts