Have you tried to use the packages provided by your distribution?
I can see that fedora 28 has packages for 17.12.
The command is something like "dnf install codeblocks", but you should remove all packages related to codeblocks before you run it, to be safe.