diff -ur rubyscript2exe-0.1.20.tar.gz/rubyscript2exe/eee.pas rubyscript2exe-0.1.21.tar.gz/rubyscript2exe/eee.pas
--- rubyscript2exe-0.1.20.tar.gz/rubyscript2exe/eee.pas 2004-07-26 16:46:37.000000000 +0200
+++ rubyscript2exe-0.1.21.tar.gz/rubyscript2exe/eee.pas 2004-08-04 23:02:04.000000000 +0200
@@ -357,7 +357,7 @@
end;
-procedure pakuit_f(var infile: file; var outfile: file; tekst: string[255]; var h: header);
+procedure pakuit_f(var infile: file; var outfile: file; tekst: string; var h: header);
begin
@@ -371,7 +371,7 @@
end;
-procedure pakuit_d(var infile: file; var outfile: file; tekst: string[255]; var h: header);
+procedure pakuit_d(var infile: file; var outfile: file; tekst: string; var h: header);
begin
@@ -384,7 +384,7 @@
end;
-procedure pakuit_c(var infile: file; var outfile: file; tekst: string[255]; var h: header);
+procedure pakuit_c(var infile: file; var outfile: file; tekst: string; var h: header);
var
c : string;
@@ -417,7 +417,7 @@
end;
-procedure pakuit_t(var infile: file; var outfile: file; tekst: string[255]; var h: header);
+procedure pakuit_t(var infile: file; var outfile: file; tekst: string; var h: header);
var
c : string;
diff -ur rubyscript2exe-0.1.20.tar.gz/rubyscript2exe/ev/dependencies.rb rubyscript2exe-0.1.21.tar.gz/rubyscript2exe/ev/dependencies.rb
--- rubyscript2exe-0.1.20.tar.gz/rubyscript2exe/ev/dependencies.rb 2004-07-30 17:39:46.000000000 +0200
+++ rubyscript2exe-0.1.21.tar.gz/rubyscript2exe/ev/dependencies.rb 2004-08-05 00:02:39.000000000 +0200
@@ -1,4 +1,4 @@
-def dlls(file, notthedefaults=true)
+def dlls(file, path=File.dirname(file))
# Only the dependencies in the same directory as the executable.
@@ -17,7 +17,7 @@
strings.delete_if{|s| s !~ /\.dll$/i}
strings.each do |lib|
- lib = File.expand_path(lib, File.dirname(file))
+ lib = File.expand_path(lib, path)
if not lib.nil? and File.file?(lib) and not res.include?(lib)
todo << lib
diff -ur rubyscript2exe-0.1.20.tar.gz/rubyscript2exe/ev/ftools.rb rubyscript2exe-0.1.21.tar.gz/rubyscript2exe/ev/ftools.rb
--- rubyscript2exe-0.1.20.tar.gz/rubyscript2exe/ev/ftools.rb 2004-08-05 00:02:45.000000000 +0200
+++ rubyscript2exe-0.1.21.tar.gz/rubyscript2exe/ev/ftools.rb 2004-08-05 00:02:39.000000000 +0200
@@ -0,0 +1,161 @@
+require "ftools"
+
+class Dir
+ def self.mkdirrec(dir)
+ pdir = File.dirname(dir)
+
+ if not pdir.empty? and not File.directory?(pdir)
+ Dir.mkdirrec(pdir)
+ end
+
+ Dir.mkdir(dir) rescue nil
+ end
+
+ def self.copy(from, to)
+ if File.directory?(from)
+ pdir = Dir.pwd
+ todir = File.expand_path(to)
+
+ mkdirrec(todir)
+
+ Dir.chdir(from)
+ Dir.new(".").each do |e|
+ Dir.copy(e, todir+"/"+e) if not [".", ".."].include?(e)
+ end
+ Dir.chdir(pdir)
+ else
+ todir = File.dirname(File.expand_path(to))
+
+ mkdirrec(todir)
+
+ File.copy(from, to)
+ end
+ end
+
+ def self.move(from, to)
+ Dir.copy(from, to)
+ Dir.rm_rf(from)
+ end
+
+ def self.rm_rf(entry)
+ if File.ftype(entry) == "directory"
+ pdir = Dir.pwd
+
+ Dir.chdir(entry)
+ Dir.new(".").each do |e|
+ Dir.rm_rf(e) if not [".", ".."].include?(e)
+ end
+ Dir.chdir(pdir)
+
+ Dir.delete(entry)
+ else
+ File.delete(entry)
+ end
+ end
+
+ def self.find(entry=nil, mask=nil)
+ entry = @dir if entry.nil?
+
+ entry.gsub!(/[\/\\]*$/, "") unless entry.nil?
+
+ res = []
+
+ if File.directory?(entry)
+ pdir = Dir.pwd
+
+ res += ["%s/" % entry] if mask.nil? or entry =~ mask
+
+ Dir.chdir(entry)
+ Dir.new(".").each do |e|
+ res += Dir.find(e, mask).collect{|e| entry+"/"+e} unless [".", ".."].include?(e)
+ end
+ Dir.chdir(pdir)
+ else
+ res += [entry] if mask.nil? or entry =~ mask
+ end
+
+ res
+ end
+end
+
+class File
+ def self.rollbackup(file, mode=nil)
+ backupfile = file + ".RB.BACKUP"
+ controlfile = file + ".RB.CONTROL"
+
+ File.touch(file) unless File.file?(file)
+
+ # Rollback
+
+ if File.file?(backupfile) and File.file?(controlfile)
+ $stdout.puts "Restoring #{file}..."
+
+ File.copy(backupfile, file) # Rollback from phase 3
+ end
+
+ # Reset
+
+ File.delete(backupfile) if File.file?(backupfile) # Reset from phase 2 or 3
+ File.delete(controlfile) if File.file?(controlfile) # Reset from phase 3 or 4
+
+ # Backup
+
+ File.copy(file, backupfile) # Enter phase 2
+ File.touch(controlfile) # Enter phase 3
+
+ # The real thing
+
+ if block_given?
+ if mode.nil?
+ yield
+ else
+ File.open(file, mode) do |f|
+ yield(f)
+ end
+ end
+ end
+
+ # Cleanup
+
+ File.delete(backupfile) # Enter phase 4
+ File.delete(controlfile) # Enter phase 5
+
+ # Return, like File.open
+
+ if block_given?
+ return nil
+ else
+ return File.open(file, (mode or "r"))
+ end
+ end
+
+ def self.touch(file)
+ File.open(file, "a"){|f|}
+ end
+
+ def self.which(file)
+ res = nil
+
+ if windows?
+ file = file.gsub(/\.exe$/i, "") + ".exe"
+ sep = ";"
+ else
+ sep = ":"
+ end
+
+ catch :stop do
+ ENV["PATH"].split(/#{sep}/).reverse.each do |d|
+ if File.directory?(d)
+ Dir.new(d).each do |e|
+ if e.downcase == file.downcase
+ res = File.expand_path(e, d)
+ throw :stop
+ end
+ end
+ end
+ end
+ end
+
+ res
+ end
+end
diff -ur rubyscript2exe-0.1.20.tar.gz/rubyscript2exe/ev/oldandnewlocation.rb rubyscript2exe-0.1.21.tar.gz/rubyscript2exe/ev/oldandnewlocation.rb
--- rubyscript2exe-0.1.20.tar.gz/rubyscript2exe/ev/oldandnewlocation.rb 2004-07-30 17:39:46.000000000 +0200
+++ rubyscript2exe-0.1.21.tar.gz/rubyscript2exe/ev/oldandnewlocation.rb 2004-08-05 00:02:39.000000000 +0200
@@ -1,5 +1,5 @@
-ENV["OLDDIR"] = Dir.pwd if not ENV.include?("OLDDIR")
-ENV["NEWDIR"] = Dir.pwd if not ENV.include?("NEWDIR")
+ENV["OLDDIR"] = Dir.pwd unless ENV.include?("OLDDIR")
+ENV["NEWDIR"] = File.dirname($0) unless ENV.include?("NEWDIR")
begin
oldlocation
@@ -15,7 +15,7 @@
res = yield
Dir.chdir(pdir)
else
- res = File.expand_path(file, dir) if not file.nil?
+ res = File.expand_path(file, dir) unless file.nil?
end
res
@@ -36,7 +36,7 @@
res = yield
Dir.chdir(pdir)
else
- res = File.expand_path(file, dir) if not file.nil?
+ res = File.expand_path(file, dir) unless file.nil?
end
res
diff -ur rubyscript2exe-0.1.20.tar.gz/rubyscript2exe/init.rb rubyscript2exe-0.1.21.tar.gz/rubyscript2exe/init.rb
--- rubyscript2exe-0.1.20.tar.gz/rubyscript2exe/init.rb 2004-07-29 16:31:46.000000000 +0200
+++ rubyscript2exe-0.1.21.tar.gz/rubyscript2exe/init.rb 2004-08-05 00:02:02.000000000 +0200
@@ -1,6 +1,6 @@
require "ev/oldandnewlocation"
require "ev/dependencies"
-require "ftools"
+require "ev/ftools"
require "rbconfig"
def backslashes(s)
@@ -51,7 +51,14 @@
dlls("#{bindir}/ruby.exe").each do |dll|
file = File.basename(dll)
- File.copy(dll, "bin/#{file}") unless file == "ruby.exe"
+ File.copy(dll, "bin/#{file}")
+ end
+
+ Dir.find(libdir, /\.so$/).each do |file|
+ dlls(file, bindir).each do |dll|
+ file = File.basename(dll)
+ File.copy(dll, "bin/#{file}")
+ end
end
$stderr.puts "Creating #{app}.exe..."
@@ -75,7 +82,10 @@
system(backslashes("./eee app.eee #{appexe} #{eeeexe}"))
oldlocation do
- File.copy(newlocation(appexe), appexe)
+ from = newlocation(appexe)
+ to = oldlocation(appexe)
+
+ File.copy(from, to) unless from == to
system(backslashes("reshacker -modify #{newlocation(appexe)}, #{appexe}, #{appico}, icon,appicon,")) if File.file?(appico)
end
diff -ur rubyscript2exe-0.1.20.tar.gz/rubyscript2exe/require2lib.rb rubyscript2exe-0.1.21.tar.gz/rubyscript2exe/require2lib.rb
--- rubyscript2exe-0.1.20.tar.gz/rubyscript2exe/require2lib.rb 2004-07-30 17:39:46.000000000 +0200
+++ rubyscript2exe-0.1.21.tar.gz/rubyscript2exe/require2lib.rb 2004-08-05 00:02:39.000000000 +0200
@@ -32,7 +32,7 @@
fromfile = File.expand_path(req, lib)
tofile = File.expand_path(req, LIBDIR)
- if FileTest.file?(fromfile)
+ if File.file?(fromfile)
unless fromfile == tofile or fromfile == THISFILE
if JUSTSITE and fromfile.include?(SITEDIR)
$stderr.puts "Skipped #{fromfile} ."
Binary files rubyscript2exe-0.1.20.tar.gz/rubyscript2exe/eee.exe and rubyscript2exe-0.1.21.tar.gz/rubyscript2exe/eee.exe differ
Binary files rubyscript2exe-0.1.20.tar.gz/rubyscript2exe/eeew.exe and rubyscript2exe-0.1.21.tar.gz/rubyscript2exe/eeew.exe differ