From 28e938cf837c6859197000cc647f84f92668f0b6 Mon Sep 17 00:00:00 2001 From: Luis Lavena Date: Sun, 2 Nov 2008 17:04:09 -0300 Subject: [PATCH] Skeleton import after cleanup. --- LICENSE | 20 ++++++++++++++++++++ README | 0 Rakefile | 23 +++++++++++++++++++++++ tasks/rubygems.rake | 45 +++++++++++++++++++++++++++++++++++++++++++++ 4 files changed, 88 insertions(+) create mode 100644 LICENSE create mode 100644 README create mode 100644 Rakefile create mode 100644 tasks/rubygems.rake diff --git a/LICENSE b/LICENSE new file mode 100644 index 0000000..9d8e774 --- /dev/null +++ b/LICENSE @@ -0,0 +1,20 @@ +Copyright (c) 2008 Luis Lavena. + +Permission is hereby granted, free of charge, to any person obtaining +a copy of this software and associated documentation files (the +"Software"), to deal in the Software without restriction, including +without limitation the rights to use, copy, modify, merge, publish, +distribute, sublicense, and/or sell copies of the Software, and to +permit persons to whom the Software is furnished to do so, subject to +the following conditions: + +The above copyright notice and this permission notice shall be +included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND +NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE +LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION +OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION +WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. diff --git a/README b/README new file mode 100644 index 0000000..e69de29 diff --git a/Rakefile b/Rakefile new file mode 100644 index 0000000..fd8e1e9 --- /dev/null +++ b/Rakefile @@ -0,0 +1,23 @@ +#-- +# Copyright (c) 2008 Luis Lavena +# +# This source code is released under the MIT License. +# See LICENSE file for details +#++ + +# +# NOTE: Keep this file clean. +# Add your customizations inside tasks directory. +# Thank You. +# + +begin + require 'rake' +rescue LoadError + require 'rubygems' + gem 'rake', '>= 0.8.3', '~> 0.8.4' + require 'rake' +end + +# load rakefile extensions (tasks) +Dir['tasks/*.rake'].each { |f| import f } diff --git a/tasks/rubygems.rake b/tasks/rubygems.rake new file mode 100644 index 0000000..fb1a2ea --- /dev/null +++ b/tasks/rubygems.rake @@ -0,0 +1,45 @@ +require 'rake/gempackagetask' + +spec = Gem::Specification.new do |s| + # basic information + s.name = "rake-compiler" + s.version = "0.1.0" + s.platform = Gem::Platform::RUBY + + # description and details + s.summary = 'Rake-based Ruby C Extension task generator.' + s.description = <<-EOF + Provide a spandard and simplified way to build and package + Ruby C extensions using Rake as glue. + EOF + + # dependencies + s.add_dependency 'rake', '>= 0.8.3', '~> 0.8.4' + + # components, files and paths + #s.files + s.require_path = 'lib' + + # documentation + s.has_rdoc = false + + # project information + s.homepage = 'TODO' + s.rubyforge_project = 'TODO' + + # author and contributors + s.author = 'Luis Lavena' + s.email = 'luislavena@gmail.com' +end + +gem_package = Rake::GemPackageTask.new(spec) do |pkg| + pkg.need_tar = false + pkg.need_zip = false +end + +file 'rake-compiler.gemspec' => ['Rakefile', 'tasks/rubygems.rake'] do |t| + File.open(t.name, 'w') { |f| f.puts spec.to_yaml } +end + +desc "Generate or update the standalone gemspec file for the project" +task :gemspec => ['rake-compiler.gemspec']