From 5f1b46d29803f76c7cad3f2a9b910e5272d0c96a Mon Sep 17 00:00:00 2001 From: Markus Makela Date: Mon, 21 Mar 2016 10:42:12 +0200 Subject: [PATCH] Fixed RPM dependencies The RPMs depended on Perl due to the Nagios scripts that are installed. This dependency is not needed and should be managed by some other means. --- etc/postinst.in | 7 +++++++ plugins/CMakeLists.txt | 6 +++--- 2 files changed, 10 insertions(+), 3 deletions(-) diff --git a/etc/postinst.in b/etc/postinst.in index 7f155e671..37721f575 100755 --- a/etc/postinst.in +++ b/etc/postinst.in @@ -65,4 +65,11 @@ then cp -n @MAXSCALE_CONFDIR@/maxscale.cnf.template @MAXSCALE_CONFDIR@/maxscale.cnf fi +# This will allow us to install the Perl scripts as executable files +# without adding the Perl dependencies +for i in $(find @MAXSCALE_SHAREDIR@/plugins/nagios -name '*.pl') +do + chmod ug+x $i +done + /sbin/ldconfig diff --git a/plugins/CMakeLists.txt b/plugins/CMakeLists.txt index 09575c539..fc18cc602 100644 --- a/plugins/CMakeLists.txt +++ b/plugins/CMakeLists.txt @@ -1,5 +1,5 @@ -install(PROGRAMS nagios/check_maxscale_monitors.pl DESTINATION ${MAXSCALE_SHAREDIR}/plugins/nagios) -install(PROGRAMS nagios/check_maxscale_resources.pl DESTINATION ${MAXSCALE_SHAREDIR}/plugins/nagios) -install(PROGRAMS nagios/check_maxscale_threads.pl DESTINATION ${MAXSCALE_SHAREDIR}/plugins/nagios) +install(FILES nagios/check_maxscale_monitors.pl DESTINATION ${MAXSCALE_SHAREDIR}/plugins/nagios) +install(FILES nagios/check_maxscale_resources.pl DESTINATION ${MAXSCALE_SHAREDIR}/plugins/nagios) +install(FILES nagios/check_maxscale_threads.pl DESTINATION ${MAXSCALE_SHAREDIR}/plugins/nagios) install(FILES nagios/maxscale_commands.cfg DESTINATION ${MAXSCALE_SHAREDIR}/plugins/nagios) install(FILES nagios/server1.cfg DESTINATION ${MAXSCALE_SHAREDIR}/plugins/nagios)