# This template contains configurations for compiling libDAI with Visual C++
# under Windows (and GNU Make)
#
-# TODO: the latest libDAI version depends on GMP (Windows users can use MPIR)
-# This file has to be updated in order to link with the right GMP/MPIR libraries
-#
# To use it, simply copy this file to 'Makefile.conf' and adapt 'Makefile.conf'
# to your local setup
# MatLab compiled MEX file
ME=.mexw32
+# DIRECTORIES
+# Directories where third party libraries are located
+BOOSTDIR=E:\windows\boost_1_51_0
+MPIRDIR=E:\windows\mpir_251
+
# COMPILER
# Compile using Visual C++ Compiler
CC=cl
# Flags to add in non-debugging mode (if DEBUG=false)
CCNODEBUGFLAGS=/Ox
# Standard include directories
-CCINC=-Iinclude -IE:\windows\boost_1_42_0
+CCINC=-Iinclude -I$(BOOSTDIR) -I$(MPIRDIR)
# LINKER
# Standard libraries to include
LIBS=/link $(LIB)/libdai$(LE)
# For linking with BOOST libraries
-BOOSTLIBS_PO=/LIBPATH:E:\windows\boost_1_42_0\stage\lib
-BOOSTLIBS_UTF=/LIBPATH:E:\windows\boost_1_42_0\stage\lib
+BOOSTLIBS_PO=/LIBPATH:$(BOOSTDIR)\stage\lib
+BOOSTLIBS_UTF=/LIBPATH:$(BOOSTDIR)\stage\lib
# Additional library search paths for linker
# (For some reason, we have to add the VC library path, although it is in the environment)
-CCLIB=/LIBPATH:"C:\Program Files\Microsoft Visual Studio 9.0\VC\ATLMFC\LIB" /LIBPATH:"C:\Program Files\Microsoft Visual Studio 9.0\VC\LIB" /LIBPATH:"C:\Program Files\Microsoft SDKs\Windows\v6.0A\lib"
+CCLIB=/LIBPATH:"C:\Program Files\Microsoft Visual Studio 9.0\VC\ATLMFC\LIB" /LIBPATH:"C:\Program Files\Microsoft Visual Studio 9.0\VC\LIB" /LIBPATH:"C:\Program Files\Microsoft SDKs\Windows\v6.0A\lib" /LIBPATH:"$(MPIRDIR)" mpirxx.lib mpir.lib
# MATLAB
# MatLab version 7.3 (R2006b) or newer?
# Standard include directories for MEX
MEXINC:=$(CCINC)
# Standard libraries to include
-MEXLIBS=
+MEXLIBS:=-lmpirxx -lmpir
# Additional library search paths for MEX
-MEXLIB=
+MEXLIB:=-L"$(BOOSTDIR)\stage\lib" -L"C:\Program Files\Microsoft Visual Studio 9.0\VC\ATLMFC\LIB" -L"C:\Program Files\Microsoft Visual Studio 9.0\VC\LIB" -L"C:\Program Files\Microsoft SDKs\Windows\v6.0A\lib" -L"$(MPIRDIR)"
# SWIG PYTHON INTERFACE
# The following should resolve to the SWIG command
# Location of Python header files
INCLUDE_PYTHON=C:\python2.5
# Location of Boost C++ library header files
-INCLUDE_BOOST=E:\windows\boost_1_42_0
+INCLUDE_BOOST=$(BOOSTDIR)
# CIMG
# CImg version 1.3.0 or newer?
* \section compatibility Compatibility
*
* The code has been developed under Debian GNU/Linux with the GCC compiler suite.
- * libDAI compiles successfully with g++ versions 3.4 up to 4.6.
+ * libDAI compiles successfully with g++ versions 3.4 up to 4.7 (both 32 and 64 bits).
*
- * libDAI has also been successfully compiled with MS Visual Studio 2008 under Windows
- * (but not all build targets are supported yet) and with Cygwin under Windows.
+ * libDAI has also been successfully compiled with MS Visual Studio 2008 under Windows,
+ * MS Visual Studio 2010 under Windows 64, and with Cygwin under Windows.
*
- * Finally, libDAI has been compiled successfully on MacOS X.
+ * Finally, libDAI has been compiled successfully on MacOS X (both 32 and 64 bits).
*
* \section download Downloading libDAI
* The libDAI sources and documentation can be downloaded from the libDAI website: