
On Wed, Dec 30, 2009 at 01:20:46AM +0100, Pau Garcia i Quiles wrote:
I've uploaded the full tarball of libsmi late july 2009 + CMake build system to my website. It's not just one CMakeLists.txt but a few CMakeLists.txt and a few parametrized .cmake files, similar to the .in files for autotools. The "TODOs" at the top of the main CMakeLists.txt are probably outdated.
Thanks for sharing this. Would be cool if people can take a look at this.
To build it:
- Download and install CMake form http://www.cmake.org or your
favorite distribution 2. Download $ wget http://elpauer.org/tmp/libsmi-latejuly09-cmake.tar.bz2 3. Untar $ tar xf libsmi-latejuly09-cmake.tar.bz2 4. Create build directory for out-of-source build $ mkdir build $ cd build 5. Configure $ cmake ../libsmi-latejuly09-cmake
I think this is just 'cmake ..', right?
- Build $ make
You can change options using "ccmake ." (on Unix-based systems) or "cmake-gui ." (on Unix-based systems and Windows). I implemented the very same options that were available at the time with autotools:
[...]
By default, it seems to built static libraries and link the programs against it. Is there something similar to autotools --enable-shared? There is a definition for "smi" in the CMakeLists but the rules for the binaries depend on "smi_static". Is there an easy way to change this?
A perhaps more difficult question: Can I get cmake to generate a Makefile for cross compiling using mingw? There seems to be a ""MinGW Makefiles" generator but only for Windows.
/js