First of all I'm working with Centos 7 I'm trying to compile the latest darktable and I have overcome sveral problems, including compiling gphoto2, exiv2, etc.
But now when I try to build darktable using the basic instructions here: https://github.com/darktable-org/darktable
mkdir build/ cd build/ cmake -DCMAKE_INSTALL_PREFIX=/opt/darktable/ .. make sudo make install
Whilst trying cmake several times I had to solve a few depencies problems, but the one I'm stuck with is.
Centos7 comes with Exiv2 version 0.23, Darktable requires minimum version 0.24
I removed exiv2 0.23 with dnf and then successfully compiled and installed exiv2 from source to version 0.26.
After a few attempts I configured exiv2 with a --prefix=/usr as darktable said he could not find the libraries.
Now I still have the same problem and cmake exits with the following error:
CMake Error at cmake/modules/FindExiv2.cmake:46 (message): Exiv2 version check failed. Version was found, at least version 0.24 is required Call Stack (most recent call first): src/CMakeLists.txt:292 (find_package) -- Configuring incomplete, errors occurred! See also "/opt/darktable-2.4.1/build/CMakeFiles/CMakeOutput.log". See also "/opt/darktable-2.4.1/build/CMakeFiles/CMakeError.log".
My knowledge of cmake is next to nothing,but I see that src/CMakeLists.txt line 292 searches for a package which doesn't exist anymore, because I've removed it with dnf.
# Require exiv2 >= 0.24 to make sure everything we need is available find_package(Exiv2 0.24 REQUIRED) include_directories(SYSTEM ${Exiv2_INCLUDE_DIRS}) list(APPEND LIBS ${Exiv2_LIBRARIES}) add_definitions(${Exiv2_DEFINITIONS})
But how can I make cmake look for the exiv2 I've build and installed? And find all the libraries it needs?
Found The Solution!
I realised that under the /usr/lib64/pkgconfig /usr/local/lib/pkgconfig and a few others a lot of *.pc files were.
After my compilation and installation of Exiv2 it placed this exiv2.pc under /usr/lib/pkgconfig/. And it was the only file there.
So I made a soft link in /usr/lib64/pkgconfig to the exiv2.pc file and it did the job, just got another list of issues popping up.