CSP.hpp File Reference

Plans regarding installation of constraint satisfaction systems. More...

Go to the source code of this file.

Detailed Description

Plans regarding installation of constraint satisfaction systems.

Constraint modelling languages
  • Gecode http://www.gecode.org/
  • Since this is a library, this is very interesting.
  • The current version (28.7.2011) is 3.6.0, and now they also have a reasonable introductory text.
  • Gecode provides an executable which reads "FlatZinc" files and outputs the solution.
  • Minion http://minion.sourceforge.net/
  • This is a single solver, apparently with a powerful input language.
  • Installation:
    builds/CSP> tar -xzf ../../sources/CSP/Minion/minion-0.8.1-src.tar.gz
    builds/CSP> cd minion-0.8.1
    minion-0.8.1> mkdir bin
    minion-0.8.1> cd bin
    minion-0.8.1/bin> BOOST_INCLUDEDIR=$(boost_source_library_okl)/boost BOOST_LIBRARYDIR=$(boost_link_library_okl) cmake ..
    CMake Error: Boost not found -- do you have the iostreams component?
    So we need CMake and Boost --- how to tell Minion about the location of Boost sources and link-libraries? The above should work, but doesn't.
  • The above doesn't work for several reasons :
    • The cmake files present in minion seem to use "HINTS" rather than "PATHS" for "FIND_PATH" and "FIND_LIBRARY" which is only available in versions of cmake >= 2.6.1.
    • One must make sure the "iostreams" library in Boost is built which requires the "bzip2" headers to be installed for it to be built during the Boost installation.
    • As the Boost library files include the gcc compiler version in their names, one must ensure that the gcc version being used by cmake is the local version by setting CC and CXX environment variables. Either that or ensure there are symlinks such as "libboost_iostreams.so" etc, as the "FindBoost.cmake" cmake module detects either.
    Ensuring all of the above and using the following command seems to generate the minion Makefile :
    CC="$(gcc_call_okl)" CXX="$(gcc_call_okl)" BOOST_INCLUDEDIR=$(boost_source_library_okl)/boost/ BOOST_LIBRARYDIR=$(boost_link_library_okl) cmake ..
  • Building minion 0.12 with current (outdated) cmake:
    builds/CSP> tar -xzf ../../sources/CSP/Minion/minion-0.12-src.tar.gz
    builds/CSP> cd minion-0.12
    minion-0.12> mkdir bin
    minion-0.12> cd bin
    minion-0.12/bin> CC="$(gcc_call_okl)" CXX="$(gcc_call_okl)" cmake -DBOOST_ROOT:PATH=$(boost_installation_dir_okl) -DBZIP2_LIBRARIES:PATH=$(bzip2_link_library_okl)/libbz2.a
    Note that /home/csoliver/OKplatform/ExternalSources/Installations/Gcc/4.7.3/bin/gcc are make variables.
  • We should update CMake. DONE (don't provide it ourselves anymore)
  • Seems to be a library.
  • Open-source?

Definition in file CSP.hpp.