]> git.pld-linux.org Git - packages/cas.git/blob - cas.spec
- drop obsolete and outdated manual inclusion of rpm macros
[packages/cas.git] / cas.spec
1 Summary:        JA-SIG Central Authentication Service
2 Name:           cas
3 Version:        3.4.2
4 Release:        3
5 License:        MIT License
6 Group:          Networking/Daemons/Java/Servlets
7 Source0:        http://www.ja-sig.org/downloads/cas/%{name}-server-%{version}-release.tar.gz
8 # Source0-md5:  3a7dfd70be008053b8619509dcc45be9
9 Source1:        %{name}-context.xml
10 URL:            http://www.ja-sig.org/products/cas/
11 BuildRequires:  rpm-javaprov
12 BuildRequires:  rpmbuild(macros) >= 1.546
13 Requires:       jpackage-utils
14 Requires:       tomcat >= 6
15 BuildArch:      noarch
16 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
17
18 %define webappdir %{_datadir}/%{name}
19 %define libdir    %{_datadir}/%{name}/WEB-INF/lib
20 %define logdir    %{_var}/log/%{name}
21
22 %description
23 CAS is an authentication system originally created by Yale University
24 to provide a trusted way for an application to authenticate a user.
25 CAS became a JA-SIG project in December 2004.
26
27 CAS provides enterprise single sign on service. It features:
28
29 - An open and well-documented protocol
30 - An open-source Java server component
31 - A library of clients for Java, .Net, PHP, Perl, Apache, uPortal and
32   others
33 - Integrates with uPortal, BlueSocket, TikiWiki, Mule, Liferay, Moodle
34   and others
35 - Community documentation and implementation support
36 - An extensive community of adopters
37
38 %package authenticator-spnego
39 Summary:        Spnego authenticator for CAS server
40 Group:          Libraries/Java
41 Requires:       %{name} = %{version}-%{release}
42
43 %description authenticator-spnego
44 Spnego authentication backend for CAS Server.
45
46 %package authenticator-x509
47 Summary:        x509 authenticator for CAS server
48 Group:          Libraries/Java
49 Requires:       %{name} = %{version}-%{release}
50
51 %description authenticator-x509
52 X509 client certificates authentication backend for CAS Server.
53
54 %package authenticator-openid
55 Summary:        OpenID authenticator for CAS server
56 Group:          Libraries/Java
57 Requires:       %{name} = %{version}-%{release}
58
59 %description authenticator-openid
60 OpenID authentication backend for CAS Server.
61
62 %package authenticator-legacy
63 Summary:        Legacy authenticator for CAS server
64 Group:          Libraries/Java
65 Requires:       %{name} = %{version}-%{release}
66
67 %description authenticator-legacy
68 Legacy authentication backend for CAS Server.
69
70 %package authenticator-radius
71 Summary:        Radius authenticator for CAS server
72 Group:          Libraries/Java
73 Requires:       %{name} = %{version}-%{release}
74
75 %description authenticator-radius
76 Radius authentication backend for CAS Server.
77
78 %package authenticator-ldap
79 Summary:        LDAP authenticator for CAS server
80 Group:          Libraries/Java
81 Requires:       %{name} = %{version}-%{release}
82
83 %description authenticator-ldap
84 LDAP authentication backend for CAS Server.
85
86 %package authenticator-generic
87 Summary:        Generic authenticator for CAS server
88 Group:          Libraries/Java
89 Requires:       %{name} = %{version}-%{release}
90
91 %description authenticator-generic
92 Generic authentication backend for CAS Server.
93
94 %package authenticator-trusted
95 Summary:        Trusted authenticator for CAS server
96 Group:          Libraries/Java
97 Requires:       %{name} = %{version}-%{release}
98
99 %description authenticator-trusted
100 Trusted authentication backend for CAS Server.
101
102 %package authenticator-jdbc
103 Summary:        JDBC authenticator for CAS server
104 Group:          Libraries/Java
105 Requires:       %{name} = %{version}-%{release}
106
107 %description authenticator-jdbc
108 JDBC authentication backend for CAS Server.
109
110 %package integration-berkeleydb
111 Summary:        Berkeleydb ticket registry for CAS server
112 Group:          Libraries/Java
113 Requires:       %{name} = %{version}-%{release}
114
115 %description integration-berkeleydb
116 BerkeleyDB integration for CAS Server allows to store ticket registry
117 in berkeleyDB.
118
119 %package integration-jboss
120 Summary:        Jboss ticket registry for CAS server
121 Group:          Libraries/Java
122 Requires:       %{name} = %{version}-%{release}
123
124 %description integration-jboss
125 Jboss integration for CAS Server allows to store ticket registry in
126 Jboss internal authentication system.
127
128 %package integration-memcached
129 Summary:        Memory ticket registry for CAS server
130 Group:          Libraries/Java
131 Requires:       %{name} = %{version}-%{release}
132
133 %description integration-memcached
134 Memcached integration for CAS Server allows to store ticket registry
135 in memory cache.
136
137 %package integration-restlet
138 Summary:        I have no idea WTF is that, but it is for CAS server
139 Group:          Libraries/Java
140 Requires:       %{name} = %{version}-%{release}
141
142 %description integration-restlet
143 I really have no idea WTF is that. It name suggests it is yet another
144 registry storage driver for CAS, but it does not extends
145 AbstractDistributedTicketRegistry class.
146
147 %prep
148 %setup -q -n %{name}-server-%{version}
149 unzip modules/%{name}-server-webapp-%{version}.war -d webapp
150
151 sed -i 's,\(name="File" value="\)\([^"]*"\),\1%{logdir}/\2,' webapp/WEB-INF/classes/log4j.xml
152
153 %build
154
155 %install
156 rm -rf $RPM_BUILD_ROOT
157 install -d $RPM_BUILD_ROOT{%{_sysconfdir}/%{name},%{_datadir},%{_sharedstatedir}/%{name},%{_tomcatconfdir},%{logdir}}
158
159 cp -a webapp $RPM_BUILD_ROOT%{webappdir}
160
161 MODULES="
162   integration-berkeleydb
163   integration-jboss
164   integration-memcached
165   integration-restlet
166   support-generic
167   support-jdbc
168   support-ldap
169   support-legacy
170   support-openid
171   support-radius
172   support-spnego
173   support-trusted
174   support-x509
175 "
176
177 CONFIGFILES="
178   classes/log4j.xml
179   cas.properties
180   deployerConfigContext.xml
181   login-webflow.xml
182   restlet-servlet.xml
183   cas-servlet.xml
184   web.xml
185 "
186
187 for i in $MODULES; do
188   install modules/%{name}-server-$i-%{version}.jar $RPM_BUILD_ROOT%{libdir}/%{name}-$i-%{version}.jar
189 done
190
191 for i in $CONFIGFILES; do
192   mv $RPM_BUILD_ROOT%{webappdir}/WEB-INF/$i $RPM_BUILD_ROOT%{_sysconfdir}/%{name}/$(basename $i)
193   ln -s %{_sysconfdir}/%{name}/$(basename $i) $RPM_BUILD_ROOT%{webappdir}/WEB-INF/$i
194 done
195
196 install %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/%{name}/tomcat-context.xml
197 ln -sf %{_sysconfdir}/%{name}/tomcat-context.xml $RPM_BUILD_ROOT%{_tomcatconfdir}/%{name}.xml
198
199 %postun
200 %tomcat_clear_cache %{name}
201
202 %clean
203 rm -rf $RPM_BUILD_ROOT
204
205 %files
206 %defattr(644,root,root,755)
207 %dir %{_sysconfdir}/%{name}
208 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}/*.xml
209 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}/*.properties
210 %{_tomcatconfdir}/%{name}.xml
211 %{_datadir}/%{name}
212 %exclude %{libdir}/%{name}-support-spnego-%{version}.jar
213 %exclude %{libdir}/%{name}-integration-berkeleydb-%{version}.jar
214 %exclude %{libdir}/%{name}-support-x509-%{version}.jar
215 %exclude %{libdir}/%{name}-integration-jboss-%{version}.jar
216 %exclude %{libdir}/%{name}-support-openid-%{version}.jar
217 %exclude %{libdir}/%{name}-support-legacy-%{version}.jar
218 %exclude %{libdir}/%{name}-support-radius-%{version}.jar
219 %exclude %{libdir}/%{name}-integration-memcached-%{version}.jar
220 %exclude %{libdir}/%{name}-integration-restlet-%{version}.jar
221 %exclude %{libdir}/%{name}-support-ldap-%{version}.jar
222 %exclude %{libdir}/%{name}-support-generic-%{version}.jar
223 %exclude %{libdir}/%{name}-support-trusted-%{version}.jar
224 %exclude %{libdir}/%{name}-support-jdbc-%{version}.jar
225 %attr(2775,root,servlet) %dir %{_sharedstatedir}/%{name}
226 %dir %attr(2770,root,servlet) %{logdir}
227
228 %files authenticator-spnego
229 %defattr(644,root,root,755)
230 %{libdir}/%{name}-support-spnego-%{version}.jar
231
232 %files authenticator-x509
233 %defattr(644,root,root,755)
234 %{libdir}/%{name}-support-x509-%{version}.jar
235
236 %files authenticator-openid
237 %defattr(644,root,root,755)
238 %{libdir}/%{name}-support-openid-%{version}.jar
239
240 %files authenticator-legacy
241 %defattr(644,root,root,755)
242 %{libdir}/%{name}-support-legacy-%{version}.jar
243
244 %files authenticator-radius
245 %defattr(644,root,root,755)
246 %{libdir}/%{name}-support-radius-%{version}.jar
247
248 %files authenticator-ldap
249 %defattr(644,root,root,755)
250 %{libdir}/%{name}-support-ldap-%{version}.jar
251
252 %files authenticator-generic
253 %defattr(644,root,root,755)
254 %{libdir}/%{name}-support-generic-%{version}.jar
255
256 %files authenticator-trusted
257 %defattr(644,root,root,755)
258 %{libdir}/%{name}-support-trusted-%{version}.jar
259
260 %files authenticator-jdbc
261 %defattr(644,root,root,755)
262 %{libdir}/%{name}-support-jdbc-%{version}.jar
263
264 %files integration-berkeleydb
265 %defattr(644,root,root,755)
266 %{libdir}/%{name}-integration-berkeleydb-%{version}.jar
267
268 %files integration-jboss
269 %defattr(644,root,root,755)
270 %{libdir}/%{name}-integration-jboss-%{version}.jar
271
272 %files integration-memcached
273 %defattr(644,root,root,755)
274 %{libdir}/%{name}-integration-memcached-%{version}.jar
275
276 %files integration-restlet
277 %defattr(644,root,root,755)
278 %{libdir}/%{name}-integration-restlet-%{version}.jar
This page took 1.173487 seconds and 3 git commands to generate.