diff options
-rw-r--r-- | support-files/CMakeLists.txt | 36 | ||||
-rw-r--r-- | support-files/policy/selinux/mariadb.te (renamed from support-files/policy/selinux/mysqld-safe.te) | 0 | ||||
-rw-r--r-- | support-files/rpm/server-postin.sh | 2 |
3 files changed, 19 insertions, 19 deletions
diff --git a/support-files/CMakeLists.txt b/support-files/CMakeLists.txt index 40a28e67625..c80de04d069 100644 --- a/support-files/CMakeLists.txt +++ b/support-files/CMakeLists.txt @@ -57,27 +57,27 @@ IF(UNIX) DESTINATION ${inst_location} COMPONENT Server_Scripts) ENDFOREACH() - FIND_PROGRAM(CHECKMODULE checkmodule) - FIND_PROGRAM(SEMODULE_PACKAGE semodule_package) - MARK_AS_ADVANCED(CHECKMODULE SEMODULE_PACKAGE) - - # Build pp files in policy/selinux - IF(CHECKMODULE AND SEMODULE_PACKAGE) - FOREACH(pol mysqld-safe) - SET(src ${CMAKE_CURRENT_SOURCE_DIR}/policy/selinux/${pol}.te) - SET(mod ${CMAKE_CURRENT_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/${pol}-pp.dir/${pol}.mod) - SET(out ${CMAKE_CURRENT_SOURCE_DIR}/policy/selinux/${pol}.pp) - ADD_CUSTOM_COMMAND(OUTPUT ${out} - COMMAND ${CHECKMODULE} -M -m ${src} -o ${mod} - COMMAND ${SEMODULE_PACKAGE} -m ${mod} -o ${out} - DEPENDS ${src}) - ADD_CUSTOM_TARGET(${pol}-pp ALL DEPENDS ${out}) - ENDFOREACH() - ENDIF() - IF(INSTALL_SUPPORTFILESDIR) INSTALL(FILES magic DESTINATION ${inst_location} COMPONENT SupportFiles) INSTALL(DIRECTORY policy DESTINATION ${inst_location} COMPONENT SupportFiles) + FIND_PROGRAM(CHECKMODULE checkmodule) + FIND_PROGRAM(SEMODULE_PACKAGE semodule_package) + MARK_AS_ADVANCED(CHECKMODULE SEMODULE_PACKAGE) + + # Build pp files in policy/selinux + IF(CHECKMODULE AND SEMODULE_PACKAGE) + FOREACH(pol mariadb) + SET(src ${CMAKE_CURRENT_SOURCE_DIR}/policy/selinux/${pol}.te) + SET(tmp ${CMAKE_CURRENT_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/${pol}-pp.dir/${pol}.mod) + SET(out ${CMAKE_CURRENT_BINARY_DIR}/${pol}.pp) + ADD_CUSTOM_COMMAND(OUTPUT ${out} + COMMAND ${CHECKMODULE} -M -m ${src} -o ${tmp} + COMMAND ${SEMODULE_PACKAGE} -m ${tmp} -o ${out} + DEPENDS ${src}) + ADD_CUSTOM_TARGET(${pol}-pp ALL DEPENDS ${out}) + INSTALL(FILES ${out} DESTINATION ${inst_location}/policy/selinux COMPONENT SupportFiles) + ENDFOREACH() + ENDIF() ENDIF() CONFIGURE_FILE(mariadb.pc.in ${CMAKE_CURRENT_BINARY_DIR}/mariadb.pc @ONLY) diff --git a/support-files/policy/selinux/mysqld-safe.te b/support-files/policy/selinux/mariadb.te index 1d3de52c700..1d3de52c700 100644 --- a/support-files/policy/selinux/mysqld-safe.te +++ b/support-files/policy/selinux/mariadb.te diff --git a/support-files/rpm/server-postin.sh b/support-files/rpm/server-postin.sh index bdce35b1d0e..9ef9bec3e0d 100644 --- a/support-files/rpm/server-postin.sh +++ b/support-files/rpm/server-postin.sh @@ -96,7 +96,7 @@ if [ -f /etc/redhat-release ] ; then fi if grep 'CentOS release 6' /etc/redhat-release >/dev/null 2>&1; then if [ -x /usr/sbin/semodule ] ; then - /usr/sbin/semodule -i /usr/share/mysql/policy/selinux/mysqld-safe.pp + /usr/sbin/semodule -i /usr/share/mysql/policy/selinux/mariadb.pp fi fi fi |