%define nginx_user nginx %define nginx_group %{nginx_user} %define nginx_home /var/lib/nginx %define nginx_home_tmp %{nginx_home}/tmp %define nginx_logdir /var/log/nginx %define nginx_confdir %{_sysconfdir}/nginx %define nginx_datadir %{_datadir}/nginx %define nginx_webroot %{nginx_datadir}/html Summary: Robust, small and high performance http and reverse proxy server Name: nginx Version: 1.1.15 Release: 1 Group: System/Servers # BSD License (two clause) # http://www.freebsd.org/copyright/freebsd-license.html License: BSD URL: http://nginx.net/ Source0: http://nginx.org/download/nginx-%{version}.tar.gz Source1: http://nginx.org/download/nginx-%{version}.tar.gz.asc Source2: %{name}.init Source3: %{name}.logrotate Source4: virtual.conf Source5: ssl.conf Source6: %{name}.sysconfig Source100: index.html Source101: poweredby.png Source102: nginx-logo.png Source103: 50x.html Source104: 404.html Requires(post): rpm-helper Requires(preun): rpm-helper Requires(pre): rpm-helper Requires(postun): rpm-helper Requires(pre): apache-conf >= 2.2.0 Requires: apache-conf >= 2.2.0 BuildRequires: pcre-devel BuildRequires: zlib-devel BuildRequires: openssl-devel BuildRequires: perl-devel BuildRequires: perl(ExtUtils::Embed) Requires: pcre Requires: openssl Provides: webserver %description Nginx [engine x] is an HTTP(S) server, HTTP(S) reverse proxy and IMAP/POP3 proxy server written by Igor Sysoev. %prep %setup -q %build %serverbuild ./configure \ --user=%{nginx_user} \ --group=%{nginx_group} \ --prefix=%{nginx_datadir} \ --sbin-path=%{_sbindir}/%{name} \ --conf-path=%{nginx_confdir}/%{name}.conf \ --error-log-path=%{nginx_logdir}/error.log \ --http-log-path=%{nginx_logdir}/access.log \ --http-client-body-temp-path=%{nginx_home_tmp}/client_body \ --http-proxy-temp-path=%{nginx_home_tmp}/proxy \ --http-fastcgi-temp-path=%{nginx_home_tmp}/fastcgi \ --pid-path=/var/run/%{name}/%{name}.pid \ --lock-path=/var/lock/subsys/%{name} \ --with-http_ssl_module \ --with-http_realip_module \ --with-http_addition_module \ --with-http_sub_module \ --with-http_dav_module \ --with-http_flv_module \ --with-http_gzip_static_module \ --with-http_stub_status_module \ --with-http_perl_module \ --with-ipv6 \ --with-mail \ --with-mail_ssl_module \ --with-cc-opt="$CFLAGS $(pcre-config --cflags)" # this is only passed to perl module being built and only overrides the # default '-O' flag which anyways lowers optimizations (which we don't # want) %make OPTIMIZE="-fno-PIE" %install %makeinstall_std INSTALLDIRS=vendor find %{buildroot} -type f -name .packlist -exec rm -f {} \; find %{buildroot} -type f -name perllocal.pod -exec rm -f {} \; find %{buildroot} -type f -empty -exec rm -f {} \; find %{buildroot} -type f -exec chmod 0644 {} \; find %{buildroot} -type f -name '*.so' -exec chmod 0755 {} \; chmod 0755 %{buildroot}%{_sbindir}/nginx %{__install} -p -D -m 0755 %{SOURCE2} %{buildroot}%{_initrddir}/%{name} %{__install} -p -D -m 0644 %{SOURCE3} %{buildroot}%{_sysconfdir}/logrotate.d/%{name} %{__install} -p -D -m 0644 %{SOURCE6} %{buildroot}%{_sysconfdir}/sysconfig/%{name} %{__install} -p -d -m 0755 %{buildroot}%{nginx_confdir}/conf.d %{__install} -p -m 0644 %{SOURCE4} %{SOURCE5} %{buildroot}%{nginx_confdir}/conf.d %{__install} -p -d -m 0755 %{buildroot}%{nginx_home_tmp} %{__install} -p -d -m 0755 %{buildroot}%{nginx_logdir} %{__install} -p -d -m 0755 %{buildroot}%{nginx_webroot} %{__install} -p -m 0644 %{SOURCE100} %{SOURCE101} %{SOURCE102} %{SOURCE103} %{SOURCE104} %{buildroot}%{nginx_webroot} # add current version perl -pi -e "s|_VERSION_|%{version}|g" %{buildroot}%{nginx_webroot}/index.html # convert to UTF-8 all files that give warnings. for textfile in CHANGES; do mv $textfile $textfile.old iconv --from-code ISO8859-1 --to-code UTF-8 --output $textfile $textfile.old rm -f $textfile.old done install -d %{buildroot}%{_mandir}/man8 install -m0644 man/*.8 %{buildroot}%{_mandir}/man8/ %pre %_pre_useradd %{nginx_user} %{nginx_home} /bin/false %post %_post_service %{nginx_user} if [ -f /var/lock/subsys/%{name} ]; then %{_initrddir}/%{name} restart 1>&2; fi %preun %_preun_service %{nginx_user} %postun %_postun_userdel %{nginx_user} %files %defattr(-,root,root,-) %doc LICENSE CHANGES README %{nginx_datadir}/ %{_sbindir}/%{name} %{_mandir}/man3/%{name}.3pm* %{_mandir}/man8/* %{_initrddir}/%{name} %dir %{nginx_confdir} %dir %{nginx_confdir}/conf.d %config(noreplace) %{nginx_confdir}/conf.d/*.conf %config(noreplace) %{nginx_confdir}/win-utf %config(noreplace) %{nginx_confdir}/%{name}.conf.default %config(noreplace) %{nginx_confdir}/scgi_params %config(noreplace) %{nginx_confdir}/scgi_params.default %config(noreplace) %{nginx_confdir}/fastcgi.conf %config(noreplace) %{nginx_confdir}/fastcgi.conf.default %config(noreplace) %{nginx_confdir}/mime.types.default %config(noreplace) %{nginx_confdir}/fastcgi_params %config(noreplace) %{nginx_confdir}/fastcgi_params.default %config(noreplace) %{nginx_confdir}/koi-win %config(noreplace) %{nginx_confdir}/koi-utf %config(noreplace) %{nginx_confdir}/%{name}.conf %config(noreplace) %{nginx_confdir}/mime.types %config(noreplace) %{nginx_confdir}/uwsgi_params %config(noreplace) %{nginx_confdir}/uwsgi_params.default %config(noreplace) %{_sysconfdir}/logrotate.d/%{name} %config(noreplace) %{_sysconfdir}/sysconfig/%{name} %dir %{perl_vendorarch}/auto/%{name} %{perl_vendorarch}/%{name}.pm %{perl_vendorarch}/auto/%{name}/%{name}.so %attr(-,%{nginx_user},%{nginx_group}) %dir %{nginx_home} %attr(-,%{nginx_user},%{nginx_group}) %dir %{nginx_home_tmp} %attr(-,%{nginx_user},%{nginx_group}) %dir %{nginx_logdir} %attr(-,%{nginx_user},%{nginx_group}) %dir /var/run/%{name} %changelog * Tue Feb 21 2012 Lonyai Gergely 1.1.15-1 + Revision: 778545 - 1.1.15 * Tue Feb 07 2012 Oden Eriksson 1.1.13-2 + Revision: 771523 - rebuilt for new pcre * Sun Feb 05 2012 Alexander Khrukin 1.1.13-1 + Revision: 771307 - version update 1.1.13 * Tue Jan 31 2012 Per Øyvind Karlsen 1.0.8-2 + Revision: 770066 - drop some dead DESTDIR hackiness - drop legacy junk - fix so that perl module isn't attempted to be compiled with -fPIE which break built - mass rebuild of perl extensions against perl 5.14.2 * Tue Oct 04 2011 Leonardo Coelho 1.0.8-1 + Revision: 702740 - bump new version * Fri Aug 12 2011 Oden Eriksson 1.0.5-1 + Revision: 694277 - drop the config patch, seems redundant now - 1.0.5 * Wed Jun 01 2011 Funda Wang 1.0.4-1 + Revision: 682322 - update to new version 1.0.4 * Mon May 30 2011 Oden Eriksson 1.0.3-2 + Revision: 681815 - package loss * Thu May 26 2011 Funda Wang 1.0.3-1 + Revision: 679137 - update to new version 1.0.3 * Tue May 10 2011 Funda Wang 1.0.2-1 + Revision: 673308 - update to new version 1.0.2 * Mon May 09 2011 Oden Eriksson 1.0.1-1 + Revision: 672714 - 1.0.1 * Sun Apr 10 2011 Oden Eriksson 0.9.7-1 + Revision: 652249 - 0.9.7 * Sat Apr 02 2011 Oden Eriksson 0.9.6-1 + Revision: 649785 - 0.9.6 * Sat Jan 01 2011 Oden Eriksson 0.9.3-1mdv2011.0 + Revision: 627093 - 0.9.3 * Tue Nov 02 2010 Rémy Clouard 0.8.53-2mdv2011.0 + Revision: 592564 - make nginx provide webserver * Tue Oct 19 2010 Funda Wang 0.8.53-1mdv2011.0 + Revision: 586696 - new version 0.8.53 * Mon Oct 04 2010 Funda Wang 0.8.52-1mdv2011.0 + Revision: 582791 - update to new version 0.8.52 * Mon Aug 09 2010 Funda Wang 0.8.49-1mdv2011.0 + Revision: 567990 - update to new version 0.8.49 * Wed Aug 04 2010 Funda Wang 0.8.48-1mdv2011.0 + Revision: 565647 - update to new version 0.8.48 * Sun Aug 01 2010 Funda Wang 0.8.47-1mdv2011.0 + Revision: 564290 - update to new version 0.8.47 * Tue Jul 20 2010 Jérôme Quelin 0.8.46-2mdv2011.0 + Revision: 555663 - rebuild * Mon Jul 19 2010 Funda Wang 0.8.46-1mdv2011.0 + Revision: 554964 - new version 0.8.46 * Tue Jun 15 2010 Oden Eriksson 0.8.41-1mdv2010.1 + Revision: 548065 - 0.8.41 * Thu May 06 2010 Oden Eriksson 0.8.36-1mdv2010.1 + Revision: 542875 - 0.8.36 * Wed Apr 14 2010 Oden Eriksson 0.8.35-1mdv2010.1 + Revision: 534664 - 0.8.35 - use the %%serverbuild macro * Wed Apr 07 2010 Funda Wang 0.8.34-3mdv2010.1 + Revision: 532516 - rebuild * Mon Mar 29 2010 Michael Scherer 0.8.34-2mdv2010.1 + Revision: 528833 - remove patch0, no longer useful ( as nginx compile fine with -Werror and -D_FORTIFY_SOURCE=2 ) * Thu Mar 04 2010 Funda Wang 0.8.34-1mdv2010.1 + Revision: 514055 - new version 0.8.34 * Fri Feb 26 2010 Oden Eriksson 0.8.33-2mdv2010.1 + Revision: 511596 - rebuilt against openssl-0.9.8m * Wed Feb 17 2010 Oden Eriksson 0.8.33-1mdv2010.1 + Revision: 506976 - 0.8.33 * Thu Jan 14 2010 Michael Scherer 0.8.31-2mdv2010.1 + Revision: 491109 - enable ipv6, for point spec104 of 2010.1 ( ipv6 support ) + Oden Eriksson - fix deps (shikamaru) * Wed Jan 06 2010 Frederik Himpe 0.8.31-1mdv2010.1 + Revision: 486834 - update to new version 0.8.31 * Sun Dec 20 2009 Oden Eriksson 0.8.30-1mdv2010.1 + Revision: 480481 - 0.8.30 * Sat Dec 12 2009 Frederik Himpe 0.8.29-1mdv2010.1 + Revision: 477775 - update to new version 0.8.29 * Wed Nov 25 2009 Funda Wang 0.8.28-1mdv2010.1 + Revision: 469934 - update to new version 0.8.28 * Tue Nov 17 2009 Frederik Himpe 0.8.27-1mdv2010.1 + Revision: 467003 - update to new version 0.8.27 * Sat Nov 07 2009 Frederik Himpe 0.8.22-1mdv2010.1 + Revision: 462619 - update to new version 0.8.22 + Thomas Backlund - fix typo in initscript * Mon Sep 28 2009 Frederik Himpe 0.8.17-1mdv2010.0 + Revision: 450653 - update to new version 0.8.17 * Mon Sep 14 2009 Frederik Himpe 0.8.15-1mdv2010.0 + Revision: 440749 - update to new version 0.8.15 * Sat Aug 29 2009 Frederik Himpe 0.8.11-1mdv2010.0 + Revision: 422223 - update to new version 0.8.11 * Wed Aug 12 2009 Frederik Himpe 0.8.8-1mdv2010.0 + Revision: 415678 - update to new version 0.8.8 * Sun Jun 28 2009 Oden Eriksson 0.8.4-1mdv2010.0 + Revision: 390248 - import nginx * Sun Jun 28 2009 Oden Eriksson 0.8.4-1 - initial Mandriva package (fedora import) * Sun May 17 2009 Jeremy Hinegardner - 0.6.36-2 - init script updates from Gena Makhomed - remove nginx-upstream-fair * Sat Apr 11 2009 Jeremy Hinegardner - 0.6.36-1 - update to 0.6.36 * Wed Feb 25 2009 Fedora Release Engineering - 0.6.35-3 - Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild * Thu Feb 19 2009 Jeremy Hinegardner - 0.6.35-2 - rebuild * Thu Feb 19 2009 Jeremy Hinegardner - 0.6.35-1 - update to 0.6.35 * Sat Jan 17 2009 Tomas Mraz - 0.6.34-2 - rebuild with new openssl * Tue Dec 30 2008 Jeremy Hinegardner - 0.6.34-1 - update to 0.6.34 * Thu Dec 4 2008 Michael Schwendt - 0.6.33-2 - Fix inclusion of /usr/share/nginx tree => no unowned directories. * Sun Nov 23 2008 Jeremy Hinegardner - 0.6.33-1 - update to 0.6.33 * Tue Jul 22 2008 Jeremy Hinegardner - 0.6.32-1 - update to 0.6.32 - nginx now supports DESTDIR so removed the patches that enabled it * Mon May 26 2008 Jeremy Hinegardner - 0.6.31-3 - init script fixes - resolve 'listen 80 default' [#447873] * Mon May 12 2008 Jeremy Hinegardner - 0.6.31-2 - update to 0.6.31 * Sun May 11 2008 Jeremy Hinegardner - 0.6.30-2 - upate to new upstream stable branch 0.6 - added 3rd party module nginx-upstream-fair - added default webpages * Sun Apr 20 2008 Jeremy Hinegardner - 0.5.35-2 - update init script to match recommended guidelines - add /etc/nginx/conf.d support [#443280] - use /etc/sysconfig/nginx to determine nginx.conf [#442708] * Tue Mar 18 2008 Tom "spot" Callaway - 0.5.35-3 - add Requires for versioned perl (libperl.so) - drop silly file Requires * Tue Feb 19 2008 Fedora Release Engineering - 0.5.35-2 - Autorebuild for GCC 4.3 * Sat Jan 19 2008 Jeremy Hinegardner - 0.5.35-1 - update to 0.5.35 * Sat Dec 15 2007 Jeremy Hinegardner - 0.5.34-1 - update to 0.5.34 * Wed Dec 05 2007 Release Engineering - 0.5.33-2 - Rebuild for deps * Sun Nov 11 2007 Jeremy Hinegardner - 0.5.33-1 - update to 0.5.33 * Mon Sep 24 2007 Jeremy Hinegardner - 0.5.32-1 - updated to 0.5.32 - fixed rpmlint UTF-8 complaints. * Sat Aug 18 2007 Jeremy Hinegardner - 0.5.31-2 - added --with-http_stub_status_module build option. - added --with-http_sub_module build option. - added use of pcre-config --cflags * Fri Aug 17 2007 Jeremy Hinegardner - 0.5.31-1 - Update to 0.5.31 - specify license is BSD * Sat Aug 11 2007 Jeremy Hinegardner - 0.5.30-2 - Add BuildRequires: perl-devel - fixing rawhide build * Mon Jul 30 2007 Jeremy Hinegardner - 0.5.30-1 - Update to 0.5.30 * Tue Jul 24 2007 Jeremy Hinegardner - 0.5.29-1 - Update to 0.5.29 * Wed Jul 18 2007 Jeremy Hinegardner - 0.5.28-1 - Update to 0.5.28 * Mon Jul 09 2007 Jeremy Hinegardner - 0.5.27-1 - Update to 0.5.27 * Mon Jun 18 2007 Jeremy Hinegardner - 0.5.26-1 - Update to 0.5.26 * Sat Apr 28 2007 Jeremy Hinegardner - 0.5.19-1 - Update to 0.5.19 * Mon Apr 02 2007 Jeremy Hinegardner - 0.5.17-1 - Update to 0.5.17 * Mon Mar 26 2007 Jeremy Hinegardner - 0.5.16-1 - Update to 0.5.16 - add ownership of /usr/share/nginx/html (#233950) * Fri Mar 23 2007 Jeremy Hinegardner - 0.5.15-3 - fixed package review bugs (#235222) given by ruben@rubenkerkhof.com * Thu Mar 22 2007 Jeremy Hinegardner - 0.5.15-2 - fixed package review bugs (#233522) given by kevin@tummy.com * Thu Mar 22 2007 Jeremy Hinegardner - 0.5.15-1 - create patches to assist with building for Fedora - initial packaging for Fedora