htmldoc_remote_compile_wrapper 0.2 → 0.3

Sign up to get free protection for your applications and to get access to all the features.
data/ext/extconf.rb CHANGED
@@ -4,13 +4,18 @@ require 'open-uri'
4
4
 
5
5
  root = File.expand_path('../..', __FILE__)
6
6
  src_dir = File.join(root, 'src')
7
+ bin_dir = File.join(root, 'bin')
7
8
  tgz_filename = "htmldoc.tgz"
8
9
  tgz_file = File.join(src_dir, tgz_filename)
10
+ patch_file = File.join(src_dir, "libpng_patch")
9
11
 
10
12
  FileUtils.rm_rf src_dir
11
13
  FileUtils.mkdir src_dir
12
14
 
13
15
  source_url = "http://ftp.easysw.com/pub/htmldoc/1.8.27/htmldoc-1.8.27-source.tar.gz"
16
+ # Fixes building with libpng-1.5, from upstream svn r1668 via Fedora
17
+ # Remove at version 1.8.28. cf. https://github.com/mxcl/homebrew/issues/15915
18
+ patch_url = "http://pkgs.fedoraproject.org/cgit/htmldoc.git/plain/htmldoc-1.8.27-libpng15.patch?h=f18"
14
19
 
15
20
  puts "===> Downloading: #{source_url} to #{tgz_file}"
16
21
 
@@ -18,16 +23,23 @@ open(tgz_file, "wb") do |file|
18
23
  file.print open(source_url).read
19
24
  end
20
25
 
26
+ open(patch_file, "wb") do |file|
27
+ file.print open(patch_url).read
28
+ end
29
+
21
30
  Dir.chdir(src_dir) do
22
31
  puts "===> Changing to directory: #{src_dir}"
23
32
  puts "===> Extracting #{tgz_filename}"
24
33
  system "tar xzf #{tgz_filename} --strip-components=1"
34
+ puts "===> Patching"
35
+ system "patch -p0 <libpng_patch"
25
36
  puts "===> Configuring with prefix: #{root}"
26
37
  system "./configure --prefix=#{root}"
27
38
  puts "===> Building..."
28
39
  system "make"
29
40
  puts "===> Installing..."
30
41
  system "make install"
42
+ raise "make install failed!" unless File.exist?(bin_dir)
31
43
  puts "===> Cleaning up..."
32
44
  system "make clean"
33
45
  end
@@ -12,5 +12,5 @@ Gem::Specification.new do |gem|
12
12
  gem.extensions = ['ext/extconf.rb']
13
13
  gem.name = "htmldoc_remote_compile_wrapper"
14
14
  gem.require_paths = ["lib"]
15
- gem.version = "0.2"
15
+ gem.version = "0.3"
16
16
  end
metadata CHANGED
@@ -1,32 +1,24 @@
1
- --- !ruby/object:Gem::Specification
1
+ --- !ruby/object:Gem::Specification
2
2
  name: htmldoc_remote_compile_wrapper
3
- version: !ruby/object:Gem::Version
4
- prerelease: false
5
- segments:
6
- - 0
7
- - 2
8
- version: "0.2"
3
+ version: !ruby/object:Gem::Version
4
+ version: '0.3'
5
+ prerelease:
9
6
  platform: ruby
10
- authors:
7
+ authors:
11
8
  - Joe Noon
12
9
  autorequire:
13
10
  bindir: bin
14
11
  cert_chain: []
15
-
16
- date: 2012-07-01 00:00:00 -07:00
17
- default_executable:
12
+ date: 2012-12-04 00:00:00.000000000 Z
18
13
  dependencies: []
19
-
20
14
  description: Compile htmldoc binary
21
- email:
15
+ email:
22
16
  - joenoon@gmail.com
23
17
  executables: []
24
-
25
- extensions:
18
+ extensions:
26
19
  - ext/extconf.rb
27
20
  extra_rdoc_files: []
28
-
29
- files:
21
+ files:
30
22
  - .gitignore
31
23
  - Gemfile
32
24
  - LICENSE
@@ -35,35 +27,29 @@ files:
35
27
  - ext/extconf.rb
36
28
  - htmldoc_remote_compile_wrapper.gemspec
37
29
  - lib/htmldoc_remote_compile_wrapper.rb
38
- has_rdoc: true
39
- homepage: ""
30
+ homepage: ''
40
31
  licenses: []
41
-
42
32
  post_install_message:
43
33
  rdoc_options: []
44
-
45
- require_paths:
34
+ require_paths:
46
35
  - lib
47
- required_ruby_version: !ruby/object:Gem::Requirement
48
- requirements:
49
- - - ">="
50
- - !ruby/object:Gem::Version
51
- segments:
52
- - 0
53
- version: "0"
54
- required_rubygems_version: !ruby/object:Gem::Requirement
55
- requirements:
56
- - - ">="
57
- - !ruby/object:Gem::Version
58
- segments:
59
- - 0
60
- version: "0"
36
+ required_ruby_version: !ruby/object:Gem::Requirement
37
+ none: false
38
+ requirements:
39
+ - - ! '>='
40
+ - !ruby/object:Gem::Version
41
+ version: '0'
42
+ required_rubygems_version: !ruby/object:Gem::Requirement
43
+ none: false
44
+ requirements:
45
+ - - ! '>='
46
+ - !ruby/object:Gem::Version
47
+ version: '0'
61
48
  requirements: []
62
-
63
49
  rubyforge_project:
64
- rubygems_version: 1.3.6
50
+ rubygems_version: 1.8.23
65
51
  signing_key:
66
52
  specification_version: 3
67
- summary: Suitable for environments like Heroku. Downloads the htmldoc source and compiles using the native extension hook upon gem installation.
53
+ summary: Suitable for environments like Heroku. Downloads the htmldoc source and
54
+ compiles using the native extension hook upon gem installation.
68
55
  test_files: []
69
-