[mlpack-svn] [MLPACK] #330: Make xml dependency optional

MLPACK Trac trac at coffeetalk-1.cc.gatech.edu
Wed Feb 19 04:38:19 EST 2014


#330: Make xml dependency optional
------------------------+---------------------------------------------------
 Reporter:  hanslovsky  |        Owner:     
     Type:  wishlist    |       Status:  new
 Priority:  major       |    Milestone:     
Component:  mlpack      |     Keywords:     
 Blocking:              |   Blocked By:     
------------------------+---------------------------------------------------
 In our project we do not use the xml functionality at all and we are
 creating an automated build process. Any addititional dependency means
 more work and fragility, especially as we want to have it work on Linux,
 OS X and Windows. We would much appreciate an option to disable xml
 functionality in mlpack.

 I do not know if it's the best way to do it, but this sounds quite
 straight forward to me:

 -Add a cached switch to CMakeLists.txt, e.g. WITH_XML:BOOL (default = 1).
 -Set a preprocessor definition WITH_XML_COMPILER according to the value of
 the cmake variable WITH_XML
 -Pass the preprocessor definition to the compiler using cmake's
 COMPILE_DEFINITIONS
 -In source and header files ecnlose all xml related stuff in conditional
 preprocessor directives checking the status of WITH_XML_COMPILER.

 COMPILE_DEFINITIONS is explained here:
 http://www.cmake.org/Wiki/CMake_2.6_Notes

-- 
Ticket URL: <http://trac.research.cc.gatech.edu/fastlab/ticket/330>
MLPACK <www.fast-lab.org>
MLPACK is an intuitive, fast, and scalable C++ machine learning library developed at Georgia Tech.


More information about the mlpack-svn mailing list