X-Git-Url: http://www.aleph1.co.uk/gitweb/?p=yaffs2.git;a=blobdiff_plain;f=direct%2Fpython%2Fyaffsfs.py;h=77048200b65b48eb2279ac9d32905a48a2633413;hp=5ef7c76120a38e4ae00e549a8d1c1f03b735e01c;hb=d4264d6b99c4b943c3217347ec73e1f6bef49a63;hpb=5e008044bbb82598c2ae8ddd7bab78c955b6d2b0 diff --git a/direct/python/yaffsfs.py b/direct/python/yaffsfs.py index 5ef7c76..7704820 100644 --- a/direct/python/yaffsfs.py +++ b/direct/python/yaffsfs.py @@ -2,6 +2,11 @@ from ctypes import * cdll.LoadLibrary("./libyaffsfs.so") ylib = CDLL("./libyaffsfs.so") +#int yaffs_open_sharing(const YCHAR *path, int oflag, int mode, int sharingmode) ; +yaffs_open_sharing = ylib.yaffs_open_sharing +yaffs_open_sharing.argtypes = [ c_char_p, c_int, c_int, c_int] +yaffs_open_sharing.restype = c_int + #int yaffs_open(const YCHAR *path, int oflag, int mode) ; yaffs_open = ylib.yaffs_open yaffs_open.argtypes = [ c_char_p, c_int, c_int] @@ -240,3 +245,20 @@ yaffs_StartUp = ylib.yaffs_StartUp yaffs_StartUp.argtypes = [] yaffs_StartUp.restype = c_int +yaffs_O_CREAT=ylib.yaffs_O_CREAT() +yaffs_O_RDONLY=ylib.yaffs_O_RDONLY() +yaffs_O_WRONLY=ylib.yaffs_O_WRONLY() +yaffs_O_RDWR=ylib.yaffs_O_RDWR() +yaffs_O_TRUNC=ylib.yaffs_O_TRUNC() + + +yaffs_S_IFMT=ylib.yaffs_S_IFMT() +yaffs_S_IFLNK= ylib.yaffs_S_IFLNK() +yaffs_S_IFDIR =ylib.yaffs_S_IFDIR() +yaffs_S_IFREG=ylib.yaffs_S_IFREG() +yaffs_S_IREAD=ylib.yaffs_S_IREAD() +yaffs_S_IWRITE=ylib.yaffs_S_IWRITE() +yaffs_S_IEXEC=ylib.yaffs_S_IEXEC() +yaffs_XATTR_CREATE=ylib.yaffs_XATTR_CREATE() +yaffs_XATTR_REPLACE=ylib.yaffs_XATTR_REPLACE() +yaffs_S_IEXEC=ylib.yaffs_S_IEXEC()