update NOTICE
[nit.git] / c_src / file_nit.h
index 4291f02..1f5b183 100644 (file)
 #include <stdio.h>
 #include <sys/types.h>
 
-#ifndef NONITCNI
-#include <file._nitni.h>
-
-Set String_files___impl( String recv );
-#endif
-
 extern int string_NativeString_NativeString_file_exists_0(char *f);
 extern void *string_NativeString_NativeString_file_stat_0(char *f);
 extern void *file_NativeFile_NativeFile_file_stat_0(FILE *f);
@@ -48,6 +42,9 @@ extern int string_NativeString_NativeString_file_delete_0(char *f);
 #define file_FileStat_FileStat_size_0(self) (((struct stat*)self)->st_size)
 
 #define string_NativeString_NativeString_file_mkdir_0(p) (mkdir(p, 0777))
+#define string_NativeString_NativeString_file_getcwd_0(p) (getcwd(NULL, 0))
+#define string_NativeString_NativeString_file_chdir_0(p) (chdir(p)?-1:0) /* hack to avoid warn_unused_result */
+#define file_NativeString_realpath(p) (realpath(p, NULL))
 
 #define file_stdin_poll_in(self) file_stdin_poll_in_()
 int file_stdin_poll_in_(void);