/[smecontribs]/rpms/smeserver-moodle/contribs7/smeserver-moodle.spec
ViewVC logotype

Annotation of /rpms/smeserver-moodle/contribs7/smeserver-moodle.spec

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


Revision 1.2 - (hide annotations) (download)
Sun Dec 23 21:45:25 2007 UTC (16 years, 11 months ago) by slords
Branch: MAIN
CVS Tags: smeserver-moodle-1_0-4_el4_sme
Changes since 1.1: +0 -2 lines
Specfile fixes

1 slords 1.1 %define name smeserver-moodle
2     %define version 1.0
3     %define release 4
4     Summary: smserver rpm to setup moodle, a course management system
5     Name: %{name}
6     Version: %{version}
7     Release: %{release}%{?dist}
8     License: GNU GPL version 2
9     URL: http://www.dungog.net/sme
10     Group: SMEserver/addon
11     Source: %{name}-%{version}.tar.gz
12     Patch0: smeserver-moodle-1.0-null.patch
13     Patch1: smeserver-moodle-1.0-20db.patch2
14     BuildArchitectures: noarch
15     BuildRequires: e-smith-devtools >= 1.13.1-03
16     BuildRoot: /var/tmp/%{name}-%{version}
17     Requires: e-smith-release >= 7.0
18     Requires: moodle
19     Requires: gd
20     AutoReqProv: no
21    
22     %description
23     smserver rpm to setup moodle, a course management system
24    
25     %changelog
26     * Sun Sep 2 2007 Stephen Noble <support@dungog.net> 1.0-4
27     - 20db patch fixed
28    
29     * Sun Sep 2 2007 Stephen Noble <support@dungog.net> 1.0-3
30     - crontab redirect to null not nul
31     - remove 20db patch
32    
33     * Sun Jul 29 2007 Stephen Noble <support@dungog.net> 1.0-2
34     - 20db template fixed
35    
36     * Fri Jul 06 2007 Stephen Noble <support@dungog.net> 1.0-1
37     - http alias, auto setup, template config.php
38    
39     * Mon Dec 11 2006 Stephen Noble <support@dungog.net>
40     - rpm %post events reordered, to enable clean install
41     - [0.9-2]
42    
43     * Fri Dec 1 2006 Stephen Noble <support@dungog.net>
44     - initial release
45     - [0.9-1]
46    
47     %prep
48     %setup
49     %patch0 -p1
50     %patch1 -p1
51    
52     %build
53    
54     mkdir -p root/etc/e-smith/db/accounts/defaults/moodle
55     echo "reserved" > root/etc/e-smith/db/accounts/defaults/moodle/type
56    
57     mkdir -p root/etc/e-smith/db/configuration/defaults/moodle
58     echo "Online Learning" > root/etc/e-smith/db/configuration/defaults/moodle/Name
59     echo "global-pw-remote" > root/etc/e-smith/db/configuration/defaults/moodle/PublicAccess
60     echo "enabled" > root/etc/e-smith/db/configuration/defaults/moodle/status
61     echo "moodle" > root/etc/e-smith/db/configuration/defaults/moodle/DbName
62     echo "moodle" > root/etc/e-smith/db/configuration/defaults/moodle/DbUser
63    
64     mkdir -p root/etc/e-smith/templates.metadata/etc/e-smith/sql/init
65     echo "PERMS=0750" > root/etc/e-smith/templates.metadata/etc/e-smith/sql/init/80moodle
66    
67     #only needed so it is removed afterwards
68     mkdir -p root/opt/moodle/html
69     touch root/opt/moodle/html/config.php
70    
71     %install
72     rm -rf $RPM_BUILD_ROOT
73     (cd root ; find . -depth -print | cpio -dump $RPM_BUILD_ROOT)
74     rm -f %{name}-%{version}-filelist
75     /sbin/e-smith/genfilelist $RPM_BUILD_ROOT > %{name}-%{version}-filelist
76     echo "%doc COPYING" >> %{name}-%{version}-filelist
77    
78     %clean
79     cd ..
80     rm -rf %{name}-%{version}
81    
82     %pre
83     %preun
84     %post
85     /etc/e-smith/events/actions/initialize-default-databases
86     /sbin/e-smith/expand-template /etc/e-smith/sql/init/80moodle
87     /etc/rc.d/init.d/mysql.init start
88     /sbin/e-smith/expand-template /etc/httpd/conf/httpd.conf
89     /sbin/e-smith/expand-template /opt/moodle/html/config.php
90     /usr/bin/sv h /service/httpd-e-smith
91     /sbin/e-smith/expand-template /etc/crontab
92    
93     echo ""
94     echo "see http://wiki.contribs.org/moodle"
95    
96     %postun
97     #uninstall
98     if [ $1 = 0 ] ; then
99     /sbin/e-smith/expand-template /etc/httpd/conf/httpd.conf
100     /usr/bin/sv h /service/httpd-e-smith
101     /sbin/e-smith/expand-template /etc/crontab
102     fi
103    
104     %files -f %{name}-%{version}-filelist
105     %defattr(-,root,root)
106    

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