Accepting request 313585 from home:MargueriteSu:branches:server:http

update version 1.8.0

OBS-URL: https://build.opensuse.org/request/show/313585
OBS-URL: https://build.opensuse.org/package/show/server:http/nginx?expand=0&rev=52
This commit is contained in:
Marguerite Su 2015-06-24 16:07:53 +00:00 committed by Git OBS Bridge
parent abc4d45b31
commit 2ecf20024e
11 changed files with 239 additions and 270 deletions

View File

@ -1,6 +1,8 @@
--- passenger/build/common_library.rb
Index: passenger/build/common_library.rb
===================================================================
--- passenger.orig/build/common_library.rb
+++ passenger/build/common_library.rb
@@ -34,7 +34,7 @@
@@ -34,7 +34,7 @@ require 'phusion_passenger/common_librar
# Defines tasks for compiling a static library containing Boost and OXT.
def define_libboost_oxt_task(namespace, output_dir, extra_compiler_flags = nil)
output_file = "#{output_dir}.a"
@ -9,7 +11,7 @@
if false && boolean_option('RELEASE')
# Disable RELEASE support. Passenger Standalone wants to link to the
@@ -126,7 +126,7 @@
@@ -126,7 +126,7 @@ if USE_VENDORED_LIBEV
]
file LIBEV_OUTPUT_DIR + "Makefile" => dependencies do
# Disable all warnings: http://pod.tst.eu/http://cvs.schmorp.de/libev/ev.pod#COMPILER_WARNINGS
@ -18,7 +20,7 @@
sh "mkdir -p #{LIBEV_OUTPUT_DIR}" if !File.directory?(LIBEV_OUTPUT_DIR)
sh "cd #{LIBEV_OUTPUT_DIR} && sh #{LIBEV_SOURCE_DIR}configure " +
"--disable-shared --enable-static CFLAGS='#{cflags}' orig_CFLAGS=1"
@@ -174,7 +174,7 @@
@@ -174,7 +174,7 @@ if USE_VENDORED_LIBEIO
file LIBEIO_OUTPUT_DIR + "Makefile" => dependencies do
# Disable all warnings. The author has a clear standpoint on that:
# http://pod.tst.eu/http://cvs.schmorp.de/libev/ev.pod#COMPILER_WARNINGS
@ -27,7 +29,7 @@
sh "mkdir -p #{LIBEIO_OUTPUT_DIR}" if !File.directory?(LIBEIO_OUTPUT_DIR)
sh "cd #{LIBEIO_OUTPUT_DIR} && sh #{LIBEIO_SOURCE_DIR}configure " +
"--disable-shared --enable-static CFLAGS='#{cflags}'"
@@ -183,6 +183,7 @@
@@ -183,6 +183,7 @@ if USE_VENDORED_LIBEIO
libeio_sources = Dir["ext/libeio/{*.c,*.h}"]
file LIBEIO_OUTPUT_DIR + ".libs/libeio.a" => [LIBEIO_OUTPUT_DIR + "Makefile"] + libeio_sources do
sh "rm -f #{LIBEIO_OUTPUT_DIR}/libeio.la"
@ -35,9 +37,11 @@
sh "cd #{LIBEIO_OUTPUT_DIR} && make libeio.la"
end
--- passenger/ext/boost/libs/thread/src/pthread/thread.cpp
Index: passenger/ext/boost/libs/thread/src/pthread/thread.cpp
===================================================================
--- passenger.orig/ext/boost/libs/thread/src/pthread/thread.cpp
+++ passenger/ext/boost/libs/thread/src/pthread/thread.cpp
@@ -376,6 +376,7 @@
@@ -376,6 +376,7 @@ namespace boost
boost::throw_exception(thread_resource_error(system::errc::invalid_argument, "boost thread: thread not joinable"));
#endif
}
@ -45,9 +49,29 @@
}
bool thread::joinable() const BOOST_NOEXCEPT
--- passenger/lib/phusion_passenger/common_library.rb
Index: passenger/ext/nginx/StaticContentHandler.c
===================================================================
--- passenger.orig/ext/nginx/StaticContentHandler.c
+++ passenger/ext/nginx/StaticContentHandler.c
@@ -67,13 +67,6 @@ passenger_static_content_handler(ngx_htt
return NGX_DECLINED;
}
- #if (PASSENGER_NGINX_MINOR_VERSION == 8 && PASSENGER_NGINX_MICRO_VERSION < 38) || \
- (PASSENGER_NGINX_MINOR_VERSION == 7 && PASSENGER_NGINX_MICRO_VERSION < 66)
- if (r->zero_in_uri) {
- return NGX_DECLINED;
- }
- #endif
-
log = r->connection->log;
ngx_log_debug1(NGX_LOG_DEBUG_HTTP, log, 0,
Index: passenger/lib/phusion_passenger/common_library.rb
===================================================================
--- passenger.orig/lib/phusion_passenger/common_library.rb
+++ passenger/lib/phusion_passenger/common_library.rb
@@ -101,7 +101,7 @@
@@ -101,7 +101,7 @@ class CommonLibraryBuilder
end
def define_tasks(extra_compiler_flags = nil)

View File

@ -1,21 +0,0 @@
diff -Ppru passenger/build/common_library.rb passenger/build/common_library.rb
--- passenger/build/common_library.rb 2012-07-16 21:23:58.000000000 +0200
+++ passenger/build/common_library.rb 2014-01-17 13:44:58.830352986 +0100
@@ -94,7 +94,7 @@ def define_common_library_task(namespace
static_library = "#{output_dir}.a"
# Define compilation targets for the object files in libpassenger_common.
- flags = "-Iext -Iext/common #{LIBEV_CFLAGS} #{extra_compiler_flags} "
+ flags = "-Iext -Iext/common #{LIBEV_CFLAGS} #{extra_compiler_flags} -fPIC #{ENV['RPM_OPT_FLAGS']} "
flags << "#{PlatformInfo.portability_cflags} #{EXTRA_CXXFLAGS}"
flags.strip!
@@ -162,7 +162,7 @@ end
# Defines tasks for compiling a static library containing Boost and OXT.
def define_libboost_oxt_task(namespace, output_dir, extra_compiler_flags = nil)
output_file = "#{output_dir}.a"
- flags = "-Iext #{extra_compiler_flags} #{PlatformInfo.portability_cflags} #{EXTRA_CXXFLAGS}"
+ flags = "-Iext #{extra_compiler_flags} #{PlatformInfo.portability_cflags} #{EXTRA_CXXFLAGS} -fPIC #{ENV['RPM_OPT_FLAGS']}"
if boolean_option('RELEASE')
sources = Dir['ext/boost/src/pthread/*.cpp'] + Dir['ext/oxt/*.cpp']

View File

@ -1,173 +0,0 @@
--- passenger/build/common_library.rb
+++ passenger/build/common_library.rb
@@ -34,19 +34,19 @@
# Defines tasks for compiling a static library containing Boost and OXT.
def define_libboost_oxt_task(namespace, output_dir, extra_compiler_flags = nil)
output_file = "#{output_dir}.a"
- flags = "-Iext #{extra_compiler_flags} #{EXTRA_CXXFLAGS}"
-
+ flags = "-Iext #{extra_compiler_flags} #{EXTRA_CXXFLAGS} -fPIC #{ENV['RPM_OPT_FLAGS']} "
+
if false && boolean_option('RELEASE')
# Disable RELEASE support. Passenger Standalone wants to link to the
# common library but does not know whether it was compiled with RELEASE
# or not. See http://code.google.com/p/phusion-passenger/issues/detail?id=808
sources = Dir['ext/boost/libs/**/*.cpp'] + Dir['ext/oxt/*.cpp']
sources.sort!
-
+
aggregate_source = "#{output_dir}/aggregate.cpp"
aggregate_object = "#{output_dir}/aggregate.o"
object_files = [aggregate_object]
-
+
file(aggregate_object => sources) do
sh "mkdir -p #{output_dir}" if !File.directory?(output_dir)
aggregate_content = %Q{
@@ -71,13 +71,13 @@
boost_output_dir = "#{output_dir}/boost"
object_file = "#{boost_output_dir}/#{object_name}"
boost_object_files << object_file
-
+
file object_file => source_file do
sh "mkdir -p #{boost_output_dir}" if !File.directory?(boost_output_dir)
compile_cxx(source_file, "#{flags} -o #{object_file}")
end
end
-
+
# Define compilation targets for .cpp files in ext/oxt.
oxt_object_files = []
oxt_dependency_files = Dir["ext/oxt/*.hpp"] + Dir["ext/oxt/detail/*.hpp"]
@@ -92,19 +92,19 @@
compile_cxx(source_file, "#{flags} -o #{object_file}")
end
end
-
+
object_files = boost_object_files + oxt_object_files
end
-
+
file(output_file => object_files) do
sh "mkdir -p #{output_dir}"
create_static_library(output_file, object_files.join(' '))
end
-
+
task "#{namespace}:clean" do
sh "rm -rf #{output_file} #{output_dir}"
end
-
+
return output_file
end
@@ -116,9 +116,9 @@
LIBEV_CFLAGS = "-Iext/libev"
LIBEV_LIBS = LIBEV_OUTPUT_DIR + ".libs/libev.a"
LIBEV_TARGET = LIBEV_LIBS
-
+
task :libev => LIBEV_TARGET
-
+
dependencies = [
"ext/libev/configure",
"ext/libev/config.h.in",
@@ -128,7 +128,7 @@
cc = PlatformInfo.cc
cxx = PlatformInfo.cxx
# Disable all warnings: http://pod.tst.eu/http://cvs.schmorp.de/libev/ev.pod#COMPILER_WARNINGS
- cflags = "#{EXTRA_CFLAGS} -w"
+ cflags = "#{EXTRA_CFLAGS} #{ENV['RPM_OPT_FLAGS']} -w"
sh "mkdir -p #{LIBEV_OUTPUT_DIR}" if !File.directory?(LIBEV_OUTPUT_DIR)
sh "cd #{LIBEV_OUTPUT_DIR} && sh #{LIBEV_SOURCE_DIR}configure " +
"--disable-shared --enable-static " +
@@ -136,7 +136,7 @@
# do, so we force our compiler choice.
"CC='#{cc}' CXX='#{cxx}' CFLAGS='#{cflags}' orig_CFLAGS=1"
end
-
+
libev_sources = Dir["ext/libev/{*.c,*.h}"]
file LIBEV_OUTPUT_DIR + ".libs/libev.a" => [LIBEV_OUTPUT_DIR + "Makefile"] + libev_sources do
sh "rm -f #{LIBEV_OUTPUT_DIR}/libev.la"
@@ -148,7 +148,7 @@
sh "cd #{LIBEV_OUTPUT_DIR} && make maintainer-clean"
end
end
-
+
task :clean => 'libev:clean'
else
LIBEV_CFLAGS = string_option('LIBEV_CFLAGS', '-I/usr/include/libev')
@@ -168,9 +168,9 @@
LIBEIO_CFLAGS = "-Iext/libeio"
LIBEIO_LIBS = LIBEIO_OUTPUT_DIR + ".libs/libeio.a"
LIBEIO_TARGET = LIBEIO_LIBS
-
+
task :libeio => LIBEIO_TARGET
-
+
dependencies = [
"ext/libeio/configure",
"ext/libeio/config.h.in",
@@ -181,7 +181,7 @@
cxx = PlatformInfo.cxx
# Disable all warnings. The author has a clear standpoint on that:
# http://pod.tst.eu/http://cvs.schmorp.de/libev/ev.pod#COMPILER_WARNINGS
- cflags = "#{EXTRA_CFLAGS} -w"
+ cflags = "#{EXTRA_CFLAGS} #{ENV['RPM_OPT_FLAGS']} -w"
sh "mkdir -p #{LIBEIO_OUTPUT_DIR}" if !File.directory?(LIBEIO_OUTPUT_DIR)
sh "cd #{LIBEIO_OUTPUT_DIR} && sh #{LIBEIO_SOURCE_DIR}configure " +
"--disable-shared --enable-static " +
@@ -189,13 +189,14 @@
# do, so we force our compiler choice.
"CC='#{cc}' CXX='#{cxx}' CFLAGS='#{cflags}'"
end
-
+
libeio_sources = Dir["ext/libeio/{*.c,*.h}"]
file LIBEIO_OUTPUT_DIR + ".libs/libeio.a" => [LIBEIO_OUTPUT_DIR + "Makefile"] + libeio_sources do
sh "rm -f #{LIBEIO_OUTPUT_DIR}/libeio.la"
+ sh "cd #{LIBEIO_OUTPUT_DIR} && make eio.o"
sh "cd #{LIBEIO_OUTPUT_DIR} && make libeio.la"
end
-
+
task :clean do
if File.exist?(LIBEIO_OUTPUT_DIR + "Makefile")
sh "cd #{LIBEIO_OUTPUT_DIR} && make maintainer-clean"
--- passenger/ext/boost/libs/thread/src/pthread/thread.cpp
+++ passenger/ext/boost/libs/thread/src/pthread/thread.cpp
@@ -390,6 +390,7 @@
{
return false;
}
+ return false;
}
bool thread::joinable() const BOOST_NOEXCEPT
--- passenger/lib/phusion_passenger/common_library.rb
+++ passenger/lib/phusion_passenger/common_library.rb
@@ -101,7 +101,7 @@
end
def define_tasks(extra_compiler_flags = nil)
- flags = "-Iext -Iext/common #{LIBEV_CFLAGS} #{extra_compiler_flags} "
+ flags = "-Iext -Iext/common #{LIBEV_CFLAGS} #{extra_compiler_flags} -fPIC #{ENV['RPM_OPT_FLAGS']} "
cflags = (flags + EXTRA_CFLAGS).strip
cxxflags = (flags + EXTRA_CXXFLAGS).strip
@@ -171,7 +171,7 @@
# packaging the runtime ('passenger package-runtime') so we
# never generate static libraries.
library = "#{@output_dir}/#{category}.a"
-
+
file(library => object_filenames) do
create_static_library(library, object_filenames.join(' '))
end

View File

@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:0a98e95b366e4d6042f331e1fa4d70e18fd1e49d8993e589008e70e742b7e757
size 805253

View File

@ -0,0 +1,131 @@
Index: passenger/ext/nginx/Configuration.c
===================================================================
--- passenger.orig/ext/nginx/Configuration.c 2015-06-24 23:29:12.725985654 +0800
+++ passenger/ext/nginx/Configuration.c 2015-06-24 23:02:39.654901783 +0800
@@ -261,7 +261,11 @@
conf->upstream_config.pass_request_body = NGX_CONF_UNSET;
#if (NGX_HTTP_CACHE)
- conf->upstream_config.cache = NGX_CONF_UNSET_PTR;
+ #if NGINX_VERSION_NUM >= 1007009
+ conf->upstream_config.cache = NGX_CONF_UNSET_PTR;
+ #else
+ conf->upstream_config.cache = NGX_CONF_UNSET;
+ #endif
conf->upstream_config.cache_min_uses = NGX_CONF_UNSET_UINT;
conf->upstream_config.cache_bypass = NGX_CONF_UNSET_PTR;
conf->upstream_config.no_cache = NGX_CONF_UNSET_PTR;
@@ -270,6 +274,9 @@
conf->upstream_config.cache_lock = NGX_CONF_UNSET;
conf->upstream_config.cache_lock_timeout = NGX_CONF_UNSET_MSEC;
#endif
+ #if NGINX_VERSION_NUM >= 1007008
+ conf->upstream_config.cache_lock_age = NGX_CONF_UNSET_MSEC;
+ #endif
#endif
conf->upstream_config.intercept_errors = NGX_CONF_UNSET;
@@ -374,15 +381,34 @@
/******************************/
/******************************/
- if (conf->upstream_config.store != 0) {
- ngx_conf_merge_value(conf->upstream_config.store,
- prev->upstream_config.store, 0);
+ #if (NGX_HTTP_CACHE) && NGINX_VERSION_NUM >= 1007009
+ if (conf->upstream_config.store > 0) {
+ conf->upstream_config.cache = 0;
+ }
+ if (conf->upstream_config.cache > 0) {
+ conf->upstream_config.store = 0;
+ }
+ #endif
+
+ #if NGINX_VERSION_NUM >= 1007009
+ if (conf->upstream_config.store == NGX_CONF_UNSET) {
+ ngx_conf_merge_value(conf->upstream_config.store,
+ prev->upstream_config.store, 0);
- if (conf->upstream_config.store_lengths == NULL) {
conf->upstream_config.store_lengths = prev->upstream_config.store_lengths;
conf->upstream_config.store_values = prev->upstream_config.store_values;
}
- }
+ #else
+ if (conf->upstream_config.store != 0) {
+ ngx_conf_merge_value(conf->upstream_config.store,
+ prev->upstream_config.store, 0);
+
+ if (conf->upstream_config.store_lengths == NULL) {
+ conf->upstream_config.store_lengths = prev->upstream_config.store_lengths;
+ conf->upstream_config.store_values = prev->upstream_config.store_values;
+ }
+ }
+ #endif
ngx_conf_merge_uint_value(conf->upstream_config.store_access,
prev->upstream_config.store_access, 0600);
@@ -526,20 +552,42 @@
#if (NGX_HTTP_CACHE)
- ngx_conf_merge_ptr_value(conf->upstream_config.cache,
- prev->upstream_config.cache, NULL);
+ #if NGINX_VERSION_NUM >= 1007009
+ if (conf->upstream_config.cache == NGX_CONF_UNSET) {
+ ngx_conf_merge_value(conf->upstream_config.cache,
+ prev->upstream_config.cache, 0);
+
+ conf->upstream_config.cache_zone = prev->upstream_config.cache_zone;
+ conf->upstream_config.cache_value = prev->upstream_config.cache_value;
+ }
- if (conf->upstream_config.cache && conf->upstream_config.cache->data == NULL) {
- ngx_shm_zone_t *shm_zone;
+ if (conf->upstream_config.cache_zone && conf->upstream_config.cache_zone->data == NULL) {
+ ngx_shm_zone_t *shm_zone;
- shm_zone = conf->upstream_config.cache;
+ shm_zone = conf->upstream_config.cache_zone;
ngx_conf_log_error(NGX_LOG_EMERG, cf, 0,
- "\"scgi_cache\" zone \"%V\" is unknown",
- &shm_zone->shm.name);
+ "\"scgi_cache\" zone \"%V\" is unknown",
+ &shm_zone->shm.name);
- return NGX_CONF_ERROR;
- }
+ return NGX_CONF_ERROR;
+ }
+ #else
+ ngx_conf_merge_ptr_value(conf->upstream_config.cache,
+ prev->upstream_config.cache, NULL);
+
+ if (conf->upstream_config.cache && conf->upstream_config.cache->data == NULL) {
+ ngx_shm_zone_t *shm_zone;
+
+ shm_zone = conf->upstream_config.cache;
+
+ ngx_conf_log_error(NGX_LOG_EMERG, cf, 0,
+ "\"scgi_cache\" zone \"%V\" is unknown",
+ &shm_zone->shm.name);
+
+ return NGX_CONF_ERROR;
+ }
+ #endif
ngx_conf_merge_uint_value(conf->upstream_config.cache_min_uses,
prev->upstream_config.cache_min_uses, 1);
@@ -585,6 +633,11 @@
prev->upstream_config.cache_lock_timeout, 5000);
#endif
+ #if NGINX_VERSION_NUM >= 1007008
+ ngx_conf_merge_msec_value(conf->upstream_config.cache_lock_age,
+ prev->upstream_config.cache_lock_age, 5000);
+ #endif
+
#endif
ngx_conf_merge_value(conf->upstream_config.pass_request_headers,

3
nginx-1.8.0.tar.gz Normal file
View File

@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:23cca1239990c818d8f6da118320c4979aadf5386deda691b1b7c2c96b9df3d5
size 832104

View File

@ -1,11 +1,11 @@
Index: nginx-1.2.9/auto/unix
Index: nginx-1.9.1/auto/unix
===================================================================
--- nginx-1.2.9.orig/auto/unix
+++ nginx-1.2.9/auto/unix
@@ -396,7 +396,11 @@ if [ $NGX_FILE_AIO = YES ]; then
--- nginx-1.9.1.orig/auto/unix
+++ nginx-1.9.1/auto/unix
@@ -438,7 +438,11 @@ if [ $NGX_FILE_AIO = YES ]; then
ngx_feature="Linux AIO support (SYS_eventfd)"
ngx_feature_incs="#include <linux/aio_abi.h>
#include <sys/syscall.h>"
ngx_feature_path=
ngx_feature_libs=
- ngx_feature_test="int n = SYS_eventfd;
+ ngx_feature_test="#ifdef SYS_eventfd
+ int n = SYS_eventfd;
@ -15,31 +15,30 @@ Index: nginx-1.2.9/auto/unix
struct iocb iocb;
iocb.aio_lio_opcode = IOCB_CMD_PREAD;
iocb.aio_flags = IOCB_FLAG_RESFD;
Index: nginx-1.2.9/src/event/modules/ngx_epoll_module.c
Index: nginx-1.9.1/src/event/modules/ngx_epoll_module.c
===================================================================
--- nginx-1.2.9.orig/src/event/modules/ngx_epoll_module.c
+++ nginx-1.2.9/src/event/modules/ngx_epoll_module.c
@@ -70,10 +70,7 @@ int epoll_wait(int epfd, struct epoll_ev
--- nginx-1.9.1.orig/src/event/modules/ngx_epoll_module.c
+++ nginx-1.9.1/src/event/modules/ngx_epoll_module.c
@@ -76,9 +76,7 @@ int epoll_wait(int epfd, struct epoll_ev
#if (NGX_HAVE_FILE_AIO)
-#define SYS_io_setup 245
-#define SYS_io_destroy 246
-#define SYS_io_getevents 247
-#define SYS_eventfd 323
+#include <sys/syscall.h>
typedef u_int aio_context_t;
@@ -225,7 +222,11 @@ ngx_epoll_aio_init(ngx_cycle_t *cycle, n
int n;
struct epoll_event ee;
@@ -246,7 +244,11 @@ ngx_epoll_aio_init(ngx_cycle_t *cycle, n
#if (NGX_HAVE_SYS_EVENTFD_H)
ngx_eventfd = eventfd(0, 0);
#else
+#ifdef SYS_eventfd
ngx_eventfd = syscall(SYS_eventfd, 0);
+#else
+ ngx_eventfd = syscall(SYS_eventfd2, 0, 0);
+#endif
#endif
if (ngx_eventfd == -1) {
ngx_log_error(NGX_LOG_EMERG, cycle->log, ngx_errno,

View File

@ -1,3 +1,23 @@
-------------------------------------------------------------------
Thu Jun 11 14:55:50 UTC 2015 - i@marguerite.su
- update version 1.8.0 stable
* refer to http://nginx.org/en/CHANGES-1.8 for 1.7.x changes
- enable thread pools invented in nginx 1.7.11
- refactor nginx-1.4.2-passenger_fix.patch
* rename to nginx-1.4.2-passenger-4.0.18.patch
* remove zero_in_uri usage
- add patch: nginx-1.8.0-passenger-4.0.18.patch
* fix "warning: comparison between pointer and integer"
and "error: invalid type argument of -> (have int)"
- drop nginx-1.4.4-passenger-4.0.33_fix.patch
* webyast is dead, we only enable passenger on 13.1 and below,
for compatibility. this patch will never be applied now.
- drop nginx-1.4.4-passenger-3.0.12_fix.patch
* this patch intended to be applied on < 13.1 machines, but
13.1 is the oldest one we still have to build against.
- update fancyindex to version 0.3.5
-------------------------------------------------------------------
Sun Apr 12 04:37:00 UTC 2015 - mrueckert@suse.de

View File

@ -1,7 +1,7 @@
#
# spec file for package nginx
#
# Copyright (c) 2014 SUSE LINUX Products GmbH, Nuernberg, Germany.
# Copyright (c) 2015 SUSE LINUX GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
@ -24,13 +24,6 @@
%define ngx_log_dir %{_localstatedir}/log/nginx
%define ngx_error_log %{ngx_log_dir}/error.log
%define ngx_access_log %{ngx_log_dir}/access.log
%if 0%{?suse_version} <= 1310
%define ngx_pid_path %{_localstatedir}/run/nginx.pid
%define ngx_lock_path %{_localstatedir}/run/nginx.lock
%else
%define ngx_pid_path /run/nginx.pid
%define ngx_lock_path /run/nginx.lock
%endif
%define ngx_home %{_localstatedir}/lib/nginx
%define ngx_tmp_http %{ngx_home}/tmp/
%define ngx_tmp_proxy %{ngx_home}/proxy/
@ -41,7 +34,14 @@
%define with_cpp_test 0
%define with_google_perftools 0
%define with_fancyindex 1
%define fancyindex_version 0.3.3
%define fancyindex_version 0.3.5
%if 0%{?suse_version} <= 1310
%define ngx_pid_path %{_localstatedir}/run/nginx.pid
%define ngx_lock_path %{_localstatedir}/run/nginx.lock
%else
%define ngx_pid_path /run/nginx.pid
%define ngx_lock_path /run/nginx.lock
%endif
%if 0%{?suse_version} != 1315
%define with_libatomic 1
%endif
@ -58,9 +58,8 @@
BuildRequires: systemd
%{?systemd_requires}
%endif
Name: nginx
Version: 1.6.3
Version: 1.8.0
Release: 0
Summary: A HTTP server and IMAP/POP3 proxy server
License: BSD-2-Clause
@ -70,7 +69,7 @@ Source: http://nginx.org/download/nginx-%{version}.tar.gz
Source1: nginx.init
Source2: nginx.logrotate
Source3: nginx.service
Source4: https://github.com/aperezdc/ngx-fancyindex/archive/v%{fancyindex_version}.zip
Source4: https://github.com/aperezdc/ngx-fancyindex/archive/v%{fancyindex_version}/ngx-fancyindex-%{fancyindex_version}.tar.gz
Source100: nginx.rpmlintrc
# PATCH-FIX-UPSTREAM nginx-0.4.0-no_Werror.patch
Patch0: nginx-0.4.0-no_Werror.patch
@ -84,33 +83,37 @@ Patch4: nginx-1.6.1-default_config.patch
Patch5: nginx-1.0.15_docs.patch
# PATCH-FIX-UPSTREAM nginx-aio.patch fix support for Linux AIO
Patch6: nginx-aio.patch
%if 0%{?suse_version} > 1310
Patch7: nginx-1.4.4-passenger-4.0.33_fix.patch
%else
BuildRequires: gcc-c++
BuildRequires: gd-devel
BuildRequires: libxslt-devel
BuildRequires: openssl-devel
BuildRequires: pcre-devel
BuildRequires: pkgconfig
BuildRequires: zlib-devel
%requires_eq perl
Requires(pre): %fillup_prereq
Requires(pre): %insserv_prereq
Requires(pre): pwdutils
Recommends: logrotate
Conflicts: otherproviders(nginx)
Provides: http_daemon
Provides: httpd
BuildRoot: %{_tmppath}/%{name}-%{version}-build
%if 0%{?suse_version} == 1310
Patch7: nginx-1.4.2-passenger_fix.patch
%else
Patch7: nginx-1.4.4-passenger-3.0.12_fix.patch
%endif
Patch7: nginx-1.4.2-passenger-4.0.18.patch
Patch8: nginx-1.8.0-passenger-4.0.18.patch
%endif
%if 0%{?suse_version} <= 1310
BuildRequires: GeoIP-devel
%else
BuildRequires: libGeoIP-devel
%endif
BuildRequires: gcc-c++
BuildRequires: gd-devel
%if 0%{?with_google_perftools}
BuildRequires: google-perftools-devel
%endif
%if 0%{?with_libatomic}
BuildRequires: libatomic-ops-devel
%endif
BuildRequires: libxslt-devel
BuildRequires: openssl-devel
BuildRequires: pcre-devel
BuildRequires: pkgconfig
BuildRequires: zlib-devel
%if 0%{?with_passenger}
BuildRequires: curl-devel
BuildRequires: ruby-devel
@ -118,28 +121,11 @@ BuildRequires: rubygem-passenger
BuildRequires: rubygem-passenger-devel-static
Recommends: packageand(rubygem-passenger:rubygem-passenger-nginx)
%endif
%if 0%{?with_fancyindex}
BuildRequires: unzip
%endif
Conflicts: nginx-0.5 nginx-0.6 nginx-0.7 nginx-0.8 nginx-0.9 nginx-1.0 nginx-1.2 nginx-1.3 nginx-1.4 nginx-1.5 nginx-1.7
Provides: nginx-1.6 = %{version}
%requires_eq perl
PreReq: %fillup_prereq
PreReq: %insserv_prereq
Requires(pre): pwdutils
Recommends: logrotate
Provides: http_daemon
Provides: httpd
BuildRoot: %{_tmppath}/%{name}-%{version}-build
%description
nginx [engine x] is a HTTP server and IMAP/POP3 proxy server written by Igor Sysoev.
It has been running on many heavily loaded Russian sites for more than two years.
Author:
-------
Igor Sysoev
%prep
%if 0%{?with_fancyindex}
%setup -q -n %{pkg_name}-%{version} -b4
@ -164,6 +150,7 @@ if [[ -f "passenger/ext/common/libpassenger_common.a" ]] || \
fi
%endif
%patch7
%patch8
%endif
%if 0%{with_fancyindex}
@ -195,6 +182,7 @@ sed -i "s/\/var\/run/\/run/" %{_sourcedir}/nginx.init
--without-select_module \
--without-poll_module \
--with-file-aio \
--with-threads \
--with-ipv6 \
--with-http_ssl_module \
%if 0%{?suse_version} > 1220
@ -209,6 +197,7 @@ sed -i "s/\/var\/run/\/run/" %{_sourcedir}/nginx.init
--with-http_dav_module \
--with-http_flv_module \
--with-http_mp4_module \
--with-http_gunzip_module \
--with-http_gzip_static_module \
--with-http_auth_request_module \
--with-http_random_index_module \
@ -235,8 +224,8 @@ sed -i "s/\/var\/run/\/run/" %{_sourcedir}/nginx.init
%if 0%{with_fancyindex}
--add-module=../ngx-fancyindex-%{fancyindex_version} \
%endif
--with-md5=/usr \
--with-sha1=/usr \
--with-md5=%{_prefix} \
--with-sha1=%{_prefix} \
%if 0%{?suse_version} > 1220
--with-cc-opt="%{optflags} -fPIE -D_GNU_SOURCE -std=gnu99 -fstack-protector" \
--with-ld-opt="-Wl,-z,relro,-z,now -pie"

View File

@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:e0998e83be58bc5787fa9243a76a9d21de3cd01088d3cf63177ba88a562634a1
size 14837

View File

@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:5f90583b719380da4fe21f61ba868d3145221044f77f1c1997715bb0f22a1706
size 16981