1

I'd like to use ExactImage on Fedora 37. As far as I can see, it is neither in the main repository nor in rpmfusion, nor can I find any third-party package.

I tried compiling from source but it appears to be an extremely difficult case. For one thing, the latest release does not compile as-is, but at least this was fixable with Ubuntu/Debian patches. However, I'm still having trouble building/installing AGG. I somehow managed to with CMake, but something must be wrong since I'm getting a linking error with ExactImage.

Has anyone else tried this and can provide steps, or at least a hint how to properly build AGG? Also I'm confused which AGG sources I should use?

3
  • Don't know what AGG is, could you help with links? Generally, I don't like imagemagick too much and propose to use graphicsmagick instead, so learning about exactimage is already a win for me, thanks! (A link to the source code would still have been nice 🙂) Jan 4, 2023 at 23:52
  • AGG is the "Anti-Grain Geometry" graphics library originally developed by Maxim Shemanarev. The thing is, I don't know which sources I should use myself, as AGG is unmaintained. The old official code is on sourceforge, but this appears to be AGG 2.4 and distributions seem to be shipping with some 2.6 version nowadays.
    – mara004
    Jan 5, 2023 at 12:33
  • And the original source code for exactimage is at dl.exactcode.de/oss/exact-image (linked at the bottom of its main page: exactcode.com/opensource/exactimage)
    – mara004
    Sep 20, 2023 at 20:40

2 Answers 2

0

In this case, I suggest you to use alien to convert deb to rpm package.

sudo dnf install alien
sudo alien --to-rpm exactimage_1.0.2-8+b3_amd64.deb

Now you have an rpm package. Next step is to resolve the dependencies, which might be time-consuming, I know.

sudo rpm -i exactimage_1.0.2-8+b3_amd64.rpm 

In my case the following deps were required:
lilmbase25-common
libIex-2_5.so.25()(64bit)
libIlmImf-2_5.so.25()(64bit)
libagg.so.2()(64bit)

These are the apps that rpm installed:
/usr/bin/bardecode
/usr/bin/e2mtiff
/usr/bin/econvert
/usr/bin/edentify
/usr/bin/empty-page
/usr/bin/hocr2pdf
/usr/bin/optimize2bw

2
  • Good to know alien exists, and apparently it worked for your case. However, this appears kind of wonky to me, as the debian package is linked against libs from another distribution that may be at different, incompatible versions compared to Fedora.
    – mara004
    Jan 5, 2023 at 13:21
  • And you'll need to use another foreign package for AGG as well, making dependency / version problems even more likely. I can hardly imagine that this worked out?
    – mara004
    Jan 8, 2023 at 20:13
0

I managed to build from source after all, although it might not be the proper way. Here are some key steps:

  • Download and extract the following archives from Ubuntu:

  • Apply patches for both projects. Assuming you are in the respective source trees: cat ../debian/patches/series | while read PATCHFILE; do echo "../debian/patches/$PATCHFILE"; git apply "../debian/patches/$PATCHFILE"; done

  • Install the dependencies of AGG and ExactImage from Fedora repository (including the corresponding -devel packages of course)

  • Build/install AGG using automake (do not use CMake, it doesn't yield correct results!)

    • bash autogen.sh
    • Manually fix the generated configure script, there's a syntax error. (Or perhaps better, fix the configure.ac source file, lines 104-107, before running autogen.sh)
    • ./configure --disable-gpc --disable-examples --enable-freetype --enable-ctrl --enable-platform --with-pic, make -j4, sudo make install (reason for --disable flags: GPC was removed by Debian for licensing reasons, examples don't compile - if excluding the GPC patch, you might be able to avoid at least one of these)
  • Build/install ExactImage

    • Manually fix image/Makefile (rename -laggfontfreetype_pic to -laggfontfreetype)
    • PKG_CONFIG_PATH=/usr/local/lib/pkgconfig ./configure --without-jasper --without-evas, make -j4, sudo make install (warning: no uninstall command provided!) (reason for --without flags: ExactImage's Jasper code is outdated/incompatible with Fedora's Jasper package; not sure what was wrong with evas)
    • ExactImage doesn't look in /usr/local/lib for some reason, hence create symbolic links for AGG to /usr/lib64: for LIBFILE in /usr/local/lib/libagg*; do sudo ln -s "$LIBFILE" /usr/lib64/$(basename "$LIBFILE"); done (warning: likely not an elegant solution)

Frankly, I'm a bit annoyed I couldn't find sources working out of the box. This was probably the most chaotic and time-taking build process I ever had, especially as it needed many tries to get right. But at least I can use ExactImage now. Next thing I'll do is file a packaging request for ExactImage at Fedora or RPMFusion.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .