/[smecontribs]/rpms/smeserver-awstats/contribs10/smeserver-awstats.spec
ViewVC logotype

Diff of /rpms/smeserver-awstats/contribs10/smeserver-awstats.spec

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

Revision 1.2 by brianr, Tue Oct 20 11:19:32 2020 UTC Revision 1.12 by brianr, Fri Mar 1 16:09:10 2024 UTC
# Line 1  Line 1 
1  # $Id: smeserver-awstats.spec,v 1.1 2020/10/19 15:36:38 brianr Exp $  # $Id: smeserver-awstats.spec,v 1.11 2023/04/19 14:10:10 michel Exp $
2  # Authority: dungog  # Authority: dungog
3  # Name: Stephen Noble  # Name: Stephen Noble
4    
5  %define realname smeserver-awstats  %define realname smeserver-awstats
6  %define version 1.4  %define version 1.4
7  %define release 2  %define release 10
8    
9  Summary:  SME Server intergration rpm for awstats  Summary:  SME Server integration rpm for awstats
10  Name: %{realname}  Name: %{realname}
11  Version: %{version}  Version: %{version}
12  Release: %{release}%{?dist}  Release: %{release}%{?dist}
# Line 14  License: GNU GPL (GNU General Public Lic Line 14  License: GNU GPL (GNU General Public Lic
14  Group: SMEserver/addon  Group: SMEserver/addon
15  Source: %{name}-%{version}.tar.gz  Source: %{name}-%{version}.tar.gz
16  BuildRoot: /var/tmp/%{name}-%{version}  BuildRoot: /var/tmp/%{name}-%{version}
17  URL: http://www.dungog.net/sme  URL: https://wiki.koozali.org/AWStats
18  BuildArchitectures: noarch  BuildArchitectures: noarch
19  BuildRequires: e-smith-devtools >= 1.13.1-03  BuildRequires: e-smith-devtools >= 1.13.1-03
20  Requires: e-smith-release >= 9  Requires: e-smith-release >= 10
21  Requires: awstats >= 6.5  Requires: awstats >= 6.5
22    Requires: perl(POSIX)
23  AutoReqProv: no  AutoReqProv: no
24  #Patch0: smeserver-awstats-1.4.  Patch0: smeserver-awstats-1.4-bz11045.patch
25  #Patch1: smeserver-awstats-1.4.  Patch1: smeserver-awstats-1.4-bz11998-backup.patch
26    Patch2: smeserver-awstats-1.4-bz5925_add_qmail_stats.patch
27    Patch3: smeserver-awstats-1.4-bz12324_sm2_initial.patch
28    Patch4: smeserver-awstats-1.4-bz12324_sm2_init_bis.patch
29    Patch5: smeserver-awstats-1.4-Alter-menu-category-for-new-arrangement.patch
30    
31  %description  %description
32  SME Server integration rpm for awstats.  SME Server integration rpm for awstats.
33    
34  %changelog  %changelog
35    * Fri Mar 01 2024 Brian Read <brianr@koozali.org> 1.4-10.sme
36    - Edit SM2 Menu entry to conform to new arrangements [SME: 12493]
37    
38    * Fri Mar 24 2023 Michel Begue <mab974@misouk.com> 1.4-9.sme
39    - fix typo and Requires in .spec file [SME: 12324]
40    - (sm2) consider Daily and Hourly Reported Period
41    - (sm2) remove unnecessary file in templates directory
42    
43    * Mon Mar 20 2023 Michel Begue <mab974@misouk.com> 1.4-8.sme
44    - Initial release for server-manager (sm2) [SME: 12324]
45    
46    * Sun Feb 12 2023 Michel Begue <mab974@misouk.com> 1.4-7.sme
47    - add mail stats to panel (ftp stats too) [SME: 5925]
48    
49    * Sat Jul 30 2022 Brian Read <brianr@bjsystems.co.uk> 1.4-6.sme
50    - Re-build and link to latest devtools [SME: 11997]
51    
52    * Thu Jul 21 2022 Jean-Philippe Pialasse <tests@pialasse.com> 1.4-5.sme
53    - add to core backup [SME: 11998]
54    
55    * Mon Feb 22 2021 Jean-Philipe Pialasse <tests@pialasse.com> 1.4-3.sme
56    - add update event for easy install [SME: 11045]
57      rewrite spec and createlinks to be more smeserver compliant
58    - run actions/awstats-upgrade on update of awstats or smeserver-awstats [SME: 10784]
59    
60    * Tue Oct 20 2020 BogusDateBot
61    - Eliminated rpmbuild "bogus date" warnings due to inconsistent weekday,
62      by assuming the date is correct and changing the weekday.
63      Tue May 27 2001 --> Tue May 22 2001 or Sun May 27 2001 or Tue May 29 2001 or ....
64    
65  * Mon Oct 19 2020 Brian Read <brianr@bjsystems.co.uk> 1.4-2.sme  * Mon Oct 19 2020 Brian Read <brianr@bjsystems.co.uk> 1.4-2.sme
66  - Initial import to SME10 tree  [SME: 11045]  - Initial import to SME10 tree  [SME: 11045]
67    
# Line 116  SME Server integration rpm for awstats. Line 151  SME Server integration rpm for awstats.
151  * Thu Oct 04 2001 Michael Weinberger  * Thu Oct 04 2001 Michael Weinberger
152  - based on AWStats 2.32  - based on AWStats 2.32
153    RPM name changed    RPM name changed
154  * Tue May 27 2001 Michael Weinberger  * Sun May 27 2001 Michael Weinberger
155      Tue May 27 2001 --> Tue May 22 2001 or Sun May 27 2001 or Tue May 29 2001 or ....
156  - problems when started by e-smith events  - problems when started by e-smith events
157    awstats pre-processor now runs in background    awstats pre-processor now runs in background
158  * Tue May 01 2001 Michael Weinberger  * Tue May 01 2001 Michael Weinberger
# Line 135  SME Server integration rpm for awstats. Line 171  SME Server integration rpm for awstats.
171    
172  %prep  %prep
173  %setup -q -n %{realname}-%{version}  %setup -q -n %{realname}-%{version}
174  #%patch0 -p1  %patch0 -p1
175  #%patch0 -p1  %patch1 -p1
176    %patch2 -p1
177    %patch3 -p1
178    %patch4 -p1
179    %patch5 -p1
180    
181  %build  %build
182  perl createlinks  perl createlinks
183    mkdir -p root/home/e-smith/files/users/admin/home/awstats
184  mkdir -p root/etc/e-smith/web/panels/manager/html/awstats/icon  mkdir -p root/etc/e-smith/web/panels/manager/html/awstats/icon
185  mkdir -p root/etc/e-smith/web/panels/manager/cgi-bin/.awstats  mkdir -p root/etc/e-smith/web/panels/manager/cgi-bin/.awstats
186    #user-manager
187    mkdir -p root/etc/e-smith/web/panels/user/html/
188    mkdir -p root/etc/e-smith/web/panels/user/cgi-bin/
189    ln -fs /etc/e-smith/web/panels/manager/html/awstats root/etc/e-smith/web/panels/user/html/awstats
190    ln -fs /etc/e-smith/web/panels/manager/cgi-bin/.awstats root/etc/e-smith/web/panels/user/cgi-bin/.awstats
191  echo %{version}-%{release} > root/etc/e-smith/web/panels/manager/cgi-bin/.awstats/version  echo %{version}-%{release} > root/etc/e-smith/web/panels/manager/cgi-bin/.awstats/version
192    
193  %install  %install
194  rm -rf $RPM_BUILD_ROOT  rm -rf $RPM_BUILD_ROOT
195  (cd root ; find . -depth -print | cpio -dump $RPM_BUILD_ROOT)  (cd root ; find . -depth -print | cpio -dump $RPM_BUILD_ROOT)
196  /sbin/e-smith/genfilelist $RPM_BUILD_ROOT > %{name}-%{version}-filelist  /sbin/e-smith/genfilelist $RPM_BUILD_ROOT \
197            --dir '/home/e-smith/files/users/admin/home/awstats' 'attr(40770,admin,root)' \
198            --dir '/etc/e-smith/web/panels/manager/cgi-bin/.awstats' 'attr(40770,root,root)' \
199    > %{name}-%{version}-filelist
200  echo "%doc " >> %{name}-%{version}-filelist  echo "%doc " >> %{name}-%{version}-filelist
201    
202  %clean  %clean
# Line 156  rm -rf %{name}-%{version} Line 205  rm -rf %{name}-%{version}
205    
206  %pre  %pre
207  %post  %post
 mkdir -p /home/e-smith/files/users/admin/home/awstats  
 chown -R admin.root /home/e-smith/files/users/admin/home/awstats  
 chmod -R u+rw,g+rw /home/e-smith/files/users/admin/home/awstats  
 /sbin/e-smith/config setprop AWStats status enabled  
 /sbin/e-smith/signal-event awstats-update  
208    
209  #user-manager  if (systemctl list-unit-files |grep smanager) then
210  /bin/mkdir -p /etc/e-smith/web/panels/user/html/    echo "Smanager restart in spec file"
211  /bin/mkdir -p /etc/e-smith/web/panels/user/cgi-bin/    /sbin/e-smith/signal-event smanager-refresh;
212  /bin/ln -fs /etc/e-smith/web/panels/manager/html/awstats /etc/e-smith/web/panels/user/html/awstats  fi
213  /bin/ln -fs /etc/e-smith/web/panels/manager/cgi-bin/.awstats /etc/e-smith/web/panels/user/cgi-bin/.awstats  
214    
215  %preun  %preun
216  %postun  %postun
# Line 175  if [ $1 = 0 ] ; then Line 219  if [ $1 = 0 ] ; then
219   /bin/rm -rf /etc/e-smith/web/panels/manager/cgi-bin/.awstats   /bin/rm -rf /etc/e-smith/web/panels/manager/cgi-bin/.awstats
220   /bin/rm -rf /etc/e-smith/web/panels/user/html/awstats   /bin/rm -rf /etc/e-smith/web/panels/user/html/awstats
221   /bin/rm -rf /etc/e-smith/web/panels/user/cgi-bin/.awstats   /bin/rm -rf /etc/e-smith/web/panels/user/cgi-bin/.awstats
222     /bin/rm -f /usr/share/smanager/themes/default/images/awstats/icon
223   /sbin/e-smith/config setprop AWStats status removed   /sbin/e-smith/config setprop AWStats status removed
224   /sbin/e-smith/expand-template /etc/crontab   /sbin/e-smith/expand-template /etc/crontab
225  fi  fi
226    true
227    
228  %files -f %{name}-%{version}-filelist  %files -f %{name}-%{version}-filelist
229  %defattr(-,root,root)  %defattr(-,root,root)
   
 #runs when awstats OR smeserver-awstats is installed or upgraded  
 %triggerin -- awstats  
 /etc/e-smith/events/actions/awstats-upgrade  


Legend:
Removed lines/characters  
Changed lines/characters
  Added lines/characters

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