(none) imager-devel
/ help / lists / applications / search /
 

Re: Problems with Imager Imager::Plot on Solaris 8

From: Slaven Rezic (
05961@xyz.molar.is)
Date: Mon 14 Oct 2002 - 19:27:38 GMT

  • Next message: Super-User: "Center the image in Imager::PlotB"

    Arnar Mar Hrafnkelsson <05884@xyz.molar.is> writes:

    > The problem is that solaris stores its color file rgb.txt in a different
    > location than many other operating systems. The problem is really in
    > Imager and not in Imager::Plot. It just so turns out that the tests for
    > Imager don't tickle this particular bug. (Which is a bug too of course).
    > If I'm remembering correctly the fix for this is to change the definition
    > of @x_search in lib/Imager/Color.pm in the imager distribution (and then
    > reinstall).
    >
    > The correct definition is:
    >
    > my @x_search =
    > (
    > '/usr/lib/X11/rgb.txt', # seems fairly standard
    > '/usr/local/lib/X11/rgb.txt', # seems possible
    > '/usr/X11R6/lib/X11/rgb.txt', # probably the same as the first
    > '/usr/openwin/lib/rgb.txt',
    > '/usr/openwin/lib/X11/rgb.txt',
    > );
    >

    Maybe additionally the x11 library directory could be fetched in
    Makefile.PL, e.g.:

    use File::Spec;

    open(IMAKEFILE, ">Imakefile") or die "Can't create Imakefile: $!";
    print IMAKEFILE <<'EOF';
    echolibdir:
            @echo $(LIBDIR)
    EOF
    close IMAKEFILE;

    open(OLDOUT, ">&STDOUT") or die $!;
    open(OLDERR, ">&STDERR") or die $!;
    open(STDOUT, ">". File::Spec->devnull) or die $!;
    open(STDERR, ">". File::Spec->devnull) or die $!;
    system("xmkmf") and die "Error while running xmkmf";
    chomp($x11libdir = `make echolibdir`);
    open(STDOUT, ">&OLDOUT") or die $!;
    open(STDERR, ">&OLDERR") or die $!;

    unlink "Imakefile";
    unlink "Makefile";

    warn $x11libdir;
    __END__

    Regards,
            Slaven

    -- 
    Slaven Rezic - 05961@xyz.molar.is
        babybike - routeplanner for cyclists in Berlin
    	       handheld (e.g. Compaq iPAQ with Linux) version of bbbike
        http://bbbike.sourceforge.net
    



  •