diff --git a/.cvsignore b/.cvsignore deleted file mode 100644 index e69de29..0000000 diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..158eb7e --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +zarafa-webaccess-ajax-6.30.14.tar.gz diff --git a/Makefile b/Makefile deleted file mode 100644 index 185a3c2..0000000 --- a/Makefile +++ /dev/null @@ -1,21 +0,0 @@ -# Makefile for source rpm: zarafa-webaccess -# $Id$ -NAME := zarafa-webaccess -SPECFILE = $(firstword $(wildcard *.spec)) - -define find-makefile-common -for d in common ../common ../../common ; do if [ -f $$d/Makefile.common ] ; then if [ -f $$d/CVS/Root -a -w $$d/Makefile.common ] ; then cd $$d ; cvs -Q update ; fi ; echo "$$d/Makefile.common" ; break ; fi ; done -endef - -MAKEFILE_COMMON := $(shell $(find-makefile-common)) - -ifeq ($(MAKEFILE_COMMON),) -# attept a checkout -define checkout-makefile-common -test -f CVS/Root && { cvs -Q -d $$(cat CVS/Root) checkout common && echo "common/Makefile.common" ; } || { echo "ERROR: I can't figure out how to checkout the 'common' module." ; exit -1 ; } >&2 -endef - -MAKEFILE_COMMON := $(shell $(checkout-makefile-common)) -endif - -include $(MAKEFILE_COMMON) diff --git a/sources b/sources index e69de29..66db136 100644 --- a/sources +++ b/sources @@ -0,0 +1 @@ +914dc200e5ffdfb8cc1ea797d9149730 zarafa-webaccess-ajax-6.30.14.tar.gz diff --git a/zarafa-webaccess.conf b/zarafa-webaccess.conf new file mode 100644 index 0000000..7e6a7f6 --- /dev/null +++ b/zarafa-webaccess.conf @@ -0,0 +1,32 @@ +# +# Zarafa Webaccess featuring a 'Look & Feel' similar to Outlook +# + +Alias /webaccess /usr/share/zarafa-webaccess/ + +# Following Apache and PHP settings need to be set to work correct +# + + # Some apache settings + Options -Indexes +FollowSymLinks + + # Register globals must be off + php_flag register_globals off + + # Magic quotes must be off + php_flag magic_quotes_gpc off + php_flag magic_quotes_runtime off + + # The maximum POST limit. To upload large files, this value must + # be larger than upload_max_filesize. + php_value post_max_size 31M + php_value upload_max_filesize 30M + + # Short open tags must be on + php_flag short_open_tag on + + # Uncomment for debugging purposes only. Make sure Apache/PHP can + # write to this file or no errors will be logged! +# php_flag log_errors on +# php_value error_log /var/lib/zarafa-webaccess/error_log + diff --git a/zarafa-webaccess.spec b/zarafa-webaccess.spec new file mode 100644 index 0000000..2298853 --- /dev/null +++ b/zarafa-webaccess.spec @@ -0,0 +1,233 @@ +# +# Releasing with this .spec, for fun and profit; +# +# = Beta Release or Release Candidate = +# +# 1. Set beta_or_rc to 1 +# 2. Set actual_release to the actual_release value of the previous +# build attempt, +1 +# - The release tag in case of a beta_or_rc release is (statically) +# prefixed with "0.", so that the first final release ("1") is always +# newer (in rpm-compver). +# 3. Set the SVN revision to the current SVN revision; +# - This ensures a future SVN revision is always *more* recent in +# rpm-compver +# - Lacking a unique zarafa-.svn.tar.gz source +# tarball, setting the correct SVN revision in the .spec is +# critical in order to be able to determine exactly what was in +# the tarball at the time of this build. You may recover the exact +# SVN revision used from the resulting SRPM and RPMs because it ends +# up in the RPM release tag. +# 4. Update %%changelog, considering the following; +# - Possibly change only the release tag for the most recent changelog +# %%changelog entry, if appropriate +# - Add a message about the changes to either the product or the RPM +# packaging +# 5. Build locally +# 6. Build in mock for; +# a) fedora-rawhide-x86_64, +# b) fedora-12-x86_64, +# c) fedora-11-x86_64, +# d) epel-5-x86_64, +# e) epel-4-x86_64 +# +# or scratch build in koji; +# +# for tag in dist-f13 dist-f12-updates-candidate dist-f11-updates-candidate \ +# dist-5E-epel dist-4E-epel; do +# echo "- $tag: `koji build --scratch --nowait $tag $srpm 2>&1 | grep \"Task info\" | awk '{print $3}'`" +# done +# +# 7. Should builds fail, repeat the process. +# +# = Final Release = +# +# NOTE: A final release of a version, or multiple final releases of the +# same version, of Zarafa 6.30.10 requires one unique tarball, probably +# named similar to zarafa-webaccess-ajax-6.30.10.tar.gz. +# +# Once this tarball is used for an RPM package that is actually released, +# the .tar.gz source should not change anymore. You may, though, include +# patches for the 6.30.10 RPM package in this .spec and bumping the release +# number. +# +# When you do so, however, you will need to take into account upgrade paths +# between distribution versions. E.g., when releasing 6.30.10-2 to F-11, you +# would also need to release 6.30.10-2 to F-12. +# +# An alternative is to release 6.30.10.1 with a zarafa-6.30.10.1.tar.gz (yet +# again ensuring there is an upgrade path to later distribution versions) +# +# The point behind this has to do with reproducibility, though admittedly, +# the Source RPM corresponding to the binary RPM (comparing the +# -.src.rpm vs. the installed +# -..rpm) does reveal the actual SVN revision number, +# and should thus also build the exact same thing running in production (euh, +# at customers, that is). +# +# 1. Set beta_or_rc to 0 +# 2. Set actual_release to 1, or the value of actual_release of +# the previous stable release, +1 in case have already released +# this SVN revision as a stable product. +# 3. Set the SVN revision to the current SVN revision; +# - Lacking a unique zarafa-.svn.tar.gz source +# tarball, setting the correct SVN revision in the .spec is +# critical in order to be able to determine exactly what was in +# the tarball at the time of this build. You may recover the exact +# SVN revision used from the resulting SRPM, as the .spec in that +# SRPM contains the SVN revision number (but not the resulting RPMs +# just for the sake of appearance). +# 4. Update %%changelog, considering the following; +# - Remove all %%changelog stamps that have a beta_or_rc type of versioning, +# again just for appearances sake, possibly preserving the important +# messages from each beta_or_rc type of changelog entries, e.g.: +# +# * Some Time Your Name - 6.30.10-0.1svn12345 +# - Improve packaging +# +# might, in a final release, become: +# +# * Some Time Zarafa Release Engineering - 6.30.10-1 +# - Release 6.30.10 +# - Improve packaging +# +# - Possibly change only the release tag for the most recent changelog +# %%changelog entry, if appropriate. This is assuming there is no +# important or significant changes between the beta_or_rc and the final +# product. +# - Add a message about the changes to either the product or the RPM +# packaging if appropriate. +# 5. Build locally +# 6. Build in mock for; +# a) fedora-rawhide-x86_64, +# b) fedora-12-x86_64, +# c) fedora-11-x86_64, +# d) epel-5-x86_64, +# e) epel-4-x86_64 +# +# or scratch build in koji; +# +# for tag in dist-f13 dist-f12-updates-candidate dist-f11-updates-candidate \ +# dist-5E-epel dist-4E-epel; do +# echo "- $tag: `koji build --scratch --nowait $tag $srpm 2>&1 | grep \"Task info\" | awk '{print $3}'`" +# done +# +# 7. When mock or koji scratch builds fail, repeat the process. +# + +%define beta_or_rc 0 +%define actual_release 1 +%define svnrevision 20002 + +Summary: Zarafa Webaccess featuring a 'Look & Feel' similar to Outlook +Name: zarafa-webaccess +Version: 6.30.14 +%if %{beta_or_rc} +Release: 0.%{actual_release}.svn%{svnrevision}%{?dist} +%else +Release: %{actual_release}%{?dist} +%endif +# Red Hat Legal has been advised by email from Zarafa that no license is +# required in order to use the letter string "zarafa" (combined with other +# words) in the package naming, to refer to the software as "Zarafa" to +# indicate its intended purpose, and to modify packages with bug fixes and +# enhancements. +License: AGPLv3 with exceptions +Group: Applications/Productivity +URL: http://www.zarafa.com/ +# http://www.zarafa.com/download-community -> "Zarafa AJAX Webaccess Source Package" +Source0: %{name}-ajax-%{version}.tar.gz +Source1: %{name}.conf +BuildRequires: gettext +Requires: php(mapi) = %{version}, httpd, php >= 4.3 +BuildArch: noarch +BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) + +%description +Zarafa Webaccess features the familiar Outlook 'Look & Feel' interface +and you can keep using the features in Outlook that have always allowed +you to work efficiently. View your e-mail, calendar and contacts via a +web browser. And opening your colleagues calendar or sending a meeting +request is only a piece of cake. The Zarafa Webaccess is using the ajax +technology to give a more interactive feeling to the users. + +%prep +%setup -q -n php-webclient-ajax + +%build + +%install +rm -rf $RPM_BUILD_ROOT + +# Install all files into destination +mkdir -p $RPM_BUILD_ROOT%{_datadir}/%{name}/ +cp -af * $RPM_BUILD_ROOT%{_datadir}/%{name}/ + +# Compile *.mo from *.po translation files +for po in $RPM_BUILD_ROOT%{_datadir}/%{name}/server/language/*/LC_MESSAGES/*.po; do + msgfmt -v -o ${po%.po}.mo $po; rm -f $po +done + +# Move configuration file to its place +mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/zarafa/webaccess/ +mv -f $RPM_BUILD_ROOT%{_datadir}/%{name}/config.php.dist $RPM_BUILD_ROOT%{_sysconfdir}/zarafa/webaccess/config.php +ln -sf ../../..%{_sysconfdir}/zarafa/webaccess/config.php $RPM_BUILD_ROOT%{_datadir}/%{name}/config.php + +# Install the apache configuration file +mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/httpd/conf.d/ +install -p -m 644 %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/httpd/conf.d/%{name}.conf + +# Create temporary directory for packaging +mkdir -p $RPM_BUILD_ROOT%{_localstatedir}/lib/%{name}/{plugins,tmp}/ + +# Remove unwanted fckeditor language connectors +rm -rf $RPM_BUILD_ROOT%{_datadir}/%{name}/client/widgets/fckeditor/editor/filemanager/connectors/{asp,aspx,cfm,lasso,perl,py} +rm -f $RPM_BUILD_ROOT%{_datadir}/%{name}/client/widgets/fckeditor/editor/dialog/fck_spellerpages/spellerpages/server-scripts/spellchecker.{cfm,pl} + +# Remove \r line endings, correct permissions +for file in $(find $RPM_BUILD_ROOT%{_datadir}/%{name}/client/widgets/fckeditor -type f); do + # Ignore *.png and *.gif files + if [ "${file##*.}" != "png" -a "${file##*.}" != "gif" ]; then + sed -e 's/\r//' $file > $file.new + touch -c -r $file $file.new + mv -f $file.new $file + fi + + # Correct permissions to all files + chmod 644 $file +done + +# Remove the unwanted files before packaging +rm -f $RPM_BUILD_ROOT%{_datadir}/%{name}/{debug.php,zarafa-webaccess.conf} + +%clean +rm -rf $RPM_BUILD_ROOT + +%files +%defattr(-,root,root,-) +%config(noreplace) %{_sysconfdir}/httpd/conf.d/%{name}.conf +%dir %{_sysconfdir}/zarafa/ +%dir %{_sysconfdir}/zarafa/webaccess/ +%config(noreplace) %{_sysconfdir}/zarafa/webaccess/config.php +%{_datadir}/%{name}/ +%dir %{_localstatedir}/lib/%{name}/ +%dir %{_localstatedir}/lib/%{name}/plugins/ +%attr(-,apache,apache) %dir %{_localstatedir}/lib/%{name}/tmp/ + +%changelog +* Sat May 01 2010 Robert Scheck 6.30.14-1 +- Upgrade to 6.30.14 + +* Sun Apr 25 2010 Robert Scheck 6.30.13-1 +- Upgrade to 6.30.13 + +* Sat Mar 20 2010 Robert Scheck 6.30.12-1 +- Upgrade to 6.30.12 + +* Fri Mar 19 2010 Robert Scheck 6.30.11-1 +- Upgrade to 6.30.11 + +* Sat Feb 06 2010 Robert Scheck 6.30.10-1 +- Upgrade to 6.30.10 (#498195) +- Initial spec file for Fedora and Red Hat Enterprise Linux (thanks + to Jeroen van Meeuwen, John van der Kamp and Steve Hardy)