Revision f220cdf5
Added by specs-from-koji (Jenkins) about 10 years ago
rpms/epel-6/rubygem-passenger/apache-passenger.conf.in | ||
---|---|---|
LoadModule passenger_module modules/mod_passenger.so
|
||
<IfModule mod_passenger.c>
|
||
PassengerRoot @PASSENGERROOT@
|
||
PassengerRuby /usr/bin/ruby
|
||
PassengerRuby @BINDIR@/ruby
|
||
</IfModule>
|
||
|
||
# Deploying a Ruby on Rails application: an example
|
rpms/epel-6/rubygem-passenger/locations.ini | ||
---|---|---|
[locations]
|
||
natively_packaged=true
|
||
bin_dir=@BINDIR@
|
||
agents_dir=@GEM_EXTDIR@/agents
|
||
helper_scripts_dir=@GEM_INSTDIR@/helper-scripts
|
||
resources_dir=@GEM_INSTDIR@/resources
|
||
doc_dir=@GEM_DOCDIR@
|
||
ruby_libdir=@GEM_INSTDIR@/..
|
||
lib_dir=@GEM_INSTDIR@/lib
|
||
include_dir=@GEM_INSTDIR@/include
|
||
apache2_module_path=@HTTPD_MODDIR@
|
||
ruby_extension_source_dir=@GEM_INSTDIR@/ruby_extension_source
|
||
nginx_module_source_dir=@GEM_INSTDIR@/ngx_http_passenger_module
|
rpms/epel-6/rubygem-passenger/passenger.logrotate | ||
---|---|---|
/var/log/passenger-analytics/*.log {
|
||
$localstatedir/log/passenger-analytics/*.log {
|
||
missingok
|
||
notifempty
|
||
sharedscripts
|
rpms/epel-6/rubygem-passenger/passenger_do_not_sign_gem.patch | ||
---|---|---|
diff -up ./build/packaging.rb.nosign ./build/packaging.rb
|
||
--- ./build/packaging.rb.nosign 2013-05-28 18:33:10.117895835 +0200
|
||
+++ ./build/packaging.rb 2013-05-28 18:33:32.246157763 +0200
|
||
@@ -88,7 +88,7 @@ end
|
||
|
||
task 'package:gem' => Packaging::PREGENERATED_FILES do
|
||
require 'phusion_passenger'
|
||
- sh "gem build #{PhusionPassenger::PACKAGE_NAME}.gemspec --sign --key 0x0A212A8C"
|
||
+ sh "gem build #{PhusionPassenger::PACKAGE_NAME}.gemspec"
|
||
sh "mkdir -p pkg"
|
||
sh "mv #{PhusionPassenger::PACKAGE_NAME}-#{PhusionPassenger::VERSION_STRING}.gem pkg/"
|
||
end
|
rpms/epel-6/rubygem-passenger/passenger_dynamic_thread_group.patch | ||
---|---|---|
diff --git a/test/oxt/dynamic_thread_group_test.cpp b/test/oxt/dynamic_thread_group_test.cpp
|
||
index 003b7ef..5a90463 100644
|
||
--- a/test/oxt/dynamic_thread_group_test.cpp
|
||
+++ b/test/oxt/dynamic_thread_group_test.cpp
|
||
@@ -103,9 +103,9 @@ namespace tut {
|
||
}
|
||
|
||
static void create_threads(dynamic_thread_group *group) {
|
||
- for (int i = 1000; i >= 0; i--) {
|
||
+ for (int i = 100; i >= 0; i--) {
|
||
boost::function<void ()> f(boost::bind(do_nothing, i * 1000));
|
||
- group->create_thread(f, "", 256 * 1024);
|
||
+ group->create_thread(f, "", 8 * 1024);
|
||
}
|
||
}
|
||
|
rpms/epel-6/rubygem-passenger/passenger_include_sys_types.patch | ||
---|---|---|
diff -up ./ext/common/EventedMessageServer.h.types ./ext/common/EventedMessageServer.h
|
||
--- ./ext/common/EventedMessageServer.h.types 2013-06-03 13:37:58.254800329 +0200
|
||
+++ ./ext/common/EventedMessageServer.h 2013-06-03 13:38:23.193089923 +0200
|
||
@@ -27,6 +27,7 @@
|
||
|
||
#include <boost/shared_ptr.hpp>
|
||
#include <ev++.h>
|
||
+#include <sys/types.h>
|
||
#include <cstdarg>
|
||
#include <cstdlib>
|
||
#include <EventedServer.h>
|
||
diff -up ./ext/common/FileDescriptor.h.types ./ext/common/FileDescriptor.h
|
||
--- ./ext/common/FileDescriptor.h.types 2013-06-03 13:39:07.953609698 +0200
|
||
+++ ./ext/common/FileDescriptor.h 2013-06-03 13:39:37.223949595 +0200
|
||
@@ -30,6 +30,7 @@
|
||
#include <oxt/system_calls.hpp>
|
||
|
||
#include <utility>
|
||
+#include <sys/types.h>
|
||
#include <unistd.h>
|
||
#include <cerrno>
|
||
|
||
diff -up ./ext/common/Utils/BufferedIO.h.types ./ext/common/Utils/BufferedIO.h
|
||
--- ./ext/common/Utils/BufferedIO.h.types 2013-06-03 13:40:39.636674347 +0200
|
||
+++ ./ext/common/Utils/BufferedIO.h 2013-06-03 13:40:58.231890279 +0200
|
||
@@ -1,6 +1,7 @@
|
||
#ifndef _PASSENGER_BUFFERED_IO_H_
|
||
#define _PASSENGER_BUFFERED_IO_H_
|
||
|
||
+#include <sys/types.h>
|
||
#include <string>
|
||
#include <utility>
|
||
#include <algorithm>
|
||
diff -up ./ext/common/Utils/StreamBoyerMooreHorspool.h.types ./ext/common/Utils/StreamBoyerMooreHorspool.h
|
||
--- ./ext/common/Utils/StreamBoyerMooreHorspool.h.types 2013-06-03 13:42:43.866116917 +0200
|
||
+++ ./ext/common/Utils/StreamBoyerMooreHorspool.h 2013-06-03 13:43:14.619474026 +0200
|
||
@@ -189,7 +189,7 @@
|
||
#endif
|
||
#endif
|
||
|
||
-
|
||
+#include <sys/types.h>
|
||
#include <cstddef>
|
||
#include <cstring>
|
||
#include <cassert>
|
||
diff -up ./resources/mime.types ./resources/mime
|
||
diff -up ./test/stub/apache2/mime.types ./test/stub/apache2/mime
|
||
diff -up ./test/stub/nginx/mime.types ./test/stub/nginx/mime
|
rpms/epel-6/rubygem-passenger/passenger_remove_fastthread_dep.patch | ||
---|---|---|
diff -up ./lib/phusion_passenger/platform_info/depcheck_specs/gems.rb.fastthreaddep ./lib/phusion_passenger/platform_info/depcheck_specs/gems.rb
|
||
--- ./lib/phusion_passenger/platform_info/depcheck_specs/gems.rb.fastthreaddep 2013-06-03 10:56:56.815898127 +0200
|
||
+++ ./lib/phusion_passenger/platform_info/depcheck_specs/gems.rb 2013-06-03 10:57:59.086587118 +0200
|
||
@@ -1,11 +1,3 @@
|
||
-define 'fastthread' do
|
||
- name 'fastthread'
|
||
- define_checker do
|
||
- check_for_ruby_library('fastthread')
|
||
- end
|
||
- gem_install 'fastthread'
|
||
-end
|
||
-
|
||
define 'rack' do
|
||
name 'rack'
|
||
define_checker do
|
rpms/epel-6/rubygem-passenger/rubygem-passenger-4.0.18-CVE-2014-1832.patch | ||
---|---|---|
From 94428057c602da3d6d34ef75c78091066ecac5c0 Mon Sep 17 00:00:00 2001
|
||
From: "Hongli Lai (Phusion)" <hongli@phusion.nl>
|
||
Date: Wed, 29 Jan 2014 14:19:25 +0100
|
||
Subject: [PATCH] Fix a symlink-related security vulnerability.
|
||
|
||
The fix in commit 34b10878 and contained a small attack time window in
|
||
between two filesystem operations. This has been fixed.
|
||
---
|
||
NEWS | 18 ++++++++++++++++++
|
||
ext/common/ServerInstanceDir.h | 38 ++++++++++++++++++++++----------------
|
||
ext/common/Utils.cpp | 29 -----------------------------
|
||
ext/common/Utils.h | 6 ------
|
||
4 files changed, 40 insertions(+), 51 deletions(-)
|
||
|
||
diff --git a/ext/common/ServerInstanceDir.h b/ext/common/ServerInstanceDir.h
|
||
index 8da3cf3..1315de5 100644
|
||
--- a/ext/common/ServerInstanceDir.h
|
||
+++ b/ext/common/ServerInstanceDir.h
|
||
@@ -1,6 +1,6 @@
|
||
/*
|
||
* Phusion Passenger - https://www.phusionpassenger.com/
|
||
- * Copyright (c) 2010-2013 Phusion
|
||
+ * Copyright (c) 2010-2014 Phusion
|
||
*
|
||
* "Phusion Passenger" is a trademark of Hongli Lai & Ninh Bui.
|
||
*
|
||
@@ -193,6 +193,9 @@ class ServerInstanceDir: public noncopyable {
|
||
|
||
void initialize(const string &path, bool owner) {
|
||
TRACE_POINT();
|
||
+ struct stat buf;
|
||
+ int ret;
|
||
+
|
||
this->path = path;
|
||
this->owner = owner;
|
||
|
||
@@ -212,18 +215,25 @@ class ServerInstanceDir: public noncopyable {
|
||
* rights though, because we want admin tools to be able to list the available
|
||
* generations no matter what user they're running as.
|
||
*/
|
||
+
|
||
+ do {
|
||
+ ret = lstat(path.c_str(), &buf);
|
||
+ } while (ret == -1 && errno == EAGAIN);
|
||
if (owner) {
|
||
- switch (getFileTypeNoFollowSymlinks(path)) {
|
||
- case FT_NONEXISTANT:
|
||
+ if (ret == 0) {
|
||
+ if (S_ISDIR(buf.st_mode)) {
|
||
+ verifyDirectoryPermissions(path, buf);
|
||
+ } else {
|
||
+ throw RuntimeException("'" + path + "' already exists, and is not a directory");
|
||
+ }
|
||
+ } else if (errno == ENOENT) {
|
||
createDirectory(path);
|
||
- break;
|
||
- case FT_DIRECTORY:
|
||
- verifyDirectoryPermissions(path);
|
||
- break;
|
||
- default:
|
||
- throw RuntimeException("'" + path + "' already exists, and is not a directory");
|
||
+ } else {
|
||
+ int e = errno;
|
||
+ throw FileSystemException("Cannot lstat '" + path + "'",
|
||
+ e, path);
|
||
}
|
||
- } else if (getFileType(path) != FT_DIRECTORY) {
|
||
+ } else if (!S_ISDIR(buf.st_mode)) {
|
||
throw RuntimeException("Server instance directory '" + path +
|
||
"' does not exist");
|
||
}
|
||
@@ -259,14 +269,10 @@ class ServerInstanceDir: public noncopyable {
|
||
* so that an attacker cannot pre-create a directory with too liberal
|
||
* permissions.
|
||
*/
|
||
- void verifyDirectoryPermissions(const string &path) {
|
||
+ void verifyDirectoryPermissions(const string &path, struct stat &buf) {
|
||
TRACE_POINT();
|
||
- struct stat buf;
|
||
|
||
- if (stat(path.c_str(), &buf) == -1) {
|
||
- int e = errno;
|
||
- throw FileSystemException("Cannot stat() " + path, e, path);
|
||
- } else if (buf.st_mode != (S_IFDIR | parseModeString("u=rwx,g=rx,o=rx"))) {
|
||
+ if (buf.st_mode != (S_IFDIR | parseModeString("u=rwx,g=rx,o=rx"))) {
|
||
throw RuntimeException("Tried to reuse existing server instance directory " +
|
||
path + ", but it has wrong permissions");
|
||
} else if (buf.st_uid != geteuid() || buf.st_gid != getegid()) {
|
||
diff --git a/ext/common/Utils.cpp b/ext/common/Utils.cpp
|
||
index d1db8d6..1f3dec5 100644
|
||
--- a/ext/common/Utils.cpp
|
||
+++ b/ext/common/Utils.cpp
|
||
@@ -143,35 +143,6 @@
|
||
}
|
||
}
|
||
|
||
-FileType
|
||
-getFileTypeNoFollowSymlinks(const StaticString &filename) {
|
||
- struct stat buf;
|
||
- int ret;
|
||
-
|
||
- ret = lstat(filename.c_str(), &buf);
|
||
- if (ret == 0) {
|
||
- if (S_ISREG(buf.st_mode)) {
|
||
- return FT_REGULAR;
|
||
- } else if (S_ISDIR(buf.st_mode)) {
|
||
- return FT_DIRECTORY;
|
||
- } else if (S_ISLNK(buf.st_mode)) {
|
||
- return FT_SYMLINK;
|
||
- } else {
|
||
- return FT_OTHER;
|
||
- }
|
||
- } else {
|
||
- if (errno == ENOENT) {
|
||
- return FT_NONEXISTANT;
|
||
- } else {
|
||
- int e = errno;
|
||
- string message("Cannot lstat '");
|
||
- message.append(filename);
|
||
- message.append("'");
|
||
- throw FileSystemException(message, e, filename);
|
||
- }
|
||
- }
|
||
-}
|
||
-
|
||
void
|
||
createFile(const string &filename, const StaticString &contents, mode_t permissions, uid_t owner,
|
||
gid_t group, bool overwrite)
|
||
diff --git a/ext/common/Utils.h b/ext/common/Utils.h
|
||
index 5cfaf92..a04e507 100644
|
||
--- a/ext/common/Utils.h
|
||
+++ b/ext/common/Utils.h
|
||
@@ -65,8 +65,6 @@
|
||
FT_REGULAR,
|
||
/** A directory. */
|
||
FT_DIRECTORY,
|
||
- /** A symlink. Only returned by getFileTypeNoFollowSymlinks(), not by getFileType(). */
|
||
- FT_SYMLINK,
|
||
/** Something else, e.g. a pipe or a socket. */
|
||
FT_OTHER
|
||
} FileType;
|
||
@@ -123,10 +121,6 @@ bool fileExists(const StaticString &filename, CachedFileStat *cstat = 0,
|
||
*/
|
||
FileType getFileType(const StaticString &filename, CachedFileStat *cstat = 0,
|
||
unsigned int throttleRate = 0);
|
||
-/**
|
||
- * Like getFileType(), but does not follow symlinks.
|
||
- */
|
||
-FileType getFileTypeNoFollowSymlinks(const StaticString &filename);
|
||
|
||
/**
|
||
* Create the given file with the given contents, permissions and ownership.
|
||
--
|
||
1.8.5.1
|
||
|
rpms/epel-6/rubygem-passenger/rubygem-passenger-4.0.18-GLIBC_HAVE_LONG_LONG.patch | ||
---|---|---|
diff -urp passenger-release-4.0.18.orig/ext/boost/cstdint.hpp passenger-release-4.0.18/ext/boost/cstdint.hpp
|
||
--- passenger-release-4.0.18.orig/ext/boost/cstdint.hpp 2013-09-17 13:47:54.000000000 -0500
|
||
+++ passenger-release-4.0.18/ext/boost/cstdint.hpp 2013-09-23 16:34:02.074450639 -0500
|
||
@@ -41,7 +41,15 @@
|
||
// so we disable use of stdint.h when GLIBC does not define __GLIBC_HAVE_LONG_LONG.
|
||
// See https://svn.boost.org/trac/boost/ticket/3548 and http://sources.redhat.com/bugzilla/show_bug.cgi?id=10990
|
||
//
|
||
-#if defined(BOOST_HAS_STDINT_H) && (!defined(__GLIBC__) || defined(__GLIBC_HAVE_LONG_LONG))
|
||
+// This define has been dropped altogether in GLIBC 2.17. As of then,
|
||
+// support for long long is part of baseline requirements, and
|
||
+// [u]int64_t is always defined. See here:
|
||
+// http://sourceware.org/ml/libc-alpha/2013-01/msg00440.html
|
||
+//
|
||
+#if defined(BOOST_HAS_STDINT_H) \
|
||
+ && (!defined(__GLIBC__) \
|
||
+ || defined(__GLIBC_HAVE_LONG_LONG) \
|
||
+ || (defined __GLIBC_PREREQ && __GLIBC_PREREQ(2,17)))
|
||
|
||
// The following #include is an implementation artifact; not part of interface.
|
||
# ifdef __hpux
|
||
Only in passenger-release-4.0.18/ext/boost: cstdint.hpp.glibc-long
|
rpms/epel-6/rubygem-passenger/rubygem-passenger-4.0.18-correct_docs.patch | ||
---|---|---|
diff -urp passenger-release-4.0.18.orig/lib/phusion_passenger/packaging.rb passenger-release-4.0.18/lib/phusion_passenger/packaging.rb
|
||
--- passenger-release-4.0.18.orig/lib/phusion_passenger/packaging.rb 2013-09-17 13:47:54.000000000 -0500
|
||
+++ passenger-release-4.0.18/lib/phusion_passenger/packaging.rb 2013-09-24 14:42:54.126310781 -0500
|
||
@@ -36,7 +36,7 @@ module Packaging
|
||
# Files that must be generated before packaging.
|
||
PREGENERATED_FILES = [
|
||
'ext/common/Constants.h',
|
||
- 'doc/Packaging.html'
|
||
+ 'doc/Packaging.txt.md'
|
||
] + ASCII_DOCS
|
||
|
||
USER_EXECUTABLES = [
|
rpms/epel-6/rubygem-passenger/rubygem-passenger-4.0.18-daemon-controller.patch | ||
---|---|---|
diff --git a/passenger.gemspec b/passenger.gemspec
|
||
index f7de823..688e757 100644
|
||
--- a/passenger.gemspec
|
||
+++ b/passenger.gemspec
|
||
@@ -15,7 +15,7 @@ Gem::Specification.new do |s|
|
||
s.email = "software-signing@phusion.nl"
|
||
s.require_paths = ["lib"]
|
||
s.add_dependency 'rake', '>= 0.8.1'
|
||
- s.add_dependency 'daemon_controller', '>= 1.1.0'
|
||
+# s.add_dependency 'daemon_controller', '>= 1.1.0'
|
||
s.add_dependency 'rack'
|
||
s.files = Dir[*PhusionPassenger::Packaging::GLOB] -
|
||
Dir[*PhusionPassenger::Packaging::EXCLUDE_GLOB]
|
rpms/epel-6/rubygem-passenger/rubygem-passenger-4.0.18-gcc47-include-sys_types.patch | ||
---|---|---|
diff -urp passenger-release-4.0.18.orig/ext/common/EventedMessageServer.h passenger-release-4.0.18/ext/common/EventedMessageServer.h
|
||
--- passenger-release-4.0.18.orig/ext/common/EventedMessageServer.h 2013-09-17 13:47:54.000000000 -0500
|
||
+++ passenger-release-4.0.18/ext/common/EventedMessageServer.h 2013-09-23 13:59:23.012484647 -0500
|
||
@@ -27,6 +27,7 @@
|
||
|
||
#include <boost/shared_ptr.hpp>
|
||
#include <ev++.h>
|
||
+#include <sys/types.h>
|
||
#include <cstdarg>
|
||
#include <cstdlib>
|
||
#include <EventedServer.h>
|
||
diff -urp passenger-release-4.0.18.orig/ext/common/FileDescriptor.h passenger-release-4.0.18/ext/common/FileDescriptor.h
|
||
--- passenger-release-4.0.18.orig/ext/common/FileDescriptor.h 2013-09-17 13:47:54.000000000 -0500
|
||
+++ passenger-release-4.0.18/ext/common/FileDescriptor.h 2013-09-23 13:59:23.013484647 -0500
|
||
@@ -30,6 +30,7 @@
|
||
#include <oxt/system_calls.hpp>
|
||
|
||
#include <utility>
|
||
+#include <sys/types.h>
|
||
#include <unistd.h>
|
||
#include <cerrno>
|
||
|
||
diff -urp passenger-release-4.0.18.orig/ext/common/Utils/BufferedIO.h passenger-release-4.0.18/ext/common/Utils/BufferedIO.h
|
||
--- passenger-release-4.0.18.orig/ext/common/Utils/BufferedIO.h 2013-09-17 13:47:54.000000000 -0500
|
||
+++ passenger-release-4.0.18/ext/common/Utils/BufferedIO.h 2013-09-23 13:59:23.014484646 -0500
|
||
@@ -1,6 +1,7 @@
|
||
#ifndef _PASSENGER_BUFFERED_IO_H_
|
||
#define _PASSENGER_BUFFERED_IO_H_
|
||
|
||
+#include <sys/types.h>
|
||
#include <string>
|
||
#include <utility>
|
||
#include <algorithm>
|
||
diff -urp passenger-release-4.0.18.orig/ext/common/Utils/StreamBoyerMooreHorspool.h passenger-release-4.0.18/ext/common/Utils/StreamBoyerMooreHorspool.h
|
||
--- passenger-release-4.0.18.orig/ext/common/Utils/StreamBoyerMooreHorspool.h 2013-09-17 13:47:54.000000000 -0500
|
||
+++ passenger-release-4.0.18/ext/common/Utils/StreamBoyerMooreHorspool.h 2013-09-23 13:59:23.015484645 -0500
|
||
@@ -189,7 +189,7 @@
|
||
#endif
|
||
#endif
|
||
|
||
-
|
||
+#include <sys/types.h>
|
||
#include <cstddef>
|
||
#include <cstring>
|
||
#include <cassert>
|
rpms/epel-6/rubygem-passenger/rubygem-passenger-4.0.18-tmpsymlink.patch | ||
---|---|---|
From 34b1087870c2bf85ebfd72c30b78577e10ab9744 Mon Sep 17 00:00:00 2001
|
||
From: "Hongli Lai (Phusion)" <hongli@phusion.nl>
|
||
Date: Tue, 28 Jan 2014 19:17:39 +0100
|
||
Subject: [PATCH] Fix low-urgency security vulnerability: writing files to
|
||
arbitrary directory by hijacking temp directories.
|
||
|
||
---
|
||
NEWS | 30 ++++++++++++++++++++++++++++++
|
||
ext/common/ServerInstanceDir.h | 2 +-
|
||
ext/common/Utils.cpp | 29 +++++++++++++++++++++++++++++
|
||
ext/common/Utils.h | 8 +++++++-
|
||
4 files changed, 67 insertions(+), 2 deletions(-)
|
||
|
||
diff --git a/ext/common/ServerInstanceDir.h b/ext/common/ServerInstanceDir.h
|
||
index 136437a..8da3cf3 100644
|
||
--- a/ext/common/ServerInstanceDir.h
|
||
+++ b/ext/common/ServerInstanceDir.h
|
||
@@ -213,7 +213,7 @@ class ServerInstanceDir: public noncopyable {
|
||
* generations no matter what user they're running as.
|
||
*/
|
||
if (owner) {
|
||
- switch (getFileType(path)) {
|
||
+ switch (getFileTypeNoFollowSymlinks(path)) {
|
||
case FT_NONEXISTANT:
|
||
createDirectory(path);
|
||
break;
|
||
diff --git a/ext/common/Utils.cpp b/ext/common/Utils.cpp
|
||
index 1f3dec5..d1db8d6 100644
|
||
--- a/ext/common/Utils.cpp
|
||
+++ b/ext/common/Utils.cpp
|
||
@@ -143,6 +143,35 @@
|
||
}
|
||
}
|
||
|
||
+FileType
|
||
+getFileTypeNoFollowSymlinks(const StaticString &filename) {
|
||
+ struct stat buf;
|
||
+ int ret;
|
||
+
|
||
+ ret = lstat(filename.c_str(), &buf);
|
||
+ if (ret == 0) {
|
||
+ if (S_ISREG(buf.st_mode)) {
|
||
+ return FT_REGULAR;
|
||
+ } else if (S_ISDIR(buf.st_mode)) {
|
||
+ return FT_DIRECTORY;
|
||
+ } else if (S_ISLNK(buf.st_mode)) {
|
||
+ return FT_SYMLINK;
|
||
+ } else {
|
||
+ return FT_OTHER;
|
||
+ }
|
||
+ } else {
|
||
+ if (errno == ENOENT) {
|
||
+ return FT_NONEXISTANT;
|
||
+ } else {
|
||
+ int e = errno;
|
||
+ string message("Cannot lstat '");
|
||
+ message.append(filename);
|
||
+ message.append("'");
|
||
+ throw FileSystemException(message, e, filename);
|
||
+ }
|
||
+ }
|
||
+}
|
||
+
|
||
void
|
||
createFile(const string &filename, const StaticString &contents, mode_t permissions, uid_t owner,
|
||
gid_t group, bool overwrite)
|
||
diff --git a/ext/common/Utils.h b/ext/common/Utils.h
|
||
index 41e6214..5cfaf92 100644
|
||
--- a/ext/common/Utils.h
|
||
+++ b/ext/common/Utils.h
|
||
@@ -65,6 +65,8 @@
|
||
FT_REGULAR,
|
||
/** A directory. */
|
||
FT_DIRECTORY,
|
||
+ /** A symlink. Only returned by getFileTypeNoFollowSymlinks(), not by getFileType(). */
|
||
+ FT_SYMLINK,
|
||
/** Something else, e.g. a pipe or a socket. */
|
||
FT_OTHER
|
||
} FileType;
|
||
@@ -110,7 +112,7 @@ bool fileExists(const StaticString &filename, CachedFileStat *cstat = 0,
|
||
/**
|
||
* Check whether 'filename' exists and what kind of file it is.
|
||
*
|
||
- * @param filename The filename to check.
|
||
+ * @param filename The filename to check. It MUST be NULL-terminated.
|
||
* @param mstat A CachedFileStat object, if you want to use cached statting.
|
||
* @param throttleRate A throttle rate for cstat. Only applicable if cstat is not NULL.
|
||
* @return The file type.
|
||
@@ -121,6 +123,10 @@ bool fileExists(const StaticString &filename, CachedFileStat *cstat = 0,
|
||
*/
|
||
FileType getFileType(const StaticString &filename, CachedFileStat *cstat = 0,
|
||
unsigned int throttleRate = 0);
|
||
+/**
|
||
+ * Like getFileType(), but does not follow symlinks.
|
||
+ */
|
||
+FileType getFileTypeNoFollowSymlinks(const StaticString &filename);
|
||
|
||
/**
|
||
* Create the given file with the given contents, permissions and ownership.
|
||
--
|
||
1.8.5.1
|
||
|
rpms/epel-6/rubygem-passenger/rubygem-passenger-4.0.18_apache_fix_autofoo.patch | ||
---|---|---|
diff -urp passenger-release-4.0.18.orig/build/basics.rb passenger-release-4.0.18/build/basics.rb
|
||
--- passenger-release-4.0.18.orig/build/basics.rb 2013-09-17 13:47:54.000000000 -0500
|
||
+++ passenger-release-4.0.18/build/basics.rb 2013-09-23 16:11:12.926455965 -0500
|
||
@@ -138,7 +138,7 @@ LIBEXT = PlatformInfo.library_extensio
|
||
USE_DMALLOC = boolean_option('USE_DMALLOC')
|
||
USE_EFENCE = boolean_option('USE_EFENCE')
|
||
USE_ASAN = boolean_option('USE_ASAN')
|
||
-OPTIMIZATION_FLAGS = "#{PlatformInfo.debugging_cflags} -DPASSENGER_DEBUG -DBOOST_DISABLE_ASSERTS -fcommon".strip
|
||
+OPTIMIZATION_FLAGS = "#{ENV['CXXFLAGS']} #{PlatformInfo.debugging_cflags} -DPASSENGER_DEBUG -DBOOST_DISABLE_ASSERTS -fcommon".strip
|
||
OPTIMIZATION_FLAGS << " -O" if OPTIMIZE
|
||
OPTIMIZATION_FLAGS << " -feliminate-unused-debug-symbols -feliminate-unused-debug-types" if PlatformInfo.compiler_supports_feliminate_unused_debug?
|
||
OPTIMIZATION_FLAGS << " -fvisibility=hidden -DVISIBILITY_ATTRIBUTE_SUPPORTED" if PlatformInfo.compiler_supports_visibility_flag?
|
rpms/epel-6/rubygem-passenger/rubygem-passenger-4.0.18_native_dir.patch | ||
---|---|---|
diff --git a/lib/phusion_passenger/native_support.rb b/lib/phusion_passenger/native_support.rb
|
||
index 994c379..d2b84fc 100644
|
||
--- a/lib/phusion_passenger/native_support.rb
|
||
+++ b/lib/phusion_passenger/native_support.rb
|
||
@@ -113,7 +113,7 @@ private
|
||
end
|
||
|
||
def load_from_load_path
|
||
- require 'passenger_native_support'
|
||
+ require "%%NATIVE_SUPPORT_DIR%%/native/#{library_name}"
|
||
return true
|
||
rescue LoadError
|
||
return false
|
rpms/epel-6/rubygem-passenger/rubygem-passenger-4.0.18_remove_fastthread_dep.patch | ||
---|---|---|
diff -urp passenger-release-4.0.18.orig/lib/phusion_passenger/platform_info/depcheck_specs/gems.rb passenger-release-4.0.18/lib/phusion_passenger/platform_info/depcheck_specs/gems.rb
|
||
--- passenger-release-4.0.18.orig/lib/phusion_passenger/platform_info/depcheck_specs/gems.rb 2013-09-17 13:47:54.000000000 -0500
|
||
+++ passenger-release-4.0.18/lib/phusion_passenger/platform_info/depcheck_specs/gems.rb 2013-09-23 16:27:59.963267382 -0500
|
||
@@ -1,11 +1,3 @@
|
||
-define 'fastthread' do
|
||
- name 'fastthread'
|
||
- define_checker do
|
||
- check_for_ruby_library('fastthread')
|
||
- end
|
||
- gem_install 'fastthread'
|
||
-end
|
||
-
|
||
define 'rack' do
|
||
name 'rack'
|
||
define_checker do
|
||
Only in passenger-release-4.0.18/lib/phusion_passenger/platform_info/depcheck_specs: gems.rb.fastthread
|
rpms/epel-6/rubygem-passenger/rubygem-passenger.spec | ||
---|---|---|
%global gem_name passenger
|
||
|
||
%{?scl:%scl_package rubygem-%{gem_name}}
|
||
%{!?scl:%global pkg_name %{name}}
|
||
%{?scl:%scl_package rubygem-%{gem_name}}
|
||
|
||
%if 0%{?fedora} >= 19
|
||
%global gem_extdir %{gem_extdir_mri}
|
||
%endif
|
||
|
||
%if !("%{?scl}" == "ruby193" || 0%{?rhel} > 6 || 0%{?fedora} > 16)
|
||
%define gem_dir %(ruby -rubygems -e 'puts Gem::dir' 2>/dev/null)
|
||
%define gem_instdir %{gem_dir}/gems/%{gem_name}-%{version}
|
||
%define gem_cache %{gem_dir}/cache/%{gem_name}-%{version}.gem
|
||
%define gem_docdir %{gem_dir}/doc/%{gem_name}-%{version}
|
||
%define gem_spec %{gem_dir}/specifications/%{gem_name}-%{version}.gemspec
|
||
%define ruby_vendorarchdir %{_libdir}/ruby
|
||
%if 0%{?rhel} <= 6
|
||
%{!?gem_extdir:%global gem_extdir %{_libdir}/gems/exts/%{gem_name}-%{version}}
|
||
%endif
|
||
|
||
%{!?_httpd_apxs: %{expand: %%global _httpd_apxs %%{_sbindir}/apxs}}
|
||
%{!?_httpd_mmn: %{expand: %%global _httpd_mmn %%(cat %{_includedir}/httpd/.mmn 2>/dev/null || echo missing-httpd-devel)}}
|
||
%{!?_httpd_confdir: %{expand: %%global _httpd_confdir %%{_sysconfdir}/httpd/conf.d}}
|
||
# /etc/httpd/conf.d with httpd < 2.4 and defined as /etc/httpd/conf.modules.d with httpd >= 2.4
|
||
%{!?_httpd_modconfdir: %{expand: %%global _httpd_modconfdir %%{_sysconfdir}/httpd/conf.d}}
|
||
%{!?_httpd_moddir: %{expand: %%global _httpd_moddir %%{_libdir}/httpd/modules}}
|
||
|
||
Summary: Passenger Ruby web application server
|
||
Name: %{?scl_prefix}rubygem-%{gem_name}
|
||
Version: 4.0.5
|
||
Release: 7%{?dist}
|
||
Version: 4.0.18
|
||
Release: 9%{?dist}
|
||
Group: System Environment/Daemons
|
||
# Passenger code uses MIT license.
|
||
# Bundled(Boost) uses Boost Software License
|
||
... | ... | |
License: Boost and BSD and BSD with advertising and MIT and zlib
|
||
|
||
URL: http://www.modrails.com
|
||
BuildRoot: %{_tmppath}/%{pkg_name}-%{version}-%{release}-root-%(%{__id_u} -n)
|
||
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
|
||
|
||
Source: http://phusion-passenger.googlecode.com/files/passenger-%{version}.tar.gz
|
||
Source: https://github.com/FooBarWidget/passenger/archive/release-%{version}.tar.gz
|
||
Source1: passenger.logrotate
|
||
Source2: rubygem-passenger.tmpfiles
|
||
Source10: apache-passenger.conf.in
|
||
#Source20: nginx-passenger4.conf.in
|
||
|
||
# Get passenger to recognize our path preferences
|
||
#Patch1: rubygem-passenger-3.0.12-force-native.patch
|
||
Source11: locations.ini
|
||
|
||
# Include sys/types.h for GCC 4.7
|
||
Patch2: passenger_include_sys_types.patch
|
||
|
||
# Remove signing gems with GPG, requires rubygem-openpgp >= 0.3.0
|
||
Patch3: passenger_do_not_sign_gem.patch
|
||
Patch2: rubygem-passenger-4.0.18-gcc47-include-sys_types.patch
|
||
|
||
# Make example config for tests ready for linux by default
|
||
Patch4: passenger_tests_default_config_example.patch
|
||
|
||
#Patch10: rubygem-passenger-3.0.12-spoof-nginx-install.patch
|
||
|
||
# Honor CXXFLAGS in the environment.
|
||
#Patch100: passenger_apache_fix_autofoo.patch
|
||
Patch100: rubygem-passenger-4.0.18_apache_fix_autofoo.patch
|
||
|
||
# Test tries to spawn 1000 threads with 256kb stacks. Default Linux settings
|
||
# deny allocating so much, causing test to fail. Let's use 8kb stacks instead.
|
||
#Patch102: passenger_dynamic_thread_group.patch
|
||
|
||
# Use rspec2 conventions
|
||
#Patch103: passenger_rspec2_helper.patch
|
||
Patch102: passenger_dynamic_thread_group.patch
|
||
|
||
# Remove checking for fastthread on F17+
|
||
Patch104: passenger_remove_fastthread_dep.patch
|
||
Patch104: rubygem-passenger-4.0.18_remove_fastthread_dep.patch
|
||
|
||
# https://bugzilla.redhat.com/show_bug.cgi?id=985634
|
||
Patch107: rubygem-passenger-4.0.18-GLIBC_HAVE_LONG_LONG.patch
|
||
|
||
# bz1059084 - https://github.com/phusion/passenger/commit/34b1087870c2.patch
|
||
Patch108: rubygem-passenger-4.0.18-tmpsymlink.patch
|
||
|
||
# removes -Werror in upstream build scripts. -Werror conflicts with
|
||
# -D_FORTIFY_SOURCE=2 causing warnings to turn into errors.
|
||
##Patch200: nginx-auto-cc-gcc.patch
|
||
# bz1059084 - https://github.com/phusion/passenger/commit/94428057c602.patch
|
||
Patch109: rubygem-passenger-4.0.18-CVE-2014-1832.patch
|
||
|
||
# Until rubygem-bluecloth is in Fedora, don't use it
|
||
Patch201: rubygem-passenger-4.0.18-correct_docs.patch
|
||
|
||
# Load native library from proper directory
|
||
Patch202: rubygem-passenger-4.0.18_native_dir.patch
|
||
Patch203: rubygem-passenger-4.0.18-daemon-controller.patch
|
||
|
||
Requires: %{?scl_prefix}rubygems
|
||
Requires: %{?scl_prefix}rubygem(daemon_controller) >= 1.1.0
|
||
# XXX: Needed to run passenger standalone
|
||
#Requires: %{?scl_prefix}rubygem(daemon_controller) >= 1.0.0
|
||
Requires: %{?scl_prefix}rubygem(rack)
|
||
Requires: %{?scl_prefix}rubygem(rake)
|
||
%if 0%{?fedora} >= 19
|
||
Requires: %{?scl_prefix}ruby(release)
|
||
%else
|
||
Requires: %{?scl_prefix}ruby
|
||
%endif
|
||
Requires: %{?scl_prefix}ruby(abi)
|
||
|
||
%if 0%{?rhel} >= 6 || 0%{?fedora} >= 15
|
||
BuildRequires: libcurl-devel
|
||
... | ... | |
BuildRequires: curl-devel
|
||
%endif
|
||
|
||
%if "%{?scl}" != "ruby193" && 0%{?rhel} <= 6 && 0%{?fedora} <= 16
|
||
Requires: %{?scl_prefix}rubygem(fastthread) >= 1.0.1
|
||
BuildRequires: %{?scl_prefix}rubygem(fastthread) >= 1.0.1
|
||
%endif
|
||
# %if 0%{?rhel} <= 6 && 0%{?fedora} <= 16
|
||
# Requires: rubygem(fastthread) >= 1.0.1
|
||
# BuildRequires: rubygem(fastthread) >= 1.0.1
|
||
# %endif
|
||
|
||
BuildRequires: asciidoc
|
||
BuildRequires: boost-devel
|
||
BuildRequires: doxygen
|
||
BuildRequires: graphviz
|
||
BuildRequires: httpd-devel
|
||
BuildRequires: libev-devel
|
||
# BuildRequires: libev-devel
|
||
BuildRequires: %{?scl_prefix}ruby
|
||
BuildRequires: %{?scl_prefix}ruby-devel
|
||
BuildRequires: %{?scl_prefix}rubygems
|
||
|
||
%if "%{?scl}" == "ruby193" || 0%{?rhel} > 6 || 0%{?fedora} > 16
|
||
BuildRequires: %{?scl_prefix}rubygems-devel
|
||
%endif
|
||
|
||
BuildRequires: %{?scl_prefix}rubygem(rake) >= 0.8.1
|
||
BuildRequires: %{?scl_prefix}rubygem(rack)
|
||
BuildRequires: %{?scl_prefix}rubygem(rspec)
|
||
BuildRequires: %{?scl_prefix}rubygem(mime-types)
|
||
BuildRequires: source-highlight
|
||
# BuildRequires: source-highlight
|
||
|
||
# XXX
|
||
BuildRequires: zlib-devel
|
||
|
||
Provides: %{?scl_prefix}rubygem(%{gem_name}) = %{version}-%{release}
|
||
Provides: %{?scl_prefix}bundled(boost) = 1.44
|
||
Provides: bundled(boost) = 1.44
|
||
|
||
%description
|
||
Phusion Passenger™ — a.k.a. mod_rails or mod_rack — makes deployment
|
||
... | ... | |
%package -n %{?scl_prefix}mod_passenger
|
||
Summary: Apache Module for Phusion Passenger
|
||
Group: System Environment/Daemons
|
||
BuildRequires: httpd-devel
|
||
Requires: httpd >= 2.2
|
||
BuildRequires: httpd-devel
|
||
Requires: httpd-mmn = %{_httpd_mmn}
|
||
Requires: %{?scl_prefix}rubygem(%{gem_name}) = %{version}-%{release}
|
||
Requires: %{?scl_prefix}%{pkg_name}-native%{?_isa} = %{version}-%{release}
|
||
Requires: %{name}-native%{?_isa} = %{version}-%{release}
|
||
License: Boost and BSD and BSD with advertising and MIT and zlib
|
||
|
||
%description -n %{?scl_prefix}mod_passenger
|
||
... | ... | |
Summary: Apache Module for Phusion Passenger
|
||
Group: System Environment/Daemons
|
||
Requires: %{?scl_prefix}rubygem(%{gem_name}) = %{version}-%{release}
|
||
Provides: %{?scl_prefix}bundled(boost-devel) = 1.44
|
||
Provides: bundled(boost-devel) = 1.44
|
||
License: Boost and BSD and BSD with advertising and GPL+ and MIT and zlib
|
||
|
||
%description devel
|
||
... | ... | |
Summary: Phusion Passenger native extensions
|
||
Group: System Environment/Daemons
|
||
Requires: %{?scl_prefix}rubygem(%{gem_name}) = %{version}-%{release}
|
||
Requires: %{?scl_prefix}%{pkg_name}-native-libs%{?_isa} = %{version}-%{release}
|
||
Requires: %{?scl_prefix}%{pkg_name}%{?_isa} = %{version}-%{release}
|
||
Requires: libev
|
||
Requires: %{name}-native-libs%{?_isa} = %{version}-%{release}
|
||
Requires: %{name}%{?_isa} = %{version}-%{release}
|
||
License: Boost and BSD and BSD with advertising and MIT and zlib
|
||
%description native
|
||
This package contains the native code extensions for Apache & Nginx
|
||
... | ... | |
%package native-libs
|
||
Summary: Phusion Passenger native extensions
|
||
Group: System Environment/Daemons
|
||
Requires: %{?scl_prefix}%{pkg_name}%{?_isa} = %{version}-%{release}
|
||
Requires: %{name}%{?_isa} = %{version}-%{release}
|
||
Requires: %{?scl_prefix}ruby
|
||
License: Boost and BSD and BSD with advertising and MIT and zlib
|
||
%description native-libs
|
||
... | ... | |
|
||
|
||
%prep
|
||
%setup -q -n passenger-%{version}
|
||
%setup -q -n %{gem_name}-release-%{version}
|
||
|
||
#%patch1 -p1 -b .force-native
|
||
%patch2 -p1 -b .include-sys-types
|
||
%patch3 -p1 -b .nosign
|
||
%patch4 -p1 -b .lindefault
|
||
|
||
#%patch20 -p1 -b .spawnip
|
||
#%patch100 -p0 -b .autofoo
|
||
#%patch102 -p1 -b .threadtest
|
||
#%patch103 -p1 -b .rspec2
|
||
%patch100 -p1 -b .autofoo
|
||
%patch102 -p1 -b .threadtest
|
||
|
||
# remove fastthread checking
|
||
%if "%{?scl}" == "ruby193" || 0%{?fedora} >= 17
|
||
# %if 0%{?fedora} >= 17
|
||
%patch104 -p1 -b .fastthread
|
||
# %endif
|
||
|
||
# fix passenger boost for glibc >= 2.18
|
||
%if 0%{?fedora} >= 20
|
||
%patch107 -p1 -b .glibc-long
|
||
%endif
|
||
|
||
%patch108 -p1 -b .tmpsymlink
|
||
%patch109 -p1 -b .1832
|
||
|
||
# Until bluecloth is in Fedora, don't use it
|
||
%patch201 -p1 -b .docs
|
||
%patch202 -p1 -b .nativedir
|
||
%patch203 -p1 -b .daemoncontroller
|
||
|
||
# Don't use bundled libev
|
||
%{__rm} -rf ext/libev
|
||
# %{__rm} -rf ext/libev
|
||
|
||
# asciidoc 8.4.x doesn't have an html5 backend
|
||
%{__sed} -i 's/-b html5/-b html4/' build/documentation.rb
|
||
... | ... | |
# fix up install paths
|
||
%{__sed} -i \
|
||
-e 's|%%%%GEM_INSTALL_DIR%%%%|%{gem_instdir}|g' \
|
||
-e 's|%%%%APACHE_INSTALLED_MOD%%%%|%{_libdir}/httpd/modules/|g' \
|
||
-e 's|%%%%AGENTS_DIR%%%%|%{gem_instdir}/agents|g' \
|
||
-e 's|%%%%APACHE_INSTALLED_MOD%%%%|%{_httpd_moddir}|g' \
|
||
-e 's|%%%%AGENTS_DIR%%%%|%{gem_extdir}/agents|g' \
|
||
-e 's|%%%%NATIVE_SUPPORT_DIR%%%%|%{gem_extdir}/lib|g' \
|
||
lib/phusion_passenger.rb \
|
||
lib/phusion_passenger/native_support.rb \
|
||
... | ... | |
done
|
||
|
||
%build
|
||
%{?scl:scl enable %{scl} '}
|
||
export USE_VENDORED_LIBEV=false
|
||
CFLAGS="${CFLAGS:-%optflags}" ; export CFLAGS ;
|
||
EXTRA_CFLAGS="${CFLAGS:-%optflags}" ; export EXTRA_CFLAGS ;
|
||
CXXFLAGS="${CXXFLAGS:-%optflags}" ; export CXXFLAGS ;
|
||
EXTRA_CXXFLAGS="${CXXFLAGS:-%optflags}" ; export EXTRA_CXXFLAGS ;
|
||
# export USE_VENDORED_LIBEV=false
|
||
CFLAGS="${CFLAGS:-%optflags} -fno-strict-aliasing" ; export CFLAGS ;
|
||
CXXFLAGS="${CXXFLAGS:-%optflags} -fno-strict-aliasing" ; export CXXFLAGS ;
|
||
FFLAGS="${FFLAGS:-%optflags}" ; export FFLAGS ;
|
||
#CONFIGURE_ARGS='--with-cflags='%{optflags}'' ; export CONFIGURE_ARGS ;
|
||
|
||
rake package:gem
|
||
%if 0%{?scl:1}
|
||
. /opt/rh/%scl/enable
|
||
%endif
|
||
|
||
rake package:gem SKIP_SIGNING=1
|
||
rake apache2
|
||
#rake nginx
|
||
%{?scl: '}
|
||
|
||
%install
|
||
export USE_VENDORED_LIBEV=false
|
||
export MANPATH=%{_mandir}:\$MANPATH
|
||
# export USE_VENDORED_LIBEV=false
|
||
|
||
%if 0%{?scl:1}
|
||
. /opt/rh/%scl/enable
|
||
%endif
|
||
|
||
# Install the gem.
|
||
%{?scl:scl enable %{scl} "}
|
||
gem install -V \
|
||
--local \
|
||
--install-dir %{buildroot}%{gem_dir} \
|
||
... | ... | |
--force \
|
||
--rdoc \
|
||
pkg/%{gem_name}-%{version}.gem
|
||
%{?scl:"}
|
||
|
||
# Install locations.ini
|
||
install -pm 0644 %{SOURCE11} %{buildroot}%{gem_instdir}/lib/phusion_passenger/
|
||
%{__sed} -i 's|@BINDIR@|%{_bindir}|' %{buildroot}%{gem_instdir}/lib/phusion_passenger/locations.ini
|
||
%{__sed} -i 's|@GEM_EXTDIR@|%{gem_extdir}|' %{buildroot}%{gem_instdir}/lib/phusion_passenger/locations.ini
|
||
%{__sed} -i 's|@GEM_INSTDIR@|%{gem_instdir}|' %{buildroot}%{gem_instdir}/lib/phusion_passenger/locations.ini
|
||
%{__sed} -i 's|@GEM_DOCDIR@|%{gem_docdir}|' %{buildroot}%{gem_instdir}/lib/phusion_passenger/locations.ini
|
||
%{__sed} -i 's|@HTTPD_MODDIR@|%{_httpd_moddir}|' %{buildroot}%{gem_instdir}/lib/phusion_passenger/locations.ini
|
||
|
||
# Install Apache module.
|
||
%{__mkdir_p} %{buildroot}/%{_libdir}/httpd/modules
|
||
install -pm 0755 libout/apache2/mod_passenger.so %{buildroot}/%{_libdir}/httpd/modules
|
||
%{__mkdir_p} %{buildroot}/%{_httpd_moddir}
|
||
install -pm 0755 buildout/apache2/mod_passenger.so %{buildroot}/%{_httpd_moddir}
|
||
|
||
# Install Apache config.
|
||
%{__mkdir_p} %{buildroot}/%{_sysconfdir}/httpd/conf.d
|
||
install -pm 0644 %{SOURCE10} %{buildroot}%{_sysconfdir}/httpd/conf.d/passenger.conf
|
||
%{__sed} -i -e 's|@PASSENGERROOT@|%{gem_instdir}|g' %{buildroot}/%{_sysconfdir}/httpd/conf.d/passenger.conf
|
||
%{__mkdir_p} %{buildroot}%{_httpd_confdir} %{buildroot}%{_httpd_modconfdir}
|
||
%{__sed} -e 's|@PASSENGERROOT@|%{gem_instdir}/lib/phusion_passenger/locations.ini|g' %{SOURCE10} > passenger.conf
|
||
%{__sed} -i 's|@BINDIR@|%{_bindir}|' passenger.conf
|
||
|
||
%if "%{_httpd_modconfdir}" != "%{_httpd_confdir}"
|
||
%{__sed} -n /^LoadModule/p passenger.conf > 10-passenger.conf
|
||
%{__sed} -i /^LoadModule/d passenger.conf
|
||
touch -r %{SOURCE10} 10-passenger.conf
|
||
install -pm 0644 10-passenger.conf %{buildroot}%{_httpd_modconfdir}/passenger.conf
|
||
%endif
|
||
touch -r %{SOURCE10} passenger.conf
|
||
install -pm 0644 passenger.conf %{buildroot}%{_httpd_confdir}/passenger.conf
|
||
|
||
|
||
# Install man pages into the proper location.
|
||
%{__mkdir_p} %{buildroot}%{_mandir}/man1
|
||
... | ... | |
rmdir %{buildroot}%{gem_instdir}/man
|
||
|
||
# The agents aren't in the gem for some reason...
|
||
%{__chmod} -R 0755 agents/*
|
||
%{__mkdir_p} %{buildroot}%{gem_instdir}
|
||
%{__cp} -a agents %{buildroot}%{gem_instdir}
|
||
%{__chmod} -R 0755 buildout/agents/*
|
||
%{__mkdir_p} %{buildroot}%{gem_extdir}
|
||
%{__cp} -a buildout/agents %{buildroot}%{gem_extdir}
|
||
%{__rm} -f %{buildroot}%{gem_extdir}/agents/*.o
|
||
|
||
# Make our ghost log and run directories...
|
||
%{__mkdir_p} %{buildroot}%{_localstatedir}/log/passenger-analytics
|
||
|
||
# logrotate
|
||
%{__mkdir_p} %{buildroot}%{_sysconfdir}/logrotate.d
|
||
install -pm 0644 %{SOURCE1} %{buildroot}%{_sysconfdir}/logrotate.d/passenger
|
||
|
||
# tmpfiles.d
|
||
%if 0%{?fedora} > 15
|
||
%{__mkdir_p} %{buildroot}/run
|
||
%{__mkdir_p} %{buildroot}%{_prefix}/lib/tmpfiles.d
|
||
install -m 0644 %{SOURCE2} %{buildroot}%{_prefix}/lib/tmpfiles.d/%{pkg_name}.conf
|
||
install -d -m 0755 %{buildroot}/run/%{pkg_name}
|
||
%else
|
||
%{__mkdir_p} %{buildroot}%{_localstatedir}/run/%{pkg_name}
|
||
%endif
|
||
|
||
# Fix wrong EOF encoding on the RI files...
|
||
for file in `find %{buildroot}%{gem_docdir} -type f -name "*.ri"`; do
|
||
sed -i 's/\r//' $file
|
||
done
|
||
%{__mkdir_p} %{buildroot}/etc/logrotate.d
|
||
install -pm 0644 %{SOURCE1} %{buildroot}/etc/logrotate.d/%{?scl_prefix}passenger
|
||
sed -i 's|\$localstatedir|%{_localstatedir}|' \
|
||
%{buildroot}/etc/logrotate.d/%{?scl_prefix}passenger
|
||
|
||
# # tmpfiles.d
|
||
# %if 0%{?fedora} > 15
|
||
# %{__mkdir_p} %{buildroot}/run
|
||
# %{__mkdir_p} %{buildroot}%{_prefix}/lib/tmpfiles.d
|
||
# install -m 0644 %{SOURCE2} %{buildroot}%{_prefix}/lib/tmpfiles.d/%{name}.conf
|
||
# install -d -m 0755 %{buildroot}/run/%{name}
|
||
# %else
|
||
%{__mkdir_p} %{buildroot}%{_localstatedir}/run/rubygem-passenger
|
||
# %endif
|
||
|
||
# Bring over just the native binaries
|
||
%if "%{?scl}" != "ruby193" && 0%{?rhel} <= 6 && 0%{?fedora} < 17
|
||
%{__mkdir_p} %{buildroot}%{_libdir}/ruby/site_ruby/1.8
|
||
install -m 0755 libout/ruby/ruby*linux/passenger_native_support.so %{buildroot}%{_libdir}/ruby/site_ruby/1.8
|
||
%else
|
||
%{__mkdir_p} %{buildroot}%{ruby_vendorarchdir}
|
||
install -m 0755 libout/ruby/ruby*linux/passenger_native_support.so %{buildroot}%{ruby_vendorarchdir}
|
||
%endif
|
||
%{__mkdir_p} %{buildroot}%{gem_extdir}/lib/native
|
||
install -m 0755 buildout/ruby/ruby*linux/passenger_native_support.so %{buildroot}%{gem_extdir}/lib/native
|
||
|
||
# Remove zero-length files
|
||
# Remove zero-length and non-needed files
|
||
find %{buildroot}%{gem_instdir} -type f -size 0c -delete
|
||
%{__rm} -rf %{buildroot}%{gem_instdir}/.gitignore
|
||
%{__rm} -rf %{buildroot}%{gem_instdir}/.yardoc
|
||
%{__rm} -rf %{buildroot}%{gem_instdir}/rpm/
|
||
|
||
%{__rm} -rf %{buildroot}%{gem_dir}/gems/%{gem_name}-%{version}/.yardoc
|
||
|
||
# Don't install the installation scripts. That's why we have packaging.
|
||
%{__rm} %{buildroot}{%{_bindir},%{gem_instdir}/bin}/%{gem_name}-install-apache2-module
|
||
%{__rm} %{buildroot}{%{_bindir},%{gem_instdir}/bin}/%{gem_name}-install-nginx-module
|
||
find %{buildroot}%{_bindir} -type f | xargs chmod a+x
|
||
|
||
find %{buildroot} -name "*.o" -exec rm -f {} \;
|
||
# Don't install the installation scripts and Rakefile. That's why we have packaging.
|
||
%{__rm} %{buildroot}%{gem_instdir}/bin/%{gem_name}-install-apache2-module
|
||
%{__rm} %{buildroot}%{gem_instdir}/bin/%{gem_name}-install-nginx-module
|
||
%{__rm} %{buildroot}%{_bindir}/%{gem_name}-install-apache2-module
|
||
%{__rm} %{buildroot}%{_bindir}/%{gem_name}-install-nginx-module
|
||
%{__rm} %{buildroot}%{gem_instdir}/Rakefile
|
||
|
||
%check
|
||
export USE_VENDORED_LIBEV=false
|
||
%if 0%{?scl:1}
|
||
. /opt/rh/%scl/enable
|
||
%endif
|
||
|
||
# export USE_VENDORED_LIBEV=false
|
||
# Run the tests, capture the output, but don't fail the build if the tests fail
|
||
#
|
||
# This will make the test failure non-critical, but it should be examined
|
||
... | ... | |
|
||
%{__cp} test/config.json.example test/config.json
|
||
|
||
%{__mkdir_p} test/stub/wsgi/tmp
|
||
|
||
%{?scl:scl enable %{scl} "}
|
||
rake test --trace ||:
|
||
%{?scl:"}
|
||
|
||
%files
|
||
%doc %{gem_instdir}/README.md
|
||
%doc %{gem_instdir}/CONTRIBUTING.md
|
||
%doc %{gem_instdir}/CONTRIBUTORS
|
||
%doc %{gem_instdir}/LICENSE
|
||
%doc %{gem_instdir}/NEWS
|
||
%{gem_cache}
|
||
%{gem_spec}
|
||
%{gem_instdir}/passenger.gemspec
|
||
%{gem_instdir}/.travis.yml
|
||
%dir %{gem_instdir}
|
||
%{_bindir}/passenger
|
||
%{_bindir}/passenger-config
|
||
%{_bindir}/passenger-status
|
||
%{_bindir}/passenger-memory-stats
|
||
%{gem_instdir}/bin
|
||
%{gem_instdir}/helper-scripts
|
||
%{gem_instdir}/lib
|
||
%{gem_instdir}/passenger.gemspec
|
||
%{gem_instdir}/resources
|
||
%{gem_instdir}/.travis.yml
|
||
%{_bindir}/%{gem_name}*
|
||
%{_mandir}/man1/%{gem_name}-*
|
||
%{_mandir}/man8/%{gem_name}-*
|
||
%if 0%{?fedora} > 15
|
||
%{_prefix}/lib/tmpfiles.d/%{pkg_name}.conf
|
||
%dir /run/rubygem-passenger
|
||
%else
|
||
%dir %{_localstatedir}/run/rubygem-passenger
|
||
%endif
|
||
%exclude %{gem_instdir}/configure
|
||
%exclude %{gem_instdir}/debian/
|
||
%exclude %{gem_instdir}/debian.template/
|
||
%exclude %{gem_cache}
|
||
|
||
%files doc
|
||
... | ... | |
|
||
%files devel
|
||
%doc %{gem_instdir}/INSTALL.md
|
||
%doc %{gem_instdir}/CONTRIBUTING.md
|
||
%{gem_instdir}/Rakefile
|
||
%{gem_instdir}/test
|
||
%{gem_instdir}/build
|
||
%{gem_instdir}/dev
|
||
%{gem_instdir}/ext
|
||
|
||
%files -n %{?scl_prefix}mod_passenger
|
||
%config(noreplace) %{_sysconfdir}/httpd/conf.d/passenger.conf
|
||
%config(noreplace) %{_httpd_modconfdir}/*.conf
|
||
%{_httpd_moddir}/mod_passenger.so
|
||
%doc doc/Users?guide?Apache.txt
|
||
%{_libdir}/httpd/modules/mod_passenger.so
|
||
|
||
%files native
|
||
%{gem_instdir}/agents
|
||
%{gem_extdir}/agents
|
||
%dir %{_localstatedir}/log/passenger-analytics
|
||
%{_sysconfdir}/logrotate.d/passenger
|
||
/etc/logrotate.d/%{?scl_prefix}passenger
|
||
|
||
%files native-libs
|
||
%if "%{?scl}" != "ruby193" && 0%{?rhel} <= 6 && 0%{?fedora} < 17
|
||
%dir %{_libdir}/ruby/site_ruby/1.8
|
||
%{_libdir}/ruby/site_ruby/1.8
|
||
%else
|
||
%dir %{ruby_vendorarchdir}
|
||
%{ruby_vendorarchdir}
|
||
%endif
|
||
%dir %{gem_extdir}
|
||
%{gem_extdir}/lib
|
||
|
||
%changelog
|
||
* Mon Dec 02 2013 Jason Montleon <jmontleo@redhat.com> 4.0.5-7
|
||
- remove empty changelog entry and fix chronological order
|
||
(jmontleo@redhat.com)
|
||
- comment out configure_args again (jmontleo@redhat.com)
|
||
- don't remove debug package anymore (jmontleo@redhat.com)
|
||
- move find command to delete o files (jmontleo@redhat.com)
|
||
- try different find args for finding o files (jmontleo@redhat.com)
|
||
- try different find args for finding o files (jmontleo@redhat.com)
|
||
- remove post install macro to prevent stripping. This should be fixed
|
||
(jmontleo@redhat.com)
|
||
|
||
* Wed Nov 27 2013 Dominic Cleal <dcleal@redhat.com> 4.0.5-6
|
||
- Define EXTRA_CFLAGS/CXXFLAGS so agents are compiled with RPM CFLAGS
|
||
(dcleal@redhat.com)
|
||
|
||
* Fri Oct 04 2013 Dominic Cleal <dcleal@redhat.com> 4.0.5-5
|
||
- fixes #3197 - don't write binstubs to gem install's bin/ (dcleal@redhat.com)
|
||
|
||
* Thu Sep 12 2013 Sam Kottler <shk@redhat.com> 4.0.5-12
|
||
- Remove object files so the debuginfo package doesn't explode (shk@redhat.com)
|
||
|
||
* Mon Jun 10 2013 Martin Bačovský <mbacovsk@redhat.com> 4.0.5-4
|
||
- Fixed native-libs paths on F18 (mbacovsk@redhat.com)
|
||
|
||
* Thu Jun 06 2013 Martin Bačovský <mbacovsk@redhat.com> 4.0.5-3
|
||
- Fixed binary utils path and manpath (mbacovsk@redhat.com)
|
||
|
||
* Wed Jun 05 2013 Martin Bačovský <mbacovsk@redhat.com> 4.0.5-2
|
||
- new package built with tito
|
||
- update to 4.0.5
|
||
- support for SCL
|
||
* Wed Mar 05 2014 Jan Kaluza <jkaluza@redhat.com> - 4.0.18-9
|
||
- fix the dependency on daemon-controller (#1072927)
|
||
|
||
* Fri Feb 14 2014 Jan Kaluza <jkaluza@redhat.com> - 4.0.18-8
|
||
- fix corrupted RI documentation (#1064824)
|
||
|
||
* Mon Feb 03 2014 Jan Kaluza <jkaluza@redhat.com> - 4.0.18-7
|
||
- fix also CVE-2014-1832 (#1059084)
|
||
|
||
* Wed Jan 29 2014 Jan Kaluza <jkaluza@redhat.com> - 4.0.18-6
|
||
- fix a symlink-related security vulnerability (#1059084)
|
||
|
||
* Tue Nov 26 2013 Joe Orton <jorton@redhat.com> - 4.0.18-5
|
||
- build with no-strict-aliasing
|
||
|
||
* Mon Nov 11 2013 Jan Kaluza <jkaluza@redhat.com> - 4.0.18-4
|
||
- load native library from proper path
|
||
|
||
* Mon Nov 11 2013 Jan Kaluza <jkaluza@redhat.com> - 4.0.18-3
|
||
- support for software collections
|
||
|
||
* Wed Sep 25 2013 Troy Dawson <tdawson@redhat.com> - 4.0.18-2
|
||
- Cleanup spec file
|
||
- Fix for bz#987879
|
||
|
||
* Tue Sep 24 2013 Troy Dawson <tdawson@redhat.com> - 4.0.18-1
|
||
- Update to 4.0.18
|
||
- Remove patches no longer needed
|
||
- Update patches that need updating
|
||
|
||
* Mon Sep 23 2013 Brett Lentz <blentz@redhat.com> - 3.0.21-9
|
||
- finish fixing bz#999384
|
||
|
||
* Fri Sep 20 2013 Joe Orton <jorton@redhat.com> - 3.0.21-8
|
||
- update packaging for httpd 2.4.x
|
||
|
||
* Thu Sep 19 2013 Troy Dawson <tdawson@redhat.com> - 3.0.21-7
|
||
- Fix for F20 FTBFS (#993310)
|
||
|
||
* Thu Aug 22 2013 Brett Lentz <blentz@redhat.com> - 3.0.21-6
|
||
- bz#999384
|
||
|
||
* Sun Aug 04 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 3.0.21-5
|
||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild
|
||
|
||
* Thu Jul 18 2013 Troy Dawson <tdawson@redhat.com> - 3.0.21-4
|
||
- Fix for CVE-2013-4136 (#985634)
|
||
|
||
* Fri Jun 21 2013 Troy Dawson <tdawson@redhat.com> - 3.0.21-3
|
||
- Putting the agents back to where they originally were
|
||
|
||
* Fri Jun 21 2013 Troy Dawson <tdawson@redhat.com> - 3.0.21-2
|
||
- Remove Rakefile (only used for building) (#976843)
|
||
|
||
* Thu May 30 2013 Troy Dawson <tdawson@redhat.com> - 3.0.21-1
|
||
- Update to version 3.0.21
|
||
- Fix for CVE-2013-2119
|
||
|
||
* Thu May 16 2013 Troy Dawson <tdawson@redhat.com> - 3.0.19-4
|
||
- Fix to make agents work on F19+
|
Also available in: Unified diff
Update rubygem-passenger to 4.0.18-9.el6