rt.spec 17 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440
  1. ##
  2. ## rt.spec -- OpenPKG RPM Package Specification
  3. ## Copyright (c) 2000-2008 OpenPKG Foundation e.V. <http://openpkg.net/>
  4. ##
  5. ## Permission to use, copy, modify, and distribute this software for
  6. ## any purpose with or without fee is hereby granted, provided that
  7. ## the above copyright notice and this permission notice appear in all
  8. ## copies.
  9. ##
  10. ## THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  11. ## WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
  12. ## MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
  13. ## IN NO EVENT SHALL THE AUTHORS AND COPYRIGHT HOLDERS AND THEIR
  14. ## CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  15. ## SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  16. ## LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  17. ## USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  18. ## ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  19. ## OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  20. ## OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  21. ## SUCH DAMAGE.
  22. ##
  23. # package versions
  24. %define V_rt 3.6.7
  25. %define V_log_dispatch 2.21
  26. %define V_html_mason 1.39
  27. %define V_mldbm 2.01
  28. %define V_html_format 2.04
  29. %define V_html_scrubber 0.08
  30. %define V_module_version 1.02
  31. # package information
  32. Name: rt
  33. Summary: Request Tracker
  34. URL: http://bestpractical.com/rt/
  35. Vendor: Best Practical
  36. Packager: OpenPKG Foundation e.V.
  37. Distribution: OpenPKG Community
  38. Class: EVAL
  39. Group: Ticketing
  40. License: GPL
  41. Version: %{V_rt}
  42. Release: 20080617
  43. # package options
  44. %option with_db_sqlite no
  45. %option with_db_mysql yes
  46. %option with_db_pgsql no
  47. %option with_db_oracle no
  48. # fixing conflicting options
  49. %if "%{with_db_sqlite}" == "yes" || "%{with_db_pgsql}" == "yes" || "%{with_db_oracle}" == "yes"
  50. %undefine with_db_mysql
  51. %define with_db_mysql no
  52. %endif
  53. # list of sources
  54. Source0: http://download.bestpractical.com/pub/rt/release/rt-%{V_rt}.tar.gz
  55. Source1: http://www.cpan.org/modules/by-module/Log/Log-Dispatch-%{V_log_dispatch}.tar.gz
  56. Source2: http://www.cpan.org/modules/by-module/HTML/HTML-Mason-%{V_html_mason}.tar.gz
  57. Source3: http://www.cpan.org/modules/by-authors/id/C/CH/CHAMAS/MLDBM-%{V_mldbm}.tar.gz
  58. Source4: http://www.cpan.org/modules/by-authors/id/S/SB/SBURKE/HTML-Format-%{V_html_format}.tar.gz
  59. Source5: http://www.cpan.org/modules/by-authors/id/P/PO/PODMASTER/HTML-Scrubber-%{V_html_scrubber}.tar.gz
  60. Source6: http://www.cpan.org/modules/by-authors/id/S/SB/SBURKE/Module-Versions-Report-%{V_module_version}.tar.gz
  61. Source7: rc.rt
  62. Source8: rtsetup
  63. Source9: rtcleanup
  64. Source10: rtupgrade
  65. Source11: rtapachectl
  66. Source12: rtapache.conf
  67. Source13: config.layout
  68. Source14: rt-mailgate.sh
  69. Patch0: rt.patch
  70. # build information
  71. Prefix: %{l_prefix}
  72. BuildRoot: %{l_buildroot}
  73. BuildPreReq: OpenPKG, openpkg >= 20060823, perl, perl-openpkg >= 5.8.3-20051031
  74. PreReq: OpenPKG, openpkg >= 20060823, perl
  75. BuildPreReq: perl-sys, perl-util, perl-ds, perl-text, perl-apache, perl-module
  76. PreReq: perl-sys, perl-util, perl-ds, perl-text, perl-apache, perl-module
  77. BuildPreReq: perl-dbi, perl-dbix, perl-mail, perl-www, perl-locale, perl-devel, perl-cache
  78. PreReq: perl-dbi, perl-dbix, perl-mail, perl-www, perl-locale, perl-devel, perl-cache
  79. BuildPreReq: apache, apache-perl
  80. PreReq: apache, apache-perl
  81. %if "%{with_db_sqlite}" == "yes"
  82. PreReq: sqlite, perl-dbi::with_dbd_sqlite = yes
  83. %endif
  84. %if "%{with_db_mysql}" == "yes"
  85. PreReq: mysql, mysql::with_innobase = yes, perl-dbi::with_dbd_mysql = yes
  86. %endif
  87. %if "%{with_db_pgsql}" == "yes"
  88. PreReq: postgresql, perl-dbi::with_dbd_pgsql = yes
  89. %endif
  90. %if "%{with_db_oracle}" == "yes"
  91. PreReq: oracle, perl-dbi::with_dbd_oracle = yes
  92. %endif
  93. PreReq: MTA
  94. AutoReq: no
  95. AutoReqProv: no
  96. %description
  97. RT is an industrial-grade ticketing system. It lets a group of
  98. people intelligently and efficiently manage requests submitted by a
  99. community of users. RT is used by systems administrators, customer
  100. support staffs, NOCs, developers and even marketing departments at
  101. over a thousand sites around the world.
  102. %track
  103. prog rt = {
  104. version = %{V_rt}
  105. url = http://bestpractical.com/rt/download.html
  106. regex = rt-(__VER__)\.tar\.gz
  107. }
  108. prog rt:html-format = {
  109. version = %{V_html_format}
  110. url = http://www.cpan.org/modules/by-authors/id/S/SB/SBURKE/
  111. regex = HTML-Format-(__VER__)\.tar\.gz
  112. }
  113. prog rt:html-mason = {
  114. version = %{V_html_mason}00
  115. url = http://www.cpan.org/modules/by-module/HTML/
  116. regex = HTML-Mason-(__VER__)\.tar\.gz
  117. transform = "s/^(\\d+\\.\\d\\d)$/${1}00/; $_"
  118. }
  119. prog rt:log-dispatch = {
  120. version = %{V_log_dispatch}
  121. url = http://www.cpan.org/modules/by-module/Log/
  122. regex = Log-Dispatch-(__VER__)\.tar\.gz
  123. }
  124. prog rt:mldbm = {
  125. version = %{V_mldbm}
  126. url = http://www.cpan.org/modules/by-authors/id/C/CH/CHAMAS/
  127. regex = MLDBM-(__VER__)\.tar\.gz
  128. }
  129. prog rt:html-scrubber = {
  130. version = %{V_html_scrubber}
  131. url = http://www.cpan.org/modules/by-authors/id/P/PO/PODMASTER/
  132. regex = HTML-Scrubber-(__VER__)\.tar\.gz
  133. }
  134. prog rt:module-version = {
  135. version = %{V_module_version}
  136. url = http://www.cpan.org/modules/by-authors/id/S/SB/SBURKE/
  137. regex = Module-Versions-Report-(__VER__)\.tar\.gz
  138. }
  139. %prep
  140. # unpack distribution tarballs
  141. %setup -q -c
  142. %setup -q -T -D -a 1
  143. %setup -q -T -D -a 2
  144. %setup -q -T -D -a 3
  145. %setup -q -T -D -a 4
  146. %setup -q -T -D -a 5
  147. %setup -q -T -D -a 6
  148. # patch RT distribution
  149. cd rt-%{V_rt}
  150. %patch -p0
  151. %{l_shtool} install -c -m 0644 %{l_value -s -a} \
  152. %{SOURCE config.layout} .
  153. %{l_shtool} subst \
  154. -e 's;chown;true;g' \
  155. -e 's;chgrp;true;g' \
  156. -e 's;chmod;true;g' \
  157. -e 's;mkdir -p;%{l_shtool} mkdir -p;g' \
  158. Makefile.in
  159. %{l_shtool} subst \
  160. -e 's;Locale::Maketext 1\.04;Locale::Maketext 1.03;' \
  161. lib/RT/I18N.pm
  162. %{l_shtool} subst \
  163. -e 's;/usr/sbin/sendmail;%{l_prefix}/sbin/sendmail;g' \
  164. etc/RT_Config.pm.in
  165. %build
  166. # configure RT part
  167. cd rt-%{V_rt}
  168. PERL=%{l_prefix}/bin/perl
  169. ./configure \
  170. --enable-layout=OPKG \
  171. --with-db-host=localhost \
  172. --with-db-home=%{l_prefix} \
  173. %if "%{with_db_sqlite}" == "yes"
  174. --with-db-type=SQLite \
  175. --with-db-dba=%{l_rusr} \
  176. --with-db-database=%{l_prefix}/var/rt/run/rt.db \
  177. --with-db-user=rt \
  178. --with-db-pass=XXX \
  179. %endif
  180. %if "%{with_db_mysql}" == "yes"
  181. --with-db-type=mysql \
  182. --with-db-dba=root \
  183. --with-db-database=rt \
  184. --with-db-user=rt \
  185. --with-db-pass=XXX \
  186. %endif
  187. %if "%{with_db_pgsql}" == "yes"
  188. --with-db-type=Pg \
  189. --with-db-dba=postgresql \
  190. --with-db-database=rt \
  191. --with-db-user=rt \
  192. --with-db-pass=XXX \
  193. %endif
  194. %if "%{with_db_oracle}" == "yes"
  195. --with-db-type=Oracle \
  196. --with-db-dba=system \
  197. --with-db-database=rt \
  198. --with-db-user=rt \
  199. --with-db-pass=XXX \
  200. %endif
  201. --with-web-user=%{l_rusr} \
  202. --with-web-group=%{l_rgrp} \
  203. --with-customdir=%{l_prefix}/etc/rt/local \
  204. --with-customhtmldir=%{l_prefix}/etc/rt/local/html \
  205. --with-customlibdir=%{l_prefix}/etc/rt/local/lib \
  206. --with-customlexdir=%{l_prefix}/etc/rt/local/po
  207. %install
  208. rm -rf $RPM_BUILD_ROOT
  209. # perform common Perl prolog operations
  210. %{l_shtool} mkdir -f -p -m 755 ${RPM_BUILD_ROOT}%{l_prefix}/libexec/rt
  211. %{l_prefix}/bin/perl-openpkg prepare
  212. # install remaining prerequisite Perl modules which
  213. # are not part of the OpenPKG perl-xxx packages.
  214. %{l_prefix}/bin/perl-openpkg -d Log-Dispatch-%{V_log_dispatch} \
  215. -l %{l_prefix}/libexec/rt configure build install
  216. %{l_prefix}/bin/perl-openpkg -d HTML-Mason-%{V_html_mason} \
  217. -l %{l_prefix}/libexec/rt configure build install
  218. %{l_prefix}/bin/perl-openpkg -d MLDBM-%{V_mldbm} \
  219. -l %{l_prefix}/libexec/rt configure build install
  220. %{l_prefix}/bin/perl-openpkg -d HTML-Format-%{V_html_format} \
  221. -l %{l_prefix}/libexec/rt configure build install
  222. %{l_prefix}/bin/perl-openpkg -d HTML-Scrubber-%{V_html_scrubber} \
  223. -l %{l_prefix}/libexec/rt configure build install
  224. %{l_prefix}/bin/perl-openpkg -d Module-Versions-Report-%{V_module_version} \
  225. -l %{l_prefix}/libexec/rt configure build install
  226. %{l_prefix}/bin/perl-openpkg -F perl-openpkg-files fixate cleanup
  227. # create installation file hierarchy
  228. %{l_shtool} mkdir -f -p -m 0755 \
  229. $RPM_BUILD_ROOT%{l_prefix}/sbin \
  230. $RPM_BUILD_ROOT%{l_prefix}/etc/rt \
  231. $RPM_BUILD_ROOT%{l_prefix}/etc/rc.d \
  232. $RPM_BUILD_ROOT%{l_prefix}/cgi/rt \
  233. $RPM_BUILD_ROOT%{l_prefix}/share/rt \
  234. $RPM_BUILD_ROOT%{l_prefix}/libexec/rt/tools \
  235. $RPM_BUILD_ROOT%{l_prefix}/libexec/rt/etc/upgrade \
  236. $RPM_BUILD_ROOT%{l_prefix}/var/rt/mason-data \
  237. $RPM_BUILD_ROOT%{l_prefix}/var/rt/mason-session \
  238. $RPM_BUILD_ROOT%{l_prefix}/var/rt/log \
  239. $RPM_BUILD_ROOT%{l_prefix}/var/rt/run
  240. # perform RT installation procedure
  241. ( cd rt-%{V_rt}
  242. %{l_make} %{l_mflags} \
  243. config-install dirs libs-install etc-install bin-install \
  244. sbin-install html-install doc-install \
  245. DESTDIR=$RPM_BUILD_ROOT
  246. cp -rp \
  247. etc/upgrade/* \
  248. $RPM_BUILD_ROOT%{l_prefix}/libexec/rt/etc/upgrade/
  249. %{l_shtool} install -c -m 0644 \
  250. -e '/Set($WebBaseURL/s;"[^"]*";"";' \
  251. etc/RT_Config.pm \
  252. $RPM_BUILD_ROOT%{l_prefix}/etc/rt/RT_SiteConfig.pm
  253. ) || exit $?
  254. # post-adjust installation hierarchy
  255. %{l_shtool} mkln -f -s \
  256. $RPM_BUILD_ROOT%{l_prefix}/etc/rt/RT_SiteConfig.pm \
  257. $RPM_BUILD_ROOT%{l_prefix}/libexec/rt/etc/RT_SiteConfig.pm
  258. mv \
  259. $RPM_BUILD_ROOT%{l_prefix}/libexec/rt/WebRT/html/NoAuth/css/print.css \
  260. $RPM_BUILD_ROOT%{l_prefix}/etc/rt/print.css
  261. %{l_shtool} mkln -f -s \
  262. $RPM_BUILD_ROOT%{l_prefix}/etc/rt/print.css \
  263. $RPM_BUILD_ROOT%{l_prefix}/libexec/rt/WebRT/html/NoAuth/css/print.css
  264. mv \
  265. $RPM_BUILD_ROOT%{l_prefix}/libexec/rt/local \
  266. $RPM_BUILD_ROOT%{l_prefix}/etc/rt/local
  267. %{l_shtool} mkln -f -s \
  268. $RPM_BUILD_ROOT%{l_prefix}/etc/rt/local \
  269. $RPM_BUILD_ROOT%{l_prefix}/libexec/rt/local
  270. mv \
  271. $RPM_BUILD_ROOT%{l_prefix}/bin/webmux.pl \
  272. $RPM_BUILD_ROOT%{l_prefix}/bin/mason_handler.fcgi \
  273. $RPM_BUILD_ROOT%{l_prefix}/cgi/rt/
  274. mv \
  275. $RPM_BUILD_ROOT%{l_prefix}/bin/rt-crontool \
  276. $RPM_BUILD_ROOT%{l_prefix}/bin/rt-mailgate \
  277. $RPM_BUILD_ROOT%{l_prefix}/libexec/rt/tools/
  278. %{l_shtool} install -c -m 755 %{l_value -s -a} \
  279. %{SOURCE rt-mailgate.sh} \
  280. $RPM_BUILD_ROOT%{l_prefix}/bin/rt-mailgate
  281. # strip installation hierarchy
  282. rm -f $RPM_BUILD_ROOT%{l_prefix}/bin/convert*
  283. rm -f $RPM_BUILD_ROOT%{l_prefix}/bin/*.svc
  284. rm -f $RPM_BUILD_ROOT%{l_prefix}/libexec/rt/tools/rt-test-dependencies
  285. rm -rf $RPM_BUILD_ROOT%{l_prefix}/libexec/rt/t
  286. rm -f $RPM_BUILD_ROOT%{l_prefix}/libexec/rt/RT.pm.in
  287. rm -f $RPM_BUILD_ROOT%{l_prefix}/bin/xgettext.pl
  288. rm -f $RPM_BUILD_ROOT%{l_prefix}/bin/pod2test
  289. rm -rf $RPM_BUILD_ROOT%{l_prefix}/man/man3
  290. rm -rf $RPM_BUILD_ROOT%{l_prefix}/share/rt
  291. # install own setup/cleanup/upgrade script
  292. %if "%{with_db_sqlite}" == "yes"
  293. rt_db_dba=%{l_rusr}
  294. %endif
  295. %if "%{with_db_mysql}" == "yes"
  296. rt_db_dba=root
  297. %endif
  298. %if "%{with_db_pgsql}" == "yes"
  299. rt_db_dba=postgresql
  300. %endif
  301. %if "%{with_db_oracle}" == "yes"
  302. rt_db_dba=system
  303. %endif
  304. %{l_shtool} install -c -m 755 %{l_value -s -a} \
  305. -e "s;@rt_db_dba@;$rt_db_dba;g" \
  306. %{SOURCE rtsetup} %{SOURCE rtcleanup} %{SOURCE rtupgrade} \
  307. $RPM_BUILD_ROOT%{l_prefix}/sbin/
  308. # install OpenPKG run-command script
  309. %{l_shtool} install -c -m 755 %{l_value -s -a} \
  310. %{SOURCE rc.rt} \
  311. $RPM_BUILD_ROOT%{l_prefix}/etc/rc.d/
  312. # install Apache "apachectl" wrapper
  313. %{l_shtool} install -c -m 755 %{l_value -s -a} \
  314. %{SOURCE rtapachectl} \
  315. $RPM_BUILD_ROOT%{l_prefix}/libexec/rt/tools/
  316. # install Apache configuration
  317. l_hostname=`%{l_shtool} echo -e %h`
  318. l_domainname=`%{l_shtool} echo -e %d | cut -c2-`
  319. %{l_shtool} install -c -m 755 %{l_value -s -a} \
  320. -e "s;@l_hostname@;$l_hostname;g" \
  321. -e "s;@l_domainname@;$l_domainname;g" \
  322. %{SOURCE rtapache.conf} \
  323. $RPM_BUILD_ROOT%{l_prefix}/etc/rt/
  324. # final post-adjustments to installation hierarchy
  325. find $RPM_BUILD_ROOT%{l_prefix}/libexec/rt \
  326. -type f -name "*.html" -print | xargs chmod 644
  327. find $RPM_BUILD_ROOT%{l_prefix}/libexec/rt \
  328. -type f -name "*.pm" -print | xargs chmod 644
  329. find $RPM_BUILD_ROOT%{l_prefix}/libexec/rt \
  330. -type f -print | xargs chmod a+r
  331. find $RPM_BUILD_ROOT%{l_prefix}/libexec/rt \
  332. -type d -print | xargs chmod 755
  333. find ${RPM_BUILD_ROOT}${l_prefix} -name .packlist -print | xargs rm -f
  334. # determine installation files
  335. %{l_rpmtool} files -v -ofiles -r$RPM_BUILD_ROOT \
  336. %{l_files_std} `cat perl-openpkg-files` \
  337. '%{l_prefix}/libexec/rt' \
  338. '%attr(755,%{l_musr},%{l_mgrp}) %{l_prefix}/libexec/rt/tools/rt-setup-database' \
  339. '%attr(755,%{l_musr},%{l_mgrp}) %{l_prefix}/libexec/rt/tools/rt-crontool' \
  340. '%attr(755,%{l_musr},%{l_mgrp}) %{l_prefix}/libexec/rt/tools/rt-mailgate' \
  341. '%config %attr(640,%{l_musr},%{l_rgrp}) %{l_prefix}/etc/rt/RT_SiteConfig.pm' \
  342. '%config %attr(640,%{l_musr},%{l_rgrp}) %{l_prefix}/etc/rt/rtapache.conf' \
  343. '%config %attr(644,%{l_musr},%{l_rgrp}) %{l_prefix}/etc/rt/print.css' \
  344. '%attr(750,%{l_rusr},%{l_rgrp}) %{l_prefix}/var/rt/mason-data' \
  345. '%attr(750,%{l_rusr},%{l_rgrp}) %{l_prefix}/var/rt/mason-data/*' \
  346. '%attr(750,%{l_rusr},%{l_rgrp}) %{l_prefix}/var/rt/mason-session' \
  347. '%attr(750,%{l_rusr},%{l_rgrp}) %{l_prefix}/var/rt/log' \
  348. '%attr(750,%{l_rusr},%{l_rgrp}) %{l_prefix}/var/rt/run'
  349. %files -f files
  350. %clean
  351. rm -rf $RPM_BUILD_ROOT
  352. %post
  353. if [ $1 -eq 1 ]; then
  354. # activate in MTA configuration
  355. aliases_file=`$RPM_INSTALL_PREFIX/bin/openpkg rc --query MTA_aliases_file`
  356. aliases_update=`$RPM_INSTALL_PREFIX/bin/openpkg rc --query MTA_aliases_update`
  357. if [ ".$aliases_file" != . ]; then
  358. ( echo "rt: \"|$RPM_INSTALL_PREFIX/bin/rt-mailgate --action correspond --queue general --url http://127.0.0.1:8380/\""
  359. echo "rt-comment: \"|$RPM_INSTALL_PREFIX/bin/rt-mailgate --action comment --queue general --url http://127.0.0.1:8380/\""
  360. ) | %{l_rpmtool} config -a -i "$RPM_INSTALL_PREFIX:rt" $aliases_file
  361. fi
  362. if [ ".$aliases_update" != . ]; then
  363. eval $aliases_update
  364. fi
  365. # display final hint after initial installation
  366. ( echo "To complete installation of RT, please check the file"
  367. echo " $RPM_INSTALL_PREFIX/etc/rt/RT_SiteConfig.pm"
  368. echo "In particular, you have to assign a password to the RT"
  369. echo "database user. Then you have to start the MySQL RDBMS and"
  370. echo "create the initial RT database with:"
  371. echo " \$ $RPM_INSTALL_PREFIX/bin/openpkg rc mysql start"
  372. echo " \$ $RPM_INSTALL_PREFIX/sbin/rtsetup"
  373. echo "After this post-installation, start RT by running"
  374. echo " \$ $RPM_INSTALL_PREFIX/bin/openpkg rc rt start"
  375. echo "and connect with a browser to:"
  376. echo " http://127.0.0.1:8380/"
  377. echo "Login as 'root' (with initial password 'password')"
  378. echo "to change the password to a custom one."
  379. ) | %{l_rpmtool} msg -b -t notice
  380. elif [ $1 -gt 1 ]; then
  381. # display final hint after upgrading
  382. ( echo "If you have an old RT database you can erase it with:"
  383. echo " \$ $RPM_INSTALL_PREFIX/sbin/rtcleanup"
  384. echo "Upgrading from an earlier RT 3.x database you can with:"
  385. echo " \$ $RPM_INSTALL_PREFIX/sbin/rtupgrade <old-rt-version>"
  386. ) | %{l_rpmtool} msg -b -t notice
  387. fi
  388. %preun
  389. if [ $1 -eq 0 ]; then
  390. # stop perhaps still running server
  391. $RPM_INSTALL_PREFIX/bin/openpkg rc rt stop
  392. # deactivate in MTA configuration
  393. aliases_file=`$RPM_INSTALL_PREFIX/bin/openpkg rc --query MTA_aliases_file`
  394. aliases_update=`$RPM_INSTALL_PREFIX/bin/openpkg rc --query MTA_aliases_update`
  395. if [ ".$aliases_file" != . ]; then
  396. %{l_rpmtool} config -r -i "$RPM_INSTALL_PREFIX:rt" $aliases_file
  397. fi
  398. if [ ".$aliases_update" != . ]; then
  399. eval $aliases_update
  400. fi
  401. # remove generated files
  402. rm -f $RPM_INSTALL_PREFIX/var/rt/mason-session/*
  403. rm -rf $RPM_INSTALL_PREFIX/var/rt/mason-data/*/*
  404. rm -f $RPM_INSTALL_PREFIX/var/rt/log/*
  405. rm -f $RPM_INSTALL_PREFIX/var/rt/run/apache.pid
  406. rm -f $RPM_INSTALL_PREFIX/var/rt/run/ssl_scache
  407. fi