]> git.pld-linux.org Git - packages/eventum.git/blobdiff - eventum.spec
- add to PLD CVS
[packages/eventum.git] / eventum.spec
index 57ca44bec1e552f12e46215af5c353eb2158b9ea..4708028a95af3411cb4c02e4654c9513564b5f9f 100644 (file)
@@ -1,6 +1,4 @@
 # TODO
-# - system pear is incompatible, at least pear DB class seems broke Eventum
-# - php5 is not tested, but not placing hard conflict on it, as it prevents php4 & php coinstallation
 # - discard bundled packages (from INSTALL):
 #  - JpGraph 1.5.3 (last GPL version)
 #  - dTree 2.0.5 (http://www.destroydrop.com/javascript/tree/)
@@ -9,16 +7,16 @@
 #  - A few other small javascript libraries
 # - 64bit platforms beware? http://bugs.php.net/bug.php?id=30215 (it's actually Smarty related problem)
 
-%bcond_with    pear    # build with system PEAR packages (or use bundled ones)
+%bcond_without pear    # build with system PEAR packages (or use bundled ones)
 %bcond_with    qmail   # build the router-qmail subpackage
 
 # snapshot: DATE
-%define        _snap 20051130
+%define        _snap 20051227
 
 # release candidate
 #define _rc            RC1
 
-%define        _rel    4.24
+%define        _rel    4.45
 
 %if 0%{?_rc:1}
 %define        _source http://pessoal.org/%{name}-%{version}-%{_rc}.tar.gz
@@ -30,6 +28,7 @@
 %endif
 %endif
 
+%{?with_pear:%include  /usr/lib/rpm/macros.php}
 Summary:       Eventum Issue / Bug tracking system
 Summary(pl):   Eventum - system ¶ledzenia spraw/b³êdów
 Name:          eventum
@@ -38,7 +37,7 @@ Release:      %{?_snap:0.%{_snap}.}%{?_rc:%{_rc}.}%{_rel}
 License:       GPL
 Group:         Applications/WWW
 Source0:       %{_source}
-# Source0-md5: 9fdc64a7b6c194062759281caf576226
+# Source0-md5: 37185deab6f5a1e388800e1fe182e64c
 Source1:       %{name}-apache.conf
 Source2:       %{name}-mail-queue.cron
 Source3:       %{name}-mail-download.cron
@@ -62,22 +61,24 @@ Patch4:             http://glen.alkohol.ee/pld/%{name}-reply-subject.patch
 Patch5:                %{name}-lf.patch
 Patch6:                http://glen.alkohol.ee/pld/%{name}-maq-subject.patch
 Patch7:                %{name}-bot-reconnect.patch
-Patch9:                http://glen.alkohol.ee/pld/eventum-httpclient-clientside.patch
-Patch11:       eventum-cli-wr-separated.patch
-Patch12:       eventum-php440.patch
-Patch13:       eventum-htmloptions-truncate.patch
-Patch15:       eventum-db-1.7.0.patch
+Patch8:                %{name}-perms.patch
+Patch9:                http://glen.alkohol.ee/pld/%{name}-httpclient-clientside.patch
+Patch10:       %{name}-cli-wr-separated.patch
+Patch11:       %{name}-php440.patch
+Patch12:       %{name}-htmloptions-truncate.patch
+Patch13:       http://glen.alkohol.ee/pld/%{name}-link_filter-updates.patch
 URL:           http://dev.mysql.com/downloads/other/eventum/
+%{?with_pear:BuildRequires:    rpm-php-pearprov >= 4.0.2-98}
 BuildRequires: rpmbuild(macros) >= 1.223
 BuildRequires: sed >= 4.0
+Requires:      %{name}-base = %{epoch}:%{version}-%{release}
+Requires:      Smarty >= 2.6.2
 Requires:      php >= 3:4.2.0
 Requires:      php-gd
 Requires:      php-imap
 Requires:      php-mysql
 Requires:      php-pcre
 Requires:      php-session
-Requires:      %{name}-base = %{epoch}:%{version}-%{release}
-Requires:      Smarty >= 2.6.2
 %if %{with pear}
 Requires:      php-pear-Benchmark
 Requires:      php-pear-DB
@@ -86,26 +87,29 @@ Requires:   php-pear-HTTP_Request
 Requires:      php-pear-Mail
 Requires:      php-pear-Math_Stats
 Requires:      php-pear-Net_DIME
-Requires:      php-pear-Net_POP3
 Requires:      php-pear-Net_SMTP
 Requires:      php-pear-Net_Socket
 Requires:      php-pear-Net_URL
 Requires:      php-pear-Net_UserAgent_Detect
-Requires:      php-pear-PEAR
+Requires:      php-pear-PEAR-core
 Requires:      php-pear-Text_Diff
 Requires:      php-pear-XML_RPC
+#Suggests:     php-pear-Net_POP3
 %endif
+Requires(triggerpostun):       /usr/bin/php
+Requires(triggerpostun):       sed >= 4.0
+Requires:      apache(mod_dir)
 Requires:      webapps
 Requires:      webserver = apache
-Requires:      apache(mod_dir)
-Requires(triggerpostun):       sed >= 4.0
-Conflicts:     apache1 < 1.3.33-2
 BuildArch:     noarch
 BuildRoot:     %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
+%define                _noautoreq      'pear(/etc/webapps/.*)' 'pear(jpgraph_dir.php)' 'pear(.*Smarty.class.php)' 'pear(Net/POP3.php)'
+
 %define                _libdir         %{_prefix}/lib/%{name}
 %define                _appdir %{_datadir}/%{name}
 %define                _smartyplugindir        %{_appdir}/include/smarty
+%define                _smartydir      /usr/share/php/Smarty
 %define                _webapps        /etc/webapps
 %define                _webapp         %{name}
 %define                _sysconfdir     %{_webapps}/%{_webapp}
@@ -129,14 +133,14 @@ reakcji.
 Summary:       Eventum base package
 Summary(pl):   Podstawowy pakiet Eventum
 Group:         Applications/WWW
+Requires(postun):      /usr/sbin/groupdel
+Requires(postun):      /usr/sbin/userdel
 Requires(pre): /bin/id
 Requires(pre): /usr/bin/getgid
-Requires(pre): /usr/sbin/useradd
 Requires(pre): /usr/sbin/groupadd
-Requires(postun):      /usr/sbin/userdel
-Requires(postun):      /usr/sbin/groupdel
-Provides:      user(eventum)
+Requires(pre): /usr/sbin/useradd
 Provides:      group(eventum)
+Provides:      user(eventum)
 
 %description base
 This package contains base directory structure for Eventum.
@@ -148,7 +152,7 @@ Ten pakiet zawiera podstawow
 Summary:       Eventum setup package
 Summary(pl):   Pakiet do wstêpnej konfiguracji Eventum
 Group:         Applications/WWW
-PreReq:                %{name} = %{epoch}:%{version}-%{release}
+Requires:      %{name} = %{epoch}:%{version}-%{release}
 
 %description setup
 Install this package to configure initial Eventum installation. You
@@ -165,6 +169,7 @@ Summary:    Eventum mail queue process
 Summary(pl):   Przetwarzanie kolejki poczty Eventum
 Group:         Applications/WWW
 Requires:      %{name} = %{epoch}:%{version}-%{release}
+Requires:      /usr/bin/php
 Requires:      crondaemon
 
 %description mail-queue
@@ -190,6 +195,7 @@ Summary:    Eventum email download
 Summary(pl):   ¦ci±ganie poczty Eventum
 Group:         Applications/WWW
 Requires:      %{name} = %{epoch}:%{version}-%{release}
+Requires:      /usr/bin/php
 Requires:      crondaemon
 
 %description mail-download
@@ -210,6 +216,7 @@ Summary:    Eventum Reminder System
 Summary(pl):   System przypominania dla Eventum
 Group:         Applications/WWW
 Requires:      %{name} = %{epoch}:%{version}-%{release}
+Requires:      /usr/bin/php
 Requires:      crondaemon
 
 %description reminder
@@ -235,8 +242,9 @@ Summary:    Eventum Heartbeat Monitor
 Summary(pl):   Monitor ¿ycia dla Eventum
 Group:         Applications/WWW
 Requires:      %{name} = %{epoch}:%{version}-%{release}
-Requires:      php-posix
+Requires:      /usr/bin/php
 Requires:      crondaemon
+Requires:      php-posix
 
 %description monitor
 The heartbeat monitor is a feature designed for the administrator that
@@ -269,6 +277,7 @@ Summary:    Eventum Email Routing
 Summary(pl):   Przekazywanie poczty dla Eventum
 Group:         Applications/WWW
 Requires:      %{name} = %{epoch}:%{version}-%{release}
+Requires:      /usr/bin/php
 Requires:      eventum(router)
 
 %description route-emails
@@ -294,6 +303,7 @@ Summary:    Eventum Note Routing
 Summary(pl):   Przekazywanie notatek dla Eventum
 Group:         Applications/WWW
 Requires:      %{name} = %{epoch}:%{version}-%{release}
+Requires:      /usr/bin/php
 Requires:      eventum(router)
 
 %description route-notes
@@ -356,8 +366,9 @@ Summary(pl):        IRC-owy bot powiadamiaj
 Group:         Applications/WWW
 Requires(triggerpostun):       sed >= 4.0
 Requires:      %{name} = %{epoch}:%{version}-%{release}
-Requires:      php-sockets
+Requires:      /usr/bin/php
 #Requires:     php-pear-Net_SmartIRC
+Requires:      php-sockets
 Requires:      rc-scripts >= 0.4.0.18
 
 %description irc
@@ -389,11 +400,11 @@ Summary:  Eventum command-line interface
 Summary(pl):   Interfejs linii poleceñ dla Eventum
 Group:         Applications/WWW
 Requires:      %{name}-base = %{epoch}:%{version}-%{release}
-Requires:      php-common >= 3:4.1.0
 Requires:      php-cli
+Requires:      php-common >= 3:4.1.0
 Requires:      php-curl
-Requires:      php-xml
 Requires:      php-pear-XML_RPC
+Requires:      php-xml
 
 %description cli
 The Eventum command-line interface allows you to access most of the
@@ -408,8 +419,8 @@ Summary:    Eventum SCM integration
 Summary(pl):   Integracja SCM dla Eventum
 Group:         Applications/WWW
 Requires:      %{name}-base = %{epoch}:%{version}-%{release}
-Requires:      php-common >= 3:4.1.0
 Requires:      php-cli
+Requires:      php-common >= 3:4.1.0
 Requires:      php-pcre
 
 %description scm
@@ -442,6 +453,9 @@ rm -f setup.conf.php
 rm -rf misc/upgrade/*v1.[123]* # too old to support in PLD
 rm -rf misc/upgrade/flush_compiled_templates.php
 
+sed -e '1s,#!.*/bin/php -q,#!%{_bindir}/php,' misc/cli/eventum > %{name}-cli
+sed -e '1i#!%{_bindir}/php' misc/scm/process_cvs_commits.php > %{name}-scm
+
 # using system package
 #rm -rf include/pear/Net/SmartIRC*
 
@@ -456,11 +470,12 @@ rm -rf misc/upgrade/flush_compiled_templates.php
 %patch5 -p1
 %patch6 -p1
 %patch7 -p1
+%patch8 -p1
 %patch9 -p1
+%patch10 -p1
 %patch11 -p1
 %patch12 -p1
 %patch13 -p1
-%patch15 -p1
 
 # replace in remaining scripts config.inc.php to system one
 grep -rl 'include_once(".*config.inc.php")' . | xargs sed -i -e '
@@ -478,7 +493,7 @@ install -d \
        $RPM_BUILD_ROOT{%{_sysconfdir},%{_bindir},%{_libdir}} \
        $RPM_BUILD_ROOT/etc/{rc.d/init.d,cron.d,sysconfig} \
        $RPM_BUILD_ROOT/var/{run,log,cache,lib}/%{name} \
-       $RPM_BUILD_ROOT/var/lib/%{name}/routed_emails \
+       $RPM_BUILD_ROOT/var/lib/%{name}/routed_{emails,drafts,notes} \
        $RPM_BUILD_ROOT%{_appdir}/{include,htdocs/misc,upgrade} \
 
 cp -a *.php css customer images js manage reports rpc setup $RPM_BUILD_ROOT%{_appdir}/htdocs
@@ -499,13 +514,10 @@ install %{SOURCE14} $RPM_BUILD_ROOT%{_appdir}/upgrade/upgrade.sh
 install -d $RPM_BUILD_ROOT%{_appdir}/cli
 install misc/cli/include/class.{misc,command_line}.php $RPM_BUILD_ROOT%{_appdir}/cli
 install misc/cli/config.inc.php $RPM_BUILD_ROOT%{_sysconfdir}/cli.php
-sed -e '1s,#!.*/bin/php,#!%{_bindir}/php4,' \
-       misc/cli/eventum > $RPM_BUILD_ROOT%{_bindir}/%{name}
+install %{name}-cli $RPM_BUILD_ROOT%{_bindir}/%{name}
 cp -f misc/cli/eventumrc_example eventumrc
 
 # scm
-echo '#!%{_bindir}/php4 -q' > %{name}-scm
-cat misc/scm/process_cvs_commits.php >> %{name}-scm
 install %{name}-scm $RPM_BUILD_ROOT%{_libdir}/scm
 
 # private key
@@ -525,8 +537,14 @@ install %{SOURCE6} $RPM_BUILD_ROOT%{_sysconfdir}/cvs.php
 install %{SOURCE7} $RPM_BUILD_ROOT%{_sysconfdir}/irc.php
 install %{SOURCE8} $RPM_BUILD_ROOT/etc/rc.d/init.d/eventum-irc
 install %{SOURCE9} $RPM_BUILD_ROOT/etc/sysconfig/eventum-irc
-sed -e 's,%%{APP_VERSION}%%,%{version}%{?_snap:-%{_snap}},' \
-       %{SOURCE10} > $RPM_BUILD_ROOT%{_sysconfdir}/core.php
+
+sed -e '
+s,%%{APP_VERSION}%%,%{version}%{?_snap:-%{_snap}},
+s,%%{PHP_PEAR_DIR}%%,%{?with_pear:%{php_pear_dir}}%{!?with_pear:%{_appdir}/includes/pear},
+s,%%{APP_PATH}%%,%{_appdir},
+s,%%{SMARTY_DIR}%%,%{_smartydir},
+s,%%{SYSCONFDIR}%%,%{_sysconfdir},
+' %{SOURCE10} > $RPM_BUILD_ROOT%{_sysconfdir}/core.php
 
 # config
 > $RPM_BUILD_ROOT%{_sysconfdir}/setup.php
@@ -743,7 +761,7 @@ s,\$irc_username,$username,
 s,\$irc_password,$password,
 ' /etc/eventum/irc.php
 
-%triggerpostun -- %{name} < 1.6.1-4.18
+%triggerpostun -- eventum < 1.7.0-0.20051130.4.25
 # migrate from apache-config macros
 if [ -f /etc/%{name}/apache.conf.rpmsave ]; then
        if [ -d /etc/apache/webapps.d ]; then
@@ -772,6 +790,11 @@ if [ -L /etc/httpd/httpd.conf/99_%{_webapp}.conf ]; then
        fi
 fi
 
+%{_appdir}/upgrade/upgrade.sh %{_appdir}/upgrade/v1.6.1_to_v1.7.0 <<EOF
+database_changes.php Perform database changes
+set_root_message_ids.php Set iss_root_message_id
+EOF
+
 # regular configs
 for i in apache.conf config.php private_key.php setup.php; do
        if [ -f /etc/eventum/$i.rpmsave ]; then
@@ -792,12 +815,6 @@ if [ -f /etc/eventum/irc.php.rpmsave ]; then
        mv -f /etc/eventum/irc.php.rpmsave %{_sysconfdir}/irc.php
 fi
 
-%triggerpostun -- eventum < 1.7.0-0.20051130.4.24
-%{_appdir}/upgrade/upgrade.sh %{_appdir}/upgrade/v1.6.1_to_v1.7.0 <<EOF
-database_changes.php Perform database changes
-set_root_message_ids.php Set iss_root_message_id
-EOF
-
 %files
 %defattr(644,root,root,755)
 %doc ChangeLog FAQ INSTALL README UPGRADE
@@ -855,8 +872,10 @@ EOF
 %dir %{_appdir}
 # qmail will ignore user, if it's home directory is not owned
 %attr(750,eventum,eventum) %dir /var/lib/%{name}
-# for saved routed emails
+# saved mail copies
 %attr(770,root,eventum) %dir /var/lib/%{name}/routed_emails
+%attr(770,root,eventum) %dir /var/lib/%{name}/routed_drafts
+%attr(770,root,eventum) %dir /var/lib/%{name}/routed_notes
 
 %files setup
 %defattr(644,root,root,755)
This page took 0.152408 seconds and 4 git commands to generate.