1
1
#set(PLUGIN_COLUMNSTORE "NO" CACHE STRING "Enable ColumnStore engine")
2
2
3
- if ("NO" STREQUAL "${PLUGIN_COLUMNSTORE} " OR NOT ( RPM OR DEB ) )
3
+ if ("NO" STREQUAL "${PLUGIN_COLUMNSTORE} " )
4
4
return ()
5
5
endif ()
6
6
7
+ # this does everything, gets the var from the correct scope, appends new
8
+ # values, sets in the correct scope
9
+ macro (APPEND_FOR_CPACK V )
10
+ get_directory_property (var DIRECTORY columnstore DEFINITION ${V} )
11
+ set (${V} "${var}${ARGN} " PARENT_SCOPE )
12
+ endmacro ()
13
+
7
14
IF (CMAKE_SYSTEM_PROCESSOR STREQUAL "x86_64" OR
8
15
CMAKE_SYSTEM_PROCESSOR STREQUAL "amd64" OR
9
16
CMAKE_SYSTEM_PROCESSOR STREQUAL "i386" OR
@@ -13,15 +20,15 @@ CMAKE_SYSTEM_PROCESSOR STREQUAL "i686")
13
20
14
21
IF (TARGET columnstore )
15
22
# Needed to bump the component changes up to the main scope
16
- SET (CPACK_COMPONENTS_ALL ${CPACK_COMPONENTS_ALL} PARENT_SCOPE )
23
+ APPEND_FOR_CPACK (CPACK_COMPONENTS_ALL )
17
24
IF (RPM )
18
- SET (CPACK_RPM_columnstore-engine_USER_FILELIST ${CPACK_RPM_columnstore-engine_USER_FILELIST} PARENT_SCOPE )
19
- # To untie the python mess across distributions MCS supports.
20
- SET (CPACK_RPM_columnstore-engine_PACKAGE_REQUIRES "${CPACK_RPM_columnstore-engine_PACKAGE_REQUIRES}, MariaDB-server >= 10.5.4, python3, binutils" PARENT_SCOPE )
21
- SET ( CPACK_RPM_columnstore-engine_PRE_INSTALL_SCRIPT_FILE ${CPACK_RPM_columnstore-engine_PRE_INSTALL_SCRIPT_FILE} PARENT_SCOPE )
22
- SET (CPACK_RPM_columnstore-engine_POST_INSTALL_SCRIPT_FILE ${CPACK_RPM_columnstore-engine_POST_INSTALL_SCRIPT_FILE} PARENT_SCOPE )
23
- SET (CPACK_RPM_columnstore-engine_PRE_UNINSTALL_SCRIPT_FILE ${CPACK_RPM_columnstore-engine_PRE_UNINSTALL_SCRIPT_FILE} PARENT_SCOPE )
24
- SET (CPACK_RPM_columnstore-engine_PACKAGE_CONFLICTS "thrift, MariaDB- columnstore-engine, MariaDB-columnstore-platform, MariaDB-columnstore-libs" PARENT_SCOPE )
25
+ APPEND_FOR_CPACK (CPACK_RPM_columnstore-engine_PACKAGE_REQUIRES " binutils net-tools python3" )
26
+ APPEND_FOR_CPACK ( CPACK_RPM_columnstore-engine_USER_FILELIST ";%ignore /var/lib;%ignore /var" )
27
+ APPEND_FOR_CPACK (CPACK_RPM_columnstore-engine_PACKAGE_CONFLICTS " thrift MariaDB-columnstore-platform MariaDB-columnstore-libs" )
28
+ # these three don't have the list semantics, so no append here
29
+ SET (CPACK_RPM_columnstore-engine_PRE_INSTALL_SCRIPT_FILE ${CMAKE_CURRENT_SOURCE_DIR} /columnstore/build/preInstall_storage_engine.sh PARENT_SCOPE )
30
+ SET (CPACK_RPM_columnstore-engine_POST_INSTALL_SCRIPT_FILE ${CMAKE_CURRENT_SOURCE_DIR} /columnstore/build/postInstall_storage_engine.sh PARENT_SCOPE )
31
+ SET (CPACK_RPM_columnstore-engine_PRE_UNINSTALL_SCRIPT_FILE ${CMAKE_CURRENT_SOURCE_DIR} / columnstore/build/preUn_storage_engine.sh PARENT_SCOPE )
25
32
ENDIF ()
26
33
INSTALL_MYSQL_TEST ("${CMAKE_CURRENT_SOURCE_DIR} /mysql-test/" "plugin/columnstore" )
27
34
ENDIF ()
0 commit comments