But I wonder if there's a compiler switch (maybe -std=c++11) that would fix that for you.

Not that I can find.
Having upgraded the ImageMagick executable from release 19 to release 28, I hit the same issue.
To fix, I did a cd to the .cpan build directory and started by removing the failed cpan -fi Image::Magick attempt:
C:\> cd \Users\Owner\.cpan\build\Image-Magick-7.1.1-18 then C:\Users\Owner\.cpan\build\Image-Magick-7.1.1-18>gmake realclean then C:\Users\Owner\.cpan\build\Image-Magick-7.1.1-18>perl Makefile.PL CC=g +++ then C:\Users\Owner\.cpan\build\Image-Magick-7.1.1-18>gmake test then C:\Users\Owner\.cpan\build\Image-Magick-7.1.1-18>gmake install
That worked fine for me, though the single test still failed:
t/blob.t .......... ok t/composite.t ..... ok t/filter.t ........ Failed 1/58 subtests t/getattribute.t .. ok t/montage.t ....... ok t/ping.t .......... ok t/read.t .......... ok t/setattribute.t .. ok t/write.t ......... ok Test Summary Report ------------------- t/filter.t (Wstat: 0 Tests: 58 Failed: 1) Failed test: 2 Files=9, Tests=273, 1 wallclock secs ( 0.01 usr + 0.00 sys = 0.01 C +PU) Result: FAIL Failed 1/9 test programs. 1/273 subtests failed. gmake: *** [makefile:1048: test_dynamic] Error 255
Update: Looks like that one test fails for me because the font "Generic.ttf" can't be found:
Annotate(text=>'Magick',geometry=>'+0+20',font=>'Generic.ttf',fill=>'g +old',gravity=>'North',pointsize=>14) ... Annotate (text=>'Magick',geometry=>'+0+20',font=>'Generic.ttf',fill= +>'gold',gravity=>'North',pointsize=>14): Exception 305: unable to read font `Generic.ttf' @ warning/annotate. +c/RenderType/1024 not ok 2
Update 2: In the previous versions of Image::Magick that I've built, "Generic.tiff" has been provided in both the "demo" and the "t" folders - though the MANIFEST file listed only "demo/Generic.tiff"..
Now, however, "Generic.tiff" is to be found only in the "demo" folder.
Copying "demo/Generic.tiff" to "t/Generic.tiff" allows all tests to pass.

Cheers,
Rob

In reply to Re^4: Errors While Installing Image::Magick by syphilis
in thread Errors While Installing Image::Magick by roho

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.