Darktable Ubuntu CR3 support

i’ve been through the manual process of making DT for CR3 support a few times and I’ve passed more or less the same steps every time. Now, with a brand spanking new PC I made a list of all the steps I’ve made. This is literally the first thing done, installation is very fresh (Ubuntu 20.04).
Hope this helps you to get CR3 support, at least it should get you in the right direction.

sudo apt install gimp
sudo add-apt-repository ppa:otto-kesselgulasch/gimp
sudo apt install gimp-gmic
sudo apt-get install -y python3-jsonschema
sudo apt-get install -y exiftool

# Latest llvm is a must
sudo bash -c "$(wget -O - https://apt.llvm.org/llvm.sh)"

mkdir git && cd git

git clone https://github.com/darktable-org/darktable.git
git clone https://github.com/Exiv2/exiv2.git

cd exiv2/

git checkout 0.27-maintenance

mkdir build && cd build

cmake --build .
make tests
sudo make install

sudo rm /lib/x86_64-linux-gnu/libexiv2.so.27
sudo ln -s /usr/local/lib/libexiv2.so.0.27.5 /lib/x86_64-linux-gnu/libexiv2.so.27

cd ../../darktable

# I am adding this in the source just for reference, 
# but I have to manually fetch the branch to get it working.
# Update .gitmodules with your favourite editor:
# [submodule "src/external/rawspeed"]
#         path = src/external/rawspeed
#         url = https://github.com/cytrinox/rawspeed.git
#         branch = canon_cr3
# Then: 

git submodule init
git submodule update --init

cd src/external
rm -rf rawspeed
git clone https://github.com/cytrinox/rawspeed.git
cd rawspeed
git switch canon_cr3

mkdir build && cd build


# Check the output of the above command. 
# If there are important pieces missing you need to get more stuff installed.

sudo make install

# Now you can start Darktable with:
$ /opt/darktable/bin/darktable

Also, if you add the following file and content, you’ll able to start from the apps menu and add a favorite to the Favorite bar.

sudo vi /usr/share/applications/darktable.desktop

[Desktop Entry]
Name=Darktable Raw Editor
1 Like

Could you add why you added that gimp PPA?

Replacing /lib/x86_64-linux-gnu/libexiv2.so.27 might give you an error whenever that libexiv updates.

Did you decide against using a fork on github? The submodule setup could be simpler then.

The gimp-gmic package is not available for 20.04 since earlier this year, it can be found in that PPA. It is an optional package so it can be skipped.
Of course it can break, DT can break too as everything is a dev branch build. So far it hasn’t been a problem and I know where to look if it happens.
There is no Github fork that solves the issues AFAIK and the submodules have not been working as expected to get the CR3 support. This manual bonanza has solved it for several people so far. :slightly_smiling_face:

Thanks @lomo for the walkthrough, I’ll be testing your instructions soon!

He we all need to rant :slight_smile: These things can be so frustrating esp when you feel you are 99% of the way there…