From bd4c77bb2ba0ee9c6cfd33ad92daeb2e2a5140559d7e1889020bb8009f449bb4 Mon Sep 17 00:00:00 2001 From: Stephan Kulow Date: Mon, 13 Oct 2014 08:40:49 +0000 Subject: [PATCH] Accepting request 255548 from home:coolo:branches:devel:languages:ruby:extensions - adapt to new rubygem packaging OBS-URL: https://build.opensuse.org/request/show/255548 OBS-URL: https://build.opensuse.org/package/show/devel:languages:ruby:extensions/rubygem-eventmachine?expand=0&rev=26 --- gem2rpm.yml | 71 ++++++++++++++++++++++++++++++++++++ rubygem-eventmachine.changes | 5 +++ rubygem-eventmachine.spec | 55 +++++++++------------------- 3 files changed, 94 insertions(+), 37 deletions(-) create mode 100644 gem2rpm.yml diff --git a/gem2rpm.yml b/gem2rpm.yml new file mode 100644 index 0000000..441e8f3 --- /dev/null +++ b/gem2rpm.yml @@ -0,0 +1,71 @@ +# --- +# ## used by gem2rpm +# :summary: this is a custom summary +# ## used by gem2rpm +# :description: |- +# this is a custom description +# +# it can be multiline +# ## used by gem2rpm +# :license: MIT or Ruby +# ## used by gem2rpm and gem_packages +# :version_suffix: -x_y +# ## used by gem2rpm and gem_packages +# :disable_docs: true +# ## used by gem2rpm +# :disable_automatic_rdoc_dep: true +# ## used by gem2rpm +:preamble: |- + BuildRequires: gcc-c++ + BuildRequires: openssl-devel + BuildRequires: pkg-config +# ## used by gem2rpm +# :patches: +# foo.patch: -p1 +# bar.patch: +# ## used by gem2rpm +# :sources: +# - foo.desktop +# - bar.desktop +# :gem_install_args: '....' +# ## used by gem2rpm +# :pre_install: |- +# %if 0%{?use_system_libev} +# export USE_VENDORED_LIBEV="no" +# %endif +# ## used by gem2rpm +# :post_install: |- +# # delete custom files here or do other fancy stuff +# install -D -m 0644 %{S:1} %{buildroot}%{_bindir}/gem2rpm-opensuse +# ## used by gem2rpm +# :testsuite_command: |- +# (pushd %{buildroot}%{gem_base}/gems/%{mod_full_name} && rake test) +# ## used by gem2rpm +# :filelist: |- +# /usr/bin/gem2rpm-opensuse +# ## used by gem2rpm +# :scripts: +# :post: |- +# /bin/echo foo +# ## used by gem_packages +# :main: +# :preamble: |- +# Requires: util-linux +# Recommends: pwgen +# :filelist: |- +# /usr/bin/gem2rpm-opensuse +# ## used by gem_packages +# :custom: +# apache: +# :preamble: |- +# Requires: ..... +# :filelist: |- +# /etc/apache2/conf.d/passenger.conf +# :summary: Custom summary is optional +# :description: |- +# Custom description is optional +# +# bar +# :post: |- +# /bin/echo foo +# diff --git a/rubygem-eventmachine.changes b/rubygem-eventmachine.changes index 1d83ade..db81cdf 100644 --- a/rubygem-eventmachine.changes +++ b/rubygem-eventmachine.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Mon Oct 13 08:37:57 UTC 2014 - coolo@suse.com + +- adapt to new rubygem packaging + ------------------------------------------------------------------- Thu Feb 6 08:29:10 UTC 2014 - coolo@suse.com diff --git a/rubygem-eventmachine.spec b/rubygem-eventmachine.spec index 9551f68..cdadf5e 100644 --- a/rubygem-eventmachine.spec +++ b/rubygem-eventmachine.spec @@ -14,26 +14,31 @@ # Please submit bugfixes or comments via http://bugs.opensuse.org/ # - +# +# This file was generated with a gem2rpm.yml and not just plain gem2rpm. +# All sections marked as MANUAL, license headers, summaries and descriptions +# can be maintained in that file. Please consult this file before editing any +# of those fields +# Name: rubygem-eventmachine Version: 1.0.3 Release: 0 %define mod_name eventmachine %define mod_full_name %{mod_name}-%{version} - -BuildRoot: %{_tmppath}/%{name}-%{version}-build -BuildRequires: ruby-macros >= 3 -BuildRequires: rubygem(rdoc) > 3.10 -# MANUAL BEGIN +# MANUAL BuildRequires: gcc-c++ BuildRequires: openssl-devel BuildRequires: pkg-config -BuildRequires: ruby-devel -Provides: rubygem(%{rb_ver}:eventmachine) = 1.0.0.beta5 -# MANUAL END +# /MANUAL +BuildRoot: %{_tmppath}/%{name}-%{version}-build +BuildRequires: ruby-macros >= 5 +BuildRequires: %{rubydevel} +BuildRequires: %{rubygem gem2rpm} +BuildRequires: %{rubygem rdoc > 3.10} Url: http://rubyeventmachine.com Source: http://rubygems.org/gems/%{mod_full_name}.gem +Source1: gem2rpm.yml Summary: Ruby/EventMachine library License: Ruby Group: Development/Languages/Ruby @@ -50,40 +55,16 @@ are provided with the package, primarily to serve as examples. The real goal of EventMachine is to enable programs to easily interface with other programs using TCP/IP, especially if custom protocols are required. -%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. - %prep -#gem_unpack -#if you need patches, apply them here and replace the # with a % sign in the surrounding lines -#gem_build %build %install -%gem_install -f +%gem_install \ + --doc-files="CHANGELOG.md LICENSE README.md" \ + -f %gem_cleanup -mkdir -p %{buildroot}%{_docdir}/%{name} -ln -s %{gem_base}/gems/%{mod_full_name}/CHANGELOG.md %buildroot/%{_docdir}/%{name}/CHANGELOG.md -ln -s %{gem_base}/gems/%{mod_full_name}/LICENSE %buildroot/%{_docdir}/%{name}/LICENSE -ln -s %{gem_base}/gems/%{mod_full_name}/README.md %buildroot/%{_docdir}/%{name}/README.md -%files -%defattr(-,root,root,-) -%{_docdir}/%{name} -%{gem_base}/cache/%{mod_full_name}.gem -%{gem_base}/gems/%{mod_full_name}/ -%{gem_extensions}/%{mod_full_name} -%{gem_base}/specifications/%{mod_full_name}.gemspec - -%files doc -%defattr(-,root,root,-) -%doc %{gem_base}/doc +%gem_packages %changelog