]> git.pld-linux.org Git - packages/dgee.git/blob - dgee.spec
- logrotate 3.8.0 requires "su" option for non-root writable dirs
[packages/dgee.git] / dgee.spec
1 # TODO:
2 # - pnet incompatability, see -pnet.patch
3 #
4 # Conditional build:
5 %bcond_without  apache1         # disable building apache 1.3.x module
6 %bcond_without  apache2         # disable building apache 2.x module
7 %bcond_with     i_have_checked_this_patch_works_not_just_compiles
8 #
9 %define         apxs1           /usr/sbin/apxs1
10 %define         apxs2           /usr/sbin/apxs
11 %define         subver          2
12 %define         base_version    0.1.6
13 Summary:        The DotGNU Execution Environment Core
14 Summary(pl.UTF-8):      Podstawa środowiska wykonawczego DotGNU
15 Name:           dgee
16 Version:        %{base_version}_%{subver}
17 Release:        2.2
18 License:        GPL
19 Group:          Networking/Daemons
20 Source0:        http://www.nfluid.com/download/src/%{name}-%{base_version}-%{subver}.tgz
21 # Source0-md5:  a2573a076832c4c7212479cabda15eff
22 Source1:        %{name}.init
23 Source2:        %{name}.logrotate
24 Source3:        %{name}-apache.conf
25 Patch0:         %{name}-DESTDIR.patch
26 Patch1:         %{name}-apache.patch
27 Patch2:         %{name}-dglib_fix_so.patch
28 Patch3:         %{name}-pythonvm.patch
29 Patch4:         %{name}-pic.patch
30 Patch5:         %{name}-nolibnsl.patch
31 Patch6:         %{name}-pnet.patch
32 URL:            http://www.dotgnu.org/dgee.html
33 %{?with_apache1:BuildRequires:  %{apxs1}}
34 %{?with_apache2:BuildRequires:  %{apxs2}}
35 %{?with_apache2:BuildRequires:  apache-devel}
36 %{?with_apache1:BuildRequires:  apache1-devel}
37 BuildRequires:  autoconf >= 2.13
38 BuildRequires:  automake
39 BuildRequires:  expat-devel
40 BuildRequires:  gc-devel
41 BuildRequires:  goldwater-devel >= 0.3.4
42 BuildRequires:  libffi-devel
43 BuildRequires:  phlib-devel >= 1.20
44 BuildRequires:  pnet-compiler-csharp
45 BuildRequires:  pnet-devel >= 0.6.0-2
46 BuildRequires:  pnetlib-base
47 BuildRequires:  rpmbuild(macros) >= 1.268
48 Requires(post): /sbin/ldconfig
49 Requires(post,preun):   /sbin/chkconfig
50 Requires(post,preun):   rc-scripts
51 Requires:       goldwater
52 Conflicts:      logrotate < 3.8.0
53 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
54
55 %description
56 The core DotGNU Execution Environment that provides the functionality
57 of accepting, validating and satisfying web service requests.
58
59 %description -l pl.UTF-8
60 Ten pakiet zawiera podstawę środowiska wykonawczego DotGNU (DotGNU
61 Execution Environment) dostarczającą funkcjonalność przyjmowania,
62 sprawdzania poprawności i wykonywania żądań usług WWW.
63
64 %package -n apache1-mod_dgee
65 Summary:        DGEE DSO module for Apache 1.3.x
66 Summary(pl.UTF-8):      Moduł DSO DGEE dla Apache'a 1.3.x
67 Group:          Networking/Daemons
68 Requires:       %{name} = %{version}-%{release}
69 Requires:       apache1(EAPI) >= 1.3.33-2
70 Requires:       apache1-mod_mime
71
72 %description -n apache1-mod_dgee
73 The DotGNU Execution Environment Core DSO module for Apache 1.3.x.
74
75 %description -n apache1-mod_dgee -l pl.UTF-8
76 Moduł DSO podstawy środowiska wykonawczego DotGNU (DotGNU Execution
77 Environment) dla Apache'a 1.3.x.
78
79 %package -n apache-mod_dgee
80 Summary:        DGEE DSO module for Apache 2.x
81 Summary(pl.UTF-8):      Moduł DSO DGEE dla Apache'a 2.x
82 Group:          Networking/Daemons
83 Requires:       %{name} = %{version}-%{release}
84 Requires:       apache(modules-api) = %{apache_modules_api}
85 Requires:       apache-mod_mime
86
87 %description -n apache-mod_dgee
88 The DotGNU Execution Environment Core DSO module for Apache 2.x.
89
90 %description -n apache-mod_dgee -l pl.UTF-8
91 Moduł DSO podstawy środowiska wykonawczego DotGNU (DotGNU Execution
92 Environment) dla Apache'a 1.3.x.
93
94 %prep
95 %setup -q -n %{name}-%{base_version}
96 %patch0 -p1
97 %patch1 -p1
98 %patch2 -p1
99 %patch3 -p1
100 %patch4 -p1
101 %patch5 -p1
102 %{?with_i_have_checked_this_patch_works_not_just_compiles:%patch6 -p1}
103
104 %build
105 %{__aclocal}
106 %{__autoconf}
107 %{__autoheader}
108 %{__automake}
109 CFLAGS="%{rpmcflags} -I/usr/include/python2.4"
110 export CFLAGS
111 %configure \
112         cflags=our \
113         --with-goldwater=%{_prefix} \
114         --with-pnet=%{_prefix} \
115         --with-repository=/var/lib/%{name} \
116         --with-username=http \
117         --with-usergroup=http \
118         --with-python \
119         %{?with_apache1:--with-apache=%{apxs1}} \
120         %{?with_apache2:--with-apache2=%{apxs2}}
121
122 %{__make} -j1
123
124 %install
125 rm -rf $RPM_BUILD_ROOT
126
127 %{__make} install \
128         DESTDIR=$RPM_BUILD_ROOT
129
130 # Thise files should be installed by Makefile (I can't fix it):
131 install cslib/DotGNU/DGEE/DotGNU.DGEE.dll \
132         $RPM_BUILD_ROOT%{_libdir}/%{name}
133 install cslib/System/Web/Services/System.Web.Services.dll \
134         $RPM_BUILD_ROOT%{_libdir}/%{name}
135 install cslib/DotGNU/DGEE/Protocols/XmlRpc/XmlRpcService.exe \
136         $RPM_BUILD_ROOT%{_libdir}/%{name}
137
138 install -d $RPM_BUILD_ROOT/var/lib/%{name}/{index,data}
139 install -d $RPM_BUILD_ROOT/var/log/%{name}
140 touch $RPM_BUILD_ROOT/var/log/%{name}/{%{name}.log,stdout,stderr}
141 install -d $RPM_BUILD_ROOT/var/log/archive/%{name}
142 install -d $RPM_BUILD_ROOT/etc/rc.d/init.d
143 install %{SOURCE1} $RPM_BUILD_ROOT/etc/rc.d/init.d/%{name}
144 install -d $RPM_BUILD_ROOT/etc/logrotate.d
145 install %{SOURCE2} $RPM_BUILD_ROOT/etc/logrotate.d/%{name}
146
147 %if %{with apache1}
148 install -Dp %{SOURCE3} $RPM_BUILD_ROOT/etc/apache/conf.d/40_mod_dgee.conf
149 %endif
150 %if %{with apache2}
151 install -Dp %{SOURCE3} $RPM_BUILD_ROOT/etc/httpd/httpd.conf/40_mod_dgee.conf
152 %endif
153
154 %clean
155 rm -rf $RPM_BUILD_ROOT
156
157 %post
158 /sbin/ldconfig
159 /sbin/chkconfig --add dgee
160 %service dgee restart "goltwater and dgee services"
161
162 %preun
163 if [ "$1" = "0" ]; then
164         %service dgee stop
165         /sbin/chkconfig --del dgee
166 fi
167
168 %postun -p /sbin/ldconfig
169
170 %post -n apache1-mod_dgee
171 %service -q apache restart
172
173 %postun -n apache1-mod_dgee
174 if [ "$1" = 0 ]; then
175         %service -q apache restart
176 fi
177
178 %post -n apache-mod_dgee
179 %service -q httpd restart
180
181 %postun -n apache-mod_dgee
182 if [ "$1" = 0 ]; then
183         %service -q httpd restart
184 fi
185
186 %files
187 %defattr(644,root,root,755)
188 %doc BINARYINSTALL INSTALL QUICKSTART README
189 %attr(755,root,root) %{_bindir}/*
190 %attr(755,root,root) %{_libdir}/libdgee.so.*.*
191 %attr(755,root,root) %{_libdir}/libdgxml.so.*.*
192 %dir %{_libdir}/%{name}
193 %attr(755,root,root) %{_libdir}/%{name}/*
194 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}*
195 %{_datadir}/%{name}
196 /var/lib/%{name}
197 %attr(754,root,root) /etc/rc.d/init.d/%{name}
198 %attr(730,root,http) %dir /var/log/%{name}
199 %attr(660,root,http) /var/log/%{name}/*
200 %attr(750,root,root) %dir /var/log/archive/%{name}
201 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/logrotate.d/*
202
203 %if %{with apache1}
204 %files -n apache1-mod_dgee
205 %defattr(644,root,root,755)
206 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/apache/conf.d/*_mod_%{name}.conf
207 %attr(755,root,root) %{_libdir}/apache1/mod_%{name}.so
208 %endif
209
210 %if %{with apache2}
211 %files -n apache-mod_dgee
212 %defattr(644,root,root,755)
213 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/httpd/httpd.conf/*_mod_%{name}.conf
214 %attr(755,root,root) %{_libdir}/apache/mod_%{name}.so
215 %endif
This page took 0.106736 seconds and 3 git commands to generate.