Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Newer
Older
100644 51 lines (40 sloc) 1.093 kB
f8b6669 @tenderlove initial checkin
authored
1 # -*- ruby -*-
2
3 require 'rubygems'
4 require 'hoe'
5
6 kind = Config::CONFIG['DLEXT']
7 windows = RUBY_PLATFORM =~ /mswin/i ? true : false
8
581c773 @tenderlove renaming, adding decoder
authored
9 EXT = "ext/qrtools/qrtools.#{kind}"
f8b6669 @tenderlove initial checkin
authored
10
d0dc386 @tenderlove adding gemspec, version and binary file
authored
11 require './lib/qrtools/version'
12
13 HOE = Hoe.new('qrtools', QRTools::VERSION) do |p|
f8b6669 @tenderlove initial checkin
authored
14 p.developer('Aaron Patterson', 'aaronp@rubyforge.org')
15 p.clean_globs = [
581c773 @tenderlove renaming, adding decoder
authored
16 'ext/qrtools/Makefile',
17 'ext/qrtools/*.{o,so,bundle,a,log,dll}',
18 'ext/qrtools/conftest.dSYM',
f8b6669 @tenderlove initial checkin
authored
19 ]
4cd5972 @tenderlove forgot a gem dependency
authored
20 p.extra_deps = [['png', '>= 1.1.0']]
581c773 @tenderlove renaming, adding decoder
authored
21 p.spec_extras = { :extensions => ["ext/qrtools/extconf.rb"] }
f8b6669 @tenderlove initial checkin
authored
22 end
23
581c773 @tenderlove renaming, adding decoder
authored
24 task 'ext/qrtools/Makefile' do
25 Dir.chdir('ext/qrtools') do
f8b6669 @tenderlove initial checkin
authored
26 ruby "extconf.rb #{ENV['EXTOPTS']}"
27 end
28 end
29
581c773 @tenderlove renaming, adding decoder
authored
30 task EXT => 'ext/qrtools/Makefile' do
31 Dir.chdir('ext/qrtools') do
f8b6669 @tenderlove initial checkin
authored
32 sh 'make'
33 end
34 end
35 task :build => [EXT]
36
37 Rake::Task['test'].prerequisites << :build
38
d0dc386 @tenderlove adding gemspec, version and binary file
authored
39 namespace :gem do
40 namespace :dev do
41 task :spec do
42 File.open("#{HOE.name}.gemspec", 'w') do |f|
43 HOE.spec.version = "#{HOE.version}.#{Time.now.strftime("%Y%m%d%H%M%S")}"
44 f.write(HOE.spec.to_ruby)
45 end
46 end
47 end
48 end
49
f8b6669 @tenderlove initial checkin
authored
50 # vim: syntax=Ruby
Something went wrong with that request. Please try again.