projects
/
yaffs2.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
5fdeee7
)
More SWIG pythonry
author
charles
<charles>
Thu, 8 Oct 2009 23:11:12 +0000
(23:11 +0000)
committer
charles
<charles>
Thu, 8 Oct 2009 23:11:12 +0000
(23:11 +0000)
direct/python/Makefile
patch
|
blob
|
history
direct/python/yaffs_swig_helper.c
patch
|
blob
|
history
diff --git
a/direct/python/Makefile
b/direct/python/Makefile
index 98b726c38bae0f74f90fa9486b3197e7c830d093..5f24f97eeaab6d838c5243fa4e667655d14ac0a0 100644
(file)
--- a/
direct/python/Makefile
+++ b/
direct/python/Makefile
@@
-14,7
+14,7
@@
#
# NB Warning this Makefile does not include header dependencies.
#
#
# NB Warning this Makefile does not include header dependencies.
#
-# $Id: Makefile,v 1.
1 2009-10-08 01:58:5
2 charles Exp $
+# $Id: Makefile,v 1.
2 2009-10-08 23:11:1
2 charles Exp $
#EXTRA_COMPILE_FLAGS = -DYAFFS_IGNORE_TAGS_ECC
#EXTRA_COMPILE_FLAGS = -DYAFFS_IGNORE_TAGS_ECC
@@
-62,7
+62,14
@@
yaffs_wrap.c: yaffs.i yaffsfs_for_swig.h
swig -python yaffs.i
yaffsfs_for_swig.h: yaffsfs.h
swig -python yaffs.i
yaffsfs_for_swig.h: yaffsfs.h
- cat yaffsfs.h | sed -e "s/YCHAR/char/g" | sed -e "s/YUCHAR/unsigned char/g" | sed -e "s/struct yaffs_stat/struct yaffs_stat_struct/g" > $@
+ cat yaffsfs.h | \
+ sed -e "s/YCHAR/char/g" | \
+ sed -e "s/YUCHAR/unsigned char/g" | \
+ sed -e "s/void \*/char \*/g" | \
+ sed -e "s/loff_t/long long/g" | \
+ sed -e "s/off_t/long/g" | \
+ sed -e "s/struct yaffs_stat/struct yaffs_stat_struct/g" \
+ > $@
$(ALLOBJS): %.o: %.c
gcc -c $(CFLAGS) -I/usr/include/python2.6/ -o $@ $<
$(ALLOBJS): %.o: %.c
gcc -c $(CFLAGS) -I/usr/include/python2.6/ -o $@ $<
diff --git
a/direct/python/yaffs_swig_helper.c
b/direct/python/yaffs_swig_helper.c
index 9adc18313d3820dc9f84fc8487164022938b55b4..c803a5576338c95b12abbe82f2e176377a9884a1 100644
(file)
--- a/
direct/python/yaffs_swig_helper.c
+++ b/
direct/python/yaffs_swig_helper.c
@@
-18,4
+18,6
@@
int yaffs_print_constants(void)
printf( "O_WRONLY.......%d\n",O_WRONLY);
printf( "O_RDWR.........%d\n",O_RDWR);
printf( "O_TRUNC........%d\n",O_TRUNC);
printf( "O_WRONLY.......%d\n",O_WRONLY);
printf( "O_RDWR.........%d\n",O_RDWR);
printf( "O_TRUNC........%d\n",O_TRUNC);
+
+ return 0;
}
}