Re: Image::Imlib2 error

Ian B <[email protected]> Sat, 29 Mar 2025 18:45:26 +0000
Newsgroups gmane.comp.apache.mod-perl
Message-ID <CANAUX_SoPjjsu0TU78vW_3OPhf7y-JnHcBGrUxsaMjfbu1q1gg@mail.gmail.com>
--000000000000c881b406317f9756
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable

Make sure you install the Imlib2 headers, something like Imlib2-dev
package. Perl will probably use that to compile its own .so file.

On Sat, Mar 29, 2025 at 6:33=E2=80=AFPM Ruben Safir <[email protected]> wr=
ote:

> On 3/29/25 3:34 AM, Ian B wrote:
> > Try nm -D rather than nm....
> >
> > nm -D /usr/lib/imlib2/loaders/jpeg.so | grep ProgressRows
> >
> > I'd be tempted to ask about this question on StackOverflow, there's som=
e
> > very knowledgeable folk on there, who may have some better things to
> > check...a part of me wants to suggest reinstalling Perls Image::Imlib2,
> but
> > I wouldn't want to break anything, so maybe a wiser head would help.
> >
> > On Fri, Mar 28, 2025 at 11:42=E2=80=AFPM Ruben Safir <[email protected]=
m> wrote:
> >
> >>
> >> [ruben@www3 ~]$ strings  /usr/lib/imlib2/loaders/zlib.so|grep
> >> __imlib_FindBestLoader
> >> __imlib_FindBestLoader
> >>
> >>
> >>
> >
>
>
>
>
> I looked this over yesterday when I was searching for the source code to
> try to build it by hand.  I must have changed on the upstream.  Money it
> worked and Tuesday it just didn't so  something changed.
>
> I think the library itself works in that it can find the image loader
> libraries and binaries.   The Perl module can't find them, though, where
> last week it did.  There is a lynchpin of information missing between
> the two.
>
> These are the libraries:
>
> Code: [Select]
>
>
> [www3 ~]# ls -al /usr/lib/imlib2/loaders/
> total 432
> drwxr-xr-x 2 root root  4096 Mar 28 08:19 .
> drwxr-xr-x 4 root root  4096 Oct  9  2017 ..
> -rwxr-xr-x 1 root root 14232 Mar 17 20:36 ani.so
> -rwxr-xr-x 1 root root 14232 Mar 17 20:36 argb.so
> -rwxr-xr-x 1 root root 18328 Mar 17 20:36 bmp.so
> -rwxr-xr-x 1 root root 14232 Mar 17 20:36 bz2.so
> -rwxr-xr-x 1 root root 14232 Mar 17 20:36 ff.so
> -rwxr-xr-x 1 root root 14232 Mar 17 20:36 gif.so
> -rwxr-xr-x 1 root root 14232 Mar 17 20:36 heif.so
> -rwxr-xr-x 1 root root 14232 Mar 17 20:36 ico.so
> -rwxr-xr-x 1 root root 14232 Mar 17 20:36 id3.so
> -rwxr-xr-x 1 root root 14232 Mar 17 20:36 j2k.so
> -rwxr-xr-x 1 root root 14232 Mar 17 20:36 jpeg.so
> -rwxr-xr-x 1 root root 14232 Mar 17 20:36 jxl.so
> -rwxr-xr-x 1 root root 18328 Mar 17 20:36 lbm.so
> -rwxr-xr-x 1 root root 14232 Mar 17 20:36 lzma.so
> -rwxr-xr-x 1 root root 18328 Mar 17 20:36 png.so
> -rwxr-xr-x 1 root root 18328 Mar 17 20:36 pnm.so
> -rwxr-xr-x 1 root root 14232 Mar 17 20:36 ps.so
> -rwxr-xr-x 1 root root 14232 Mar 17 20:36 qoi.so
> -rwxr-xr-x 1 root root 14232 Mar 17 20:36 svg.so
> -rwxr-xr-x 1 root root 14232 Mar 17 20:36 tga.so
> -rwxr-xr-x 1 root root 18328 Mar 17 20:36 tiff.so
> -rwxr-xr-x 1 root root 14232 Mar 17 20:36 webp.so
> -rwxr-xr-x 1 root root 14232 Mar 17 20:36 xbm.so
> -rwxr-xr-x 1 root root 18328 Mar 17 20:36 xpm.so
> -rwxr-xr-x 1 root root 14232 Mar 17 20:36 zlib.so
>
>
>
> The test programs that come with it seem to work - under /usr/bin - they
> are imlib2_*  like imlib2_view etc.
>
> Trying to figure this out, I by passed cpan and tried to install the
> Perl by hand and it refused to build
>
> Code: [Select]
>
> [ruben@www3 Image-Imlib2-2.03-2]$ perl Makefile.PL
> # running Build.PL
> You must install the imlib2 library before you can install
> Image::Imlib2. You can obtain imlib2 from
> http://sourceforge.net/projects/enlightenment/
>
> Alternatively, if you have downloaded and installed imlib2 and this
> still will not work, modify the $CONFIG variable inside Build.PL to
> point to the imlib2-config program that provides.
>
>
>
> The change file of imlib2 says this program has been removed and
> returned and then recently removed again.  Scouring the net for a
> solution I turned up this:
>
>
> https://stackoverflow.com/questions/66261506/imlib2-saving-image-returns-=
imlib-load-error-no-loader-for-file-format#66264954
>
> Quote
>
>     Ok, after digging a little deeper into the imlib2 source it turns
> out that the loaders are always looked up as shared objects. I thought
> the loaders are also compiled into the static lib, but I was wrong.
>
>     Either I can set the directory by specifying IMLIB2_LOADER_PATH or
> by putting them into the default loader path which is
> /usr/local/lib/imlib2/loaders in the self compiled version.
>
>
> I don't think adding an environmental variable to a program called by
> Apache is a good idea.
>
> It is in the Arch AUR but hasn't been changed since 2015
>
> https://packages.artixlinux.org/packages/world/x86_64/imlib2/
>
> I don't see anything in the package build that can be useful to fix
> this, but I am not a pacman expert.
>
>
>
> --
> So many immigrant groups have swept through our town
> that Brooklyn, like Atlantis, reaches mythological
> proportions in the mind of the world - RI Safir 1998
> http://www.mrbrklyn.com
> DRM is THEFT - We are the STAKEHOLDERS - RI Safir 2002
>
> http://www.nylxs.com - Leadership Development in Free Software
> http://www.brooklyn-living.com
>
> Being so tracked is for FARM ANIMALS and extermination camps,
> but incompatible with living as a free human being. -RI Safir 2013
>

--000000000000c881b406317f9756
Content-Type: text/html; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable

<div dir=3D"ltr">Make sure you install the Imlib2 headers, something like I=
mlib2-dev package. Perl will probably use that to compile its own .so file.=
</div><br><div class=3D"gmail_quote gmail_quote_container"><div dir=3D"ltr"=
 class=3D"gmail_attr">On Sat, Mar 29, 2025 at 6:33=E2=80=AFPM Ruben Safir &=
lt;<a href=3D"mailto:[email protected]">[email protected]</a>&gt; wrote:<=
br></div><blockquote class=3D"gmail_quote" style=3D"margin:0px 0px 0px 0.8e=
x;border-left:1px solid rgb(204,204,204);padding-left:1ex">On 3/29/25 3:34 =
AM, Ian B wrote:<br>
&gt; Try nm -D rather than nm....<br>
&gt; <br>
&gt; nm -D /usr/lib/imlib2/loaders/jpeg.so | grep ProgressRows<br>
&gt; <br>
&gt; I&#39;d be tempted to ask about this question on StackOverflow, there&=
#39;s some<br>
&gt; very knowledgeable folk on there, who may have some better things to<b=
r>
&gt; check...a part of me wants to suggest reinstalling Perls Image::Imlib2=
, but<br>
&gt; I wouldn&#39;t want to break anything, so maybe a wiser head would hel=
p.<br>
&gt; <br>
&gt; On Fri, Mar 28, 2025 at 11:42=E2=80=AFPM Ruben Safir &lt;<a href=3D"ma=
ilto:[email protected]" target=3D"_blank">[email protected]</a>&gt; wrote=
:<br>
&gt; <br>
&gt;&gt;<br>
&gt;&gt; [ruben@www3 ~]$ strings=C2=A0 /usr/lib/imlib2/loaders/zlib.so|grep=
<br>
&gt;&gt; __imlib_FindBestLoader<br>
&gt;&gt; __imlib_FindBestLoader<br>
&gt;&gt;<br>
&gt;&gt;<br>
&gt;&gt;<br>
&gt; <br>
<br>
<br>
<br>
<br>
I looked this over yesterday when I was searching for the source code to<br=
>
try to build it by hand.=C2=A0 I must have changed on the upstream.=C2=A0 M=
oney it<br>
worked and Tuesday it just didn&#39;t so=C2=A0 something changed.<br>
<br>
I think the library itself works in that it can find the image loader<br>
libraries and binaries.=C2=A0 =C2=A0The Perl module can&#39;t find them, th=
ough, where<br>
last week it did.=C2=A0 There is a lynchpin of information missing between<=
br>
the two.<br>
<br>
These are the libraries:<br>
<br>
Code: [Select]<br>
<br>
<br>
[www3 ~]# ls -al /usr/lib/imlib2/loaders/<br>
total 432<br>
drwxr-xr-x 2 root root=C2=A0 4096 Mar 28 08:19 .<br>
drwxr-xr-x 4 root root=C2=A0 4096 Oct=C2=A0 9=C2=A0 2017 ..<br>
-rwxr-xr-x 1 root root 14232 Mar 17 20:36 ani.so<br>
-rwxr-xr-x 1 root root 14232 Mar 17 20:36 argb.so<br>
-rwxr-xr-x 1 root root 18328 Mar 17 20:36 bmp.so<br>
-rwxr-xr-x 1 root root 14232 Mar 17 20:36 bz2.so<br>
-rwxr-xr-x 1 root root 14232 Mar 17 20:36 ff.so<br>
-rwxr-xr-x 1 root root 14232 Mar 17 20:36 gif.so<br>
-rwxr-xr-x 1 root root 14232 Mar 17 20:36 heif.so<br>
-rwxr-xr-x 1 root root 14232 Mar 17 20:36 ico.so<br>
-rwxr-xr-x 1 root root 14232 Mar 17 20:36 id3.so<br>
-rwxr-xr-x 1 root root 14232 Mar 17 20:36 j2k.so<br>
-rwxr-xr-x 1 root root 14232 Mar 17 20:36 jpeg.so<br>
-rwxr-xr-x 1 root root 14232 Mar 17 20:36 jxl.so<br>
-rwxr-xr-x 1 root root 18328 Mar 17 20:36 lbm.so<br>
-rwxr-xr-x 1 root root 14232 Mar 17 20:36 lzma.so<br>
-rwxr-xr-x 1 root root 18328 Mar 17 20:36 png.so<br>
-rwxr-xr-x 1 root root 18328 Mar 17 20:36 pnm.so<br>
-rwxr-xr-x 1 root root 14232 Mar 17 20:36 ps.so<br>
-rwxr-xr-x 1 root root 14232 Mar 17 20:36 qoi.so<br>
-rwxr-xr-x 1 root root 14232 Mar 17 20:36 svg.so<br>
-rwxr-xr-x 1 root root 14232 Mar 17 20:36 tga.so<br>
-rwxr-xr-x 1 root root 18328 Mar 17 20:36 tiff.so<br>
-rwxr-xr-x 1 root root 14232 Mar 17 20:36 webp.so<br>
-rwxr-xr-x 1 root root 14232 Mar 17 20:36 xbm.so<br>
-rwxr-xr-x 1 root root 18328 Mar 17 20:36 xpm.so<br>
-rwxr-xr-x 1 root root 14232 Mar 17 20:36 zlib.so<br>
<br>
<br>
<br>
The test programs that come with it seem to work - under /usr/bin - they<br=
>
are imlib2_*=C2=A0 like imlib2_view etc.<br>
<br>
Trying to figure this out, I by passed cpan and tried to install the<br>
Perl by hand and it refused to build<br>
<br>
Code: [Select]<br>
<br>
[ruben@www3 Image-Imlib2-2.03-2]$ perl Makefile.PL<br>
# running Build.PL<br>
You must install the imlib2 library before you can install<br>
Image::Imlib2. You can obtain imlib2 from<br>
<a href=3D"http://sourceforge.net/projects/enlightenment/" rel=3D"noreferre=
r" target=3D"_blank">http://sourceforge.net/projects/enlightenment/</a><br>
<br>
Alternatively, if you have downloaded and installed imlib2 and this<br>
still will not work, modify the $CONFIG variable inside Build.PL to<br>
point to the imlib2-config program that provides.<br>
<br>
<br>
<br>
The change file of imlib2 says this program has been removed and<br>
returned and then recently removed again.=C2=A0 Scouring the net for a<br>
solution I turned up this:<br>
<br>
<a href=3D"https://stackoverflow.com/questions/66261506/imlib2-saving-image=
-returns-imlib-load-error-no-loader-for-file-format#66264954" rel=3D"norefe=
rrer" target=3D"_blank">https://stackoverflow.com/questions/66261506/imlib2=
-saving-image-returns-imlib-load-error-no-loader-for-file-format#66264954</=
a><br>
<br>
Quote<br>
<br>
=C2=A0 =C2=A0 Ok, after digging a little deeper into the imlib2 source it t=
urns<br>
out that the loaders are always looked up as shared objects. I thought<br>
the loaders are also compiled into the static lib, but I was wrong.<br>
<br>
=C2=A0 =C2=A0 Either I can set the directory by specifying IMLIB2_LOADER_PA=
TH or<br>
by putting them into the default loader path which is<br>
/usr/local/lib/imlib2/loaders in the self compiled version.<br>
<br>
<br>
I don&#39;t think adding an environmental variable to a program called by<b=
r>
Apache is a good idea.<br>
<br>
It is in the Arch AUR but hasn&#39;t been changed since 2015<br>
<br>
<a href=3D"https://packages.artixlinux.org/packages/world/x86_64/imlib2/" r=
el=3D"noreferrer" target=3D"_blank">https://packages.artixlinux.org/package=
s/world/x86_64/imlib2/</a><br>
<br>
I don&#39;t see anything in the package build that can be useful to fix<br>
this, but I am not a pacman expert.<br>
<br>
<br>
<br>
-- <br>
So many immigrant groups have swept through our town<br>
that Brooklyn, like Atlantis, reaches mythological<br>
proportions in the mind of the world - RI Safir 1998<br>
<a href=3D"http://www.mrbrklyn.com" rel=3D"noreferrer" target=3D"_blank">ht=
tp://www.mrbrklyn.com</a><br>
DRM is THEFT - We are the STAKEHOLDERS - RI Safir 2002<br>
<br>
<a href=3D"http://www.nylxs.com" rel=3D"noreferrer" target=3D"_blank">http:=
//www.nylxs.com</a> - Leadership Development in Free Software<br>
<a href=3D"http://www.brooklyn-living.com" rel=3D"noreferrer" target=3D"_bl=
ank">http://www.brooklyn-living.com</a><br>
<br>
Being so tracked is for FARM ANIMALS and extermination camps,<br>
but incompatible with living as a free human being. -RI Safir 2013<br>
</blockquote></div>

--000000000000c881b406317f9756--