Skip to content

What is the process of building native extension? #5627

Closed Answered by deivid-rodriguez
hurricup asked this question in Q&A
Discussion options

You must be logged in to vote

Probably does not fully answer your question but gives some hint to investigate. I think there's some backwards compatibility stuff that makes the built extension live in several places:

# TODO remove in RubyGems 3
if Gem.install_extension_in_lib and lib_dir
FileUtils.mkdir_p lib_dir
entries = Dir.entries(full_tmp_dest) - %w[. ..]
entries = entries.map {|entry| File.join full_tmp_dest, entry }
FileUtils.cp_r entries, lib_dir, :remove_destination => true
end

(By the way that TODO should be moved to "RubyGems 4", because it was obviously not removed in RubyGems 3 😅.

Replies: 2 comments 3 replies

Comment options

You must be logged in to vote
3 replies
@hurricup
Comment options

@hurricup
Comment options

@hurricup
Comment options

Answer selected by hurricup
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
3 participants