I suppose the only way to fix this is by deleting everything in /usr/local .
I don't use /usr/local except for linking paths to binaries and I don't suffer from such problems...
I followed your advice and did this
./configure --with-contrib-plugins=all --with-wx-config=/usr/bin/wx-config --prefix=/ssd1/cb/
But I did NOT delete everything in /usr/local as it would cause a lot of rework, so I tried the above instead and then both the build and install succeeded
That must mean the --prefix is passed on to the compiler if invoked during make install. Thanks for the --prefix tip, I didn't know that defines the install dir, but now I know.
p.s. if you're not doing development of codeblocks the best option is to build deb packages. It will take you an hour to learn how to do it, but after that you'll save tons of time, because the builds done with the deb builder are way more reliable than doing it manually.
Yes indeed, deb files would be preferable. I got deb packages when building from Jens' tarballs, but then it is all built into his setup, or so it seems. What I did then was $ sudo dpkg-buildpackage, it gave me a bunch of deb-packages to install.
Can I just replace make with dpkg-buildpackage when building from your github clone? If no, where can I read and learn?