BenV's notes

CMake issues

by on Feb.13, 2010, under Morons, Software

I can’t for the life of me begin to imagine why anyone would use cmake as an autoconf alternative. Actually, that’s a lie.
I suppose when you’re too dumb to write an autoconf file (never heard of autoscan, etc), or perhaps when your system doesn’t support autoconf you might look at those alternatives.
Personally I rather see a dir with only a Makefile in that case, because those are easier to fix than cmake.
However, if you DO run into a CMake fuckup, you can put this in your environment to give it a prefix etc.


(put it in a file in /etc/profile.d to have it loaded all the time).
Unfortunately this won’t save you from all CMake builds. For instance I just tried to build Awesome (messing around with a new window manager can be fun sometimes) but when I saw that they use CMake I almost aborted instantly. To make the installation use proper paths you would have to add this to the CMAKE_ARGS for instance:

export CMAKE_ARGS="$CMAKE_ARGS -DAWESOME_DOC_PATH=/usr/share/doc/awesome -DAWESOME_MAN_PATH=/usr/share/man -DAWESOME_XSESSION_PATH=/usr/share/xsessions -DXDG_CONFIG_HOME=/etc/xdg"


Anyhow, if I still feel like messing around it once it finally compiles I might talk about it later.

Did you know that CMake also fails to create an uninstall target…. gah.
Because oh dear, it might remove useful files from the system. NO SHIT SHERLOCK, WHY DO YOU THINK I WOULD WANT TO RUN AN UNINSTALL?!?!?!
Fortunately it does support DESTDIR, so we can handle the uninstall through our package managers. Phew.


Leave a Reply

You must be logged in to post a comment.


  • 2018 (1)
  • 2016 (1)
  • 2015 (7)
  • 2014 (4)
  • 2013 (11)
  • 2012 (27)
  • 2011 (26)
  • 2010 (25)
  • 2009 (68)