From 8648757e1965104343afd7fa72c001216baecdb7 Mon Sep 17 00:00:00 2001 From: Mike Kestner Date: Mon, 7 Jan 2002 00:25:51 +0000 Subject: [PATCH] 2002-01-06 Mike Kestner * */makefile : Add atk to the build. * generator/EnumGen.cs : Create the generated dir if necessary. * generator/ObjectGen.cs : Create the generated dir if necessary. * generator/StructGen.cs : Create the generated dir if necessary. * parser/gapi2xml.pl : Squash bug in comma separated field defs. svn path=/trunk/gtk-sharp/; revision=1882 --- ChangeLog | 8 ++++++++ atk/.cvsignore | 4 ++++ atk/makefile | 10 ++++++++++ gdk/.cvsignore | 1 + gdk/makefile | 2 +- generator/.cvsignore | 1 + generator/EnumGen.cs | 3 +++ generator/ObjectGen.cs | 3 +++ generator/StructGen.cs | 3 +++ generator/api.xml | 2 +- glib/.cvsignore | 1 + gtk/.cvsignore | 2 +- gtk/makefile | 2 +- makefile | 2 +- pango/.cvsignore | 1 + parser/gapi2xml.pl | 2 +- sample/.cvsignore | 1 + 17 files changed, 42 insertions(+), 6 deletions(-) create mode 100644 atk/.cvsignore create mode 100644 atk/makefile diff --git a/ChangeLog b/ChangeLog index c8f198603..d257ef8cd 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,11 @@ +2002-01-06 Mike Kestner + + * */makefile : Add atk to the build. + * generator/EnumGen.cs : Create the generated dir if necessary. + * generator/ObjectGen.cs : Create the generated dir if necessary. + * generator/StructGen.cs : Create the generated dir if necessary. + * parser/gapi2xml.pl : Squash bug in comma separated field defs. + 2002-01-06 Mike Kestner * generator/EnumGen.cs : Open stream Create only. diff --git a/atk/.cvsignore b/atk/.cvsignore new file mode 100644 index 000000000..7851f6209 --- /dev/null +++ b/atk/.cvsignore @@ -0,0 +1,4 @@ +*.dll +*.exe +generated + diff --git a/atk/makefile b/atk/makefile new file mode 100644 index 000000000..a5ba1a04a --- /dev/null +++ b/atk/makefile @@ -0,0 +1,10 @@ + +all: + @echo "You must use 'make windows' or 'make unix'." + @echo "'make unix' is broken for now." + +windows: + $(CSC) /unsafe /target:library /r:../glib/glib-sharp.dll /r:../pango/pango-sharp.dll /out:atk-sharp.dll /recurse:*.cs + +unix: + @echo "'make unix' is broken for now." diff --git a/gdk/.cvsignore b/gdk/.cvsignore index 4e8ac1c1b..7851f6209 100644 --- a/gdk/.cvsignore +++ b/gdk/.cvsignore @@ -1,3 +1,4 @@ *.dll *.exe +generated diff --git a/gdk/makefile b/gdk/makefile index 985540823..7cbdc7c27 100755 --- a/gdk/makefile +++ b/gdk/makefile @@ -4,7 +4,7 @@ all: @echo "'make unix' is broken for now." windows: - $(CSC) /unsafe /target:library /r:../glib/glib-sharp.dll /r:../pango/pango-sharp.dll /out:gdk-sharp.dll /recurse:*.cs + $(CSC) /unsafe /target:library /r:../glib/glib-sharp.dll /r:../pango/pango-sharp.dll /r:../atk/atk-sharp.dll /out:gdk-sharp.dll /recurse:*.cs unix: @echo "'make unix' is broken for now." diff --git a/generator/.cvsignore b/generator/.cvsignore index 4e8ac1c1b..7851f6209 100644 --- a/generator/.cvsignore +++ b/generator/.cvsignore @@ -1,3 +1,4 @@ *.dll *.exe +generated diff --git a/generator/EnumGen.cs b/generator/EnumGen.cs index 15faf3440..f5166f4fe 100644 --- a/generator/EnumGen.cs +++ b/generator/EnumGen.cs @@ -56,6 +56,9 @@ namespace GtkSharp.Generation { public void Generate (SymbolTable table) { + if (!Directory.Exists("..\\" + ns.ToLower() + "\\generated")) { + Directory.CreateDirectory("..\\"+ns.ToLower()+"\\generated"); + } String filename = "..\\" + ns.ToLower() + "\\generated\\" + Name + ".cs"; FileStream stream = new FileStream (filename, FileMode.Create, FileAccess.Write); diff --git a/generator/ObjectGen.cs b/generator/ObjectGen.cs index 7c03a8bfc..4c96dbe13 100644 --- a/generator/ObjectGen.cs +++ b/generator/ObjectGen.cs @@ -49,6 +49,9 @@ namespace GtkSharp.Generation { public void Generate (SymbolTable table) { + if (!Directory.Exists("..\\" + ns.ToLower() + "\\generated")) { + Directory.CreateDirectory("..\\"+ns.ToLower()+"\\generated"); + } String filename = "..\\" + ns.ToLower() + "\\generated\\" + Name + ".cs"; FileStream stream = new FileStream (filename, FileMode.Create, FileAccess.Write); diff --git a/generator/StructGen.cs b/generator/StructGen.cs index 1cce903db..cb518fcc4 100644 --- a/generator/StructGen.cs +++ b/generator/StructGen.cs @@ -49,6 +49,9 @@ namespace GtkSharp.Generation { public void Generate (SymbolTable table) { + if (!Directory.Exists("..\\" + ns.ToLower() + "\\generated")) { + Directory.CreateDirectory("..\\"+ns.ToLower()+"\\generated"); + } String filename = "..\\" + ns.ToLower() + "\\generated\\" + Name + ".cs"; FileStream stream = new FileStream (filename, FileMode.Create, FileAccess.Write); diff --git a/generator/api.xml b/generator/api.xml index cbf0910a5..aeaa1e6fa 100644 --- a/generator/api.xml +++ b/generator/api.xml @@ -1,2 +1,2 @@ - + diff --git a/glib/.cvsignore b/glib/.cvsignore index 4e8ac1c1b..7851f6209 100755 --- a/glib/.cvsignore +++ b/glib/.cvsignore @@ -1,3 +1,4 @@ *.dll *.exe +generated diff --git a/gtk/.cvsignore b/gtk/.cvsignore index d28995576..7851f6209 100755 --- a/gtk/.cvsignore +++ b/gtk/.cvsignore @@ -1,4 +1,4 @@ *.dll *.exe -generated.cs +generated diff --git a/gtk/makefile b/gtk/makefile index 46fb49a6b..469444640 100755 --- a/gtk/makefile +++ b/gtk/makefile @@ -3,7 +3,7 @@ all: @echo "'make unix' is broken for now." windows: - $(CSC) /unsafe /target:library /r:../glib/glib-sharp.dll /r:../pango/pango-sharp.dll /r:../gdk/gdk-sharp.dll /out:gtk-sharp.dll /recurse:*.cs + $(CSC) /unsafe /target:library /r:../glib/glib-sharp.dll /r:../pango/pango-sharp.dll /r:../atk/atk-sharp.dll /r:../gdk/gdk-sharp.dll /out:gtk-sharp.dll /recurse:*.cs unix: @echo "'make unix' is broken for now." diff --git a/makefile b/makefile index 78c91eb01..c79645fad 100644 --- a/makefile +++ b/makefile @@ -1,4 +1,4 @@ -DIRS=generator glib pango gdk gtk sample +DIRS=generator glib pango atk gdk gtk sample ROOT=/cygdrive/$(subst \,/,$(subst :\,/,$(SYSTEMROOT))) CSC=$(ROOT)/microsoft.net/framework/v1.0.2914/csc.exe diff --git a/pango/.cvsignore b/pango/.cvsignore index 4e8ac1c1b..7851f6209 100644 --- a/pango/.cvsignore +++ b/pango/.cvsignore @@ -1,3 +1,4 @@ *.dll *.exe +generated diff --git a/parser/gapi2xml.pl b/parser/gapi2xml.pl index 988635108..5d33c7ae4 100755 --- a/parser/gapi2xml.pl +++ b/parser/gapi2xml.pl @@ -306,7 +306,7 @@ sub addFieldElems $elem = addNameElem($parent, 'field', $1); $elem->setAttribute('bits', "$2"); } else { - $elem = addNameElem($parent, 'field', $symb); + $elem = addNameElem($parent, 'field', $tok); } $elem->setAttribute('type', "$type"); } diff --git a/sample/.cvsignore b/sample/.cvsignore index 4e8ac1c1b..7851f6209 100755 --- a/sample/.cvsignore +++ b/sample/.cvsignore @@ -1,3 +1,4 @@ *.dll *.exe +generated