1 |
# $Id: smeserver-mailman.spec,v 1.1 2021/01/01 10:30:06 brianr Exp $ |
# $Id: smeserver-mailman.spec,v 1.21 2022/11/11 16:04:52 jpp Exp $ |
2 |
# Authority: gordonr |
# Authority: gordonr |
3 |
# Name: Gordon Rowell |
# Name: Gordon Rowell |
4 |
|
|
5 |
# avoid brp bytecompile |
# avoid brp bytecompile |
6 |
%define __os_install_post %{nil} |
%define __os_install_post %{nil} |
7 |
|
%define debug_package %{nil} |
8 |
|
|
9 |
Summary: Mailman configuration for SME server. |
Summary: Mailman configuration for SME server. |
10 |
%define name smeserver-mailman |
%define name smeserver-mailman |
11 |
Name: %{name} |
Name: %{name} |
12 |
%define version 1.5.0 |
%define version 1.5.0 |
13 |
%define release 8 |
%define release 21 |
14 |
Version: %{version} |
Version: %{version} |
15 |
Release: %{release}%{?dist} |
Release: %{release}%{?dist} |
16 |
License: GPL |
License: GPL |
19 |
BuildRoot: /var/tmp/%{name}-%{version}-%{release}-buildroot |
BuildRoot: /var/tmp/%{name}-%{version}-%{release}-buildroot |
20 |
BuildArchitectures: noarch |
BuildArchitectures: noarch |
21 |
Requires: e-smith-base |
Requires: e-smith-base |
22 |
Requires: e-smith-release >= 9.0 |
Requires: e-smith-release >= 10.0 |
23 |
|
Requires: e-smith-apache >= 2.6.0-19 |
24 |
Requires: mailman >= 2.1.9-20.el5.sme |
Requires: mailman >= 2.1.9-20.el5.sme |
25 |
Requires: e-smith-formmagick >= 1.4.0-12 |
Requires: e-smith-formmagick >= 1.4.0-12 |
26 |
BuildRequires: e-smith-devtools >= 1.13.1-03 |
BuildRequires: e-smith-devtools >= 1.13.1-03 |
27 |
Obsoletes: e-smith-mailman |
Obsoletes: e-smith-mailman |
28 |
Provides: e-smith-mailman |
Provides: e-smith-mailman |
29 |
AutoReqProv: no |
AutoReqProv: no |
30 |
Patch0: smeserver-mailman-1.5.0.bz2411.Backup_mailman.patch |
#Patch0: smeserver-mailman-1.5.0.bz2411.Backup_mailman.patch |
31 |
Patch1: smeserver-mailman-1.5.0-locale-2016-03-09.patch |
Patch1: smeserver-mailman-1.5.0-locale-2016-03-09.patch |
32 |
|
Patch2: smeserver-mailman-1.5.0-locale-2021-08-22.patch |
33 |
|
Patch3: smeserver-mailman-1.5.0-bz11278-systemd.patch |
34 |
|
Patch4: smeserver-mailman-1.5.0-bz11278-wrapper.patch |
35 |
|
Patch5: smeserver-mailman-1.5.0-bz11937.patch |
36 |
|
Patch6: smeserver-mailman-1.5.0-bz11941-checkperms.patch |
37 |
|
Patch7: smeserver-mailman-1.5.0-bz2248-bz2247-enabled-localonly.patch |
38 |
|
Patch8: smeserver-mailman-1.5.0-locale-2022-07-24.patch |
39 |
|
Patch9: smeserver-mailman-1.5.0-bz12015-backup.patch |
40 |
|
Patch10: smeserver-mailman-1.5.0-bz12050-24syntax.patch |
41 |
|
Patch11: smeserver-mailman-1.5.0-locale-2022-11-11.patch |
42 |
|
Patch12: smeserver-mailman-1.5.0-locale-2024-09-05.patch |
43 |
|
|
44 |
%description |
%description |
45 |
Add Mailman integration to the SME server. |
Add Mailman integration to the SME server. |
46 |
|
|
47 |
%changelog |
%changelog |
48 |
|
* Fri Sep 06 2024 terry Fage <terry@fage.id.au> 1.5.0-21.sme |
49 |
|
- apply locale 2024-09-05.patch |
50 |
|
|
51 |
|
* Fri Nov 11 2022 Jean-Philippe Pialasse <tests@pialasse.com> 1.5.0-20.sme |
52 |
|
- apply locale 2022-11-11 patch |
53 |
|
|
54 |
|
* Sat Jul 30 2022 Brian Read <brianr@bjsystems.co.uk> 1.5.0-18.sme |
55 |
|
- Re-build and link to latest devtools [SME: 11997] |
56 |
|
|
57 |
|
* Sat Jul 30 2022 Jean-Philippe Pialasse <tests@pialasse.com> 1.5.0-17.sme |
58 |
|
- update to httpd 2.4 access syntax [SME: 12050] |
59 |
|
- rebuild for core backup [SME: 12015] |
60 |
|
|
61 |
|
* Sat Jul 23 2022 Jean-Philippe Pialasse <tests@pialasse.com> 1.5.0-16.sme |
62 |
|
- apply locale 2022-07-24.patch |
63 |
|
- add to core backup [SME: 12015] |
64 |
|
remove patch only adding to dar in SME 2411 |
65 |
|
- already compatible with httpd 2.4 syntax [SME: 12050] |
66 |
|
|
67 |
|
* Tue Apr 12 2022 Jean-Philippe Pialasse <tests@pialasse.com> 1.5.0-15.sme |
68 |
|
- Re-build and link to latest devtools permissions as expected by mailman [SME: 11941] |
69 |
|
- make mailman enabled on install [SME: 2248] |
70 |
|
- by default listinfo is public [SME: 2247] |
71 |
|
- by default admin and archives are private [SME: 2247] |
72 |
|
- make access modifiable [SME: 2247] |
73 |
|
|
74 |
|
* Tue Apr 12 2022 Jean-Philippe Pialasse <tests@pialasse.com> 1.5.0-14.sme |
75 |
|
- increase master password size to 18 [SME: 11937] |
76 |
|
|
77 |
|
* Sun Apr 10 2022 Jean-Philippe Pialasse <tests@pialasse.com> 1.5.0-13.sme |
78 |
|
- add c wrapper with setuid [SME: 11278] |
79 |
|
|
80 |
|
* Sun Apr 10 2022 Jean-Philippe Pialasse <tests@pialasse.com> 1.5.0-12.sme |
81 |
|
- Re-build and link to latest devtools missing service start [SME: 11278] |
82 |
|
add update event |
83 |
|
|
84 |
|
* Tue Mar 15 2022 Jean-Philippe Pialasse <tests@pialasse.com> 1.5.0-11.sme |
85 |
|
- Re-build and link to latest devtools www line should be after apache line in /etc/group [SME: 8056] |
86 |
|
|
87 |
|
* Mon Aug 23 2021 Terry Fage <terry.fage@gmail.com> 1.5.0-10.sme |
88 |
|
- apply locale 2021-08-22 patch |
89 |
|
|
90 |
|
* Thu Jun 03 2021 Jean-Philippe Pialasse <tests@pialasse.com> 1.5.0-9.sme |
91 |
|
- Re-build and link to latest devtools conflicting folders [SME: 11278] |
92 |
|
|
93 |
* Mon Feb 22 2021 JP Pialasse <tests@pialasse.com> 1.5.0-8.sme |
* Mon Feb 22 2021 JP Pialasse <tests@pialasse.com> 1.5.0-8.sme |
94 |
- Eliminated rpmbuild "bogus date" warnings due to inconsistent weekday, |
- Eliminated rpmbuild "bogus date" warnings due to inconsistent weekday, |
95 |
by assuming the date is correct and changing the weekday. |
by assuming the date is correct and changing the weekday. |
114 |
- Initial release to sme9 |
- Initial release to sme9 |
115 |
|
|
116 |
* Fri Sep 20 2013 JP Pialasse <tests@pialasse.com> 1.3.0-45.sme |
* Fri Sep 20 2013 JP Pialasse <tests@pialasse.com> 1.3.0-45.sme |
117 |
- fix bug [SME: 7787] |
- Re-build and link to latest devtools bug [SME: 7787] |
118 |
|
|
119 |
* Thu Sep 19 2013 JP Pialasse <tests@pialasse.com> 1.3.0-44.sme |
* Thu Sep 19 2013 JP Pialasse <tests@pialasse.com> 1.3.0-44.sme |
120 |
- fix case sensitive TRUE to true in smeserver-mailman-1.3.0-restarthang.patch |
- Re-build and link to latest devtools case sensitive TRUE to true in smeserver-mailman-1.3.0-restarthang.patch |
121 |
- wrong path to actions folder fixed |
- wrong path to actions folder fixed |
122 |
- see [SME: 7845] |
- see [SME: 7845] |
123 |
|
|
125 |
- apply locale 2013-07-14 patch |
- apply locale 2013-07-14 patch |
126 |
|
|
127 |
* Sun Jul 14 2013 JP Pialasse <tests@pialasse.com> 1.3.0-41.sme |
* Sun Jul 14 2013 JP Pialasse <tests@pialasse.com> 1.3.0-41.sme |
128 |
- fix signal-event hang on mailman restart [SME ] |
- Re-build and link to latest devtools signal-event hang on mailman restart [SME ] |
129 |
* Mon Jul 01 2013 JP Pialasse <tests@pialasse.com> 1.3.0-40.sme |
* Mon Jul 01 2013 JP Pialasse <tests@pialasse.com> 1.3.0-40.sme |
130 |
- fix expanding pyc pyo [SME: 7730] |
- Re-build and link to latest devtools expanding pyc pyo [SME: 7730] |
131 |
|
|
132 |
* Mon Jul 01 2013 JP Pialasse <tests@pialasse.com> 1.3.0-38.sme |
* Mon Jul 01 2013 JP Pialasse <tests@pialasse.com> 1.3.0-38.sme |
133 |
- import to sme8 buildsys |
- import to sme8 buildsys |
134 |
- fix bootstrap hang [SME: 6693] |
- Re-build and link to latest devtools bootstrap hang [SME: 6693] |
135 |
|
|
136 |
* Tue Mar 20 2012 SME Translation Server <translations@contribs.org> 1.3.0-37.el6 |
* Tue Mar 20 2012 SME Translation Server <translations@contribs.org> 1.3.0-37.el6 |
137 |
- apply locale 2012-03-20 patch |
- apply locale 2012-03-20 patch |
355 |
|
|
356 |
%prep |
%prep |
357 |
%setup |
%setup |
358 |
%patch0 -p1 |
#%patch0 -p1 |
359 |
%patch1 -p1 |
%patch1 -p1 |
360 |
|
%patch2 -p1 |
361 |
|
%patch3 -p1 |
362 |
|
%patch4 -p1 |
363 |
|
%patch5 -p1 |
364 |
|
%patch6 -p1 |
365 |
|
%patch7 -p1 |
366 |
|
%patch8 -p1 |
367 |
|
%patch9 -p1 |
368 |
|
%patch10 -p1 |
369 |
|
%patch11 -p1 |
370 |
|
%patch12 -p1 |
371 |
|
|
372 |
#/bin/rm -r root/opt/mailman |
#/bin/rm -r root/opt/mailman |
373 |
|
|
374 |
%build |
%build |
375 |
perl createlinks |
perl createlinks |
376 |
|
gcc -o root/usr/lib/mailman/bin/smelist smelist.c |
377 |
|
|
378 |
|
|
379 |
mkdir -p root/usr/lib/mailman/aliases |
mkdir -p root/usr/lib/mailman/aliases |
380 |
|
|
381 |
mkdir -p root/opt |
mkdir -p root/opt |
386 |
mkdir -p root/var/spool/mailman/qfiles/$dir |
mkdir -p root/var/spool/mailman/qfiles/$dir |
387 |
done |
done |
388 |
|
|
|
|
|
389 |
%install |
%install |
390 |
rm -rf $RPM_BUILD_ROOT |
rm -rf $RPM_BUILD_ROOT |
391 |
(cd root ; find . -depth -print | cpio -dump $RPM_BUILD_ROOT) |
(cd root ; find . -depth -print | cpio -dump $RPM_BUILD_ROOT) |
392 |
rm -f e-smith-%{version}-filelist |
rm -f e-smith-%{version}-filelist |
393 |
/sbin/e-smith/genfilelist \ |
/sbin/e-smith/genfilelist \ |
|
--dir '/usr/lib/mailman' 'attr(02775,root,mailman)' \ |
|
|
--dir '/usr/lib/mailman/bin' 'attr(02775,root,mailman)' \ |
|
394 |
--dir '/var/spool/mailman' 'attr(02775,root,mailman)' \ |
--dir '/var/spool/mailman' 'attr(02775,root,mailman)' \ |
395 |
--dir '/usr/lib/mailman/aliases' 'attr(02775,mailman,mailman)' \ |
--dir '/usr/lib/mailman/aliases' 'attr(02775,mailman,mailman)' \ |
396 |
--file '/usr/lib/mailman/bin/post-install' 'attr(0755,root,mailman)' \ |
--file '/usr/lib/mailman/bin/post-install' 'attr(0755,root,mailman)' \ |
397 |
--file '/usr/lib/mailman/bin/smelist' 'attr(04755,root,mailman)' \ |
--file '/usr/lib/mailman/bin/smelist' 'attr(04755,root,mailman)' \ |
398 |
--dir '/usr/lib/mailman/Mailman' 'attr(02775,root,mailman)' \ |
--file '/usr/lib/mailman/bin/smelist.pl' 'attr(02755,root,mailman)' \ |
399 |
--dir '/usr/lib/mailman/Mailman/MTA' 'attr(02775,root,mailman)' \ |
--file '/usr/lib/mailman/Mailman/MTA/SME.py' 'attr(02775,mailman,mailman)' \ |
400 |
--file '/usr/lib/mailman/Mailman/MTA/SME.py' 'attr(02775,root,mailman)' \ |
--dir '/var/spool/mailman/qfiles' 'attr(02775,mailman,mailman)' \ |
|
--dir '/var/spool/mailman/qfiles' 'attr(02770,mailman,mailman)' \ |
|
401 |
--dir '/var/spool/mailman/qfiles/archive' 'attr(02770,mailman,mailman)' \ |
--dir '/var/spool/mailman/qfiles/archive' 'attr(02770,mailman,mailman)' \ |
402 |
--dir '/var/spool/mailman/qfiles/bounces' 'attr(02770,mailman,mailman)' \ |
--dir '/var/spool/mailman/qfiles/bounces' 'attr(02770,mailman,mailman)' \ |
403 |
--dir '/var/spool/mailman/qfiles/commands' 'attr(02770,mailman,mailman)' \ |
--dir '/var/spool/mailman/qfiles/commands' 'attr(02770,mailman,mailman)' \ |
409 |
--dir '/var/spool/mailman/qfiles/virgin' 'attr(02770,mailman,mailman)' \ |
--dir '/var/spool/mailman/qfiles/virgin' 'attr(02770,mailman,mailman)' \ |
410 |
$RPM_BUILD_ROOT > %{name}-%{version}-filelist |
$RPM_BUILD_ROOT > %{name}-%{version}-filelist |
411 |
|
|
412 |
# SME8 build to avoid error |
sed -i -e '/\/usr\/lib\/mailman$/d ; /\/usr\/lib\/mailman\/bin$/d ; /\/usr\/lib\/mailman\/Mailman$/d ; /\/usr\/lib\/mailman\/Mailman\/MTA$/d ' %{name}-%{version}-filelist |
413 |
#/usr/lib/rpm/brp-python-bytecompile |
#those will conflict with mailman rpm on sme10 |
414 |
#rm -rf $RPM_BUILD_ROOT/etc/e-smith/events/domain-create/templates2expand/usr/lib/mailman/Mailman/mm_cfg.pyc |
# --dir '/usr/lib/mailman' 'attr(02775,root,mailman)' \ |
415 |
#rm -rf $RPM_BUILD_ROOT/etc/e-smith/events/domain-create/templates2expand/usr/lib/mailman/Mailman/mm_cfg.pyo |
# --dir '/usr/lib/mailman/bin' 'attr(02775,root,mailman)' \ |
416 |
#rm -rf $RPM_BUILD_ROOT/etc/e-smith/events/domain-delete/templates2expand/usr/lib/mailman/Mailman/mm_cfg.pyc |
# --dir '/usr/lib/mailman/Mailman' 'attr(02775,root,mailman)' \ |
417 |
#rm -rf $RPM_BUILD_ROOT/etc/e-smith/events/domain-delete/templates2expand/usr/lib/mailman/Mailman/mm_cfg.pyo |
# --dir '/usr/lib/mailman/Mailman/MTA' 'attr(02775,root,mailman)' \ |
|
#rm -rf $RPM_BUILD_ROOT/etc/e-smith/events/bootstrap-console-save/templates2expand/usr/lib/mailman/Mailman/mm_cfg.pyc |
|
|
#rm -rf $RPM_BUILD_ROOT/etc/e-smith/events/bootstrap-console-save/templates2expand/usr/lib/mailman/Mailman/mm_cfg.pyo |
|
|
#rm -rf $RPM_BUILD_ROOT/etc/e-smith/events/mailman-update/templates2expand/usr/lib/mailman/Mailman/mm_cfg.pyc |
|
|
#rm -rf $RPM_BUILD_ROOT/etc/e-smith/events/mailman-update/templates2expand/usr/lib/mailman/Mailman/mm_cfg.pyo |
|
|
#rm -rf $RPM_BUILD_ROOT/usr/lib/mailman/Mailman/mm_cfg.pyc |
|
|
#rm -rf $RPM_BUILD_ROOT/usr/lib/mailman/Mailman/mm_cfg.pyo |
|
|
#rm -rf $RPM_BUILD_ROOT/usr/lib/mailman/Mailman/MTA/SME.pyc |
|
|
#rm -rf $RPM_BUILD_ROOT/usr/lib/mailman/Mailman/MTA/SME.pyo |
|
418 |
|
|
419 |
# fixe for unwanted listed compiled python files |
# SME10 to avoid error |
420 |
|
#/usr/lib/rpm/brp-python-bytecompile |
421 |
|
# fix for unwanted listed compiled python files |
422 |
|
# those pyc and pyo gets added by default by genfilelist, so need to filtering them out when we disable byte compile. |
423 |
|
#"/etc/e-smith/events/domain-create/templates2expand/usr/lib/mailman/Mailman/mm_cfg.pyc" |
424 |
|
#"/etc/e-smith/events/domain-create/templates2expand/usr/lib/mailman/Mailman/mm_cfg.pyo" |
425 |
|
#/etc/e-smith/events/domain-create/templates2expand/usr/lib/mailman/Mailman/mm_cfg.pyc |
426 |
cat %{name}-%{version}-filelist |sed -r '/py[oc]"?$/d'>%{name}-%{version}-filelist.tmp |
cat %{name}-%{version}-filelist |sed -r '/py[oc]"?$/d'>%{name}-%{version}-filelist.tmp |
427 |
cat %{name}-%{version}-filelist.tmp> %{name}-%{version}-filelist |
cat %{name}-%{version}-filelist.tmp> %{name}-%{version}-filelist |
|
#rm -rf %{name}-%{version}-filelist.tmp |
|
428 |
|
|
429 |
%clean |
%clean |
430 |
rm -rf $RPM_BUILD_ROOT |
rm -rf $RPM_BUILD_ROOT |
438 |
"Mailman user" /usr/lib/mailman /bin/false |
"Mailman user" /usr/lib/mailman /bin/false |
439 |
|
|
440 |
#mailman wants that the apache group appears before the www group in /etc/group [SME: 8056] |
#mailman wants that the apache group appears before the www group in /etc/group [SME: 8056] |
441 |
TEST=$(grep -P '^www|apache' /etc/group) |
TEST=`egrep "^apache:" /etc/group -n| cut -f1 -d:` |
442 |
TEST2='www:x:102:admin |
TEST2=`egrep "^www:" /etc/group -n| cut -f1 -d:` |
443 |
apache:x:102:' |
if [[ $TEST > $TEST2 ]]; then |
|
|
|
|
if [[ $TEST == $TEST2 ]]; then |
|
444 |
WWW=$(sed -n '/^www/p' /etc/group) |
WWW=$(sed -n '/^www/p' /etc/group) |
445 |
sed -i '/^www/d' /etc/group |
sed -i '/^www/d' /etc/group |
446 |
echo $WWW >> /etc/group |
echo $WWW >> /etc/group |