diff options
author | Jörg Frings-Fürst <debian@jff-webhosting.net> | 2023-01-29 15:45:51 +0100 |
---|---|---|
committer | Jörg Frings-Fürst <debian@jff-webhosting.net> | 2023-01-29 15:45:51 +0100 |
commit | 517ad9d4b6eae320b708d03a9340a22893b0cab7 (patch) | |
tree | 37cf1907008821b4155cf90718b8d7b00a9d3461 /build/cmake/CMakeLists.txt | |
parent | 4875a3dd9b183dcd2256e2abfc4ccf7484c233b4 (diff) |
New upstream version 4.0.3upstream/4.0.3
Diffstat (limited to 'build/cmake/CMakeLists.txt')
-rwxr-xr-x | build/cmake/CMakeLists.txt | 65 |
1 files changed, 47 insertions, 18 deletions
diff --git a/build/cmake/CMakeLists.txt b/build/cmake/CMakeLists.txt index 0a192b8..516b9c9 100755 --- a/build/cmake/CMakeLists.txt +++ b/build/cmake/CMakeLists.txt @@ -3,7 +3,7 @@ cmake_minimum_required(VERSION 3.0) project (xbase64) set( xbase_VERSION_MAJOR 4 ) set( xbase_VERSION_MINOR 0 ) -set( xbase_VERSION_PATCH 0 ) +set( xbase_VERSION_PATCH 3 ) MESSAGE( "--- Xbase build for: " ${CMAKE_SYSTEM_NAME} ) MESSAGE( "--- Compiler: " ${CMAKE_CXX_COMPILER_ID} ) @@ -167,7 +167,7 @@ option( XB_EXPRESSION_SUPPORT "Compile Expression support into library" option( XB_NDX_SUPPORT "Compile NDX Index support into library" ON) option( XB_MDX_SUPPORT "Compile MDX Index support into library" ON) option( XB_SQL_SUPPORT "Compile SQL support into library" ON) -option( XB_NDXINF_SUPPORT "Compile NDX INF file support into library" ON) +option( XB_INF_SUPPORT "Compile NDX INF file support into library" ON) option( XB_FILTER_SUPPORT "Compile Filter support into library" ON) @@ -183,10 +183,10 @@ Message( "--- XB_LINKLIST_SUPPORT " ${XB_LINKLIST_SUPPORT}) Message( "--- XB_LOCKING_SUPPORT " ${XB_LOCKING_SUPPORT}) Message( "--- XB_FUNCTION_SUPPORT " ${XB_FUNCTION_SUPPORT}) Message( "--- XB_EXPRESSION_SUPPORT " ${XB_EXPRESSION_SUPPORT}) -Message( "--- XB_NDX_SUPPORT " ${XB_EXPRESSION_SUPPORT}) -Message( "--- XB_MDX_SUPPORT " ${XB_EXPRESSION_SUPPORT}) -Message( "--- XB_SQL_SUPPORT " ${XB_EXPRESSION_SUPPORT}) -Message( "--- XB_NDXINF_SUPPORT " ${XB_NDXINF_SUPPORT}) +Message( "--- XB_NDX_SUPPORT " ${XB_NDX_SUPPORT}) +Message( "--- XB_MDX_SUPPORT " ${XB_MDX_SUPPORT}) +Message( "--- XB_SQL_SUPPORT " ${XB_SQL_SUPPORT}) +Message( "--- XB_INF_SUPPORT " ${XB_INF_SUPPORT}) Message( "--- XB_FILTER_SUPPORT " ${XB_FILTER_SUPPORT}) IF( XB_DEBUG_SUPPORT ) @@ -313,10 +313,10 @@ IF( NOT XB_DBF3_SUPPORT AND NOT XB_DBF4_SUPPORT ) set( XB_DBF4_SUPPORT ON CACHE BOOL "Compile DBase File Format Version 4 support" FORCE ) ENDIF( NOT XB_DBF3_SUPPORT AND NOT XB_DBF4_SUPPORT ) -IF( XB_DBF_SUPPORT AND XB_MEMO_SUPPORT AND NOT XB_LINKLIST_SUPPORT ) +IF( XB_DBF4_SUPPORT AND XB_MEMO_SUPPORT AND NOT XB_LINKLIST_SUPPORT ) MESSAGE( "--- Link List support required for DBF V4 Memo files. Setting to ON" ) set( XB_LINKLIST_SUPPORT ON CACHE BOOL "Compile Link List routines into library" FORCE ) -ENDIF( XB_DBF_SUPPORT AND XB_MEMO_SUPPORT AND NOT XB_LINKLIST_SUPPORT ) +ENDIF( XB_DBF4_SUPPORT AND XB_MEMO_SUPPORT AND NOT XB_LINKLIST_SUPPORT ) IF( XB_LOCKING_SUPPORT AND NOT XB_LINKLIST_SUPPORT ) MESSAGE( "--- Link List support required for locking functions. Setting to ON" ) @@ -334,10 +334,26 @@ IF( XB_EXPRESSION_SUPPORT AND NOT XB_FUNCTION_SUPPORT ) ENDIF( XB_EXPRESSION_SUPPORT AND NOT XB_FUNCTION_SUPPORT ) IF( XB_EXPRESSION_SUPPORT AND NOT XB_LINKLIST_SUPPORT ) - MESSAGE( "--- Function support required for expressions. Setting to ON" ) + MESSAGE( "--- Linklist support required for expressions. Setting to ON" ) set( XB_LINKLIST_SUPPORT ON CACHE BOOL "Compile Link List routines into library" FORCE ) ENDIF( XB_EXPRESSION_SUPPORT AND NOT XB_LINKLIST_SUPPORT ) +IF( XB_SQL_SUPPORT AND NOT XB_MEMO_SUPPORT ) + MESSAGE( "--- Memo support required for SQL. Setting to ON" ) + set( XB_MEMO_SUPPORT ON CACHE BOOL "Compile memo field support into library" FORCE ) +ENDIF( XB_SQL_SUPPORT AND NOT XB_MEMO_SUPPORT ) + +IF( XB_SQL_SUPPORT AND NOT XB_DBF4_SUPPORT ) + MESSAGE( "--- DBF4 support required for SQL. Setting to ON" ) + set( XB_DBF4_SUPPORT ON CACHE BOOL "Compile DBase File Format Version 4 support" FORCE ) +ENDIF( XB_SQL_SUPPORT AND NOT XB_DBF4_SUPPORT ) + +IF( XB_FILTER_SUPPORT AND NOT XB_EXPRESSION_SUPPORT ) + MESSAGE( "--- Expression required for filters. Setting to ON" ) + set( XB_EXPRESSION_SUPPORT ON CACHE BOOL "Compile Expression support into library" FORCE ) +ENDIF( XB_FILTER_SUPPORT AND NOT XB_EXPRESSION_SUPPORT ) + + # Build configuration header file configure_file ( @@ -420,13 +436,16 @@ IF( XB_MDX_SUPPORT ) ENDIF( XB_MDX_SUPPORT ) IF( XB_SQL_SUPPORT ) - set (SOURCES ${SOURCES} ${PROJECT_SOURCE_DIR}/sql/xbsql.cpp ) - set (SOURCES ${SOURCES} ${PROJECT_SOURCE_DIR}/sql/xbinsert.cpp ) - set (SOURCES ${SOURCES} ${PROJECT_SOURCE_DIR}/sql/xbcrtbl.cpp ) + set (SOURCES ${SOURCES} ${PROJECT_SOURCE_DIR}/sql/xbalttbl.cpp ) set (SOURCES ${SOURCES} ${PROJECT_SOURCE_DIR}/sql/xbcrix.cpp ) + set (SOURCES ${SOURCES} ${PROJECT_SOURCE_DIR}/sql/xbcrtbl.cpp ) + set (SOURCES ${SOURCES} ${PROJECT_SOURCE_DIR}/sql/xbdelete.cpp ) set (SOURCES ${SOURCES} ${PROJECT_SOURCE_DIR}/sql/xbdrpix.cpp ) set (SOURCES ${SOURCES} ${PROJECT_SOURCE_DIR}/sql/xbdrptbl.cpp ) + set (SOURCES ${SOURCES} ${PROJECT_SOURCE_DIR}/sql/xbinsert.cpp ) set (SOURCES ${SOURCES} ${PROJECT_SOURCE_DIR}/sql/xbset.cpp ) + set (SOURCES ${SOURCES} ${PROJECT_SOURCE_DIR}/sql/xbsql.cpp ) + set (SOURCES ${SOURCES} ${PROJECT_SOURCE_DIR}/sql/xbselect.cpp ) ENDIF( XB_SQL_SUPPORT ) @@ -523,18 +542,19 @@ add_test( NAME xbFunctions COMMAND xb_test_funcs QUIET ) ENDIF( XB_FUNCTION_SUPPORT ) IF( XB_NDX_SUPPORT ) +IF( XB_DBF3_SUPPORT ) add_executable( xb_test_ndx ${PROJECT_SOURCE_DIR}/tests/xb_test_ndx.cpp ) target_link_libraries( xb_test_ndx ${EXTRA_LIBS}) add_test( NAME xbIxNdx COMMAND xb_test_ndx QUIET ) -add_executable( xb_test_ndx2 ${PROJECT_SOURCE_DIR}/tests/xb_test_ndx2.cpp ) -target_link_libraries( xb_test_ndx2 ${EXTRA_LIBS}) -add_test( NAME xbIxNdx2 COMMAND xb_test_ndx2 QUIET ) +ENDIF( XB_DBF3_SUPPORT ) ENDIF( XB_NDX_SUPPORT ) IF( XB_MDX_SUPPORT ) +IF( XB_DBF4_SUPPORT ) add_executable( xb_test_mdx ${PROJECT_SOURCE_DIR}/tests/xb_test_mdx.cpp ) target_link_libraries( xb_test_mdx ${EXTRA_LIBS}) add_test( NAME xbIxMdx COMMAND xb_test_mdx QUIET ) +ENDIF( XB_DBF4_SUPPORT ) ENDIF( XB_MDX_SUPPORT ) IF( XB_INDEX_SUPPORT ) @@ -603,10 +623,16 @@ IF( XB_EXAMPLES_SUPPORT ) IF( XB_DBF4_SUPPORT ) add_executable( xb_ex_v4_create_dbf ${PROJECT_SOURCE_DIR}/examples/xb_ex_v4_create_dbf.cpp ) target_link_libraries( xb_ex_v4_create_dbf ${EXTRA_LIBS}) + ENDIF( XB_DBF4_SUPPORT ) + + IF( XB_EXPRESSION_SUPPORT ) + add_executable( xb_ex_expression ${PROJECT_SOURCE_DIR}/examples/xb_ex_expression.cpp ) + target_link_libraries( xb_ex_expression ${EXTRA_LIBS}) + ENDIF( XB_EXPRESSION_SUPPORT ) add_executable( xb_ex_v4_upd_dbf ${PROJECT_SOURCE_DIR}/examples/xb_ex_v4_upd_dbf.cpp ) target_link_libraries( xb_ex_v4_upd_dbf ${EXTRA_LIBS}) - ENDIF( XB_DBF4_SUPPORT ) + ENDIF( XB_EXAMPLES_SUPPORT ) @@ -663,7 +689,11 @@ IF( XB_UTILS_SUPPORT ) install (TARGETS xb_pack DESTINATION bin) install (TARGETS xb_undelall DESTINATION bin) install (TARGETS xb_zap DESTINATION bin) + IF( XB_SQL_SUPPORT ) install (TARGETS xb_execsql DESTINATION bin) + ENDIF( XB_SQL_SUPPORT ) + + ENDIF( XB_UTILS_SUPPORT ) @@ -694,8 +724,7 @@ install (FILES include/xbconfig.h DESTINATION include/${CMAKE_PROJECT_NAME}) -SET_TARGET_PROPERTIES( ${XB_LIBNAME} PROPERTIES VERSION 1.0.0 SOVERSION 0 ) -#SET_TARGET_PROPERTIES( ${CMAKE_PROJECT_NAME} PROPERTIES VERSION 1.0.0 SOVERSION 0 ) +SET_TARGET_PROPERTIES( ${XB_LIBNAME} PROPERTIES VERSION 4.0.3 SOVERSION 0 ) IF( EXISTS /usr/local/lib64 ) install (TARGETS ${XB_LIBNAME} DESTINATION lib64/${CMAKE_PROJECT_NAME}) |