/[packages]/cauldron/horde/current/SPECS/horde.spec
ViewVC logotype

Annotation of /cauldron/horde/current/SPECS/horde.spec

Parent Directory Parent Directory | Revision Log Revision Log


Revision 389214 - (hide annotations) (download)
Thu Jan 17 21:30:27 2013 UTC (12 years, 6 months ago) by pterjan
File size: 5617 byte(s)
oops
1 spuhler 4613 %define name horde
2     %define version 3.3.8
3     %define release %mkrel 3
4    
5     %define _requires_exceptions pear(Horde/Kolab/FreeBusy.php)
6    
7     Name: %{name}
8     Version: %{version}
9     Release: %{release}
10     Summary: The Horde framework
11     License: GPL
12     Group: System/Servers
13     Source0: ftp://ftp.horde.org/pub/horde/%{name}-%{version}.tar.gz
14     ############################
15     # domxml php4 - php5 wrapper
16     # Written by Alexandre Alapetite
17     # Licence: Creative Commons "Attribution-ShareAlike 2.0 France" BY-SA (FR)
18     # http://alexandre.alapetite.net/doc-alex/domxml-php4-php5
19     Source1: http://alexandre.alapetite.net/doc-alex/domxml-php4-php5/domxml-php4-to-php5.php.txt
20     ############################
21     Patch2: %{name}-3.3.2-better-default-configuration.patch
22     Patch4: %{name}-3.3.5-registry.patch
23     Patch6: horde-3.2-usr_local.patch
24     URL: http://www.horde.org/
25     Requires: horde-dimp
26     Requires: horde-gollem
27     Requires: horde-ingo
28     Requires: horde-mimp
29     Requires: horde-nag
30     Requires: horde-turba
31     Requires: horde-passwd
32     Requires: horde-kronolith
33     Requires: horde-imp
34     Requires: horde-vacation
35     Requires: apache-mod_php
36     Requires: php-imagick
37     Requires: php-xml
38     Requires: php-dom
39     Conflicts: horde-accounts <= 2.1.2
40     Conflicts: horde-forwards <= 2.2.2
41     Conflicts: horde-password <= 2.2.2
42     Conflicts: horde-vacation <= 2.2.2
43     BuildArch: noarch
44    
45     %description
46     The Horde Framework provides a common structure and interface for Horde
47     applications (such as IMP, a web-based mail program). This RPM is required
48     for all other Horde module RPMS.
49    
50     The Horde Project writes web applications in PHP and releases them under
51     the GNU Public License. For more information (including help with Horde
52     and its modules) please visit http://www.horde.org/.
53    
54     %prep
55     %setup -q
56     %patch2 -p 1
57     %patch4 -p 1
58     %patch6 -p 1
59    
60     # fix perms
61     chmod 755 scripts/*.{php,sh,cron}
62    
63     # nuke patch backup files
64     find . -type f -name "*.orig" | xargs rm -f
65    
66     %build
67    
68     %install
69     rm -rf %{buildroot}
70    
71     # apache configuration
72     install -d -m 755 %{buildroot}%{_webappconfdir}
73     cat > %{buildroot}%{_webappconfdir}/%{name}.conf <<EOF
74     # %{name} Apache configuration file
75     Alias /%{name} %{_datadir}/%{name}
76     <Directory %{_datadir}/%{name}>
77     Order allow,deny
78     Allow from localhost
79     </Directory>
80    
81     <Directory %{_datadir}/%{name}/lib>
82     Order allow,deny
83     Deny from all
84     </Directory>
85    
86     <Directory %{_datadir}/%{name}/locale>
87     Order allow,deny
88     Deny from all
89     </Directory>
90    
91     <Directory %{_datadir}/%{name}/scripts>
92     Order allow,deny
93     Deny from all
94     </Directory>
95    
96     <Directory %{_datadir}/%{name}/templates>
97     Order allow,deny
98     Deny from all
99     </Directory>
100     EOF
101    
102     # remove .htaccess files
103     find . -name .htaccess -exec rm -f {} \;
104    
105     # install files
106     install -d -m 755 %{buildroot}%{_datadir}/%{name}
107     cp -pR *.php %{buildroot}%{_datadir}/%{name}
108     cp -pR admin %{buildroot}%{_datadir}/%{name}
109     cp -pR js %{buildroot}%{_datadir}/%{name}
110     cp -pR services %{buildroot}%{_datadir}/%{name}
111     cp -pR themes %{buildroot}%{_datadir}/%{name}
112     cp -pR util %{buildroot}%{_datadir}/%{name}
113     cp -pR lib %{buildroot}%{_datadir}/%{name}
114     cp -pR locale %{buildroot}%{_datadir}/%{name}
115     cp -pR scripts %{buildroot}%{_datadir}/%{name}
116     cp -pR templates %{buildroot}%{_datadir}/%{name}
117    
118     install -d -m 755 %{buildroot}%{_sysconfdir}
119     cp -pR config %{buildroot}%{_sysconfdir}/%{name}
120     pushd %{buildroot}%{_datadir}/%{name}
121     ln -s ../../..%{_sysconfdir}/%{name} config
122     popd
123    
124     # put domxml-php4-to-php5.php in place
125     install -m0644 %{SOURCE1} %{buildroot}%{_datadir}/%{name}/lib/Horde/domxml-php4-to-php5.php
126    
127     # activate configuration files
128     for file in %{buildroot}%{_sysconfdir}/%{name}/*.dist; do
129     mv $file ${file%.dist}
130     done
131    
132     # fix script shellbang
133     for file in `find %{buildroot}%{_datadir}/%{name}/scripts`; do
134     perl -pi -e 's|/usr/local/bin/php|/usr/bin/php|' $file
135     done
136    
137     # registry dir
138     install -d -m 755 %{buildroot}%{_sysconfdir}/%{name}/registry.d
139    
140     # logs
141     install -d -m 755 %{buildroot}%{_var}/log/%{name}
142     install -d -m 755 %{buildroot}%{_sysconfdir}/logrotate.d
143     cat > %{buildroot}%{_sysconfdir}/logrotate.d/%{name} <<EOF
144     %{_var}/log/%{name}/*.log {
145     missingok
146     compress
147     }
148     EOF
149    
150     cat > README.mdv <<EOF
151 spuhler 33184 Mageia RPM specific notes
152 spuhler 4613
153     setup
154     -----
155     The setup used here differs from default one, to achieve better FHS compliance.
156     - the configuration files are in /etc/horde
157     - the log files are in /var/log/horde
158     - the constant files are in /usr/share/horde
159    
160     post-installation
161     -----------------
162     You have to either use a browser to http://your.server.url/horde, so as to
163     configure proper configuration.
164    
165     Additional useful packages
166     --------------------------
167     - either a SQL database (MySQL or PostgreSQL), an LDAP (openldap) or a Kolab
168     server for storing preferences
169     - php-mcrypt for better encryption
170     - php-iconv and php-mbstring for better utf8 support
171     - php-gd for image manipulations
172     - php-pear-File for CVS import support
173     - php-Date to deal with calendar data
174     - php-Services_Weather to the weather.com block on the portal page
175    
176    
177     Additional horde applications
178     -----------------------------
179     They are all packaged as horde-<application>. Warning, some have still not been
180     ported to horde 3, and have been removed from the distribution (vacation,
181     forwards and accounts notably).
182     EOF
183    
184     %clean
185     rm -rf %{buildroot}
186    
187    
188     %files
189     %defattr(-,root,root)
190     %doc README README.mdv COPYING docs scripts/SCRIPTS
191     %config(noreplace) %{_webappconfdir}/%{name}.conf
192     %config(noreplace) %{_sysconfdir}/logrotate.d/%{name}
193     %config(noreplace) %{_sysconfdir}/%{name}
194     %attr(-,apache,apache) %config(noreplace) %{_sysconfdir}/%{name}/conf.php
195     %{_datadir}/%{name}
196     %attr(-,apache,apache) %{_var}/log/%{name}
197    
198    
199    
200    

  ViewVC Help
Powered by ViewVC 1.1.30