michael@721: ## michael@721: ## roundcube.spec -- OpenPKG RPM Package Specification michael@721: ## Copyright (c) 2012-2012 Michael Schloh von Bennewitz michael@721: ## michael@721: ## Permission to use, copy, modify, and distribute this software for michael@721: ## any purpose with or without fee is hereby granted, provided that michael@721: ## the above copyright notice and this permission notice appear in all michael@721: ## copies. michael@721: ## michael@721: ## THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED michael@721: ## WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF michael@721: ## MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. michael@721: ## IN NO EVENT SHALL THE AUTHORS AND COPYRIGHT HOLDERS AND THEIR michael@721: ## CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, michael@721: ## SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT michael@721: ## LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF michael@721: ## USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND michael@721: ## ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, michael@721: ## OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT michael@721: ## OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF michael@721: ## SUCH DAMAGE. michael@721: ## michael@721: michael@721: # package information michael@721: Name: roundcube michael@721: Summary: Roundcube Webmail Client michael@721: URL: http://www.roundcube.net/ michael@721: Vendor: Thomas Bruederli michael@721: Packager: Michael Schloh von Bennewitz michael@721: Distribution: Europalab Networks Production michael@721: Class: EVAL michael@721: Group: Mail michael@721: License: GPL michael@721: Version: 0.8.1 michael@721: Release: 20120800 michael@721: michael@721: # list of sources michael@721: Source0: http://switch.dl.sourceforge.net/roundcubemail/%{version}/roundcubemail-%{version}.tar.gz michael@721: michael@721: # build information michael@721: BuildPreReq: OpenPKG, openpkg >= 20100101 michael@721: PreReq: OpenPKG, openpkg >= 20100101 michael@721: PreReq: MTA, apache, apache-php michael@721: PreReq: apache-php::with_xml = yes michael@721: PreReq: apache-php::with_json = yes michael@721: PreReq: apache-php::with_exim = yes michael@721: PreReq: apache-php::with_mcrypt = yes michael@721: PreReq: apache-php::with_iconv = yes michael@721: PreReq: apache-php::with_session = yes michael@721: PreReq: apache-php::with_ssl = yes michael@721: michael@721: %description michael@721: Roundcube webmail is a browser based multilingual IMAP client with michael@721: an application-like user interface. It provides full functionality michael@721: expected from a email client, including MIME support, address book, michael@721: folder manipulation, message searching and spell checking. michael@721: michael@721: %track michael@721: prog roundcube = { michael@721: version = %{version} michael@721: url = http://prdownloads.sourceforge.net/roundcubemail/ michael@721: regex = roundcubemail-(\d+\.\d+\.\d+)\.tar\.gz michael@721: } michael@721: michael@721: %prep michael@721: %setup -q -n roundcubemail-%{version} michael@721: %{l_shtool} subst \ michael@721: -e 's;\(E_ALL&~E_NOTICE\));\1&~E_STRICT);' \ michael@721: installer/index.php michael@721: michael@721: %build michael@721: michael@721: %install michael@721: # create directory structure michael@721: %{l_shtool} mkdir -f -p -m 755 \ michael@721: $RPM_BUILD_ROOT%{l_prefix}/share/roundcube michael@721: michael@721: # install program michael@721: cp -rpf \ michael@721: bin config installer logs plugins program skins SQL temp \ michael@721: $RPM_BUILD_ROOT%{l_prefix}/share/roundcube/ michael@721: %{l_shtool} install -c -m 644 \ michael@721: index.php robots.txt \ michael@721: opkg_large.png opkg_small.png \ michael@721: $RPM_BUILD_ROOT%{l_prefix}/share/roundcube/ michael@721: michael@721: # determine package ingredients and tag config files michael@721: #'%attr(755,%{l_nusr},%{l_ngrp}) %{l_prefix}/share/roundcube' michael@721: %{l_rpmtool} files -v -ofiles -r$RPM_BUILD_ROOT \ michael@721: %{l_files_std} \ michael@721: '%attr(775,-,%{l_ngrp}) %{l_prefix}/share/roundcube/temp' michael@721: '%attr(775,-,%{l_ngrp}) %{l_prefix}/share/roundcube/logs' michael@721: michael@721: %files -f files michael@721: michael@721: %clean michael@721: michael@721: %post michael@721: # display information about next steps michael@721: ( echo "Roundcube stores data in SQL and requires an existing" michael@721: echo "local or remote installation of PostgreSQL, MySQL, or" michael@721: echo "SQLite. Please refer to online documentation to carry" michael@721: echo "out the SQL configuration, something like:" michael@721: echo "" michael@721: echo "CREATE DATABASE roundcubemail;" michael@721: echo "CREATE USER 'username'@'localhost' IDENTIFIED BY 'newpwd'; michael@721: echo "GRANT ALL PRIVILEGES ON roundcubemail.* TO username@localhost IDENTIFIED BY 'newpwd';" michael@721: echo "FLUSH PRIVILEGES;" michael@721: ) | %{l_rpmtool} msg -b -t notice michael@721: michael@721: %preun michael@721: # before erase, remove log files michael@721: [ $1 -eq 0 ] || exit 0 michael@721: rm -f $RPM_INSTALL_PREFIX/var/roundcube/log/*.log >/dev/null 2>&1 || true michael@721: