From: Marcin Krol Date: Mon, 9 Nov 2015 11:01:11 +0000 (+0000) Subject: - package subdirs too X-Git-Url: https://git.tld-linux.org/?a=commitdiff_plain;h=363b7ece1e6995e6110609b29a8923d0e22afabb;p=packages%2Fmunin-plugins-contrib.git - package subdirs too --- diff --git a/munin-plugins-contrib.spec b/munin-plugins-contrib.spec index 86f6efb..23924a7 100644 --- a/munin-plugins-contrib.spec +++ b/munin-plugins-contrib.spec @@ -3,7 +3,7 @@ Summary: 3rd-party Munin plugins Summary(pl.UTF-8): Nieoficjalne wtyczki munina Name: munin-plugins-contrib Version: 20151106 -Release: 1 +Release: 2 License: GPL Group: Daemons Source0: https://github.com/munin-monitoring/contrib/tarball/master/%{name}-%{version}.tar.gz @@ -101,8 +101,14 @@ for i in plugins/*; do find $i/* -type f | while read f ; do echo $f | grep -q -E "(example|png|.gitignore)" && continue n=$(echo $f | sed -e 's!'$i'/!!') + d=$(dirname $n) + if [ "$d" != "%{_datadir}/munin/plugins" ]; then + if ! test -d $RPM_BUILD_ROOT%{_datadir}/munin/plugins/$d; then + echo "%dir %{_datadir}/munin/plugins/$d" >>$j.list + install -d $RPM_BUILD_ROOT%{_datadir}/munin/plugins/$d + fi + fi echo "%{_datadir}/munin/plugins/$n" >>$j.list - install -d $RPM_BUILD_ROOT%{_datadir}/munin/plugins/$(dirname $n) install -p $f $RPM_BUILD_ROOT%{_datadir}/munin/plugins/$n done done