# Generated from bootsnap-1.3.0.gem by gem2rpm -*- rpm-spec -*- %global gem_name bootsnap # Not sure how to fix error: # Empty %files file /builddir/build/BUILD/bootsnap-1.10.3/debugsourcefiles.list %global debug_package %{nil} Name: rubygem-%{gem_name} Version: 1.10.3 Release: 1%{?dist} Summary: Boot large ruby/rails apps faster License: MIT URL: https://github.com/Shopify/bootsnap Source0: https://rubygems.org/gems/%{gem_name}-%{version}.gem # The bootsnap gem doesn't ship with the test suite. # You may check it out like so: # git clone http://github.com/Shopify/bootsnap.git --no-checkout # cd bootsnap && git archive -v -o bootsnap-1.10.3-tests.txz v1.10.3 test/ Source1: %{gem_name}-%{version}-tests.txz BuildRequires: ruby(release) BuildRequires: rubygems-devel BuildRequires: ruby-devel >= 2.0.0 BuildRequires: rubygem(minitest) BuildRequires: rubygem(mocha) # Bundler is needed just for one test, that is failing atm. BuildRequires: rubygem(bundler) BuildRequires: rubygem(msgpack) # Compiler is required for build of gem binary extension. # https://fedoraproject.org/wiki/Packaging:C_and_C++#BuildRequires_and_Requires BuildRequires: gcc %description Bootsnap is a library that plugs into Ruby, with optional support for ActiveSupport and YAML, to optimize and cache expensive computations. %package doc Summary: Documentation for %{name} Requires: %{name} = %{version}-%{release} BuildArch: noarch %description doc Documentation for %{name}. %prep %setup -q -n %{gem_name}-%{version} -a 1 sed -i -e "/^\s*\$CFLAGS / s/^/#/g" \ ext/bootsnap/extconf.rb %build gem build ../%{gem_name}-%{version}.gemspec %gem_install chmod 0644 .%{gem_extdir_mri}/%{gem_name}/*.so %install mkdir -p %{buildroot}%{gem_dir} cp -a .%{gem_dir}/* \ %{buildroot}%{gem_dir}/ mkdir -p %{buildroot}%{gem_extdir_mri}/%{gem_name} cp -a .%{gem_extdir_mri}/gem.build_complete %{buildroot}%{gem_extdir_mri}/ cp -a .%{gem_extdir_mri}/%{gem_name}/*.so %{buildroot}%{gem_extdir_mri}/%{gem_name} # Prevent dangling symlink in -debuginfo (rhbz#878863). rm -rf %{buildroot}%{gem_instdir}/ext/ %check # copy the previously unpacked test files cp -a test/ .%{gem_instdir} pushd .%{gem_instdir} # Test failures # https://github.com/Shopify/bootsnap/issues/395 # NoMethodError: undefined method `bundle_path' for Bundler:Module sed -i -e '/^\s*def test_precompile_gemfile\s*$/ a \ skip' test/cli_test.rb sed -i -e '/^\s*def test_load_file_freeze\s*$/ a \ skip' test/compile_cache/json_test.rb sed -i -e '/^\s*def test_path_encoding\s*$/ a \ skip' test/load_path_cache/cache_test.rb # '/usr/share/ruby/time.rb' is expected to be in stable prefix, # but that is failing for some reason. Same issue with bundler. # https://github.com/Shopify/bootsnap/issues/173 sed -i -e "/^\s*assert(stable.stable?,/ s/^/#/g" \ -e "/^\s*refute(stable.volatile?,/ s/^/#/g" \ -e "/^\s*assert(bundler.stable?,/ s/^/#/g" \ -e "/^\s*Bundler/ s/^/#/g" \ test/load_path_cache/path_test.rb ruby -rpathname -rmsgpack -rset -Ilib:test:ext -e 'Dir.glob "./test/**/*_test.rb", &method(:require)' popd %files %dir %{gem_instdir} %{gem_extdir_mri} %exclude %{gem_instdir}/.* %license %{gem_instdir}/LICENSE.txt %{gem_instdir}/exe/ %{gem_libdir} %exclude %{gem_cache} %{gem_spec} %files doc %doc %{gem_docdir} %doc %{gem_instdir}/CHANGELOG.md %doc %{gem_instdir}/README.md %changelog * Sun Feb 06 2022 Pavel Valena - 1.10.3-1 - Update to bootsnap 1.10.3. Resolves: rhbz#1868112 * Wed Jan 26 2022 Pavel Valena - 1.4.7-6 - Rebuilt for https://fedoraproject.org/wiki/Changes/Ruby_3.1 * Fri Jan 21 2022 Fedora Release Engineering - 1.4.7-5 - Rebuilt for https://fedoraproject.org/wiki/Fedora_36_Mass_Rebuild * Fri Jul 23 2021 Fedora Release Engineering - 1.4.7-4 - Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild * Wed Jan 27 2021 Fedora Release Engineering - 1.4.7-3 - Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild * Wed Jan 6 2021 Vít Ondruch - 1.4.7-2 - Rebuilt for https://fedoraproject.org/wiki/Changes/Ruby_3.0 * Fri Jul 31 09:47:28 GMT 2020 Pavel Valena - 1.4.7-1 - Update to bootsnap 1.4.7. Resolves: rhbz#1862090 * Fri Jul 31 09:19:53 GMT 2020 Vít Ondruch - 1.3.2-7 - Re-enable ARM support. The problem should be gone since Ruby 2.6+. * Wed Jul 29 2020 Fedora Release Engineering - 1.3.2-6 - Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild * Thu Jan 30 2020 Fedora Release Engineering - 1.3.2-5 - Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild * Mon Jan 20 2020 Mamoru TASAKA - 1.3.2-4 - Apply upstream patch to support ruby 2.7 - Unpack test tarball beforehand, as the above patch needs applying - Rebuild against ruby27 * Fri Jul 26 2019 Fedora Release Engineering - 1.3.2-3 - Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild * Sat Feb 02 2019 Fedora Release Engineering - 1.3.2-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild * Fri Jan 18 2019 Pavel Valena - 1.3.2-1 - Update to Bootsnap 1.3.2. - Rebuilt for https://fedoraproject.org/wiki/Changes/Ruby_2.6 * Sat Jul 14 2018 Fedora Release Engineering - 1.3.0-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild * Wed May 30 2018 Pavel Valena - 1.3.0-1 - Initial package