Created
January 24, 2024 14:40
-
-
Save pvalena/c0ad8f42411016bd3b8af00a5d53b3db to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- rubygem-mixlib-shellout/.generated.spec 2024-01-24 15:33:53.157807238 +0100 | |
+++ rubygem-mixlib-shellout/rubygem-mixlib-shellout.spec 2024-01-11 05:10:12.619970842 +0100 | |
@@ -1,22 +1,28 @@ | |
-Downloaded mixlib-shellout-3.2.7 | |
-# Generated from mixlib-shellout-3.2.7.gem by gem2rpm -*- rpm-spec -*- | |
+# Generated from mixlib-shellout-1.0.0.gem by gem2rpm -*- rpm-spec -*- | |
%global gem_name mixlib-shellout | |
+Summary: Run external commands on Unix or Windows | |
Name: rubygem-%{gem_name} | |
Version: 3.2.7 | |
Release: 1%{?dist} | |
-Summary: Run external commands on Unix or Windows | |
-License: Apache-2.0 | |
+License: ASL 2.0 | |
URL: https://github.com/chef/mixlib-shellout | |
Source0: https://rubygems.org/gems/%{gem_name}-%{version}.gem | |
+# Tests for this package are not in the gem. To update: | |
+# git clone --no-checkout https://github.com/chef/mixlib-shellout.git | |
+# git -C mixlib-shellout archive -v -o rubygem-mixlib-shellout-3.2.7-specs.txz v3.2.7 spec/ | |
+Source1: rubygem-%{gem_name}-%{version}-specs.txz | |
+ | |
BuildRequires: ruby(release) | |
+BuildRequires: ruby(rubygems) | |
+BuildRequires: rubygem(rspec) | |
+BuildRequires: rubygem(chef-utils) | |
BuildRequires: rubygems-devel | |
-BuildRequires: ruby >= 2.5 | |
+BuildRequires: procps | |
BuildArch: noarch | |
%description | |
-Run external commands on Unix or Windows. | |
- | |
+Run external commands on Unix or Windows | |
%package doc | |
Summary: Documentation for %{name} | |
@@ -24,18 +30,14 @@ | |
BuildArch: noarch | |
%description doc | |
-Documentation for %{name}. | |
+Documentation for %{name} | |
%prep | |
-%setup -q -n %{gem_name}-%{version} | |
+%setup -q -c -T | |
-%build | |
-# Create the gem as gem install only works on a gem file | |
-gem build ../%{gem_name}-%{version}.gemspec | |
+%gem_install -n %{SOURCE0} | |
-# %%gem_install compiles any C extensions and installs the gem into ./%%gem_dir | |
-# by default, so that we can move it into the buildroot in %%install | |
-%gem_install | |
+%build | |
%install | |
mkdir -p %{buildroot}%{gem_dir} | |
@@ -42,16 +44,17 @@ | |
cp -a .%{gem_dir}/* \ | |
%{buildroot}%{gem_dir}/ | |
- | |
- | |
%check | |
pushd .%{gem_instdir} | |
-# Run the test suite. | |
+tar xavf %{SOURCE1} | |
+# One of the tests involves a fork && sleep 10 that may not finish before mock | |
+rspec | |
+sleep 2 | |
popd | |
%files | |
+%doc %{gem_instdir}/LICENSE | |
%dir %{gem_instdir} | |
-%license %{gem_instdir}/LICENSE | |
%{gem_libdir} | |
%exclude %{gem_cache} | |
%{gem_spec} | |
@@ -61,5 +64,104 @@ | |
%changelog |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment