How to compile ART?

LibRaw question. I use fully updated Fedora 35. Latest LibRaw built and installed from GitHub:

ibRaw$ ./version.sh
0.21.0-RC1

But when configuring ART I get this:

build$ cmake -DCMAKE_BUILD_TYPE=Release ENABLE_LIBRAW=1 …
– WARNING: gcc 11.3.1 is known to miscompile ART when using --ffp-contract=fast, forcing the option to be off
– CMAKE_BUILD_TYPE: Release
– searching for library exiv2 in /usr/lib64
– result: /usr/lib64/libexiv2.so
– searching for library lensfun in /usr/local/lib64
– result: /usr/local/lib64/liblensfun.so
– Checking for module ‘libraw_r>=0.21’
Package ‘libraw_r’, required by ‘virtual:world’, not found
– libraw not found
– Configuring done
– Generating done
– Build files have been written to: /data/soft/art/build

I do have libraw_r in the standard place:

/usr/local/lib/libraw_r.so.23.0.0
/usr/local/lib/libraw_r.so.23
/usr/local/lib/libraw_r.so
/usr/local/lib/libraw_r.la
/usr/local/lib/libraw_r.a
/usr/local/lib/pkgconfig/libraw_r.pc

And many thanks for creating ART. It is my favorite raw editor even though I’m familiar with RawTherapee and darktable.

Maybe not “standard” on Fedora? The other libs seem to be under /usr/lib64 and /usr/local/lib64

Have you tried moving it to /usr/local/lib64? (You’ll need to update the contents of the .pc files to match as well.)

Edit: perhaps starting with a clean LibRaw folder and doing autoreconf -ifv before configure would do all of this for you correctly to begin with?

Thank you, kmilos, for trying to help.

I actually ran autoreconf first - without it configure does not exist.

I also copied the files:

$ sudo cp -av /usr/local/lib/libraw* /usr/local/lib64
‘/usr/local/lib/libraw.a’ → ‘/usr/local/lib64/libraw.a’
‘/usr/local/lib/libraw.la’ → ‘/usr/local/lib64/libraw.la’
‘/usr/local/lib/libraw_r.a’ → ‘/usr/local/lib64/libraw_r.a’
‘/usr/local/lib/libraw_r.la’ → ‘/usr/local/lib64/libraw_r.la’
‘/usr/local/lib/libraw_r.so’ → ‘/usr/local/lib64/libraw_r.so’
‘/usr/local/lib/libraw_r.so.23’ → ‘/usr/local/lib64/libraw_r.so.23’
‘/usr/local/lib/libraw_r.so.23.0.0’ → ‘/usr/local/lib64/libraw_r.so.23.0.0’
‘/usr/local/lib/libraw.so’ → ‘/usr/local/lib64/libraw.so’
‘/usr/local/lib/libraw.so.23’ → ‘/usr/local/lib64/libraw.so.23’
‘/usr/local/lib/libraw.so.23.0.0’ → ‘/usr/local/lib64/libraw.so.23.0.0’

Updated the .pc file:

libdir=${exec_prefix}/lib64

Still the same error:

– Checking for module ‘libraw_r>=0.21’
– Package ‘libraw_r’, required by ‘virtual:world’, not found
– libraw not found

I tried autoconf again with the flags you suggested, rebuilt and reinstalled LibRaw - still it is not found by ART’s cmake.

I guess I need to delve into how exactly cmake tries to locate this particular module…

Try setting PKG_CONFIG_PATH to the directory where the libraw.pc file got installed

Great, this worked! You are the man, Alberto, many thanks!