[Solved] Xubuntu 20 > 22.04 - compile error ART and RT

Hello, I did an upgrade from Xubuntu 20.04.5 to Xubuntu 22.04 today, using Xubuntus internal upgrade system (so no fresh install as I always do, just curious to see what should happen… :wink: )

One of the things that happened is that I get the very same compile error for ART and for RawTherapee, see screenshot. Any ideas?

Hmmm… I know I’ve had this before. Are you compiling in an empty build directory?

Hello, I’m compiling in the directory with the git clone of ART.

But I found the solution, rebuilding ART from scratch did the job. Apart from some never seen before error msgs (see below) ART runs fine.

The error states: “No rule to make target /…/libpthread.so, needed for rtgui/ART”. Stopped.

Hmm, not sure if this is solved, ART runs fine but it is the version I compiled this morning, not the one I rebuilt this afternoon…

Solved now.

I’m compiling ART with the build flags mimalloc=ON and LibRaw=on. All that was needed was to rm -rf art & mimalloc & LibRaw and restart from scratch with git pull art & mimalloc & LibRaw. Now ART compiles fine.

I’m compiling RawTherapee without mimalloc and LibRaw. Removing the rawtherapee folder and restarting with git pull RT and make etc. did the job as well.

So everything is fine again. :wink:

You may be able to avoid that ‘start from scratch’ by telling git it should remove all files that are not present in the git repo (such as artefacts from previous builds). I do that all the time before compiling darktable, and the practice has served me well. This should do it:
git clean -d -f -x

2 Likes

Even better - just don’t do in-tree builds, much easier/cleaner to just rm -rf build (if RT/ART support out-of-tree building that is).

1 Like

It is, of course. :smile:

Hello, sorry for my somewhat late reaction, busy etc…

Thanks @kofa for that git command to clean up things, I didn’t know that one.

I’m not a programmer (except some things in Bash), nor a git or cmake hero and I compile RT since 2013 or so with just some simple commands. If I mess things up, I restart from scratch and that always served me.

But I’ve seen since years that warning at the beginning of the compile process as well: “You are making an in-source build, which is discouraged”. I never took notice of that because compiling went fine.

The reaction of @kmilos triggered something however and I took a closer look at how to make out-of-source builds. With the result that I now have a folder named build and another one named debug, with a normal and a debug release in it. Both work fine. I can use the one or the other, while before I recompiled a Release version to a Debug version and if I didn’t need the last one anymore, I recompiled again a release version. Of course having two separate dirs for that is much more practical!

So one little step ahead in becoming a real cmake hero! :wink:

Thank you both for your reactions. :+1:

3 Likes

Think also of all the trees you’re saving now by not downloading the whole repository over and over again :wink:

1 Like

Well, less than once a year I think, so not that many trees saved. :wink: