]> gitweb.factorcode.org Git - factor.git/commitdiff
Fix Windows bootstrap
authorU-SLAVA-DFB8FF805\Slava <Slava@slava-dfb8ff805.(none)>
Sat, 13 Dec 2008 10:41:33 +0000 (04:41 -0600)
committerU-SLAVA-DFB8FF805\Slava <Slava@slava-dfb8ff805.(none)>
Sat, 13 Dec 2008 10:41:33 +0000 (04:41 -0600)
13 files changed:
basis/io/backend/windows/nt/nt.factor [changed mode: 0644->0755]
basis/io/directories/directories.factor [changed mode: 0644->0755]
basis/io/directories/windows/windows.factor [changed mode: 0644->0755]
basis/io/files/info/windows/nt/nt.factor [changed mode: 0644->0755]
basis/io/files/info/windows/windows.factor [changed mode: 0644->0755]
basis/io/files/windows/nt/nt.factor
basis/io/files/windows/windows.factor
basis/io/launcher/launcher.factor [changed mode: 0644->0755]
basis/io/launcher/windows/nt/nt.factor [changed mode: 0644->0755]
basis/io/launcher/windows/windows.factor [changed mode: 0644->0755]
basis/io/monitors/windows/nt/nt.factor
basis/tools/deploy/windows/windows.factor
basis/tools/disassembler/gdb/gdb.factor [changed mode: 0644->0755]

old mode 100644 (file)
new mode 100755 (executable)
index d6c74ed..e41293b
@@ -1,9 +1,9 @@
 USING: alien alien.c-types arrays assocs combinators
 continuations destructors io io.backend io.ports io.timeouts
-io.backend.windows io.files.windows io.files io.buffers io.streams.c
-libc kernel math namespaces sequences threads windows
-windows.errors windows.kernel32 strings splitting qualified
-ascii system accessors locals ;
+io.backend.windows io.files.windows io.files.windows.nt io.files
+io.pathnames io.buffers io.streams.c libc kernel math namespaces
+sequences threads windows windows.errors windows.kernel32
+strings splitting qualified ascii system accessors locals ;
 QUALIFIED: windows.winsock
 IN: io.backend.windows.nt
 
old mode 100644 (file)
new mode 100755 (executable)
index 0b8fa13..2630be8
@@ -83,4 +83,5 @@ M: object copy-file
 
 {
     { [ os unix? ] [ "io.directories.unix" require ] }
+    { [ os windows? ] [ "io.directories.windows" require ] }
 } cond
\ No newline at end of file
old mode 100644 (file)
new mode 100755 (executable)
index 6520602..c2955d3
@@ -1,7 +1,19 @@
 ! Copyright (C) 2008 Doug Coleman.
 ! See http://factorcode.org/license.txt for BSD license.
+USING: system io.directories io.encodings.utf16n alien.strings
+io.pathnames io.backend io.files.windows destructors
+kernel accessors calendar windows windows.errors
+windows.kernel32 alien.c-types sequences splitting
+fry continuations ;
 IN: io.directories.windows
 
+M: windows touch-file ( path -- )
+    [
+        normalize-path
+        maybe-create-file [ &dispose ] dip
+        [ drop ] [ handle>> f now dup (set-file-times) ] if
+    ] with-destructors ;
+
 M: windows move-file ( from to -- )
     [ normalize-path ] bi@ MoveFile win32-error=0/f ;
 
old mode 100644 (file)
new mode 100755 (executable)
index e1b8062..19ea086
@@ -2,12 +2,3 @@
 ! See http://factorcode.org/license.txt for BSD license.
 IN: io.files.info.windows.nt
 
-ERROR: not-absolute-path ;
-
-M: winnt root-directory ( string -- string' )
-    unicode-prefix ?head drop
-    dup {
-        [ length 2 >= ]
-        [ second CHAR: : = ]
-        [ first Letter? ]
-    } 1&& [ 2 head "\\" append ] [ not-absolute-path ] if ;
old mode 100644 (file)
new mode 100755 (executable)
index c3068db..aecf42d
@@ -1,5 +1,11 @@
 ! Copyright (C) 2008 Doug Coleman.
 ! See http://factorcode.org/license.txt for BSD license.
+USING: byte-arrays math io.backend io.files.info
+io.files.windows io.files.windows.nt kernel windows.kernel32
+windows.time windows accessors alien.c-types combinators
+generalizations system alien.strings io.encodings.utf16n
+sequences splitting windows.errors fry continuations destructors
+calendar ascii combinators.short-circuit ;
 IN: io.files.info.windows
 
 TUPLE: windows-file-info < file-info attributes ;
@@ -72,10 +78,10 @@ TUPLE: windows-file-info < file-info attributes ;
         get-file-information BY_HANDLE_FILE_INFORMATION>file-info
     ] if ;
 
-M: winnt file-info ( path -- info )
+M: windows file-info ( path -- info )
     normalize-path get-file-information-stat ;
 
-M: winnt link-info ( path -- info )
+M: windows link-info ( path -- info )
     file-info ;
 
 : volume-information ( normalized-path -- volume-name volume-serial max-component flags type )
@@ -103,7 +109,15 @@ M: winnt link-info ( path -- info )
 
 TUPLE: win32-file-system-info < file-system-info max-component flags device-serial ;
 
-HOOK: root-directory os ( string -- string' )
+ERROR: not-absolute-path ;
+
+: root-directory ( string -- string' )
+    unicode-prefix ?head drop
+    dup {
+        [ length 2 >= ]
+        [ second CHAR: : = ]
+        [ first Letter? ]
+    } 1&& [ 2 head "\\" append ] [ not-absolute-path ] if ;
 
 M: winnt file-system-info ( path -- file-system-info )
     normalize-path root-directory
index f3a534388a2764f740f01c70ce18cafde64fb2f8..37c6e3190ae43c982c4e194aac0232fc65ca9a30 100755 (executable)
@@ -1,5 +1,5 @@
 USING: continuations destructors io.buffers io.files io.backend
-io.timeouts io.ports io.files.private io.backend.windows
+io.timeouts io.ports io.pathnames io.files.private io.backend.windows
 io.files.windows io.backend.windows.nt io.encodings.utf16n
 windows windows.kernel32 kernel libc math threads system
 environment alien.c-types alien.arrays alien.strings sequences
@@ -48,7 +48,7 @@ M: winnt FileArgs-overlapped ( port -- overlapped )
     make-overlapped ;
 
 M: winnt open-append
-    [ dup file-info size>> ] [ drop 0 ] recover
+    0 ! [ dup file-info size>> ] [ drop 0 ] recover
     [ (open-append) ] dip >>ptr ;
 
 M: winnt home "USERPROFILE" os-env ;
index 30915f8c71295d2bd30732a6d33acaad4a1cc1e5..1a1ffe0dc7858f592a68c83122397418d666cf85 100755 (executable)
@@ -1,11 +1,12 @@
 ! Copyright (C) 2008 Doug Coleman.
 ! See http://factorcode.org/license.txt for BSD license.
-USING: alien.c-types io.binary io.backend io.files io.buffers
-io.encodings.utf16n io.ports io.backend.windows kernel math splitting
-fry alien.strings windows windows.kernel32 windows.time calendar
-combinators math.functions sequences namespaces make words
-symbols system destructors accessors math.bitwise continuations
-windows.errors arrays byte-arrays generalizations ;
+USING: alien.c-types io.binary io.backend io.files
+io.files.types io.buffers io.encodings.utf16n io.ports
+io.backend.windows kernel math splitting fry alien.strings
+windows windows.kernel32 windows.time calendar combinators
+math.functions sequences namespaces make words symbols system
+destructors accessors math.bitwise continuations windows.errors
+arrays byte-arrays generalizations ;
 IN: io.files.windows
 
 : open-file ( path access-mode create-mode flags -- handle )
@@ -130,10 +131,3 @@ SYMBOLS: +read-only+ +hidden+ +system+
 : (set-file-times) ( handle timestamp/f timestamp/f timestamp/f -- )
     [ timestamp>FILETIME ] tri@
     SetFileTime win32-error=0/f ;
-
-M: winnt touch-file ( path -- )
-    [
-        normalize-path
-        maybe-create-file [ &dispose ] dip
-        [ drop ] [ handle>> f now dup (set-file-times) ] if
-    ] with-destructors ;
old mode 100644 (file)
new mode 100755 (executable)
index ad2f7e4..f580922
@@ -262,7 +262,6 @@ M: object run-pipeline-element
 
 {
     { [ os unix? ] [ "io.launcher.unix" require ] }
-    { [ os winnt? ] [ "io.backend.windows.nt.launcher" require ] }
-    { [ os wince? ] [ "io.launcher.windows" require ] }
+    { [ os winnt? ] [ "io.launcher.windows.nt" require ] }
     [ ]
 } cond
old mode 100644 (file)
new mode 100755 (executable)
index d098456..5ebb38a
@@ -6,7 +6,7 @@ windows.kernel32 windows namespaces make io.launcher kernel
 sequences windows.errors assocs splitting system strings
 io.launcher.windows io.files.windows io.backend io.files
 io.files.private combinators shuffle accessors locals ;
-IN: io.backend.windows.nt.launcher
+IN: io.launcher.windows.nt
 
 : duplicate-handle ( handle -- handle' )
     GetCurrentProcess ! source process
old mode 100644 (file)
new mode 100755 (executable)
index 1e6d1f1..0497754
@@ -1,7 +1,7 @@
 ! Copyright (C) 2007, 2008 Doug Coleman, Slava Pestov.
 ! See http://factorcode.org/license.txt for BSD license.
 USING: alien alien.c-types arrays continuations io
-io.backend.windows io.pipes.windows.nt libc io.ports
+io.backend.windows io.pipes.windows.nt io.pathnames libc io.ports
 windows.types math windows.kernel32
 namespaces make io.launcher kernel sequences windows.errors
 splitting system threads init strings combinators
index 57bd07ef24a1157159eb427f0e09a71e94b22d48..d2408a3dd1810c92b9f9ad7319ff0f3cc35c2bc0 100755 (executable)
@@ -6,7 +6,8 @@ hashtables sorting arrays combinators math.bitwise strings
 system accessors threads splitting io.backend io.backend.windows
 io.backend.windows.nt io.files.windows.nt io.monitors io.ports
 io.buffers io.files io.timeouts io.encodings.string
-io.encodings.utf16n io windows windows.kernel32 windows.types ;
+io.encodings.utf16n io windows windows.kernel32 windows.types
+io.pathnames ;
 IN: io.monitors.windows.nt
 
 : open-directory ( path -- handle )
index 6188e78b0eb37e410c58841fa6d7b6a806044523..7ce635b1ba90623ffac6c0007a036d1f2ab648e4 100755 (executable)
@@ -1,6 +1,6 @@
 ! Copyright (C) 2007, 2008 Slava Pestov.
 ! See http://factorcode.org/license.txt for BSD license.
-USING: io io.files kernel namespaces sequences system
+USING: io io.files io.directories kernel namespaces sequences system
 tools.deploy.backend tools.deploy.config
 tools.deploy.config.editor assocs hashtables prettyprint
 combinators windows.shell32 windows.user32 ;
old mode 100644 (file)
new mode 100755 (executable)
index 65d0e2f..e97cc20
@@ -1,9 +1,9 @@
 ! Copyright (C) 2008 Slava Pestov, Jorge Acereda Macia.
 ! See http://factorcode.org/license.txt for BSD license.
-USING: io.files io words alien kernel math.parser alien.syntax
-io.launcher system assocs arrays sequences namespaces make
-qualified system math io.encodings.ascii accessors
-tools.disassembler ;
+USING: io.files io.files.temp io words alien kernel math.parser
+alien.syntax io.launcher system assocs arrays sequences
+namespaces make qualified system math io.encodings.ascii
+accessors tools.disassembler ;
 IN: tools.disassembler.gdb
 
 SINGLETON: gdb-disassembler