diff --git a/rakelib/cross-ruby.rake b/rakelib/cross-ruby.rake index b841cf7d2f..29669eb2ce 100644 --- a/rakelib/cross-ruby.rake +++ b/rakelib/cross-ruby.rake @@ -298,7 +298,7 @@ if java? jruby_home = RbConfig::CONFIG['prefix'] jars = ["#{jruby_home}/lib/jruby.jar"] + FileList['lib/*.jar'] - ext.gem_spec.files.reject! { |f| f =~ %r{^ext/nokogiri/} } + ext.gem_spec.files.reject! { |path| File.fnmatch?("ext/nokogiri/**", path) } ext.ext_dir = 'ext/java' ext.lib_dir = 'lib/nokogiri' @@ -349,7 +349,9 @@ else Nokogiri is built with the packaged libraries: #{libs}. EOS - spec.files.reject! { |path| File.fnmatch?('ports/*', path) } + spec.extra_rdoc_files.reject! { |path| File.fnmatch?("ext/nokogiri/**", path) } + spec.files.reject! { |path| File.fnmatch?("ext/nokogiri/**", path) } + spec.files.reject! { |path| File.fnmatch?("ports/*", path) } spec.dependencies.reject! { |dep| dep.name=='mini_portile2' } # when pre-compiling a native gem, package all the C headers in lib/nokogiri/include: diff --git a/scripts/test-gem-file-contents b/scripts/test-gem-file-contents index e95c1c7a8a..eb18e9dca2 100755 --- a/scripts/test-gem-file-contents +++ b/scripts/test-gem-file-contents @@ -152,7 +152,7 @@ describe File.basename(gemfile) do end it "does not contain ext/nokogiri" do - skip "until we fix https://github.com/sparklemotion/nokogiri/issues/2077" + # https://github.com/sparklemotion/nokogiri/issues/2077 assert_empty(gemfile_contents.grep(%r{^ext/nokogiri/})) end