Search
j0ke.net Open Build Service
>
Projects
>
home:netmax
:
playground
:
ruby
>
rubygem-passenger
> rubygem-passenger.spec
Sign Up
|
Log In
Username
Password
Cancel
Overview
Repositories
Revisions
Requests
Users
Advanced
Attributes
Meta
File rubygem-passenger.spec of Package rubygem-passenger
# # spec file for package rubygem-passenger # # Copyright (c) 2013 SUSE LINUX Products GmbH, Nuernberg, Germany. # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed # upon. The license for this file, and modifications and additions to the # file, is the same license as for the pristine package itself (unless the # license for the pristine package is not an Open Source License, in which # case the license is the MIT License). An "Open Source License" is a # license that conforms to the Open Source Definition (Version 1.9) # published by the Open Source Initiative. # Please submit bugfixes or comments via http://bugs.opensuse.org/ # Name: rubygem-passenger Version: 4.0.25 Release: 0 %define rb_ver %{rb19_ver} %define mod_name passenger %define mod_full_name %{mod_name}-%{version} %define apxs /usr/sbin/apxs2 %define apache_libexecdir %(%{apxs} -q LIBEXECDIR) %define apache_sysconfdir %(%{apxs} -q SYSCONFDIR) %define apache_mmn %(MMN=$(%{apxs} -q LIBEXECDIR)_MMN; test -x $MMN && $MMN) %if 0%{?suse_version} > 1100 %define with_system_boost 1 %endif %define use_system_libev 1 # # BuildRoot: %{_tmppath}/%{name}-%{version}-build BuildRequires: rubygems_with_buildroot_patch %rubygems19_requires # rake >= 0.8.1 BuildRequires: rubygem-rake >= 0.8.1 # fastthread >= 1.0.1 BuildRequires: rubygem-fastthread >= 1.0.1 # daemon_controller >= 0.2.5 BuildRequires: rubygem-daemon_controller >= 1.0.0 # rack >= 0 BuildRequires: apache2-devel BuildRequires: boost-devel BuildRequires: gcc-c++ BuildRequires: ruby19-devel BuildRequires: rubygem-rack-1 > 1.0 %if 0%{?suse_version} >= 1110 BuildRequires: libcurl-devel %else BuildRequires: curl-devel %endif BuildRequires: zlib-devel %if 0%{?use_system_libev} BuildRequires: libev-devel %endif Recommends: packageand(apache2:rubygem-passenger-apache2) Recommends: packageand(nginx:rubygem-passenger-nginx) # Url: http://www.modrails.com/ Source: %{mod_full_name}.gem # patches are just in for the case i find time to forward port them. # atm we use the static boost library that ships with passenger Source1: rubygem-passenger-2.0.5_system_boost.patch Source2: rubygem-passenger-2.0.5_boost_exception.patch Source3: rubygem-passenger-2.0.5_missing_includes.patch Source4: mod_passenger.conf Source5: mod_passenger_root.include Source6: nginx_passenger.conf Source7: nginx_passenger_root.include Source11: rubygem-passenger-3.0.12_boost_threads.patch Source12: rubygem-passenger-4.0.14_missing_includes.patch # Summary: Easy and robust Ruby web application deployment License: MIT and GPL-2.0 Group: Development/Languages/Ruby %description Easy and robust Ruby web application deployment. %package nginx Summary: Passenger Nginx module for Ruby on Rails support Group: Development/Languages/Ruby Requires: nginx Requires: rubygem-passenger = %{version} %description nginx Additional rubygem-passenger module for nginx HTTP-server. %package apache2 Summary: Passenger apache module Group: Development/Languages/Ruby Requires: %{apache_mmn} Requires: apache2 Requires: rubygem-passenger = %{version} %description apache2 Additional rubygem-passenger module for apache2 HTTP-server. %package doc Summary: RDoc documentation for %{mod_name} Group: Development/Languages/Ruby Requires: %{name} = %{version} %description doc Documentation generated at gem installation time. Usually in RDoc and RI formats. %package testsuite Summary: Test suite for %{mod_name} Group: Development/Languages/Ruby Requires: %{name} = %{version} %description testsuite Test::Unit or RSpec files, useful for developers. %package devel-static Summary: Files to develop passenger bindings for your webserver Group: Development/Languages/Ruby Requires: %{name} = %{version} Provides: %{name}-devel = %{version} %description devel-static The 2 static files that are needed to build the nginx extension %prep %build %install # TODO: # currently -lev gets lost when using system libev %if 0%{?use_system_libev} export USE_VENDORED_LIBEV="no" %endif %gem19_install %{S:0} || : # avoid BUILDROOT leaking into the binaries mv %{buildroot}%{_libdir}/ruby/gems/%{rb_ver}/gems/%{mod_full_name}/ . pushd %{mod_full_name} export PATH="%{_sbindir}:$PATH" patch --no-backup-if-mismatch -p0 --fuzz=0 -i %{S:11} patch --no-backup-if-mismatch -p1 --fuzz=0 -i %{S:12} #compiling nginx stuff rake nginx:clean nginx CACHING=no #compiling apache2 stuff rake apache2 %{__install} -D -m 0755 buildout/apache2/mod_passenger.so %{buildroot}%{apache_libexecdir}/mod_passenger.so # cleanup %if ! 0%{?use_system_libev} make -C ext/libev distclean %endif find buildout/apache2 -name \*.a -print -delete rm -v buildout/apache2/mod_passenger.so mv -v buildout/ruby/*/passenger_native_support.so lib/ rm -rv buildout/ruby/ruby-*-linux popd mv %{mod_full_name} %{buildroot}%{_libdir}/ruby/gems/%{rb_ver}/gems/%{mod_full_name} %gem19_cleanup find %{buildroot}%{_libdir}/ruby/gems/%{rb_ver}/gems/%{mod_full_name}/ -name dispatch.\* -print0 | \ xargs -r0 ruby -p -i -e 'gsub(%r{#!.*/bin/ruby.*}, "#!/usr/bin/ruby")' %{__install} -D -m 0644 %{S:4} %{buildroot}%{apache_sysconfdir}/conf.d/mod_passenger.conf %{__install} -D -m 0644 %{S:5} %{buildroot}%{apache_sysconfdir}/conf.d/mod_passenger_root.include %{__sed} -i -e "s,@PassengerRoot@,%{_libdir}/ruby/gems/%{rb_ver}/gems/%{mod_full_name}," %{buildroot}%{apache_sysconfdir}/conf.d/mod_passenger_root.include %{__install} -D -m 0644 %{S:6} %{buildroot}/etc/nginx/conf.d/passenger.conf %{__install} -D -m 0644 %{S:7} %{buildroot}/etc/nginx/conf.d/passenger_root.include %{__sed} -i -e "s,@PassengerRoot@,%{_libdir}/ruby/gems/%{rb_ver}/gems/%{mod_full_name}," %{buildroot}/etc/nginx/conf.d/passenger_root.include %{__rm} -v %{buildroot}%{_bindir}/passenger-install-*-module find %{buildroot}%{_libdir}/ruby/gems/%{rb_ver}/gems/%{mod_full_name}/{ext,test} -type f -print0 | xargs -r0 chmod a-x chmod a+r %{buildroot}%{_libdir}/ruby/gems/%{rb_ver}/gems/%{mod_full_name}/helper-scripts/download_binaries/* %files nginx %defattr(-,root,root) #%{_libdir}/ruby/gems/%{rb_ver}/gems/%{mod_full_name}/agents/nginx %dir /etc/nginx %dir /etc/nginx/conf.d %config(noreplace) /etc/nginx/conf.d/passenger.conf %config /etc/nginx/conf.d/passenger_root.include %files apache2 %defattr(-,root,root) %{apache_libexecdir}/mod_passenger.so %config(noreplace) %{apache_sysconfdir}/conf.d/mod_passenger.conf %config %{apache_sysconfdir}/conf.d/mod_passenger_root.include #%{_libdir}/ruby/gems/%{rb_ver}/gems/%{mod_full_name}/agents/apache2 %files %defattr(-,root,root,-) %{_bindir}/passenger %{_bindir}/passenger-config %{_bindir}/passenger-status %{_bindir}/passenger-memory-stats #%{_bindir}/passenger-make-enterprisey %{_libdir}/ruby/gems/%{rb_ver}/cache/%{mod_full_name}.gem %{_libdir}/ruby/gems/%{rb_ver}/gems/%{mod_full_name}/ # doc and testsuite subpackage %exclude %{_libdir}/ruby/gems/%{rb_ver}/gems/%{mod_full_name}/test %{_libdir}/ruby/gems/%{rb_ver}/specifications/%{mod_full_name}.gemspec # backend subpackages #%exclude %{_libdir}/ruby/gems/%{rb_ver}/gems/%{mod_full_name}/agents/apache2 #%exclude %{_libdir}/ruby/gems/%{rb_ver}/gems/%{mod_full_name}/agents/nginx # needed to build the nginx extension %exclude %{_libdir}/ruby/gems/%{rb_ver}/gems/%{mod_full_name}/buildout/common/libboost_oxt.a #%exclude %{_libdir}/ruby/gems/%{rb_ver}/gems/%{mod_full_name}/buildout/common/libpassenger_common.a %files doc %defattr(-,root,root,-) %doc %{_libdir}/ruby/gems/%{rb_ver}/doc/%{mod_full_name}/ %files testsuite %defattr(-,root,root,-) %{_libdir}/ruby/gems/%{rb_ver}/gems/%{mod_full_name}/test %files devel-static %defattr(-,root,root,-) %{_libdir}/ruby/gems/%{rb_ver}/gems/%{mod_full_name}/buildout/common/libboost_oxt.a #%{_libdir}/ruby/gems/%{rb_ver}/gems/%{mod_full_name}/buildout/common/libpassenger_common.a %changelog