Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Tests] wandtest and some demos are failing #782

Closed
3 tasks done
mooninite opened this issue Sep 26, 2017 · 12 comments
Closed
3 tasks done

[Tests] wandtest and some demos are failing #782

mooninite opened this issue Sep 26, 2017 · 12 comments

Comments

@mooninite
Copy link

Prerequisites

  • I have written a descriptive issue title
  • I have verified that I am using the latest version of ImageMagick
  • I have searched open and closed issues to ensure it has not already been reported

Description

The wandtest and demos 2, 3, 5, 6, and 7 are failing on Fedora.

Steps to Reproduce

test-suite.log

System Configuration

  • ImageMagick version: 6.9.9-15
  • Environment (Operating system, version and so on): Fedora Rawhide (Fedora 28)
  • Additional information:
@mikayla-grace
Copy link

mikayla-grace commented Sep 26, 2017

Do you have Ghostscript installed? We ran the ImageMagick 6.9.9-15 unit tests on Fedora 26 and they completed without complaint:

make[3]: Entering directory '/home/mikayla/ImageMagick-6.9.9-15'
PASS: tests/cli-pipe.tap 1
PASS: tests/cli-pipe.tap 2
PASS: tests/cli-pipe.tap 3
PASS: tests/cli-pipe.tap 4
PASS: tests/cli-pipe.tap 5
PASS: tests/cli-pipe.tap 6
PASS: tests/cli-pipe.tap 7
PASS: tests/cli-pipe.tap 8
PASS: tests/cli-colorspace.tap 1
PASS: tests/cli-colorspace.tap 2
PASS: tests/cli-colorspace.tap 3
PASS: tests/cli-colorspace.tap 4
PASS: tests/cli-colorspace.tap 5
PASS: tests/cli-colorspace.tap 6
PASS: tests/cli-colorspace.tap 7
PASS: tests/cli-colorspace.tap 8
PASS: tests/cli-colorspace.tap 9
PASS: tests/cli-colorspace.tap 10
PASS: tests/cli-colorspace.tap 11
PASS: tests/cli-colorspace.tap 12
PASS: tests/cli-colorspace.tap 13
PASS: tests/cli-colorspace.tap 14
PASS: tests/cli-colorspace.tap 15
PASS: tests/cli-colorspace.tap 16
PASS: tests/cli-colorspace.tap 17
PASS: tests/cli-colorspace.tap 18
PASS: tests/cli-colorspace.tap 19
PASS: tests/validate-colorspace.tap 1
PASS: tests/validate-compare.tap 1
PASS: tests/validate-composite.tap 1
PASS: tests/validate-convert.tap 1
PASS: tests/validate-formats-disk.tap 1
PASS: tests/validate-formats-map.tap 1
PASS: tests/validate-formats-memory.tap 1
PASS: tests/validate-identify.tap 1
PASS: tests/validate-import.tap 1
PASS: tests/validate-montage.tap 1
PASS: tests/validate-stream.tap 1
PASS: tests/drawtest.tap 1
PASS: tests/wandtest.tap 1
PASS: Magick++/tests/tests.tap 1
PASS: Magick++/tests/tests.tap 2
PASS: Magick++/tests/tests.tap 3
PASS: Magick++/tests/tests.tap 4
PASS: Magick++/tests/tests.tap 5
PASS: Magick++/tests/tests.tap 6
PASS: Magick++/tests/tests.tap 7
PASS: Magick++/tests/tests.tap 8
PASS: Magick++/tests/tests.tap 9
PASS: Magick++/tests/tests.tap 10
PASS: Magick++/tests/tests.tap 11
PASS: Magick++/tests/tests.tap 12
PASS: Magick++/demo/demos.tap 1
PASS: Magick++/demo/demos.tap 2
PASS: Magick++/demo/demos.tap 3
PASS: Magick++/demo/demos.tap 4
PASS: Magick++/demo/demos.tap 5
PASS: Magick++/demo/demos.tap 6
PASS: Magick++/demo/demos.tap 7
PASS: Magick++/demo/demos.tap 8
PASS: Magick++/demo/demos.tap 9
PASS: Magick++/demo/demos.tap 10
PASS: Magick++/demo/demos.tap 11
PASS: Magick++/demo/demos.tap 12
PASS: Magick++/demo/demos.tap 13
PASS: Magick++/demo/demos.tap 14
PASS: Magick++/demo/demos.tap 15
PASS: Magick++/demo/demos.tap 16
PASS: Magick++/demo/demos.tap 17
PASS: Magick++/demo/demos.tap 18
PASS: Magick++/demo/demos.tap 19
PASS: Magick++/demo/demos.tap 20
PASS: Magick++/demo/demos.tap 21
PASS: Magick++/demo/demos.tap 22
PASS: Magick++/demo/demos.tap 23
PASS: Magick++/demo/demos.tap 24
============================================================================
Testsuite summary for ImageMagick 6.9.9
============================================================================
# TOTAL: 76
# PASS:  76
# SKIP:  0
# XFAIL: 0
# FAIL:  0
# XPASS: 0
# ERROR: 0
============================================================================

@mooninite
Copy link
Author

Yes, Ghostscript 9.20 is installed. There is no Fedora 29 (typo?).

You can see the contents of the build root (all packages installed) here: https://kojipkgs.fedoraproject.org//work/tasks/1216/22091216/root.log

You can see the full build log here: https://kojipkgs.fedoraproject.org//work/tasks/1216/22091216/build.log

Here is the scratch build task to show all arches we build for: https://koji.fedoraproject.org/koji/taskinfo?taskID=22091215

@mikayla-grace
Copy link

You have enabled Freetype but have not installed the default Helvetica font. The unit tests are failing because ImageMagick cannot find the default Helvetica font. What do you get from this command in your build environment:

convert -list font

@mooninite
Copy link
Author

Thanks for the hint. It appears a new package in Fedora Rawhide has been introduced just this week that overrides the "urw-fonts" package (which contains Helvetica) and does not provide Helvetica. I will file a bug against the new package.

@deekej
Copy link

deekej commented Sep 27, 2017

Hello people. I would suggest reopening this issue, here's why:
https://bugzilla.redhat.com/show_bug.cgi?id=1496308#c1

@urban-warrior urban-warrior reopened this Sep 27, 2017
@deekej
Copy link

deekej commented Sep 27, 2017

Okay, so I have updated to font paths for the config/type-ghostscript.xml.in, and tried to build it for Fedora Rawhide (alongside with updated ghostscript package). However, the build still fails. Here's the test-suite.log:

=========================================
   ImageMagick 6.9.9: ./test-suite.log
=========================================

# TOTAL: 76
# PASS:  70
# SKIP:  0
# XFAIL: 0
# FAIL:  6
# XPASS: 0
# ERROR: 0

.. contents:: :depth: 2

FAIL: tests/wandtest
====================

tests/wandtest.c main 5321 non-conforming drawing primitive definition `text' @ error/draw.c/DrawImage/3265
1..1
Reading images...
Iterate forward...
index 0 scene 0
index 1 scene 1
index 2 scene 2
index 3 scene 3
index 4 scene 4
Iterate reverse...
index 4 scene 4
index 3 scene 3
index 2 scene 2
index 1 scene 1
index 0 scene 0
Remove scene 1...
index 0 scene 0
index 1 scene 2
index 2 scene 3
index 3 scene 4
Insert scene 1 back in sequence...
index 0 scene 0
index 1 scene 1
index 2 scene 2
index 3 scene 3
index 4 scene 4
Set scene 2 to scene 1...
index 0 scene 0
index 1 scene 1
index 2 scene 1
index 3 scene 3
index 4 scene 4
Apply image processing options...
not ok
FAIL: tests/wandtest.tap 1

FAIL: Magick++/demo/demos
=========================

1..24
File: /builddir/build/BUILD/ImageMagick-6.9.9-13/Magick++/demo//model.miff
lt-analyze: unable to load module `analyze.la': /usr/lib64/ImageMagick-6.9.9//modules-Q16/filters/analyze.la @ error/module.c/InvokeDynamicImageFilter/994
ok
PASS: Magick++/demo/demos.tap 1
Caught exception: lt-button: unable to read font `(null)' @ error/annotate.c/RenderFreetype/1362
not ok
FAIL: Magick++/demo/demos.tap 2
Read images ...
Creating thumbnails...
  add noise ...
  add noise (blue) ...
  annotate ...
Caught exception: lt-demo: unable to read font `(null)' @ error/annotate.c/RenderFreetype/1362
not ok
FAIL: Magick++/demo/demos.tap 3
Writing image "flip_out.miff" ...
ok
PASS: Magick++/demo/demos.tap 4
angle 0
Caught exception: lt-gravity: unable to read font `(null)' @ error/annotate.c/RenderFreetype/1362
not ok
FAIL: Magick++/demo/demos.tap 5
Caught exception: lt-piddle: non-conforming drawing primitive definition `text' @ error/draw.c/DrawImage/3265
not ok
FAIL: Magick++/demo/demos.tap 6
Caught exception: lt-shapes: unable to read font `(null)' @ error/annotate.c/RenderFreetype/1362
not ok
FAIL: Magick++/demo/demos.tap 7
ok
PASS: Magick++/demo/demos.tap 8
ok
PASS: Magick++/demo/demos.tap 9
ok
PASS: Magick++/demo/demos.tap 10
ok
PASS: Magick++/demo/demos.tap 11
ok
PASS: Magick++/demo/demos.tap 12
ok
PASS: Magick++/demo/demos.tap 13
ok
PASS: Magick++/demo/demos.tap 14
ok
PASS: Magick++/demo/demos.tap 15
ok
PASS: Magick++/demo/demos.tap 16
ok
PASS: Magick++/demo/demos.tap 17
ok
PASS: Magick++/demo/demos.tap 18
ok
PASS: Magick++/demo/demos.tap 19
ok
PASS: Magick++/demo/demos.tap 20
ok
PASS: Magick++/demo/demos.tap 21
ok
PASS: Magick++/demo/demos.tap 22
ok
PASS: Magick++/demo/demos.tap 23
ok
PASS: Magick++/demo/demos.tap 24

@urban-warrior
Copy link
Member

urban-warrior commented Sep 27, 2017

https://bugzilla.redhat.com/show_bug.cgi?id=1496308#c1 suggests that the file names have changed as well as the paths. Since you seem to be supporting fontconfig in the build, ImageMagick should consult fontconfig for the appropriate font. What does convert -list font report?

It might be easier if we had access to a Fedora 28 machine so we can debug. If you could provide temporary ssh access, contact us @ fedora at imagemagick dot org.

@deekej
Copy link

deekej commented Sep 27, 2017

Sorry, I'm unable to provide you with ssh access to Fedora Rawhide machine, we have only internal access to them, and it's forbidden to share it outside anyway. :-/

Regarding the convert -list font command - I have installed urw-base35-fonts in a Fedora Rawhide machine, alongside with previous (successful) build of ImageMagick (which was build against older urw-fonts). Here's the output of it:

Path: System Fonts
  Font: C059-Bold
    family: C059
    style: Normal
    stretch: Normal
    weight: 700
    glyphs: /usr/share/fonts/urw-base35/C059-Bold.t1
  Font: C059-Bold-Italic
    family: C059
    style: Italic
    stretch: Normal
    weight: 700
    glyphs: /usr/share/fonts/urw-base35/C059-BdIta.t1
  Font: C059-Italic
    family: C059
    style: Italic
    stretch: Normal
    weight: 500
    glyphs: /usr/share/fonts/urw-base35/C059-Italic.t1
  Font: C059-Roman
    family: C059
    style: Normal
    stretch: Normal
    weight: 500
    glyphs: /usr/share/fonts/urw-base35/C059-Roman.t1
  Font: Comfortaa
    family: Comfortaa
    style: Normal
    stretch: Normal
    weight: 400
    glyphs: /usr/share/fonts/aajohan-comfortaa/Comfortaa-Regular.ttf
  Font: Comfortaa-Bold
    family: Comfortaa
    style: Normal
    stretch: Normal
    weight: 700
    glyphs: /usr/share/fonts/aajohan-comfortaa/Comfortaa-Bold.ttf
  Font: Comfortaa-Light
    family: Comfortaa
    style: Normal
    stretch: Normal
    weight: 300
    glyphs: /usr/share/fonts/aajohan-comfortaa/Comfortaa-Light.ttf
  Font: D050000L
    family: D050000L
    style: Normal
    stretch: Normal
    weight: 400
    glyphs: /usr/share/fonts/urw-base35/D050000L.t1
  Font: Nimbus-Mono-PS
    family: Nimbus Mono PS
    style: Normal
    stretch: Normal
    weight: 400
    glyphs: /usr/share/fonts/urw-base35/NimbusMonoPS-Regular.t1
  Font: Nimbus-Mono-PS-Bold
    family: Nimbus Mono PS
    style: Normal
    stretch: Normal
    weight: 700
    glyphs: /usr/share/fonts/urw-base35/NimbusMonoPS-Bold.t1
  Font: Nimbus-Mono-PS-Bold-Italic
    family: Nimbus Mono PS
    style: Italic
    stretch: Normal
    weight: 700
    glyphs: /usr/share/fonts/urw-base35/NimbusMonoPS-BoldItalic.t1
  Font: Nimbus-Mono-PS-Italic
    family: Nimbus Mono PS
    style: Italic
    stretch: Normal
    weight: 400
    glyphs: /usr/share/fonts/urw-base35/NimbusMonoPS-Italic.t1
  Font: Nimbus-Roman
    family: Nimbus Roman
    style: Normal
    stretch: Normal
    weight: 400
    glyphs: /usr/share/fonts/urw-base35/NimbusRoman-Regular.t1
  Font: Nimbus-Roman-Bold
    family: Nimbus Roman
    style: Normal
    stretch: Normal
    weight: 700
    glyphs: /usr/share/fonts/urw-base35/NimbusRoman-Bold.t1
  Font: Nimbus-Roman-Bold-Italic
    family: Nimbus Roman
    style: Italic
    stretch: Normal
    weight: 700
    glyphs: /usr/share/fonts/urw-base35/NimbusRoman-BoldItalic.t1
  Font: Nimbus-Roman-Italic
    family: Nimbus Roman
    style: Italic
    stretch: Normal
    weight: 400
    glyphs: /usr/share/fonts/urw-base35/NimbusRoman-Italic.t1
  Font: Nimbus-Sans
    family: Nimbus Sans
    style: Normal
    stretch: Normal
    weight: 400
    glyphs: /usr/share/fonts/urw-base35/NimbusSans-Regular.t1
  Font: Nimbus-Sans-Bold
    family: Nimbus Sans
    style: Normal
    stretch: Normal
    weight: 700
    glyphs: /usr/share/fonts/urw-base35/NimbusSans-Bold.t1
  Font: Nimbus-Sans-Bold-Italic
    family: Nimbus Sans
    style: Italic
    stretch: Normal
    weight: 700
    glyphs: /usr/share/fonts/urw-base35/NimbusSans-BoldItalic.t1
  Font: Nimbus-Sans-Italic
    family: Nimbus Sans
    style: Italic
    stretch: Normal
    weight: 400
    glyphs: /usr/share/fonts/urw-base35/NimbusSans-Italic.t1
  Font: Nimbus-Sans-Narrow
    family: Nimbus Sans Narrow
    style: Normal
    stretch: Normal
    weight: 400
    glyphs: /usr/share/fonts/urw-base35/NimbusSansNarrow-Regular.t1
  Font: Nimbus-Sans-Narrow-Bold
    family: Nimbus Sans Narrow
    style: Normal
    stretch: Normal
    weight: 700
    glyphs: /usr/share/fonts/urw-base35/NimbusSansNarrow-Bold.t1
  Font: Nimbus-Sans-Narrow-Bold-Oblique
    family: Nimbus Sans Narrow
    style: Oblique
    stretch: Normal
    weight: 700
    glyphs: /usr/share/fonts/urw-base35/NimbusSansNarrow-BdOblique.t1
  Font: Nimbus-Sans-Narrow-Oblique
    family: Nimbus Sans Narrow
    style: Oblique
    stretch: Normal
    weight: 400
    glyphs: /usr/share/fonts/urw-base35/NimbusSansNarrow-Oblique.t1
  Font: P052-Bold
    family: P052
    style: Normal
    stretch: Normal
    weight: 700
    glyphs: /usr/share/fonts/urw-base35/P052-Bold.t1
  Font: P052-Bold-Italic
    family: P052
    style: Italic
    stretch: Normal
    weight: 700
    glyphs: /usr/share/fonts/urw-base35/P052-BoldItalic.t1
  Font: P052-Italic
    family: P052
    style: Italic
    stretch: Normal
    weight: 400
    glyphs: /usr/share/fonts/urw-base35/P052-Italic.t1
  Font: P052-Roman
    family: P052
    style: Normal
    stretch: Normal
    weight: 500
    glyphs: /usr/share/fonts/urw-base35/P052-Roman.t1
  Font: Standard-Symbols-PS
    family: Standard Symbols PS
    style: Normal
    stretch: Normal
    weight: 400
    glyphs: /usr/share/fonts/urw-base35/StandardSymbolsPS.t1
  Font: URW-Bookman-Demi
    family: URW Bookman
    style: Normal
    stretch: Normal
    weight: 600
    glyphs: /usr/share/fonts/urw-base35/URWBookman-Demi.t1
  Font: URW-Bookman-Demi-Italic
    family: URW Bookman
    style: Italic
    stretch: Normal
    weight: 600
    glyphs: /usr/share/fonts/urw-base35/URWBookman-DemiItalic.t1
  Font: URW-Bookman-Light
    family: URW Bookman
    style: Normal
    stretch: Normal
    weight: 300
    glyphs: /usr/share/fonts/urw-base35/URWBookman-Light.t1
  Font: URW-Bookman-Light-Italic
    family: URW Bookman
    style: Italic
    stretch: Normal
    weight: 300
    glyphs: /usr/share/fonts/urw-base35/URWBookman-LightItalic.t1
  Font: URW-Gothic-Book
    family: URW Gothic
    style: Normal
    stretch: Normal
    weight: 300
    glyphs: /usr/share/fonts/urw-base35/URWGothic-Book.t1
  Font: URW-Gothic-Book-Oblique
    family: URW Gothic
    style: Oblique
    stretch: Normal
    weight: 300
    glyphs: /usr/share/fonts/urw-base35/URWGothic-BookOblique.t1
  Font: URW-Gothic-Demi
    family: URW Gothic
    style: Normal
    stretch: Normal
    weight: 600
    glyphs: /usr/share/fonts/urw-base35/URWGothic-Demi.t1
  Font: URW-Gothic-Demi-Oblique
    family: URW Gothic
    style: Oblique
    stretch: Normal
    weight: 600
    glyphs: /usr/share/fonts/urw-base35/URWGothic-DemiOblique.t1
  Font: Utopia
    family: Utopia
    style: Normal
    stretch: Normal
    weight: 400
    glyphs: /usr/share/fonts/default/ghostscript/putr.pfa
  Font: Utopia-Bold
    family: Utopia
    style: Normal
    stretch: Normal
    weight: 700
    glyphs: /usr/share/fonts/default/ghostscript/putb.pfa
  Font: Utopia-Bold-Italic
    family: Utopia
    style: Italic
    stretch: Normal
    weight: 700
    glyphs: /usr/share/fonts/default/ghostscript/putbi.pfa
  Font: Utopia-Italic
    family: Utopia
    style: Italic
    stretch: Normal
    weight: 400
    glyphs: /usr/share/fonts/default/ghostscript/putri.pfa
  Font: Z003-Medium-Italic
    family: Z003
    style: Italic
    stretch: Normal
    weight: 500
    glyphs: /usr/share/fonts/urw-base35/Z003-MediumItalic.t1

If I ignore the outdated/deprecated fonts (from ghostscript-fonts package), I can see that it can find the new (URW)++ fonts correctly.

So, I might have fixed the font names, but my wild guess is that the path to these fonts can't somehow be find? In Fedora, we ship the fonts separately from ghostscript (it is able to find them automatically), so the ghostscript package does not even contain links to these fonts.

@deekej
Copy link

deekej commented Sep 27, 2017

Okay, so I have managed to successfully build the ImageMagick for Fedora Rawhide again. The missing piece to make it work was to fix font directory detection in configure and configure.ac (I wasn't regenerating the configure script completely, feel free to do it if needed.)

See the updated commit for more info. I'll be creating a pull-request now.

@mikayla-grace
Copy link

We need to support both old-style Ghostscript fonts and URW-base65. We manually added a robust solution based on your pull request. Thank you for your contribution. Let us know if the ImageMagick build works now for Fedora 28.

@mooninite
Copy link
Author

The 1360649 / fbca0d0 patch solves the issue. Thanks.

@deekej
Copy link

deekej commented Oct 2, 2017

@mooninite is the leading maintainer for ImageMagick in Fedora, so I would take his word for it... ;)

The commit fbca0d0 looks good to me, but I have one small note to add...

The path /usr/share/fonts/default/Type1/ is currently based on the (old) urw-fonts package in Fedora. Honestly, I really don't know the path was chosen like this before (I can only guess), but since the urw-fonts will now be soon retired (in favor of urw-base35-fonts), you could deprecate the use of urw-fonts at some point in the future. Unless you want to keep backward compatibility forever... ;)

Best regards,

Dee'Kej

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging a pull request may close this issue.

4 participants