/[smeserver]/rpms/smeserver-mock/sme10/smeserver-mock.spec
ViewVC logotype

Annotation of /rpms/smeserver-mock/sme10/smeserver-mock.spec

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph


Revision 1.24 - (hide annotations) (download)
Sun Apr 30 06:19:47 2023 UTC (19 months ago) by terryfage
Branch: MAIN
CVS Tags: smeserver-mock-1_0-19_el7_sme
Changes since 1.23: +8 -2 lines
* Sun Apr 30 2023 TerryFage <terry.fage@gmail.com> 1.0-19.sme
- add package to mock*.cfg facilitate cvm build [SME: 12350]
- attribute solution to Trevor batley

1 terryfage 1.24 # $Id: smeserver-mock.spec,v 1.23 2023/04/14 02:57:42 jpp Exp $
2 jpp 1.20 %global __os_install_post %(echo '%{__os_install_post}' | sed -e 's!/usr/lib[^[:space:]]*/brp-python-bytecompile[[:space:]].*$!!g')
3 jpp 1.1 Summary: smeserver-mock tools for building RPMs
4 jpp 1.2 %define name smeserver-mock
5 jpp 1.1 Name: %{name}
6     %define version 1.0
7 terryfage 1.24 %define release 19
8 jpp 1.1 Version: %{version}
9     Release: %{release}%{?dist}
10     License: GPL
11     Group: Networking/Daemons
12     Source: %{name}-%{version}.tgz
13 jpp 1.5 Patch0: smeserver-mock-1.0-updates_values.patch
14 jpp 1.7 Patch1: smeserver-mock-1.0-sme10599-spamassassin.patch
15 jpp 1.8 Patch2: smeserver-mock-1.0-sme10600-video.patch
16 michel 1.10 Patch3: smeserver-mock-1.0-ocaml.patch
17 jpp 1.11 Patch4: smeserver-mock-1.0-sme10946-mock.patch
18 jpp 1.12 Patch5: smeserver-mock-1.0-sme10924-bins.patch
19 michel 1.13 Patch6: smeserver-mock-1.0-sme10993-kmodtool.patch
20 michel 1.14 Patch7: smeserver-mock-1.0-sme11005-mojo-jwt.patch
21 jpp 1.16 Patch8: smeserver-mock-1.0-sme11203-spamassassin.patch
22 michel 1.17 Patch9: smeserver-mock-1.0-sme11005-mojo-jwt-2.patch
23 jpp 1.18 Patch10: smeserver-mock-1.0-20220630.patch
24 jpp 1.21 Patch11: smeserver-mock-1.0-change-log.patch
25 jpp 1.22 Patch12: smeserver-mock-1.0-20230412.patch
26 terryfage 1.24 Patch13: smeserver-mock-1.0-bg12350-cvm.patch
27 jpp 1.12
28 jpp 1.1 BuildRoot: /var/tmp/%{name}-%{version}-%{release}-buildroot
29     BuildArchitectures: noarch
30     Requires: e-smith-devtools
31     Requires: mock
32     Requires: glances
33     Requires: make rpm-build rpm-sign wget
34     Requires: cmake automake libtool
35     Buildrequires: e-smith-devtools
36     # needed for scl
37 jpp 1.18 #Requires: scl-utils scl-utils-build centos-release-scl centos-release-scl-rh
38     #Requires: python27-build
39 jpp 1.1 AutoReqProv: no
40    
41     %changelog
42 terryfage 1.24 * Sun Apr 30 2023 TerryFage <terry.fage@gmail.com> 1.0-19.sme
43     - add package to mock*.cfg facilitate cvm build [SME: 12350]
44     - attribute solution to Trevor batley
45    
46 jpp 1.23 * Thu Apr 13 2023 Jean-Philippe Pialasse <tests@pialasse.com> 1.0-18.sme
47     - fixpost scriptled not working [SME: 12349]
48     - add smeos and smeupdates in mock file
49    
50 jpp 1.22 * Wed Apr 12 2023 Jean-Philippe Pialasse <tests@pialasse.com> 1.0-17.sme
51     - fix change-log [SME: 12340]
52     - update smeserver 10 base mockfile
53     - perl.prov workaround in mock file
54    
55 jpp 1.21 * Fri Nov 18 2022 Jean-Philippe Pialasse <tests@pialasse.com> 1.0-16.sme
56     - fix change-log not handling tab for version or release
57    
58 jpp 1.20 * Thu Jun 30 2022 Jean-Philippe Pialasse <tests@pialasse.com> 1.0-15.sme
59 jpp 1.19 - update sme10 mock files [SME: 12089]
60 jpp 1.18 - remove python scl dependencies blocks a lot from using the rpm
61 jpp 1.19 almost never needed [SME: 12090]
62 jpp 1.18 - cleaning remove sme8 and sme9 mock files
63     - added workaround to perl.prov not working [SME: 11958]
64     added mock plugin copy.py and an updated perl.prov
65     - update embded bins
66    
67 michel 1.17 * Mon Dec 27 2021 Michel Begue <mab974@misouk.com> 1.0-13.sme
68     - fix build deps for Mojo::JWT [SME: 11005]
69    
70 jpp 1.16 * Thu Nov 26 2020 Jean-Philipe Pialasse <tests@pialasse.com> 1.0-12.sme
71     - fix build deps for spamassassin [SME: 11203]
72    
73 michel 1.15 * Fri Sep 04 2020 Michel Begue <mab974@gmail.com> 1.0-11.sme
74 michel 1.14 - update dependencies to build Mojo::JWT package [SME: 11005]
75    
76 michel 1.13 * Tue Aug 18 2020 Michel Begue <mab974@gmail.com> 1.0-10.sme
77     - update dependencies to build kmod packages [SME: 10993]
78    
79 jpp 1.11 * Thu May 14 2020 Jean-Philipe Pialasse <tests@pialasse.com> 1.0-9.sme
80     - fix nspawn and package_manager set to yum [SME: 10946]
81     - updating list of included packages for SME10 and SME9 repo
82 jpp 1.12 - updating the attached bins to help building [SME: 10924]
83 jpp 1.11
84 michel 1.10 * Mon Sep 30 2019 Michel Begue <mab974@gmail.com> 1.0-8.sme
85     - added include pkg ocaml, camlp5 [SME: 10809]
86    
87 jpp 1.9 * Tue Nov 13 2018 Jean-Philipe Pialasse <tests@pialasse.com> 1.0-7.sme
88     - fix non needed Requires python-ctypes [SME: 10647]
89    
90 jpp 1.8 * Wed Jun 20 2018 Jean-Philipe Pialasse <tests@pialasse.com> 1.0-6.sme
91     - added include pkg for video tools [SME: 1600]
92     - applied patch for previous bug fix [SME: 10599]
93    
94 jpp 1.6 * Tue Jun 19 2018 Jean-Philipe Pialasse <tests@pialasse.com> 1.0-5.sme
95     - update dependencies to build spamassassin [SME: 10599]
96    
97 jpp 1.5 * Sun Mar 18 2018 Jean-Philipe Pialasse <tests@pialasse.com> 1.0-4.sme
98     - update include package values according to buildsys
99    
100 jpp 1.4 * Sat Mar 17 2018 Jean-Philipe Pialasse <tests@pialasse.com> 1.0-3.sme
101     - set %config on mock config files
102     - a rpmsave of the previous version will be created if modified.
103     - fix typo in filename
104    
105 jpp 1.3 * Sun Mar 11 2018 Jean-Philipe Pialasse <tests@pialasse.com> 1.0-2.sme
106     - update of site-default.cfg via post script [SME: 10537]
107     - removed e-smith-devtools of requirements
108     - added Requires python27-build
109    
110 jpp 1.1 * Sat Mar 10 2018 Jean-Philipe Pialasse <tests@pialasse.com> 1.0-1.sme
111 jpp 1.2 - Initial release with SME iServer mock config files [SME: 10537]
112 jpp 1.1 - tools added : BogusDateBot.sh change-log clog createBuildDir prepa tagbuild
113    
114     %description
115     Tools for use in building RPMs for the Koozali SME server and gateway.
116    
117     Few tools are also provided to help you with package building.
118    
119     %prep
120     %setup
121 jpp 1.5 %patch0 -p1
122 jpp 1.7 %patch1 -p1
123 jpp 1.8 %patch2 -p1
124 michel 1.10 %patch3 -p1
125 jpp 1.11 %patch4 -p1
126 jpp 1.12 %patch5 -p1
127 michel 1.13 %patch6 -p1
128 michel 1.14 %patch7 -p1
129 jpp 1.16 %patch8 -p1
130 michel 1.17 %patch9 -p1
131 jpp 1.18 %patch10 -p1
132 jpp 1.21 %patch11 -p1
133 jpp 1.22 %patch12 -p1
134 terryfage 1.24 %patch13 -p1
135 jpp 1.1
136     %build
137    
138     %install
139     rm -rf $RPM_BUILD_ROOT
140     (cd root ; /usr/bin/find . -depth -print | /bin/cpio -dump $RPM_BUILD_ROOT)
141     /bin/rm -f %{name}-%{version}-filelist
142     /sbin/e-smith/genfilelist $RPM_BUILD_ROOT \
143     --file /usr/bin/BogusDateBot.sh '%attr(0755,root,root)' \
144     --file /usr/bin/change-log '%attr(0755,root,root)' \
145     --file /usr/bin/clog '%attr(0755,root,root)' \
146     --file /usr/bin/createBuildDir '%attr(0755,root,root)' \
147     --file /usr/bin/prepa '%attr(0755,root,root)' \
148     --file /usr/bin/tagbuild '%attr(0755,root,root)' \
149 jpp 1.22 --file /etc/mock/perl.prov '%attr(0755,root,root)' \
150 jpp 1.18 --ignoredir /usr/lib/python3.6/site-packages/mockbuild/plugins \
151     --ignoredir /usr/lib/python3.6/site-packages/mockbuild \
152     --ignoredir /usr/lib/python3.6/site-packages \
153     --ignoredir /usr/lib/python3.6 \
154 jpp 1.20 --ignoredir /etc/mock \
155     | grep -v copy.pyc \
156     | grep -v copy.pyo \
157 jpp 1.1 > %{name}-%{version}-filelist
158    
159     %clean
160     rm -rf $RPM_BUILD_ROOT
161    
162     %pre
163     %preun
164 jpp 1.23 %post -p /bin/bash
165 jpp 1.3
166     # updates sme site defaults
167     main=/etc/mock/site-defaults.cfg
168     tmp=/tmp/site-defaults.cfg
169     gen=/etc/mock/sme-site-defaults.cfg
170    
171     # position of the tags
172     BEGIN_GEN=$(cat $main | grep -n '### KOOZALI SME SERVER BEGIN GENERATED CONTENT' | sed 's/\(.*\):.*/\1/g' )
173     END_GEN=$(cat $main | grep -n '### KOOZALI SME SERVER END GENERATED CONTENT' | sed 's/\(.*\):.*/\1/g' )
174     #if tag is absent set first to 0
175     if [[ "$BEGIN_GEN" -eq "" ]]; then BEGIN_GEN=0; fi
176     if [[ "$END_GEN" -eq "" ]]; then
177     # if second tag is absent just concatenate
178     cat <(head -n $(expr $BEGIN_GEN - 1) $main) $gen >$tmp;
179    
180     else
181     # if both tags are present replace content
182     cat <(head -n $(expr $BEGIN_GEN - 1) $main) $gen <(tail -n +$(expr $END_GEN + 1) $main) >$tmp;
183    
184     fi
185     # mv tmp file to main file
186     mv $tmp $main
187    
188    
189 jpp 1.1 %postun
190    
191 jpp 1.2 %files -f %{name}-%{version}-filelist
192 jpp 1.1 %defattr(-,root,root,-)
193 jpp 1.4 /etc/mock/* %config %attr(0755,root,mock)

admin@koozali.org
ViewVC Help
Powered by ViewVC 1.2.1 RSS 2.0 feed