kindlegen 2.4.1 → 2.5.0

Sign up to get free protection for your applications and to get access to all the features.
@@ -7,22 +7,23 @@ File::open('Makefile', 'w') do |w|
7
7
  tarball = case RbConfig::CONFIG['host_os']
8
8
  when /mac|darwin/i
9
9
  unzip = 'unzip'
10
- "KindleGen_Mac_i386_v2_4.zip"
10
+ "KindleGen_Mac_i386_v2_5.zip"
11
11
  when /linux|cygwin/i
12
12
  unzip = 'tar zxf'
13
- "kindlegen_linux_2.6_i386_v2_4.tar.gz"
13
+ "kindlegen_linux_2.6_i386_v2_5.tar.gz"
14
14
  else
15
15
  STDERR.puts "Host OS unsupported!"
16
16
  exit(1)
17
17
  end
18
18
 
19
- config = {
19
+ config = RbConfig::CONFIG.merge( {
20
20
  "unzip" => unzip,
21
21
  "tarball" => tarball
22
- }
22
+ } )
23
23
 
24
- if Dir::pwd.include? 'gems'
25
- w.puts RbConfig.expand(DATA.read, config.merge('bindir' => '../../../../bin') )
24
+ bindir = '../../../../bin'
25
+ if Dir::pwd.include?( 'gems' ) && FileTest.directory?( bindir )
26
+ w.puts RbConfig.expand(DATA.read, config.merge('bindir' => bindir) )
26
27
  else
27
28
  w.puts RbConfig.expand(DATA.read, config)
28
29
  end
@@ -36,13 +37,14 @@ BINDIR = $(bindir)
36
37
  TARBALL = $(tarball)
37
38
  CURL = curl
38
39
  UNZIP = $(unzip)
39
- CP = cp
40
+ CP = cp -a
40
41
 
41
42
  all:
42
43
 
43
44
  $(TARGET): $(TARBALL)
44
45
  $(UNZIP) $(TARBALL)
45
46
  touch $(TARGET)
47
+ chmod +x $(TARGET)
46
48
 
47
49
  $(TARBALL):
48
50
  $(CURL) $(AMAZON)/$(TARBALL) -o $(TARBALL)
@@ -1,3 +1,3 @@
1
1
  module Kindlegen
2
- VERSION = "2.4.1"
2
+ VERSION = "2.5.0"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: kindlegen
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.4.1
4
+ version: 2.5.0
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2012-07-01 00:00:00.000000000 Z
12
+ date: 2012-07-19 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: systemu