Page 1 of 1

Is it possible to use libpng et al. in a clib2 project?

Posted: Fri Nov 29, 2019 5:01 pm
by softwarefailure
I have a clib2 project. To reduce its executable size I'd like my project to dynamically use SOBJS:libpng.so instead of statically linking it against libpng. Is this possible? Or can those shared objects only be used in newlib projects?

Specifically, I'm looking to use libpng.so, libjpeg.so, and libz.so. However, the SDK only provides link libraries for those libraries for newlib so is it not possible to use them with clib2? If it is possible, how to do that?

Re: Is it possible to use libpng et al. in a clib2 project?

Posted: Wed Dec 04, 2019 3:49 pm
by kas1e
As far as i aware: clib2 didnt support sobjes. At least, when we discuss bugs in adtools, it was said to better use clib2 , if we dont need sobjes (which in turn mean no sobjes for clib2 then)

Re: Is it possible to use libpng et al. in a clib2 project?

Posted: Sun Dec 08, 2019 2:44 pm
by softwarefailure
That's too bad. If it had been possible I would have been able to reduce executable size by 1 MB like on MorphOS where we have shared libraries like jfif.library, z.library and png.library that are part of the OS.

Re: Is it possible to use libpng et al. in a clib2 project?

Posted: Sun Dec 08, 2019 4:04 pm
by nbache
softwarefailure wrote:That's too bad. If it had been possible I would have been able to reduce executable size by 1 MB like on MorphOS where we have shared libraries like jfif.library, z.library and png.library that are part of the OS.
Actually, z.library is part of (delivered and maintained with) the OS.

Best regards,

Niels

Re: Is it possible to use libpng et al. in a clib2 project?

Posted: Sun Dec 08, 2019 4:30 pm
by softwarefailure
nbache wrote:Actually, z.library is part of (delivered and maintained with) the OS.
Right, but unfortunately, this is actually rather small. The lion's share is taken up by libpng and libjpeg and those don't seem to be available as shared libraries.