Improve GambitREPL iOS example.
[gambit-c.git] / lib / os_files.h
blobd37f3f8a1564d462b9252c81c8a0d2de4d0fe215
1 /* File: "os_files.h", Time-stamp: <2008-12-09 16:15:30 feeley> */
3 /* Copyright (c) 1994-2008 by Marc Feeley, All Rights Reserved. */
5 #ifndef ___OS_FILES_H
6 #define ___OS_FILES_H
9 /*---------------------------------------------------------------------------*/
11 /**********************************/
12 #include "os.h"
14 typedef struct ___files_module_struct
16 ___BOOL setup;
18 } ___files_module;
21 extern ___files_module ___files_mod;
24 /*---------------------------------------------------------------------------*/
26 /* File system path expansion. */
29 /* Max length of a path, not including null. */
31 #define ___PATH_MAX_LENGTH 1024
34 #ifdef USE_WIN32
35 #ifdef _UNICODE
36 #define ___PATH_CE_SELECT(latin1,utf8,ucs2,ucs4,wchar,native) ucs2
37 #else
38 #define ___PATH_CE_SELECT(latin1,utf8,ucs2,ucs4,wchar,native) native
39 #endif
40 #endif
42 #ifndef ___PATH_CE_SELECT
43 #define ___PATH_CE_SELECT(latin1,utf8,ucs2,ucs4,wchar,native) native
44 #endif
47 extern ___SCMOBJ ___os_path_homedir ___PVOID;
49 extern ___SCMOBJ ___os_path_gambcdir ___PVOID;
51 extern ___SCMOBJ ___os_path_gambcdir_map_lookup
52 ___P((___SCMOBJ dir),
53 ());
55 extern ___SCMOBJ ___os_path_normalize_directory
56 ___P((___SCMOBJ path),
57 ());
60 /*---------------------------------------------------------------------------*/
62 /* File system operations. */
65 extern ___SCMOBJ ___os_create_directory
66 ___P((___SCMOBJ path,
67 ___SCMOBJ mode),
68 ());
70 extern ___SCMOBJ ___os_create_fifo
71 ___P((___SCMOBJ path,
72 ___SCMOBJ mode),
73 ());
75 extern ___SCMOBJ ___os_create_link
76 ___P((___SCMOBJ path1,
77 ___SCMOBJ path2),
78 ());
80 extern ___SCMOBJ ___os_create_symbolic_link
81 ___P((___SCMOBJ path1,
82 ___SCMOBJ path2),
83 ());
85 extern ___SCMOBJ ___os_delete_directory
86 ___P((___SCMOBJ path),
87 ());
89 extern ___SCMOBJ ___os_set_current_directory
90 ___P((___SCMOBJ path),
91 ());
93 extern ___SCMOBJ ___os_rename_file
94 ___P((___SCMOBJ path1,
95 ___SCMOBJ path2),
96 ());
98 extern ___SCMOBJ ___os_copy_file
99 ___P((___SCMOBJ path1,
100 ___SCMOBJ path2),
101 ());
103 extern ___SCMOBJ ___os_delete_file
104 ___P((___SCMOBJ path),
105 ());
108 /*---------------------------------------------------------------------------*/
110 /* File system module initialization/finalization. */
113 extern ___SCMOBJ ___setup_files_module ___PVOID;
115 extern void ___cleanup_files_module ___PVOID;
118 /*---------------------------------------------------------------------------*/
121 #endif