0
5
1
... | ... |
@@ -5,24 +5,27 @@ |
5 | 5 |
ELSE(EXISTS ${CMAKE_SOURCE_DIR}/cmake/version.cmake) |
6 | 6 |
SET(PROJECT_NAME "LEMON") |
7 | 7 |
SET(PROJECT_VERSION "hg-tip" CACHE STRING "LEMON version string.") |
8 | 8 |
ENDIF(EXISTS ${CMAKE_SOURCE_DIR}/cmake/version.cmake) |
9 | 9 |
|
10 | 10 |
PROJECT(${PROJECT_NAME}) |
11 | 11 |
|
12 | 12 |
SET(CMAKE_MODULE_PATH ${CMAKE_SOURCE_DIR}/cmake) |
13 | 13 |
|
14 | 14 |
INCLUDE(FindDoxygen) |
15 | 15 |
INCLUDE(FindGhostscript) |
16 | 16 |
|
17 |
INCLUDE(CheckTypeSize) |
|
18 |
CHECK_TYPE_SIZE("long long" LONG_LONG) |
|
19 |
|
|
17 | 20 |
ENABLE_TESTING() |
18 | 21 |
|
19 | 22 |
ADD_SUBDIRECTORY(lemon) |
20 | 23 |
ADD_SUBDIRECTORY(demo) |
21 | 24 |
ADD_SUBDIRECTORY(doc) |
22 | 25 |
ADD_SUBDIRECTORY(test) |
23 | 26 |
|
24 | 27 |
IF(WIN32) |
25 | 28 |
SET(CPACK_PACKAGE_NAME ${PROJECT_NAME}) |
26 | 29 |
SET(CPACK_PACKAGE_VENDOR "EGRES") |
27 | 30 |
SET(CPACK_PACKAGE_DESCRIPTION_SUMMARY |
28 | 31 |
"LEMON - Library of Efficient Models and Optimization in Networks") |
... | ... |
@@ -15,24 +15,30 @@ |
15 | 15 |
AC_INIT([LEMON], [lemon_version()], [lemon-user@lemon.cs.elte.hu], [lemon]) |
16 | 16 |
AC_CONFIG_AUX_DIR([build-aux]) |
17 | 17 |
AC_CONFIG_MACRO_DIR([m4]) |
18 | 18 |
AM_INIT_AUTOMAKE([-Wall -Werror foreign subdir-objects nostdinc]) |
19 | 19 |
AC_CONFIG_SRCDIR([lemon/list_graph.h]) |
20 | 20 |
AC_CONFIG_HEADERS([config.h lemon/config.h]) |
21 | 21 |
|
22 | 22 |
lx_cmdline_cxxflags_set=${CXXFLAGS+set} |
23 | 23 |
|
24 | 24 |
dnl Do compilation tests using the C++ compiler. |
25 | 25 |
AC_LANG([C++]) |
26 | 26 |
|
27 |
dnl Check the existence of long long type. |
|
28 |
AC_CHECK_TYPE(long long, [long_long_found=yes], [long_long_found=no]) |
|
29 |
if test x"$long_long_found" = x"yes"; then |
|
30 |
AC_DEFINE([HAVE_LONG_LONG], [1], [Define to 1 if you have long long.]) |
|
31 |
fi |
|
32 |
|
|
27 | 33 |
dnl Checks for programs. |
28 | 34 |
AC_PROG_CXX |
29 | 35 |
AC_PROG_CXXCPP |
30 | 36 |
AC_PROG_INSTALL |
31 | 37 |
AC_DISABLE_SHARED |
32 | 38 |
AC_PROG_LIBTOOL |
33 | 39 |
|
34 | 40 |
AC_CHECK_PROG([doxygen_found],[doxygen],[yes],[no]) |
35 | 41 |
AC_CHECK_PROG([gs_found],[gs],[yes],[no]) |
36 | 42 |
|
37 | 43 |
dnl Detect Intel compiler. |
38 | 44 |
AC_MSG_CHECKING([whether we are using the Intel C++ compiler]) |
... | ... |
@@ -107,24 +113,26 @@ |
107 | 113 |
]) |
108 | 114 |
|
109 | 115 |
AC_OUTPUT |
110 | 116 |
|
111 | 117 |
echo |
112 | 118 |
echo '****************************** SUMMARY ******************************' |
113 | 119 |
echo |
114 | 120 |
echo Package version............... : $PACKAGE-$VERSION |
115 | 121 |
echo |
116 | 122 |
echo C++ compiler.................. : $CXX |
117 | 123 |
echo C++ compiles flags............ : $CXXFLAGS |
118 | 124 |
echo |
125 |
echo Compiler supports long long... : $long_long_found |
|
126 |
echo |
|
119 | 127 |
#echo GLPK support.................. : $lx_glpk_found |
120 | 128 |
#echo CPLEX support................. : $lx_cplex_found |
121 | 129 |
#echo SOPLEX support................ : $lx_soplex_found |
122 | 130 |
#echo |
123 | 131 |
echo Build demo programs........... : $enable_demo |
124 | 132 |
echo Build additional tools........ : $enable_tools |
125 | 133 |
echo |
126 | 134 |
echo The packace will be installed in |
127 | 135 |
echo -n ' ' |
128 | 136 |
echo $prefix. |
129 | 137 |
echo |
130 | 138 |
echo '*********************************************************************' |
... | ... |
@@ -87,25 +87,25 @@ |
87 | 87 |
// long |
88 | 88 |
template <typename _Graph, typename _Item> |
89 | 89 |
struct DefaultMapSelector<_Graph, _Item, signed long> { |
90 | 90 |
typedef VectorMap<_Graph, _Item, signed long> Map; |
91 | 91 |
}; |
92 | 92 |
|
93 | 93 |
template <typename _Graph, typename _Item> |
94 | 94 |
struct DefaultMapSelector<_Graph, _Item, unsigned long> { |
95 | 95 |
typedef VectorMap<_Graph, _Item, unsigned long> Map; |
96 | 96 |
}; |
97 | 97 |
|
98 | 98 |
|
99 |
#if defined |
|
99 |
#if defined HAVE_LONG_LONG |
|
100 | 100 |
|
101 | 101 |
// long long |
102 | 102 |
template <typename _Graph, typename _Item> |
103 | 103 |
struct DefaultMapSelector<_Graph, _Item, signed long long> { |
104 | 104 |
typedef VectorMap<_Graph, _Item, signed long long> Map; |
105 | 105 |
}; |
106 | 106 |
|
107 | 107 |
template <typename _Graph, typename _Item> |
108 | 108 |
struct DefaultMapSelector<_Graph, _Item, unsigned long long> { |
109 | 109 |
typedef VectorMap<_Graph, _Item, unsigned long long> Map; |
110 | 110 |
}; |
111 | 111 |
... | ... |
@@ -362,25 +362,25 @@ |
362 | 362 |
static bool positive(Value a) { return 0<a; } |
363 | 363 |
///Returns \c true if \c a is \e surely negative |
364 | 364 |
static bool negative(Value) { return false; } |
365 | 365 |
///Returns \c true if \c a is \e surely non-zero |
366 | 366 |
static bool nonZero(Value a) { return a!=0;} |
367 | 367 |
|
368 | 368 |
///@} |
369 | 369 |
|
370 | 370 |
///Returns zero |
371 | 371 |
static Value zero() {return 0;} |
372 | 372 |
}; |
373 | 373 |
|
374 |
#if |
|
374 |
#if HAVE_LONG_LONG |
|
375 | 375 |
|
376 | 376 |
///Long long integer specialization of Tolerance. |
377 | 377 |
|
378 | 378 |
///Long long integer specialization of Tolerance. |
379 | 379 |
///\warning This class (more exactly, type <tt>long long</tt>) |
380 | 380 |
///is not ansi compatible. |
381 | 381 |
///\sa Tolerance |
382 | 382 |
template<> |
383 | 383 |
class Tolerance<long long int> |
384 | 384 |
{ |
385 | 385 |
public: |
386 | 386 |
///\e |
0 comments (0 inline)