forked from openresty/openresty
-
Notifications
You must be signed in to change notification settings - Fork 0
/
openresty.spec
68 lines (47 loc) · 1.89 KB
/
openresty.spec
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
%define resty_prefix /opt/
%define resty_user nobody
%define resty_group nobody
%define dir_name openresty
Name: openresty
Version: 1.0.5.1
Release: 5
Summary: nginx for openresty
Group: Productivity/Networking/Web/Servers
License: BSD
URL: http:https://www.openresty.org/
Source0: openresty-%{version}rc%{release}.tar.gz
BuildRoot: %{build_root}
AutoReqProv: no
BuildRequires: gcc >= 3.0, openssl-devel, pcre-devel, readline-devel
Requires: openssl, pcre, readline
%description
OpenResty is a full-fledged web application server by bundling the standard Nginx core, lots of 3rd-party Nginx modules, as well as most of their external dependencies
%prep
#%setup -q -n openresty-%{version}
%setup -q -n openresty-%{version}rc%{release}
%build
#--with-pg_config=opt/pg90/bin/pg_config \
#--with-luajit \
./configure --prefix=%{resty_prefix}/%{dir_name} \
--with-http_postgres_module
make %{?_smp_mflags}
%install
make install DESTDIR=$RPM_BUILD_ROOT
cur_dir=`pwd`
cd $RPM_BUILD_ROOT%{resty_prefix}/%{dir_name}/nginx/ && \
mkdir client_body_temp fastcgi_temp proxy_temp
cd $RPM_BUILD_ROOT && (find . -type f | sed -e 's|^./|/|g' > $cur_dir/%{name}.manifest)
cd $RPM_BUILD_ROOT && (find . -type l | sed -e 's|^./|/|g' >> $cur_dir/%{name}.manifest)
echo %{resty_prefix}/%{dir_name}/nginx/logs >> $cur_dir/%{name}.manifest
echo %{resty_prefix}/%{dir_name}/nginx/client_body_temp >> $cur_dir/%{name}.manifest
echo %{resty_prefix}/%{dir_name}/nginx/fastcgi_temp >> $cur_dir/%{name}.manifest
echo %{resty_prefix}/%{dir_name}/nginx/proxy_temp >> $cur_dir/%{name}.manifest
#echo %{resty_prefix}/%{dir_name}/nginx/proxy_temp >> $cur_dir/%{name}.manifest
%clean
rm -rf $RPM_BUILD_ROOT
%files -f %{name}.manifest
%defattr(-,%{resty_user},%{resty_group},-)
#%doc
%changelog
* Wed Aug 24 2011 liseen <[email protected]>
- initial packaging