Created
December 8, 2009 14:12
-
-
Save luislavena/251663 to your computer and use it in GitHub Desktop.
Workaround issue with Jeweler and rake-compiler
This file contains 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
# Hack to avoid "allocator undefined for Proc" issue when unpacking Gems: | |
# gemspec provided by Jeweler uses Rake::FileList for files, test_files and | |
# extra_rdoc_files, and procs cannot be marshalled. | |
# Jeweler Issue GH-73 | |
# Workaround by Alex Coles (myabc) | |
def gemspec | |
@clean_gemspec ||= eval("#{Rake.application.jeweler.gemspec.to_ruby}") # $SAFE = 3\n | |
end | |
# Define your extension normally, using the +gemspec+ defined above | |
Rake::ExtensionTask.new('my_extension', gemspec) do |ext| | |
# ... | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment