1 2008-08-19 Colin Walters <walters@verbum.org>
3 * giscanner/transformer.py: Don't try
4 to strip prefix before namespace.
6 2008-08-19 Johan Dahlin <johan@gnome.org>
8 * giscanner/transformer.py:
9 * tests/scanner/Foo-expected.gir:
10 * tests/scanner/foo-object.h:
11 Add support for typedef void foo type of
14 2008-08-19 Johan Dahlin <johan@gnome.org>
17 * giscanner/girwriter.py:
18 * giscanner/glibtransformer.py:
19 * giscanner/transformer.py:
20 * tests/scanner/Foo-expected.gir:
21 Add basic support for union, base the code much
22 on Struct. Add a testcase.
24 2008-08-19 Johan Dahlin <johan@gnome.org>
26 * tests/scanner/Foo-expected.gir:
27 * tests/scanner/foo-object.h:
28 Add a union testcase which the compiler currently
31 2008-08-19 Johan Dahlin <johan@gnome.org>
33 * gobject-introspection-1.0.pc.in:
34 Add a g_ir_compiler variable
36 2008-08-19 Colin Walters <walters@verbum.org>
38 * giscanner/ast.py: Rework types to be more closely
40 * giscanner/girparser.py: Parse more bits.
41 * giscanner/girwriter.py: Write sequences in a new
42 way that specifies container type.
43 * giscanner/glibast.py: Adjust for ast.py changes,
44 add 'ctype' property to GLibObject and GLibInterface
45 so we can look things up by it later.
46 * gicanner/transformer.py: Names is new class holding
47 the various namespaces we manage. Do not confuse
48 with Namespace which is toplevel XML node effectively.
49 Rework all type resolution to go through
51 * giscanner/glibtransformer.py: Raise UnknownTypeError
52 instead of ValueError for cleanliness. Add Unresolved
53 class to mark types whose parent we haven't seen yet.
54 Use new Names object from transformer.py.
55 Correctly look up parent=.
56 Fix type validation to handle sequences.
57 * tests/scanner/Foo-expected.gir: Update for sequence
58 work, int instead of int32.
59 * tools/g-ir-scanner: Add --noclosure option
60 * gir/Makefile.am: Use --noclosure by default for
63 2008-08-18 Johan Dahlin <johan@gnome.org>
65 * gir/gio-2.0-good.gir:
66 * gir/glib-2.0-good.gir:
67 * gir/gobject-2.0-good.gir:
70 2008-08-18 Johan Dahlin <johan@gnome.org>
73 * giscanner/girparser.py:
74 * giscanner/girwriter.py:
75 * giscanner/glibast.py:
76 * giscanner/glibtransformer.py:
77 * giscanner/transformer.py:
78 * tests/scanner/Foo-expected.gir:
79 * tests/scanner/foo-object.h:
80 * tests/scanner/utility-expected.gir:
81 * tests/scanner/utility.h:
82 Redo type resolving and validation.
83 Add a couple of new tests.
84 Patch mostly written by Colin.
86 2008-08-18 Johan Dahlin <johan@gnome.org>
89 * giscanner/girparser.py:
91 * giscanner/transformer.py:
92 Improve enum parsing for enums without a GType.
93 Make flags/enum references to other girs work
96 * tests/scanner/Makefile.am:
97 * tests/scanner/foo-object.h:
98 * tests/scanner/utility-expected.gir:
99 * tests/scanner/utility.h:
100 Add a new test for external enum references
102 2008-08-18 Johan Dahlin <johan@gnome.org>
104 * docs/global-module-registry.txt: Update
106 * tests/array.gir: Update with new type proposal
108 * girepository/girepository.c (g_type_tag_to_string):
109 * girepository/girepository.h:
110 * girepository/girnode.c (g_ir_node_get_full_size_internal),
112 * girepository/girnode.h:
113 Make enum serializing functions public. Clean up some whitespace.
115 2008-08-17 Johan Dahlin <johan@gnome.org>
117 * docs/global-module-registry.txt:
118 Add a document for an on disk module registry format
120 2008-08-17 Johan Dahlin <johan@gnome.org>
123 * gir/gio-2.0-good.gir:
126 2008-08-17 Johan Dahlin <johan@gnome.org>
129 * gir/glib-2.0-good.gir:
130 * gir/gobject-2.0-good.gir:
131 * giscanner/cgobject.py:
132 * giscanner/glibtransformer.py:
133 Regenerate GObject & GType.
134 Avoid warnings when generating gobject-2.0.gir.
135 Introspect a little more, and skip *_get_type functions.
137 2008-08-17 Colin Walters <walters@verbum.org>
139 * gir/glib-2.0.gir, gir/gobject-2.0.gir:
140 Rename to -good, always generate during build.
141 * gir/Makefile.am: Ensure .gir files dep on
143 * Makefile.am: Switch build order to ensure
144 the scanner is ready before we do gir/.
145 * tools/g-ir-scanner: Look for .git too.
147 2008-08-17 Johan Dahlin <johan@gnome.org>
149 * girepository/gtypelib.c (validate_enum_blob):
150 * giscanner/glibtransformer.py:
151 * giscanner/transformer.py:
152 Remove resolve_possible_typedefs, it was unused.
153 Allow multiple enum values of the sample value in an enum,
154 since it's actually pretty common.
155 Register enums so they can be resolved too.
157 2008-08-16 Johan Dahlin <johan@gnome.org>
159 * giscanner/girparser.py:
160 Parse enumeration/bitfield.
162 2008-08-16 Johan Dahlin <johan@gnome.org>
164 * giscanner/girparser.py:
167 2008-08-16 Johan Dahlin <johan@gnome.org>
169 * giscanner/glibtransformer.py:
170 Resolve type names for alias targets
171 * giscanner/transformer.py:
172 Skip FILE* parameters fow now
174 2008-08-16 Johan Dahlin <johan@gnome.org>
177 * gir/gobject-2.0.gir:
180 * tests/scanner/Makefile.am:
183 2008-08-15 Colin Walters <walters@verbum.org>
185 * giscanner/glibtransformer.py: Explicitly construct
186 new list, since we're deleting as we iterate.
187 Don't delete all structures which end in Class; just
188 ones which have a paired GObject.
189 Fix printing of type warning.
190 * giscanner/transformer.py: Make strip_namespace_object
191 be the identity function if it doesn't match the
194 2008-08-15 Colin Walters <walters@verbum.org>
196 * giscanner/cgobject.py: Define yet more argument
197 prototypes; fix prototype for g_type_fundamental.
199 2008-08-14 Johan Dahlin <johan@gnome.org>
202 * tests/constant.gir:
205 * tools/generate.c (write_struct_info):
206 Fix generator for constant/gobject/struct
208 2008-08-14 Johan Dahlin <johan@gnome.org>
212 * tools/generate.c (write_enum_info):
213 Fix generation of enum/bitfields
215 2008-08-14 Johan Dahlin <johan@gnome.org>
217 * girepository/girparser.c (start_field), (start_constant),
218 (start_type), (end_element_handler):
219 Clear up constant parsing
224 * tools/generate.c (write_callable_info), (write_function_info),
225 (write_callback_info), (write_constant_info), (write_signal_info),
226 (write_vfunc_info), (write_property_info), (write_object_info),
227 (write_interface_info):
228 Constants/Signals are handled now.
230 2008-08-14 Johan Dahlin <johan@gnome.org>
232 * girepository/girparser.c (start_type):
233 Don't require c:type.
237 Update, remove parts we don't support yet
238 * tests/roundtrips.sh:
240 * tools/generate.c (write_type_info), (write_field_info),
241 (write_callable_info), (write_struct_info):
242 Make it emit proper gir.
244 2008-08-14 Johan Dahlin <johan@gnome.org>
246 * giscanner/transformer.py:
247 New internal function for adding a new node.
249 2008-08-14 Johan Dahlin <johan@gnome.org>
252 Define an internal _H_ variable so we skip parsing both
253 i18n headers, only one is needed.
255 Add the glib-2.0.gir too.
256 * giscanner/glibast.py:
257 Add gconstpointer as an alias for ANY
258 * giscanner/transformer.py:
259 Do not lower case enumeration names per se.
260 Skip functions which has parameters called 'va_list'
262 2008-08-14 Colin Walters <walters@verbum.org>
264 * giscanner/transformer.py: Comment data structures.
265 Also squash pointers in resolve_type_name to correspond
266 with what we do for params.
267 * giscanner/glibtransformer.py: Print warnings in more
268 situations. Rework checks for method/constructor to
269 look up in our GType database instead of just checking
270 for *. Avoid generating <record> for GObject which
271 duplicate the <class>.
272 * gir/Makefile.am: Generate glib-2.0.gir and gobject-2.0.gir
275 2008-08-14 Johan Dahlin <johan@gnome.org>
277 * giscanner/girwriter.py:
278 * giscanner/glibast.py:
279 * giscanner/glibtransformer.py:
280 * giscanner/transformer.py:
283 Add pyflakes.py and run it in make check.
284 Update the source code to fix the errors reported by
287 2008-08-14 Johan Dahlin <johan@gnome.org>
290 * giscanner/girparser.py:
291 * giscanner/glibast.py:
292 * giscanner/glibtransformer.py:
293 Refactor the parser a bit.
294 Add parent type to interfaces and update callsites.
296 2008-08-14 Johan Dahlin <johan@gnome.org>
298 * giscanner/glibtransformer.py:
299 * giscanner/utils.py:
300 Refactor a bit, avoid isinstance and add a method
301 for each type we parse.
303 2008-08-14 Johan Dahlin <johan@gnome.org>
306 * giscanner/girparser.py:
307 * giscanner/glibtransformer.py:
309 Run pep8.py in make check, fix old errors.
311 2008-08-13 Colin Walters <walters@verbum.org>
313 * giscanner/girparser.py: Parse records.
315 2008-08-13 Colin Walters <walters@verbum.org>
317 * gir/Makefile.am: Install again.
318 * gir/gobject-2.0.gir: Add some more bits.
320 2008-08-13 Colin Walters <walters@verbum.org>
322 * gir/gobject-2.0.gir: Use correct namespace, add GType.
323 * giscanner/girparser.py: Handle aliases.
324 * giscanner/transformer.py: Record aliases. Make resolver
325 functions public; we now call into these explicitly from
326 glibtransformer. Handle resolving aliases.
327 * giscanner/glibtransformer.py: Separate our internal namespace
328 from included ones. Call up into transformer's resolver functions.
330 2008-08-13 Johan Dahlin <johan@gnome.org>
332 * girepository/girnode.c (g_ir_node_get_full_size_internal):
333 * girepository/girparser.c (start_class):
334 * giscanner/glibtransformer.py:
335 Allow get_type to be None, set a get_type for GInitiallyUnowned too.
337 2008-08-13 Johan Dahlin <johan@gnome.org>
339 * giscanner/cgobject.py:
340 Register GInitiallyUnowned
341 * giscanner/girwriter.py:
342 * giscanner/glibtransformer.py:
343 Special case GObject/GInitially owned as they are a bit special to use.
345 2008-08-13 Colin Walters <walters@verbum.org>
347 * tests/scanner/Foo-expected.gir, tests/scanner/utility-expected.gir:
348 Object is in GObject namespace.
350 2008-08-13 Colin Walters <walters@verbum.org>
352 * giscanner/girparser.py: Fix processing of functions
355 2008-08-13 Colin Walters <walters@verbum.org>
357 * giscanner/girparser.py: Parse more than just <class.
358 * giscanner/glibtransformer.py: Put aliases in a separate
359 data structure since their name is not canonicall.
360 * giscanner/transformer.py: Handle resolving type names
363 2008-08-13 Johan Dahlin <johan@gnome.org>
365 * tools/g-ir-scanner:
366 Allow multiple libraries
367 * giscanner/glibtransformer.py:
368 Rename load_library to add_library, traverse over all libraries
369 when trying to resolve a function
371 2008-08-12 Colin Walters <walters@verbum.org>
373 * giscanner/transformer.py: Record typedefs as <alias> elements.
374 Also attempt to look up types in external namespaces.
375 * giscanner/girwriter.py: Write them.
376 * giscanner/glibtransformer.py: Rework resolver using real instanceof
377 checks. Resolve interface methods and properties.
378 * tests/scanner/foo-object.h: Add a method with typedef.
379 * tests/scanner/Foo-expected.gir: Update.
380 * girepository/girnode.c: Debug tweaks.
381 * girepository/girparser.c: Make a first pass through the XML where we
382 record all the aliases. This lets us resolve them as we go through the
384 * gir/Makefile.am: Don't install gobject-2.0.gir; we want that to come
387 2008-08-12 Colin Walters <walters@verbum.org>
389 * giscanner/glibtransformer.py: Resolve typedefs (e.g. AtkAttributeSet -> GSList).
390 Correctly do subclasseing in 2nd pass resolution. Handle callbacks in structure
392 * giscanner/transformer.py: Record typedefs and expose public API for resolving
394 * tests/scanner/Foo-expected.gir: Fix expected callback types.
396 2008-08-12 Colin Walters <walters@verbum.org>
398 * giscanner/glibtransformer.py: Also transform object properties.
400 2008-08-12 Colin Walters <walters@verbum.org>
402 * giscanner/glibtransformer.py: Also transform callbacks
403 and structure field types.
404 * tests/scanner/Fooe-expected.gir: Update to expect correct
405 names for callbacks and structs.
407 2008-08-12 Colin Walters <walters@verbum.org>
409 * girepository/girparser.c: Handle 'any'.
410 * tests/scanner/Foo-expected.gir, tests/scanner/foo-object.h:
413 2008-08-12 Colin Walters <walters@verbum.org>
415 * giscanner/glibtransformer.py: We need to do type
416 resolution in a second pass after we've seen all the
419 2008-08-12 Colin Walters <walters@verbum.org>
421 * tests/scanner/Foo-expected.gir, tests/scanner/foo-object.h:
422 Add enum return value.
423 * giscanner/glibtransformer.py: Transform function return types
426 2008-08-12 Colin Walters <walters@verbum.org>
428 * tests/scanner/Makefile.am: Dep .gir files on scanner
429 sources too. Also remove @ so we see scanner invocations.
431 2008-08-12 Colin Walters <walters@verbum.org>
433 * girepository/girparser.c, girepository/gtypelib.c,
434 girepository/gtypelib.h, girepository/girnode.c:
435 Remove usage of (GAPI-oriented) TypeTag in favor of
436 GITypeTag from girepository.h.
438 2008-08-10 Colin Walters <walters@verbum.org>
440 * tests/roundtrips.sh: Use the correct tests.
442 2008-08-10 Colin Walters <walters@verbum.org>
444 * giscanner/cgobject.py: Declare/wrap a few more functions.
445 Fix parameter types for g_object_new and g_type_fundamental.
447 2008-08-10 Colin Walters <walters@verbum.org>
449 * giscanner/cgobject.py: Add new decorator @gwrap which forces
450 us to declare types for both return value and parameters. The
451 ctypes default of 'int' is bad because it hides 32/64 bit
452 problems. Convert all existing functions to use it.
454 2008-08-09 Johan Dahlin <johan@gnome.org>
456 * giscanner/__init__.py:
458 * giscanner/cgobject.py:
459 * giscanner/gidlparser.py:
460 * giscanner/gidlwriter.py:
461 * giscanner/girparser.py:
462 * giscanner/girwriter.py:
463 * giscanner/glibast.py:
464 * giscanner/glibtransformer.py:
465 * giscanner/odict.py:
466 * giscanner/sourcescanner.py:
467 * giscanner/transformer.py:
468 * giscanner/utils.py:
469 * giscanner/xmlwriter.py:
470 * tools/g-ir-scanner:
474 2008-08-09 Johan Dahlin <johan@gnome.org>
477 * relaxng/c-types.xml:
478 * relaxng/g-types.xml:
479 * relaxng/relaxng.rng:
481 Remove outdated relaxng schemas.
483 2008-08-09 Johan Dahlin <johan@gnome.org>
486 Rename metadata to typelib in variable names,
489 2008-08-09 Johan Dahlin <johan@gnome.org>
493 Remove old C scanner, which got rewritten in python.
495 2008-08-09 Johan Dahlin <johan@gnome.org>
497 * girepository/Makefile.am:
507 Move shared *.[ch] files to girepository from tools
509 2008-08-09 Johan Dahlin <johan@gnome.org>
514 * tests/constant.test:
517 * tests/function.test:
518 * tests/gobject.test:
519 * tests/interface.test:
526 Rename *.test to *.gir
528 2008-08-09 Johan Dahlin <johan@gnome.org>
532 * tests/parser/Foo-expected.gir:
533 * tests/parser/Makefile.am:
534 * tests/parser/foo-object.h:
535 * tests/parser/foo.c:
536 * tests/parser/utility-expected.gir:
537 * tests/parser/utility.c:
538 * tests/parser/utility.h:
539 * tests/scanner/Makefile.am:
540 Rename tests/parser to test/scanner
542 2008-08-08 Colin Walters <walters@verbum.org>
544 * tests/roundtrips.sh: Use local .gir files again.
546 2008-08-08 Colin Walters <walters@verbum.org>
548 * tests/invoke/Makefile.am: .gir file depends on libtool
551 2008-08-08 Colin Walters <walters@verbum.org>
553 * tools/girnode.c: Pass through parent node so we can
554 print the node whose child is NULL, if that occurs.
556 2008-08-08 Johan Dahlin <johan@gnome.org>
559 Disable roundtrip tests which are not yet working
560 * tests/invoke/testfns.gir:
563 2008-08-08 Johan Dahlin <johan@gnome.org>
565 * giscanner/girwriter.py:
567 * giscanner/glibast.py:
568 * giscanner/glibtransformer.py:
569 Swap order of members, to keep it consistent with
572 2008-08-08 Johan Dahlin <johan@gnome.org>
574 * girepository/gtypelib.c (validate_header):
575 * girepository/gtypelib.h:
577 * giscanner/girwriter.py:
578 * giscanner/sourcescanner.c (gi_source_symbol_ref),
579 (gi_source_symbol_unref):
582 * tests/constant.test:
585 * tests/function.test:
586 * tests/gobject.test:
587 * tests/interface.test:
588 * tests/invoke/Makefile.am:
589 * tests/invoke/testfns.xml:
591 * tests/parser/Makefile.am:
592 * tests/roundtrips.sh:
599 * tools/compiler.c (main):
600 * tools/generate.c (write_callable_info), (write_function_info),
602 * tools/gidlmodule.c:
603 * tools/gidlmodule.h:
606 * tools/gidlparser.c:
607 * tools/gidlparser.h:
608 * tools/gidlwriter.c:
609 * tools/gidlwriter.h:
610 * tools/scanner.c (create_node_from_gtype),
611 (create_node_from_ctype), (g_igenerator_process_properties),
612 (g_igenerator_process_signals), (g_igenerator_create_object),
613 (g_igenerator_create_interface), (g_igenerator_create_boxed),
614 (g_igenerator_create_enum), (g_igenerator_create_flags),
615 (g_igenerator_process_function_symbol),
616 (g_igenerator_process_unregistered_struct_typedef),
617 (g_igenerator_process_struct_typedef),
618 (g_igenerator_process_union_typedef),
619 (g_igenerator_process_enum_typedef),
620 (g_igenerator_process_function_typedef),
621 (g_igenerator_process_constant), (g_igenerator_process_symbols),
622 (g_igenerator_add_module), (g_igenerator_add_include_idl):
623 Merge in the gir-compiler branch.
624 Thanks to Philip and Colin for their help.
626 2008-07-26 Colin Walters <walters@verbum.org>
628 * tools/Makefile.am (bin_PROGRAMS): Install g-idl-compiler
629 and g-idl-generate to go along with how we're changing this
630 module to be installed.
631 * gobject-introspection-1.0.pc.in: Set up Cflags and Libs.
633 2008-07-24 Colin Walters <walters@verbum.org>
635 * girepository/girepository.c (g_irepository_register): Add
636 environment variable G_IREPOSITORY_VERBOSE so we can print
637 out what we're doing.
638 * girepository/girepository.c (g_irepository_register_file):
639 Add GError error message to g_debug call.
641 2008-07-08 Jürg Billeter <j@bitron.ch>
643 * giscanner/glibast.py:
647 2008-06-21 Johan Dahlin <jdahlin@async.com.br>
649 * giscanner/girparser.py (GIRParser._parse_api): Ignore a few
652 2008-06-20 Johan Dahlin <jdahlin@async.com.br>
655 * giscanner/girwriter.py:
656 * giscanner/transformer.py:
657 * tests/parser/Foo-expected.gir:
658 * tests/parser/foo-object.h:
659 * tests/parser/foo.c (foo_object_allow_none):
660 Add support for gtk-doc annotations for allow-none.
663 2008-06-19 Johan Dahlin <jdahlin@async.com.br>
666 * giscanner/girwriter.py:
667 * giscanner/glibast.py:
668 * giscanner/glibtransformer.py:
669 * giscanner/transformer.py:
670 * tests/parser/Foo-expected.gir:
671 Start using abstract type instead of the raw C types.
672 Register a bunch of glib types we care about.
674 2008-06-19 Rob Taylor <rob.taylor@codethink.co.uk>
679 2008-06-08 Philip Van Hoof <pvanhoof@gnome.org>
681 * girepository/girepository.c:
682 * girepository/gtypelib.c:
683 * girepository/ginfo.c:
684 * girepository/ginvoke.c:
685 * girepository/girepository.h:
686 * girepository/gtypelib.h:
687 * girepository/gmetadata.c:
688 * girepository/Makefile.am:
689 * girepository/gmetadata.h:
691 * tools/gidlmodule.c:
694 * tools/gidlmodule.h:
695 * tools/gidlparser.c:
697 Renamed GMetadata to GTypelib
699 2008-06-07 Johan Dahlin <jdahlin@async.com.br>
701 * giscanner/xmlwriter.py:
702 Improve line wrapping when > 79 charaters
704 2008-06-05 Jürg Billeter <j@bitron.ch>
707 * giscanner/girwriter.py:
708 * giscanner/transformer.py:
709 Use <type> element for field types
710 * tests/parser/Foo-expected.gir:
713 2008-06-04 Johan Dahlin <jdahlin@async.com.br>
715 * giscanner/glibtransformer.py:
716 Fix a bug which prevented GdkEvent from being generated
718 2008-06-03 Johan Dahlin <jdahlin@async.com.br>
720 * giscanner/Makefile.am:
722 * giscanner/girwriter.py:
723 * giscanner/glibast.py:
724 * giscanner/glibtransformer.py:
725 * giscanner/transformer.py:
726 * giscanner/utils.py:
727 * tests/parser/Foo-expected.gir:
728 Improve enum member parsing and introspection
730 2008-05-31 Johan Dahlin <jdahlin@async.com.br>
732 * giscanner/scannerparser.y:
733 * giscanner/sourcescanner.h:
734 * giscanner/sourcescanner.py:
735 Add a new source type enum for member.
736 Use __repr__ for improved debugging
737 * giscanner/girparser.py:
739 * giscanner/transformer.py:
740 Improve parsing of struct members.
741 * tests/parser/foo-object.h:
744 2008-05-31 Johan Dahlin <jdahlin@async.com.br>
746 * giscanner/xmlwriter.py:
747 Improve error reporting when trying to quote None.
748 * giscanner/girparser.py:
749 Do not print warnings when including more complete .gir files
750 * giscanner/girwriter.py:
751 Do not require a name for parameters, add a todo for singletons
752 * giscanner/glibtransformer.py:
753 Refactor the way structs are done, add a couple of hacks to allow
755 * giscanner/transformer.py:
756 Add enough hacks so cairo, atk and pango.gir can be parsed properly
757 * gobject-introspection-1.0.pc.in:
758 Export girdir, so we can access gobject-2.0.gir from outside
760 2008-05-31 Johan Dahlin <jdahlin@async.com.br>
762 * tools/g-ir-scanner:
763 * tests/parser/Makefile.am:
764 Update sys.path before running the parser so we don't have
765 to setup PYTHONPATH ourselves.
769 * girepository/Makefile.am:
770 * giscanner/transformer.py:
771 * gobject-introspection-1.0.pc.in:
772 * gobject-introspection.pc.in:
775 Rename pkg-config name to gobject-introspection-1.0,
776 Do not installed anything which is not using the gir format.
777 Disable compililation the old C scanner, but still keep the source
778 until all the remaning functionallity has been ported.
780 2008-05-31 Johan Dahlin <jdahlin@async.com.br>
782 * giscanner/giscannermodule.c (symbol_get_ident): Prevent
783 a crash when symbol->indent is NULL.
785 * giscanner/sourcescanner.py (ctype_name): Add ctype_name,
786 a function to convert a CTYPE symbol to a string
788 2008-05-24 Johan Dahlin <jdahlin@async.com.br>
791 * giscanner/girwriter.py:
792 * giscanner/giscannermodule.c
793 (pygi_source_scanner_append_filename),
794 (pygi_source_scanner_parse_file):
795 * giscanner/glibtransformer.py:
796 * giscanner/sourcescanner.py:
797 Revert back to using temporary files to send in headers.
798 Allow Functions to be passed in as callbacks, add a couple
799 of try/excepts missing features.
800 We can now scan pango
802 2008-05-08 Johan Dahlin <johan@gnome.org>
804 * giscanner/glibtransformer.py:
805 * giscanner/transformer.py:
806 Move namespace stripping glibtransformer->transformer
808 2008-05-08 Johan Dahlin <johan@gnome.org>
811 * giscanner/girwriter.py:
812 * giscanner/glibtransformer.py:
813 * giscanner/transformer.py:
814 * tools/g-ir-scanner:
815 Introduce a namespace ast node
817 2008-05-05 Johan Dahlin <johan@gnome.org>
819 * giscanner/__init__.py:
820 * giscanner/sourcescanner.py:
821 * giscanner/transformer.py:
822 Move sourcescanner symbols to the sourcescanner module, instead
823 of in the global __init__ namespace.
825 2008-05-03 Johan Dahlin <johan@gnome.org>
827 * giscanner/glibtransformer.py:
828 * tools/g-ir-scanner:
829 Handle missing parameters better, allow - and + in .la dlname
832 2008-05-03 Johan Dahlin <johan@gnome.org>
834 * giscanner/__init__.py:
836 * giscanner/girwriter.py:
837 * giscanner/glibtransformer.py:
838 * giscanner/transformer.py:
839 Parse struct fields properly, improve debugging.
841 2008-04-29 Johan Dahlin <johan@gnome.org>
844 * giscanner/girwriter.py:
845 * giscanner/transformer.py:
846 * tests/parser/Foo-expected.gir:
848 Use transfer-ownership everywhere, to mark ownership/calle/caller etc.
850 2008-04-29 Johan Dahlin <jdahlin@async.com.br>
853 * docs/g-ir-scanner.1:
854 * metadata-annotations-proposal.txt:
855 * metadata-format.txt:
856 Add a basic, unfinshed man page for g-ir-scanner, move documents into .txt
858 2008-04-29 Johan Dahlin <jdahlin@async.com.br>
860 * giscanner/girwriter.py:
861 * giscanner/glibtransformer.py:
862 * giscanner/transformer.py:
863 * giscanner/xmlwriter.py:
864 * tests/parser/Foo-expected.gir:
865 * tests/parser/foo-object.h:
866 Write record/structs to gir file too. Add a couple of tests,
867 fix an off by one error in xmlwriter.py.
869 2008-04-28 Johan Dahlin <johan@gnome.org>
871 * giscanner/xmlwriter.py: Calculate the line length properly,
872 include the provided extra indentation in the calculation, really.
874 2008-04-28 Johan Dahlin <jdahlin@async.com.br>
877 * giscanner/glibast.py:
878 * giscanner/glibtransformer.py:
879 * giscanner/transformer.py:
880 * tools/g-ir-scanner:
881 Add a --strip-prefix and sort out confusion between names and symbols
882 for functions and struct + derivaties.
883 Refactor bootstrap of g-ir-scanner, so we can set options on
884 Transformer() before parsing everything.
886 2008-04-28 Johan Dahlin <johan@gnome.org>
888 * giscanner/transformer.py (Transformer._traverse_one): Avoid recursion
889 when scanning girepository.h
891 * giscanner/sourcescanner.py (SourceScanner._preprocess): Define
892 a __GI_SCANNER__ when we run.
894 2008-04-28 Johan Dahlin <jdahlin@async.com.br>
897 * giscanner/girwriter.py:
898 * giscanner/glibast.py:
899 * giscanner/glibtransformer.py:
900 * tests/parser/Foo-expected.gir:
901 * tests/parser/utility-expected.gir:
902 Rename most c:identifier to c:type. Add new ones to
903 class/interface/enum/boxed.
905 2008-04-28 Johan Dahlin <jdahlin@async.com.br>
908 * giscanner/girwriter.py:
909 * giscanner/glibtransformer.py:
910 * tests/parser/Foo-expected.gidl:
911 * tests/parser/Makefile.am:
912 Move c:identifier from return-value to subchild type,
913 as per Jürgs suggestion
915 2008-04-28 Johan Dahlin <johan@gnome.org>
917 * giscanner/girwriter.py:
918 * tests/parser/Foo-expected.gir:
919 Write property.type as a child node.
921 2008-04-27 Johan Dahlin <johan@gnome.org>
926 * gidl/gobject-2.0.gidl:
928 * gir/gobject-2.0.gir:
929 * tests/parser/Makefile.am:
930 Replace the GObject gidl with a GObject gir.
932 2008-04-27 Johan Dahlin <johan@gnome.org>
934 * tools/Makefile.am (bin_SCRIPTS): g-ir-scanner is a script,
937 * giscanner/xmlwriter.py:
938 * tests/parser/Foo-expected.gir:
939 Include indentation in line length calculation
941 2008-04-27 Johan Dahlin <johan@gnome.org>
943 * giscanner/girparser.py:
944 Prettify NS parsing using elementtree.
946 2008-04-27 Johan Dahlin <johan@gnome.org>
949 * giscanner/Makefile.am:
950 * giscanner/girparser.py:
951 * giscanner/glibtransformer.py:
952 * tests/parser/Foo-expected.gidl:
953 * tests/parser/Foo-expected.gir:
954 * tests/parser/Makefile.am:
955 * tests/parser/utility-expected.gidl:
956 * tests/parser/utility-expected.gir:
957 * tools/g-ir-scanner:
958 Switch over to GIR as the default format. Add a simple GIDL
960 Update tests and fix simplify makefiles by depending
961 on GNU make extensions.
963 2008-04-27 Johan Dahlin <johan@gnome.org>
965 * giscanner/xmlwriter.py:
966 Wrap attributes for lines which are wider than 79 characters
968 * giscanner/scannerlexer.l:
969 Allow parenthesis in annotations
972 * giscanner/gidlwriter.py:
973 * giscanner/girwriter.py:
974 * giscanner/glibtransformer.py:
975 * giscanner/transformer.py:
976 Add initial sequence support, including annotation.
977 Refactor type handling a bit.
979 2008-04-27 Johan Dahlin <johan@gnome.org>
981 * tests/parser/Foo-expected.gidl:
982 * tests/parser/foo-object.h:
983 * tests/parser/foo.c (foo_object_class_init),
984 (foo_object_get_strings), (foo_object_get_objects):
985 Add two new functions to check sequence return values.
986 Also fixes a compilation warning.
988 2008-04-27 Johan Dahlin <johan@gnome.org>
990 * giscanner/giscannermodule.c (]): Cast the getter, avoids
991 a compilation warning.
993 * tools/Makefile.am (g_ir_scanner_SOURCES):
994 g-ir-scanner has no sources.
996 2008-04-25 Johan Dahlin <johan@gnome.org>
998 * giscanner/Makefile.am:
1000 * giscanner/gidlparser.py:
1001 * giscanner/gidlwriter.py:
1002 * giscanner/girwriter.py:
1003 * giscanner/glibast.py:
1004 * giscanner/glibtransformer.py:
1005 * giscanner/transformer.py:
1006 Split out nodes to ast.py and glibast.py
1008 2008-04-25 Johan Dahlin <jdahlin@async.com.br>
1010 * giscanner/Makefile.am:
1011 * giscanner/gidlparser.py:
1012 * giscanner/gidlwriter.py:
1013 * giscanner/girwriter.py:
1014 * giscanner/glibtransformer.py:
1015 * giscanner/gobjecttreebuilder.py:
1016 * giscanner/transformer.py:
1017 * giscanner/treebuilder.py:
1018 * tools/g-ir-scanner:
1019 Rename treebuilder to transformer and
1020 gobjectreebuilder to glibtransformer.
1022 2008-04-25 Johan Dahlin <jdahlin@async.com.br>
1024 * giscanner/Makefile.am:
1025 * giscanner/__init__.py:
1026 * giscanner/cgobject.py:
1027 * giscanner/gidlparser.py:
1028 * giscanner/gidlwriter.py:
1029 * giscanner/girwriter.py:
1030 * giscanner/gobjecttreebuilder.py:
1031 * giscanner/odict.py:
1032 * giscanner/sourcescanner.py:
1033 * giscanner/treebuilder.py:
1034 * giscanner/xmlwriter.py:
1035 * tools/Makefile.am:
1036 * tools/g-ir-scanner:
1037 Add LGPLv2 license header and install all python files
1039 2008-04-25 Johan Dahlin <jdahlin@async.com.br>
1042 * giscanner/gidlwriter.py:
1043 * giscanner/giscannermodule.c (pygi_source_directive_new),
1044 (directive_get_options), (pygi_source_symbol_new),
1045 (symbol_get_base_type), (pygi_source_type_new),
1046 (type_get_base_type), (type_get_child_list),
1047 (pygi_source_scanner_get_symbols),
1048 (pygi_source_scanner_get_directives):
1049 * giscanner/gobjecttreebuilder.py:
1050 * giscanner/sourcescanner.py:
1051 * giscanner/treebuilder.py:
1052 * tests/parser/foo-object.h:
1053 Add support for virtual methods.
1054 Pair struct FooClass with struct Foo.
1055 Clean up the SourceScanner bindings a bit.
1056 Add a testcase for virtual methods.
1058 2008-04-25 Johan Dahlin <jdahlin@async.com.br>
1060 * giscanner/cgobject.py:
1061 * giscanner/gidlwriter.py:
1062 * giscanner/gobjecttreebuilder.py:
1063 Add support for signals
1065 * tests/parser/foo.c (foo_object_class_init):
1066 * Foo-expected.gidl:
1067 Add a signal and update the expected output.
1069 2008-04-24 Johan Dahlin <jdahlin@async.com.br>
1071 * giscanner/gidlwriter.py:
1072 * giscanner/girwriter.py:
1073 * giscanner/giscannermodule.c (directive_get_name),
1074 (directive_get_value), (directive_get_options),
1075 (symbol_get_directives), (symbol_set_directives),
1076 (pygi_source_scanner_parse_file),
1077 (pygi_source_scanner_lex_filename),
1078 (pygi_source_scanner_get_directives), (init_giscanner):
1079 * giscanner/sourcescanner.c (gi_source_scanner_get_directives):
1080 * giscanner/sourcescanner.h:
1081 * giscanner/sourcescanner.py:
1082 * giscanner/treebuilder.py:
1083 * tools/g-ir-scanner:
1084 Add support for source/header annotations.
1086 2008-04-22 Johan Dahlin <jdahlin@async.com.br>
1088 * giscanner/gidlwriter.py:
1089 * giscanner/girwriter.py:
1090 * giscanner/gobjecttreebuilder.py:
1091 * giscanner/treebuilder.py:
1092 Add support for Callbacks
1094 2008-04-22 Havoc Pennington <hp@pobox.com>
1096 * girepository/ginvoke.c (g_function_info_invoke): If a symbol is
1097 not in metadata->module, look for it in the global module, in case
1098 some other object or the app itself provides the symbol.
1100 2008-04-22 Havoc Pennington <hp@pobox.com>
1102 * girepository/gmetadata.c (_g_metadata_init): hack to avoid
1103 dlopening a library that is already in the main app, by checking
1104 whether one of the lib's symbols is already loaded.
1106 2008-04-22 Johan Dahlin <jdahlin@async.com.br>
1108 * tests/parser/Foo-expected.gidl:
1109 * tests/parser/foo-object.h:
1112 2008-04-22 Havoc Pennington <hp@pobox.com>
1114 * girepository/ginfo.c (g_interface_info_find_method):
1115 Use interface_blob_size not object_blob_size to compute offset.
1117 2008-04-22 Havoc Pennington <hp@pobox.com>
1119 * girepository/gmetadata.c (_g_metadata_init): remove
1120 G_MODULE_BIND_LOCAL flag when loading libraries, since some libs
1121 (Glade and Clutter for example) rely on being loaded globally.
1123 2008-04-22 Havoc Pennington <hp@pobox.com>
1125 * girepository/ginfo.c (g_registered_type_info_get_g_type): new
1126 function to get the GType given a RegisteredTypeInfo
1128 2008-04-22 Johan Dahlin <johan@gnome.org>
1130 * COPYING: Add a LGPL license, to prevent automake to
1131 put in a copy of GPL here. Pointed out by Havoc.
1133 * girepository/ginfo.c (g_info_from_entry), (g_type_info_new),
1134 (g_type_info_is_pointer), (g_type_info_get_tag),
1135 (g_type_info_get_param_type), (g_type_info_get_interface),
1136 (g_type_info_get_array_length), (g_type_info_is_zero_terminated),
1137 (g_type_info_get_n_error_domains), (g_type_info_get_error_domain),
1138 (g_error_domain_info_get_codes), (g_enum_info_get_value),
1139 (g_object_info_get_interface), (g_object_info_get_field),
1140 (g_interface_info_get_prerequisite),
1141 (g_signal_info_get_class_closure), (g_constant_info_get_value):
1142 * girepository/ginvoke.c (get_ffi_type):
1143 * girepository/girepository.h:
1144 * girepository/gmetadata.c (g_metadata_get_dir_entry),
1145 (g_metadata_check_sanity), (validate_header),
1146 (validate_array_type_blob), (validate_iface_type_blob),
1147 (validate_param_type_blob), (validate_error_type_blob),
1148 (validate_type_blob), (validate_constant_blob),
1149 (validate_struct_blob), (validate_enum_blob):
1150 * girepository/gmetadata.h:
1151 * tests/Makefile.am:
1152 * tests/invoke/Makefile.am:
1153 * tests/invoke/invoke.c (main):
1154 * tests/roundtrips.sh:
1155 * tools/Makefile.am:
1156 * tools/compiler.c (format_output), (write_out_metadata), (main):
1157 * tools/generate.c (write_type_name), (write_type_info),
1158 (write_constant_value), (write_enum_info), (load_metadata), (main):
1159 * tools/gidlcompilercontext.c:
1160 * tools/gidlcompilercontext.h:
1161 * tools/gidlcompilerentrynode.c:
1162 * tools/gidlcompilerentrynode.h:
1163 * tools/gidlcompilertypenode.c:
1164 * tools/gidlcompilertypenode.h:
1165 * tools/gidlmodule.c (g_idl_module_build_metadata):
1166 * tools/gidlmodule.h:
1167 * tools/gidlnode.c (init_stats), (dump_stats),
1168 (g_idl_node_get_size), (g_idl_node_get_full_size),
1169 (g_idl_node_cmp), (g_idl_node_can_have_member),
1170 (g_idl_node_add_member), (g_idl_node_param_direction_string),
1171 (parse_int_value), (parse_uint_value), (parse_float_value),
1172 (parse_boolean_value), (find_entry_node), (find_entry),
1173 (serialize_type), (g_idl_node_build_metadata), (write_string):
1175 * tools/gidlparser.c (parse_type_internal):
1176 * tools/quote-file.sh:
1177 Revert revisions 157,149-148,136-129 and 120.
1178 Move back to using g-idl-generate to generate the metadata and
1179 avoids dependency on a c compiler.
1181 2008-04-22 Johan Dahlin <jdahlin@async.com.br>
1183 * giscanner/girwriter.py:
1184 * tools/g-ir-scanner:
1185 Add an initial GIR writer and a --format option to g-ir-scanner
1187 2008-04-21 Johan Dahlin <johan@gnome.org>
1189 * giscanner/cgobject.py: Use ctypes.util.find_library to locate
1190 gobject-2.0 and raise ImportError if not found.
1192 * giscanner/gidlparser.py:
1193 * giscanner/gidlwriter.py:
1194 * giscanner/gobjecttreebuilder.py:
1195 * tools/g-ir-scanner:
1196 Add a --include argument to include types from other idls.
1197 Add a minimalistic GIDL parser (just objects for now)
1198 Implement resolving of external type references and use it to
1199 resolve parent types, argument types and return types.
1201 2008-04-21 Johan Dahlin <johan@gnome.org>
1203 * giscanner/gidlwriter.py:
1204 * giscanner/gobjecttreebuilder.py:
1205 * giscanner/treebuilder.py:
1206 Add support for properties.
1207 Refactor Class/Interface support a bit, to share more code and
1208 always initialize their method attribute to an empty list.
1210 2008-04-21 Johan Dahlin <johan@gnome.org>
1212 * giscanner/cgobject.py:
1213 Add a workaround for a glib bug interface introspection bug
1214 (object_interface_list_properties, object_class_list_properties):
1215 Cast the return value to GParamSpec.
1217 * tests/parser/Foo-expected.gidl: Update
1218 * tests/parser/foo.c: Add a string property
1220 * giscanner/gobjecttreebuilder.py:
1221 After stripping namespaces, remove the original
1222 item to avoid duplication (GtkButton struct and Button object)
1224 2008-04-21 Johan Dahlin <johan@gnome.org>
1226 * giscanner/gobjecttreebuilder.py:
1227 * giscanner/treebuilder.py:
1228 Strip namespaces before objects, so we'll export
1229 GtkButton as Button in the gtk namespace
1231 2008-04-21 Johan Dahlin <johan@gnome.org>
1233 * giscanner/gidlwriter.py:
1234 * giscanner/gobjecttreebuilder.py:
1235 * giscanner/treebuilder.py:
1236 Add constructors for object/boxed types.
1238 2008-04-21 Johan Dahlin <johan@gnome.org>
1240 * giscanner/gidlwriter.py:
1241 * giscanner/gobjecttreebuilder.py:
1242 Add support for boxed types
1244 2008-04-21 Johan Dahlin <johan@gnome.org>
1246 * giscanner/giscannermodule.c: Mark structures as const,
1247 wrap SourceType.const_string.
1249 * tests/parser/foo-object.h: Add a couple of constants.
1251 * giscanner/gidlwriter.py:
1252 * giscanner/gobjecttreebuilder.py:
1253 * giscanner/treebuilder.py:
1254 Add basic support for interfaces
1256 * tools/g-ir-scanner:
1257 Add -o/--output for writing to a file
1259 2008-04-21 Havoc Pennington <hp@redhat.com>
1261 * TODO: add some C API wishlist items I could think of quickly
1263 2008-04-21 Johan Dahlin <jdahlin@async.com.br>
1265 * giscanner/gidlwriter.py:
1266 * giscanner/xmlwriter.py:
1267 Add a simple api for writing tags which can be used
1268 with the new 'with statement' in python 2.5
1270 2008-04-21 Johan Dahlin <johan@gnome.org>
1272 * giscanner/gobjecttreebuilder.py:
1273 Strip namespace and object prefix from method names.
1275 2008-04-21 Johan Dahlin <johan@gnome.org>
1277 * tools/g-ir-scanner (main): Add --pkg option to pass in
1278 pkg-config modules to get cflags from.
1280 * giscanner/gidlwriter.py (GIDLWriter._write_method):
1281 Avoid duplication, reuse function writer for methods.
1283 2008-04-21 Johan Dahlin <jdahlin@async.com.br>
1285 * giscanner/gidlwriter.py:
1286 * giscanner/gobjecttreebuilder.py:
1287 * giscanner/treebuilder.py:
1288 * tools/g-ir-scanner:
1289 Resolve libtool .la files.
1290 Strip name spaces for methods.
1291 Add function symbols
1293 2008-04-20 Johan Dahlin <jdahlin@async.com.br>
1295 * giscanner/cgobject.py:
1296 * giscanner/gidlwriter.py:
1297 * giscanner/gobjecttreebuilder.py:
1298 * giscanner/treebuilder.py:
1299 Add support for classes and methods
1301 2008-04-20 Johan Dahlin <johan@gnome.org>
1303 * giscanner/gidlwriter.py:
1304 * giscanner/gobjecttreebuilder.py:
1305 * giscanner/odict.py:
1306 Avoid conflicts, keep the output ordered similar to
1307 the order of the input.
1308 Add a simple ordered dictionary implemenation
1310 2008-04-19 Johan Dahlin <johan@gnome.org>
1312 * giscanner/cgobject.py:
1313 * giscanner/gidlwriter.py:
1314 * giscanner/gobjecttreebuilder.py:
1315 * tools/g-ir-scanner:
1316 Start introspecting get-type functions.
1317 Implement support for GLib/GFlags GTypes.
1318 Add a ctype based GObject binding.
1320 2008-04-18 Johan Dahlin <jdahlin@async.com.br>
1322 * giscanner/gidlwriter.py:
1323 * giscanner/xmlwriter.py:
1324 * tools/g-ir-scanner:
1325 Add a simplistic gidl writer, which can't do too much.
1327 2008-04-18 Johan Dahlin <johan@gnome.org>
1329 * giscanner/sourcescanner.py:
1330 * giscanner/treebuilder.py:
1331 * tools/g-ir-scanner:
1332 split tree building and source scanning interface to separate files.
1334 2008-04-18 Johan Dahlin <johan@gnome.org>
1336 * tools/g-ir-scanner (Parameter.__init__): Start constructing
1338 - Add support for struct/parameter/return, start parsing of ctypes
1340 * giscanner/giscannermodule.c: wrap GISourceType.child_list and
1343 2008-03-31 Johan Dahlin <johan@gnome.org>
1345 * tools/g-ir-scanner:
1346 Start to build abstract syntax node of scanned sources.
1347 Add support for cpp options.
1349 2008-03-27 Johan Dahlin <johan@gnome.org>
1351 * giscanner/giscannermodule.c:
1352 * giscanner/scannerlexer.l:
1353 * giscanner/sourcescanner.c:
1354 * tools/g-ir-scanner:
1356 Add simple pre-processor using subprocess and a PIPE.
1357 Change the parse_file apis to accept a file descriptor.
1359 2008-03-25 Johan Dahlin <johan@gnome.org>
1361 * giscanner/__init__.py:
1362 * tools/g-ir-scanner:
1363 Fix a typo and add an example python test program.
1365 2008-03-25 Johan Dahlin <johan@gnome.org>
1367 * giscanner/__init__.py:
1368 * giscanner/giscannermodule.c:
1369 * giscanner/sourcescanner.c:
1370 * giscanner/sourcescanner.h:
1371 Add constants and wrap a few more SymbolType fields
1373 2008-03-25 Johan Dahlin <johan@gnome.org>
1377 * giscanner/__init__.py:
1378 * giscanner/giscannermodule.c:
1379 * giscanner/Makefile.am:
1381 Add initial python bindings for the scanner and
1382 depend on python 2.5.
1384 2008-03-25 Johan Dahlin <johan@gnome.org>
1388 * giscanner/Makefile.am:
1389 * giscanner/sourcescanner.c:
1390 * giscanner/sourcescanner.h:
1391 * tools/Makefile.am:
1392 * tools/grealpath.h:
1393 * tools/sourcescanner.c:
1394 * tools/sourcescanner.h:
1396 Move the scanner to a separate library.
1398 2008-03-23 Johan Dahlin <johan@gnome.org>
1400 * tools/Makefile.am:
1403 * tools/scannerlexer.l:
1404 * tools/scannerparser.y:
1405 * tools/sourcescanner.c:
1406 * tools/sourcescanner.h:
1407 Split out the source scanner from the generator.
1408 Rename the symbols used in the scanner to use the gi_ prefix.
1409 This should make it possible to use the raw C parser from
1412 2008-03-23 Johan Dahlin <johan@gnome.org>
1414 * tests/parser/Makefile.am (utility.gidl):
1415 * tests/parser/utility-expected.gidl:
1416 Pass in the gobject.gidl since we're defining a GObject.
1418 2008-03-12 Johan Dahlin <johan@gnome.org>
1420 * relaxng/relaxng.rng:
1421 Add a releaxng in relaxng we can use to validate the relaxngs
1424 2008-03-12 Jürg Billeter <j@bitron.ch>
1426 * tools/scanner.c: (g_igenerator_new):
1427 * tools/scannerparser.y:
1428 Fix compiler warnings.
1430 2008-03-12 Jürg Billeter <j@bitron.ch>
1434 * tools/scannerparser.y:
1435 Start fixing memory management in g-idl-scanner.
1437 2008-03-12 Rob Taylor <rob.taylor@codethink.co.uk>
1439 * tools/gidlcompilercontext.c: (write_compiled):
1440 Fix critical warning when no shlib passed to g-idl-compiler.
1442 2008-03-12 Johan Dahlin <johan@gnome.org>
1444 * tests/parser/utility-expected.gidl:
1445 * tests/parser/utility.h:
1446 Add a get_type-function, so the scanner actually
1447 parses it as an object.
1449 2008-03-12 Johan Dahlin <johan@gnome.org>
1451 * tools/gidlwriter.c (function_generate): Add missing trailing quote.
1454 * tests/parser/Foo-expected.gidl:
1455 * tests/parser/Makefile.am:
1456 * tests/parser/foo-object.h:
1457 * tests/parser/foo.c:
1458 * tests/parser/utility-expected.gidl:
1459 * tests/parser/utility.c:
1460 * tests/parser/utility.h:
1462 Add a new gidl test. 'utility.gidl', which is used to be able
1463 to test external type references. Add a reference to UtilityObject*
1466 2008-03-11 Johan Dahlin <johan@gnome.org>
1470 Remove most global variables
1472 2008-03-11 Philip Van Hoof <me@pvanhoof.be>
1474 * tools/scannerlexer.l:
1476 * tests/parser/Foo-expected.gidl:
1477 * tests/parser/foo.c:
1478 * tests/parser/Makefile.am:
1479 * tests/parser/foo-object.h:
1481 Added a few extra tests. Which resulted in finding a few
1482 bugs. Which resulted in me fixing those bugs
1484 2008-03-11 Rob Taylor <rob.taylor@codethink.co.uk>
1486 * tools/gidlcompilercontext.c: (g_idl_compiler_write_dir_entry),
1487 (g_idl_compiler_write_xref_entry), (g_idl_compiler_add_xref):
1488 Add some comments for strings into generated output for
1491 2008-03-11 Rob Taylor <rob.taylor@codethink.co.uk>
1493 * tools/gidlcompilercontext.c: (write_compiled):
1494 Write out the shlibs variable before writing out the strings
1495 length. Fixes compiler warning when using '-l' flag with
1498 2008-03-11 Johan Dahlin <johan@gnome.org>
1500 * tests/parser/Foo-expected.gidl:
1501 * tests/parser/foo-object.h:
1504 * tools/scannerlexer.l:
1505 Add support for parsing return arguments. Add support for
1506 caller-owns return types.
1507 Patch by Philip Van Hoof.
1509 * tools/scannerparser.y:
1510 Remove parsing of the @deprecated syntax used in headers.
1511 We will support gtk-doc deprecation in the future instead.
1513 2008-03-11 Johan Dahlin <johan@gnome.org>
1515 * tools/compiler.c (main): Coding style fixes
1517 2008-03-10 Johan Dahlin <johan@gnome.org>
1520 Add GCOV_LIBS to GILIBS
1522 2008-03-10 Johan Dahlin <johan@gnome.org>
1524 * tests/parser/Foo-expected.gidl:
1525 * tests/parser/foo.c:
1526 Rename null-ok to direction=out
1528 2008-03-10 Philip Van Hoof <me@pvanhoof.be>
1530 reviewed and extensively tested by Johan
1532 * tests/parser/Foo-expected.gidl:
1533 * tests/parser/foo-object.h:
1534 * tests/parser/foo.c:
1537 * tools/gidlwriter.c:
1540 * tools/scannerlexer.l:
1541 * tools/scannerparser.y:
1543 Add support for scanning for gtk-doc comments inside
1544 C source files. Add tests
1546 2008-03-10 Johan Dahlin <johan@gnome.org>
1548 * tests/parser/Makefile.am:
1549 * tests/parser/foo.c:
1552 * tools/scannerparser.y:
1553 Add an api to lex filenames.
1554 Lex all source .c files passed in on the command line.
1555 Scan sources in a test and a couple of private structures
1556 which should not be included in the generated gidl
1558 2008-03-10 Johan Dahlin <johan@gnome.org>
1560 * tests/invoke/Makefile.am: Make the generated metadata
1561 depend on the g-idl-compiler
1563 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
1565 * tools/gidlmodule.c
1566 * tools/gidlmodule.h
1569 Remove the old g-idl-compiler code.
1572 2008-02-22 Mark Doffman <mark.doffman@codethink.co.uk>
1574 * tools/quote-file.sh
1577 Move to using the 'C' struct compiler code.
1579 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
1581 * girepository/ginfo.c
1583 Change the way that external references with no namespace
1584 are dealt with. External references with no namespace
1585 are placed into the XML as-if they are a local reference.
1586 This is temporary, but helps with roundtrip tests.
1588 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
1590 * girepository/ginfo.c
1591 Add the ability to get the value of a constant of
1592 type TYPE_TAG_SYMBOL. In the case of a symbol the value
1593 is provided as a string.
1595 This would deal properly with:
1596 typedef char* random;
1597 const random = "A string";
1599 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
1601 * girepository/ginfo.c
1602 * girepository/girepository.h
1604 Add a function to check if an enum is registered or not.
1605 Previously anything testing this relied on the g-type
1606 string offset having a value of 0.
1608 * girepository/gmetadata.c
1609 * girepository/gmetadata.h
1611 Remove unneccesary or erroneous checks. There were two
1612 metadata validation checks which made sure that the blob
1613 sizes were the same as some magic numbers compiled into the code.
1614 This is wrong as it breaks any forwards compatibility that may
1617 Checks were also present that made sure that unregistered type
1618 blobs had a value of 0 in the g-type offset field. This is
1619 unneccessary. If a type blob is unregistered then any value
1620 in its g-type field is simply invalid.
1622 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
1624 * girepository/ginfo.c
1625 * girepository/gmetadata.c
1626 * girepository/gmetadata.h
1628 Change the metadata format to have a standard header
1629 for all the type blobs. Merge the SimpleTypeBlob
1630 and InterfaceTypeBlob into a union. A union of these
1631 two blobs existed previously but was not explicit
1632 in the metadata format.
1634 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
1636 * tools/gidlcompilercontext.c
1637 * tools/gidlcompilercontext.h
1638 * tools/gidlcompilerentrynode.c
1639 * tools/gidlcompilerentrynode.h
1640 * tools/gidlcompilertypenode.c
1641 * tools/gidlcompilertypenode.h
1643 Add code to compile a tree of GIdlNodes to
1644 a 'C' struct representing the metadata.
1645 This is to aid cross-compiling. Previously
1646 the g-idl-compiler created a binary blob with
1647 data written in the byte order and alignment
1648 of the tool rather than the intended target.
1650 Cleaned up and improved by Johan and Robert :-)
1652 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
1654 * girepository/ginvoke.c
1655 * girepository/girepository.h
1656 * girepository/gmetadata.c
1657 * girepository/gmetadata.h
1659 * tools/gidlparser.c
1660 Modify TYPE_TAG_INTERFACE to TYPE_TAG_SYMBOL
1661 to avoid confusion with the interface blob.
1664 * tools/gidlparser.c
1665 Remove magic numbers and replace with type-tag
1666 enumeration symbols.
1668 * girepository/gmetadata.c
1669 Add validate declaration.
1671 2008-03-10 Jürg Billeter <j@bitron.ch>
1673 * tools/gidlparser.c: (parse_type_internal):
1674 * tools/scannerlexer.l:
1675 * tools/scannerparser.y:
1676 Support C99 _Bool type in scanner.
1678 2008-03-10 Jürg Billeter <j@bitron.ch>
1680 * tests/parser/Foo-expected.gidl:
1681 * tests/parser/foo-object.h:
1682 * tests/parser/foo.c: (foo_enum_method):
1683 * tools/scanner.c: (g_igenerator_process_function_symbol):
1684 Don't skip functions that are defined in the namespace of a type
1685 that doesn't support methods, as for example enums.
1687 2008-03-10 Johan Dahlin <johan@gnome.org>
1689 * gidl.dtd: Remove, we're using relaxng for now
1691 * tests/parser/Foo-expected.gidl:
1692 * tests/parser/foo-object.h:
1693 * tests/parser/foo.c:
1694 Rename the enum/flags get_type functions to include the whole type.
1696 2008-03-08 Marc-Andre Lureau <marcandre.lureau@gmail.com>
1698 * tools/gidlwriter.c (enum_generate): added "type-name",
1699 "get-type" and "deprecated" missing arguments.
1700 * tests/parser/Foo-expected.gidl:
1701 * tests/parser/foo-object.h: test enum type, and no type.
1703 2008-03-06 Johan Dahlin <jdahlin@async.com.br>
1706 Consistent checks, add missing 'test'
1708 2008-03-05 Havoc Pennington <hp@redhat.com>
1710 * configure.ac: Take advantage of a libffi.pc if one exists, as it
1711 does on Fedora 8. Make libffi a hard requirement, since it was in
1712 practice anyway (was not really conditional in the code or
1713 makefile, only in configure).
1715 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
1717 reviewed by: Rob Taylor <rob.taylor@codethink.co.uk>
1718 reviewed by: Johan Dahlin <johan@gnome.org>
1720 * tests/Makefile.am:
1721 * tests/roundtrips.sh:
1722 Modify the roundtrips test so that they do not use the
1723 --raw option of the gidl compiler but instead compile a
1724 shared library to use with g_module.
1726 * tests/invoke/Makefile.am:
1727 * tests/invoke/invoke.c:
1728 Modify the invoke tests to build a shared library rather
1729 than use the --raw option.
1731 * tests/invoke/invoke-namespace-find.sh: Removed:
1732 Noone knows why this was here, so removed.
1734 2008-02-19 Rob Taylor <rob.taylor@codethink.co.uk>
1736 * tools/scanner.c: (g_igenerator_process_function_symbol):
1737 Move g_idl_node_can_have_member test later, as it broke spotting
1738 get_type's for nodes that can't have members.
1740 2008-02-18 Rob Taylor <rob.taylor@codethink.co.uk>
1743 * tools/gidlnode.c: (g_idl_node_can_have_member):
1744 Add g_idl_node_can_have_member.
1746 * tools/scanner.c: (g_igenerator_process_function_symbol):
1747 Use g_idl_node_can_have_member to test if we should add a function
1748 as a member of the type node.
1750 2008-02-18 Rob Taylor <rob.taylor@codethink.co.uk>
1752 * gidl/GLib.gidl: Renamed to gidl/gobject-2.0.gidl:
1754 * tests/parser/Makefile.am:
1755 Rename GLib.gidl to gobject-2.0.gidl and install in /usr/share/gidl.
1757 2008-02-18 Rob Taylor <rob.taylor@codethink.co.uk>
1759 * tools/scanner.c: (main):
1760 Ignore -pthread when passed to g-idl-scanner.
1762 2008-02-18 Rob Taylor <rob.taylor@codethink.co.uk>
1764 * tools/grealpath.h: Added:
1765 * tools/scanner.c: (main):
1766 * tools/scannerlexer.l:
1767 * tools/Makefile.am:
1768 Always use absolute paths with symbolic links resolved when
1769 comparing filenames.
1771 2008-02-18 Rob Taylor <rob.taylor@codethink.co.uk>
1773 * gobject-introspection.pc.in:
1774 Provide variables for g-idl-parser, scanner and compiler in the
1777 2008-02-13 Rob Taylor <rob.taylor@codethink.co.uk>
1780 * girepository/Makefile.am:
1781 * tools/Makefile.am:
1782 Rename GCOV_SOURCES to GCOVSOURCES to top automake complaining.
1784 2008-02-10 Johan Dahlin <johan@gnome.org>
1786 * tests/parser/Foo-expected.gidl:
1787 * tests/parser/foo-object.h:
1788 * tests/parser/foo.c: (foo_boxed_copy), (foo_boxed_free),
1789 (foo_boxed_get_type), (foo_boxed_new), (foo_boxed_method):
1792 2008-02-10 Johan Dahlin <johan@gnome.org>
1794 * tests/parser/Foo-expected.gidl:
1795 * tests/parser/foo-object.h:
1796 * tests/parser/foo.c: (foo_enum_get_type), (foo_flags_get_type):
1797 Add enum and flags test.
1799 2008-02-10 Johan Dahlin <johan@gnome.org>
1803 * girepository/Makefile.am:
1804 Make 'make distcheck' work again.
1806 2008-02-10 Johan Dahlin <johan@gnome.org>
1808 * m4/Makefile.am (EXTRA_DIST): its called as-compiler-flag.m4,
1811 * tests/parser/Makefile.am: Only create Foo.gidl when running make
1812 check, eg exclude it from BUILT_SOURCES.
1814 2008-02-08 Rob Taylor <rob.taylor@codethink.co.uk>
1819 * girepository/Makefile.am:
1820 * m4/Makefile.am: Added:
1821 * m4/as-compiler-flag.m4: Added:
1822 * m4/gcov.m4: Added:
1823 * tools/Makefile.am:
1824 Add ability to generate a coverage report.
1825 Adds configure option --enable-gcov and make rule 'check-coverage'.
1827 2008-02-08 Rob Taylor <rob.taylor@codethink.co.uk>
1831 * gidl/Makefile.am: Added:
1832 * girepository/Makefile.am: Added:
1833 * src/Makefile.am: Renamed to tools/Makefile.am:
1834 * src/compiler.c: Renamed to tools/compiler.c:
1835 * src/g-idl-offsets.pl: Renamed to tools/g-idl-offsets.pl:
1836 * src/generate.c: Renamed to tools/generate.c:
1837 * src/gidlmodule.c: Renamed to tools/gidlmodule.c:
1838 * src/gidlmodule.h: Renamed to tools/gidlmodule.h:
1839 * src/gidlnode.c: Renamed to tools/gidlnode.c:
1840 * src/gidlnode.h: Renamed to tools/gidlnode.h:
1841 * src/gidlparser.c: Renamed to tools/gidlparser.c:
1842 * src/gidlparser.h: Renamed to tools/gidlparser.h:
1843 * src/gidlwriter.c: Renamed to tools/gidlwriter.c:
1844 * src/gidlwriter.h: Renamed to tools/gidlwriter.h:
1845 * src/ginfo.c: Renamed to girepository/ginfo.c:
1846 * src/ginvoke.c: Renamed to girepository/ginvoke.c:
1847 * src/girepository.c: Renamed to girepository/girepository.c:
1848 * src/girepository.h: Renamed to girepository/girepository.h:
1849 * src/gmetadata.c: Renamed to girepository/gmetadata.c:
1850 * src/gmetadata.h: Renamed to girepository/gmetadata.h:
1851 * src/scanner.c: Renamed to tools/scanner.c:
1852 * src/scanner.h: Renamed to tools/scanner.h:
1853 * src/scannerlexer.l: Renamed to tools/scannerlexer.l:
1854 * src/scannerparser.y: Renamed to tools/scannerparser.y:
1855 * tests/invoke/Makefile.am:
1856 Split src/ into girepository/ and tools/
1860 * girepository/Makefile.am:
1861 * tests/Makefile.am:
1862 * tests/invoke/Makefile.am:
1863 * tests/parser/Makefile.am:
1864 * tests/roundtrips.sh:
1865 * tools/Makefile.am:
1866 Make distcheck work.
1868 2008-02-04 Rob Taylor <rob.taylor@codethink.co.uk>
1870 * tests/invoke/invoke.c: (main):
1871 * tests/invoke/testfns.c: (test6), (test7):
1872 * tests/invoke/testfns.xml:
1873 Add tests for invokation with a GList argument.
1874 Also tests caller-owns return values.
1876 2008-02-04 Rob Taylor <robtaylor@floopily.org>
1879 Add some documentation for GICallableInfo
1881 2008-02-01 Mark Doffman <mark.doffman@codethink.co.uk>
1884 Correct syntax errors in the DTD file.
1886 * relaxng/c-types.xml:
1887 * relaxng/g-types.xml:
1889 Add a RelaxNG specification for the GObject Introspection XML data.
1890 The Specification has validated all of the test files.
1892 2008-01-25 Rob Taylor <robtaylor@floopily.org>
1894 * tests/roundtrips.sh:
1895 * tests/struct.test:
1896 Add roundtrip tests for structs.
1898 2008-01-11 Johan Dahlin <johan@gnome.org>
1900 * src/scanner.c (g_igenerator_process_function_symbol):
1901 Refactor out g_idle_node_add_member.
1902 (create_node_from_gtype, create_node_from_ctype):
1903 Use case instead of if...else
1904 (get_type_from_type_id):
1905 Rename to create_node_from_gtype
1906 (get_type_from_ctype):
1907 Rename to create_node_from_ctype
1909 Rename ginode -> node, gitype -> type, gifunc -> func.
1911 * src/gidlnode.c (g_idl_node_add_member, g_idl_node_cmp):
1912 Two new functions, refactor out of scanner.c
1914 * src/scanner.c: (g_igenerator_process_function_symbol):
1915 * src/scannerlexer.l:
1916 Do not save the content of the deprecated variable, only
1919 2008-01-11 Johan Dahlin <johan@gnome.org>
1921 * tests/parser/foo-object.h: Add a couple of comment parser tests.
1923 2008-01-11 Jürg Billeter <j@bitron.ch>
1925 * src/scannerlexer.l:
1926 Fix GTK-Doc parsing.
1928 2008-01-11 Jürg Billeter <j@bitron.ch>
1930 * src/scannerlexer.l:
1931 Fix GTK-Doc parsing.
1933 2008-01-11 Jürg Billeter <j@bitron.ch>
1935 * src/scanner.c: (lookup_symbol):
1936 Return unresolved name if we find unknown symbol.
1938 2008-01-11 Jürg Billeter <j@bitron.ch>
1940 * src/scanner.c: (g_igenerator_generate):
1941 Initialize GObject to fix scanning interface properties.
1943 * tests/parser/Foo-expected.gidl:
1944 * tests/parser/foo-object.h:
1945 * tests/parser/foo.c: (foo_interface_get_type):
1946 Test interfaces with GObject prerequisite.
1948 * tests/parser/Makefile.am:
1949 Set G_DEBUG=fatal_warnings to abort test on warnings and criticals.
1951 2007-12-27 Johan Dahlin <johan@gnome.org>
1953 * src/scannerlexer.l:
1954 Parse gtk-doc comments.
1956 * src/gidlwriter.c: (function_generate):
1957 Reorganize, avoid duplication and add support for
1958 writing deprecated functions.
1960 * src/scannerparser.y:
1962 Add new structure CDirective and functions to create/free them.
1964 * src/scanner.c: (g_igenerator_process_function_symbol),
1965 (g_igenerator_process_unregistered_struct_typedef),
1966 (g_igenerator_process_struct_typedef),
1967 (g_igenerator_process_union_typedef),
1968 (g_igenerator_process_enum_typedef),
1969 (g_igenerator_process_function_typedef), (g_igenerator_add_symbol),
1970 (g_igenerator_start_preprocessor):
1971 Parse @deprecated directive for functions.
1972 Remove some more C99isms.
1973 Send in -C to cpp to avoid stripping comments.
1975 * tests/parser/foo-object.h:
1976 * tests/parser/Foo-expected.gidl:
1977 Add deprecated directive
1979 2007-12-27 Johan Dahlin <johan@gnome.org>
1981 * src/scannerlexer.l (intsuffix): Add emacs mode line and
1982 escape ' and " so it looks more like C.
1985 Unlink temporary file used.
1987 2007-12-27 Johan Dahlin <johan@gnome.org>
1989 * src/scanner.c: (g_igenerator_new), (g_igenerator_free),
1990 (g_igenerator_start_preprocessor), (main):
1992 * src/scannerparser.y:
1993 Plug a couple of simple memory leaks.
1995 2007-12-27 Johan Dahlin <johan@gnome.org>
1997 * src/scanner.c: (g_igenerator_parse_macros),
1998 (g_igenerator_start_preprocessor), (g_igenerator_set_verbose),
2001 * src/scannerparser.y:
2002 * tests/parser/Makefile.am:
2004 Improve error reporting, return when the preprocessor fails.
2005 Add a verbose parameter, to aid debugging.
2006 Revert to using a temporary file to communicate between the
2007 preprocessor and the parser, because we need to wait for
2008 the exit code from the pre-processor before starting to parse.
2010 2007-12-16 Johan Dahlin <jdahlin@async.com.br>
2012 * src/Makefile.am: Rename clexer.l to scannerlexer.l and
2013 cparser.y to scannerparser.y
2015 2007-12-11 Johan Dahlin <johan@gnome.org>
2019 * src/scanner.c: (g_igenerator_new):
2021 Get rid of the global the_generator variable.
2023 2007-12-10 Johan Dahlin <johan@gnome.org>
2025 * src/scanner.c (main): Add an output option,
2026 add checks for required parameters
2029 set BUILD_SOURCES and CLEANFILES properly
2031 * src/gidlwriter.c: (g_writer_write_inline), (g_writer_write),
2032 (g_writer_write_indent), (g_writer_write_unindent),
2033 (field_generate), (value_generate), (constant_generate),
2034 (property_generate), (function_generate), (vfunc_generate),
2035 (signal_generate), (interface_generate), (struct_generate),
2036 (union_generate), (boxed_generate), (enum_generate),
2037 (node_generate), (g_writer_write_module), (g_idl_writer_save_file):
2039 * src/scanner.c: (g_igenerator_generate):
2041 * src/scannerwriter.c:
2043 Refactor scannerwriter to only be tied to a GIdlModule and move
2044 it (again!) to gidlwriter.c. Change the writer function to take
2047 2007-12-10 Johan Dahlin <johan@gnome.org>
2050 * src/scanner.c: (g_igenerator_generate):
2052 * src/scannerwriter.c: (g_igenerator_write_inline),
2053 (g_igenerator_write), (g_igenerator_write_indent),
2054 (g_igenerator_write_unindent), (field_generate), (value_generate),
2055 (constant_generate), (property_generate), (function_generate),
2056 (vfunc_generate), (signal_generate), (interface_generate),
2057 (struct_generate), (union_generate), (boxed_generate),
2058 (enum_generate), (node_generate), (module_generate),
2059 (g_scanner_write_file):
2061 Move the scanner gidl writing to a separate source file.
2063 2007-12-10 Johan Dahlin <johan@gnome.org>
2068 Move over all CType construction functions.
2070 * tests/parser/Makefile.am:
2071 Be verbose when printing parsing tests results.
2073 2007-12-10 Johan Dahlin <johan@gnome.org>
2075 * src/scanner.c (g_igenerator_start_preprocessor): Refactor
2076 preprocessor handling to here. Start cpp insteado of cc -E,
2077 always include -U__GNUC__, since it's specific to the preprocessor
2080 * tests/parser/Makefile.am (check-local): Silent diff and skip
2081 -U__GNUC__ which is always defined now
2083 2007-12-10 Johan Dahlin,,, <jdahlin@plasttroll>
2085 reviewed by: <delete if not using a buddy>
2087 * src/scanner.c: (g_igenerator_start_preprocessor), (main):
2088 * tests/parser/Makefile.am:
2090 2007-12-09 Johan Dahlin <johan@gnome.org>
2093 Use GOption for command line options.
2094 (g_igenerator_new, main): Simplify constructor and they way
2095 parameters are passed into it.
2101 * src/gen-introspect.c:
2102 * src/gen-introspect.h:
2104 Rename gen-introspect.[ch] to scanner.[ch]
2106 2007-12-09 Johan Dahlin <johan@gnome.org>
2110 * src/Makefile.am: Rename gen-introspect to g-idl-scanner,
2111 don't make the repository library and the other utilites link against
2114 * src/gen-introspect.c: (g_igenerator_create_object),
2115 (g_igenerator_create_interface), (g_igenerator_create_boxed),
2116 (g_igenerator_create_enum), (g_igenerator_create_flags),
2117 (g_igenerator_process_module_symbol),
2118 (g_igenerator_process_module), (g_igenerator_generate), (main):
2119 * src/gen-introspect.h:
2120 Refactor g_igenerator_process_types into smaller pieces.
2122 * tests/parser/Makefile.am:
2123 Depend on the gen-introspect binary
2125 2007-12-09 Johan Dahlin <johan@gnome.org>
2127 * src/gen-introspect.c (g_igenerator_process_types):
2128 Break into smaller pieces, one for each generated node type.
2130 2007-12-08 Johan Dahlin <johan@gnome.org>
2132 * src/gen-introspect.c: (g_igenerator_process_types),
2133 (g_igenerator_add_module):
2134 * tests/parser/Foo-expected.gidl:
2135 * tests/parser/foo-object.h:
2136 * tests/parser/foo.c: (foo_subobject_class_init),
2137 (foo_subobject_init):
2139 Add a subobject test and make sure to register defined classes
2140 in the lookup symbol hash table.
2142 2007-12-08 Johan Dahlin <johan@gnome.org>
2146 * src/gen-introspect.c: (g_igenerator_new), (lookup_symbol),
2147 (g_igenerator_process_types), (g_igenerator_add_module),
2148 (g_igenerator_add_include_idl), (main):
2149 * src/gen-introspect.h:
2150 * tests/parser/Makefile.am:
2151 * tests/parser/Foo-expected.gidl:
2153 Change the gen-introspect to generate namespaced module names,
2154 such as GLib.Object instead of GObject.
2155 Add a GLib.gidl which introduces GLib.Object and GLib.InitiallyUnowned,
2156 add a --include-idl parameter to gen-introspect,
2157 and update the parser test.
2159 2007-12-08 Johan Dahlin <johan@gnome.org>
2161 * src/gen-introspect.c:
2162 Move main to the end of the file and attempt to make it valid
2165 * tests/parser/Makefile.am (BUILT_SOURCES): Remove .repo here,
2166 we're not quite ready to generate metadata yet.
2171 Add a simple gen-introspect parser test
2173 2007-12-06 Gustavo J. A. M. Carneiro <gjc@gnome.org>
2175 reviewed by: Johan Dahlin <johan@gnome.org>
2178 * gobject-introspection.pc.in:
2180 * src/compiler.c: (format_output), (write_out_metadata), (main):
2181 * src/gen-introspect.c: (main):
2182 * src/gen-introspect.h:
2183 * src/generate.c: (write_callable_info), (write_repository),
2184 (load_metadata), (main):
2185 * src/gidlmodule.c: (g_idl_module_new),
2186 (g_idl_module_build_metadata):
2188 * src/gidlparser.c: (start_element_handler):
2189 * src/ginfo.c: (g_info_new), (g_info_from_entry),
2190 (g_base_info_get_name), (g_base_info_get_namespace),
2191 (g_base_info_is_deprecated), (g_base_info_get_annotation),
2192 (g_base_info_get_metadata), (g_function_info_get_symbol),
2193 (g_function_info_get_flags), (g_function_info_get_property),
2194 (g_function_info_get_vfunc), (signature_offset), (g_type_info_new),
2195 (g_callable_info_may_return_null),
2196 (g_callable_info_get_caller_owns), (g_callable_info_get_n_args),
2197 (g_callable_info_get_arg), (g_arg_info_get_direction),
2198 (g_arg_info_is_return_value), (g_arg_info_is_dipper),
2199 (g_arg_info_is_optional), (g_arg_info_may_be_null),
2200 (g_arg_info_get_ownership_transfer), (g_type_info_is_pointer),
2201 (g_type_info_get_tag), (g_type_info_get_param_type),
2202 (g_type_info_get_interface), (g_type_info_get_array_length),
2203 (g_type_info_is_zero_terminated),
2204 (g_type_info_get_n_error_domains), (g_type_info_get_error_domain),
2205 (g_error_domain_info_get_quark), (g_error_domain_info_get_codes),
2206 (g_value_info_get_value), (g_field_info_get_flags),
2207 (g_field_info_get_size), (g_field_info_get_offset),
2208 (g_registered_type_info_get_type_name),
2209 (g_registered_type_info_get_type_init),
2210 (g_struct_info_get_n_fields), (g_struct_info_get_field),
2211 (g_struct_info_get_n_methods), (g_struct_info_get_method),
2212 (find_method), (g_struct_info_find_method),
2213 (g_enum_info_get_n_values), (g_enum_info_get_value),
2214 (g_object_info_get_parent), (g_object_info_get_type_name),
2215 (g_object_info_get_type_init), (g_object_info_get_n_interfaces),
2216 (g_object_info_get_interface), (g_object_info_get_n_fields),
2217 (g_object_info_get_field), (g_object_info_get_n_properties),
2218 (g_object_info_get_property), (g_object_info_get_n_methods),
2219 (g_object_info_get_method), (g_object_info_find_method),
2220 (g_object_info_get_n_signals), (g_object_info_get_signal),
2221 (g_object_info_get_n_vfuncs), (g_object_info_get_vfunc),
2222 (g_object_info_get_n_constants), (g_object_info_get_constant),
2223 (g_interface_info_get_n_prerequisites),
2224 (g_interface_info_get_prerequisite),
2225 (g_interface_info_get_n_properties),
2226 (g_interface_info_get_property), (g_interface_info_get_n_methods),
2227 (g_interface_info_get_method), (g_interface_info_find_method),
2228 (g_interface_info_get_n_signals), (g_interface_info_get_signal),
2229 (g_interface_info_get_n_vfuncs), (g_interface_info_get_vfunc),
2230 (g_interface_info_get_n_constants),
2231 (g_interface_info_get_constant), (g_property_info_get_flags),
2232 (g_signal_info_get_flags), (g_signal_info_get_class_closure),
2233 (g_signal_info_true_stops_emit), (g_vfunc_info_get_flags),
2234 (g_vfunc_info_get_offset), (g_vfunc_info_get_signal),
2235 (g_constant_info_get_value), (g_union_info_get_n_fields),
2236 (g_union_info_get_field), (g_union_info_get_n_methods),
2237 (g_union_info_get_method), (g_union_info_is_discriminated),
2238 (g_union_info_get_discriminator_offset),
2239 (g_union_info_get_discriminator):
2240 * src/ginvoke.c: (g_function_info_invoke):
2241 * src/girepository.c: (g_irepository_register),
2242 (g_irepository_unregister), (g_irepository_get_default),
2243 (count_interfaces), (g_irepository_get_n_infos), (find_interface),
2244 (g_irepository_get_info), (g_irepository_find_by_name),
2245 (g_irepository_get_shared_library),
2246 (g_irepository_build_search_path), (g_irepository_register_file),
2247 (g_irepository_error_quark):
2248 * src/girepository.h:
2249 * src/gmetadata.c: (g_metadata_get_dir_entry),
2250 (g_metadata_check_sanity), (validate_header),
2251 (validate_array_type_blob), (validate_iface_type_blob),
2252 (validate_param_type_blob), (validate_error_type_blob),
2253 (validate_type_blob), (validate_arg_blob),
2254 (validate_signature_blob), (validate_function_blob),
2255 (validate_callback_blob), (validate_constant_blob),
2256 (validate_value_blob), (validate_field_blob),
2257 (validate_property_blob), (validate_signal_blob),
2258 (validate_vfunc_blob), (validate_struct_blob),
2259 (validate_enum_blob), (validate_object_blob),
2260 (validate_interface_blob), (validate_errordomain_blob),
2261 (validate_union_blob), (validate_blob), (validate_directory),
2262 (validate_annotations), (g_metadata_validate), (_g_metadata_init),
2263 (g_metadata_new_from_memory), (g_metadata_new_from_const_memory),
2264 (g_metadata_new_from_mapped_file), (g_metadata_free),
2265 (g_metadata_set_module), (g_metadata_get_namespace):
2267 * tests/Makefile.am:
2268 * tests/invoke/Makefile.am:
2269 * tests/invoke/invoke-namespace-find.sh:
2270 * tests/invoke/invoke.c: (main):
2272 Add a namespace/shared library mapping. fixes #313268.
2274 2007-12-03 Johan Dahlin <johan@gnome.org>
2276 * src/gidlparser.c (parse_type_internal): Disable char/gchar and
2279 2007-11-30 Jürg Billeter <j@bitron.ch>
2285 * src/gen-introspect.c: (g_idl_node_cmp), (g_igenerator_new),
2286 (g_igenerator_write_inline), (g_igenerator_write),
2287 (g_igenerator_write_indent), (g_igenerator_write_unindent),
2288 (field_generate), (value_generate), (constant_generate),
2289 (property_generate), (function_generate), (vfunc_generate),
2290 (signal_generate), (interface_generate), (struct_generate),
2291 (union_generate), (boxed_generate), (enum_generate),
2292 (node_generate), (module_generate), (get_type_from_type_id),
2293 (str_replace), (g_igenerator_process_properties),
2294 (g_igenerator_process_signals), (g_igenerator_process_types),
2295 (get_type_from_ctype), (g_igenerator_process_function_symbol),
2296 (g_igenerator_process_unregistered_struct_typedef),
2297 (g_igenerator_process_struct_typedef),
2298 (g_igenerator_process_union_typedef),
2299 (g_igenerator_process_enum_typedef),
2300 (g_igenerator_process_function_typedef),
2301 (g_igenerator_process_constant), (g_igenerator_process_symbols),
2302 (g_igenerator_add_symbol), (g_igenerator_is_typedef),
2303 (g_igenerator_generate), (main), (csymbol_new),
2304 (csymbol_get_const_boolean), (ctype_new), (ctype_copy),
2305 (cbasic_type_new), (ctypedef_new), (cstruct_new), (cunion_new),
2306 (cenum_new), (cpointer_new), (carray_new), (cfunction_new),
2307 (eat_hspace), (eat_line), (read_identifier),
2308 (g_igenerator_parse_macros):
2309 * src/gen-introspect.h:
2311 Import gen-introspect to generate introspection information by
2314 2007-11-30 Jürg Billeter <j@bitron.ch>
2316 * src/gidlnode.c: (g_idl_node_new): support creating callback nodes
2318 2007-11-30 Jürg Billeter <j@bitron.ch>
2320 * src/gidlparser.c: (end_element_handler): Don't leave requires
2323 2007-11-29 Johan Dahlin <johan@gnome.org>
2325 * src/gidlparser.c (parse_type_internal): Add char,
2326 gchar and guchar to the builtin types.
2328 2007-11-26 Johan Dahlin <johan@gnome.org>
2330 * src/ginfo.c: (g_object_info_get_type_name),
2331 (g_object_info_get_type_init):
2332 * src/girepository.c: (g_irepository_is_registered):
2333 * src/girepository.h:
2335 Add g_object_info_get_type_name, g_object_info_get_type_init and
2336 g_irepository_is_registered.
2338 2006-08-14 Jürg Billeter <j@bitron.ch>
2340 * src/gidlparser.c: (end_element_handler): Don't leave
2341 namespace and implements states too early.
2344 2007-11-26 Johan Dahlin <johan@gnome.org>
2346 * src/gmetadata.c (validate_struct_blob):
2347 pass blob_type to validate_function_blob instead of
2348 hard-coding BLOB_TYPE_STRUCT.
2350 Patch by Torsten Schoenfeld, fixes #314190
2352 2006-10-03 Torsten Schoenfeld <tsch@cvs.gnome.org>
2354 * src/compiler.c, src/generate.c, src/gidlnode.c,
2355 src/gidlparser.c, src/ginfo.c, src/girepository.c,
2356 tests/invoke/invoke.c, test/invoke/testfns.c: Hush compiler
2357 warnings about return values, signedness mismatches, unused
2358 variables, and unhandles enum values in switch statements.
2360 * tests/invoke/Makefile.am: Don't install the invoke test program.
2361 Add -I ../../src to the cflags used for the test functions files.
2363 2005-08-31 Torsten Schoenfeld <tsch@cvs.gnome.org>
2365 * src/girepository.h: Export g_invoke_error_quark.
2367 2005-08-31 Torsten Schoenfeld <tsch@cvs.gnome.org>
2369 * src/ginvoke.c: Remove the fallback implementation of
2370 g_function_info_invoke since we now formally depend on libffi.
2372 2005-07-25 Matthias Clasen <mclasen@redhat.com>
2374 * src/Makefile, tests/Makefile, tests/invoke/Makefile:
2375 Remove these files from cvs, as they are now generated.
2377 * src/gmetadata.c (validate_iface_type_blob): Don't
2378 complain if blob->pointer is not set, since that
2379 happens for enum and flag types. (#308935, Gustavo
2382 * Commit an autoconf-conversion patch by
2383 Gustavo Carneiro (#308708)
2385 2005-05-24 Matthias Clasen <mclasen@redhat.com>
2387 * src/compiler.c (main): Use it here to validate
2388 the generated metadata.
2390 * src/gmetadata.[hc]: Add code to validate a
2393 * metadata-format.txt: Updates
2395 2005-05-22 Matthias Clasen <mclasen@redhat.com>
2397 * tests/*: Add struct offsets to field and vfunc
2400 * src/generate.c (write_vfunc_info): Write offset
2401 information for vfuncs.
2403 * src/gidlnode.c (g_idl_node_build_metadata): Write
2404 the struct offsets into the metadata.
2406 * src/gidlparser.c: Parse the offset attributes of
2407 field and vfunc elements.
2409 * src/gidlnode.h: Add offset members to field and
2412 2005-05-21 Matthias Clasen <mclasen@redhat.com>
2416 * gidl.dtd: Updates.
2418 * src/g-idl-offsets.pl: A perl script which reads a .gidl
2419 file, creates, compiles and runs a C file, and folds the
2420 resulting struct offsets back into the .gidl file.
2422 2005-05-20 Matthias Clasen <mclasen@redhat.com>
2424 * src/gidlparser.c (start_field): Make fields in objects
2427 * src/gidlmodule.c: Include string.h
2432 * metadata-format.txt: Cleanup basic types.
2433 * src/*: Adapt to the changes.
2434 * tests/*: Adapt to the changes.
2435 * examples/gdk-pixbuf.gidl: Adapt to the changes.
2437 * src/gidlnode.c (g_idl_node_get_size): Report the correct
2438 size for enum blobs.
2439 (g_idl_node_get_full_size): Report the correct size for
2442 * src/gidlmodule.c (g_idl_module_build_metadata): Add some
2443 error checking for blob sizes.
2445 2005-05-19 Matthias Clasen <mclasen@redhat.com>
2447 * src/gidlnode.c (g_idl_node_build_metadata): Correctly handle
2448 interface types for which is_pointer is FALSE, e.g. enums.
2450 * src/gidlnode.c (g_idl_node_get_full_size)
2451 * src/gidlparser.c (parse_type_internal):
2452 * src/generate.c (write_type_info): Support unspecialized
2453 lists, hashtables and errors. Also emit a '*' after these.
2457 2005-05-17 Matthias Clasen <mclasen@redhat.com>
2461 * metadata-format.txt: Cleanups by Maciej Katafiasz.
2463 2005-05-15 Matthias Clasen <mclasen@redhat.com>
2465 * src/*.c: Change the directory to be addressed by
2466 1-based indexes, and use an index of zero to mean
2469 2005-05-15 Matthias Clasen <mclasen@redhat.com>
2471 * tests/roundtrips.sh (SIMPLE_TESTS): Add union.test.
2473 * tests/union.test: Add a union test.
2475 * src/generate.c: Handle unions.
2477 * src/girepository.h:
2478 * src/ginfo.c: Add GIUnionInfo and functions to access it.
2480 * src/gidlnode.c: Handle GIdlNodeUnion nodes.
2482 * src/gidlparser.c (start_union): Parse <union> elements.
2484 * src/gidlnode.h: Add a GIdlNodeUnion.
2486 * gidl.dtd: Add a <union> element.
2488 * src/gmetadata.c (g_metadata_check_sanity): Check
2491 * src/gmetadata.h: Add union_blob_size to Header,
2494 * metadata-format.txt: Add a UnionBlob.
2496 2005-05-13 Matthias Clasen <mclasen@redhat.com>
2498 * tests/*: Update testcases.
2500 * src/generate.c (write_callable_info): Don't forget to
2501 write transfer and null-ok attributes for return types
2504 * src/girepository.h:
2505 * src/ginfo.c (g_callable_info_may_return_null):
2506 New function to find out if a function may return NULL.
2508 * src/compiler.c (format_output): Make the generated
2511 * README: Point to a recent libffi snapshot.
2513 * tests/invoke/*: Some invoke tests.
2515 * src/Makefile: Add ginvoke.c and the necessary
2518 * src/girepository.h (g_function_info_invoke): Add
2521 * src/ginvoke.c (g_function_info_invoke): Initial
2522 implementation of invoke functionality based on libffi.
2524 * src/gidlnode.c (g_idl_node_build_metadata): Pass the
2525 strings and types hash tables in the right order when
2527 (find_entry_node): Free the name parts.
2529 2005-05-12 Johan Dahlin <johan@gnome.org>
2531 * src/generate.c: Generate consistent end tags.
2535 2005-05-12 Matthias Clasen <mclasen@redhat.com>
2539 * src/gidlparser.c (start_function): Actually add
2540 methods to objects. (Steven Walter)
2542 * src/girepository.h:
2543 * src/ginfo.c: Rename Transfer and Direction to
2544 GITransfer and GIDirection. (Torsten Schoenfeld)
2546 * tests/*: Make tests work with the changes in name
2549 * src/gidlnode.c (find_entry_node): Parse qualified
2550 names and generate xref nodes for them if needed. Don't
2551 require all modules to be loaded any more.
2553 * src/gidlmodule.c (g_idl_module_build_metadata): Choke
2556 * src/ginfo.c (g_object_info_get_parent): Return NULL
2557 if blob->parent is 0. Still need to make sure index
2560 * src/generate.c: Generate qualified names when
2561 referring to non-local types. Emit transfer attribute
2564 * src/compiler.c (format_output): Put the function
2565 attributes where gcc accepts them.
2567 2005-05-11 Matthias Clasen <mclasen@redhat.com>
2569 * src/compiler.c (main): Add a --verbose cmdline option
2570 and only log messages if it is specified.
2573 * src/gidlnode.c (init_stats, dump_stats): Collect some
2574 statistics on string and type sharing.
2576 * src/gidlmodule.c (g_idl_module_build_metadata): Use
2577 g_message() instead of fprintf().
2579 * src/gidlnode.c (g_idl_node_free): Make this more robust.
2580 (g_idl_node_get_size): Implement for structs.
2581 (g_idl_node_get_full_size): Handle parent being NULL.
2582 (serialize_type): Handle lookup failures more gracefully.
2584 2005-05-10 Matthias Clasen <mclasen@redhat.com>
2586 * src/gidlnode.c (g_idl_node_get_full_size): Correct the
2587 size calculation for 2-parameter types and for objects.
2589 * src/compiler.c: Add a cmdline option for debug output
2590 and install a log handler to implement it.
2591 * src/gidlnode.c: Add some debug spew.
2595 * src/gidlmodule.c (g_idl_module_build_metadata): Don't
2596 forget to count the module name when calculating the
2597 required size for the metadata.
2600 * src/gidlparser.c: Fix compiler warnings.
2602 2005-05-09 Matthias Clasen <mclasen@redhat.com>
2604 * src/compiler.c (main): Free the option context.
2606 * gidl.dtd: Clean up handling of names. All elements
2607 have a "name", only the elements corresponding to
2608 actual callable functions (function, method, constructor),
2609 have an additional "symbol" attribute holding the
2610 dlsym()-able function name.
2612 * src/generate.c: Adapt to generate xml matching the
2616 * src/gidlnode.c: Adapt to parse the new dtd.
2618 * tests/*.test: Adjust to the new dtd.
2620 * metadata-format.txt:
2621 * src/gmetadata.h: Remove the short_name field
2623 * src/gmetadata.c: Shrink size of ValueBlob to 12.
2624 * src/girepository.h:
2625 * src/ginfo.c (g_value_info_get_short_name): Removed
2627 2005-05-09 Matthias Clasen <mclasen@redhat.com>
2629 * gidl.dtd: Allow constructors for boxed types,
2630 patch by Jonathan Blandford.
2633 2005-05-09 Matthias Clasen <mclasen@redhat.com>
2635 * --- Initial import ---