diff -r 914043724d20 -r baeac098d68f roundcube/roundcube.spec --- a/roundcube/roundcube.spec Sat Oct 06 16:24:01 2012 +0200 +++ b/roundcube/roundcube.spec Sat Oct 06 20:29:43 2012 +0200 @@ -21,6 +21,9 @@ ## SUCH DAMAGE. ## +# package version +%define V_plug_rcguard 0.2.0-39-g6d98249 + # package information Name: roundcube Summary: Roundcube Webmail Client @@ -31,11 +34,14 @@ Class: EVAL Group: Mail License: GPL -Version: 0.8.1 +Version: 0.8.2 Release: 20120800 # list of sources Source0: http://switch.dl.sourceforge.net/roundcubemail/%{version}/roundcubemail-%{version}.tar.gz +Source1: https://www.github.com/dennylin93/rcguard/tarball/master/dennylin93-rcguard-%{V_plug_rcguard}.tar.gz +Source2: linen_login.png +Patch0: roundcube.patch # build information BuildPreReq: OpenPKG, openpkg >= 20100101 @@ -43,7 +49,7 @@ PreReq: MTA, apache, apache-php PreReq: apache-php::with_xml = yes PreReq: apache-php::with_json = yes -PreReq: apache-php::with_exim = yes +PreReq: apache-php::with_exif = yes PreReq: apache-php::with_mcrypt = yes PreReq: apache-php::with_iconv = yes PreReq: apache-php::with_session = yes @@ -64,9 +70,14 @@ %prep %setup -q -n roundcubemail-%{version} + %setup -q -n roundcubemail-%{version} -D -T -a 1 %{l_shtool} subst \ -e 's;\(E_ALL&~E_NOTICE\));\1&~E_STRICT);' \ installer/index.php + mv dennylin93-rcguard-* plugins/rcguard + %patch -p0 + %{l_shtool} subst %{l_value -s -a} \ + plugins/managesieve/config.inc.php.dist %build @@ -81,15 +92,22 @@ $RPM_BUILD_ROOT%{l_prefix}/share/roundcube/ %{l_shtool} install -c -m 644 \ index.php robots.txt \ - opkg_large.png opkg_small.png \ $RPM_BUILD_ROOT%{l_prefix}/share/roundcube/ + # install other components + ( cd $RPM_BUILD_ROOT%{l_prefix}/share/roundcube/plugins/rcguard/skins \ + && ln -s default larry ) + %{l_shtool} install -c -m 644 \ + %{SOURCE linen_login.png} \ + $RPM_BUILD_ROOT%{l_prefix}/share/roundcube/skins/larry/images/ + # determine package ingredients and tag config files -#'%attr(755,%{l_nusr},%{l_ngrp}) %{l_prefix}/share/roundcube' %{l_rpmtool} files -v -ofiles -r$RPM_BUILD_ROOT \ %{l_files_std} \ - '%attr(775,-,%{l_ngrp}) %{l_prefix}/share/roundcube/temp' - '%attr(775,-,%{l_ngrp}) %{l_prefix}/share/roundcube/logs' + '%attr(775,-,%{l_ngrp}) %{l_prefix}/share/roundcube/temp' \ + '%attr(775,-,%{l_ngrp}) %{l_prefix}/share/roundcube/logs' \ + '%config %attr(640,%{l_mgrp},%{l_ngrp}) %{l_prefix}/share/roundcube/config/*' \ + '%config %attr(640,%{l_mgrp},%{l_ngrp}) %{l_prefix}/share/roundcube/plugins/*/*config*' %files -f files @@ -103,7 +121,7 @@ echo "out the SQL configuration, something like:" echo "" echo "CREATE DATABASE roundcubemail;" - echo "CREATE USER 'username'@'localhost' IDENTIFIED BY 'newpwd'; + echo "CREATE USER 'username'@'localhost' IDENTIFIED BY 'newpwd';" echo "GRANT ALL PRIVILEGES ON roundcubemail.* TO username@localhost IDENTIFIED BY 'newpwd';" echo "FLUSH PRIVILEGES;" ) | %{l_rpmtool} msg -b -t notice