Browse Source

mod_ruby: update to 1.3.0, drop apache1 support, merge apache2 package to main package

git-svn-id: http://trac.vinelinux.org/repos/projects/specs@3928 ec354946-7b23-47d6-9f5a-488ba84defc7
daisuke 14 years ago
parent
commit
945f2d242a
1 changed files with 21 additions and 92 deletions
  1. 21 92
      m/mod_ruby/mod_ruby-vl.spec

+ 21 - 92
m/mod_ruby/mod_ruby-vl.spec

@@ -1,35 +1,30 @@
-%define docroot			/home/httpd
-%define apxs			/usr/sbin/apxs
+%define docroot			/var/www/html
 %define apxs2			/usr/bin/apxs
-%define httpdmoddir		%(%{apxs} -q LIBEXECDIR)
-%define httpdconfdir		%(%{apxs} -q SYSCONFDIR)
 %define apache2moddir		%(%{apxs2} -q LIBEXECDIR)
 %define apache2confdir		%(%{apxs2} -q SYSCONFDIR)
-%define httpdconfmodruby	httpd.conf.mod_ruby
 %define apache2confmodruby	httpd.conf.mod_ruby
-%define apachever		1.3.29
-%define apache2ver		2.2.9
+%define apache2ver		2.2.14
 
 Summary: A Ruby interpreter for the Apache Web server.
-Summary(ja): Apacheサーバ組み込みのRuby言語インタプリタ
+Summary(ja): Apache2サーバ組み込みのRuby言語インタプリタ
 Name: mod_ruby
-Version: 1.2.6
+Version: 1.3.0
 Release: 1%{?_dist_release}
 License: distributable
 Group: System Environment/Daemons
 Source0: http://www.modruby.net/archive/%{name}-%{version}.tar.gz
-Source99: httpd.conf.mod_ruby
 Source100: httpd.conf.mod_ruby-apache2
-Patch10: mod_ruby-1.2.6-fix-xldflags.patch
 URL: http://www.modruby.net/
-Prefix: /usr
+
 BuildRoot: %{_tmppath}/%{name}-%{version}-root
 BuildRequires: ruby, ruby-devel
-BuildPreReq: apache, apache-devel >= %{apachever}
-BuildPreReq: apache2, apache2-devel >= %{apache2ver}
-Requires: apache >= %{apachever}, liberuby >= 1.0.5
+BuildRequires: apache2, apache2-devel >= %{apache2ver}
+Requires: apache2 >= %{apache2ver}
 Requires: ruby >= 1.8
-Requires: mod_ruby-common = %{version}-%{release}
+Provides: mod_ruby-apache2 = %{version}-%{release}
+Obsoletes: mod_ruby-apache2 < 1.3.0
+Obsoletes: mod_ruby-common < 1.3.0
+
 
 %description
 mod_ruby embeds the Ruby interpreter into the Apache web server,
@@ -37,76 +32,22 @@ allowing Ruby CGI scripts to be executed natively. These scripts
 will start up much faster than without mod_ruby.
 
 %description -l ja
-mod_rubyはApacheウェブサーバにRubyインタプリタを組み込み、CGIスクリ
-プトがネイティブに起動されることを許します。スクリプトはmod_rubyを利
-用しない場合よりも速く起動するでしょう。
-
-
-%package apache2
-Summary: A Ruby interpreter for the Apache2 Web server.
-Summary(ja): Apache2サーバ組み込みのRuby言語インタプリタ
-Group: System Environment/Daemons
-Requires: apache2 >= %{apache2ver}
-Requires: ruby >= 1.8
-Requires: mod_ruby-common = %{version}-%{release}
-
-%description apache2
-mod_ruby embeds the Ruby interpreter into the Apache web server,
-allowing Ruby CGI scripts to be executed natively. These scripts 
-will start up much faster than without mod_ruby.
-
-%description apache2 -l ja
 mod_rubyはApache2ウェブサーバにRubyインタプリタを組み込み、CGIスクリ
 プトがネイティブに起動されることを許します。スクリプトはmod_rubyを利
 用しない場合よりも速く起動するでしょう。
 
 
-%package common
-Summary: Ruby libraries for mod_ruby
-Summary(ja): mod_ruby 用の Ruby ライブラリ
-Group: System Environment/Daemons
-Requires: ruby >= 1.8
-
-%description common
-Ruby libraries for mod_ruby
-
-%description common -l ja
-mod_ruby 用の Ruby ライブラリ
-
-
 %prep
-%setup -q -c
-%patch10 -p0
+%setup -q
 
 
 %build
-## for apache1
-cd %{name}-%{version}
-ruby configure.rb --with-apxs=%{apxs}
+ruby configure.rb --with-apxs=%{apxs2} --with-apr-includes=/usr/include/apr-1
 make
-cd ..
 
 
 %install
 rm -rf ${RPM_BUILD_ROOT}
-mkdir -p ${RPM_BUILD_ROOT}%{httpdmoddir}
-mkdir -p ${RPM_BUILD_ROOT}%{httpdconfdir}
-
-# installing binaries ...
-cd %{name}-%{version}
-make install DESTDIR=${RPM_BUILD_ROOT}
-cd ..
-
-sed -e 's|@@DOCROOT@@|%{docroot}|g' < %{SOURCE99} \
-  > ${RPM_BUILD_ROOT}/%{httpdconfdir}/%{httpdconfmodruby}
-chmod 644 ${RPM_BUILD_ROOT}/%{httpdconfdir}/%{httpdconfmodruby}
-
-## for apache2
-cd %{name}-%{version}
-make clean
-ruby configure.rb --with-apxs=%{apxs2} --with-apr-includes=/usr/include/apr-1
-make
-
 mkdir -p ${RPM_BUILD_ROOT}%{apache2moddir}
 mkdir -p ${RPM_BUILD_ROOT}%{apache2confdir}
 make install DESTDIR=${RPM_BUILD_ROOT}
@@ -127,31 +68,19 @@ rm -f *.files
 %doc %{name}-%{version}/README.ja
 %doc %{name}-%{version}/ChangeLog
 %doc %{name}-%{version}/examples/
-%config %{httpdconfdir}/%{httpdconfmodruby}
-%{_libdir}/apache/*
-
-
-%files apache2
-%defattr(-, root, root)
-%doc %{name}-%{version}/README.en
-%doc %{name}-%{version}/README.ja
-%doc %{name}-%{version}/ChangeLog
-%doc %{name}-%{version}/examples/
 %config %{apache2confdir}/%{apache2confmodruby}
 %{_libdir}/apache2/*
-
-
-%files common
-%defattr(-, root, root)
-%doc %{name}-%{version}/README.en
-%doc %{name}-%{version}/README.ja
-%doc %{name}-%{version}/ChangeLog
-%{_libdir}/ruby/1.8/auto-reload.rb
-%dir %{_libdir}/ruby/1.8/apache
-%{_libdir}/ruby/1.8/apache/*
+%{rlibdir}/auto-reload.rb
+%dir %{rlibdir}/apache
+%{rlibdir}/apache/*
 
 
 %changelog
+* Sun May 22 2011 Daisuke SUZUKI <daisuke@linux.or.jp> 1.3.0-1
+- update to 1.3.0
+- drop apache1 support
+  - merge mod_ruby-apache2 and common to main package
+
 * Mon Sep 22 2008 MATSUBAYASHI Kohji <shaolin@vinelinux.org> - 1.2.6-1
 - new upstream release
 - add apache2/common subpackages