1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
|
Source: Richard Brown
Upstream: no
Reason: respect --prefix properly, stop stamping on live filesystem.
--- setup.rb.orig 2008-03-27 23:09:24.000000000 +0000
+++ setup.rb 2008-03-29 09:12:32.000000000 +0000
@@ -81,8 +81,8 @@
raise "invalid --prefix #{prefix.inspect}" if prefix.nil?
- lib_dir = File.join prefix, 'lib'
- bin_dir = File.join prefix, 'bin'
+ lib_dir = File.join prefix, Config::CONFIG['sitelibdir']
+ bin_dir = File.join prefix, Config::CONFIG['bindir']
mkdir_p lib_dir
mkdir_p bin_dir
@@ -187,30 +187,15 @@
end
end
-# Remove source caches
-
-require 'rubygems/source_info_cache'
-
-user_cache_file = Gem::SourceInfoCache.user_cache_file
-system_cache_file = Gem::SourceInfoCache.system_cache_file
-
-rm_f user_cache_file if File.writable? File.dirname(user_cache_file)
-rm_f system_cache_file if File.writable? File.dirname(system_cache_file)
-
# install RDoc
gem_doc_dir = File.join Gem.dir, 'doc'
if File.writable? gem_doc_dir then
- puts "Removing old RubyGems RDoc and ri"
- Dir[File.join(Gem.dir, 'doc', 'rubygems-[0-9]*')].each do |dir|
- rm_rf dir
- end
-
def run_rdoc(*args)
args << '--quiet'
args << '--main' << 'README'
- args << '.' << 'README' << 'LICENSE.txt' << 'GPL.txt'
+ args << '.' << 'README'
r = RDoc::RDoc.new
r.document args
@@ -237,6 +222,7 @@
end
# Remove stubs
+if false # Don't want this
def stub?(path)
return unless File.readable? path
@@ -305,3 +291,4 @@
puts "to remove it by hand."
puts
+end
|