Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 217248 - rmagick emerge hangs when "doc" USE flag is set
Summary: rmagick emerge hangs when "doc" USE flag is set
Status: RESOLVED WORKSFORME
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: New packages (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: Gentoo Ruby Team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-04-11 02:56 UTC by M. Edward Borasky
Modified: 2008-04-15 05:34 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments
e,erge --info (emerge-info,4.56 KB, text/plain)
2008-04-11 02:58 UTC, M. Edward Borasky
Details

Note You need to log in before you can comment on or make changes to this bug.
Description M. Edward Borasky 2008-04-11 02:56:55 UTC
I can emerge dev-ruby/rmagick 2.3.0 without the "doc" USE flag fine. But when I set the "doc" USE flag, it gets to "example 12" and then goes into some kind of infinite loop on example 12 of 184:

setup.rb: entering post-setup phase...
post-setup.rb: setting up documentation...
/usr/bin/ruby18 -I /var/tmp/portage/dev-ruby/rmagick-2.3.0/work/RMagick-2.3.0/./lib -I /var/tmp/portage/dev-ruby/rmagick-2.3.0/work/RMagick-2.3.0/./ext/RMagick InitialCoords.rb (example 1 of 184)
/usr/bin/ruby18 -I /var/tmp/portage/dev-ruby/rmagick-2.3.0/work/RMagick-2.3.0/./lib -I /var/tmp/portage/dev-ruby/rmagick-2.3.0/work/RMagick-2.3.0/./ext/RMagick NewCoordSys.rb (example 2 of 184)
/usr/bin/ruby18 -I /var/tmp/portage/dev-ruby/rmagick-2.3.0/work/RMagick-2.3.0/./lib -I /var/tmp/portage/dev-ruby/rmagick-2.3.0/work/RMagick-2.3.0/./ext/RMagick OrigCoordSys.rb (example 3 of 184)
/usr/bin/ruby18 -I /var/tmp/portage/dev-ruby/rmagick-2.3.0/work/RMagick-2.3.0/./lib -I /var/tmp/portage/dev-ruby/rmagick-2.3.0/work/RMagick-2.3.0/./ext/RMagick PreserveAspectRatio.rb (example 4 of 184)
/usr/bin/ruby18 -I /var/tmp/portage/dev-ruby/rmagick-2.3.0/work/RMagick-2.3.0/./lib -I /var/tmp/portage/dev-ruby/rmagick-2.3.0/work/RMagick-2.3.0/./ext/RMagick RotateScale.rb (example 5 of 184)
/usr/bin/ruby18 -I /var/tmp/portage/dev-ruby/rmagick-2.3.0/work/RMagick-2.3.0/./lib -I /var/tmp/portage/dev-ruby/rmagick-2.3.0/work/RMagick-2.3.0/./ext/RMagick Skew.rb (example 6 of 184)
/usr/bin/ruby18 -I /var/tmp/portage/dev-ruby/rmagick-2.3.0/work/RMagick-2.3.0/./lib -I /var/tmp/portage/dev-ruby/rmagick-2.3.0/work/RMagick-2.3.0/./ext/RMagick Use01.rb (example 7 of 184)
/usr/bin/ruby18 -I /var/tmp/portage/dev-ruby/rmagick-2.3.0/work/RMagick-2.3.0/./lib -I /var/tmp/portage/dev-ruby/rmagick-2.3.0/work/RMagick-2.3.0/./ext/RMagick Use02.rb (example 8 of 184)
/usr/bin/ruby18 -I /var/tmp/portage/dev-ruby/rmagick-2.3.0/work/RMagick-2.3.0/./lib -I /var/tmp/portage/dev-ruby/rmagick-2.3.0/work/RMagick-2.3.0/./ext/RMagick Use03.rb (example 9 of 184)
/usr/bin/ruby18 -I /var/tmp/portage/dev-ruby/rmagick-2.3.0/work/RMagick-2.3.0/./lib -I /var/tmp/portage/dev-ruby/rmagick-2.3.0/work/RMagick-2.3.0/./ext/RMagick ViewBox.rb (example 10 of 184)
/usr/bin/ruby18 -I /var/tmp/portage/dev-ruby/rmagick-2.3.0/work/RMagick-2.3.0/./lib -I /var/tmp/portage/dev-ruby/rmagick-2.3.0/work/RMagick-2.3.0/./ext/RMagick adaptive_threshold.rb (example 11 of 184)
/usr/bin/ruby18 -I /var/tmp/portage/dev-ruby/rmagick-2.3.0/work/RMagick-2.3.0/./lib -I /var/tmp/portage/dev-ruby/rmagick-2.3.0/work/RMagick-2.3.0/./ext/RMagick add_noise.rb (example 12 of 184)
Comment 1 M. Edward Borasky 2008-04-11 02:58:44 UTC
Created attachment 149364 [details]
e,erge --info
Comment 2 M. Edward Borasky 2008-04-11 03:07:56 UTC
The gem installs fine with "gem install rmagick", so I'm stumped as to why it's doing this. I can try the emerge again and "strace" the Ruby processes (there are two) when it hangs.
Comment 3 Hans de Graaff gentoo-dev Security 2008-04-11 05:33:15 UTC
Note that we don't use the gem due to potential borkage with the configure process.

The examples build fine for me. It might be useful to determine the arch, and the instance of imagemagick (version and USE flags) you are trying to build against.
Comment 4 M. Edward Borasky 2008-04-11 13:59:25 UTC
Arch is AMD64

USE flags:

# emerge -pv imagemagick

These are the packages that would be merged, in order:

Calculating dependencies... done!
[ebuild   R   ] media-gfx/imagemagick-6.3.9.7  USE="X bzip2 djvu fontconfig fpx graphviz gs jpeg lcms perl png svg tiff truetype wmf xml zlib -doc -hdri -jbig -jpeg2k -nocxx -openexr -q32 -q8" 0 kB 


So ... what does example 12 do? The one that is hanging? "add_noise.rb"

#! /usr/local/bin/ruby -w
require 'RMagick'

# Demonstrate the Image#add_noise method
NOISE_TYPES = [Magick::UniformNoise, Magick::GaussianNoise,
               Magick::MultiplicativeGaussianNoise,
               Magick::ImpulseNoise, Magick::LaplacianNoise,
               Magick::PoissonNoise]

img = Magick::Image.read('images/Flower_Hat.jpg').first

NOISE_TYPES.each do |noise|
    copy = img.add_noise(noise)
    copy.write "add_noise_#{noise.to_s}.jpg"

end
exit

Looks OK to me ... maybe I just didn't wait long enough?
Comment 5 Markos Chandras (RETIRED) gentoo-dev 2008-04-11 20:13:32 UTC
Works fine for me too

/usr/bin/ruby18 -I /var/tmp/portage/dev-ruby/rmagick-2.3.0/work/RMagick-2.3.0/./lib -I /var/tmp/portage/dev-ruby/rmagick-2.3.0/work/RMagick-2.3.0/./ext/RMagick adaptive_threshold.rb (example 11 of 184)
/usr/bin/ruby18 -I /var/tmp/portage/dev-ruby/rmagick-2.3.0/work/RMagick-2.3.0/./lib -I /var/tmp/portage/dev-ruby/rmagick-2.3.0/work/RMagick-2.3.0/./ext/RMagick add_noise.rb (example 12 of 184)
/usr/bin/ruby18 -I /var/tmp/portage/dev-ruby/rmagick-2.3.0/work/RMagick-2.3.0/./lib -I /var/tmp/portage/dev-ruby/rmagick-2.3.0/work/RMagick-2.3.0/./ext/RMagick affine.rb (example 13 of 184
...
Comment 6 Hans de Graaff gentoo-dev Security 2008-04-12 06:40:52 UTC
I'm also on amd64, although with a different set of USE flags:

[6.3.7.9-r1] USE="X bzip2 jpeg lcms perl* png svg tiff truetype xml zlib -djvu -doc -fontconfig -fpx -graphviz -gs -hdri -jbig -jpeg2k -nocxx -openexr -q32 -q8 -wmf"

The example should run quickly as well: real	0m0.418s

I think it would be useful to try and run the example by itself and use strace to determine what it is waiting for.


Comment 7 M. Edward Borasky 2008-04-12 15:47:21 UTC
strace didn't tell anything -- it's apparently not doing system calls. I have AMD CodeAnalyst, so I could figure out where in the Ruby interpreter this is happening. However, since I can reproduce it with the Rmagick gem and since nobody else on Gentoo has reproduced it yet, I think I'm going to go over to the Rmagick mailing list.
Comment 8 M. Edward Borasky 2008-04-13 03:50:22 UTC
OK ... it's reproducible from the upstream tarball, so I am going to open a ticket there. If I get ambitious I'll try it on a 32-bit machine. There is a configuration option you can use to suppress running the examples, assuming that's required.
Comment 9 M. Edward Borasky 2008-04-13 21:12:51 UTC
The RMagick team thinks this is an ImageMagick problem and they haven't been able to reproduce it either. Meanwhile they recommended trying a more recent version of ImageMagick. 
Comment 10 M. Edward Borasky 2008-04-15 02:17:45 UTC
Good news ... upgrading to imagemagick-6.4.0.6 fixed it!! I guess you can close it as "unable to reproduce" or dependent on the bug that called for an ImageMagick version bump.
Comment 11 Hans de Graaff gentoo-dev Security 2008-04-15 05:34:23 UTC
I'm closing this as worksforme. imagemagick-6.4.0.6 just got added to CVS two days ago, so there is no open bug to depend on anymore. :-)