1 2009-01-20 Johan Dahlin <jdahlin@async.com.br>
3 * giscanner/glibtransformer.py:
4 When trying to map functions to structs, do
5 not require a public structure to exist, should
6 fix Gst gir generation in.
8 2009-01-20 Johan Dahlin <jdahlin@async.com.br>
10 Bug 562615 – Struct methods missing
12 * giscanner/annotationparser.py:
14 * giscanner/girwriter.py:
15 * giscanner/glibast.py:
16 * giscanner/glibtransformer.py:
17 * tests/scanner/foo-1.0-expected.gir:
18 * tests/scanner/foo-1.0-expected.tgir:
20 2009-01-16 Dan Winship <danw@gnome.org>
22 * gir/GL-1.0.gir: add back GLvoid, which got lost during the
23 gir-repository -> gobject-introspection migration
25 2009-01-15 Johan Dahlin <jdahlin@async.com.br>
27 * gir/freetype2-2.0.gir: add FT_Int32
28 * gir/xft-2.0.gir: add XftFont
29 * girepository/gdump.c (g_irepository_dump):
30 Report errors when an invalid type is encountered
31 * giscanner/glibtransformer.py:
32 Make the error message a bit nicer.
34 Part of preparating for gir generating inside pango.
36 2009-01-15 Johan Dahlin <jdahlin@async.com.br>
41 * gir/fontconfig-2.0.gir:
42 * gir/freetype2-2.0.gir:
43 * gir/libxml2-2.0.gir:
48 Move over the hand-written girs from gir-repository
49 so upstream libraries depending on these can avoid
50 a gir-repository dependency.
52 2009-01-15 Johan Dahlin <jdahlin@async.com.br>
54 Bug 567813 – Everything should be versioned
57 * girepository/Makefile.am:
58 * girepository/girepository.c (init_globals):
59 * girepository/girparser.c (locate_gir):
60 * giscanner/dumper.py:
61 * giscanner/transformer.py:
62 * gobject-introspection-1.0.pc.in:
63 * tests/everything/Makefile.am:
64 * tests/invoke/Makefile.am:
65 * tests/offsets/Makefile.am:
66 * tests/repository/Makefile.am:
67 * tests/scanner/Makefile.am:
70 2009-01-13 Johan Dahlin <jdahlin@async.com.br>
72 Bug 555036 – put gtk-doc in GIR
74 * giscanner/annotationparser.py:
76 * giscanner/girwriter.py:
77 * giscanner/glibast.py:
78 * tests/scanner/annotation-1.0-expected.gir:
79 * tests/scanner/annotation.h:
80 * tests/scanner/foo-1.0-expected.gir:
82 2009-01-13 Johan Dahlin <jdahlin@async.com.br>
84 * giscanner/cachestore.py (CacheStore.load): Catch AttributeError
85 which seems to be occasionally raised for Record.
87 * giscanner/annotationparser.py:
88 Fix a bug where \n was not present in a comment
90 2009-01-12 Johan Dahlin <jdahlin@async.com.br>
92 Bug 562467 – Property annotation
94 * giscanner/annotationparser.py:
95 * tests/scanner/annotation-1.0-expected.gir:
96 * tests/scanner/annotation-1.0-expected.tgir:
97 * tests/scanner/annotation.c (annotation_object_set_property),
98 (annotation_object_get_property), (annotation_object_class_init):
100 Annotations are parsed for properties.
102 2009-01-12 Johan Dahlin <jdahlin@async.com.br>
104 Bug 546739 – Introspection should know precise signal parameter types
106 * giscanner/annotationparser.py:
107 * tests/scanner/annotation-1.0-expected.gir:
108 * tests/scanner/annotation-1.0-expected.tgir:
109 * tests/scanner/annotation.c (annotation_object_class_init):
111 Annotations are parsed for signals, the (type) annotation is introduced.
113 2009-01-12 Johan Dahlin <jdahlin@async.com.br>
115 Bug 563591 – Flags not recognized when there is no introspection data
118 * giscanner/girwriter.py:
119 * giscanner/giscannermodule.c (type_get_is_bitfield):
120 * giscanner/glibast.py:
121 * giscanner/glibtransformer.py:
122 * giscanner/scannerparser.y:
123 * giscanner/sourcescanner.c (gi_source_type_copy):
124 * giscanner/sourcescanner.h:
125 * giscanner/sourcescanner.py:
126 * giscanner/transformer.py:
127 * tests/scanner/foo-1.0-expected.gir:
128 * tests/scanner/foo-1.0-expected.tgir:
129 * tests/scanner/foo.h:
131 Large parts of this patch was done by Jürg Billeter.
133 2009-01-12 Havoc Pennington <hp@pobox.com>
135 Bug 563386 – scanner ignores "const" on boxed return values
137 * tests/everything/everything.c (test_simple_boxed_a_const_return):
138 * tests/everything/everything.h:
140 This adds just the tests specified in the bug above, the fix itself
141 was included in Bug 563794
143 2009-01-03 Andreas Rottmann <a.rottmann@gmx.at>
145 Bug 566404 – Annotations for GLib
147 * gir/glib-2.0.c: Added allow-none annotations for g_thread_init()
148 and g_main_loop_new().
150 2009-01-12 Johan Dahlin <jdahlin@async.com.br>
152 Bug 566419 – Element type of arrays not properly handled in all cases
154 * giscanner/annotationparser.py:
155 * tests/scanner/annotation-1.0-expected.gir:
156 * tests/scanner/annotation-1.0-expected.tgir:
157 * tests/scanner/annotation.c (annotation_object_set_data),
158 (annotation_object_set_data2), (annotation_object_set_data3):
159 * tests/scanner/annotation.h:
161 Based on patch by Andreas Rottmann
163 2009-01-12 Johan Dahlin <jdahlin@async.com.br>
165 Bug 566560 – giscanner.transformer.SkipError
167 * giscanner/transformer.py:
169 Catch SkipError for all nodes, not just functions.
170 Makes it possible to skip unsupported parameter types in
173 2009-01-12 Johan Dahlin <jdahlin@async.com.br>
175 Bug 563794 - Redo annotation parsing & applying
177 Thanks to Colin for helping out considerably in landing this.
179 * giscanner/Makefile.am:
181 * giscanner/dumper.py:
182 * giscanner/girparser.py:
183 * giscanner/giscannermodule.c (pygi_source_scanner_get_comments),
184 (calc_attrs_length), (pygi_collect_attributes), (init_giscanner):
185 * giscanner/glibtransformer.py:
186 * giscanner/scannerlexer.l:
187 * giscanner/sourcescanner.c (gi_source_symbol_unref),
188 (gi_source_scanner_new), (gi_source_scanner_free),
189 (gi_source_scanner_get_comments):
190 * giscanner/sourcescanner.h:
191 * giscanner/sourcescanner.py:
192 * giscanner/transformer.py:
193 * giscanner/xmlwriter.py:
194 * tests/scanner/annotation-1.0-expected.gir:
195 * tests/scanner/annotation-1.0-expected.tgir:
196 * tests/scanner/annotation.c:
197 * tests/scanner/annotation.h:
198 * tests/scanner/foo-1.0-expected.gir:
199 * tests/scanner/foo-1.0-expected.tgir:
200 * tests/scanner/foo.h:
201 * tools/g-ir-scanner:
203 This commit merges the annotation parser rewrite branch.
204 It'll change the annotation parsing to be done completely in python
205 code which will make it easier to do further annotation parsing
208 2009-01-03 Andreas Rottmann <a.rottmann@gmx.at>
210 Bug 563469 – Arrays not treated correctly in struct offset calculation
212 * tests/scanner/foo.h (FooObject): Added field `some_int'.
213 * tests/scanner/foo-1.0-expected.gir,
214 * tests/scanner/foo-1.0-expected.tgir: Adapted.
216 * giscanner/glibtransformer.py (GLibTransformer._create_gobject):
217 carry over object fields from original (struct) node.
218 (GLibTransformer._pair_class_struct): Don't add fields of the
219 class struct to to the node for the class, they should go under a
220 nested <record> element (see also Bug 551738). This is needed as
221 otherwise offset calculation would not work, as the instance
222 fields are mingled with the class fields without a way to
225 2009-01-03 Johan Dahlin <jdahlin@async.com.br>
228 Disable blank line check, it works differently under
229 Python 2.5 from 2.6 and was rather annoying from the start.
231 2008-01-03 Andreas Rottmann <a.rottmann@gmx.at>
233 Bug 556489 – callback annotations
235 * giscanner/transformer.py
237 * tools/generate.c (write_callable_info): Write out the new scope,
238 closure and destroy attributes.
240 * giscanner/transformer.py (Transformer._type_is_callback): New
241 method, checking if a given type is a callback.
242 (Transformer._augment_callback_params): New method; adds
243 information (closure, destroy) to callback parameters.
244 (Transformer._handle_closure, Transformer._handle_destroy): New methods,
245 auxiliary to _augment_callback_params.
246 (Transformer._create_function): Call _augment_callback_params().
247 (Transformer._create_parameter): Handle scope option.
249 (Transformer._create_typedef_callback): New method, creates a
250 callback, and registers it in the typedef namespace
251 (Transformer._create_typedef): Use _create_typedef_callback()
252 instead of the plain _create_callback().
254 * giscanner/ast.py (Parameter): Added callback-related fields.
255 * giscanner/girwriter.py: Write out new Parameter fields.
257 * girepository/girnode.h (GIrNodeParam): Added fields scope,
259 * girepository/gtypelib.h (ArgBlob): Ditto.
260 * girepository/girparser.c (start_parameter): Handle new fields.
262 * girepository/girmodule.c (g_ir_module_build_typelib): Adjust
263 arg_blob_size, bump major version due to this change.
264 * girepository/girnode.c (g_ir_node_get_full_size_internal)
265 (g_ir_node_build_typelib)
266 * girepository/gtypelib.c (g_typelib_check_sanity): ArgBlob size
268 (g_ir_node_build_typelib): Fill in new ArgBlob flags from param.
270 * girepository/girepository.h (GIScope): New enumeration, listing
271 the different possible scopes for callbacks.
273 * girepository/ginfo.c (g_arg_info_get_scope)
274 (g_arg_info_get_closure, g_arg_info_get_destroy): Accessors for
275 callback-related argument indices (callback scope, closure for a
276 callback, destroy notification for a callback).
278 * tests/scanner/: Added testcases for new features.
280 2009-01-03 Jürg Billeter <j@bitron.ch>
283 * giscanner/dumper.py:
284 * giscanner/girparser.py:
285 * giscanner/glibtransformer.py:
286 * giscanner/sourcescanner.py:
287 * giscanner/transformer.py:
288 * giscanner/xmlwriter.py:
290 Fix inconsistencies with PEP8
292 2008-12-21 Johan Dahlin <jdahlin@async.com.br>
295 Annotate transfer, direction and allow none for
296 g_file_load_contents, g_file_load_contents_finish and
297 g_file_load_partial_contents_finish parameters.
299 2008-12-12 Owen Taylor <otaylor@redhat.com>
301 Disable array auto-detection for out-annotated parameters (#563934)
303 If we have a parameter annotated as (out), then having a ctype of
304 'char **' (or similar) doesn't necessarily indicate an array.
306 * giscanner/transformer.py: Skip array-detection logic for
307 (out)-annotated parameters.
308 * tests/scanner/annotation.h tests/scanner/annotation.c
309 tests/scanner/annotation-1.0-expected.gir
310 tests/scanner/annotation-1.0-expected.tgir: Add a test for
311 an (out) string parameter.
313 2008-12-12 Johan Dahlin <jdahlin@async.com.br>
315 * giscanner/dumper.py (DumpCompiler._link): Pass in
316 --tag=CC to libtool to avoid making libtool confused
317 when CC is different from gcc on some systems.
319 2008-12-10 Johan Bilien <jobi@via.ecp.fr>
321 Bug 563998 – Cache the GIBaseInfo for GTypes
323 * girepository/girepository.c (g_irepository_find_by_gtype):
324 add a cache of GType -> GIBaseInfo.
326 2008-12-09 Johan Bilien <jobi@via.ecp.fr>
328 Bug 562545 – Add function taking / returning GValue
330 * tests/everything/everything.[ch]: add a test of function taking and
331 returning "const GValue *"
333 2008-12-09 Johan Dahlin <johan@async.com.br>
335 * giscanner/cachestore.py (CacheStore.store): Use
336 shutil.move instead of os.rename, since it will
337 automatically fall back to copying+remove if the
338 src directory is on a different partition from
341 2008-12-08 Tristan Van Berkom <tristan.van.berkom@gmail.com>
343 Bug 563742 – introspection should record the introduced version of
344 symbols marked with the "Since:" tag
349 * giscanner/girwriter.py:
350 * giscanner/scannerlexer.l:
351 * giscanner/transformer.py:
352 * tests/scanner/annotation-1.0-expected.gir:
353 * tests/scanner/annotation-1.0-expected.tgir:
354 * tests/scanner/annotation.c (annotation_versioned):
355 * tests/scanner/annotation.h:
357 2008-12-08 Johan Dahlin <johan@async.com.br>
359 * giscanner/cachestore.py (_get_cachedir): Don't require
360 HOME to be set and if it set, don't require the
363 2008-12-08 Johan Dahlin <johan@async.com.br>
365 * giscanner/cachestore.py (CacheStore.store): Dump the cache
366 file to a temporary file and rename it the expected filename
367 only when it's completely written.
368 This should make the cache more roboust when run in parallel,
369 and hopefully avoid triggering bugs in Python.
371 2008-12-03 Christophe Fergeau <teuf@gnome.org>
373 Bug 562971 – g-ir-scanner failure on libgpod headers
375 * giscanner/scannerlexer.l: raise YY_BUF_SIZE to 65536 up from the
376 default 16384. Without it, the lexer was aborting with a cryptic
377 error message on source files containing really long comment
380 2008-12-01 Colin Walters <walters@verbum.org>
382 * girepository/gfield.c: Fix memory leak; unref type info we
383 created, not field info
385 2008-11-30 Johan Dahlin <jdahlin@async.com.br>
387 Bug 562289 – Race when removing invalid cache
389 * giscanner/cachestore.py:
390 ENOENT is mapped to a OSError, not IOError.
392 2008-11-27 Johan Dahlin <jdahlin@async.com.br>
394 * gir/glib-2.0.c: Add return value transfer annotation
395 for g_markup_escape_text.
397 2008-11-25 Colin Walters <walters@verbum.org>
399 * tools/g-ir-scanner: Add --libtool option which we expect Automake-using
401 * giscanner/dumper.py: Implement it.
402 * gir/Makefile.am, tests/**/Makefile.am: Use it.
404 2008-11-25 Colin Walters <walters@verbum.org>
406 * tests/scanner/Makefile.am: Remove hand-rolled generation of .tgir; easier
407 to just use a Makefile rule and dependencies. This corresponds with a change
408 made to gir-repository to fix srcdir != builddir issues.
410 2008-11-25 Johan Dahlin <jdahlin@async.com.br>
413 Post release version bump
416 2008-11-25 Johan Dahlin <jdahlin@async.com.br>
421 2008-11-25 Colin Walters <walters@verbum.org>
423 Bug 559705 – Missing association between static methods and classes
425 * docs/typelib-format.txt:
426 * girepository/ginfo.c (g_function_info_get_flags):
427 * girepository/girmodule.c (g_ir_module_build_typelib):
428 * girepository/girnode.c (g_ir_node_get_size),
429 (g_ir_node_build_typelib):
430 * girepository/girparser.c (start_function):
431 * girepository/gtypelib.c (g_typelib_check_sanity),
432 (validate_header), (validate_function_blob):
433 * girepository/gtypelib.h:
435 * giscanner/girwriter.py:
436 * giscanner/glibtransformer.py:
437 * tests/scanner/foo-1.0-expected.gir:
438 * tests/scanner/foo-1.0-expected.tgir:
439 * tests/scanner/foo.h:
441 2008-11-25 Johan Dahlin <jdahlin@async.com.br>
443 * giscanner/ast.py: Define socklen_t as an alias for int32.
445 2008-11-24 Johan Dahlin <jdahlin@async.com.br>
447 * girepository/gdump.c (dump_type): Remove a warning,
448 be less verbose on error on fundamental types.
450 2008-11-23 Johan Dahlin <jdahlin@async.com.br>
452 * giscanner/dumper.py: Add license headers,
453 refactor into a class, avoid some duplication and do some
454 extra pedantic checks.
456 2008-11-23 Johan Dahlin <jdahlin@async.com.br>
458 Make it compilable with -Werror on my system by adding
459 a couple of prototypes and including headers.
461 2008-11-23 Johan Dahlin <jdahlin@async.com.br>
463 Bug 562022 – gobject-introspection needs python headers
465 * configure.ac: fail without python headers present.
468 2008-11-21 Johan Dahlin <jdahlin@async.com.br>
470 Bug 561617 – Return value array annotations
472 * giscanner/transformer.py:
473 * tests/scanner/annotation.c (annotation_return_array):
474 * tests/scanner/annotation.h:
475 Add support for (array) for return value annotations as well.
477 2008-11-20 Johan Bilien <jobi@via.ecp.fr>
479 * tests/everything/everything.[ch]: add a test function which calls a
482 2008-11-19 Johan Dahlin <jdahlin@async.com.br>
484 * giscanner/cachestore.py:
485 Catch ValueError exceptions.
487 2008-11-18 Tommi Komulainen <tommi.komulainen@iki.fi>
489 * tests/scanner/Makefile.am (barapp_SOURCES): fix builddir != srcdir
491 2008-11-18 Andreas Rottmann <a.rottmann@gmx.at>
493 * girepository/girnode.c (g_ir_node_build_typelib): Use sizeof()
494 instead of hard-coding struct sizes.
496 2008-11-18 Owen Taylor <otaylor@redhat.com>
498 Bug 561296 - Add "storage type" to the typelib data for enums
500 In order to set and get enum and flag fields in structures, we need
501 to know the integral type that the enumeration is stored as. We are already
502 computing that at compile time in order to compute struct offsets, so the
503 easiest thing to do is to save that in the typelib.
505 * docs/typelib-format.txt girepository/girnode.[ch] girepository/giroffsets.c
506 girepository/gtypelib.h: Add 'storage_type' to the typelib format for EnumBlob
507 and compute and save it at compile time.
509 * girepository/girepository.h girepository/ginfo.c:
510 Add g_enum_info_get_storage_type().
512 * girepository/gfield.c: Implement reading and writing enum and flags fields
513 based on the storage type.
515 2008-11-18 Owen Taylor <otaylor@redhat.com>
517 Add enums to the Everything test module
519 * tests/everything/everything.[ch]: Add TestEnum and TestFlags to the Everything
520 test module and register them as GTypes.
522 https://bugzilla.gnome.org/show_bug.cgi?id=561296
524 2008-11-18 Johan Dahlin <jdahlin@async.com.br>
526 * giscanner/cachestore.py:
527 Catch BadPickleGet exceptions as well.
529 2008-11-17 Owen Taylor <otaylor@redhat.com>
531 * tests/everything/everything.c: Fix doc comment annotations
532 for test_struct_b_clone() to refer to the right function.
534 2008-11-17 Dan Winship <danw@gnome.org>
536 * giscanner/glibtransformer.py (GLibTransformer.__init__): fix
537 spelling of GHashTable. #561135
539 * tests/scanner/annotation.c (annotation_object_get_hash):
540 * tests/scanner/annotation-1.0-expected.gir:
541 * tests/scanner/annotation-1.0-expected.tgir: add a test of
542 GHashTable annotations
544 2008-11-17 Andreas Rottmann <a.rottmann@gmx.at>
546 * giscanner/ast.py: Change string array match type to be in terms
547 of canonicalized type.
548 * giscanner/transformer.py: Add canonicalize_ctype which gives us
549 a version of a c:type without aliases, so we can deep canonicalize
550 char** to utf8*. Update parse_ctype to use it.
551 * tests/*: Add gtk_init like int*/char*** arg functions for testing.
553 2008-11-16 Colin Walters <walters@verbum.org>
555 * girepository/girepository.c: Ensure we always call init_globals,
556 even if passed a non-default repository.
558 2008-11-16 Colin Walters <walters@verbum.org>
560 Bug 559706 - Interface prerequisites
562 * common.mk: Dep on libgirepository.la for scanner libs so that
563 we rebuild things even if just gdump.c changes.
564 * girepository/gdump.c: Dump prerequisites.
565 * giscanner/ast.py: Add prerequisite list.
566 * giscanner/girparser.py: Parse them from gdump.
567 * giscanner/girwriter.py: Write them.
568 * giscanner/glibtransformer.py: Resolve them.
571 2008-11-16 Owen Taylor <otaylor@redhat.com>
573 Bug 561087 - Respect is_pointer in serialize_type()
575 Add a '*' to the serialization for the cases where we set is_pointer
576 in the type blob we write out depending on node->is_pointer. Don't
577 add the '*' in the cases where is_pointer is set or not set in a
580 http://bugzilla.gnome.org/show_bug.cgi?id=561087
582 2008-11-16 Owen Taylor <otaylor@redhat.com>
584 Bug 560825 – Add size and alignment to typelib
586 Include the size and alignment of structures and unions in the typelib,
587 and add getter methods to retrieve them from GIStructInfo/GIUnionInfo.
589 * docs/typelib-format.txt girepository/gtypelib.h girepository/girnode.c
590 girepository/girmodule.c girepository/gtypelib.c: Add size and alignment
591 to StructBlob and UnionBlob.
593 * girepository/ginfo.c girepository/girepository.h:
594 Add g_[struct|union]_get[size|alignment]().
596 * test/offsets/gen-gitestoffsets: Test overall structure size and alignment.
598 2008-11-16 Owen Taylor <otaylor@redhat.com>
600 Bug 552371 – implement struct field get/set
602 * girepository/gfield.c girepository/girepository.h: Add
603 convenience functions g_field_info_set_field() and
604 g_field_info_get_field() to set and get fields based on the
605 offsets in GIFieldInfo.
607 2008-11-16 Andreas Rottmann <a.rottmann@gmx.at>
609 Bug 560241 - Out-arguments should not be marked as being pointers
612 * girepository/girparser.c: Improved logic for out arguments.
614 2008-11-16 Andreas Rottmann <a.rottmann@gmx.at>
616 Bug 559601 - Pointers in structs/unions unduly treated as arrays
618 * giscanner/transformer.py: Differentiate type creation logic
619 between parameters and struct components.
621 2008-11-15 Colin Walters <walters@verbum.org>
623 * giscanner/dumper.py: Check return code from pkg-config
626 2008-11-14 Johan Dahlin <jdahlin@async.com.br>
628 * tests/everything/everything.c (test_array_int_in),
629 (test_array_gtype_in):
630 * tests/everything/everything.h:
631 Rename the int/gtype array tests. Make the return value
632 useful, an aggregation of the array input values.
634 2008-11-14 Johan Dahlin <jdahlin@async.com.br>
636 * tests/everything/Makefile.am:
637 * tests/everything/everything.c:
638 * tests/everything/everything.h:
639 * tests/everything/gitesttypes.c:
640 * tests/everything/gitesttypes.h:
641 Rename gitesttypes.[ch] to everything.[ch]
643 2008-11-13 Andreas Rottmann <a.rottmann@gmx.at>
645 Bug 560708 – Don't treat arrays that have a length specified as
646 zero-terminated by default
648 * giscanner/transformer.py: Default to non zero terminated for
650 * tests/*: Update, add test for zero vs not.
652 2008-11-13 Andreas Rottmann <a.rottmann@gmx.at>
654 Bug 557788 - Return types for constructors in generated typelib bogus
656 * girepository/girnode.c: Namespace-qualify XREFs; not doing so is
657 obviously broken in the face of duplicate names in different
659 * tests/scanner/*expected.gir: Fix up.
661 2008-11-13 Owen Taylor <otaylor@redhat.com>
663 * girepository/girffi.c: Fix "Unexpected time for time_t"
666 2008-11-13 Colin Walters <walters@verbum.org>
668 Bug 558436 - avoid having scanner load app code
670 * giscanner/cgobject.py: Delete; we no longer load shared
672 * giscanner/dumper.py: Support for linking a library to
673 a stub binary for introspection.
674 * giscanner/glibtransformer.py: Rewrite to use gdump XML
675 from invocation of child binary.
676 * giscanner/transformer.py: Fix up to use fully qualified
677 name in parse tree. Make parse_ctype public so we can use
678 it inside glibtransformer.
679 * tests/scanner/barapp.c: New test, using --program arg
681 * tests/*: Update to use common.mk for invoking scanner.
682 * tools/g-ir-scanner: Add options --program, --program-arg,
684 * docs/g-ir-scanner.1: Update.
686 2008-11-13 Colin Walters <walters@verbum.org>
688 * configure.ac: Depend on Gio, we use it in gdump.c.
689 * girepository/gdump.c: Code to dump GType data to XML.
690 * girepository/girepository.c: Add option group for dumping.
691 * girepository/girepository.h: Define API for the above.
693 2008-11-13 Colin Walters <walters@verbum.org>
695 * common.mk: Add a file to include with Makefile fragments
696 useful for scanner invocation.
698 2008-11-13 Tommi Komulainen <tommi.komulainen@iki.fi>
700 * tests/everything/gitesttypes.c (test_filename_return): Return
701 strings in filename encoding.
703 2008-11-13 Owen Taylor <otaylor@redhat.com>
705 Bug 560253 – Add structure and boxed types to Everything test module
707 * tests/everything/gitesttypes.[ch]: Add examples of:
709 Plain old data structs
710 Plain old data structs with nested fields
712 Plain old data boxed with nested fields
713 More complicated boxed types with internal state
715 2008-11-12 Johan Dahlin <jdahlin@async.com.br>
717 * tests/everything/gitesttypes.c (test_gtype_in):
718 * tests/everything/gitesttypes.h:
719 Add a test of GType arrays, a la gtk_list_store_set_columns.
721 2008-11-12 Owen Taylor <otaylor@redhat.com>
723 Bug 560419 – Cache includes when parsing
725 Keep track of all modules parsed within a GIrParser, and when a
726 module is referenced a second time, use the existing parsed copy
727 instead of reparsing.
729 2008-11-12 Owen Taylor <otaylor@redhat.com>
731 Fix management of ParseContext.includes_modules (#560419)
733 * girepository/girparser.c: Fix some trivial bugs in managing the
734 list of include modules. (Add to module's list twice, not
735 initialized to NULL, not freed.)
737 2008-11-12 Owen Taylor <otaylor@redhat.com>
739 Keep aliases and disguised_structures local to each module (#560419)
741 * girepository/girmodule.[ch]: When parsing, keep keep a separate
742 hash tables of aliases and 'disguised' flags for each module, and
743 store that on the module.
745 After parsing an include merge the aliases/disguised flags to the
748 * girepository/girparser.c: Remove 'prefix_aliases' flag and
749 always prefix aliases/disguised structure types when parsing; this
750 simplifies the code considerably.
752 2008-11-12 Owen Taylor <otaylor@redhat.com>
754 Fix mismatches between .gir name and 'name' attribute (#560419)
756 * tests/boxed.gir tests/constant.gir tests/enum.gir tests/invoke/invoke.c
757 tests/invoke/testfns-1.0.gir tests/object.gir tests/struct.gir: Fix places
758 where the 'name' element of <namespace/> didn't match the filename of the
759 gir, an assumption that the compiler has always expected and now enforces.
761 2008-11-12 Owen Taylor <otaylor@redhat.com>
763 Only allow one <namespace/> element per <repository/> (#560419)
765 * girepository/girparser.c: The logic in girparser.c didn't work
766 very well if there were multiple <namespace/> nodes within a
767 single <repository/> (context->namespace was always the overall
768 filename and not the the name specified in the <namespace/>
769 element for one thing; this would cause aliases to be mis-prefixed
770 in include modules.) Also check that the "name" in the
771 <namespace/> node matches the filename.
773 2008-11-12 Owen Taylor <otaylor@redhat.com>
775 Add a GirParser object to hold the state of a compilation
777 * girepository/girparser.[ch] tools/compiler.c: Add a toplevel
778 GirParser object to hold state that is global across a
779 compilation. Currently just holds the include path, but will
780 eventually also keep a cached list of parsed modules.
782 2008-11-12 Tommi Komulainen <tommi.komulainen@iki.fi>
784 * girepository/girepository.c (find_namespace_latest): Fix
787 2008-11-12 Tommi Komulainen <tommi.komulainen@iki.fi>
789 * configure.ac: use 'introspection' component for bugs
791 2008-11-12 Johan Dahlin <jdahlin@async.com.br>
793 * tests/everything/gitesttypes.c (test_filename_return):
794 * tests/everything/gitesttypes.h:
795 Add a filename return test.
797 2008-11-12 Tommi Komulainen <tommi.komulainen@iki.fi>
799 * tests/offsets/Makefile.am (gitestoffsets.c): fix
800 gen-gitestoffsets invocation with builddir != srcdir
802 2008-11-12 Johan Dahlin <jdahlin@async.com.br>
804 * girepository/girepository.c:
805 Change the element type from utf8 to filename
806 * girepository/girnode.c (g_ir_node_build_typelib):
807 Special case filename equally to utf8 here.
809 2008-11-12 Johan Dahlin <jdahlin@async.com.br>
812 Remove unused variables, add a dependency of girepository.ch, so when
813 they change we rebuild the gir automatically.
815 2008-11-12 Johan Dahlin <jdahlin@async.com.br>
817 * girepository/girepository.c (g_irepository_get_search_path):
818 * girepository/girepository.h:
819 Add a g_irepository_get_search_path, so we can access the search
822 2008-11-12 Johan Bilien <jobi@via.ecp.fr>
824 Bug 560474 – g-ir-compiler crashes when compiling the glib gir
826 * girepository/girparser.c: avoid freeing an uninitialized pointer
828 2008-11-12 Johan Dahlin <jdahlin@async.com.br>
831 * giscanner/glibtransformer.py:
832 * tools/g-ir-scanner:
833 Add a GIRepository-2.0.gir. Change the libtool lookup slightly
834 so we can just pass in --library=foo/bar/baz.la and the scanner
835 does the right thing.
836 Don't warn for _get_type() functions if they don't take any
839 2008-11-11 Owen Taylor <otaylor@redhat.com>
841 Bug 560404 – Prefix types when resolving aliases in included modules
843 * girepository/girparser.c: When resolving aliases in an included
844 module, prefix types before looking them up.
846 2008-11-11 Owen Taylor <otaylor@redhat.com>
848 Compute field offsets and overall size for object structures
850 Bug 560326 – Fails to build Gtk-2.0.typelib with "Unexpected non-pointer
851 field of type object in structure"
853 Do basic computation of field offsets for objects and interfaces;
854 this doesn't attempt to address all of the "mess" for virtual
855 functions described in Bug 560281.
857 2008-11-11 Tommi Komulainen <tommi.komulainen@iki.fi>
859 Bug 560308 – g-ir-compiler goes in infinite loop on Gdk-2.0.gir
861 Based on patch by Johan Bilien.
863 * giscanner/transformer.py (_create_member, _create_parameter):
864 Resolve types here as well.
865 (_resolve_type_name_1): Try resolving using 'ctype' first since
866 it's least ambiguous. Fixes struct member type resolution with
867 similarly named types, e.g. Gdk.PangoRendererClass and
869 * tests/scanner/foo*: Add test.
871 2008-11-11 Owen Taylor <otaylor@redhat.com>
873 * girepository/girparser.c: Search provided include dirs before
874 the default directories.
876 2008-11-11 Owen Taylor <otaylor@redhat.com>
878 * girepository/giroffsets.c: Include fully-qualified names in
881 2008-11-11 Owen Taylor <otaylor@redhat.com>
883 * girepository/giroffsets.c: Fail gracefully with an informative
884 error message when recursion is encountered when computing a
887 2008-11-11 Owen Taylor <otaylor@redhat.com>
889 * girepository/girparser.c: Remove an unused variable.
891 2008-11-10 Owen Taylor <otaylor@redhat.com>
893 Add tests for field offset computations
895 * tests/offsets/offsets.h: Header file with structure definitions to test
897 * tests/offsets/gen-gitestoffsets: Generate a C program that computes
898 field offsets for the structures in offsets.h two ways: using
899 the information from a generated typelib, and as computed by the
902 We diff these two versions to test that everything is OK.
904 2008-11-10 Owen Taylor <otaylor@redhat.com>
906 Remove field offsets from g-ir-generate output and test inputs
908 Field offsets are a) architecture dependent so they shouldn't be part
909 of the architecture-independent gir format which is installed in
910 datadir. b) Are architecture-dependent so they shouldn't be in test
913 * girepository/girparser.c: Don't parse offset for fields
914 * tools/generate.c: Don't parse offset for fields
915 * tests/*.gir test/scanner/*.tgir: Remove offsets
917 (Virtual function and discriminator offsets are not removed, as they
918 aren't fully hooked up to the field-offset computation machinery yet.)
920 2008-11-10 Owen Taylor <otaylor@redhat.com>
922 Bug 560252 - Compute field offsets before writing typelib
924 * girepository/girnode.h: Store the total size and alignment for
925 GIrNodeStruct/Boxed/Union.
927 * girepository/giroffset.c: New file implementing computation of
928 structure field offsets.
930 * girepository/girnode.c: Compute structure field offsets before
931 writing types into the typelib.
933 * docs/typelib-format.txt: Document that a field offset of 0xFFFF
934 means "unknown". Also fix description of the discriminator_offset
937 2008-11-10 Owen Taylor <otaylor@redhat.com>
939 Bug 560250 - Fully parse included modules
941 For some things, like computing structure offsets to put into the typelib
942 we need more than just the aliases from included modules. Do a completel
943 parse of included modules and store in module->included_modules.
945 Also add g_ir_find_node() to find node information from within the
946 active set of modules and their includes.
948 2008-11-10 Owen Taylor <otaylor@redhat.com>
950 Split g_ir_ffi_get_ffi_type() out from ginvoke.c
952 Extract a function to convert GITypeTag to ffi_type from the internals
953 of ginvoke.c. This will be useful in figure out structure alignment.
955 Also fix handling of gsize and time_t to be portable. (Add a check
956 to configure.ac to figure out the width of time_t.)
958 2008-11-10 Owen Taylor <otaylor@redhat.com>
960 Bug 560248 – "disguised structures"
962 Certain types like GIConv and GdkAtom are pointers internally but don't
963 look like pointers when referenced. They have the form.
965 typedef struct _X *X;
967 Parse these as structures/records but mark them in the gir with a 'disguised'
968 attribute so that we know that they need special handling.
970 In the typelib treat them like any other structure.
972 2008-11-09 Jürg Billeter <j@bitron.ch>
975 * giscanner/girwriter.py:
977 Write throws attribute for virtual functions, fixes bug 559703
979 2008-11-07 Johan Dahlin <jdahlin@async.com.br>
981 * giscanner/libtoolimporter.py (LibtoolImporter.find_module): Clear
982 up some confusion about the second argument to find_module, it's
983 actually the packages __path__ attribute which we can safely ignore
985 (LibtoolImporter.load_module): Set module.__loader__ as per PEP 302.
987 2008-11-07 Owen Taylor <otaylor@redhat.com>
989 Bug 559737 – Deal with continuations in macros
991 * giscanner/giscannerlexer.l: Treat continuation lines the same
992 as regular newlines. This makes the scanner not complain about
993 #define foo(x) \ <stuff> inside a C file. There's no attempt
994 however to handle parsing macro definitions split across lines.
996 2008-11-07 Johan Dahlin <jdahlin@async.com.br>
998 * giscanner/cachestore.py:
999 Handle broken cache entries, write only filesystems and
1000 running out of diskspace.
1002 2008-11-07 Owen Taylor <otaylor@redhat.com>
1004 * giscanner/giscannermodule.c (pygi_source_scanner_lex_filename):
1005 Set current_filename before lexing the file so error messages
1006 are reported in the right file.
1008 2008-11-06 Colin Walters <walters@verbum.org>
1010 * tests/everything/*: Add some tests for strv.
1012 2008-11-05 Colin Walters <walters@verbum.org>
1014 * girepository/ginvoke.c (g_function_info_invoke): Don't use
1015 nested scope local variable for error which may go away after
1016 conditional is complete.
1018 2008-11-05 Colin Walters <walters@verbum.org>
1020 * giscanner/scannerlexer.l: Avoid static 256 char buf which we
1021 manipulate hackily; just use GString. This avoids an
1022 uninitialized memory read pointed out by Havoc.
1024 2008-11-04 Johan Dahlin <jdahlin@async.com.br>
1026 * giscanner/__init__.py:
1028 * giscanner/cachestore.py:
1029 * giscanner/cgobject.py:
1030 * giscanner/girparser.py:
1031 * giscanner/girwriter.py:
1032 * giscanner/giscannermodule.c:
1033 * giscanner/glibast.py:
1034 * giscanner/glibtransformer.py:
1035 * giscanner/libtoolimporter.py:
1036 * giscanner/minixpath.py:
1037 * giscanner/odict.py:
1038 * giscanner/sourcescanner.c:
1039 * giscanner/sourcescanner.h:
1040 * giscanner/sourcescanner.py:
1041 * giscanner/transformer.py:
1042 * giscanner/utils.py:
1043 * giscanner/xmlwriter.py:
1045 Relicense the giscanner library under LGPLv2+.
1046 This has been approved by all contributors.
1048 2008-11-01 Owen Taylor <otaylor@redhat.com>
1050 Bug 558848 giparser.py: shared library should be optional
1052 When parsing a .gir, allow the shared-library attribute
1053 of <namespace/> to be missing: this corresponds to the handling
1054 in libgirepository and elsewhere.
1056 2008-11-01 Tommi Komulainen <tommi.komulainen@iki.fi>
1058 Bug 557898 – Fails to build on OSX 10.4
1060 * configure.ac: Check for $shrext_cmds that should be implicitly
1061 available if you're using libtool >= 2.0. If undefined, call
1062 libtool --config explicitly to get its value.
1063 * girepository/gtypelib.c: Remove special case for (non-)Darwin
1064 systems as unneeded.
1066 2008-10-31 Colin Walters <walters@verbum.org>
1068 * COPYING, COPYING.lib, COPYING.tools: Clarify licensing status.
1070 2008-10-31 Johan Dahlin <jdahlin@async.com.br>
1072 * configure.ac: Post release version bump
1075 2008-10-31 Johan Dahlin <jdahlin@async.com.br>
1079 * docs/release-checklist.txt:
1082 2008-10-31 Johan Dahlin <jdahlin@async.com.br>
1084 * Makefile.am: add an upload-release target
1085 * docs/release-checklist.txt:
1086 Release process documentation
1088 2008-10-31 Colin Walters <walters@verbum.org>
1090 Bug 558109 – _g_typelib_init fails to find shared libraries
1092 * transformer/glibtransformer.py: Use ctypes' find_library
1093 on passed libraries and write that for the shared-library
1094 entry. We want to avoid depending on -devel packages.
1096 2008-10-31 Johan Dahlin <jdahlin@async.com.br>
1098 * docs/g-ir-scanner.1:
1099 Document the renaming options.
1101 2008-10-31 Tommi Komulainen <tommi.komulainen@iki.fi>
1103 * giscanner/Makefile.am:
1104 * tests/invoke/Makefile.am:
1105 * tests/repository/Makefile.am: List in-tree libraries first in
1106 LDADD / LIBADD. If installed library is listed first, the
1107 resulting binary will prefer installed version to one in .libs,
1108 possibly making 'make check' behave strangely.
1110 2008-10-30 Tommi Komulainen <tommi.komulainen@iki.fi>
1112 * giscanner/ast.py: map 'id' (ObjC) to 'any' type to stop
1113 gir-repository from choking with gdk/quartz
1115 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
1117 * giscanner/giscannermodule.c (calc_attrs_length),
1118 (pygi_collect_attributes):
1119 * giscanner/xmlwriter.py:
1120 Write a C version of the xml namespace formatter.
1121 Saves 15% of the time it takes to create a gtk gir.
1123 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
1125 * giscanner/xmlwriter.py: Abstract attribute formatting
1126 to a function external to the XMLWriter class.
1128 * giscanner/scannerlexer.l:
1129 Parse and discard __typeof and __attribute.
1131 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
1133 * giscanner/girparser.py:
1134 Remove arguments from the constructor, move them to
1135 separate accessors. Add a new parse_tree method
1136 which takes an element tree instance.
1137 * tools/g-ir-scanner:
1138 Update callsite for this
1140 * giscanner/Makefile.am:
1141 * giscanner/cachestore.py:
1142 * giscanner/transformer.py:
1143 Cache the include parsing. Saves ~25% time when
1144 creating vte (which includes everything up to gtk+).
1146 2008-10-30 Colin Walters <walters@verbum.org>
1148 * giscanner/transformer.py: Don't reparse includes
1149 we've already processed.
1151 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
1153 * giscanner/girparser.py:
1154 * giscanner/transformer.py:
1155 Avoid parsing parameters, types etc when parsing
1156 includes. Should speed up include parsing a bit.
1158 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
1160 * giscanner/girparser.py:
1161 Avoid big if/else and use a dispatch table like
1164 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
1166 * giscanner/transformer.py:
1167 Clean up include parsing and registration.
1169 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
1171 * giscanner/transformer.py:
1174 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
1176 Bug 558383 – builddir != srcdir build fails if giscanner python module not already installed
1179 construct PYTHONPATH just once
1181 * tests/everything/Makefile.am:
1182 * tests/scanner/Makefile.am:
1183 add $(top_srcdir) to PYTHONPATH to
1184 handle builddir != srcdir
1186 * giscanner/libtoolimporter.py:
1187 * giscanner/sourcescanner.py:
1188 Make the libtoolimporter work when distchecking too.
1190 Mostly based on patch by Tommi Komulainen
1192 2008-10-29 Owen Taylor <otaylor@redhat.com>
1194 * giscanner/glibtransformer.py: If a filename of an existing
1195 file is passed to --library, hunt for it directly, rather than
1196 searching for a corresponding library.
1198 2008-10-29 Johan Dahlin <jdahlin@async.com.br>
1200 * giscanner/libtoolimporter.py:
1201 * giscanner/sourcescanner.py:
1202 Clean up the libtool importer a bit. Add a context so we
1203 can use it through a with statement.
1204 Don't just look in the current directory, look in the whole
1207 2008-10-29 Tommi Komulainen <tommi.komulainen@iki.fi>
1209 Bug 558065 – gitesttypes should be installed
1212 * tests/Makefile.am:
1213 * tests/types/Makefile.am -> tests/everything/Makefile.am
1214 * tests/types/gitesttypes.c -> tests/everything/gitesttypes.c
1215 * tests/types/gitesttypes.h -> tests/everything/gitesttypes.h
1216 move tests/types to tests/everything
1218 * tests/everything/Makefile.am: build normal shared library
1219 libgirepository-everything.so.1.0.0 and corresponding typelib
1220 Everything-1.0.typelib
1222 * tests/everything/Makefile.am: explicitly link libtool
1223 versioning with typelib versioning with variables
1225 2008-10-28 Johan Bilien <jobi@via.ecp.fr>
1227 * tools/g-ir-scanner: add LD_LIBRARY_PATH to LPATH before calling ld.
1229 2008-10-27 Johan Bilien <jobi@via.ecp.fr>
1231 * gio/gio-2.0.c: add allow-none annotations, based on the pygobject
1234 2008-10-27 Johan Bilien <jobi@via.ecp.fr>
1236 Bug 558068 – when invoking a method, offset the in arguments by one,
1239 * tests/invoke/invoke.c, tests/invoke/testfns.c,
1240 tests/invoke/testfns-1.0.gir: Add testing of method and constructor.
1241 * girepository/ginvoke.c: do not offset the index of given out
1242 arguments by one for methods, "this" is provided as in argument only.
1244 2008-10-27 Johan Bilien <jobi@via.ecp.fr>
1246 * gir/gio-2.0.c: add annotation for g_file_delete
1248 2008-10-27 Tommi Komulainen <tommi.komulainen@iki.fi>
1250 Bug 558062 – provide and use paths in the .pc file
1252 * gobject-introspection-1.0.pc.in: provide typelibdir variable
1253 for where .typelibs should be installed (callers shouldn't need
1254 to construct paths from bits and pieces)
1256 2008-10-25 Andreas Rottmann <a.rottmann@gmx.at>
1258 Bug 557791 – g_irepository_require() could return a GTypelib *
1260 * girepository/girepository.c: Return GTypelib; this is useful
1261 for low level manipulation.
1263 2008-10-25 Colin Walters <walters@verbum.org>
1265 Bug 557788 – Return types for constructors in generated typelib bogus
1267 * giscanner/glibtransformer.py: Don't resolve ctors incrementally,
1268 rely on end pass resolution.
1270 2008-10-25 Andreas Rottmann <a.rottmann@gmx.at>
1272 Bug 557786 - support fixed size arrays
1274 * girepository/ginfo.c: Add g_type_info_get_array_fixed_size.
1275 * giscanner/scannerparser.y: Retain fixed array size.
1276 * giscanner/ast.py: Add to note.
1277 * giscanner/girwriter.py: Write to gir.
1278 * girepository/girnode.c: Write it to typelib.
1279 * tools/generate.c: Generate.
1280 * tests/*: Add tests.
1282 2008-10-25 Colin Walters <walters@verbum.org>
1284 Bug 557076 - move typelibs to $libdir
1286 * configure.ac: Steal some configury bits from dbus to expand
1288 * gir/Makefile.am: Move to libdir.
1289 * girepository/girepository.c: Stop searching XDG_DATA_DIRS;
1290 instead just look at one hardcoded path in libdir.
1291 * acinclude.m4: Bits from dbus.
1293 2008-10-24 Johan Dahlin <johan@gnome.org>
1295 * girepository/girnode.c (g_ir_node_check_unhandled_members):
1296 Be quiet, do not warn about unhandled members.
1298 2008-10-24 Johan Dahlin <johan@gnome.org>
1300 * girepository/gtypelib.c:
1301 Only use SHLIB_SUFFIX on darwin, otherwise use
1302 G_MODULE_SUFFIX, we cannot get shext_cmds from libtool 2.2.
1304 2008-10-24 Lucas Rocha <lucasr@gnome.org>
1306 Bug 557623 - Constructors shouldn't be flagged as methods.
1308 * girepository/ginfo.c (g_function_info_get_flags): ditto.
1310 2008-10-24 Johan Dahlin <johan@gnome.org>
1312 * giscanner/scannerparser.y:
1313 Check against division by zero for the modula operator.
1314 This fixes header parsing of OSX system headers included
1317 2008-10-24 Johan Dahlin <johan@gnome.org>
1321 Add a CONTRIBUTORS file and dist it.
1323 2008-10-23 Tommi Komulainen <tommi.komulainen@iki.fi>
1325 Bug 556739 – transfer-ownership attribute should be mandatory in .gir
1327 * girepository/girparser.c (parse_param_transfer):
1328 * giscanner/transformer.py (_create_parameter, _create_return):
1329 * giscanner/girwriter.py (_write_return, _write_parameter):
1330 * tools/generate.c (write_callable_info): always write and
1331 require "transfer-ownership" for return-values and parameters
1334 * tests/invoke/testfns-1.0.gir:
1336 * tests/scanner/DrawableAdditions.xml:
1337 * tests/scanner/GtkFrob-1.0-expected.tgir:
1338 * tests/scanner/annotation-1.0-expected.tgir:
1339 * tests/scanner/drawable-1.0-expected.tgir:
1340 * tests/scanner/drawable-injected-1.0-expected.gir:
1341 * tests/scanner/drawable-injected-1.0-expected.tgir:
1342 * tests/scanner/foo-1.0-expected.tgir: Updated
1344 2008-10-23 Tommi Komulainen <tommi.komulainen@iki.fi>
1346 * giscanner/cgobject.py: build fundamental types same way as glib
1348 * giscanner/glibtransformer.py (_type_from_gtype): record GType
1349 when constructing the Type from it
1351 * giscanner/glibtransformer.py (_adjust_transfer): Check whether
1352 the parameter is a GObject from its GType, if available.
1354 * giscanner/glibtransformer.py (_adjust_transfer):
1355 * tests/scanner/foo-1.0-expected.gir:
1356 * tests/scanner/foo-1.0-expected.tgir: deduce
1357 transfer-ownership from GTypes
1359 2008-10-23 Tommi Komulainen <tommi.komulainen@iki.fi>
1361 * giscanner/transformer.py (_create_parameter):
1362 * tests/scanner/foo-1.0-expected.gir: make varargs
1363 transfer-ownership="none"
1365 2008-10-23 Colin Walters <walters@verbum.org>
1367 Bug 556739 - transfer ownership
1369 * giscanner/ast.py: Refactor Parameter/Return to share
1370 common attributes. Add transfer_inferred attribute
1371 which says whether or not we made a guess.
1372 * giscanner/transformer.py: Add much more extensive
1373 heuristics around parameter and return transfer.
1374 * giscanner/glibtransformer.py: Adjust to inspect
1378 2008-10-22 Tommi Komulainen <tommi.komulainen@iki.fi>
1380 Bug 557377 – Add test to ensure annotations survive the roundtrip via typelib
1382 * tests/scanner/Makefile.am:
1383 * tests/scanner/annotation-1.0-expected.tgir:
1384 * tests/scanner/drawable-1.0-expected.tgir:
1385 * tests/scanner/drawable-injected-1.0-expected.tgir:
1386 * tests/scanner/foo-1.0-expected.tgir:
1387 * tests/scanner/GtkFrob-1.0-expected.tgir:
1388 * tests/scanner/utility-1.0-expected.tgir: Add test to ensure
1389 annotations survive the roundtrip via typelib
1391 The expectations are as currently produced by g-ir-generate,
1392 comparison with the .gir files shows there are differences.
1394 2008-10-23 Johan Bilien <jobi@via.ecp.fr>
1396 Bug 557468 – Support for GI_TYPELIB_PATH
1398 * girepository/girepository.c: if the GI_TYPELIB_PATH is set, add the
1399 provided paths to the global search path.
1401 2008-10-22 Tommi Komulainen <tommi.komulainen@iki.fi>
1403 Bug 557379 – g-ir-generate not writing the 'abstract' attribute
1405 * tests/scanner/drawable-1.0-expected.tgir:
1406 * tests/scanner/drawable-injected-1.0-expected.tgir:
1407 * tests/scanner/foo-1.0-expected.tgir:
1408 * tools/generate.c (write_object_info): write 'abstract'
1409 attribute for classes
1411 2008-10-22 Lucas Rocha <lucasr@gnome.org>
1413 * girepository/girmodule.c, girepository/gtypelib.c,
1414 girepository/girparser.[ch]: fix some build warnings.
1416 2008-10-22 Tommi Komulainen <tommi.komulainen@iki.fi>
1418 Bug 557405 – Use 'allow-none' consistently
1420 * docs/typelib-format.txt:
1421 * girepository/ginfo.c (g_arg_info_may_be_null):
1422 * girepository/girnode.c (g_ir_node_build_typelib):
1423 * girepository/girnode.h (struct _GIrNodeParam):
1424 * girepository/girparser.c (start_parameter):
1425 * girepository/girwriter.c (function_generate):
1426 * girepository/gtypelib.h (ArgBlob):
1428 * tests/function.gir:
1429 * tools/generate.c (write_callable_info): Use 'allow-none'
1430 consistently throughout
1432 2008-10-22 Tommi Komulainen <tommi.komulainen@iki.fi>
1434 Bug 557092 – Callback annotations not used
1436 * giscanner/transformer.py (_create_callback): use annotations
1438 * tests/scanner/annotation.h
1439 * tests/scanner/annotation-1.0-expected.gir: add tests
1441 2008-10-21 Colin Walters <walters@verbum.org>
1443 * giscanner/scannerlexer.l: Don't require trailing whitespace after
1444 uncommented parameters.
1447 2008-10-21 Colin Walters <walters@verbum.org>
1449 * girepository/girepository.c: Ensure that when doing an unversioned
1450 require, we prefer items earlier in the search path to later ones.
1452 2008-10-21 Owen Taylor <otaylor@redhat.com>
1454 * giscanner/transformer.py: For string parameters allow transfer annotation
1455 to override the standard automatic guessing based on 'const'.
1457 2008-10-21 Johan Bilien <jobi@via.ecp.fr>
1459 Bug 557241 – "throws" flag for functions
1461 * tests/scanner/drawable-1.0-expected.gir,
1462 tests/scanner/drawable-injected-1.0-expected.gir,
1463 tests/scanner/drawable.[ch]: add simple test for throwing
1464 function (has GError ** as last argument)
1466 * giscanner/ast.py: add a 'throws' flag to Function
1467 * giscanner/glibtransformer.py: if a function's last paramerter is
1468 a GError, set the 'throws' flag and remove that parameter
1469 * giscanner/girwriter.py: write out the 'throws' attribute
1470 * giscanner/girparser.py: support parsing the 'throws' attribute
1472 * tests/repository/gitestthrows.c: add a simple test to check the
1473 throws flag in a typelib and invoke the function
1475 * girepository/ginfo.c, girepository/girnode.[ch],
1476 girepository/girnode.h, girepository/girparser.c,
1477 girepository/girepository.h: Add and parse the GI_FUNCTION_THROWS flag
1479 * girepository/ginvoke.c: if a function throws, add a GError as last
1480 arguments, and propagate the error to the invoker.
1482 2008-10-21 Tommi Komulainen <tommi.komulainen@iki.fi>
1484 * giscanner/transformer.py (_create_parameters): Warn if we see
1485 annotations for unknown parameters. If .h and .c files name
1486 parameters differently, the annotations may be lost.
1488 2008-10-21 Johan Dahlin <johan@gnome.org>
1490 Bug 556358 - don't use libtool internals
1492 * giscanner/Makefile.am:
1493 * giscanner/libtoolimporter.py:
1494 * giscanner/sourcescanner.py:
1495 * giscanner/utils.py:
1496 Add a python meta importer and remove a libtool symlink hack.
1498 2008-10-20 Andreas Rottmann <a.rottmann@gmx.at>
1500 * tests/scanner/Makefile.am (%.typelib): Set PYTHONPATH
1501 and --add-include-path appropriately when invoking the scanner.
1502 * tests/types/Makefile.am (%typelib): Likewise.
1504 2008-10-20 Colin Walters <walters@verbum.org>
1506 Bug 556777 - validate properties
1508 * giscanner/transformer.py: Add option to throw on unknown types.
1509 * giscanner/glibtransformer.py: Use it on properties.
1510 * tests/*: Add a test.
1512 2008-10-20 Colin Walters <walters@verbum.org>
1514 * giscanner/glibast.py: Also register g variants of
1515 default_array_types. This is not beautiful, but
1516 good alternatives aren't easy to come by.
1517 This fixes gchar ** parsing.
1519 2008-10-20 Colin Walters <walters@verbum.org>
1521 * docs/typelib-format.txt, girepository/gtypelib.h:
1522 Take a bit from ObjectInfo to represent abstract flag.
1523 * giscanner/cgobject.py: Expose g_type_get_flags.
1524 * girepository/girepository.h: Add accessor.
1525 * girepository/ginfo.c: Implement it.
1526 * giscanner/ast.py: Add is_abstract flag to generic
1528 * giscanner/glibast.py: Use it.
1529 * giscanner/girwriter.py: Write it.
1530 * girepository/girparser.c: Parse it.
1533 2008-10-20 Tommi Komulainen <tommi.komulainen@iki.fi>
1535 * giscanner/girparser.py (_parse_function): don't lose
1536 'transfer-ownership' attributes when injecting, check for the
1539 2008-10-19 Johan Dahlin <johan@gnome.org>
1541 * giscanner/scannerlexer.l: Parse and ignore __asm.
1543 2008-10-19 Colin Walters <walters@verbum.org>
1545 * giscanner/girparser.py: Parse array length= to ensure
1546 it doesn't get lost from --inject.
1548 2008-10-17 Colin Walters <walters@verbum.org>
1550 Bug 556795 - char ** regression
1552 * giscanner/transformer.py: Fix parsing of ctypes, add some
1553 comments about what's going on.
1554 * tests/*: Add a test for char **.
1556 2008-10-17 Colin Walters <walters@verbum.org>
1558 Bug 556783 - change namespace handling to be more consistent
1560 * giscanner/transformer.py: Eliminate usage of
1561 strip_namespace_object. We now treat --namespace as the default
1562 --strip-prefix; however, if --strip-prefix is specified it
1563 overrides --namespace. This applies to everything except function
1564 names, where we do also strip the namespace.
1565 * giscanner/glibtransformer.py: Remove usage of
1566 strip_namespace_object.
1568 * tests/*: Add skeletal GtkFrob-1.0 test which has different
1569 --namespace and --strip-prefix.
1571 2008-10-17 Tommi Komulainen <tommi.komulainen@iki.fi>
1573 Bug 556732 – generate gir files consistently
1575 * girepository/girparser.c (start_parameter):
1577 * tests/invoke/testfns-1.0.gir:
1578 * tools/generate.c (write_callable_info): write
1579 'transfer-ownership' attribute consistently with both
1580 return-value and parameter elements
1582 2008-10-17 Tommi Komulainen <tommi.komulainen@iki.fi>
1584 Bug 556732 – generate gir files consistently
1586 * tools/generate.c (write_callable_info): write 'direction'
1587 attribute only if other than 'in' to be consistent with
1590 * tests/object.gir: remove direction="in" which is the default
1592 2008-10-17 Tommi Komulainen <tommi.komulainen@iki.fi>
1594 Bug 556732 – generate gir files consistently
1596 * giscanner/ast.py (Field): add readable and writable properties
1597 * giscanner/girparser.py (_parse_field): copy 'readable' and
1598 'writable' attributes
1599 * giscanner/transformer.py (_create_member): create fields as
1601 * giscanner/glibtransformer.py (_introspect_object,
1602 _pair_class_struct): make object instance and class fields
1604 * giscanner/girwriter.py (_write_field):
1605 * tools/generate.c (write_field_info): write field 'readable'
1606 and 'writable' attributes only if non-default (read-only)
1607 * girepository/girparser.c (start_field): in the absence of
1608 attributes assume fields are read-only
1610 * tests/struct.gir: remove redundant readable="1" from fields
1611 * tests/scanner/foo-1.0-expected.gir:
1612 * tests/scanner/utility-1.0-expected.gir: add writable="1" to
1613 all record and union fields
1615 2008-10-17 Tommi Komulainen <tommi.komulainen@iki.fi>
1617 Bug 556732 – generate gir files consistently
1619 * giscanner/girwriter.py (_write_property): write properties
1620 'construct' attribute if set
1621 * tools/generate.c (write_property_info): write properties
1622 'readable' and 'writable' attributes only if non-default
1623 * tests/object.gir: add writable="0"
1624 * tests/scanner/foo-1.0-expected.gir: add construct="1"
1626 2008-10-17 Johan Bilien <jobi@via.ecp.fr>
1628 * gir/glib-2.0.c: added annotations
1630 2008-10-16 Johan Bilien <jobi@via.ecp.fr>
1632 * giscanner/ast.py: Also assume direction=out for size_t*, ssize_t*
1635 2008-10-16 Johan Bilien <jobi@via.ecp.fr>
1637 Bug 556610 – giscanner/girparser.py drops parameter options
1639 * tests/scanner/drawable-injected-1.0-expected.gir,
1640 tests/scanner/DrawableAdditions.xml: added simple test for injection.
1641 * giscanner/ast.py: allow Parameter to take options in the constructor
1642 * giscanner/girparser.py: parse parameter options (transfer,
1643 direction, allow-none)
1645 2008-10-16 Colin Walters <walters@verbum.org>
1647 Bug 556185 - segfault on g_callable_info_get_return_type
1649 Initial patch from John Ehresman.
1651 * tests/repository/*: Add a test using
1652 g_callable_info_get_return_type. Instead of casting a
1653 GITypeInfo directly to a GIRegisteredTypeInfo, we need
1654 to call g_type_info_get_interface.
1656 2008-10-16 Colin Walters <walters@verbum.org>
1658 Bug 556579 - union and struct name misresolved
1660 * giscanner/transformer.py: The calls to _resolve_type_name
1661 for struct/union names was a legacy holdover from when type
1662 resolution had multiple phases. Now it's actively harmful
1663 since we might pull in an identical name from another
1667 2008-10-16 Colin Walters <walters@verbum.org>
1669 Bug 556432 - transfer annotations and defaults
1671 * giscanner/transformer.py: Canonicalize type
1672 after removing *, not before. This ensures that
1673 guchar* is transformed to 'uint8'.
1674 Add some comments here.
1675 * giscanner/glibtransformer.py: Add _adjust_transfer
1676 phase for tweaking GObject transfers.
1679 2008-10-16 Tommi Komulainen <tommi.komulainen@iki.fi>
1681 * configure.ac: enable bunch of gcc warning CFLAGS
1683 2008-10-16 Tommi Komulainen <tommi.komulainen@iki.fi>
1685 Bug 556543 – reduce compiler warnings
1687 * girepository/ginfo.c:
1688 * girepository/girepository.c (register_internal,
1689 count_interfaces, find_interface, find_namespace_version,
1690 parse_version, g_irepository_require):
1691 * girepository/girmodule.c (g_ir_module_build_typelib):
1692 * girepository/girnode.c (init_stats, dump_stats,
1693 _g_irnode_init_stats, _g_irnode_dump_stats,
1694 g_ir_node_can_have_member):
1695 * girepository/girparser.c (firstpass_end_element_handler,
1696 locate_gir, parse_basic, parse_type_internal, resolve_aliases,
1697 start_alias, start_type, end_type_top, parse_include, cleanup,
1699 * girepository/gtypelib.c (validate_function_blob, validate_enum_blob):
1700 * giscanner/giscannermodule.c (directive_get_options,
1701 type_get_child_list):
1702 * giscanner/scannerlexer.l (parse_gtkdoc):
1703 * giscanner/scannerparser.y (ctype_free):
1704 * giscanner/sourcescanner.c:
1705 * giscanner/sourcescanner.h (gi_source_scanner_parse_macros):
1706 * tests/types/gitesttypes.c:
1707 * tools/compiler.c (main):
1708 * tools/generate.c (write_repository): Remove unused variables
1709 and code, add missing includes, declarations and case
1712 2008-10-16 Tommi Komulainen <tommi.komulainen@iki.fi>
1714 Bug 556541 – access union members through UnionBlob rather than
1717 * girepository/ginfo.c (g_union_info_find_method): access union
1718 members through UnionBlob rather than StructBlob
1720 2008-10-15 Colin Walters <walters@verbum.org>
1722 Bug 556331 - clean up includes handling
1724 * tools/g-ir-scanner: Rework command line arguments; now we take
1725 --add-include-path and --include separately.
1726 * giscanner/girwriter.py: Separate name= and version= in include
1728 * giscanner/ast.py: Add Include type.
1729 * giscanner/transformer.py: Cleanups to register_include now that
1730 we don't need to handle mixed filenames and relative arguments.
1731 * girepository/girparser.c: Parse name and version separately;
1732 this fixes a bug as a side effect where we weren't resolving
1733 through aliases for basic types.
1734 * girepository/girepository.c: Fix format string args.
1735 * gir/Makefile.am: Update.
1738 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1740 Bug 556434 – unhandled interface/object/... member types
1742 * girepository/girnode.c (g_ir_node_check_unhandled_members,
1743 g_ir_node_build_typelib): Check all
1744 interface/object/boxed/struct/union members are processed and
1745 abort if they are not. (Mostly callbacks in structs, but also
1746 fields in interfaces.)
1748 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1750 * a/girepository/girnode.c (g_ir_node_build_members,
1751 g_ir_node_build_typelib): refactor common code for processing
1752 members to a function
1754 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1756 * gir/Makefile.am (check-local): check that typelib -> gir -> typelib
1757 transformation is lossless (it's not)
1759 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1761 * tests/Makefile.am: fix tests to compare xml to xml instead of
1762 typelib to xml, and stop on error
1764 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1766 * tools/generate.c (write_type_name, write_type_info,
1767 write_type_info, write_object_info, write_object_info,
1768 write_interface_info, write_error_domain_info): reduce code
1771 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1773 Bug 556174 – parse types for lists etc.
1775 * girepository/girparser.c (end_type_recurse):
1777 * tools/generate.c (write_type_info, write_field_info,
1778 write_callable_info, write_callable_info, write_constant_info,
1779 write_property_info): use nested <type>s for lists and hashes
1781 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1784 * tests/object.gir: remove trailing whitespace from inside
1785 elements to match g-ir-generate output
1787 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1789 * tools/generate.c (xml_printf): quote printf arguments so that
1790 we don't generate invalid XML by writing unescaped double quotes
1791 and such in attributes
1793 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1795 * tools/generate.c (write_field_info, write_callable_info,
1796 write_function_info, write_callback_info, write_struct_info,
1797 write_constant_value, write_signal_info, write_vfunc_info,
1798 write_object_info, write_interface_info, write_union_info,
1799 write_repository): remove unused indent parameters, xmlwriter
1800 keeps track of necessary indentation
1802 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1804 * tools/generate.c (xml_element_new, xml_element_free,
1805 xml_start_element, xml_end_element, xml_end_element_unchecked,
1806 xml_open, xml_close): Keep track of generated XML tree and
1807 handle indentation and closing tags properly.
1808 (write_field_info, write_callable_info, write_function_info,
1809 write_callback_info, write_struct_info, write_value_info,
1810 write_constant_info, write_enum_info, write_signal_info,
1811 write_vfunc_info, write_property_info, write_object_info,
1812 write_interface_info, write_error_domain_info, write_union_info,
1813 write_repository): Use xml_start_element and xml_end_element to
1816 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1818 * tools/generate.c (xml_printf, xml_open, xml_close, xml_free):
1819 (write_type_name, write_type_info, write_field_info,
1820 write_callable_info, write_function_info, write_callback_info,
1821 write_struct_info, write_value_info, write_constant_value,
1822 write_constant_info, write_enum_info, write_signal_info,
1823 write_vfunc_info, write_property_info, write_object_info,
1824 write_interface_info, write_error_domain_info, write_union_info,
1825 write_repository): wrap all FILE access to go through simple xmlwriter
1827 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1829 Bug 556400 – Fails to build on OS X 10.4
1831 * configure.ac: check for functions backtrace and backtrace_symbols
1832 * girepository/girparser.c (backtrace_stderr): Comment out
1833 implementation if the functions are not available.
1834 * gcov.mak (clean-gcov, clean-gcno): always call 'find' with a
1835 directory for better portability
1837 2008-10-15 Johan Bilien <jobi@via.ecp.fr>
1839 Bug 556433 – assume direction = out for int * parameters
1841 * giscanner/ast.py: define a list of types for which, if passed as
1842 reference, we assume a default direction of 'out'
1843 * giscanner/transformer.py: if a type has type pointer to one of the
1844 previously defined types, and no direction is set, assume out.
1845 * tests/scanner/drawable.[ch]: added tests for guessed direction=out
1847 2008-10-15 Johan Bilien <jobi@via.ecp.fr>
1849 * tests/scanner/annotation.c: fixed a few copy-paste errors
1851 2008-10-14 Johan Bilien <jobi@via.ecp.fr>
1853 Bug 556323 – transfer-ownership is wrong for functions returning const
1856 * giscanner/transformer.py: check for a const string as return value,
1857 not just const char*. Suggested by Colin Walters
1858 * tests/scanner/annotation-1.0-expected.gir: updated expected output
1860 2008-10-14 Johan Bilien <jobi@via.ecp.fr>
1862 * girepository/ginfo.c, girepository/girepository.h: add
1863 g_union_info_find_method
1865 2008-10-14 Colin Walters <walters@verbum.org>
1867 * tests/repository/Makefile.am: Reenable repo test.
1868 * tests/repository/gitestrepo.c: Prepend search
1869 path for $(top_builddir)/gir dir so that we don't
1870 require installation for "make check" to pass.
1872 2008-10-13 Jürg Billeter <j@bitron.ch>
1874 * giscanner/glibtransformer.py:
1875 * tests/scanner/annotation-1.0-expected.gir:
1876 * tests/scanner/drawable-1.0-expected.gir:
1877 * tests/scanner/foo-1.0-expected.gir:
1878 * tests/scanner/utility-1.0-expected.gir:
1880 Support fields in GObject structs
1882 2008-10-13 Jürg Billeter <j@bitron.ch>
1884 * giscanner/ast.py: add signed integer and off_t to type_names
1886 2008-10-12 Jürg Billeter <j@bitron.ch>
1888 * giscanner/girparser.py: Parse bits attribute of fields
1890 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1892 * tests/repository/Makefile.am: run 'gitestrepo' in 'make check'
1893 * tests/repository/gitestrepo.c (main): instantiate
1894 'GCancellable' to ensure the GType is registered before using
1897 2008-10-12 Johan Bilien <jobi@via.ecp.fr>
1899 * giscanner/girparser.py: actually add the parsed constant nodes
1901 2008-10-12 Colin Walters <walters@verbum.org>
1903 * girepository/girepository.c: Don't cast DirEntry to Blob,
1904 actually look it up by offset.
1906 2008-10-12 Johan Bilien <jobi@via.ecp.fr>
1908 * giscanner/girparser.py: parse constant nodes in gir files
1910 2008-10-12 Johan Bilien <jobi@via.ecp.fr>
1912 * giscanner/transformer.py: prefix for constants have an underscore,
1913 so remove them as if they were functions, not objects.
1915 2008-10-12 Johan Bilien <jobi@via.ecp.fr>
1917 * tests/scanner/foo-1.0-expected.gir: add constants to expected gir
1920 2008-10-12 Colin Walters <walters@verbum.org>
1922 Initial patch from Jani Monoses.
1924 * girepository/gtypelib.c: Fix inverted test for success
1927 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1929 * tools/generate.c (write_callable_info): use "transfer-ownership"
1930 attribute for return values
1932 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1934 * tools/generate.c (write_callable_info): move "transfer" and
1935 "null-ok" attributes from <function> to <return-value> element
1937 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1939 * girepository/girparser.c (start_return_value): handle
1940 "transfer-ownership" attribute
1942 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1944 * girepository/girparser.c (parse_param_transfer):
1945 * tools/generate.c (write_callable_info): use "container" for
1946 container/shallow ownership transfer (not "shallow")
1948 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1950 * girepository/girparser.c (parse_param_transfer,
1951 start_parameter): Refactor handling of transfer=none/shallow/full
1952 to separate function
1954 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1956 Bug 556048 – Crash in g_irepository_find_by_gtype
1958 * girepository/gtypelib.h (BLOB_IS_REGISTERED_TYPE): added
1959 * girepository/girepository.c (find_interface): Fix
1960 find_by_gtype case to get the type name from right offset
1962 2008-10-12 Jürg Billeter <j@bitron.ch>
1964 * giscanner/girparser.py: Fix parsing transfer-ownership attribute
1967 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1969 * girepository/gtypelib.h (RegisteredTypeBlob): make
1970 'unregistered' one bit wide as everywhere else
1972 2008-10-12 Jürg Billeter <j@bitron.ch>
1974 * giscanner/glibtransformer.py:
1975 * tests/scanner/annotation-1.0-expected.gir:
1976 * tests/scanner/drawable-1.0-expected.gir:
1977 * tests/scanner/drawable.h:
1978 * tests/scanner/foo-1.0-expected.gir:
1979 * tests/scanner/utility-1.0-expected.gir:
1981 Readd class records as workaround to not break Gtk typelib
1983 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1985 * tests/types/Makefile.am: fix typo in gitesttypes namespace
1987 2008-10-12 Jürg Billeter <j@bitron.ch>
1989 * giscanner/glibtransformer.py: Don't generate <record> elements
1991 * tests/scanner/*: Update test cases
1993 2008-10-11 Colin Walters <walters@verbum.org>
1995 Bug 552858: versioning
1997 This is a big patch. You should probably remove your installation
2000 * docs/typelib-format.txt: Add nsversion entry which holds
2001 version of namespace.
2002 * girepository/girepository.h: Add 'version' parameter to
2003 g_irepository_require. This may be NULL. Normally
2004 bindings should pass an explicit version though.
2005 * girepository/girepository.c: Lots of infrastructure to
2006 support versioning. Add some more documentation. Disallow
2007 some usage of NULL namespaces.
2008 * girepository/girmodule.c: Add version parameter.
2009 * girepository/gtypelib.c: Update header size.
2010 * giscanner/ast.py: Add version to Namespace.
2011 * giscanner/girparser.py: Parse version attribute from
2012 XML, pass to Namespace.
2013 * giscanner/girwriter.py: Write out version parameter.
2014 * giscanner/transformer.py: Clean up include registration.
2015 * tests/*: Add version attribute.
2016 * tests/invoke/invoke.c: Don't try looking up test before
2017 it's loaded in repository.
2018 * tools/generate.c: Output version parameter.
2019 * gir/Makefile.am: Add 2.0 version to .gir files.
2021 2008-10-11 Colin Walters <walters@verbum.org>
2023 * giscanner/scannerlexer.l (parse_gtkdoc): Don't lose
2024 if we have mismatched parens.
2026 2008-10-11 Lucas Rocha <lucasr@gnome.org>
2028 * giscanner/girparser.py (_parse_enumeration_bitfield): fix typo
2029 on 'members' variable.
2031 2008-10-11 Colin Walters <walters@verbum.org>
2033 Bug 555947 - update annotations syntax
2035 * giscanner/ast.py: Default to None for transfer. Remove
2036 default transfers for container types; we require this to
2038 * giscanner/girwriter.py: Transfer is now 'none', 'container',
2039 'full' to match repository.
2040 * giscanner/scannerlexer.l: Annotations now are parenthesized.
2041 * giscanner/transformer.py: Update for new annotations syntax.
2044 2008-10-11 Johan Bilien <jobi@litl.com>
2046 * giscanner/scannerparser.y: ignore non-UTF-8 string constants
2048 2008-10-11 Johan Bilien <jobi@litl.com>
2050 Bug 552347: Parse #defines constants
2052 * girepository/gtypelib.c: update the list of value_size
2053 with recently defined type tags
2054 * giscanner/scannerparser.y: brought back parsing of #defined, as
2055 present in older version
2056 * giscanner/giscannermodule.c: bind gi_source_scanner_append_filename
2057 * giscanner/girwriter.py: write out constant tags in the gir
2058 * giscanner/sourcescanner.py: add accessor for const_string
2059 * giscanner/transformer.py, giscanner/glibtransformer.py: handle
2062 2008-10-11 Tommi Komulainen <tommi.komulainen@iki.fi>
2064 Bug 555946: Install a test module exercising all types, transfer
2069 * tests/types/*: Add and install a test module that has functions
2070 accepting and returning most of the basic types to enable bindings
2071 implementors to more easily test their type conversion routines.
2073 2008-10-11 Jürg Billeter <j@bitron.ch>
2075 Bug 552374: Const strings should be identified in the gir.
2077 * giscanner/transformer.py: support string memory management
2078 * tests/scanner/foo.h: use char * and const char *
2079 * tests/scanner/foo-expected.gir: test that
2081 2008-10-11 Johan Dahlin <johan@gnome.org>
2083 * giscanner/girparser.py:
2084 Also parse enums which are not glib types.
2086 2008-10-11 Lucas Rocha <lucasr@gnome.org>
2088 Bug 552370: add one more test for unsigned as a type, not as
2091 * giscanner/ast.py: add 'uint' type name for 'unsigned'.
2092 * test/scanner/foo.h: add function which uses unsigned as a type.
2093 * test/scanner/foo-expected.gir: test that.
2095 2008-10-11 Andreas Rottmann <a.rottmann@gmx.at>
2097 Bug 555712: Struct and union issues
2099 * giscanner/scannerparser.y (struct_declarator): Use information
2100 provided about the bit width of a field.
2101 * giscanner/transformer.py (Transformer._create_member): Pass the
2102 symbol's const_int member to the created field (it represents the
2104 * giscanner/girwriter.py (GIRWriter._write_field): Output 'bits'
2105 field attribute, if present.
2106 * giscanner/ast.py (Field): Add 'bits' member, specifying the
2107 width in bits of the field (only relevant for bitfields).
2110 * giscanner/transformer.py (Transformer._create_typedef_struct)
2111 (Transformer._create_typedef_union): Add calls to _create_struct()
2112 and _create_union(), respectively. This causes the scanner to
2113 generate output for fields of struct and union typedefs.
2116 2008-10-11 Jürg Billeter <j@bitron.ch>
2118 Bug 552370: unsigned not scanned properly
2120 * giscanner/scannerparser.y: combine basic types such as unsigned
2121 int and long long when scanning
2122 * tests/scanner/foo-expected.gir:
2123 * tests/scanner/foo.c: (foo_test_unsigned):
2124 * tests/scanner/foo.h: test that
2126 2008-10-11 Lucas Rocha <lucasr@gnome.org>
2128 Bug 554854: The --typelib-xml and --inject options should reuse
2129 giscanner parser/writer.
2131 * giscanner/ast.py: add constructor list to Struct and Union.
2132 Add new param in Return's contructor to define transfer.
2133 * giscanner/girparser.py: several additions to the parser in order
2134 to have parsing all nodes of the gir xml files.
2135 * tools/g-ir-scanner (typelib_xml_strip, inject): use gir parser
2136 and writer in --inject and --typelib-xml options.
2137 * giscanner/xmlwriter.py: ignore empty attributes instead of
2138 raising an error as this basically exposes a bug in GIRParser.
2139 This should be reverted as soon as the parser is fixed.
2141 2008-10-11 Lucas Rocha <lucasr@gnome.org>
2143 Bug 552376: scanner generates wrong names for enum members when
2144 there's no defined gtype.
2146 * giscanner/utils.py (strip_common_prefix): Always strip common
2147 prefix exactly up to the last "_", and not beyond.
2148 * tests/scanner/foo.h (FooEnumNoType): add FOO_ENUM_NEUF. The point
2149 here is that the first character after the last '_' should should be
2150 the same as the character in the same position on the type name.
2151 * tests/scanner/foo-expected.gir: test that
2153 2008-10-10 Lucas Rocha <lucasr@gnome.org>
2155 Bug 555293: append library_paths to LPATH env variable to work
2156 around a bug in find_library when using ldconfig.
2158 * tools/g-ir-scanner (main): ditto.
2160 2008-10-09 Lucas Rocha <lucasr@gnome.org>
2162 * girepository/girepository.c (register_internal): fix regression on
2163 invoke test case by making sure we load the global module in the
2164 typelib when dealing with inline typelibs.
2165 * girepository/gtypelib.c: a couple of coding style fixes.
2167 2008-10-06 Lucas Rocha <lucasr@gnome.org>
2169 Bug 555294: Add support for multiple shared libraries per typelib.
2171 * girepository/ginvoke.c (g_function_info_invoke),
2172 girepository/ginfo.c(g_registered_type_info_get_g_type): use
2173 g_typelib_symbol instead of g_module_symbol.
2174 * girepository/girepository.h: remove g_typelib_set_module and add
2176 * girepository/gtypelib.[ch] (find_some_symbol, _g_typelib_init,
2177 g_typelib_new_from_memory, g_typelib_new_from_const_memory,
2178 g_typelib_free, g_typelib_symbol): chnage GTypeLib to hold a list of
2179 modules instead of just one. The symbol lookup is now abstracted
2180 behind g_typelib_symbol which tries to find the passed symbol name in
2182 * giscanner/girwriter.py, tools/g-ir-scanner: change scanner to read
2183 and write shared_library attribute as a comma-separated list of libs.
2185 2008-10-06 Colin Walters <walters@verbum.org>
2187 * giscanner/transformer.py: Parse length= annotation as
2188 a parameter name, not a raw int.
2191 2008-10-03 Colin Walters <walters@verbum.org>
2193 Bug 551744: Non-GObject types aren't aggregating ctors and methods
2195 * girepository/gtypelib.c: Allow ctors/methods on struct,union,
2197 * giscanner/glibtransformer.py: Ditto, and GLibBoxed is also a
2201 2008-10-03 Colin Walters <walters@verbum.org>
2203 Bug 554576: scan problem with ev_selection_render_selection()
2205 * giscanner/transformer.py: Only do type resolution once we've
2206 scanned all types. What could happen before is that we'd strip
2207 the namespace from local type "EvSelection" => Selection, and
2208 then later pull a "Selection" from some other namespace because
2209 we hadn't yet seen the local EvSelection. This could come
2210 down to hash table ordering and other things so not easy
2211 to write a test for.
2213 2008-10-03 Lucas Rocha <lucasr@gnome.org>
2215 * giscanner/girwriter.py (_parser_member): fix the last parameter of
2216 GLibEnumMember constructor as it should be the enum member nick.
2218 2008-10-02 Colin Walters <walters@verbum.org>
2220 Bug 552961: remove this parameter for methods
2222 * giscanner/glibtransformer.py: Delete this parameter; it is
2224 * girepository/ginvoke.c: Insert this parameter for methods.
2225 * girepository/gtypelib.c: Remove no longer needed verification of
2226 method this parameter.
2229 2008-09-30 Dan Winship <danw@gnome.org>
2231 Bug 554490: g-ir-scanner gets confused by '\\'
2233 * giscanner/scannerlexer.l (chartext, stringtext): fix use of
2234 backslashes so it will correctly parse '\\' and "\\"
2236 * tests/scanner/annotation.c: add a use of '\\' to make sure that
2239 * giscanner/glibtransformer.py (GLibTransformer.count_type): typo
2241 2008-10-02 Colin Walters <walters@verbum.org>
2243 bug 552393: Note variadic functions
2245 * giscanner/scannerparser.y: Parse ellipsis. Refactor grammar
2246 to use parameter_list directly.
2247 * giscanner/sourcescanner.h: Add ellipsis csymbol type.
2248 * giscanner/ast.py: Add Varargs type.
2249 * giscanner/transformer.py: Check for ellipsis symbol, transform
2251 * girepository/girnode.h: Add varargs flag to in-memory nodes.
2252 Parse varargs functions, but filter them out before we start
2253 compiling the typelib.
2255 2008-10-02 Colin Walters <walters@verbum.org>
2257 Bug 554632: type tag for GType
2259 * girepository/girepository.h, girepository/girepository.c:
2260 Add type tag for GType - it's a special type we don't want
2261 to resolve to just "long".
2262 * docs/typelib-format.txt: Update.
2263 * girepository/girparser.c: Parse it.
2264 * giscanner/glibtransformer.py: Ensure we don't put GType in
2266 * tools/generate.c: Remove hardcoded type list.
2269 2008-09-30 Dan Winship <danw@gnome.org>
2271 Bug 554521: scanner generates wrong names for enum members with
2272 full type name prefix
2274 * giscanner/utils.py (strip_common_prefix): Fix this to strip the
2275 right amount when the entire "first" string is a prefix of
2278 * tests/scanner/foo.h (FooEnumFullname):
2279 * tests/scanner/foo-expected.gir: test that
2281 2008-09-29 Colin Walters <walters@verbum.org>
2283 Bug 552380: Array parameters should be marked in the gir
2285 * giscanner/ast.py: Default char** to utf8[], and guchar* to
2286 uint8[]. Add Array, List, and Map subclasses of Type;
2287 these types can be generic. Return transfer defaults
2288 to true if return value is string or container type.
2289 Delete Sequence type.
2290 * giscanner/scannerlexer.l: Syntax change for annotations;
2291 use <> since it's more readable.
2292 * giscanner/girwriter.py: Write out these changes.
2293 * giscanner/girparser.py: Parse them.
2294 * giscanner/transformer.py: Have a defined set of
2295 both list and map types. When creating a type,
2296 check if the ctype we've parsed is one of them,
2297 if so create a container type subclass as appropriate.
2298 * girepository/girparser.c: Parse in generic types.
2301 2008-09-27 Colin Walters <walters@verbum.org>
2303 * tools/g-ir-scanner: Add --inject option.
2305 2008-09-25 Colin Walters <walters@verbum.org>
2307 Remove non-repository types from GIR
2309 * giscanner/ast.py: The canonical name is 'utf8', not
2311 * giscanner/glibast.py: A few more glib type mappings.
2312 * girepository/girparser.c: We only parse repository types.
2313 * tests/*.gir: Update.
2315 2008-09-23 Colin Walters <walters@verbum.org>
2317 Bug 552566: Add time_t type
2319 We need a type for time_t since it's special in C, and just
2320 mapping it to long precluded bindings from handling it
2323 2008-09-19 Colin Walters <walters@verbum.org>
2325 Bug 552390: Handle capitialization like "DBus" more robustly
2327 The to_underscores function was designed for use against prefixed
2328 names; we need a separate function which will convert names like
2329 DBusFoo into dbus_foo, not d_bus_foo.
2331 2008-09-19 Colin Walters <walters@verbum.org>
2333 Add check to make sure we're not hitting out unresolved types
2335 Validate the "this" argument for methods
2337 Remove heuristic matching of methods to classes based on prefix
2339 It was a broken hack that dated from when we handled underscoring
2340 and capitalization conventions less well.
2342 2008-09-18 Colin Walters <walters@verbum.org>
2344 Bug 552384: Use SHLIB_SUFFIX intead of G_MODULE_SUFFIX for Darwin
2346 On Darwin, the suffix for installed shared libraries (.dylib) is
2347 different from loadable modules (.so). We use a bit of magic shell
2348 script from Behdad Esfahbod to figure out the right suffix.
2350 2008-09-15 Johan Dahlin <johan@gnome.org>
2352 * giscanner/sourcescanner.py (SourceType.type_qualifier): Add
2353 a wrapper for type_qualifier as well.
2355 2008-09-15 Colin Walters <walters@verbum.org>
2357 http://bugzilla.gnome.org/show_bug.cgi?id=552065
2359 * giscanner/ast.py: Add deprecation attributes.
2360 * giscanner/girwriter.py: Write out deprecation data.
2361 * girepository/girparser.c: Relax parsing; deprecated
2362 attribute now includes freeform string.
2363 * giscanner/scannerlexer.l: Parse Deprecated.
2364 * giscanner/transformer.py: Look for deprecated attribute
2366 * tests/scanner/*: Add a Deprecated test.
2368 2008-09-14 Tor Lillqvist <tml@novell.com>
2370 * tests/scanner/Makefile.am (%.typelib): Use $(EXEEXT).
2372 2008-09-14 Colin Walters <walters@verbum.org>
2374 * giscanner/glibtransformer.py: Ignore functions with
2377 2008-09-12 Colin Walters <walters@verbum.org>
2379 * giscanner/glibtransformer.py: Accept Gtk.Type as GType.
2381 2008-09-12 Colin Walters <walters@verbum.org>
2383 * giscanner/ast.py: Bind pid_t to INT for vte.
2385 2008-09-12 Colin Walters <walters@verbum.org>
2387 * giscanner/girparser.py: Parse c:type for boxed records/unions.
2388 * giscanner/glibast.py: Avoid overwriting ctype.
2389 * giscsanner/transformer.py: Try resolving types using the GType names.
2391 2008-09-12 Colin Walters <walters@verbum.org>
2393 * giscanner/minixpath.py: Code to run an "XPath"
2394 assertion against an XML tree, taken from
2395 gir-repository/gir/tests.py.
2396 * giscanner/Makefile.am: Ship it.
2397 * tools/g-ir-scanner: Add --xpath-assertions option.
2398 * gir/GLib-assertions.txt: Add a few assertions.
2399 * gir/Makefile.am: Run them.
2401 2008-09-11 Colin Walters <walters@verbum.org>
2403 http://bugzilla.gnome.org/show_bug.cgi?id=551737
2405 * giscanner/transformer.py: Fix strip_namespace_func to only strip
2406 prefix if it ends with _. Tweak callback stripping to determine
2407 based on presence of _ whether we need to use strip_namespace_func
2408 or strip_namespace_object.
2410 2008-09-09 Owen Taylor <otaylor@redhat.com>
2412 * docs/typelib-format.txt: Wether => Whether
2414 2008-09-08 Colin Walters <walters@verbum.org>
2416 * girepository/girparser.c: Default to "readable" for properties.
2417 * giscanner/ast.py: Add readable, writable etc.
2418 * giscanner/girwriter.py: Writ them.
2419 * giscanner/glibtransformer.py: Inspect them.
2422 2008-09-07 Colin Walters <walters@verbum.org>
2424 * giscanner/cgobject.py: Add comment.
2426 2008-09-07 Colin Walters <walters@verbum.org>
2428 * giscanner/cgobject.py: Also call g_thread_init.
2430 2008-09-07 Colin Walters <walters@verbum.org>
2432 * giscanner/transformer.py: Fix regression by not
2433 stripping prefix before stripping namespace for unions
2436 2008-09-06 Colin Walters <walters@verbum.org>
2438 * giscanner/transformer.py: If a namespace contains
2439 multiple caps, try stripping both gnomekeyring_ and
2442 2008-09-07 Johan Dahlin <johan@gnome.org>
2444 Bug 551162 – giscanner does not recognize asm and __asm__
2445 * giscanner/scannerlexer.l:
2446 Patch by Jani Monoses.
2448 2008-09-06 Colin Walters <walters@verbum.org>
2450 * girepository/girnode.c: Allow gtype_name
2451 and gtype_init in struct and union.
2452 * girepository/girparser.c: Parse glib:
2453 boxed bits for both structure and union.
2454 * girepository/gtypelib.c: Don't barf
2455 if structure is boxed.
2456 * giscanner/girparser.py: Parse new XML
2458 * giscanner/girwriter.py: Write out new
2460 * giscanner/glibast.py: Define new classes
2461 which are both Boxed and Struct/Union, as
2462 well as an "Other" for everything else.
2463 * giscanner/glibtransformer.py: Handle
2464 boxed types specially; we try to merge
2465 them with a struct/union if one exists,
2466 otherwise fall back to generic boxed.
2468 * tools/generate.c: Write out new format.
2470 2008-09-06 Johan Dahlin <johan@gnome.org>
2472 * giscanner/grealpath.h: Include stdlib.h
2474 * docs/g-ir-generate.1: Remove leading %
2476 2008-09-01 Colin Walters <walters@verbum.org>
2478 * girepository/girparser.c: Look at c:type to determine
2479 whether or not an item is a pointer.
2481 2008-09-01 Johan Dahlin <johan@gnome.org>
2483 * tests/scanner/Makefile.am:
2484 Set PYTHONPATH so the scanner can run
2485 even if you didn't install anything.
2487 2008-09-01 Johan Dahlin <johan@gnome.org>
2490 Post-release version bump
2493 2008-09-01 Johan Dahlin <johan@gnome.org>
2497 2008-08-31 Colin Walters <walters@verbum.org>
2499 * giscanner/glibtransformer.py: Quiet info
2502 2008-08-31 Johan Dahlin <johan@gnome.org>
2505 Bump version to 0.5.0
2507 2008-08-31 Colin Walters <walters@verbum.org>
2509 * giscanner/glibtransformer.py: Follow aliases to ensure
2510 we don't get a constructor returning a basic type.
2511 * giscanner/transformer.py: Add function to follow aliases.
2514 2008-08-31 Johan Dahlin <johan@gnome.org>
2516 * giscanner/scannerlexer.l:
2517 * giscanner/scannerparser.y:
2518 * giscanner/sourcescanner.h:
2519 * giscanner/sourcescanner.py:
2520 Parse GCC extensions in the parser instead of just undeffing them
2521 in the pre-processor.
2523 2008-08-31 Johan Dahlin <johan@gnome.org>
2525 * giscanner/glibtransformer.py:
2526 Clean up a huge if. Do not add methods or constructors
2528 * giscanner/utils.py:
2529 second might be longer than first, check that.
2531 2008-08-31 Johan Dahlin <johan@gnome.org>
2536 2008-08-31 Colin Walters <walters@verbum.org>
2538 * girepository/girparser.c: Don't lose if we
2541 2008-08-31 Colin Walters <walters@verbum.org>
2543 * giscanner/glibtransformer.py: Look for libtool
2544 library in current directory
2545 * tests/scanner - Update.
2547 2008-08-30 Colin Walters <walters@verbum.org>
2549 * docs/typelib-format.txt: Add a guint32
2551 * gir/Makefile.am: Dep on Makefile
2552 * girepository/ginfo.c:
2553 * girepository/girepository.c: Clean up
2554 default typelib handling; remove global
2555 default_typelib variable. Ensure we handle
2556 NULL repository in more places.
2557 Support dependency resolution.
2558 Support lazy loading.
2559 * girepository/girepository.h: Remove
2560 g_irepository_unregister; we don't support
2561 unloading typelibs since really they're
2562 process-global. Update for lazy loading
2564 * girepository/girmodule.c: Use g_new0.
2565 Add dependencies to GirModule.
2566 * girepository/girparser.c: Parse dependencies.
2567 * girepository/gtypelib.c: Add 4 bytes for
2569 * tests/Makefile.am: Kill off gobject.gir,
2570 it conflicts with the real one.
2571 * tests/object.gir: Dep on GObject.
2572 * tools/generate.c: Take --includedir
2573 argument to say which directories to search
2574 for typelibs. Print out dependencies.
2576 2008-08-30 Colin Walters <walters@verbum.org>
2578 * giscanner/glibtransformer.py: Reduce warning noise.
2580 2008-08-29 Colin Walters <walters@verbum.org>
2582 * girepository/ginfo.c: Add some assertions regarding
2583 refcounts, just to be sure.
2584 * giscanner/glibtransformer.py: Blacklist a few more
2587 2008-08-29 Colin Walters <walters@verbum.org>
2589 * giscanner/glibtransformer.py: Blacklist a few
2590 functions that use GError oddly
2592 2008-08-29 Colin Walters <walters@verbum.org>
2594 * girepository/gtypelib.c: Don't crash if no
2597 2008-08-29 Colin Walters <walters@verbum.org>
2599 * girepository/girparser.c: Handle chains of aliases
2600 across modules by ensuring we fully qualify aliases
2603 2008-08-29 Colin Walters <walters@verbum.org>
2605 * girepository/girparser.c: Don't search aliases
2608 2008-08-29 Colin Walters <walters@verbum.org>
2610 * girepository/girparser.c: Rewrite type parsing
2611 to handle both GLib parsing case as well as correctly
2612 handling GLib.List and friends. Don't try to treat
2613 e.g. ListStore as a List.
2615 2008-08-29 Colin Walters <walters@verbum.org>
2617 * girepository/gtypelib.c: Add more context
2620 2008-08-29 Colin Walters <walters@verbum.org>
2622 * giscanner/glibtransformer.py: Add some informative
2623 logging messages in corner cases. Be sure we use
2624 the most recent node set instead of a cache
2625 when generating result set.
2626 * tests/: Remove duplicated bits in expected girs
2627 * girepository/girparser.c: Accept both List (for
2628 compiling GLib) and GLib.List (what the scanner
2631 * tools/generate.c: Generate canonical form.
2633 2008-08-29 Johan Dahlin <johan@gnome.org>
2635 * giscanner/config.py.in:
2636 Use datarootdir instead of datadir to avoid
2637 an autoconf warning.
2639 2008-08-29 Johan Dahlin <johan@gnome.org>
2643 * examples/gdk-pixbuf.gidl:
2645 Update and remove old cruft.
2647 2008-08-29 Johan Dahlin <johan@gnome.org>
2650 * docs/g-ir-compiler.1:
2651 * docs/g-ir-generate.1:
2652 * docs/g-ir-scanner.1:
2653 Add man pages for the generator and compiler.
2655 2008-08-29 Johan Dahlin <johan@gnome.org>
2657 * docs/g-ir-scanner.1: Document
2659 * giscanner/Makefile.am:
2660 * giscanner/gidlparser.py:
2661 * giscanner/gidlwriter.py:
2662 * tools/g-ir-scanner:
2663 Remove gidl support.
2665 2008-08-28 Colin Walters <walters@verbum.org>
2667 * tests/scanner/Makefile.am: Pass the right
2668 --includedir args. Add a Makefile dep.
2669 * tools/compiler.c: Pass includedirs down.
2670 * girepository/girparser.c: Actually put
2671 includedirs in context, pass down. Fix
2674 2008-08-28 Colin Walters <walters@verbum.org>
2676 * gir/Makefile.am: Use --includedir
2677 * girepository/girparser.c: Recursively parse
2678 includes to pull in aliases and expand them.
2679 We need this to avoid putting unknown names in
2681 * tools/compiler.c: Add --includedir option.
2682 * giscanner/ast.py: Map size/ssize to types
2685 2008-08-28 Tor Lillqvist <tml@novell.com>
2687 Make check now runs successfully on Windows.
2689 * tools/compiler.c (write_out_typelib): Use binary mode for output
2692 * girepository/girnode.c: Don't print NULL strings.
2694 * tests/invoke/Makefile.am
2695 * tests/scanner/Makefile.am: Use -no-undefined on Windows to
2696 convince libtool to build shared libraries.
2698 * tests/invoke/invoke.c: Don't needlessly include <dlfcn.h>. Use
2699 g_assert() instead of printing out expected errors.
2701 2008-08-28 Tor Lillqvist <tml@novell.com>
2703 * girepository/gtypelib.h: Change type of bitfield fields from
2704 guint to the most suitable smaller type. This makes the struct
2705 sizes match the ones on Linux that the sanity check expects when
2706 using gcc -mms-bitfields on Windows.
2708 2008-08-28 Johan Dahlin <johan@gnome.org>
2713 * giscanner/Makefile.am:
2714 * tests/Makefile.am:
2715 * tests/scanner/Makefile.am:
2716 Make distcheck pass.
2718 2008-08-27 Johan Dahlin <johan@gnome.org>
2720 * giscanner/Makefile.am:
2721 Only send in -no-undefined on Win32 as it breaks on MacOS X.
2723 2008-08-27 Tor Lillqvist <tml@novell.com>
2725 Make g-ir-scanner work on Windows. Still problems with the typelib
2726 code. Changes okayed by jdahlin.
2728 * configure.ac: Check for Windows, set Automake conditional
2729 OS_WIN32. Change backslashes to forward slashes in pyexecdir to
2730 avoid shell quoting issues
2732 * girepository/Makefile.am: Use -no-undefined so that libtool
2733 agrees to build a shared library on Windows.
2735 * girepository/girparser.c (backtrace_stderr): No backtrace() on
2736 Windows. Empty implementation on Windows so far.
2738 * girepository/gtypelib.c (g_typelib_check_sanity): Give more
2739 informative error message for the assertion failures. Tell also
2740 what the expected size of the struct is. Check all sizes first and
2741 fail afterwards if at least one size was different from expected.
2743 * tools/Makefile.am: Reorder libraries into proper logical
2746 * tools/generate.c: Don't include <dlfcn.h>, not used.
2748 * giscanner/Makefile.am: On Windows, link with the Python library,
2749 and install the module DLL as _giscanner.pyd. Remove the
2750 unnecessary import library and libtool library that libtool has
2753 * giscanner/scannerlexer.l: Recognize the gcc __attribute__ syntax
2754 and just skip it. Recognize also two "l" suffixes for long long
2755 constants. Recognize also __inline__.
2757 * giscanner/grealpath.h (g_realpath): Implement on Windows, using
2758 GetFullPathName(). As such, GetFullPathName() does more than the
2759 UNIX realpath(). It also changes relative paths into absolute
2760 paths. But for our purposes that shouldn't matter.
2762 * giscanner/giscannermodule.c (pygi_source_scanner_parse_file): On
2763 Windows the file descriptor passed to us is from Python. Python
2764 Python2.5 uses the msvcr71.dll C library, while mingw-built code
2765 uses msvcrt.dll. On Windows, file descriptors are specific to
2766 which C library is used. So we must find out what underlying OS
2767 handle corresponds to the file descriptor Python passes us, and
2768 then make that into a file descriptor valid for the C library this
2771 * giscanner/sourcescanner.py (_parse): Don't need to bypass
2772 __attribute__ as the lexer now handles it. The definition as empty
2773 was ineffective for mingw anyway, as mingw's _mingw.h undefines
2774 __attribute__. Close the temp file before unlinking it.
2776 * giscanner/cgobject.py: Use correct library name for the gobject
2779 * gir/Makefile.am: Must pass the full basename of the DLLs on
2780 Windows to g-ir-scanner. It's a bit ugly that we have to "know"
2781 that the names of the GLib DLLs are like libglib-2.0-0.dll, but in
2782 reality they won't change, until there is a GLib 3, and then also
2783 the Unix code here needs changing.
2785 Must pass CPPFLAGS to g-ir-scanner when building GLib.gir so that
2788 2008-08-26 Colin Walters <walters@verbum.org>
2790 * girepository/girepository.c: Search
2791 $DATADIR/girepository instead of
2792 $DATADIR/gitypelibs; this naming makes
2793 it clearer that e.g. jgir can install
2795 * gir/Makefile.am: Install there.
2797 2008-08-26 Colin Walters <walters@verbum.org>
2799 * girepository/gtypelib.c (_g_typelib_init): Also
2800 use G_MODULE_SUFFIX instead of hardcoding .so.
2802 2008-08-26 Colin Walters <walters@verbum.org>
2804 * girepository/gtypelib.c (_g_typelib_init): Free
2805 string in the right place.
2807 2008-08-26 Colin Walters <walters@verbum.org>
2809 * girepository/gtypelib.c (_g_typelib_init): Handle
2810 both .la and .so names; this works better in the
2811 uninstalled library case.
2813 2008-08-26 Johan Dahlin <johan@gnome.org>
2816 * giscanner/Makefile.am:
2817 * giscanner/cgobject.py:
2818 * giscanner/config.py.in:
2819 * giscanner/sourcescanner.py:
2820 Avoid undeffing __GNUC__, instead define
2821 __attribute__ & friends. Remove glibconfig.h hack.
2822 This makes gobject-introspection work better on
2823 MacOS X, Thanks to Richard Hult for kind help.
2825 2008-08-25 Colin Walters <walters@verbum.org>
2827 * giscanner/glibtransformer.py: Always print
2830 2008-08-25 Colin Walters <walters@verbum.org>
2832 * giscanner/glibtransformer.py: Skip over
2833 interfaces we don't know.
2835 2008-08-25 Colin Walters <walters@verbum.org>
2837 * girepository/girparser.c: Parse new implements
2838 syntax, drop gapi one.
2839 * tests/object.gir: Update.
2840 * tools/generate.c: Generate new syntax.
2842 2008-08-25 Colin Walters <walters@verbum.org>
2844 * giscanner/ast.py: Add interfaces property
2846 * giscanner/girwriter.py: Write out implemented
2848 * giscanner/glibtransformer.py: Introspect
2849 implemented interfaces.
2850 * tests/scanner/*: Make FooObject implement
2853 2008-08-25 Colin Walters <walters@verbum.org>
2855 * giscanner/glibtransformer.py: More correctly pair
2856 methods; if we have a symbol that starts with
2857 e.g. hippo_canvas look for a matching HippoCanvas
2858 class before accepting e.g. HippoCanvasImage.
2860 2008-08-24 Colin Walters <walters@verbum.org>
2862 * tools/g-ir-scanner: Filter out unknown options from
2865 2008-08-24 Colin Walters <walters@verbum.org>
2867 * giscanner/glibtransformer.py: Fail with better
2868 error if we can't find library.
2870 2008-08-24 Colin Walters <walters@verbum.org>
2872 * tools/g-ir-scanner: Use subprocess instead of
2873 commands, works on Windows and avoids the evil
2876 2008-08-24 Colin Walters <walters@verbum.org>
2878 * giscanner/glibtransformer.py: Skip over
2879 g_object_get_type from GLib trunk.
2881 2008-08-24 Colin Walters <walters@verbum.org>
2883 * girepository/girepository.c (g_irepository_require):
2884 Don't open shared library here; we already do it
2887 2008-08-24 Colin Walters <walters@verbum.org>
2889 * girepository/gtypelib.c: Add context stack so
2890 when we get an error we can print out nicely
2893 2008-08-24 Johan Dahlin <johan@gnome.org>
2895 * girepository/girparser.c (start_glib_boxed), (start_function),
2896 (start_field), (start_alias):
2897 Refactor a couple of parsing functions to be simpler to follow.
2900 2008-08-24 Johan Dahlin <johan@gnome.org>
2902 * girepository/girparser.c (start_function):
2903 Remove left-over code, checking type of function.
2905 2008-08-23 Colin Walters <walters@verbum.org>
2907 * giscanner/config.py: Define DATADIR.
2908 * giscanner/transformer.py: Look in DATADIR.
2910 2008-08-23 Colin Walters <walters@verbum.org>
2912 * girepository/gtypelib.c: Check constructor
2914 * girepository/girnode.c: Small tweaks.
2915 * girepository/ginfo.c: Calculate signature offsets
2917 * girepository/girparser.c: Remove duplicate
2919 * giscanner/glibtransformer.py: Avoid marking
2920 functions which return a basic type as
2923 2008-08-23 Colin Walters <walters@verbum.org>
2925 * girepository/girparser.c: Ignore <include>.
2926 * giscanner/girparser.py: Parse them.
2927 * giscanner/girwriter.py: Generate them.
2928 * giscanner/transformer.py: Process <include>
2929 recursively. Don't require full path for
2930 includes, look in {$XDG_DATA_DIRS}/gir.
2931 * tools/g-ir-scanner: Pass through includes.
2932 * Makefile.am: Remove extra --include
2934 * *-expected.gir: Add expected includes.
2936 2008-08-23 Johan Dahlin <johan@gnome.org>
2938 * tests/scanner/Makefile.am:
2939 * tests/scanner/annotation-expected.gir:
2940 * tests/scanner/drawable-expected.gir:
2941 Avoid duplication in the Makefile, regenerate with new
2942 namespaces (same as the filename)
2944 2008-08-22 Colin Walters <walters@verbum.org>
2946 * girepository/girnode.c: Don't hardcode integers,
2949 2008-08-22 Johan Dahlin <johan@gnome.org>
2951 * giscanner/sourcescanner.py:
2952 Check for ../gobject-introspection-1.0.pc.in to determine
2953 if we run installed or uninstalled.
2955 2008-08-22 Johan Dahlin <johan@gnome.org>
2958 * giscanner/sourcescanner.py:
2959 Send in undefs/defines via writing it directly to stdin
2960 of cpp instead of via arguments.
2962 2008-08-22 Colin Walters <walters@verbum.org>
2964 * tools/generate.c, tools/compiler.c: Default
2966 * all Makefile.am: Update.
2968 2008-08-22 Colin Walters <walters@verbum.org>
2970 * girepository/girparser.c: Pass through
2971 recursive types. Avoid overwriting errors.
2972 * giscanner/xmlwriter.py: Always write the
2974 * tests/*.gir: Adjust.
2975 * tests/scanner/Makefile.am: Build typelibs,
2976 and generate XML from those. Once we
2977 have a good diff mechanism...
2978 * tests/scanner/*-expected.gir: Add XML
2980 * tools/g-ir-scanner: Accept --typelib-xml
2982 * tools/generate.c: Better defaults for transfer.
2984 2008-08-22 Johan Dahlin <johan@gnome.org>
2988 * giscanner/Makefile.am:
2989 * giscanner/config.py.in:
2990 * giscanner/sourcescanner.py:
2991 Use the generated glibconfig.h for all scanner invokations.
2992 Rename it to glibconfig-scanner.h and install it.
2993 Add a config.py which so far contains the include dir.
2995 2008-08-22 Johan Dahlin <johan@gnome.org>
2998 Replace glibconfig.h with our own, do some replacement
2999 for CPP/C features we do not support
3001 2008-08-22 Colin Walters <walters@verbum.org>
3003 * tools/generate.c (write_callable_info): Fix unref
3006 2008-08-22 Colin Walters <walters@verbum.org>
3008 * gobject-introspection-1.0.pc.in: Add g-ir-generate.
3009 * tests/Makefile.am: Support $(DEBUG)
3010 * tools/generate.c: Do immediate close tags if no
3013 2008-08-21 Colin Walters <walters@verbum.org>
3015 * tests/scanner/drawable-expected.gir,
3016 * tests/scanner/drawable.c,
3017 * tests/scanner/drawable.h:
3020 2008-08-21 Colin Walters <walters@verbum.org>
3022 * giscanner/glibtransformer.py: Compute prefix
3023 by searching through the symbol for bits
3024 rather than going directly from ctype; this fixes
3027 2008-08-21 Colin Walters <walters@verbum.org>
3029 * giscanner/glibtransformer.py: Also try squashing
3030 underscores from namespace, fixes webkit_web_view_new.
3032 2008-08-21 Colin Walters <walters@verbum.org>
3034 * giscanner/glibtransformer.py: More ctor work,
3035 avoid having gtk_window_group_new end up under
3038 2008-08-21 Colin Walters <walters@verbum.org>
3040 * giscanner/glibtransformer.py: Much simpler approach
3041 of mapping uscored names to classes.
3042 * giscanner/utils.py: Remove unnecessary function.
3044 2008-08-21 Johan Dahlin <johan@gnome.org>
3046 * girepository/girepository.c (g_irepository_require):
3047 Plug memory leak and avoid using freed memory.
3048 Resolve the whole module path, here as well.
3050 2008-08-21 Colin Walters <walters@verbum.org>
3052 * giscanner/glibtransformer.py: Look up all permutations
3053 of class names when scanning methods/ctors based on
3054 the prefix instead of using the return value. This
3055 associates gtk_window_new with the right class.
3057 2008-08-21 Colin Walters <walters@verbum.org>
3059 * girepository/girmodule.c (g_ir_module_build_typelib):
3060 Revert change to increment header_size; we do that in
3063 2008-08-21 Colin Walters <walters@verbum.org>
3065 * girepository/girnode.c (write_string): Tweak to
3066 use UINT instead of INT. Not likely to matter.
3067 * girepository/girmodule.c (g_ir_module_build_typelib):
3068 Add to header_offset as well for header strings
3069 to match what write_string does.
3070 * girepository/gtypelib.c: Replace is_name with
3071 validate_name, which more strongly validates and
3072 handles errors in a better way. Update all callers.
3073 * giscanner/glibtransformer.py: Handle constructors
3076 2008-08-21 Johan Dahlin <johan@gnome.org>
3078 * gir/Makefile.am (typelibs_DATA): Build and
3079 install the Gio.typelib too
3081 * girepository/gtypelib.c (_g_typelib_init):
3082 Use g_module_build_path to resolve the shlib name
3084 2008-08-21 Colin Walters <walters@verbum.org>
3086 * gir/Makefile.am: CLEANFILES typelibs too.
3088 2008-08-21 Johan Dahlin <johan@gnome.org>
3090 * giscanner/glibtransformer.py:
3091 Do not send .la files through find_library.
3093 2008-08-21 Colin Walters <walters@verbum.org>
3095 * girepository/girparser.c (g_irepository_require):
3096 Fix one small leak in error case.
3098 2008-08-21 Johan Dahlin <johan@gnome.org>
3101 Parse glibconfig.h as well and install the compiled
3104 2008-08-21 Johan Dahlin <johan@gnome.org>
3107 * giscanner/glibtransformer.py:
3108 * tools/g-ir-scanner:
3109 Do not hard-core library names in the Makefile, reuse
3110 ctypes find_library instead.
3112 2008-08-21 Johan Dahlin <johan@gnome.org>
3114 * girepository/girparser.c (resolve_aliases):
3115 Remove compilation warnings
3117 2008-08-21 Johan Dahlin <johan@gnome.org>
3119 * girepository/girepository.c (g_irepository_require):
3120 Rewrap and fix double free bug by leaking a bit.
3122 2008-08-20 Colin Walters <walters@verbum.org>
3124 * girepository/girepository.c: Add new function
3125 g_irepository_get_typelib_path which tells
3126 us from where we loaded a namespace.
3128 2008-08-20 Colin Walters <walters@verbum.org>
3130 * tests/scanner/*-expected.gir: Adjust for
3131 added shared-library.
3132 * giscanner/giwriter.py: Make pylint happy.
3134 2008-08-20 Colin Walters <walters@verbum.org>
3136 * girepository/girmodule.c (g_ir_module_build_typelib):
3137 Calculate size correctly, avoid use-after-free.
3139 2008-08-20 Colin Walters <walters@verbum.org>
3141 * girepository/girepository.c: Remove
3142 g_irepository_register_file in favor of
3143 g_irepository_require. There are two
3144 possible deployment scenarios for typelibs:
3145 First, separate in $DATADIR/gitypelibs/. Second,
3146 they may be embedded in shlibs. However since
3147 the first is now the normal case, the API is
3148 optimized around it.
3150 Refactor internals to look up typelibs for
3151 namespaces just-in-time, but we expect
3152 consumers to call g_irepository_require.
3154 Also, add some docs. No one has died from that
3156 * gir/Makefile.am: Need --library for glib.
3157 * giscanner/girwriter.py: Write out shared-library.
3158 * tools/g-ir-writer: Take the first --library
3159 argument as the target of shared-library. In
3160 the future we should make this nicer with pkg-config
3163 2008-08-20 Colin Walters <walters@verbum.org>
3165 * girepository/girparser.py: And parse them.
3167 2008-08-20 Johan Dahlin <johan@gnome.org>
3169 * giscanner/glibast.py: Add gshort/gushort types
3171 2008-08-20 Colin Walters <walters@verbum.org>
3173 * gir/Makefile.am: Rename .gir files using GI namespace.
3174 * girepository/girepository.c: Use XDG_DATA_DIRS for
3175 looking up typelibs. Also typelibs are now suffixed
3177 * tests/invoke/Makefile.am: Only use metadata.
3178 * girepository/Makefile.am: Remove unnecessary include.
3179 * tests/scanner/Makefile.am: Update using GI namespaces
3180 for scanner includes.
3182 2008-08-20 Colin Walters <walters@verbum.org>
3184 * girepository/transformer.py: Suppress aliases whose
3186 * girepository/ast.py: Define some more aliases.
3188 2008-08-20 Colin Walters <walters@verbum.org>
3190 * girepository/girparser.c: Avoid alias infloops.
3192 2008-08-20 Colin Walters <walters@verbum.org>
3194 * tests/scanner/foo-expected.gir: Fix expected list type.
3196 2008-08-20 Johan Dahlin <johan@gnome.org>
3198 * giscanner/glibtransformer.py (GLibTransformer._resolve_type_name):
3199 Add a workaround for #548689.
3200 We can now compile gtk!
3202 2008-08-20 Colin Walters <walters@verbum.org>
3204 * giscanner/glibtransformer.py: Try to look up
3205 aliases using the c:type too.
3207 2008-08-20 Colin Walters <walters@verbum.org>
3209 * girepository/girparser.c: Parse union fields.
3211 2008-08-20 Johan Dahlin <johan@gnome.org>
3213 * giscanner/ast.py: Make time_t an alias for long
3215 * gir/gio-2.0-good.gir:
3216 * gir/glib-2.0-good.gir:
3217 * gir/gobject-2.0-good.gir:
3219 * giscanner/glibtransformer.py:
3220 Do not delete Class structures, we need them in gdk/gtk.
3221 * tests/scanner/drawable-expected.gir:
3222 * tests/scanner/foo-expected.gir:
3223 * tests/scanner/utility-expected.gir:
3226 2008-08-20 Johan Dahlin <johan@gnome.org>
3228 * tests/scanner/Makefile.am:
3229 * tests/scanner/annotation-expected.gir:
3230 * tests/scanner/annotation.c (annotation_object_class_init),
3231 (annotation_object_init), (annotation_object_method),
3232 (annotation_object_in), (annotation_object_out),
3233 (annotation_object_inout), (annotation_object_inout2),
3234 (annotation_object_inout3), (annotation_object_calleeowns),
3235 (annotation_object_calleesowns), (annotation_object_get_strings),
3236 (annotation_object_with_voidp), (annotation_object_get_objects),
3237 (annotation_object_create_object), (annotation_object_allow_none):
3238 * tests/scanner/annotation.h:
3239 * tests/scanner/foo-expected.gir:
3240 * tests/scanner/foo.c:
3241 * tests/scanner/foo.h:
3242 Split out annotation tests out of foo
3244 2008-08-20 Johan Dahlin <johan@gnome.org>
3246 * tests/scanner/Foo-expected.gir:
3247 * tests/scanner/Makefile.am:
3248 * tests/scanner/foo-expected.gir:
3249 * tests/scanner/foo-object.h:
3250 * tests/scanner/foo.c:
3251 Foo->foo, foo-object.h -> foo.h
3253 2008-08-20 Johan Dahlin <johan@gnome.org>
3255 * tests/scanner/Foo-expected.gir:
3256 * tests/scanner/Makefile.am:
3257 * tests/scanner/drawable-expected.gir:
3258 * tests/scanner/drawable.c (test_drawable_class_init),
3259 (test_drawable_init):
3260 * tests/scanner/drawable.h:
3261 * tests/scanner/foo-object.h:
3262 * tests/scanner/foo.c (foo_boxed_method):
3263 Move the drawable parts out of Foo to its own test.
3265 2008-08-20 Johan Dahlin <johan@gnome.org>
3267 * tests/scanner/Foo-expected.gir:
3268 * tests/scanner/foo-object.h:
3269 * tests/scanner/foo.c (foo_drawable_class_init),
3270 (foo_drawable_init):
3271 Add a based on GdkDrawable which generates
3274 2008-08-19 Colin Walters <walters@verbum.org>
3276 * giscanner/transformer.py: Don't try
3277 to strip prefix before namespace.
3279 2008-08-19 Johan Dahlin <johan@gnome.org>
3281 * giscanner/transformer.py:
3282 * tests/scanner/Foo-expected.gir:
3283 * tests/scanner/foo-object.h:
3284 Add support for typedef void foo type of
3287 2008-08-19 Johan Dahlin <johan@gnome.org>
3290 * giscanner/girwriter.py:
3291 * giscanner/glibtransformer.py:
3292 * giscanner/transformer.py:
3293 * tests/scanner/Foo-expected.gir:
3294 Add basic support for union, base the code much
3295 on Struct. Add a testcase.
3297 2008-08-19 Johan Dahlin <johan@gnome.org>
3299 * tests/scanner/Foo-expected.gir:
3300 * tests/scanner/foo-object.h:
3301 Add a union testcase which the compiler currently
3304 2008-08-19 Johan Dahlin <johan@gnome.org>
3306 * gobject-introspection-1.0.pc.in:
3307 Add a g_ir_compiler variable
3309 2008-08-19 Colin Walters <walters@verbum.org>
3311 * giscanner/ast.py: Rework types to be more closely
3313 * giscanner/girparser.py: Parse more bits.
3314 * giscanner/girwriter.py: Write sequences in a new
3315 way that specifies container type.
3316 * giscanner/glibast.py: Adjust for ast.py changes,
3317 add 'ctype' property to GLibObject and GLibInterface
3318 so we can look things up by it later.
3319 * gicanner/transformer.py: Names is new class holding
3320 the various namespaces we manage. Do not confuse
3321 with Namespace which is toplevel XML node effectively.
3322 Rework all type resolution to go through
3323 _resolve_type_name_1.
3324 * giscanner/glibtransformer.py: Raise UnknownTypeError
3325 instead of ValueError for cleanliness. Add Unresolved
3326 class to mark types whose parent we haven't seen yet.
3327 Use new Names object from transformer.py.
3328 Correctly look up parent=.
3329 Fix type validation to handle sequences.
3330 * tests/scanner/Foo-expected.gir: Update for sequence
3331 work, int instead of int32.
3332 * tools/g-ir-scanner: Add --noclosure option
3333 * gir/Makefile.am: Use --noclosure by default for
3336 2008-08-18 Johan Dahlin <johan@gnome.org>
3338 * gir/gio-2.0-good.gir:
3339 * gir/glib-2.0-good.gir:
3340 * gir/gobject-2.0-good.gir:
3343 2008-08-18 Johan Dahlin <johan@gnome.org>
3346 * giscanner/girparser.py:
3347 * giscanner/girwriter.py:
3348 * giscanner/glibast.py:
3349 * giscanner/glibtransformer.py:
3350 * giscanner/transformer.py:
3351 * tests/scanner/Foo-expected.gir:
3352 * tests/scanner/foo-object.h:
3353 * tests/scanner/utility-expected.gir:
3354 * tests/scanner/utility.h:
3355 Redo type resolving and validation.
3356 Add a couple of new tests.
3357 Patch mostly written by Colin.
3359 2008-08-18 Johan Dahlin <johan@gnome.org>
3362 * giscanner/girparser.py:
3364 * giscanner/transformer.py:
3365 Improve enum parsing for enums without a GType.
3366 Make flags/enum references to other girs work
3367 * giscanner/utils.py:
3369 * tests/scanner/Makefile.am:
3370 * tests/scanner/foo-object.h:
3371 * tests/scanner/utility-expected.gir:
3372 * tests/scanner/utility.h:
3373 Add a new test for external enum references
3375 2008-08-18 Johan Dahlin <johan@gnome.org>
3377 * docs/global-module-registry.txt: Update
3379 * tests/array.gir: Update with new type proposal
3381 * girepository/girepository.c (g_type_tag_to_string):
3382 * girepository/girepository.h:
3383 * girepository/girnode.c (g_ir_node_get_full_size_internal),
3385 * girepository/girnode.h:
3386 Make enum serializing functions public. Clean up some whitespace.
3388 2008-08-17 Johan Dahlin <johan@gnome.org>
3390 * docs/global-module-registry.txt:
3391 Add a document for an on disk module registry format
3393 2008-08-17 Johan Dahlin <johan@gnome.org>
3396 * gir/gio-2.0-good.gir:
3399 2008-08-17 Johan Dahlin <johan@gnome.org>
3402 * gir/glib-2.0-good.gir:
3403 * gir/gobject-2.0-good.gir:
3404 * giscanner/cgobject.py:
3405 * giscanner/glibtransformer.py:
3406 Regenerate GObject & GType.
3407 Avoid warnings when generating gobject-2.0.gir.
3408 Introspect a little more, and skip *_get_type functions.
3410 2008-08-17 Colin Walters <walters@verbum.org>
3412 * gir/glib-2.0.gir, gir/gobject-2.0.gir:
3413 Rename to -good, always generate during build.
3414 * gir/Makefile.am: Ensure .gir files dep on
3415 all scanner sources.
3416 * Makefile.am: Switch build order to ensure
3417 the scanner is ready before we do gir/.
3418 * tools/g-ir-scanner: Look for .git too.
3420 2008-08-17 Johan Dahlin <johan@gnome.org>
3422 * girepository/gtypelib.c (validate_enum_blob):
3423 * giscanner/glibtransformer.py:
3424 * giscanner/transformer.py:
3425 Remove resolve_possible_typedefs, it was unused.
3426 Allow multiple enum values of the sample value in an enum,
3427 since it's actually pretty common.
3428 Register enums so they can be resolved too.
3430 2008-08-16 Johan Dahlin <johan@gnome.org>
3432 * giscanner/girparser.py:
3433 Parse enumeration/bitfield.
3435 2008-08-16 Johan Dahlin <johan@gnome.org>
3437 * giscanner/girparser.py:
3440 2008-08-16 Johan Dahlin <johan@gnome.org>
3442 * giscanner/glibtransformer.py:
3443 Resolve type names for alias targets
3444 * giscanner/transformer.py:
3445 Skip FILE* parameters fow now
3447 2008-08-16 Johan Dahlin <johan@gnome.org>
3450 * gir/gobject-2.0.gir:
3453 * tests/scanner/Makefile.am:
3456 2008-08-15 Colin Walters <walters@verbum.org>
3458 * giscanner/glibtransformer.py: Explicitly construct
3459 new list, since we're deleting as we iterate.
3460 Don't delete all structures which end in Class; just
3461 ones which have a paired GObject.
3462 Fix printing of type warning.
3463 * giscanner/transformer.py: Make strip_namespace_object
3464 be the identity function if it doesn't match the
3467 2008-08-15 Colin Walters <walters@verbum.org>
3469 * giscanner/cgobject.py: Define yet more argument
3470 prototypes; fix prototype for g_type_fundamental.
3472 2008-08-14 Johan Dahlin <johan@gnome.org>
3474 * tests/Makefile.am:
3475 * tests/constant.gir:
3476 * tests/gobject.gir:
3478 * tools/generate.c (write_struct_info):
3479 Fix generator for constant/gobject/struct
3481 2008-08-14 Johan Dahlin <johan@gnome.org>
3483 * tests/Makefile.am:
3485 * tools/generate.c (write_enum_info):
3486 Fix generation of enum/bitfields
3488 2008-08-14 Johan Dahlin <johan@gnome.org>
3490 * girepository/girparser.c (start_field), (start_constant),
3491 (start_type), (end_element_handler):
3492 Clear up constant parsing
3497 * tools/generate.c (write_callable_info), (write_function_info),
3498 (write_callback_info), (write_constant_info), (write_signal_info),
3499 (write_vfunc_info), (write_property_info), (write_object_info),
3500 (write_interface_info):
3501 Constants/Signals are handled now.
3503 2008-08-14 Johan Dahlin <johan@gnome.org>
3505 * girepository/girparser.c (start_type):
3506 Don't require c:type.
3507 * tests/Makefile.am:
3510 Update, remove parts we don't support yet
3511 * tests/roundtrips.sh:
3513 * tools/generate.c (write_type_info), (write_field_info),
3514 (write_callable_info), (write_struct_info):
3515 Make it emit proper gir.
3517 2008-08-14 Johan Dahlin <johan@gnome.org>
3519 * giscanner/transformer.py:
3520 New internal function for adding a new node.
3522 2008-08-14 Johan Dahlin <johan@gnome.org>
3525 Define an internal _H_ variable so we skip parsing both
3526 i18n headers, only one is needed.
3528 Add the glib-2.0.gir too.
3529 * giscanner/glibast.py:
3530 Add gconstpointer as an alias for ANY
3531 * giscanner/transformer.py:
3532 Do not lower case enumeration names per se.
3533 Skip functions which has parameters called 'va_list'
3535 2008-08-14 Colin Walters <walters@verbum.org>
3537 * giscanner/transformer.py: Comment data structures.
3538 Also squash pointers in resolve_type_name to correspond
3539 with what we do for params.
3540 * giscanner/glibtransformer.py: Print warnings in more
3541 situations. Rework checks for method/constructor to
3542 look up in our GType database instead of just checking
3543 for *. Avoid generating <record> for GObject which
3544 duplicate the <class>.
3545 * gir/Makefile.am: Generate glib-2.0.gir and gobject-2.0.gir
3548 2008-08-14 Johan Dahlin <johan@gnome.org>
3550 * giscanner/girwriter.py:
3551 * giscanner/glibast.py:
3552 * giscanner/glibtransformer.py:
3553 * giscanner/transformer.py:
3555 * tests/Makefile.am:
3556 Add pyflakes.py and run it in make check.
3557 Update the source code to fix the errors reported by
3560 2008-08-14 Johan Dahlin <johan@gnome.org>
3563 * giscanner/girparser.py:
3564 * giscanner/glibast.py:
3565 * giscanner/glibtransformer.py:
3566 Refactor the parser a bit.
3567 Add parent type to interfaces and update callsites.
3569 2008-08-14 Johan Dahlin <johan@gnome.org>
3571 * giscanner/glibtransformer.py:
3572 * giscanner/utils.py:
3573 Refactor a bit, avoid isinstance and add a method
3574 for each type we parse.
3576 2008-08-14 Johan Dahlin <johan@gnome.org>
3579 * giscanner/girparser.py:
3580 * giscanner/glibtransformer.py:
3581 * tests/Makefile.am:
3582 Run pep8.py in make check, fix old errors.
3584 2008-08-13 Colin Walters <walters@verbum.org>
3586 * giscanner/girparser.py: Parse records.
3588 2008-08-13 Colin Walters <walters@verbum.org>
3590 * gir/Makefile.am: Install again.
3591 * gir/gobject-2.0.gir: Add some more bits.
3593 2008-08-13 Colin Walters <walters@verbum.org>
3595 * gir/gobject-2.0.gir: Use correct namespace, add GType.
3596 * giscanner/girparser.py: Handle aliases.
3597 * giscanner/transformer.py: Record aliases. Make resolver
3598 functions public; we now call into these explicitly from
3599 glibtransformer. Handle resolving aliases.
3600 * giscanner/glibtransformer.py: Separate our internal namespace
3601 from included ones. Call up into transformer's resolver functions.
3603 2008-08-13 Johan Dahlin <johan@gnome.org>
3605 * girepository/girnode.c (g_ir_node_get_full_size_internal):
3606 * girepository/girparser.c (start_class):
3607 * giscanner/glibtransformer.py:
3608 Allow get_type to be None, set a get_type for GInitiallyUnowned too.
3610 2008-08-13 Johan Dahlin <johan@gnome.org>
3612 * giscanner/cgobject.py:
3613 Register GInitiallyUnowned
3614 * giscanner/girwriter.py:
3615 * giscanner/glibtransformer.py:
3616 Special case GObject/GInitially owned as they are a bit special to use.
3618 2008-08-13 Colin Walters <walters@verbum.org>
3620 * tests/scanner/Foo-expected.gir, tests/scanner/utility-expected.gir:
3621 Object is in GObject namespace.
3623 2008-08-13 Colin Walters <walters@verbum.org>
3625 * giscanner/girparser.py: Fix processing of functions
3628 2008-08-13 Colin Walters <walters@verbum.org>
3630 * giscanner/girparser.py: Parse more than just <class.
3631 * giscanner/glibtransformer.py: Put aliases in a separate
3632 data structure since their name is not canonicall.
3633 * giscanner/transformer.py: Handle resolving type names
3636 2008-08-13 Johan Dahlin <johan@gnome.org>
3638 * tools/g-ir-scanner:
3639 Allow multiple libraries
3640 * giscanner/glibtransformer.py:
3641 Rename load_library to add_library, traverse over all libraries
3642 when trying to resolve a function
3644 2008-08-12 Colin Walters <walters@verbum.org>
3646 * giscanner/transformer.py: Record typedefs as <alias> elements.
3647 Also attempt to look up types in external namespaces.
3648 * giscanner/girwriter.py: Write them.
3649 * giscanner/glibtransformer.py: Rework resolver using real instanceof
3650 checks. Resolve interface methods and properties.
3651 * tests/scanner/foo-object.h: Add a method with typedef.
3652 * tests/scanner/Foo-expected.gir: Update.
3653 * girepository/girnode.c: Debug tweaks.
3654 * girepository/girparser.c: Make a first pass through the XML where we
3655 record all the aliases. This lets us resolve them as we go through the
3657 * gir/Makefile.am: Don't install gobject-2.0.gir; we want that to come
3658 from gir-repository.
3660 2008-08-12 Colin Walters <walters@verbum.org>
3662 * giscanner/glibtransformer.py: Resolve typedefs (e.g. AtkAttributeSet -> GSList).
3663 Correctly do subclasseing in 2nd pass resolution. Handle callbacks in structure
3665 * giscanner/transformer.py: Record typedefs and expose public API for resolving
3667 * tests/scanner/Foo-expected.gir: Fix expected callback types.
3669 2008-08-12 Colin Walters <walters@verbum.org>
3671 * giscanner/glibtransformer.py: Also transform object properties.
3673 2008-08-12 Colin Walters <walters@verbum.org>
3675 * giscanner/glibtransformer.py: Also transform callbacks
3676 and structure field types.
3677 * tests/scanner/Fooe-expected.gir: Update to expect correct
3678 names for callbacks and structs.
3680 2008-08-12 Colin Walters <walters@verbum.org>
3682 * girepository/girparser.c: Handle 'any'.
3683 * tests/scanner/Foo-expected.gir, tests/scanner/foo-object.h:
3684 Add test for void *.
3686 2008-08-12 Colin Walters <walters@verbum.org>
3688 * giscanner/glibtransformer.py: We need to do type
3689 resolution in a second pass after we've seen all the
3690 enums, records, etc.
3692 2008-08-12 Colin Walters <walters@verbum.org>
3694 * tests/scanner/Foo-expected.gir, tests/scanner/foo-object.h:
3695 Add enum return value.
3696 * giscanner/glibtransformer.py: Transform function return types
3699 2008-08-12 Colin Walters <walters@verbum.org>
3701 * tests/scanner/Makefile.am: Dep .gir files on scanner
3702 sources too. Also remove @ so we see scanner invocations.
3704 2008-08-12 Colin Walters <walters@verbum.org>
3706 * girepository/girparser.c, girepository/gtypelib.c,
3707 girepository/gtypelib.h, girepository/girnode.c:
3708 Remove usage of (GAPI-oriented) TypeTag in favor of
3709 GITypeTag from girepository.h.
3711 2008-08-10 Colin Walters <walters@verbum.org>
3713 * tests/roundtrips.sh: Use the correct tests.
3715 2008-08-10 Colin Walters <walters@verbum.org>
3717 * giscanner/cgobject.py: Declare/wrap a few more functions.
3718 Fix parameter types for g_object_new and g_type_fundamental.
3720 2008-08-10 Colin Walters <walters@verbum.org>
3722 * giscanner/cgobject.py: Add new decorator @gwrap which forces
3723 us to declare types for both return value and parameters. The
3724 ctypes default of 'int' is bad because it hides 32/64 bit
3725 problems. Convert all existing functions to use it.
3727 2008-08-09 Johan Dahlin <johan@gnome.org>
3729 * giscanner/__init__.py:
3731 * giscanner/cgobject.py:
3732 * giscanner/gidlparser.py:
3733 * giscanner/gidlwriter.py:
3734 * giscanner/girparser.py:
3735 * giscanner/girwriter.py:
3736 * giscanner/glibast.py:
3737 * giscanner/glibtransformer.py:
3738 * giscanner/odict.py:
3739 * giscanner/sourcescanner.py:
3740 * giscanner/transformer.py:
3741 * giscanner/utils.py:
3742 * giscanner/xmlwriter.py:
3743 * tools/g-ir-scanner:
3747 2008-08-09 Johan Dahlin <johan@gnome.org>
3750 * relaxng/c-types.xml:
3751 * relaxng/g-types.xml:
3752 * relaxng/relaxng.rng:
3754 Remove outdated relaxng schemas.
3756 2008-08-09 Johan Dahlin <johan@gnome.org>
3759 Rename metadata to typelib in variable names,
3762 2008-08-09 Johan Dahlin <johan@gnome.org>
3766 Remove old C scanner, which got rewritten in python.
3768 2008-08-09 Johan Dahlin <johan@gnome.org>
3770 * girepository/Makefile.am:
3771 * tools/Makefile.am:
3772 * tools/girmodule.c:
3773 * tools/girmodule.h:
3776 * tools/girparser.c:
3777 * tools/girparser.h:
3778 * tools/girwriter.c:
3779 * tools/girwriter.h:
3780 Move shared *.[ch] files to girepository from tools
3782 2008-08-09 Johan Dahlin <johan@gnome.org>
3784 * tests/Makefile.am:
3787 * tests/constant.test:
3789 * tests/errors.test:
3790 * tests/function.test:
3791 * tests/gobject.test:
3792 * tests/interface.test:
3793 * tests/object.test:
3794 * tests/struct.test:
3799 Rename *.test to *.gir
3801 2008-08-09 Johan Dahlin <johan@gnome.org>
3804 * tests/Makefile.am:
3805 * tests/parser/Foo-expected.gir:
3806 * tests/parser/Makefile.am:
3807 * tests/parser/foo-object.h:
3808 * tests/parser/foo.c:
3809 * tests/parser/utility-expected.gir:
3810 * tests/parser/utility.c:
3811 * tests/parser/utility.h:
3812 * tests/scanner/Makefile.am:
3813 Rename tests/parser to test/scanner
3815 2008-08-08 Colin Walters <walters@verbum.org>
3817 * tests/roundtrips.sh: Use local .gir files again.
3819 2008-08-08 Colin Walters <walters@verbum.org>
3821 * tests/invoke/Makefile.am: .gir file depends on libtool
3824 2008-08-08 Colin Walters <walters@verbum.org>
3826 * tools/girnode.c: Pass through parent node so we can
3827 print the node whose child is NULL, if that occurs.
3829 2008-08-08 Johan Dahlin <johan@gnome.org>
3831 * tests/Makefile.am:
3832 Disable roundtrip tests which are not yet working
3833 * tests/invoke/testfns.gir:
3836 2008-08-08 Johan Dahlin <johan@gnome.org>
3838 * giscanner/girwriter.py:
3840 * giscanner/glibast.py:
3841 * giscanner/glibtransformer.py:
3842 Swap order of members, to keep it consistent with
3845 2008-08-08 Johan Dahlin <johan@gnome.org>
3847 * girepository/gtypelib.c (validate_header):
3848 * girepository/gtypelib.h:
3850 * giscanner/girwriter.py:
3851 * giscanner/sourcescanner.c (gi_source_symbol_ref),
3852 (gi_source_symbol_unref):
3855 * tests/constant.test:
3857 * tests/errors.test:
3858 * tests/function.test:
3859 * tests/gobject.test:
3860 * tests/interface.test:
3861 * tests/invoke/Makefile.am:
3862 * tests/invoke/testfns.xml:
3863 * tests/object.test:
3864 * tests/parser/Makefile.am:
3865 * tests/roundtrips.sh:
3866 * tests/struct.test:
3871 * tools/Makefile.am:
3872 * tools/compiler.c (main):
3873 * tools/generate.c (write_callable_info), (write_function_info),
3875 * tools/gidlmodule.c:
3876 * tools/gidlmodule.h:
3879 * tools/gidlparser.c:
3880 * tools/gidlparser.h:
3881 * tools/gidlwriter.c:
3882 * tools/gidlwriter.h:
3883 * tools/scanner.c (create_node_from_gtype),
3884 (create_node_from_ctype), (g_igenerator_process_properties),
3885 (g_igenerator_process_signals), (g_igenerator_create_object),
3886 (g_igenerator_create_interface), (g_igenerator_create_boxed),
3887 (g_igenerator_create_enum), (g_igenerator_create_flags),
3888 (g_igenerator_process_function_symbol),
3889 (g_igenerator_process_unregistered_struct_typedef),
3890 (g_igenerator_process_struct_typedef),
3891 (g_igenerator_process_union_typedef),
3892 (g_igenerator_process_enum_typedef),
3893 (g_igenerator_process_function_typedef),
3894 (g_igenerator_process_constant), (g_igenerator_process_symbols),
3895 (g_igenerator_add_module), (g_igenerator_add_include_idl):
3896 Merge in the gir-compiler branch.
3897 Thanks to Philip and Colin for their help.
3899 2008-07-26 Colin Walters <walters@verbum.org>
3901 * tools/Makefile.am (bin_PROGRAMS): Install g-idl-compiler
3902 and g-idl-generate to go along with how we're changing this
3903 module to be installed.
3904 * gobject-introspection-1.0.pc.in: Set up Cflags and Libs.
3906 2008-07-24 Colin Walters <walters@verbum.org>
3908 * girepository/girepository.c (g_irepository_register): Add
3909 environment variable G_IREPOSITORY_VERBOSE so we can print
3910 out what we're doing.
3911 * girepository/girepository.c (g_irepository_register_file):
3912 Add GError error message to g_debug call.
3914 2008-07-08 Jürg Billeter <j@bitron.ch>
3916 * giscanner/glibast.py:
3920 2008-06-21 Johan Dahlin <jdahlin@async.com.br>
3922 * giscanner/girparser.py (GIRParser._parse_api): Ignore a few
3925 2008-06-20 Johan Dahlin <jdahlin@async.com.br>
3928 * giscanner/girwriter.py:
3929 * giscanner/transformer.py:
3930 * tests/parser/Foo-expected.gir:
3931 * tests/parser/foo-object.h:
3932 * tests/parser/foo.c (foo_object_allow_none):
3933 Add support for gtk-doc annotations for allow-none.
3936 2008-06-19 Johan Dahlin <jdahlin@async.com.br>
3939 * giscanner/girwriter.py:
3940 * giscanner/glibast.py:
3941 * giscanner/glibtransformer.py:
3942 * giscanner/transformer.py:
3943 * tests/parser/Foo-expected.gir:
3944 Start using abstract type instead of the raw C types.
3945 Register a bunch of glib types we care about.
3947 2008-06-19 Rob Taylor <rob.taylor@codethink.co.uk>
3952 2008-06-08 Philip Van Hoof <pvanhoof@gnome.org>
3954 * girepository/girepository.c:
3955 * girepository/gtypelib.c:
3956 * girepository/ginfo.c:
3957 * girepository/ginvoke.c:
3958 * girepository/girepository.h:
3959 * girepository/gtypelib.h:
3960 * girepository/gmetadata.c:
3961 * girepository/Makefile.am:
3962 * girepository/gmetadata.h:
3964 * tools/gidlmodule.c:
3967 * tools/gidlmodule.h:
3968 * tools/gidlparser.c:
3970 Renamed GMetadata to GTypelib
3972 2008-06-07 Johan Dahlin <jdahlin@async.com.br>
3974 * giscanner/xmlwriter.py:
3975 Improve line wrapping when > 79 charaters
3977 2008-06-05 Jürg Billeter <j@bitron.ch>
3980 * giscanner/girwriter.py:
3981 * giscanner/transformer.py:
3982 Use <type> element for field types
3983 * tests/parser/Foo-expected.gir:
3986 2008-06-04 Johan Dahlin <jdahlin@async.com.br>
3988 * giscanner/glibtransformer.py:
3989 Fix a bug which prevented GdkEvent from being generated
3991 2008-06-03 Johan Dahlin <jdahlin@async.com.br>
3993 * giscanner/Makefile.am:
3995 * giscanner/girwriter.py:
3996 * giscanner/glibast.py:
3997 * giscanner/glibtransformer.py:
3998 * giscanner/transformer.py:
3999 * giscanner/utils.py:
4000 * tests/parser/Foo-expected.gir:
4001 Improve enum member parsing and introspection
4003 2008-05-31 Johan Dahlin <jdahlin@async.com.br>
4005 * giscanner/scannerparser.y:
4006 * giscanner/sourcescanner.h:
4007 * giscanner/sourcescanner.py:
4008 Add a new source type enum for member.
4009 Use __repr__ for improved debugging
4010 * giscanner/girparser.py:
4012 * giscanner/transformer.py:
4013 Improve parsing of struct members.
4014 * tests/parser/foo-object.h:
4017 2008-05-31 Johan Dahlin <jdahlin@async.com.br>
4019 * giscanner/xmlwriter.py:
4020 Improve error reporting when trying to quote None.
4021 * giscanner/girparser.py:
4022 Do not print warnings when including more complete .gir files
4023 * giscanner/girwriter.py:
4024 Do not require a name for parameters, add a todo for singletons
4025 * giscanner/glibtransformer.py:
4026 Refactor the way structs are done, add a couple of hacks to allow
4028 * giscanner/transformer.py:
4029 Add enough hacks so cairo, atk and pango.gir can be parsed properly
4030 * gobject-introspection-1.0.pc.in:
4031 Export girdir, so we can access gobject-2.0.gir from outside
4033 2008-05-31 Johan Dahlin <jdahlin@async.com.br>
4035 * tools/g-ir-scanner:
4036 * tests/parser/Makefile.am:
4037 Update sys.path before running the parser so we don't have
4038 to setup PYTHONPATH ourselves.
4042 * girepository/Makefile.am:
4043 * giscanner/transformer.py:
4044 * gobject-introspection-1.0.pc.in:
4045 * gobject-introspection.pc.in:
4046 * tools/Makefile.am:
4048 Rename pkg-config name to gobject-introspection-1.0,
4049 Do not installed anything which is not using the gir format.
4050 Disable compililation the old C scanner, but still keep the source
4051 until all the remaning functionallity has been ported.
4053 2008-05-31 Johan Dahlin <jdahlin@async.com.br>
4055 * giscanner/giscannermodule.c (symbol_get_ident): Prevent
4056 a crash when symbol->indent is NULL.
4058 * giscanner/sourcescanner.py (ctype_name): Add ctype_name,
4059 a function to convert a CTYPE symbol to a string
4061 2008-05-24 Johan Dahlin <jdahlin@async.com.br>
4064 * giscanner/girwriter.py:
4065 * giscanner/giscannermodule.c
4066 (pygi_source_scanner_append_filename),
4067 (pygi_source_scanner_parse_file):
4068 * giscanner/glibtransformer.py:
4069 * giscanner/sourcescanner.py:
4070 Revert back to using temporary files to send in headers.
4071 Allow Functions to be passed in as callbacks, add a couple
4072 of try/excepts missing features.
4073 We can now scan pango
4075 2008-05-08 Johan Dahlin <johan@gnome.org>
4077 * giscanner/glibtransformer.py:
4078 * giscanner/transformer.py:
4079 Move namespace stripping glibtransformer->transformer
4081 2008-05-08 Johan Dahlin <johan@gnome.org>
4084 * giscanner/girwriter.py:
4085 * giscanner/glibtransformer.py:
4086 * giscanner/transformer.py:
4087 * tools/g-ir-scanner:
4088 Introduce a namespace ast node
4090 2008-05-05 Johan Dahlin <johan@gnome.org>
4092 * giscanner/__init__.py:
4093 * giscanner/sourcescanner.py:
4094 * giscanner/transformer.py:
4095 Move sourcescanner symbols to the sourcescanner module, instead
4096 of in the global __init__ namespace.
4098 2008-05-03 Johan Dahlin <johan@gnome.org>
4100 * giscanner/glibtransformer.py:
4101 * tools/g-ir-scanner:
4102 Handle missing parameters better, allow - and + in .la dlname
4105 2008-05-03 Johan Dahlin <johan@gnome.org>
4107 * giscanner/__init__.py:
4109 * giscanner/girwriter.py:
4110 * giscanner/glibtransformer.py:
4111 * giscanner/transformer.py:
4112 Parse struct fields properly, improve debugging.
4114 2008-04-29 Johan Dahlin <johan@gnome.org>
4117 * giscanner/girwriter.py:
4118 * giscanner/transformer.py:
4119 * tests/parser/Foo-expected.gir:
4121 Use transfer-ownership everywhere, to mark ownership/calle/caller etc.
4123 2008-04-29 Johan Dahlin <jdahlin@async.com.br>
4126 * docs/g-ir-scanner.1:
4127 * metadata-annotations-proposal.txt:
4128 * metadata-format.txt:
4129 Add a basic, unfinshed man page for g-ir-scanner, move documents into .txt
4131 2008-04-29 Johan Dahlin <jdahlin@async.com.br>
4133 * giscanner/girwriter.py:
4134 * giscanner/glibtransformer.py:
4135 * giscanner/transformer.py:
4136 * giscanner/xmlwriter.py:
4137 * tests/parser/Foo-expected.gir:
4138 * tests/parser/foo-object.h:
4139 Write record/structs to gir file too. Add a couple of tests,
4140 fix an off by one error in xmlwriter.py.
4142 2008-04-28 Johan Dahlin <johan@gnome.org>
4144 * giscanner/xmlwriter.py: Calculate the line length properly,
4145 include the provided extra indentation in the calculation, really.
4147 2008-04-28 Johan Dahlin <jdahlin@async.com.br>
4150 * giscanner/glibast.py:
4151 * giscanner/glibtransformer.py:
4152 * giscanner/transformer.py:
4153 * tools/g-ir-scanner:
4154 Add a --strip-prefix and sort out confusion between names and symbols
4155 for functions and struct + derivaties.
4156 Refactor bootstrap of g-ir-scanner, so we can set options on
4157 Transformer() before parsing everything.
4159 2008-04-28 Johan Dahlin <johan@gnome.org>
4161 * giscanner/transformer.py (Transformer._traverse_one): Avoid recursion
4162 when scanning girepository.h
4164 * giscanner/sourcescanner.py (SourceScanner._preprocess): Define
4165 a __GI_SCANNER__ when we run.
4167 2008-04-28 Johan Dahlin <jdahlin@async.com.br>
4170 * giscanner/girwriter.py:
4171 * giscanner/glibast.py:
4172 * giscanner/glibtransformer.py:
4173 * tests/parser/Foo-expected.gir:
4174 * tests/parser/utility-expected.gir:
4175 Rename most c:identifier to c:type. Add new ones to
4176 class/interface/enum/boxed.
4178 2008-04-28 Johan Dahlin <jdahlin@async.com.br>
4181 * giscanner/girwriter.py:
4182 * giscanner/glibtransformer.py:
4183 * tests/parser/Foo-expected.gidl:
4184 * tests/parser/Makefile.am:
4185 Move c:identifier from return-value to subchild type,
4186 as per Jürgs suggestion
4188 2008-04-28 Johan Dahlin <johan@gnome.org>
4190 * giscanner/girwriter.py:
4191 * tests/parser/Foo-expected.gir:
4192 Write property.type as a child node.
4194 2008-04-27 Johan Dahlin <johan@gnome.org>
4199 * gidl/gobject-2.0.gidl:
4201 * gir/gobject-2.0.gir:
4202 * tests/parser/Makefile.am:
4203 Replace the GObject gidl with a GObject gir.
4205 2008-04-27 Johan Dahlin <johan@gnome.org>
4207 * tools/Makefile.am (bin_SCRIPTS): g-ir-scanner is a script,
4210 * giscanner/xmlwriter.py:
4211 * tests/parser/Foo-expected.gir:
4212 Include indentation in line length calculation
4214 2008-04-27 Johan Dahlin <johan@gnome.org>
4216 * giscanner/girparser.py:
4217 Prettify NS parsing using elementtree.
4219 2008-04-27 Johan Dahlin <johan@gnome.org>
4222 * giscanner/Makefile.am:
4223 * giscanner/girparser.py:
4224 * giscanner/glibtransformer.py:
4225 * tests/parser/Foo-expected.gidl:
4226 * tests/parser/Foo-expected.gir:
4227 * tests/parser/Makefile.am:
4228 * tests/parser/utility-expected.gidl:
4229 * tests/parser/utility-expected.gir:
4230 * tools/g-ir-scanner:
4231 Switch over to GIR as the default format. Add a simple GIDL
4233 Update tests and fix simplify makefiles by depending
4234 on GNU make extensions.
4236 2008-04-27 Johan Dahlin <johan@gnome.org>
4238 * giscanner/xmlwriter.py:
4239 Wrap attributes for lines which are wider than 79 characters
4241 * giscanner/scannerlexer.l:
4242 Allow parenthesis in annotations
4245 * giscanner/gidlwriter.py:
4246 * giscanner/girwriter.py:
4247 * giscanner/glibtransformer.py:
4248 * giscanner/transformer.py:
4249 Add initial sequence support, including annotation.
4250 Refactor type handling a bit.
4252 2008-04-27 Johan Dahlin <johan@gnome.org>
4254 * tests/parser/Foo-expected.gidl:
4255 * tests/parser/foo-object.h:
4256 * tests/parser/foo.c (foo_object_class_init),
4257 (foo_object_get_strings), (foo_object_get_objects):
4258 Add two new functions to check sequence return values.
4259 Also fixes a compilation warning.
4261 2008-04-27 Johan Dahlin <johan@gnome.org>
4263 * giscanner/giscannermodule.c (]): Cast the getter, avoids
4264 a compilation warning.
4266 * tools/Makefile.am (g_ir_scanner_SOURCES):
4267 g-ir-scanner has no sources.
4269 2008-04-25 Johan Dahlin <johan@gnome.org>
4271 * giscanner/Makefile.am:
4273 * giscanner/gidlparser.py:
4274 * giscanner/gidlwriter.py:
4275 * giscanner/girwriter.py:
4276 * giscanner/glibast.py:
4277 * giscanner/glibtransformer.py:
4278 * giscanner/transformer.py:
4279 Split out nodes to ast.py and glibast.py
4281 2008-04-25 Johan Dahlin <jdahlin@async.com.br>
4283 * giscanner/Makefile.am:
4284 * giscanner/gidlparser.py:
4285 * giscanner/gidlwriter.py:
4286 * giscanner/girwriter.py:
4287 * giscanner/glibtransformer.py:
4288 * giscanner/gobjecttreebuilder.py:
4289 * giscanner/transformer.py:
4290 * giscanner/treebuilder.py:
4291 * tools/g-ir-scanner:
4292 Rename treebuilder to transformer and
4293 gobjectreebuilder to glibtransformer.
4295 2008-04-25 Johan Dahlin <jdahlin@async.com.br>
4297 * giscanner/Makefile.am:
4298 * giscanner/__init__.py:
4299 * giscanner/cgobject.py:
4300 * giscanner/gidlparser.py:
4301 * giscanner/gidlwriter.py:
4302 * giscanner/girwriter.py:
4303 * giscanner/gobjecttreebuilder.py:
4304 * giscanner/odict.py:
4305 * giscanner/sourcescanner.py:
4306 * giscanner/treebuilder.py:
4307 * giscanner/xmlwriter.py:
4308 * tools/Makefile.am:
4309 * tools/g-ir-scanner:
4310 Add LGPLv2 license header and install all python files
4312 2008-04-25 Johan Dahlin <jdahlin@async.com.br>
4315 * giscanner/gidlwriter.py:
4316 * giscanner/giscannermodule.c (pygi_source_directive_new),
4317 (directive_get_options), (pygi_source_symbol_new),
4318 (symbol_get_base_type), (pygi_source_type_new),
4319 (type_get_base_type), (type_get_child_list),
4320 (pygi_source_scanner_get_symbols),
4321 (pygi_source_scanner_get_directives):
4322 * giscanner/gobjecttreebuilder.py:
4323 * giscanner/sourcescanner.py:
4324 * giscanner/treebuilder.py:
4325 * tests/parser/foo-object.h:
4326 Add support for virtual methods.
4327 Pair struct FooClass with struct Foo.
4328 Clean up the SourceScanner bindings a bit.
4329 Add a testcase for virtual methods.
4331 2008-04-25 Johan Dahlin <jdahlin@async.com.br>
4333 * giscanner/cgobject.py:
4334 * giscanner/gidlwriter.py:
4335 * giscanner/gobjecttreebuilder.py:
4336 Add support for signals
4338 * tests/parser/foo.c (foo_object_class_init):
4339 * Foo-expected.gidl:
4340 Add a signal and update the expected output.
4342 2008-04-24 Johan Dahlin <jdahlin@async.com.br>
4344 * giscanner/gidlwriter.py:
4345 * giscanner/girwriter.py:
4346 * giscanner/giscannermodule.c (directive_get_name),
4347 (directive_get_value), (directive_get_options),
4348 (symbol_get_directives), (symbol_set_directives),
4349 (pygi_source_scanner_parse_file),
4350 (pygi_source_scanner_lex_filename),
4351 (pygi_source_scanner_get_directives), (init_giscanner):
4352 * giscanner/sourcescanner.c (gi_source_scanner_get_directives):
4353 * giscanner/sourcescanner.h:
4354 * giscanner/sourcescanner.py:
4355 * giscanner/treebuilder.py:
4356 * tools/g-ir-scanner:
4357 Add support for source/header annotations.
4359 2008-04-22 Johan Dahlin <jdahlin@async.com.br>
4361 * giscanner/gidlwriter.py:
4362 * giscanner/girwriter.py:
4363 * giscanner/gobjecttreebuilder.py:
4364 * giscanner/treebuilder.py:
4365 Add support for Callbacks
4367 2008-04-22 Havoc Pennington <hp@pobox.com>
4369 * girepository/ginvoke.c (g_function_info_invoke): If a symbol is
4370 not in metadata->module, look for it in the global module, in case
4371 some other object or the app itself provides the symbol.
4373 2008-04-22 Havoc Pennington <hp@pobox.com>
4375 * girepository/gmetadata.c (_g_metadata_init): hack to avoid
4376 dlopening a library that is already in the main app, by checking
4377 whether one of the lib's symbols is already loaded.
4379 2008-04-22 Johan Dahlin <jdahlin@async.com.br>
4381 * tests/parser/Foo-expected.gidl:
4382 * tests/parser/foo-object.h:
4385 2008-04-22 Havoc Pennington <hp@pobox.com>
4387 * girepository/ginfo.c (g_interface_info_find_method):
4388 Use interface_blob_size not object_blob_size to compute offset.
4390 2008-04-22 Havoc Pennington <hp@pobox.com>
4392 * girepository/gmetadata.c (_g_metadata_init): remove
4393 G_MODULE_BIND_LOCAL flag when loading libraries, since some libs
4394 (Glade and Clutter for example) rely on being loaded globally.
4396 2008-04-22 Havoc Pennington <hp@pobox.com>
4398 * girepository/ginfo.c (g_registered_type_info_get_g_type): new
4399 function to get the GType given a RegisteredTypeInfo
4401 2008-04-22 Johan Dahlin <johan@gnome.org>
4403 * COPYING: Add a LGPL license, to prevent automake to
4404 put in a copy of GPL here. Pointed out by Havoc.
4406 * girepository/ginfo.c (g_info_from_entry), (g_type_info_new),
4407 (g_type_info_is_pointer), (g_type_info_get_tag),
4408 (g_type_info_get_param_type), (g_type_info_get_interface),
4409 (g_type_info_get_array_length), (g_type_info_is_zero_terminated),
4410 (g_type_info_get_n_error_domains), (g_type_info_get_error_domain),
4411 (g_error_domain_info_get_codes), (g_enum_info_get_value),
4412 (g_object_info_get_interface), (g_object_info_get_field),
4413 (g_interface_info_get_prerequisite),
4414 (g_signal_info_get_class_closure), (g_constant_info_get_value):
4415 * girepository/ginvoke.c (get_ffi_type):
4416 * girepository/girepository.h:
4417 * girepository/gmetadata.c (g_metadata_get_dir_entry),
4418 (g_metadata_check_sanity), (validate_header),
4419 (validate_array_type_blob), (validate_iface_type_blob),
4420 (validate_param_type_blob), (validate_error_type_blob),
4421 (validate_type_blob), (validate_constant_blob),
4422 (validate_struct_blob), (validate_enum_blob):
4423 * girepository/gmetadata.h:
4424 * tests/Makefile.am:
4425 * tests/invoke/Makefile.am:
4426 * tests/invoke/invoke.c (main):
4427 * tests/roundtrips.sh:
4428 * tools/Makefile.am:
4429 * tools/compiler.c (format_output), (write_out_metadata), (main):
4430 * tools/generate.c (write_type_name), (write_type_info),
4431 (write_constant_value), (write_enum_info), (load_metadata), (main):
4432 * tools/gidlcompilercontext.c:
4433 * tools/gidlcompilercontext.h:
4434 * tools/gidlcompilerentrynode.c:
4435 * tools/gidlcompilerentrynode.h:
4436 * tools/gidlcompilertypenode.c:
4437 * tools/gidlcompilertypenode.h:
4438 * tools/gidlmodule.c (g_idl_module_build_metadata):
4439 * tools/gidlmodule.h:
4440 * tools/gidlnode.c (init_stats), (dump_stats),
4441 (g_idl_node_get_size), (g_idl_node_get_full_size),
4442 (g_idl_node_cmp), (g_idl_node_can_have_member),
4443 (g_idl_node_add_member), (g_idl_node_param_direction_string),
4444 (parse_int_value), (parse_uint_value), (parse_float_value),
4445 (parse_boolean_value), (find_entry_node), (find_entry),
4446 (serialize_type), (g_idl_node_build_metadata), (write_string):
4448 * tools/gidlparser.c (parse_type_internal):
4449 * tools/quote-file.sh:
4450 Revert revisions 157,149-148,136-129 and 120.
4451 Move back to using g-idl-generate to generate the metadata and
4452 avoids dependency on a c compiler.
4454 2008-04-22 Johan Dahlin <jdahlin@async.com.br>
4456 * giscanner/girwriter.py:
4457 * tools/g-ir-scanner:
4458 Add an initial GIR writer and a --format option to g-ir-scanner
4460 2008-04-21 Johan Dahlin <johan@gnome.org>
4462 * giscanner/cgobject.py: Use ctypes.util.find_library to locate
4463 gobject-2.0 and raise ImportError if not found.
4465 * giscanner/gidlparser.py:
4466 * giscanner/gidlwriter.py:
4467 * giscanner/gobjecttreebuilder.py:
4468 * tools/g-ir-scanner:
4469 Add a --include argument to include types from other idls.
4470 Add a minimalistic GIDL parser (just objects for now)
4471 Implement resolving of external type references and use it to
4472 resolve parent types, argument types and return types.
4474 2008-04-21 Johan Dahlin <johan@gnome.org>
4476 * giscanner/gidlwriter.py:
4477 * giscanner/gobjecttreebuilder.py:
4478 * giscanner/treebuilder.py:
4479 Add support for properties.
4480 Refactor Class/Interface support a bit, to share more code and
4481 always initialize their method attribute to an empty list.
4483 2008-04-21 Johan Dahlin <johan@gnome.org>
4485 * giscanner/cgobject.py:
4486 Add a workaround for a glib bug interface introspection bug
4487 (object_interface_list_properties, object_class_list_properties):
4488 Cast the return value to GParamSpec.
4490 * tests/parser/Foo-expected.gidl: Update
4491 * tests/parser/foo.c: Add a string property
4493 * giscanner/gobjecttreebuilder.py:
4494 After stripping namespaces, remove the original
4495 item to avoid duplication (GtkButton struct and Button object)
4497 2008-04-21 Johan Dahlin <johan@gnome.org>
4499 * giscanner/gobjecttreebuilder.py:
4500 * giscanner/treebuilder.py:
4501 Strip namespaces before objects, so we'll export
4502 GtkButton as Button in the gtk namespace
4504 2008-04-21 Johan Dahlin <johan@gnome.org>
4506 * giscanner/gidlwriter.py:
4507 * giscanner/gobjecttreebuilder.py:
4508 * giscanner/treebuilder.py:
4509 Add constructors for object/boxed types.
4511 2008-04-21 Johan Dahlin <johan@gnome.org>
4513 * giscanner/gidlwriter.py:
4514 * giscanner/gobjecttreebuilder.py:
4515 Add support for boxed types
4517 2008-04-21 Johan Dahlin <johan@gnome.org>
4519 * giscanner/giscannermodule.c: Mark structures as const,
4520 wrap SourceType.const_string.
4522 * tests/parser/foo-object.h: Add a couple of constants.
4524 * giscanner/gidlwriter.py:
4525 * giscanner/gobjecttreebuilder.py:
4526 * giscanner/treebuilder.py:
4527 Add basic support for interfaces
4529 * tools/g-ir-scanner:
4530 Add -o/--output for writing to a file
4532 2008-04-21 Havoc Pennington <hp@redhat.com>
4534 * TODO: add some C API wishlist items I could think of quickly
4536 2008-04-21 Johan Dahlin <jdahlin@async.com.br>
4538 * giscanner/gidlwriter.py:
4539 * giscanner/xmlwriter.py:
4540 Add a simple api for writing tags which can be used
4541 with the new 'with statement' in python 2.5
4543 2008-04-21 Johan Dahlin <johan@gnome.org>
4545 * giscanner/gobjecttreebuilder.py:
4546 Strip namespace and object prefix from method names.
4548 2008-04-21 Johan Dahlin <johan@gnome.org>
4550 * tools/g-ir-scanner (main): Add --pkg option to pass in
4551 pkg-config modules to get cflags from.
4553 * giscanner/gidlwriter.py (GIDLWriter._write_method):
4554 Avoid duplication, reuse function writer for methods.
4556 2008-04-21 Johan Dahlin <jdahlin@async.com.br>
4558 * giscanner/gidlwriter.py:
4559 * giscanner/gobjecttreebuilder.py:
4560 * giscanner/treebuilder.py:
4561 * tools/g-ir-scanner:
4562 Resolve libtool .la files.
4563 Strip name spaces for methods.
4564 Add function symbols
4566 2008-04-20 Johan Dahlin <jdahlin@async.com.br>
4568 * giscanner/cgobject.py:
4569 * giscanner/gidlwriter.py:
4570 * giscanner/gobjecttreebuilder.py:
4571 * giscanner/treebuilder.py:
4572 Add support for classes and methods
4574 2008-04-20 Johan Dahlin <johan@gnome.org>
4576 * giscanner/gidlwriter.py:
4577 * giscanner/gobjecttreebuilder.py:
4578 * giscanner/odict.py:
4579 Avoid conflicts, keep the output ordered similar to
4580 the order of the input.
4581 Add a simple ordered dictionary implemenation
4583 2008-04-19 Johan Dahlin <johan@gnome.org>
4585 * giscanner/cgobject.py:
4586 * giscanner/gidlwriter.py:
4587 * giscanner/gobjecttreebuilder.py:
4588 * tools/g-ir-scanner:
4589 Start introspecting get-type functions.
4590 Implement support for GLib/GFlags GTypes.
4591 Add a ctype based GObject binding.
4593 2008-04-18 Johan Dahlin <jdahlin@async.com.br>
4595 * giscanner/gidlwriter.py:
4596 * giscanner/xmlwriter.py:
4597 * tools/g-ir-scanner:
4598 Add a simplistic gidl writer, which can't do too much.
4600 2008-04-18 Johan Dahlin <johan@gnome.org>
4602 * giscanner/sourcescanner.py:
4603 * giscanner/treebuilder.py:
4604 * tools/g-ir-scanner:
4605 split tree building and source scanning interface to separate files.
4607 2008-04-18 Johan Dahlin <johan@gnome.org>
4609 * tools/g-ir-scanner (Parameter.__init__): Start constructing
4611 - Add support for struct/parameter/return, start parsing of ctypes
4613 * giscanner/giscannermodule.c: wrap GISourceType.child_list and
4616 2008-03-31 Johan Dahlin <johan@gnome.org>
4618 * tools/g-ir-scanner:
4619 Start to build abstract syntax node of scanned sources.
4620 Add support for cpp options.
4622 2008-03-27 Johan Dahlin <johan@gnome.org>
4624 * giscanner/giscannermodule.c:
4625 * giscanner/scannerlexer.l:
4626 * giscanner/sourcescanner.c:
4627 * tools/g-ir-scanner:
4629 Add simple pre-processor using subprocess and a PIPE.
4630 Change the parse_file apis to accept a file descriptor.
4632 2008-03-25 Johan Dahlin <johan@gnome.org>
4634 * giscanner/__init__.py:
4635 * tools/g-ir-scanner:
4636 Fix a typo and add an example python test program.
4638 2008-03-25 Johan Dahlin <johan@gnome.org>
4640 * giscanner/__init__.py:
4641 * giscanner/giscannermodule.c:
4642 * giscanner/sourcescanner.c:
4643 * giscanner/sourcescanner.h:
4644 Add constants and wrap a few more SymbolType fields
4646 2008-03-25 Johan Dahlin <johan@gnome.org>
4650 * giscanner/__init__.py:
4651 * giscanner/giscannermodule.c:
4652 * giscanner/Makefile.am:
4654 Add initial python bindings for the scanner and
4655 depend on python 2.5.
4657 2008-03-25 Johan Dahlin <johan@gnome.org>
4661 * giscanner/Makefile.am:
4662 * giscanner/sourcescanner.c:
4663 * giscanner/sourcescanner.h:
4664 * tools/Makefile.am:
4665 * tools/grealpath.h:
4666 * tools/sourcescanner.c:
4667 * tools/sourcescanner.h:
4669 Move the scanner to a separate library.
4671 2008-03-23 Johan Dahlin <johan@gnome.org>
4673 * tools/Makefile.am:
4676 * tools/scannerlexer.l:
4677 * tools/scannerparser.y:
4678 * tools/sourcescanner.c:
4679 * tools/sourcescanner.h:
4680 Split out the source scanner from the generator.
4681 Rename the symbols used in the scanner to use the gi_ prefix.
4682 This should make it possible to use the raw C parser from
4685 2008-03-23 Johan Dahlin <johan@gnome.org>
4687 * tests/parser/Makefile.am (utility.gidl):
4688 * tests/parser/utility-expected.gidl:
4689 Pass in the gobject.gidl since we're defining a GObject.
4691 2008-03-12 Johan Dahlin <johan@gnome.org>
4693 * relaxng/relaxng.rng:
4694 Add a releaxng in relaxng we can use to validate the relaxngs
4697 2008-03-12 Jürg Billeter <j@bitron.ch>
4699 * tools/scanner.c: (g_igenerator_new):
4700 * tools/scannerparser.y:
4701 Fix compiler warnings.
4703 2008-03-12 Jürg Billeter <j@bitron.ch>
4707 * tools/scannerparser.y:
4708 Start fixing memory management in g-idl-scanner.
4710 2008-03-12 Rob Taylor <rob.taylor@codethink.co.uk>
4712 * tools/gidlcompilercontext.c: (write_compiled):
4713 Fix critical warning when no shlib passed to g-idl-compiler.
4715 2008-03-12 Johan Dahlin <johan@gnome.org>
4717 * tests/parser/utility-expected.gidl:
4718 * tests/parser/utility.h:
4719 Add a get_type-function, so the scanner actually
4720 parses it as an object.
4722 2008-03-12 Johan Dahlin <johan@gnome.org>
4724 * tools/gidlwriter.c (function_generate): Add missing trailing quote.
4727 * tests/parser/Foo-expected.gidl:
4728 * tests/parser/Makefile.am:
4729 * tests/parser/foo-object.h:
4730 * tests/parser/foo.c:
4731 * tests/parser/utility-expected.gidl:
4732 * tests/parser/utility.c:
4733 * tests/parser/utility.h:
4735 Add a new gidl test. 'utility.gidl', which is used to be able
4736 to test external type references. Add a reference to UtilityObject*
4739 2008-03-11 Johan Dahlin <johan@gnome.org>
4743 Remove most global variables
4745 2008-03-11 Philip Van Hoof <me@pvanhoof.be>
4747 * tools/scannerlexer.l:
4749 * tests/parser/Foo-expected.gidl:
4750 * tests/parser/foo.c:
4751 * tests/parser/Makefile.am:
4752 * tests/parser/foo-object.h:
4754 Added a few extra tests. Which resulted in finding a few
4755 bugs. Which resulted in me fixing those bugs
4757 2008-03-11 Rob Taylor <rob.taylor@codethink.co.uk>
4759 * tools/gidlcompilercontext.c: (g_idl_compiler_write_dir_entry),
4760 (g_idl_compiler_write_xref_entry), (g_idl_compiler_add_xref):
4761 Add some comments for strings into generated output for
4764 2008-03-11 Rob Taylor <rob.taylor@codethink.co.uk>
4766 * tools/gidlcompilercontext.c: (write_compiled):
4767 Write out the shlibs variable before writing out the strings
4768 length. Fixes compiler warning when using '-l' flag with
4771 2008-03-11 Johan Dahlin <johan@gnome.org>
4773 * tests/parser/Foo-expected.gidl:
4774 * tests/parser/foo-object.h:
4777 * tools/scannerlexer.l:
4778 Add support for parsing return arguments. Add support for
4779 caller-owns return types.
4780 Patch by Philip Van Hoof.
4782 * tools/scannerparser.y:
4783 Remove parsing of the @deprecated syntax used in headers.
4784 We will support gtk-doc deprecation in the future instead.
4786 2008-03-11 Johan Dahlin <johan@gnome.org>
4788 * tools/compiler.c (main): Coding style fixes
4790 2008-03-10 Johan Dahlin <johan@gnome.org>
4793 Add GCOV_LIBS to GILIBS
4795 2008-03-10 Johan Dahlin <johan@gnome.org>
4797 * tests/parser/Foo-expected.gidl:
4798 * tests/parser/foo.c:
4799 Rename null-ok to direction=out
4801 2008-03-10 Philip Van Hoof <me@pvanhoof.be>
4803 reviewed and extensively tested by Johan
4805 * tests/parser/Foo-expected.gidl:
4806 * tests/parser/foo-object.h:
4807 * tests/parser/foo.c:
4810 * tools/gidlwriter.c:
4813 * tools/scannerlexer.l:
4814 * tools/scannerparser.y:
4816 Add support for scanning for gtk-doc comments inside
4817 C source files. Add tests
4819 2008-03-10 Johan Dahlin <johan@gnome.org>
4821 * tests/parser/Makefile.am:
4822 * tests/parser/foo.c:
4825 * tools/scannerparser.y:
4826 Add an api to lex filenames.
4827 Lex all source .c files passed in on the command line.
4828 Scan sources in a test and a couple of private structures
4829 which should not be included in the generated gidl
4831 2008-03-10 Johan Dahlin <johan@gnome.org>
4833 * tests/invoke/Makefile.am: Make the generated metadata
4834 depend on the g-idl-compiler
4836 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4838 * tools/gidlmodule.c
4839 * tools/gidlmodule.h
4842 Remove the old g-idl-compiler code.
4845 2008-02-22 Mark Doffman <mark.doffman@codethink.co.uk>
4847 * tools/quote-file.sh
4850 Move to using the 'C' struct compiler code.
4852 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4854 * girepository/ginfo.c
4856 Change the way that external references with no namespace
4857 are dealt with. External references with no namespace
4858 are placed into the XML as-if they are a local reference.
4859 This is temporary, but helps with roundtrip tests.
4861 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4863 * girepository/ginfo.c
4864 Add the ability to get the value of a constant of
4865 type TYPE_TAG_SYMBOL. In the case of a symbol the value
4866 is provided as a string.
4868 This would deal properly with:
4869 typedef char* random;
4870 const random = "A string";
4872 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4874 * girepository/ginfo.c
4875 * girepository/girepository.h
4877 Add a function to check if an enum is registered or not.
4878 Previously anything testing this relied on the g-type
4879 string offset having a value of 0.
4881 * girepository/gmetadata.c
4882 * girepository/gmetadata.h
4884 Remove unneccesary or erroneous checks. There were two
4885 metadata validation checks which made sure that the blob
4886 sizes were the same as some magic numbers compiled into the code.
4887 This is wrong as it breaks any forwards compatibility that may
4890 Checks were also present that made sure that unregistered type
4891 blobs had a value of 0 in the g-type offset field. This is
4892 unneccessary. If a type blob is unregistered then any value
4893 in its g-type field is simply invalid.
4895 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4897 * girepository/ginfo.c
4898 * girepository/gmetadata.c
4899 * girepository/gmetadata.h
4901 Change the metadata format to have a standard header
4902 for all the type blobs. Merge the SimpleTypeBlob
4903 and InterfaceTypeBlob into a union. A union of these
4904 two blobs existed previously but was not explicit
4905 in the metadata format.
4907 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4909 * tools/gidlcompilercontext.c
4910 * tools/gidlcompilercontext.h
4911 * tools/gidlcompilerentrynode.c
4912 * tools/gidlcompilerentrynode.h
4913 * tools/gidlcompilertypenode.c
4914 * tools/gidlcompilertypenode.h
4916 Add code to compile a tree of GIdlNodes to
4917 a 'C' struct representing the metadata.
4918 This is to aid cross-compiling. Previously
4919 the g-idl-compiler created a binary blob with
4920 data written in the byte order and alignment
4921 of the tool rather than the intended target.
4923 Cleaned up and improved by Johan and Robert :-)
4925 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4927 * girepository/ginvoke.c
4928 * girepository/girepository.h
4929 * girepository/gmetadata.c
4930 * girepository/gmetadata.h
4932 * tools/gidlparser.c
4933 Modify TYPE_TAG_INTERFACE to TYPE_TAG_SYMBOL
4934 to avoid confusion with the interface blob.
4937 * tools/gidlparser.c
4938 Remove magic numbers and replace with type-tag
4939 enumeration symbols.
4941 * girepository/gmetadata.c
4942 Add validate declaration.
4944 2008-03-10 Jürg Billeter <j@bitron.ch>
4946 * tools/gidlparser.c: (parse_type_internal):
4947 * tools/scannerlexer.l:
4948 * tools/scannerparser.y:
4949 Support C99 _Bool type in scanner.
4951 2008-03-10 Jürg Billeter <j@bitron.ch>
4953 * tests/parser/Foo-expected.gidl:
4954 * tests/parser/foo-object.h:
4955 * tests/parser/foo.c: (foo_enum_method):
4956 * tools/scanner.c: (g_igenerator_process_function_symbol):
4957 Don't skip functions that are defined in the namespace of a type
4958 that doesn't support methods, as for example enums.
4960 2008-03-10 Johan Dahlin <johan@gnome.org>
4962 * gidl.dtd: Remove, we're using relaxng for now
4964 * tests/parser/Foo-expected.gidl:
4965 * tests/parser/foo-object.h:
4966 * tests/parser/foo.c:
4967 Rename the enum/flags get_type functions to include the whole type.
4969 2008-03-08 Marc-Andre Lureau <marcandre.lureau@gmail.com>
4971 * tools/gidlwriter.c (enum_generate): added "type-name",
4972 "get-type" and "deprecated" missing arguments.
4973 * tests/parser/Foo-expected.gidl:
4974 * tests/parser/foo-object.h: test enum type, and no type.
4976 2008-03-06 Johan Dahlin <jdahlin@async.com.br>
4979 Consistent checks, add missing 'test'
4981 2008-03-05 Havoc Pennington <hp@redhat.com>
4983 * configure.ac: Take advantage of a libffi.pc if one exists, as it
4984 does on Fedora 8. Make libffi a hard requirement, since it was in
4985 practice anyway (was not really conditional in the code or
4986 makefile, only in configure).
4988 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4990 reviewed by: Rob Taylor <rob.taylor@codethink.co.uk>
4991 reviewed by: Johan Dahlin <johan@gnome.org>
4993 * tests/Makefile.am:
4994 * tests/roundtrips.sh:
4995 Modify the roundtrips test so that they do not use the
4996 --raw option of the gidl compiler but instead compile a
4997 shared library to use with g_module.
4999 * tests/invoke/Makefile.am:
5000 * tests/invoke/invoke.c:
5001 Modify the invoke tests to build a shared library rather
5002 than use the --raw option.
5004 * tests/invoke/invoke-namespace-find.sh: Removed:
5005 Noone knows why this was here, so removed.
5007 2008-02-19 Rob Taylor <rob.taylor@codethink.co.uk>
5009 * tools/scanner.c: (g_igenerator_process_function_symbol):
5010 Move g_idl_node_can_have_member test later, as it broke spotting
5011 get_type's for nodes that can't have members.
5013 2008-02-18 Rob Taylor <rob.taylor@codethink.co.uk>
5016 * tools/gidlnode.c: (g_idl_node_can_have_member):
5017 Add g_idl_node_can_have_member.
5019 * tools/scanner.c: (g_igenerator_process_function_symbol):
5020 Use g_idl_node_can_have_member to test if we should add a function
5021 as a member of the type node.
5023 2008-02-18 Rob Taylor <rob.taylor@codethink.co.uk>
5025 * gidl/GLib.gidl: Renamed to gidl/gobject-2.0.gidl:
5027 * tests/parser/Makefile.am:
5028 Rename GLib.gidl to gobject-2.0.gidl and install in /usr/share/gidl.
5030 2008-02-18 Rob Taylor <rob.taylor@codethink.co.uk>
5032 * tools/scanner.c: (main):
5033 Ignore -pthread when passed to g-idl-scanner.
5035 2008-02-18 Rob Taylor <rob.taylor@codethink.co.uk>
5037 * tools/grealpath.h: Added:
5038 * tools/scanner.c: (main):
5039 * tools/scannerlexer.l:
5040 * tools/Makefile.am:
5041 Always use absolute paths with symbolic links resolved when
5042 comparing filenames.
5044 2008-02-18 Rob Taylor <rob.taylor@codethink.co.uk>
5046 * gobject-introspection.pc.in:
5047 Provide variables for g-idl-parser, scanner and compiler in the
5050 2008-02-13 Rob Taylor <rob.taylor@codethink.co.uk>
5053 * girepository/Makefile.am:
5054 * tools/Makefile.am:
5055 Rename GCOV_SOURCES to GCOVSOURCES to top automake complaining.
5057 2008-02-10 Johan Dahlin <johan@gnome.org>
5059 * tests/parser/Foo-expected.gidl:
5060 * tests/parser/foo-object.h:
5061 * tests/parser/foo.c: (foo_boxed_copy), (foo_boxed_free),
5062 (foo_boxed_get_type), (foo_boxed_new), (foo_boxed_method):
5065 2008-02-10 Johan Dahlin <johan@gnome.org>
5067 * tests/parser/Foo-expected.gidl:
5068 * tests/parser/foo-object.h:
5069 * tests/parser/foo.c: (foo_enum_get_type), (foo_flags_get_type):
5070 Add enum and flags test.
5072 2008-02-10 Johan Dahlin <johan@gnome.org>
5076 * girepository/Makefile.am:
5077 Make 'make distcheck' work again.
5079 2008-02-10 Johan Dahlin <johan@gnome.org>
5081 * m4/Makefile.am (EXTRA_DIST): its called as-compiler-flag.m4,
5084 * tests/parser/Makefile.am: Only create Foo.gidl when running make
5085 check, eg exclude it from BUILT_SOURCES.
5087 2008-02-08 Rob Taylor <rob.taylor@codethink.co.uk>
5092 * girepository/Makefile.am:
5093 * m4/Makefile.am: Added:
5094 * m4/as-compiler-flag.m4: Added:
5095 * m4/gcov.m4: Added:
5096 * tools/Makefile.am:
5097 Add ability to generate a coverage report.
5098 Adds configure option --enable-gcov and make rule 'check-coverage'.
5100 2008-02-08 Rob Taylor <rob.taylor@codethink.co.uk>
5104 * gidl/Makefile.am: Added:
5105 * girepository/Makefile.am: Added:
5106 * src/Makefile.am: Renamed to tools/Makefile.am:
5107 * src/compiler.c: Renamed to tools/compiler.c:
5108 * src/g-idl-offsets.pl: Renamed to tools/g-idl-offsets.pl:
5109 * src/generate.c: Renamed to tools/generate.c:
5110 * src/gidlmodule.c: Renamed to tools/gidlmodule.c:
5111 * src/gidlmodule.h: Renamed to tools/gidlmodule.h:
5112 * src/gidlnode.c: Renamed to tools/gidlnode.c:
5113 * src/gidlnode.h: Renamed to tools/gidlnode.h:
5114 * src/gidlparser.c: Renamed to tools/gidlparser.c:
5115 * src/gidlparser.h: Renamed to tools/gidlparser.h:
5116 * src/gidlwriter.c: Renamed to tools/gidlwriter.c:
5117 * src/gidlwriter.h: Renamed to tools/gidlwriter.h:
5118 * src/ginfo.c: Renamed to girepository/ginfo.c:
5119 * src/ginvoke.c: Renamed to girepository/ginvoke.c:
5120 * src/girepository.c: Renamed to girepository/girepository.c:
5121 * src/girepository.h: Renamed to girepository/girepository.h:
5122 * src/gmetadata.c: Renamed to girepository/gmetadata.c:
5123 * src/gmetadata.h: Renamed to girepository/gmetadata.h:
5124 * src/scanner.c: Renamed to tools/scanner.c:
5125 * src/scanner.h: Renamed to tools/scanner.h:
5126 * src/scannerlexer.l: Renamed to tools/scannerlexer.l:
5127 * src/scannerparser.y: Renamed to tools/scannerparser.y:
5128 * tests/invoke/Makefile.am:
5129 Split src/ into girepository/ and tools/
5133 * girepository/Makefile.am:
5134 * tests/Makefile.am:
5135 * tests/invoke/Makefile.am:
5136 * tests/parser/Makefile.am:
5137 * tests/roundtrips.sh:
5138 * tools/Makefile.am:
5139 Make distcheck work.
5141 2008-02-04 Rob Taylor <rob.taylor@codethink.co.uk>
5143 * tests/invoke/invoke.c: (main):
5144 * tests/invoke/testfns.c: (test6), (test7):
5145 * tests/invoke/testfns.xml:
5146 Add tests for invokation with a GList argument.
5147 Also tests caller-owns return values.
5149 2008-02-04 Rob Taylor <robtaylor@floopily.org>
5152 Add some documentation for GICallableInfo
5154 2008-02-01 Mark Doffman <mark.doffman@codethink.co.uk>
5157 Correct syntax errors in the DTD file.
5159 * relaxng/c-types.xml:
5160 * relaxng/g-types.xml:
5162 Add a RelaxNG specification for the GObject Introspection XML data.
5163 The Specification has validated all of the test files.
5165 2008-01-25 Rob Taylor <robtaylor@floopily.org>
5167 * tests/roundtrips.sh:
5168 * tests/struct.test:
5169 Add roundtrip tests for structs.
5171 2008-01-11 Johan Dahlin <johan@gnome.org>
5173 * src/scanner.c (g_igenerator_process_function_symbol):
5174 Refactor out g_idle_node_add_member.
5175 (create_node_from_gtype, create_node_from_ctype):
5176 Use case instead of if...else
5177 (get_type_from_type_id):
5178 Rename to create_node_from_gtype
5179 (get_type_from_ctype):
5180 Rename to create_node_from_ctype
5182 Rename ginode -> node, gitype -> type, gifunc -> func.
5184 * src/gidlnode.c (g_idl_node_add_member, g_idl_node_cmp):
5185 Two new functions, refactor out of scanner.c
5187 * src/scanner.c: (g_igenerator_process_function_symbol):
5188 * src/scannerlexer.l:
5189 Do not save the content of the deprecated variable, only
5192 2008-01-11 Johan Dahlin <johan@gnome.org>
5194 * tests/parser/foo-object.h: Add a couple of comment parser tests.
5196 2008-01-11 Jürg Billeter <j@bitron.ch>
5198 * src/scannerlexer.l:
5199 Fix GTK-Doc parsing.
5201 2008-01-11 Jürg Billeter <j@bitron.ch>
5203 * src/scannerlexer.l:
5204 Fix GTK-Doc parsing.
5206 2008-01-11 Jürg Billeter <j@bitron.ch>
5208 * src/scanner.c: (lookup_symbol):
5209 Return unresolved name if we find unknown symbol.
5211 2008-01-11 Jürg Billeter <j@bitron.ch>
5213 * src/scanner.c: (g_igenerator_generate):
5214 Initialize GObject to fix scanning interface properties.
5216 * tests/parser/Foo-expected.gidl:
5217 * tests/parser/foo-object.h:
5218 * tests/parser/foo.c: (foo_interface_get_type):
5219 Test interfaces with GObject prerequisite.
5221 * tests/parser/Makefile.am:
5222 Set G_DEBUG=fatal_warnings to abort test on warnings and criticals.
5224 2007-12-27 Johan Dahlin <johan@gnome.org>
5226 * src/scannerlexer.l:
5227 Parse gtk-doc comments.
5229 * src/gidlwriter.c: (function_generate):
5230 Reorganize, avoid duplication and add support for
5231 writing deprecated functions.
5233 * src/scannerparser.y:
5235 Add new structure CDirective and functions to create/free them.
5237 * src/scanner.c: (g_igenerator_process_function_symbol),
5238 (g_igenerator_process_unregistered_struct_typedef),
5239 (g_igenerator_process_struct_typedef),
5240 (g_igenerator_process_union_typedef),
5241 (g_igenerator_process_enum_typedef),
5242 (g_igenerator_process_function_typedef), (g_igenerator_add_symbol),
5243 (g_igenerator_start_preprocessor):
5244 Parse @deprecated directive for functions.
5245 Remove some more C99isms.
5246 Send in -C to cpp to avoid stripping comments.
5248 * tests/parser/foo-object.h:
5249 * tests/parser/Foo-expected.gidl:
5250 Add deprecated directive
5252 2007-12-27 Johan Dahlin <johan@gnome.org>
5254 * src/scannerlexer.l (intsuffix): Add emacs mode line and
5255 escape ' and " so it looks more like C.
5258 Unlink temporary file used.
5260 2007-12-27 Johan Dahlin <johan@gnome.org>
5262 * src/scanner.c: (g_igenerator_new), (g_igenerator_free),
5263 (g_igenerator_start_preprocessor), (main):
5265 * src/scannerparser.y:
5266 Plug a couple of simple memory leaks.
5268 2007-12-27 Johan Dahlin <johan@gnome.org>
5270 * src/scanner.c: (g_igenerator_parse_macros),
5271 (g_igenerator_start_preprocessor), (g_igenerator_set_verbose),
5274 * src/scannerparser.y:
5275 * tests/parser/Makefile.am:
5277 Improve error reporting, return when the preprocessor fails.
5278 Add a verbose parameter, to aid debugging.
5279 Revert to using a temporary file to communicate between the
5280 preprocessor and the parser, because we need to wait for
5281 the exit code from the pre-processor before starting to parse.
5283 2007-12-16 Johan Dahlin <jdahlin@async.com.br>
5285 * src/Makefile.am: Rename clexer.l to scannerlexer.l and
5286 cparser.y to scannerparser.y
5288 2007-12-11 Johan Dahlin <johan@gnome.org>
5292 * src/scanner.c: (g_igenerator_new):
5294 Get rid of the global the_generator variable.
5296 2007-12-10 Johan Dahlin <johan@gnome.org>
5298 * src/scanner.c (main): Add an output option,
5299 add checks for required parameters
5302 set BUILD_SOURCES and CLEANFILES properly
5304 * src/gidlwriter.c: (g_writer_write_inline), (g_writer_write),
5305 (g_writer_write_indent), (g_writer_write_unindent),
5306 (field_generate), (value_generate), (constant_generate),
5307 (property_generate), (function_generate), (vfunc_generate),
5308 (signal_generate), (interface_generate), (struct_generate),
5309 (union_generate), (boxed_generate), (enum_generate),
5310 (node_generate), (g_writer_write_module), (g_idl_writer_save_file):
5312 * src/scanner.c: (g_igenerator_generate):
5314 * src/scannerwriter.c:
5316 Refactor scannerwriter to only be tied to a GIdlModule and move
5317 it (again!) to gidlwriter.c. Change the writer function to take
5320 2007-12-10 Johan Dahlin <johan@gnome.org>
5323 * src/scanner.c: (g_igenerator_generate):
5325 * src/scannerwriter.c: (g_igenerator_write_inline),
5326 (g_igenerator_write), (g_igenerator_write_indent),
5327 (g_igenerator_write_unindent), (field_generate), (value_generate),
5328 (constant_generate), (property_generate), (function_generate),
5329 (vfunc_generate), (signal_generate), (interface_generate),
5330 (struct_generate), (union_generate), (boxed_generate),
5331 (enum_generate), (node_generate), (module_generate),
5332 (g_scanner_write_file):
5334 Move the scanner gidl writing to a separate source file.
5336 2007-12-10 Johan Dahlin <johan@gnome.org>
5341 Move over all CType construction functions.
5343 * tests/parser/Makefile.am:
5344 Be verbose when printing parsing tests results.
5346 2007-12-10 Johan Dahlin <johan@gnome.org>
5348 * src/scanner.c (g_igenerator_start_preprocessor): Refactor
5349 preprocessor handling to here. Start cpp insteado of cc -E,
5350 always include -U__GNUC__, since it's specific to the preprocessor
5353 * tests/parser/Makefile.am (check-local): Silent diff and skip
5354 -U__GNUC__ which is always defined now
5356 2007-12-10 Johan Dahlin,,, <jdahlin@plasttroll>
5358 reviewed by: <delete if not using a buddy>
5360 * src/scanner.c: (g_igenerator_start_preprocessor), (main):
5361 * tests/parser/Makefile.am:
5363 2007-12-09 Johan Dahlin <johan@gnome.org>
5366 Use GOption for command line options.
5367 (g_igenerator_new, main): Simplify constructor and they way
5368 parameters are passed into it.
5374 * src/gen-introspect.c:
5375 * src/gen-introspect.h:
5377 Rename gen-introspect.[ch] to scanner.[ch]
5379 2007-12-09 Johan Dahlin <johan@gnome.org>
5383 * src/Makefile.am: Rename gen-introspect to g-idl-scanner,
5384 don't make the repository library and the other utilites link against
5387 * src/gen-introspect.c: (g_igenerator_create_object),
5388 (g_igenerator_create_interface), (g_igenerator_create_boxed),
5389 (g_igenerator_create_enum), (g_igenerator_create_flags),
5390 (g_igenerator_process_module_symbol),
5391 (g_igenerator_process_module), (g_igenerator_generate), (main):
5392 * src/gen-introspect.h:
5393 Refactor g_igenerator_process_types into smaller pieces.
5395 * tests/parser/Makefile.am:
5396 Depend on the gen-introspect binary
5398 2007-12-09 Johan Dahlin <johan@gnome.org>
5400 * src/gen-introspect.c (g_igenerator_process_types):
5401 Break into smaller pieces, one for each generated node type.
5403 2007-12-08 Johan Dahlin <johan@gnome.org>
5405 * src/gen-introspect.c: (g_igenerator_process_types),
5406 (g_igenerator_add_module):
5407 * tests/parser/Foo-expected.gidl:
5408 * tests/parser/foo-object.h:
5409 * tests/parser/foo.c: (foo_subobject_class_init),
5410 (foo_subobject_init):
5412 Add a subobject test and make sure to register defined classes
5413 in the lookup symbol hash table.
5415 2007-12-08 Johan Dahlin <johan@gnome.org>
5419 * src/gen-introspect.c: (g_igenerator_new), (lookup_symbol),
5420 (g_igenerator_process_types), (g_igenerator_add_module),
5421 (g_igenerator_add_include_idl), (main):
5422 * src/gen-introspect.h:
5423 * tests/parser/Makefile.am:
5424 * tests/parser/Foo-expected.gidl:
5426 Change the gen-introspect to generate namespaced module names,
5427 such as GLib.Object instead of GObject.
5428 Add a GLib.gidl which introduces GLib.Object and GLib.InitiallyUnowned,
5429 add a --include-idl parameter to gen-introspect,
5430 and update the parser test.
5432 2007-12-08 Johan Dahlin <johan@gnome.org>
5434 * src/gen-introspect.c:
5435 Move main to the end of the file and attempt to make it valid
5438 * tests/parser/Makefile.am (BUILT_SOURCES): Remove .repo here,
5439 we're not quite ready to generate metadata yet.
5444 Add a simple gen-introspect parser test
5446 2007-12-06 Gustavo J. A. M. Carneiro <gjc@gnome.org>
5448 reviewed by: Johan Dahlin <johan@gnome.org>
5451 * gobject-introspection.pc.in:
5453 * src/compiler.c: (format_output), (write_out_metadata), (main):
5454 * src/gen-introspect.c: (main):
5455 * src/gen-introspect.h:
5456 * src/generate.c: (write_callable_info), (write_repository),
5457 (load_metadata), (main):
5458 * src/gidlmodule.c: (g_idl_module_new),
5459 (g_idl_module_build_metadata):
5461 * src/gidlparser.c: (start_element_handler):
5462 * src/ginfo.c: (g_info_new), (g_info_from_entry),
5463 (g_base_info_get_name), (g_base_info_get_namespace),
5464 (g_base_info_is_deprecated), (g_base_info_get_annotation),
5465 (g_base_info_get_metadata), (g_function_info_get_symbol),
5466 (g_function_info_get_flags), (g_function_info_get_property),
5467 (g_function_info_get_vfunc), (signature_offset), (g_type_info_new),
5468 (g_callable_info_may_return_null),
5469 (g_callable_info_get_caller_owns), (g_callable_info_get_n_args),
5470 (g_callable_info_get_arg), (g_arg_info_get_direction),
5471 (g_arg_info_is_return_value), (g_arg_info_is_dipper),
5472 (g_arg_info_is_optional), (g_arg_info_may_be_null),
5473 (g_arg_info_get_ownership_transfer), (g_type_info_is_pointer),
5474 (g_type_info_get_tag), (g_type_info_get_param_type),
5475 (g_type_info_get_interface), (g_type_info_get_array_length),
5476 (g_type_info_is_zero_terminated),
5477 (g_type_info_get_n_error_domains), (g_type_info_get_error_domain),
5478 (g_error_domain_info_get_quark), (g_error_domain_info_get_codes),
5479 (g_value_info_get_value), (g_field_info_get_flags),
5480 (g_field_info_get_size), (g_field_info_get_offset),
5481 (g_registered_type_info_get_type_name),
5482 (g_registered_type_info_get_type_init),
5483 (g_struct_info_get_n_fields), (g_struct_info_get_field),
5484 (g_struct_info_get_n_methods), (g_struct_info_get_method),
5485 (find_method), (g_struct_info_find_method),
5486 (g_enum_info_get_n_values), (g_enum_info_get_value),
5487 (g_object_info_get_parent), (g_object_info_get_type_name),
5488 (g_object_info_get_type_init), (g_object_info_get_n_interfaces),
5489 (g_object_info_get_interface), (g_object_info_get_n_fields),
5490 (g_object_info_get_field), (g_object_info_get_n_properties),
5491 (g_object_info_get_property), (g_object_info_get_n_methods),
5492 (g_object_info_get_method), (g_object_info_find_method),
5493 (g_object_info_get_n_signals), (g_object_info_get_signal),
5494 (g_object_info_get_n_vfuncs), (g_object_info_get_vfunc),
5495 (g_object_info_get_n_constants), (g_object_info_get_constant),
5496 (g_interface_info_get_n_prerequisites),
5497 (g_interface_info_get_prerequisite),
5498 (g_interface_info_get_n_properties),
5499 (g_interface_info_get_property), (g_interface_info_get_n_methods),
5500 (g_interface_info_get_method), (g_interface_info_find_method),
5501 (g_interface_info_get_n_signals), (g_interface_info_get_signal),
5502 (g_interface_info_get_n_vfuncs), (g_interface_info_get_vfunc),
5503 (g_interface_info_get_n_constants),
5504 (g_interface_info_get_constant), (g_property_info_get_flags),
5505 (g_signal_info_get_flags), (g_signal_info_get_class_closure),
5506 (g_signal_info_true_stops_emit), (g_vfunc_info_get_flags),
5507 (g_vfunc_info_get_offset), (g_vfunc_info_get_signal),
5508 (g_constant_info_get_value), (g_union_info_get_n_fields),
5509 (g_union_info_get_field), (g_union_info_get_n_methods),
5510 (g_union_info_get_method), (g_union_info_is_discriminated),
5511 (g_union_info_get_discriminator_offset),
5512 (g_union_info_get_discriminator):
5513 * src/ginvoke.c: (g_function_info_invoke):
5514 * src/girepository.c: (g_irepository_register),
5515 (g_irepository_unregister), (g_irepository_get_default),
5516 (count_interfaces), (g_irepository_get_n_infos), (find_interface),
5517 (g_irepository_get_info), (g_irepository_find_by_name),
5518 (g_irepository_get_shared_library),
5519 (g_irepository_build_search_path), (g_irepository_register_file),
5520 (g_irepository_error_quark):
5521 * src/girepository.h:
5522 * src/gmetadata.c: (g_metadata_get_dir_entry),
5523 (g_metadata_check_sanity), (validate_header),
5524 (validate_array_type_blob), (validate_iface_type_blob),
5525 (validate_param_type_blob), (validate_error_type_blob),
5526 (validate_type_blob), (validate_arg_blob),
5527 (validate_signature_blob), (validate_function_blob),
5528 (validate_callback_blob), (validate_constant_blob),
5529 (validate_value_blob), (validate_field_blob),
5530 (validate_property_blob), (validate_signal_blob),
5531 (validate_vfunc_blob), (validate_struct_blob),
5532 (validate_enum_blob), (validate_object_blob),
5533 (validate_interface_blob), (validate_errordomain_blob),
5534 (validate_union_blob), (validate_blob), (validate_directory),
5535 (validate_annotations), (g_metadata_validate), (_g_metadata_init),
5536 (g_metadata_new_from_memory), (g_metadata_new_from_const_memory),
5537 (g_metadata_new_from_mapped_file), (g_metadata_free),
5538 (g_metadata_set_module), (g_metadata_get_namespace):
5540 * tests/Makefile.am:
5541 * tests/invoke/Makefile.am:
5542 * tests/invoke/invoke-namespace-find.sh:
5543 * tests/invoke/invoke.c: (main):
5545 Add a namespace/shared library mapping. fixes #313268.
5547 2007-12-03 Johan Dahlin <johan@gnome.org>
5549 * src/gidlparser.c (parse_type_internal): Disable char/gchar and
5552 2007-11-30 Jürg Billeter <j@bitron.ch>
5558 * src/gen-introspect.c: (g_idl_node_cmp), (g_igenerator_new),
5559 (g_igenerator_write_inline), (g_igenerator_write),
5560 (g_igenerator_write_indent), (g_igenerator_write_unindent),
5561 (field_generate), (value_generate), (constant_generate),
5562 (property_generate), (function_generate), (vfunc_generate),
5563 (signal_generate), (interface_generate), (struct_generate),
5564 (union_generate), (boxed_generate), (enum_generate),
5565 (node_generate), (module_generate), (get_type_from_type_id),
5566 (str_replace), (g_igenerator_process_properties),
5567 (g_igenerator_process_signals), (g_igenerator_process_types),
5568 (get_type_from_ctype), (g_igenerator_process_function_symbol),
5569 (g_igenerator_process_unregistered_struct_typedef),
5570 (g_igenerator_process_struct_typedef),
5571 (g_igenerator_process_union_typedef),
5572 (g_igenerator_process_enum_typedef),
5573 (g_igenerator_process_function_typedef),
5574 (g_igenerator_process_constant), (g_igenerator_process_symbols),
5575 (g_igenerator_add_symbol), (g_igenerator_is_typedef),
5576 (g_igenerator_generate), (main), (csymbol_new),
5577 (csymbol_get_const_boolean), (ctype_new), (ctype_copy),
5578 (cbasic_type_new), (ctypedef_new), (cstruct_new), (cunion_new),
5579 (cenum_new), (cpointer_new), (carray_new), (cfunction_new),
5580 (eat_hspace), (eat_line), (read_identifier),
5581 (g_igenerator_parse_macros):
5582 * src/gen-introspect.h:
5584 Import gen-introspect to generate introspection information by
5587 2007-11-30 Jürg Billeter <j@bitron.ch>
5589 * src/gidlnode.c: (g_idl_node_new): support creating callback nodes
5591 2007-11-30 Jürg Billeter <j@bitron.ch>
5593 * src/gidlparser.c: (end_element_handler): Don't leave requires
5596 2007-11-29 Johan Dahlin <johan@gnome.org>
5598 * src/gidlparser.c (parse_type_internal): Add char,
5599 gchar and guchar to the builtin types.
5601 2007-11-26 Johan Dahlin <johan@gnome.org>
5603 * src/ginfo.c: (g_object_info_get_type_name),
5604 (g_object_info_get_type_init):
5605 * src/girepository.c: (g_irepository_is_registered):
5606 * src/girepository.h:
5608 Add g_object_info_get_type_name, g_object_info_get_type_init and
5609 g_irepository_is_registered.
5611 2006-08-14 Jürg Billeter <j@bitron.ch>
5613 * src/gidlparser.c: (end_element_handler): Don't leave
5614 namespace and implements states too early.
5617 2007-11-26 Johan Dahlin <johan@gnome.org>
5619 * src/gmetadata.c (validate_struct_blob):
5620 pass blob_type to validate_function_blob instead of
5621 hard-coding BLOB_TYPE_STRUCT.
5623 Patch by Torsten Schoenfeld, fixes #314190
5625 2006-10-03 Torsten Schoenfeld <tsch@cvs.gnome.org>
5627 * src/compiler.c, src/generate.c, src/gidlnode.c,
5628 src/gidlparser.c, src/ginfo.c, src/girepository.c,
5629 tests/invoke/invoke.c, test/invoke/testfns.c: Hush compiler
5630 warnings about return values, signedness mismatches, unused
5631 variables, and unhandles enum values in switch statements.
5633 * tests/invoke/Makefile.am: Don't install the invoke test program.
5634 Add -I ../../src to the cflags used for the test functions files.
5636 2005-08-31 Torsten Schoenfeld <tsch@cvs.gnome.org>
5638 * src/girepository.h: Export g_invoke_error_quark.
5640 2005-08-31 Torsten Schoenfeld <tsch@cvs.gnome.org>
5642 * src/ginvoke.c: Remove the fallback implementation of
5643 g_function_info_invoke since we now formally depend on libffi.
5645 2005-07-25 Matthias Clasen <mclasen@redhat.com>
5647 * src/Makefile, tests/Makefile, tests/invoke/Makefile:
5648 Remove these files from cvs, as they are now generated.
5650 * src/gmetadata.c (validate_iface_type_blob): Don't
5651 complain if blob->pointer is not set, since that
5652 happens for enum and flag types. (#308935, Gustavo
5655 * Commit an autoconf-conversion patch by
5656 Gustavo Carneiro (#308708)
5658 2005-05-24 Matthias Clasen <mclasen@redhat.com>
5660 * src/compiler.c (main): Use it here to validate
5661 the generated metadata.
5663 * src/gmetadata.[hc]: Add code to validate a
5666 * metadata-format.txt: Updates
5668 2005-05-22 Matthias Clasen <mclasen@redhat.com>
5670 * tests/*: Add struct offsets to field and vfunc
5673 * src/generate.c (write_vfunc_info): Write offset
5674 information for vfuncs.
5676 * src/gidlnode.c (g_idl_node_build_metadata): Write
5677 the struct offsets into the metadata.
5679 * src/gidlparser.c: Parse the offset attributes of
5680 field and vfunc elements.
5682 * src/gidlnode.h: Add offset members to field and
5685 2005-05-21 Matthias Clasen <mclasen@redhat.com>
5689 * gidl.dtd: Updates.
5691 * src/g-idl-offsets.pl: A perl script which reads a .gidl
5692 file, creates, compiles and runs a C file, and folds the
5693 resulting struct offsets back into the .gidl file.
5695 2005-05-20 Matthias Clasen <mclasen@redhat.com>
5697 * src/gidlparser.c (start_field): Make fields in objects
5700 * src/gidlmodule.c: Include string.h
5705 * metadata-format.txt: Cleanup basic types.
5706 * src/*: Adapt to the changes.
5707 * tests/*: Adapt to the changes.
5708 * examples/gdk-pixbuf.gidl: Adapt to the changes.
5710 * src/gidlnode.c (g_idl_node_get_size): Report the correct
5711 size for enum blobs.
5712 (g_idl_node_get_full_size): Report the correct size for
5715 * src/gidlmodule.c (g_idl_module_build_metadata): Add some
5716 error checking for blob sizes.
5718 2005-05-19 Matthias Clasen <mclasen@redhat.com>
5720 * src/gidlnode.c (g_idl_node_build_metadata): Correctly handle
5721 interface types for which is_pointer is FALSE, e.g. enums.
5723 * src/gidlnode.c (g_idl_node_get_full_size)
5724 * src/gidlparser.c (parse_type_internal):
5725 * src/generate.c (write_type_info): Support unspecialized
5726 lists, hashtables and errors. Also emit a '*' after these.
5730 2005-05-17 Matthias Clasen <mclasen@redhat.com>
5734 * metadata-format.txt: Cleanups by Maciej Katafiasz.
5736 2005-05-15 Matthias Clasen <mclasen@redhat.com>
5738 * src/*.c: Change the directory to be addressed by
5739 1-based indexes, and use an index of zero to mean
5742 2005-05-15 Matthias Clasen <mclasen@redhat.com>
5744 * tests/roundtrips.sh (SIMPLE_TESTS): Add union.test.
5746 * tests/union.test: Add a union test.
5748 * src/generate.c: Handle unions.
5750 * src/girepository.h:
5751 * src/ginfo.c: Add GIUnionInfo and functions to access it.
5753 * src/gidlnode.c: Handle GIdlNodeUnion nodes.
5755 * src/gidlparser.c (start_union): Parse <union> elements.
5757 * src/gidlnode.h: Add a GIdlNodeUnion.
5759 * gidl.dtd: Add a <union> element.
5761 * src/gmetadata.c (g_metadata_check_sanity): Check
5764 * src/gmetadata.h: Add union_blob_size to Header,
5767 * metadata-format.txt: Add a UnionBlob.
5769 2005-05-13 Matthias Clasen <mclasen@redhat.com>
5771 * tests/*: Update testcases.
5773 * src/generate.c (write_callable_info): Don't forget to
5774 write transfer and null-ok attributes for return types
5777 * src/girepository.h:
5778 * src/ginfo.c (g_callable_info_may_return_null):
5779 New function to find out if a function may return NULL.
5781 * src/compiler.c (format_output): Make the generated
5784 * README: Point to a recent libffi snapshot.
5786 * tests/invoke/*: Some invoke tests.
5788 * src/Makefile: Add ginvoke.c and the necessary
5791 * src/girepository.h (g_function_info_invoke): Add
5794 * src/ginvoke.c (g_function_info_invoke): Initial
5795 implementation of invoke functionality based on libffi.
5797 * src/gidlnode.c (g_idl_node_build_metadata): Pass the
5798 strings and types hash tables in the right order when
5800 (find_entry_node): Free the name parts.
5802 2005-05-12 Johan Dahlin <johan@gnome.org>
5804 * src/generate.c: Generate consistent end tags.
5808 2005-05-12 Matthias Clasen <mclasen@redhat.com>
5812 * src/gidlparser.c (start_function): Actually add
5813 methods to objects. (Steven Walter)
5815 * src/girepository.h:
5816 * src/ginfo.c: Rename Transfer and Direction to
5817 GITransfer and GIDirection. (Torsten Schoenfeld)
5819 * tests/*: Make tests work with the changes in name
5822 * src/gidlnode.c (find_entry_node): Parse qualified
5823 names and generate xref nodes for them if needed. Don't
5824 require all modules to be loaded any more.
5826 * src/gidlmodule.c (g_idl_module_build_metadata): Choke
5829 * src/ginfo.c (g_object_info_get_parent): Return NULL
5830 if blob->parent is 0. Still need to make sure index
5833 * src/generate.c: Generate qualified names when
5834 referring to non-local types. Emit transfer attribute
5837 * src/compiler.c (format_output): Put the function
5838 attributes where gcc accepts them.
5840 2005-05-11 Matthias Clasen <mclasen@redhat.com>
5842 * src/compiler.c (main): Add a --verbose cmdline option
5843 and only log messages if it is specified.
5846 * src/gidlnode.c (init_stats, dump_stats): Collect some
5847 statistics on string and type sharing.
5849 * src/gidlmodule.c (g_idl_module_build_metadata): Use
5850 g_message() instead of fprintf().
5852 * src/gidlnode.c (g_idl_node_free): Make this more robust.
5853 (g_idl_node_get_size): Implement for structs.
5854 (g_idl_node_get_full_size): Handle parent being NULL.
5855 (serialize_type): Handle lookup failures more gracefully.
5857 2005-05-10 Matthias Clasen <mclasen@redhat.com>
5859 * src/gidlnode.c (g_idl_node_get_full_size): Correct the
5860 size calculation for 2-parameter types and for objects.
5862 * src/compiler.c: Add a cmdline option for debug output
5863 and install a log handler to implement it.
5864 * src/gidlnode.c: Add some debug spew.
5868 * src/gidlmodule.c (g_idl_module_build_metadata): Don't
5869 forget to count the module name when calculating the
5870 required size for the metadata.
5873 * src/gidlparser.c: Fix compiler warnings.
5875 2005-05-09 Matthias Clasen <mclasen@redhat.com>
5877 * src/compiler.c (main): Free the option context.
5879 * gidl.dtd: Clean up handling of names. All elements
5880 have a "name", only the elements corresponding to
5881 actual callable functions (function, method, constructor),
5882 have an additional "symbol" attribute holding the
5883 dlsym()-able function name.
5885 * src/generate.c: Adapt to generate xml matching the
5889 * src/gidlnode.c: Adapt to parse the new dtd.
5891 * tests/*.test: Adjust to the new dtd.
5893 * metadata-format.txt:
5894 * src/gmetadata.h: Remove the short_name field
5896 * src/gmetadata.c: Shrink size of ValueBlob to 12.
5897 * src/girepository.h:
5898 * src/ginfo.c (g_value_info_get_short_name): Removed
5900 2005-05-09 Matthias Clasen <mclasen@redhat.com>
5902 * gidl.dtd: Allow constructors for boxed types,
5903 patch by Jonathan Blandford.
5906 2005-05-09 Matthias Clasen <mclasen@redhat.com>
5908 * --- Initial import ---