You've already forked mariadb-columnstore-engine
mirror of
https://github.com/mariadb-corporation/mariadb-columnstore-engine.git
synced 2025-08-05 16:15:50 +03:00
CMakeLists config changes
This commit is contained in:
821
CMakeLists.txt
821
CMakeLists.txt
@@ -25,15 +25,16 @@ MESSAGE(STATUS "Running cmake version ${CMAKE_VERSION}")
|
|||||||
|
|
||||||
#set( CMAKE_VERBOSE_MAKEFILE on )
|
#set( CMAKE_VERBOSE_MAKEFILE on )
|
||||||
|
|
||||||
|
SET (PACKAGE columnstore)
|
||||||
|
SET (VERSION 1.0.2)
|
||||||
#AC_PREREQ(2.59)
|
SET (PACKAGE_NAME columnstore)
|
||||||
#AC_INIT(columnstore, 1.0.2, support@mariadb.com)
|
SET (PACKAGE_TARNAME columnstore)
|
||||||
|
SET (PACKAGE_VERSION 1.0.2)
|
||||||
#AC_CONFIG_MACRO_DIR([m4])
|
SET (PACKAGE_STRING columnstore-1.0.2)
|
||||||
|
SET (PACKAGE_BUGREPORT support@mariadb.com)
|
||||||
|
#SET (PACKAGE_URL "")
|
||||||
|
|
||||||
SET (ENGINE_SRC_DIR ${CMAKE_CURRENT_SOURCE_DIR})
|
SET (ENGINE_SRC_DIR ${CMAKE_CURRENT_SOURCE_DIR})
|
||||||
|
|
||||||
SET (INSTALL_ENGINE "/usr/local/mariadb/columnstore")
|
SET (INSTALL_ENGINE "/usr/local/mariadb/columnstore")
|
||||||
|
|
||||||
#
|
#
|
||||||
@@ -48,51 +49,60 @@ INCLUDE (CheckLibraryExists)
|
|||||||
INCLUDE (CheckFunctionExists)
|
INCLUDE (CheckFunctionExists)
|
||||||
INCLUDE (CheckCCompilerFlag)
|
INCLUDE (CheckCCompilerFlag)
|
||||||
INCLUDE (CheckCXXCompilerFlag)
|
INCLUDE (CheckCXXCompilerFlag)
|
||||||
INCLUDE (CheckCSourceRuns)
|
INCLUDE (CheckCXXSourceRuns)
|
||||||
INCLUDE (CheckSymbolExists)
|
INCLUDE (CheckSymbolExists)
|
||||||
|
INCLUDE (CheckCXXSymbolExists)
|
||||||
INCLUDE (CheckTypeSize)
|
INCLUDE (CheckTypeSize)
|
||||||
|
|
||||||
CHECK_INCLUDE_FILES (alloca.h HAVE_ALLOCA_H)
|
CHECK_INCLUDE_FILE_CXX (alloca.h HAVE_ALLOCA_H)
|
||||||
CHECK_INCLUDE_FILES (arpa/inet.h HAVE_ARPA_INET_H)
|
CHECK_INCLUDE_FILE_CXX (arpa/inet.h HAVE_ARPA_INET_H)
|
||||||
CHECK_INCLUDE_FILES (dlfcn.h HAVE_DLFCN_H)
|
CHECK_INCLUDE_FILE_CXX (dlfcn.h HAVE_DLFCN_H)
|
||||||
CHECK_INCLUDE_FILES (fcntl.h HAVE_FCNTL_H)
|
CHECK_INCLUDE_FILE_CXX (fcntl.h HAVE_FCNTL_H)
|
||||||
CHECK_INCLUDE_FILES (inttypes.h HAVE_INTTYPES_H)
|
CHECK_INCLUDE_FILE_CXX (inttypes.h HAVE_INTTYPES_H)
|
||||||
CHECK_INCLUDE_FILES (limits.h HAVE_LIMITS_H)
|
CHECK_INCLUDE_FILE_CXX (limits.h HAVE_LIMITS_H)
|
||||||
CHECK_INCLUDE_FILES (malloc.h HAVE_MALLOC_H)
|
CHECK_INCLUDE_FILE_CXX (malloc.h HAVE_MALLOC_H)
|
||||||
CHECK_INCLUDE_FILES (memory.h HAVE_MEMORY_H)
|
CHECK_INCLUDE_FILE_CXX (memory.h HAVE_MEMORY_H)
|
||||||
CHECK_INCLUDE_FILES (ncurses.h HAVE_NCURSES_H)
|
CHECK_INCLUDE_FILE_CXX (ncurses.h HAVE_NCURSES_H)
|
||||||
CHECK_INCLUDE_FILES (netdb.h HAVE_NETDB_H)
|
CHECK_INCLUDE_FILE_CXX (netdb.h HAVE_NETDB_H)
|
||||||
CHECK_INCLUDE_FILES (netinet/in.h HAVE_NETINET_IN_H)
|
CHECK_INCLUDE_FILE_CXX (netinet/in.h HAVE_NETINET_IN_H)
|
||||||
CHECK_INCLUDE_FILES (readline/readline.h HAVE_READLINE_READLINE_H)
|
CHECK_INCLUDE_FILE_CXX (readline/readline.h HAVE_READLINE_READLINE_H)
|
||||||
CHECK_INCLUDE_FILES (stddef.h HAVE_STDDEF_H)
|
CHECK_INCLUDE_FILE_CXX (stddef.h HAVE_STDDEF_H)
|
||||||
CHECK_INCLUDE_FILES (stdint.h HAVE_STDINT_H)
|
CHECK_INCLUDE_FILE_CXX (stdint.h HAVE_STDINT_H)
|
||||||
CHECK_INCLUDE_FILES (stdlib.h HAVE_STDLIB_H)
|
CHECK_INCLUDE_FILE_CXX (stdlib.h HAVE_STDLIB_H)
|
||||||
CHECK_INCLUDE_FILES (strings.h HAVE_STRINGS_H)
|
CHECK_INCLUDE_FILE_CXX (strings.h HAVE_STRINGS_H)
|
||||||
CHECK_INCLUDE_FILES (string.h HAVE_STRING_H)
|
CHECK_INCLUDE_FILE_CXX (string.h HAVE_STRING_H)
|
||||||
CHECK_INCLUDE_FILES (syslog.h HAVE_SYSLOG_H)
|
CHECK_INCLUDE_FILE_CXX (syslog.h HAVE_SYSLOG_H)
|
||||||
CHECK_INCLUDE_FILES (sys/file.h HAVE_SYS_FILE_H)
|
CHECK_INCLUDE_FILE_CXX (sys/file.h HAVE_SYS_FILE_H)
|
||||||
CHECK_INCLUDE_FILES (sys/mount.h HAVE_SYS_MOUNT_H)
|
CHECK_INCLUDE_FILE_CXX (sys/mount.h HAVE_SYS_MOUNT_H)
|
||||||
CHECK_INCLUDE_FILES (sys/select.h HAVE_SYS_SELECT_H)
|
CHECK_INCLUDE_FILE_CXX (sys/select.h HAVE_SYS_SELECT_H)
|
||||||
CHECK_INCLUDE_FILES (sys/socket.h HAVE_SYS_SOCKET_H)
|
CHECK_INCLUDE_FILE_CXX (sys/socket.h HAVE_SYS_SOCKET_H)
|
||||||
CHECK_INCLUDE_FILES (sys/statfs.h HAVE_SYS_STATFS_H)
|
CHECK_INCLUDE_FILE_CXX (sys/statfs.h HAVE_SYS_STATFS_H)
|
||||||
CHECK_INCLUDE_FILES (sys/stat.h HAVE_SYS_STAT_H)
|
CHECK_INCLUDE_FILE_CXX (sys/stat.h HAVE_SYS_STAT_H)
|
||||||
CHECK_INCLUDE_FILES (sys/timeb.h HAVE_SYS_TIMEB_H)
|
CHECK_INCLUDE_FILE_CXX (sys/timeb.h HAVE_SYS_TIMEB_H)
|
||||||
CHECK_INCLUDE_FILES (sys/time.h HAVE_SYS_TIME_H)
|
CHECK_INCLUDE_FILE_CXX (sys/time.h HAVE_SYS_TIME_H)
|
||||||
CHECK_INCLUDE_FILES (sys/types.h HAVE_SYS_TYPES_H)
|
CHECK_INCLUDE_FILE_CXX (sys/types.h HAVE_SYS_TYPES_H)
|
||||||
CHECK_INCLUDE_FILES (sys/wait.h HAVE_SYS_WAIT_H)
|
CHECK_INCLUDE_FILE_CXX (sys/wait.h HAVE_SYS_WAIT_H)
|
||||||
CHECK_INCLUDE_FILES (unistd.h HAVE_UNISTD_H)
|
CHECK_INCLUDE_FILE_CXX (unistd.h HAVE_UNISTD_H)
|
||||||
CHECK_INCLUDE_FILES (utime.h HAVE_UTIME_H)
|
CHECK_INCLUDE_FILE_CXX (utime.h HAVE_UTIME_H)
|
||||||
CHECK_INCLUDE_FILES (values.h HAVE_VALUES_H)
|
CHECK_INCLUDE_FILE_CXX (values.h HAVE_VALUES_H)
|
||||||
CHECK_INCLUDE_FILES (vfork.h HAVE_VFORK_H)
|
CHECK_INCLUDE_FILE_CXX (vfork.h HAVE_VFORK_H)
|
||||||
CHECK_INCLUDE_FILES (wchar.h HAVE_WCHAR_H)
|
CHECK_INCLUDE_FILE_CXX (wchar.h HAVE_WCHAR_H)
|
||||||
CHECK_SYMBOL_EXISTS(mbstate_t "wchar.h" HAVE_MBSTATE_T)
|
CHECK_INCLUDE_FILE_CXX (wctype.h HAVE_WCTYPE_H)
|
||||||
CHECK_INCLUDE_FILES (wctype.h HAVE_WCTYPE_H)
|
CHECK_INCLUDE_FILE_CXX (zlib.h HAVE_ZLIB_H)
|
||||||
CHECK_INCLUDE_FILES (zlib.h HAVE_ZLIB_H)
|
|
||||||
|
|
||||||
|
CHECK_FUNCTION_EXISTS (_getb67 GETB1)
|
||||||
|
CHECK_FUNCTION_EXISTS (GETB67 GETB2)
|
||||||
|
CHECK_FUNCTION_EXISTS (getb67 GETB3)
|
||||||
|
|
||||||
|
IF(GETB1)
|
||||||
|
SET (CRAY_STACKSEG_END 1)
|
||||||
|
ELSEIF(GETB2)
|
||||||
|
SET (CRAY_STACKSEG_END 1)
|
||||||
|
ELSEIF(GETB3)
|
||||||
|
SET (CRAY_STACKSEG_END 1)
|
||||||
|
ENDIF()
|
||||||
|
|
||||||
CHECK_FUNCTION_EXISTS (getb67 CRAY_STACKSEG_END)
|
|
||||||
CHECK_FUNCTION_EXISTS (alarm HAVE_ALARM)
|
CHECK_FUNCTION_EXISTS (alarm HAVE_ALARM)
|
||||||
CHECK_FUNCTION_EXISTS (alloca HAVE_ALLOCA)
|
|
||||||
CHECK_FUNCTION_EXISTS (btowc HAVE_BTOWC)
|
CHECK_FUNCTION_EXISTS (btowc HAVE_BTOWC)
|
||||||
CHECK_FUNCTION_EXISTS (dup2 HAVE_DUP2)
|
CHECK_FUNCTION_EXISTS (dup2 HAVE_DUP2)
|
||||||
CHECK_FUNCTION_EXISTS (floor HAVE_FLOOR)
|
CHECK_FUNCTION_EXISTS (floor HAVE_FLOOR)
|
||||||
@@ -110,7 +120,7 @@ CHECK_FUNCTION_EXISTS (malloc HAVE_MALLOC)
|
|||||||
CHECK_FUNCTION_EXISTS (mbsrtowcs HAVE_MBSRTOWCS)
|
CHECK_FUNCTION_EXISTS (mbsrtowcs HAVE_MBSRTOWCS)
|
||||||
CHECK_FUNCTION_EXISTS (memchr HAVE_MEMCHR)
|
CHECK_FUNCTION_EXISTS (memchr HAVE_MEMCHR)
|
||||||
CHECK_FUNCTION_EXISTS (memmove HAVE_MEMMOVE)
|
CHECK_FUNCTION_EXISTS (memmove HAVE_MEMMOVE)
|
||||||
CHECK_FUNCTION_EXISTS (memcpy HAVE_MEMCPY)
|
CHECK_FUNCTION_EXISTS (mempcpy HAVE_MEMPCPY)
|
||||||
CHECK_FUNCTION_EXISTS (memset HAVE_MEMSET)
|
CHECK_FUNCTION_EXISTS (memset HAVE_MEMSET)
|
||||||
CHECK_FUNCTION_EXISTS (mkdir HAVE_MKDIR)
|
CHECK_FUNCTION_EXISTS (mkdir HAVE_MKDIR)
|
||||||
CHECK_FUNCTION_EXISTS (pow HAVE_POW)
|
CHECK_FUNCTION_EXISTS (pow HAVE_POW)
|
||||||
@@ -137,26 +147,617 @@ CHECK_FUNCTION_EXISTS (utime HAVE_UTIME)
|
|||||||
CHECK_FUNCTION_EXISTS (vfork HAVE_VFORK)
|
CHECK_FUNCTION_EXISTS (vfork HAVE_VFORK)
|
||||||
CHECK_FUNCTION_EXISTS (wmempcpy HAVE_WMEMPCPY)
|
CHECK_FUNCTION_EXISTS (wmempcpy HAVE_WMEMPCPY)
|
||||||
|
|
||||||
|
CHECK_CXX_SYMBOL_EXISTS (alloca alloca.h HAVE_ALLOCA)
|
||||||
|
CHECK_CXX_SYMBOL_EXISTS (strerror_r string.h HAVE_DECL_STRERROR_R)
|
||||||
|
CHECK_CXX_SYMBOL_EXISTS (tm sys/time.h TM_IN_SYS_TIME)
|
||||||
|
|
||||||
|
#AC_TYPE_SIGNAL
|
||||||
CHECK_TYPE_SIZE (ptrdiff_t PTRDIFF_T)
|
CHECK_TYPE_SIZE (ptrdiff_t PTRDIFF_T)
|
||||||
|
CHECK_TYPE_SIZE (_Bool __BOOL)
|
||||||
|
CHECK_TYPE_SIZE (mode_t mode_t_test)
|
||||||
|
IF(NOT HAVE_mode_t_test)
|
||||||
|
SET (mode_t int)
|
||||||
|
ENDIF()
|
||||||
|
CHECK_TYPE_SIZE(off_t off_t_test)
|
||||||
|
IF(NOT HAVE_off_t_test)
|
||||||
|
SET (off_t long int)
|
||||||
|
ENDIF()
|
||||||
|
CHECK_TYPE_SIZE(pid_t pid_t_test)
|
||||||
|
IF(NOT HAVE_pid_t_test)
|
||||||
|
SET (pid_t int)
|
||||||
|
ENDIF()
|
||||||
|
CHECK_TYPE_SIZE(size_t size_t_test)
|
||||||
|
IF(NOT HAVE_size_t_test)
|
||||||
|
SET (size_t unsigned int)
|
||||||
|
ENDIF()
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
CHECK_CXX_SOURCE_COMPILES(
|
||||||
|
"#include <stdlib.h>
|
||||||
|
#include <stdarg.h>
|
||||||
|
#include <string.h>
|
||||||
|
#include <float.h>
|
||||||
|
|
||||||
|
int
|
||||||
|
main ()
|
||||||
|
{
|
||||||
|
|
||||||
|
;
|
||||||
|
return 0;
|
||||||
|
}" STDC_HEADERS)
|
||||||
|
|
||||||
|
|
||||||
|
SET (TEST_INCLUDES
|
||||||
|
"
|
||||||
|
#include <stdio.h>")
|
||||||
|
|
||||||
|
IF (HAVE_SYS_TYPES_H)
|
||||||
|
SET ( TEST_INCLUDES
|
||||||
|
"${TEST_INCLUDES}
|
||||||
|
# include <sys/types.h>")
|
||||||
|
ENDIF()
|
||||||
|
IF (HAVE_SYS_STAT_H)
|
||||||
|
SET ( TEST_INCLUDES
|
||||||
|
"${TEST_INCLUDES}
|
||||||
|
# include <sys/stat.h>")
|
||||||
|
ENDIF()
|
||||||
|
IF (STDC_HEADERS)
|
||||||
|
SET ( TEST_INCLUDES
|
||||||
|
"${TEST_INCLUDES}
|
||||||
|
# include <stdlib.h>
|
||||||
|
# include <stddef.h>")
|
||||||
|
ELSE()
|
||||||
|
IF()
|
||||||
|
SET ( TEST_INCLUDES
|
||||||
|
"${TEST_INCLUDES}
|
||||||
|
# include <stdlib.h>")
|
||||||
|
ENDIF()
|
||||||
|
ENDIF()
|
||||||
|
IF (HAVE_STRING_H)
|
||||||
|
IF(NOT STDC_HEADERS)
|
||||||
|
IF (HAVE_MEMORY_H)
|
||||||
|
SET ( TEST_INCLUDES
|
||||||
|
"${TEST_INCLUDES}
|
||||||
|
# include <memory.h>")
|
||||||
|
ENDIF()
|
||||||
|
ENDIF()
|
||||||
|
SET ( TEST_INCLUDES
|
||||||
|
"${TEST_INCLUDES}
|
||||||
|
# include <string.h>")
|
||||||
|
ENDIF()
|
||||||
|
IF (HAVE_STRINGS_H)
|
||||||
|
SET ( TEST_INCLUDES
|
||||||
|
"${TEST_INCLUDES}
|
||||||
|
# include <strings.h>")
|
||||||
|
ENDIF()
|
||||||
|
IF (HAVE_INTTYPES_H)
|
||||||
|
SET ( TEST_INCLUDES
|
||||||
|
"${TEST_INCLUDES}
|
||||||
|
# include <inttypes.h>")
|
||||||
|
ENDIF()
|
||||||
|
IF (HAVE_STDINT_H)
|
||||||
|
SET ( TEST_INCLUDES
|
||||||
|
"${TEST_INCLUDES}
|
||||||
|
# include <stdint.h>")
|
||||||
|
ENDIF()
|
||||||
|
IF (HAVE_UNISTD_H)
|
||||||
|
SET ( TEST_INCLUDES
|
||||||
|
"${TEST_INCLUDES}
|
||||||
|
# include <unistd.h>")
|
||||||
|
ENDIF()
|
||||||
|
|
||||||
|
|
||||||
|
CHECK_CXX_SOURCE_COMPILES(
|
||||||
|
"
|
||||||
|
${TEST_INCLUDES}
|
||||||
|
# include <wchar.h>
|
||||||
|
int
|
||||||
|
main ()
|
||||||
|
{
|
||||||
|
mbstate_t x; return sizeof x;
|
||||||
|
;
|
||||||
|
return 0;
|
||||||
|
}" HAVE_MBSTATE_T)
|
||||||
|
|
||||||
|
|
||||||
|
CHECK_CXX_SOURCE_RUNS(
|
||||||
|
"
|
||||||
|
${TEST_INCLUDES}
|
||||||
|
|
||||||
|
int main ()
|
||||||
|
{
|
||||||
|
struct stat sbuf;
|
||||||
|
return stat (\"\", &sbuf) == 0;
|
||||||
|
;
|
||||||
|
return 0;
|
||||||
|
}" STAT_EMPTY_STRING_BUG)
|
||||||
|
IF (NOT STAT_EMPTY_STRING_BUG)
|
||||||
|
SET (HAVE_STAT_EMPTY_STRING_BUG 1)
|
||||||
|
ENDIF()
|
||||||
|
|
||||||
|
|
||||||
|
CHECK_CXX_SOURCE_COMPILES(
|
||||||
|
"
|
||||||
|
${TEST_INCLUDES}
|
||||||
|
#include <stdbool.h>
|
||||||
|
#ifndef bool
|
||||||
|
\"error: bool is not defined\"
|
||||||
|
#endif
|
||||||
|
#ifndef false
|
||||||
|
\"error: false is not defined\"
|
||||||
|
#endif
|
||||||
|
#if false
|
||||||
|
\"error: false is not 0\"
|
||||||
|
#endif
|
||||||
|
#ifndef true
|
||||||
|
\"error: true is not defined\"
|
||||||
|
#endif
|
||||||
|
#if true != 1
|
||||||
|
\"error: true is not 1\"
|
||||||
|
#endif
|
||||||
|
#ifndef __bool_true_false_are_defined
|
||||||
|
\"error: __bool_true_false_are_defined is not defined\"
|
||||||
|
#endif
|
||||||
|
|
||||||
|
struct s { _Bool s: 1; _Bool t; } s;
|
||||||
|
|
||||||
|
char a[true == 1 ? 1 : -1];
|
||||||
|
char b[false == 0 ? 1 : -1];
|
||||||
|
char c[__bool_true_false_are_defined == 1 ? 1 : -1];
|
||||||
|
char d[(bool) 0.5 == true ? 1 : -1];
|
||||||
|
/* See body of main program for 'e'. */
|
||||||
|
char f[(_Bool) 0.0 == false ? 1 : -1];
|
||||||
|
char g[true];
|
||||||
|
char h[sizeof (_Bool)];
|
||||||
|
char i[sizeof s.t];
|
||||||
|
enum { j = false, k = true, l = false * true, m = true * 256 };
|
||||||
|
/* The following fails for
|
||||||
|
HP aC++/ANSI C B3910B A.05.55 [Dec 04 2003]. */
|
||||||
|
_Bool n[m];
|
||||||
|
char o[sizeof n == m * sizeof n[0] ? 1 : -1];
|
||||||
|
char p[-1 - (_Bool) 0 < 0 && -1 - (bool) 0 < 0 ? 1 : -1];
|
||||||
|
/* Catch a bug in an HP-UX C compiler. See
|
||||||
|
http://gcc.gnu.org/ml/gcc-patches/2003-12/msg02303.html
|
||||||
|
http://lists.gnu.org/archive/html/bug-coreutils/2005-11/msg00161.html
|
||||||
|
*/
|
||||||
|
_Bool q = true;
|
||||||
|
_Bool *pq = &q;
|
||||||
|
|
||||||
|
int
|
||||||
|
main ()
|
||||||
|
{
|
||||||
|
|
||||||
|
bool e = &s;
|
||||||
|
*pq |= q;
|
||||||
|
*pq |= ! q;
|
||||||
|
/* Refer to every declared value, to avoid compiler optimizations. */
|
||||||
|
return (!a + !b + !c + !d + !e + !f + !g + !h + !i + !!j + !k + !!l
|
||||||
|
+ !m + !n + !o + !p + !q + !pq);
|
||||||
|
|
||||||
|
;
|
||||||
|
return 0;
|
||||||
|
}" HAVE_STDBOOL_H)
|
||||||
|
|
||||||
|
IF (HAVE_UTIME_H)
|
||||||
|
CHECK_CXX_SOURCE_COMPILES(
|
||||||
|
"${TEST_INCLUDES}
|
||||||
|
# include <utime.h>
|
||||||
|
int
|
||||||
|
main ()
|
||||||
|
{
|
||||||
|
struct stat s, t;
|
||||||
|
return ! (stat (\"conftest.data\", &s) == 0
|
||||||
|
&& utime (\"conftest.data\", 0) == 0
|
||||||
|
&& stat (\"conftest.data\", &t) == 0
|
||||||
|
&& t.st_mtime >= s.st_mtime
|
||||||
|
&& t.st_mtime - s.st_mtime < 120);
|
||||||
|
;
|
||||||
|
return 0;
|
||||||
|
}" HAVE_UTIME_NULL)
|
||||||
|
ENDIF()
|
||||||
|
|
||||||
|
CHECK_CXX_SOURCE_COMPILES(
|
||||||
|
"
|
||||||
|
${TEST_INCLUDES}
|
||||||
|
int
|
||||||
|
main ()
|
||||||
|
{
|
||||||
|
/* By Ruediger Kuhlmann. */
|
||||||
|
return fork () < 0;
|
||||||
|
;
|
||||||
|
return 0;
|
||||||
|
}" HAVE_WORKING_FORK)
|
||||||
|
|
||||||
|
CHECK_CXX_SOURCE_COMPILES(
|
||||||
|
"${TEST_INCLUDES}
|
||||||
|
#include <sys/wait.h>
|
||||||
|
#ifdef HAVE_VFORK_H
|
||||||
|
include <vfork.h>
|
||||||
|
#endif
|
||||||
|
/* On some sparc systems, changes by the child to local and incoming
|
||||||
|
argument registers are propagated back to the parent. The compiler
|
||||||
|
is told about this with #include <vfork.h>, but some compilers
|
||||||
|
(e.g. gcc -O) don't grok <vfork.h>. Test for this by using a
|
||||||
|
static variable whose address is put into a register that is
|
||||||
|
clobbered by the vfork. */
|
||||||
|
static void
|
||||||
|
#ifdef __cplusplus
|
||||||
|
sparc_address_test (int arg)
|
||||||
|
# else
|
||||||
|
sparc_address_test (arg) int arg;
|
||||||
|
#endif
|
||||||
|
{
|
||||||
|
static pid_t child;
|
||||||
|
if (!child) {
|
||||||
|
child = vfork ();
|
||||||
|
if (child < 0) {
|
||||||
|
perror (\"vfork\");
|
||||||
|
_exit(2);
|
||||||
|
}
|
||||||
|
if (!child) {
|
||||||
|
arg = getpid();
|
||||||
|
write(-1, \"\", 0);
|
||||||
|
_exit (arg);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
int
|
||||||
|
main ()
|
||||||
|
{
|
||||||
|
pid_t parent = getpid ();
|
||||||
|
pid_t child;
|
||||||
|
|
||||||
|
sparc_address_test (0);
|
||||||
|
|
||||||
|
child = vfork ();
|
||||||
|
|
||||||
|
if (child == 0) {
|
||||||
|
/* Here is another test for sparc vfork register problems. This
|
||||||
|
test uses lots of local variables, at least as many local
|
||||||
|
variables as main has allocated so far including compiler
|
||||||
|
temporaries. 4 locals are enough for gcc 1.40.3 on a Solaris
|
||||||
|
4.1.3 sparc, but we use 8 to be safe. A buggy compiler should
|
||||||
|
reuse the register of parent for one of the local variables,
|
||||||
|
since it will think that parent can't possibly be used any more
|
||||||
|
in this routine. Assigning to the local variable will thus
|
||||||
|
munge parent in the parent process. */
|
||||||
|
pid_t
|
||||||
|
p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(),
|
||||||
|
p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid();
|
||||||
|
/* Convince the compiler that p..p7 are live; otherwise, it might
|
||||||
|
use the same hardware register for all 8 local variables. */
|
||||||
|
if (p != p1 || p != p2 || p != p3 || p != p4
|
||||||
|
|| p != p5 || p != p6 || p != p7)
|
||||||
|
_exit(1);
|
||||||
|
|
||||||
|
/* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent
|
||||||
|
from child file descriptors. If the child closes a descriptor
|
||||||
|
before it execs or exits, this munges the parent's descriptor
|
||||||
|
as well. Test for this by closing stdout in the child. */
|
||||||
|
_exit(close(fileno(stdout)) != 0);
|
||||||
|
} else {
|
||||||
|
int status;
|
||||||
|
struct stat st;
|
||||||
|
|
||||||
|
while (wait(&status) != child)
|
||||||
|
;
|
||||||
|
return (
|
||||||
|
/* Was there some problem with vforking? */
|
||||||
|
child < 0
|
||||||
|
|
||||||
|
/* Did the child fail? (This shouldn't happen.) */
|
||||||
|
|| status
|
||||||
|
|
||||||
|
/* Did the vfork/compiler bug occur? */
|
||||||
|
|| parent != getpid()
|
||||||
|
|
||||||
|
/* Did the file descriptor bug occur? */
|
||||||
|
|| fstat(fileno(stdout), &st) != 0
|
||||||
|
);
|
||||||
|
}
|
||||||
|
}" HAVE_WORKING_VFORK)
|
||||||
|
|
||||||
|
IF (NOT HAVE_WORKING_VFORK)
|
||||||
|
SET (VFORK fork)
|
||||||
|
ENDIF()
|
||||||
|
|
||||||
|
CHECK_CXX_SOURCE_COMPILES(
|
||||||
|
"
|
||||||
|
#include <sys/types.h>
|
||||||
|
#include <signal.h>
|
||||||
|
|
||||||
|
int
|
||||||
|
main ()
|
||||||
|
{
|
||||||
|
return *(signal (0, 0)) (0) == 1;
|
||||||
|
;
|
||||||
|
return 0;
|
||||||
|
}" RET_SIGNAL_TYPES)
|
||||||
|
IF (RET_SIGNAL_TYPES)
|
||||||
|
SET (RETSIGTYPE int)
|
||||||
|
ELSE()
|
||||||
|
SET (RETSIGTYPE void)
|
||||||
|
ENDIF()
|
||||||
|
|
||||||
|
#IF(NOT LSTAT_FOLLOWS_SLASHED_SYMLINK)
|
||||||
|
EXECUTE_PROCESS(
|
||||||
|
COMMAND rm -f conftest.sym conftest.file
|
||||||
|
COMMAND touch conftest.file
|
||||||
|
COMMAND ln -s conftest.file conftest.sym
|
||||||
|
WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}
|
||||||
|
)
|
||||||
|
CHECK_CXX_SOURCE_RUNS(
|
||||||
|
"
|
||||||
|
${TEST_INCLUDES}
|
||||||
|
int
|
||||||
|
main ()
|
||||||
|
{
|
||||||
|
struct stat sbuf;
|
||||||
|
/* Linux will dereference the symlink and fail, as required by POSIX.
|
||||||
|
That is better in the sense that it means we will not
|
||||||
|
have to compile and use the lstat wrapper. */
|
||||||
|
return lstat (\"conftest.sym/\", &sbuf) == 0;
|
||||||
|
;
|
||||||
|
return 0;
|
||||||
|
}" LSTAT_FOLLOWS_SLASHED_SYMLINK)
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
SET (SELECT_INCLUDES ${TEST_INCLUDES})
|
||||||
|
IF (HAVE_SYS_SELECT_H)
|
||||||
|
SET (SELECT_INCULDES
|
||||||
|
"${SELECT_INCLUDES}
|
||||||
|
# include <sys/select.h>")
|
||||||
|
ENDIF()
|
||||||
|
IF (HAVE_SYS_SOCKET_H)
|
||||||
|
SET (SELECT_INCULDES
|
||||||
|
"${SELECT_INCLUDES}
|
||||||
|
# include <sys/select.h>")
|
||||||
|
ENDIF()
|
||||||
|
|
||||||
|
|
||||||
|
FOREACH( ARG234 "fd_set *" "int *" "void *")
|
||||||
|
FOREACH( ARG1 "int" "size_t" "unsigned long int" "unsigned int")
|
||||||
|
FOREACH( ARG5 "struct timeval *" "const struct timeval *")
|
||||||
|
CHECK_CXX_SOURCE_COMPILES(
|
||||||
|
"
|
||||||
|
${SELECT_INCLUDES}
|
||||||
|
#ifdef HAVE_SYS_SELECT_H
|
||||||
|
# include <sys/select.h>
|
||||||
|
#endif
|
||||||
|
#ifdef HAVE_SYS_SOCKET_H
|
||||||
|
# include <sys/socket.h>
|
||||||
|
#endif
|
||||||
|
|
||||||
|
int
|
||||||
|
main ()
|
||||||
|
{
|
||||||
|
extern int select (${ARG1},
|
||||||
|
${ARG234}, ${ARG234}, ${ARG234},
|
||||||
|
${ARG5});
|
||||||
|
;
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
" SELECT_ARGS)
|
||||||
|
IF(SELECT_ARGS)
|
||||||
|
SET (SELECT_TYPE_ARG1 ${ARG1})
|
||||||
|
SET (SELECT_TYPE_ARG234 ${ARG234})
|
||||||
|
SET (SELECT_TYPE_ARG5 ${ARG5})
|
||||||
|
BREAK()
|
||||||
|
ENDIF()
|
||||||
|
ENDFOREACH()
|
||||||
|
IF(SELECT_ARGS)
|
||||||
|
BREAK()
|
||||||
|
ENDIF()
|
||||||
|
ENDFOREACH()
|
||||||
|
IF(SELECT_ARGS)
|
||||||
|
BREAK()
|
||||||
|
ENDIF()
|
||||||
|
ENDFOREACH()
|
||||||
|
|
||||||
|
|
||||||
|
CHECK_CXX_SOURCE_COMPILES(
|
||||||
|
"
|
||||||
|
#include <sys/types.h>
|
||||||
|
#include <sys/stat.h>
|
||||||
|
|
||||||
|
#if defined S_ISBLK && defined S_IFDIR
|
||||||
|
extern char c1[S_ISBLK (S_IFDIR) ? -1 : 1];
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if defined S_ISBLK && defined S_IFCHR
|
||||||
|
extern char c2[S_ISBLK (S_IFCHR) ? -1 : 1];
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if defined S_ISLNK && defined S_IFREG
|
||||||
|
extern char c3[S_ISLNK (S_IFREG) ? -1 : 1];
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if defined S_ISSOCK && defined S_IFREG
|
||||||
|
extern char c4[S_ISSOCK (S_IFREG) ? -1 : 1];
|
||||||
|
#endif
|
||||||
|
int main()
|
||||||
|
{
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
" STATS_MACROS_CHECK)
|
||||||
|
IF (NOT STATS_MACROS_CHECK)
|
||||||
|
SET (STAT_MACROS_BROKEN 1)
|
||||||
|
ENDIF()
|
||||||
|
|
||||||
|
CHECK_CXX_SOURCE_COMPILES(
|
||||||
|
"
|
||||||
|
${TEST_INCLUDES}
|
||||||
|
int
|
||||||
|
main ()
|
||||||
|
{
|
||||||
|
|
||||||
|
char buf[100];
|
||||||
|
char x = *strerror_r (0, buf, sizeof buf);
|
||||||
|
char *p = strerror_r (0, buf, sizeof buf);
|
||||||
|
return !p || x;
|
||||||
|
|
||||||
|
;
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
" STRERROR_R_CHAR_P)
|
||||||
|
|
||||||
|
CHECK_CXX_SOURCE_COMPILES(
|
||||||
|
"
|
||||||
|
#include <sys/types.h>
|
||||||
|
#include <sys/time.h>
|
||||||
|
#include <time.h>
|
||||||
|
|
||||||
|
int
|
||||||
|
main ()
|
||||||
|
{
|
||||||
|
if ((struct tm *) 0)
|
||||||
|
return 0;
|
||||||
|
;
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
" TIME_WITH_SYS_TIME)
|
||||||
|
|
||||||
|
|
||||||
|
CHECK_CXX_SOURCE_COMPILES(
|
||||||
|
"
|
||||||
|
int
|
||||||
|
main ()
|
||||||
|
{
|
||||||
|
|
||||||
|
#ifndef __cplusplus
|
||||||
|
/* Ultrix mips cc rejects this sort of thing. */
|
||||||
|
typedef int charset[2];
|
||||||
|
const charset cs = { 0, 0 };
|
||||||
|
/* SunOS 4.1.1 cc rejects this. */
|
||||||
|
char const *const *pcpcc;
|
||||||
|
char **ppc;
|
||||||
|
/* NEC SVR4.0.2 mips cc rejects this. */
|
||||||
|
struct point {int x, y;};
|
||||||
|
static struct point const zero = {0,0};
|
||||||
|
/* AIX XL C 1.02.0.0 rejects this.
|
||||||
|
It does not let you subtract one const X* pointer from another in
|
||||||
|
an arm of an if-expression whose if-part is not a constant
|
||||||
|
expression */
|
||||||
|
const char *g = \"string\";
|
||||||
|
pcpcc = &g + (g ? g-g : 0);
|
||||||
|
/* HPUX 7.0 cc rejects these. */
|
||||||
|
++pcpcc;
|
||||||
|
ppc = (char**) pcpcc;
|
||||||
|
pcpcc = (char const *const *) ppc;
|
||||||
|
{ /* SCO 3.2v4 cc rejects this sort of thing. */
|
||||||
|
char tx;
|
||||||
|
char *t = &tx;
|
||||||
|
char const *s = 0 ? (char *) 0 : (char const *) 0;
|
||||||
|
|
||||||
|
*t++ = 0;
|
||||||
|
if (s) return 0;
|
||||||
|
}
|
||||||
|
{ /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */
|
||||||
|
int x[] = {25, 17};
|
||||||
|
const int *foo = &x[0];
|
||||||
|
++foo;
|
||||||
|
}
|
||||||
|
{ /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
|
||||||
|
typedef const int *iptr;
|
||||||
|
iptr p = 0;
|
||||||
|
++p;
|
||||||
|
}
|
||||||
|
{ /* AIX XL C 1.02.0.0 rejects this sort of thing, saying
|
||||||
|
\"k.c\", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
|
||||||
|
struct s { int j; const int *ap[3]; } bx;
|
||||||
|
struct s *b = &bx; b->j = 5;
|
||||||
|
}
|
||||||
|
{ /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
|
||||||
|
const int foo = 10;
|
||||||
|
if (!foo) return 0;
|
||||||
|
}
|
||||||
|
return !cs[0] && !zero.x;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
;
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
" CONST_CONFORM_CHECK)
|
||||||
|
IF (NOT CONST_CONFORM_CHECK)
|
||||||
|
SET (const "")
|
||||||
|
ENDIF()
|
||||||
|
|
||||||
|
CHECK_CXX_SOURCE_COMPILES(
|
||||||
|
"
|
||||||
|
int
|
||||||
|
main ()
|
||||||
|
{
|
||||||
|
|
||||||
|
volatile int x;
|
||||||
|
int * volatile y = (int *) 0;
|
||||||
|
return !x && !y;
|
||||||
|
;
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
" WORKING_VOLATILE)
|
||||||
|
IF (NOT WORKING_VOLATILE)
|
||||||
|
SET (volatile "")
|
||||||
|
ENDIF()
|
||||||
|
|
||||||
|
FOREACH (RESTRICT_KW __restrict __restrict__ _Restrict restrict)
|
||||||
|
|
||||||
|
CHECK_CXX_SOURCE_COMPILES(
|
||||||
|
"
|
||||||
|
typedef int * int_ptr;
|
||||||
|
int foo (int_ptr ${RESTRICT_KW} ip) {
|
||||||
|
return ip[0];
|
||||||
|
}
|
||||||
|
int
|
||||||
|
main ()
|
||||||
|
{
|
||||||
|
int s[1];
|
||||||
|
int * ${RESTRICT_KW} t = s;
|
||||||
|
t[0] = 0;
|
||||||
|
return foo(t)
|
||||||
|
;
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
" RESTRICT_CHECK)
|
||||||
|
IF (RESTRICT_CHECK)
|
||||||
|
SET (restrict ${RESTRICT_KW})
|
||||||
|
BREAK()
|
||||||
|
ENDIF()
|
||||||
|
ENDFOREACH()
|
||||||
|
|
||||||
|
|
||||||
|
EXECUTE_PROCESS(
|
||||||
|
COMMAND rm -f conftest.data conftest.file conftest.sym
|
||||||
|
WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}
|
||||||
|
)
|
||||||
|
|
||||||
|
|
||||||
#AC_CONFIG_HEADER([config.h])
|
|
||||||
CONFIGURE_FILE(${CMAKE_CURRENT_SOURCE_DIR}/config.h.cmake ${CMAKE_CURRENT_BINARY_DIR}/config.h)
|
CONFIGURE_FILE(${CMAKE_CURRENT_SOURCE_DIR}/config.h.cmake ${CMAKE_CURRENT_BINARY_DIR}/config.h)
|
||||||
|
|
||||||
#AC_ENABLE_STATIC([no])
|
|
||||||
#AC_PROG_LIBTOOL
|
|
||||||
#AC_PROG_INSTALL
|
|
||||||
|
|
||||||
|
|
||||||
#AC_PROG_LEX
|
|
||||||
#if test "x$LEX" = "x:"; then
|
|
||||||
# AC_MSG_ERROR([Could not find a usable lex program!])
|
|
||||||
#fi
|
|
||||||
|
|
||||||
INCLUDE(bison.cmake)
|
INCLUDE(bison.cmake)
|
||||||
|
|
||||||
SET (LEX_EXECUTABLE /usr/bin/flex)
|
FIND_PROGRAM(LEX_EXECUTABLE flex DOC "path to the flex executable")
|
||||||
|
if(NOT LEX_EXECUTABLE)
|
||||||
|
FIND_PROGRAM(LEX_EXECUTABLE lex DOC "path to the lex executable")
|
||||||
|
if(NOT LEX_EXECUTABLE)
|
||||||
|
message(FATAL_ERROR "flex/lex not found!")
|
||||||
|
endif()
|
||||||
|
endif()
|
||||||
|
|
||||||
|
INCLUDE (FindLibXml2)
|
||||||
|
|
||||||
|
if (NOT LIBXML2_FOUND)
|
||||||
|
MESSAGE(FATAL_ERROR "Could not find a usable libxml2 development environment!")
|
||||||
|
endif()
|
||||||
|
|
||||||
|
FIND_PROGRAM(AWK_EXECUTABLE awk DOC "path to the awk executable")
|
||||||
|
if(NOT AWK_EXECUTABLE)
|
||||||
|
message(FATAL_ERROR "awk not found!")
|
||||||
|
endif()
|
||||||
|
|
||||||
|
|
||||||
#AC_PROG_AWK
|
|
||||||
#AC_PROG_CPP
|
#AC_PROG_CPP
|
||||||
#AC_PROG_LN_S
|
#AC_PROG_LN_S
|
||||||
#AC_PROG_MAKE_SET
|
#AC_PROG_MAKE_SET
|
||||||
@@ -189,24 +790,18 @@ SET (LEX_EXECUTABLE /usr/bin/flex)
|
|||||||
# Checks for library functions.
|
# Checks for library functions.
|
||||||
#AC_FUNC_ERROR_AT_LINE
|
#AC_FUNC_ERROR_AT_LINE
|
||||||
#AC_REPLACE_FNMATCH
|
#AC_REPLACE_FNMATCH
|
||||||
#AC_FUNC_FORK
|
|
||||||
#AC_FUNC_MALLOC
|
|
||||||
#AC_FUNC_MEMCMP
|
#AC_FUNC_MEMCMP
|
||||||
#AC_FUNC_MKTIME
|
#AC_FUNC_MKTIME
|
||||||
#AC_FUNC_SELECT_ARGTYPES
|
#AC_FUNC_SELECT_ARGTYPES
|
||||||
#AC_FUNC_SETVBUF_REVERSED
|
#AC_FUNC_SETVBUF_REVERSED
|
||||||
#AC_TYPE_SIGNAL
|
|
||||||
#AC_FUNC_STAT
|
#AC_FUNC_STAT
|
||||||
#AC_FUNC_STRERROR_R
|
|
||||||
#AC_FUNC_STRFTIME
|
#AC_FUNC_STRFTIME
|
||||||
#AC_FUNC_STRTOD
|
#AC_FUNC_STRTOD
|
||||||
#AC_FUNC_UTIME_NULL
|
#AC_FUNC_UTIME_NULL
|
||||||
#AC_CHECK_FUNCS([alarm dup2 floor ftime ftruncate gethostbyname getpagesize gettimeofday inet_ntoa isascii localtime_r memchr memmove memset mkdir pow regcomp rmdir select setenv setlocale socket strcasecmp strchr strcspn strdup strerror strrchr strspn strstr strtol strtoul strtoull utime])
|
|
||||||
|
|
||||||
#AM_PATH_XML2([2.6.26])
|
|
||||||
#if test "x$XML_CPPFLAGS" = "x"; then
|
|
||||||
# AC_MSG_ERROR([Could not find a usable libxml2 development environment!])
|
|
||||||
#fi
|
|
||||||
|
|
||||||
#AC_MSG_CHECKING(whether to enable debugging)
|
#AC_MSG_CHECKING(whether to enable debugging)
|
||||||
#AC_SUBST([idb_cppflags], [' '])
|
#AC_SUBST([idb_cppflags], [' '])
|
||||||
@@ -221,7 +816,7 @@ SET (LEX_EXECUTABLE /usr/bin/flex)
|
|||||||
# AC_SUBST([idb_cflags],['-g0 -O3 -fno-strict-aliasing -Wall'])
|
# AC_SUBST([idb_cflags],['-g0 -O3 -fno-strict-aliasing -Wall'])
|
||||||
# AC_MSG_RESULT(no)
|
# AC_MSG_RESULT(no)
|
||||||
#fi
|
#fi
|
||||||
|
##-ggdb3 -fno-tree-vectorize -DSAFE_MUTEX -DSAFEMALLOC
|
||||||
|
|
||||||
SET(CMAKE_CXX_FLAGS "-g0 -O3 -fno-strict-aliasing -Wall -DHAVE_CONFIG_H")
|
SET(CMAKE_CXX_FLAGS "-g0 -O3 -fno-strict-aliasing -Wall -DHAVE_CONFIG_H")
|
||||||
SET(CMAKE_C_FLAGS "-g0 -O3 -fno-strict-aliasing -Wall -DHAVE_CONFIG_H")
|
SET(CMAKE_C_FLAGS "-g0 -O3 -fno-strict-aliasing -Wall -DHAVE_CONFIG_H")
|
||||||
@@ -248,7 +843,7 @@ SET (ENGINE_MIBDIR "${INSTALL_ENGINE}/share/snmp/mibs")
|
|||||||
SET (ENGINE_TOOLSDIR "${INSTALL_ENGINE}/tools")
|
SET (ENGINE_TOOLSDIR "${INSTALL_ENGINE}/tools")
|
||||||
|
|
||||||
SET (ENGINE_NETSNMP_LIBS "-L${CMAKE_CURRENT_SOURCE_DIR}/net-snmp/net-snmp/snmplib/.libs -L${CMAKE_CURRENT_SOURCE_DIR}/net-snmp/net-snmp/agent/helpers/.libs -L${CMAKE_CURRENT_SOURCE_DIR}/net-snmp/net-snmp/agent/.libs/ -L${CMAKE_CURRENT_SOURCE_DIR}/net-snmp/net-snmp/apps/.libs/ -lnetsnmpmibs -lnetsnmpagent -lnetsnmp -lnetsnmpmibs -lnetsnmphelpers")
|
SET (ENGINE_NETSNMP_LIBS "-L${CMAKE_CURRENT_SOURCE_DIR}/net-snmp/net-snmp/snmplib/.libs -L${CMAKE_CURRENT_SOURCE_DIR}/net-snmp/net-snmp/agent/helpers/.libs -L${CMAKE_CURRENT_SOURCE_DIR}/net-snmp/net-snmp/agent/.libs/ -L${CMAKE_CURRENT_SOURCE_DIR}/net-snmp/net-snmp/apps/.libs/ -lnetsnmpmibs -lnetsnmpagent -lnetsnmp -lnetsnmpmibs -lnetsnmphelpers")
|
||||||
SET (ENGINE_COMMON_LIBS messageqcpp loggingcpp configcpp idbboot boost_idb xml2 pthread rt)
|
SET (ENGINE_COMMON_LIBS messageqcpp loggingcpp configcpp idbboot ${Boost_LIBRARIES} xml2 pthread rt)
|
||||||
SET (ENGINE_OAM_LIBS oamcpp snmpmanager ${ENGINE_NETSNMP_LIBS})
|
SET (ENGINE_OAM_LIBS oamcpp snmpmanager ${ENGINE_NETSNMP_LIBS})
|
||||||
SET (ENGINE_BRM_LIBS brm idbdatafile cacheutils rwlock ${ENGINE_OAM_LIBS} ${ENGINE_COMMON_LIBS})
|
SET (ENGINE_BRM_LIBS brm idbdatafile cacheutils rwlock ${ENGINE_OAM_LIBS} ${ENGINE_COMMON_LIBS})
|
||||||
SET (ENGINE_EXEC_LIBS joblist execplan windowfunction joiner rowgroup funcexp udfsdk dataconvert common compress mysqlcl_idb querystats querytele thrift threadpool ${ENGINE_BRM_LIBS})
|
SET (ENGINE_EXEC_LIBS joblist execplan windowfunction joiner rowgroup funcexp udfsdk dataconvert common compress mysqlcl_idb querystats querytele thrift threadpool ${ENGINE_BRM_LIBS})
|
||||||
@@ -257,6 +852,9 @@ SET (ENGINE_WRITE_LIBS ddlpackageproc ddlpackage dmlpackageproc dmlpackage
|
|||||||
SET (ENGINE_COMMON_LDFLAGS "")
|
SET (ENGINE_COMMON_LDFLAGS "")
|
||||||
|
|
||||||
|
|
||||||
|
FIND_PACKAGE(Boost 1.45.0 COMPONENTS system filesystem thread regex)
|
||||||
|
SET (ENGINE_UTILS_BOOSTIDB_INCLUDE "${Boost_INCLUDE_DIRS}")
|
||||||
|
|
||||||
SET (ENGINE_UTILS_XML_INCLUDE "${CMAKE_CURRENT_SOURCE_DIR}/utils/libxml")
|
SET (ENGINE_UTILS_XML_INCLUDE "${CMAKE_CURRENT_SOURCE_DIR}/utils/libxml")
|
||||||
SET (ENGINE_UTILS_MESSAGEQCPP_INCLUDE "${CMAKE_CURRENT_SOURCE_DIR}/utils/messageqcpp")
|
SET (ENGINE_UTILS_MESSAGEQCPP_INCLUDE "${CMAKE_CURRENT_SOURCE_DIR}/utils/messageqcpp")
|
||||||
SET (ENGINE_WE_SHARED_INCLUDE "${CMAKE_CURRENT_SOURCE_DIR}/writeengine/shared")
|
SET (ENGINE_WE_SHARED_INCLUDE "${CMAKE_CURRENT_SOURCE_DIR}/writeengine/shared")
|
||||||
@@ -286,7 +884,6 @@ SET (ENGINE_DBCON_DMLPKGPROC_INCLUDE "${CMAKE_CURRENT_SOURCE_DIR}/dbcon/dmlpack
|
|||||||
SET (ENGINE_UTILS_CACHEUTILS_INCLUDE "${CMAKE_CURRENT_SOURCE_DIR}/utils/cacheutils")
|
SET (ENGINE_UTILS_CACHEUTILS_INCLUDE "${CMAKE_CURRENT_SOURCE_DIR}/utils/cacheutils")
|
||||||
SET (ENGINE_UTILS_MYSQLCL_INCLUDE "${CMAKE_CURRENT_SOURCE_DIR}/utils/mysqlcl_idb")
|
SET (ENGINE_UTILS_MYSQLCL_INCLUDE "${CMAKE_CURRENT_SOURCE_DIR}/utils/mysqlcl_idb")
|
||||||
SET (ENGINE_UTILS_QUERYTELE_INCLUDE "${CMAKE_CURRENT_SOURCE_DIR}/utils/querytele")
|
SET (ENGINE_UTILS_QUERYTELE_INCLUDE "${CMAKE_CURRENT_SOURCE_DIR}/utils/querytele")
|
||||||
SET (ENGINE_UTILS_BOOSTIDB_INCLUDE "${CMAKE_CURRENT_SOURCE_DIR}/utils/boost_idb")
|
|
||||||
SET (ENGINE_UTILS_THRIFT_INCLUDE "${CMAKE_CURRENT_SOURCE_DIR}/utils/thrift")
|
SET (ENGINE_UTILS_THRIFT_INCLUDE "${CMAKE_CURRENT_SOURCE_DIR}/utils/thrift")
|
||||||
SET (ENGINE_UTILS_JOINER_INCLUDE "${CMAKE_CURRENT_SOURCE_DIR}/utils/joiner")
|
SET (ENGINE_UTILS_JOINER_INCLUDE "${CMAKE_CURRENT_SOURCE_DIR}/utils/joiner")
|
||||||
SET (ENGINE_UTILS_THREADPOOL_INCLUDE "${CMAKE_CURRENT_SOURCE_DIR}/utils/threadpool")
|
SET (ENGINE_UTILS_THREADPOOL_INCLUDE "${CMAKE_CURRENT_SOURCE_DIR}/utils/threadpool")
|
||||||
@@ -379,83 +976,3 @@ ADD_SUBDIRECTORY(writeengine/splitter)
|
|||||||
# ./configure --prefix=${INSTALL_ENGINE} --with-mib-modules=disman/event-mib --with-cc=gcc --with-logfile=$(prefix)/log/snmpd.log --with-sys-location=Unknown --with-sys-contact=root@localhost.localdomain --with-default-snmp-version=3 --with-persistent-directory=$(prefix)var/net-snmp --without-openssl --with-ldflags="-Wl,-rpath -Wl,$(prefix)/lib"
|
# ./configure --prefix=${INSTALL_ENGINE} --with-mib-modules=disman/event-mib --with-cc=gcc --with-logfile=$(prefix)/log/snmpd.log --with-sys-location=Unknown --with-sys-contact=root@localhost.localdomain --with-default-snmp-version=3 --with-persistent-directory=$(prefix)var/net-snmp --without-openssl --with-ldflags="-Wl,-rpath -Wl,$(prefix)/lib"
|
||||||
# $(MAKE)
|
# $(MAKE)
|
||||||
#
|
#
|
||||||
#all-local: net-snmp/net-snmp-5.7.3/agent/.libs/libnetsnmpmibs.so
|
|
||||||
# $(MAKE) -C utils
|
|
||||||
# $(MAKE) -C oam/oamcpp
|
|
||||||
# $(MAKE) -C snmpd
|
|
||||||
# $(MAKE) -C dbcon/execplan
|
|
||||||
# $(MAKE) -C dbcon/joblist
|
|
||||||
# $(MAKE) -C versioning
|
|
||||||
# $(MAKE) -C oam
|
|
||||||
# $(MAKE) -C versioning dbrm tools
|
|
||||||
# $(MAKE) -C writeengine/wrapper
|
|
||||||
# $(MAKE) -C writeengine/client
|
|
||||||
# $(MAKE) -C writeengine/xml
|
|
||||||
# $(MAKE) -C writeengine/redistribute
|
|
||||||
# $(MAKE) -C dbcon/ddlpackage
|
|
||||||
# $(MAKE) -C dbcon/ddlpackageproc
|
|
||||||
# $(MAKE) -C dbcon/dmlpackage
|
|
||||||
# $(MAKE) -C dbcon/dmlpackageproc
|
|
||||||
# $(MAKE) -C dbcon
|
|
||||||
# $(MAKE) -C exemgr
|
|
||||||
# $(MAKE) -C ddlproc
|
|
||||||
# $(MAKE) -C dmlproc
|
|
||||||
# $(MAKE) -C procmon
|
|
||||||
# $(MAKE) -C procmgr
|
|
||||||
# $(MAKE) -C oamapps
|
|
||||||
# $(MAKE) -C decomsvr
|
|
||||||
# $(MAKE) -C primitives
|
|
||||||
# $(MAKE) -C tools
|
|
||||||
# $(MAKE) -C writeengine/server
|
|
||||||
# $(MAKE) -C writeengine/bulk
|
|
||||||
# $(MAKE) -C writeengine/splitter
|
|
||||||
# echo $(idb_cxxflags) $(CXXFLAGS) $(DEBUG_FLAGS) > buildFlags
|
|
||||||
#
|
|
||||||
#net-snmp-install:
|
|
||||||
# $(MAKE) -C net-snmp install
|
|
||||||
#
|
|
||||||
#install: net-snmp-install
|
|
||||||
# $(MAKE) -C utils install
|
|
||||||
# $(MAKE) -C oam/oamcpp install
|
|
||||||
# $(MAKE) -C snmpd install
|
|
||||||
# $(MAKE) -C dbcon/execplan install
|
|
||||||
# $(MAKE) -C dbcon/joblist install
|
|
||||||
# $(MAKE) -C versioning install
|
|
||||||
# $(MAKE) -C oam install
|
|
||||||
# $(MAKE) -C versioning dbrm tools install
|
|
||||||
# $(MAKE) -C writeengine/wrapper install
|
|
||||||
# $(MAKE) -C writeengine/client install
|
|
||||||
# $(MAKE) -C writeengine/xml install
|
|
||||||
# $(MAKE) -C writeengine/redistribute install
|
|
||||||
# $(MAKE) -C dbcon/ddlpackage install
|
|
||||||
# $(MAKE) -C dbcon/ddlpackageproc install
|
|
||||||
# $(MAKE) -C dbcon/dmlpackage install
|
|
||||||
# $(MAKE) -C dbcon/dmlpackageproc install
|
|
||||||
# $(MAKE) -C dbcon install
|
|
||||||
# $(MAKE) -C exemgr install
|
|
||||||
# $(MAKE) -C ddlproc install
|
|
||||||
# $(MAKE) -C dmlproc install
|
|
||||||
# $(MAKE) -C procmon install
|
|
||||||
# $(MAKE) -C procmgr install
|
|
||||||
# $(MAKE) -C oamapps install
|
|
||||||
# $(MAKE) -C decomsvr install
|
|
||||||
# $(MAKE) -C primitives install
|
|
||||||
# $(MAKE) -C tools install
|
|
||||||
# $(MAKE) -C writeengine/server install
|
|
||||||
# $(MAKE) -C writeengine/bulk install
|
|
||||||
# $(MAKE) -C writeengine/splitter install
|
|
||||||
#
|
|
||||||
#compile: all-local
|
|
||||||
#
|
|
||||||
#test:
|
|
||||||
#
|
|
||||||
#coverage:
|
|
||||||
#
|
|
||||||
#leakcheck:
|
|
||||||
#
|
|
||||||
#docs:
|
|
||||||
#
|
|
||||||
#clean:
|
|
||||||
# rm -f net-snmp.built; \
|
|
||||||
# find . -name \*.d.* -o -name \*.so -o -name \*.a -o -name \*.o -o -name \*.lib -o -name \*.sa -o -name \*.lo -o -name \*.la -exec rm {} \; -print
|
|
||||||
#
|
|
||||||
|
@@ -285,42 +285,38 @@
|
|||||||
slash. */
|
slash. */
|
||||||
#cmakedefine LSTAT_FOLLOWS_SLASHED_SYMLINK 1
|
#cmakedefine LSTAT_FOLLOWS_SLASHED_SYMLINK 1
|
||||||
|
|
||||||
/* Define to the sub-directory in which libtool stores uninstalled libraries.
|
|
||||||
*/
|
|
||||||
#cmakedefine LT_OBJDIR
|
|
||||||
|
|
||||||
/* Name of package */
|
/* Name of package */
|
||||||
#cmakedefine PACKAGE
|
#cmakedefine PACKAGE ${PACKAGE}
|
||||||
|
|
||||||
/* Define to the address where bug reports for this package should be sent. */
|
/* Define to the address where bug reports for this package should be sent. */
|
||||||
#cmakedefine PACKAGE_BUGREPORT
|
#cmakedefine PACKAGE_BUGREPORT ${PACKAGE_BUGREPORT}
|
||||||
|
|
||||||
/* Define to the full name of this package. */
|
/* Define to the full name of this package. */
|
||||||
#cmakedefine PACKAGE_NAME
|
#cmakedefine PACKAGE_NAME ${PACKAGE_NAME}
|
||||||
|
|
||||||
/* Define to the full name and version of this package. */
|
/* Define to the full name and version of this package. */
|
||||||
#cmakedefine PACKAGE_STRING
|
#cmakedefine PACKAGE_STRING ${PACKAGE_STRING}
|
||||||
|
|
||||||
/* Define to the one symbol short name of this package. */
|
/* Define to the one symbol short name of this package. */
|
||||||
#cmakedefine PACKAGE_TARNAME
|
#cmakedefine PACKAGE_TARNAME ${PACKAGE_TARNAME}
|
||||||
|
|
||||||
/* Define to the home page for this package. */
|
/* Define to the home page for this package. */
|
||||||
#cmakedefine PACKAGE_URL
|
#cmakedefine PACKAGE_URL ${PACKAGE_URL}
|
||||||
|
|
||||||
/* Define to the version of this package. */
|
/* Define to the version of this package. */
|
||||||
#cmakedefine PACKAGE_VERSION
|
#cmakedefine PACKAGE_VERSION ${PACKAGE_VERSION}
|
||||||
|
|
||||||
/* Define as the return type of signal handlers (`int' or `void'). */
|
/* Define as the return type of signal handlers (`int' or `void'). */
|
||||||
#cmakedefine RETSIGTYPE
|
#cmakedefine RETSIGTYPE ${RETSIGTYPE}
|
||||||
|
|
||||||
/* Define to the type of arg 1 for `select'. */
|
/* Define to the type of arg 1 for `select'. */
|
||||||
#cmakedefine SELECT_TYPE_ARG1
|
#cmakedefine SELECT_TYPE_ARG1 ${SELECT_TYPE_ARG1}
|
||||||
|
|
||||||
/* Define to the type of args 2, 3 and 4 for `select'. */
|
/* Define to the type of args 2, 3 and 4 for `select'. */
|
||||||
#cmakedefine SELECT_TYPE_ARG234
|
#cmakedefine SELECT_TYPE_ARG234 (${SELECT_TYPE_ARG234})
|
||||||
|
|
||||||
/* Define to the type of arg 5 for `select'. */
|
/* Define to the type of arg 5 for `select'. */
|
||||||
#cmakedefine SELECT_TYPE_ARG5
|
#cmakedefine SELECT_TYPE_ARG5 (${SELECT_TYPE_ARG5})
|
||||||
|
|
||||||
/* If using the C implementation of alloca, define if you know the
|
/* If using the C implementation of alloca, define if you know the
|
||||||
direction of stack growth for your system; otherwise it will be
|
direction of stack growth for your system; otherwise it will be
|
||||||
@@ -328,7 +324,7 @@
|
|||||||
STACK_DIRECTION > 0 => grows toward higher addresses
|
STACK_DIRECTION > 0 => grows toward higher addresses
|
||||||
STACK_DIRECTION < 0 => grows toward lower addresses
|
STACK_DIRECTION < 0 => grows toward lower addresses
|
||||||
STACK_DIRECTION = 0 => direction of growth unknown */
|
STACK_DIRECTION = 0 => direction of growth unknown */
|
||||||
#cmakedefine STACK_DIRECTION
|
#cmakedefine STACK_DIRECTION ${STACK_DIRECTION}
|
||||||
|
|
||||||
/* Define to 1 if the `S_IS*' macros in <sys/stat.h> do not work properly. */
|
/* Define to 1 if the `S_IS*' macros in <sys/stat.h> do not work properly. */
|
||||||
#cmakedefine STAT_MACROS_BROKEN 1
|
#cmakedefine STAT_MACROS_BROKEN 1
|
||||||
@@ -337,8 +333,7 @@
|
|||||||
#cmakedefine STDC_HEADERS 1
|
#cmakedefine STDC_HEADERS 1
|
||||||
|
|
||||||
/* Define to 1 if strerror_r returns char *. */
|
/* Define to 1 if strerror_r returns char *. */
|
||||||
/* #cmakedefine STRERROR_R_CHAR_P 1 */
|
#cmakedefine STRERROR_R_CHAR_P 1
|
||||||
#define STRERROR_R_CHAR_P 1
|
|
||||||
|
|
||||||
/* Define to 1 if you can safely include both <sys/time.h> and <time.h>. */
|
/* Define to 1 if you can safely include both <sys/time.h> and <time.h>. */
|
||||||
#cmakedefine TIME_WITH_SYS_TIME 1
|
#cmakedefine TIME_WITH_SYS_TIME 1
|
||||||
@@ -347,7 +342,7 @@
|
|||||||
#cmakedefine TM_IN_SYS_TIME 1
|
#cmakedefine TM_IN_SYS_TIME 1
|
||||||
|
|
||||||
/* Version number of package */
|
/* Version number of package */
|
||||||
#cmakedefine VERSION
|
#cmakedefine VERSION ${VERSION}
|
||||||
|
|
||||||
/* Define to 1 if `lex' declares `yytext' as a `char *' by default, not a
|
/* Define to 1 if `lex' declares `yytext' as a `char *' by default, not a
|
||||||
`char[]'. */
|
`char[]'. */
|
||||||
@@ -372,18 +367,18 @@
|
|||||||
#cmakedefine mbstate_t
|
#cmakedefine mbstate_t
|
||||||
|
|
||||||
/* Define to `int' if <sys/types.h> does not define. */
|
/* Define to `int' if <sys/types.h> does not define. */
|
||||||
#cmakedefine mode_t
|
#cmakedefine mode_t ${mode_t}
|
||||||
|
|
||||||
/* Define to `long int' if <sys/types.h> does not define. */
|
/* Define to `long int' if <sys/types.h> does not define. */
|
||||||
#cmakedefine off_t
|
#cmakedefine off_t ${off_t}
|
||||||
|
|
||||||
/* Define to `int' if <sys/types.h> does not define. */
|
/* Define to `int' if <sys/types.h> does not define. */
|
||||||
#cmakedefine pid_t
|
#cmakedefine pid_t ${pid_t}
|
||||||
|
|
||||||
/* Define to the equivalent of the C99 'restrict' keyword, or to
|
/* Define to the equivalent of the C99 'restrict' keyword, or to
|
||||||
nothing if this is not supported. Do not define if restrict is
|
nothing if this is not supported. Do not define if restrict is
|
||||||
supported directly. */
|
supported directly. */
|
||||||
#cmakedefine restrict
|
#cmakedefine restrict ${restrict}
|
||||||
/* Work around a bug in Sun C++: it does not support _Restrict or
|
/* Work around a bug in Sun C++: it does not support _Restrict or
|
||||||
__restrict__, even though the corresponding Sun C compiler ends up with
|
__restrict__, even though the corresponding Sun C compiler ends up with
|
||||||
"#define restrict _Restrict" or "#define restrict __restrict__" in the
|
"#define restrict _Restrict" or "#define restrict __restrict__" in the
|
||||||
@@ -395,10 +390,10 @@
|
|||||||
#endif
|
#endif
|
||||||
|
|
||||||
/* Define to `unsigned int' if <sys/types.h> does not define. */
|
/* Define to `unsigned int' if <sys/types.h> does not define. */
|
||||||
#cmakedefine size_t
|
#cmakedefine size_t ${size_t}
|
||||||
|
|
||||||
/* Define as `fork' if `vfork' does not work. */
|
/* Define as `fork' if `vfork' does not work. */
|
||||||
#cmakedefine vfork
|
#cmakedefine vfork ${VFORK}
|
||||||
|
|
||||||
/* Define to empty if the keyword `volatile' does not work. Warning: valid
|
/* Define to empty if the keyword `volatile' does not work. Warning: valid
|
||||||
code using `volatile' can become incorrect without. Disable with care. */
|
code using `volatile' can become incorrect without. Disable with care. */
|
||||||
|
@@ -8,7 +8,7 @@ set(DecomSvr_SRCS quicklz.c server.cpp)
|
|||||||
|
|
||||||
add_executable(DecomSvr ${DecomSvr_SRCS})
|
add_executable(DecomSvr ${DecomSvr_SRCS})
|
||||||
|
|
||||||
target_link_libraries(DecomSvr ${ENGINE_LDFLAGS} boost_idb pthread rt)
|
target_link_libraries(DecomSvr ${ENGINE_LDFLAGS} ${Boost_LIBRARIES} pthread rt)
|
||||||
|
|
||||||
install(TARGETS DecomSvr DESTINATION ${ENGINE_BINDIR})
|
install(TARGETS DecomSvr DESTINATION ${ENGINE_BINDIR})
|
||||||
|
|
||||||
|
@@ -1,5 +1,5 @@
|
|||||||
|
|
||||||
add_subdirectory(boost_idb)
|
#add_subdirectory(boost_idb)
|
||||||
add_subdirectory(startup)
|
add_subdirectory(startup)
|
||||||
add_subdirectory(common)
|
add_subdirectory(common)
|
||||||
add_subdirectory(configcpp)
|
add_subdirectory(configcpp)
|
||||||
|
Reference in New Issue
Block a user