]> git.pld-linux.org Git - packages/CodeIgniter.git/blob - CodeIgniter.spec
- doc subpackage
[packages/CodeIgniter.git] / CodeIgniter.spec
1 %define         php_min_version 5.2.4
2 %include        /usr/lib/rpm/macros.php
3 Summary:        A powerful PHP framework with a very small footprint
4 Name:           CodeIgniter
5 Version:        2.0.2
6 Release:        0.9
7 License:        other
8 Group:          Development/Languages/PHP
9 Source0:        http://www.codeigniter.com/download_files/reactor/%{name}_%{version}.zip
10 # Source0-md5:  e75bab8cf27d2fb2483c5bb61b85a524
11 Source1:        INSTALL-PLD.txt
12 Source2:        codeigniter-install
13 URL:            http://codeigniter.com/
14 BuildRequires:  rpm-php-pearprov >= 4.3
15 BuildRequires:  rpmbuild(macros) >= 1.461
16 BuildRequires:  sed >= 4.0
17 BuildRequires:  unzip
18 Requires:       php-common >= 4:%{php_min_version}
19 Requires:       php-ctype
20 Requires:       php-date
21 Requires:       php-hash
22 Requires:       php-mbstring
23 Requires:       php-mysql
24 Requires:       php-pcre
25 Requires:       php-session
26 Requires:       php-simplexml
27 Requires:       php-spl
28 BuildArch:      noarch
29 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
30
31 %define         _appdir         %{_datadir}/%{name}
32
33 %description
34 CodeIgniter is a powerful PHP framework with a very small footprint,
35 built for PHP coders who need a simple and elegant toolkit to create
36 full-featured web applications. If you're a developer who lives in the
37 real world of shared hosting accounts and clients with deadlines, and
38 if you're tired of ponderously large and thoroughly undocumented
39 frameworks.
40
41 %package doc
42 Summary:        CodeIgniter documentation
43 Group:          Development/Languages/PHP
44
45 %description doc
46 CodeIgniter documentation.
47
48 %prep
49 %setup -q -n %{name}_%{version}
50 %{__sed} -i 's,\$application_folder.*=.*,$application_folder = "PLEASE SET TO CORRECT PATH";,' index.php
51 %{__sed} -i '59 s,\$system_path.*=.*,$system_path = "%{_datadir}/CodeIgniter/system"\;, ' index.php
52
53 %install
54 rm -rf $RPM_BUILD_ROOT
55
56 install -d $RPM_BUILD_ROOT%{_appdir}
57 install -d $RPM_BUILD_ROOT%{_docdir}/%{name}-%{version}
58
59 cp -r index.php application system $RPM_BUILD_ROOT%{_appdir}
60 cp -r user_guide/* $RPM_BUILD_ROOT%{_docdir}/%{name}-%{version}
61 install %{SOURCE1} $RPM_BUILD_ROOT%{_docdir}/%{name}-%{version}
62
63 install -d $RPM_BUILD_ROOT%{_bindir}
64 install %{SOURCE2} $RPM_BUILD_ROOT%{_bindir}
65
66 find $RPM_BUILD_ROOT%{_datadir}/%{name} -name index.html -delete
67
68 rm -rf $RPM_BUILD_ROOT%{_appdir}/application/{cache,core,helpers,hooks,libraries}
69
70 %clean
71 rm -rf $RPM_BUILD_ROOT
72
73 %post
74 %banner -e %{name} <<-EOF
75 Please read INSTALL-PLD.txt to know how can use the users the installed CodeIgniter!
76 EOF
77
78 %files
79 %defattr(644,root,root,755)
80 %attr(755,root,root) %{_bindir}/codeigniter-install
81
82 %dir %{_appdir}
83 %dir %{_appdir}/application
84 %dir %{_appdir}/application/config
85 %dir %{_appdir}/application/controllers
86 %dir %{_appdir}/application/errors
87 %dir %{_appdir}/application/language
88 %dir %{_appdir}/application/views
89 %dir %{_appdir}/system
90 %dir %{_appdir}/system/core
91 %dir %{_appdir}/system/database
92 %dir %{_appdir}/system/database/drivers
93 %dir %{_appdir}/system/fonts
94 %dir %{_appdir}/system/helpers
95 %dir %{_appdir}/system/language
96 %dir %{_appdir}/system/libraries
97
98 %{_appdir}/index.php
99 %{_appdir}/application/.htaccess
100 %{_appdir}/system/.htaccess
101
102 %{_appdir}/application/config/*
103 %{_appdir}/application/controllers/*
104 %{_appdir}/application/errors/*
105 %{_appdir}/application/language/*
106 %{_appdir}/application/views/*
107
108 %{_appdir}/system/core/*
109 %{_appdir}/system/database/DB*.php
110 %{_appdir}/system/database/drivers/*
111 %{_appdir}/system/fonts/*
112 %{_appdir}/system/helpers/*
113 %{_appdir}/system/language/*
114 %{_appdir}/system/libraries/*
115
116 %files doc
117 %defattr(644,root,root,755)
118 %doc %{_docdir}/%{name}-%{version}
This page took 0.027868 seconds and 3 git commands to generate.