1 2009-02-02 Dan Winship <danw@gnome.org>
3 * girepository/ginfo.c (g_registered_type_info_get_g_type): handle
4 the special case for GObject, whose glib:get-type is listed as
7 2009-02-02 Andreas Rottmann <a.rottmann@gmx.at>
9 Bug 569408 – Scanner doesn't handle arbitrary typedefs correctly
11 * giscanner/glibtransformer.py (GLibTransformer._create_gobject):
12 Treat GInitiallyUnowned specially.
14 Bug 568680 – Scanner misses fields (at least in GObject.Object)
16 * girepository/giroffsets.c (compute_struct_field_offsets): Fix
17 handling of callbacks (a callback member clobbered the size
20 * giscanner/transformer.py (Transformer._create_compound): Use
21 the (empty) compound created by a typedef if present; this means
22 that fields will no longer get lost.
24 * giscanner/transformer.py (Transformer._create_compound): New
25 method, contains logic common to _create_union and _create_struct.
26 (Transformer._create_struct, Transformer._create_union): Rewritten
27 in terms of _create_compound.
29 * gir/GObject-2.0.xpath: Some new assertations of the presence
31 * tests/offsets/Makefile.am, tests/offsets/offsets.h: Added test
32 for object field offsets.
34 2009-02-02 Andreas Rottmann <a.rottmann@gmx.at>
36 Bug 563469 – Arrays not treated correctly in struct offset calculation
38 * tests/offsets/offsets.h (OffsetsArray): New struct, containing a
41 * tests/offsets/gen-gitestoffsets (FIELD_RE): Handle arrays.
43 * girepository/giroffsets.c (get_interface_size_alignment):
44 Refactored to make it more general, now takes a GIrNodeType*
45 instead of a GIrNodeField*, plus an additional 'who' parameter
46 that denotes what the size/alignment is calculated for.
47 (get_type_size_alignment): New function, refactored version of
48 get_field_size_alignment().
49 (get_field_size_alignment): Implemented in terms of
50 get_type_size_alignment().
51 (get_type_size_alignment): Handle array types correctly.
53 2009-01-28 Johan Bilien <jobi@via.ecp.fr>
55 * tests/scanner/annotation-1.0-expected.gir: add missing
58 2009-01-27 Johan Dahlin <jdahlin@async.com.br>
61 * gir/fontconfig-2.0.gir:
62 * gir/freetype2-2.0.gir:
63 * gir/libxml2-2.0.gir:
67 Remove shared-library tags for these too.
69 2009-01-27 Johan Dahlin <jdahlin@async.com.br>
72 Remove shared-library which removes the build
73 time dependency on mesa.
75 2009-01-27 Dan Winship <danw@gnome.org>
79 * giscanner/scannerparser.y: Fix the "Ignoring non-UTF-8 constant
80 string" error to print the right value.
82 * tests/scanner/annotation.c (backslash_parsing_tester)
83 (backslash_parsing_tester_2): make these non-static to avoid a
85 (annotation_object_string_out)
86 (annotation_string_zero_terminated): fix return values
88 * tests/scanner/annotation.h (annotation_object_with_voidp):
91 * tests/scanner/gtkfrob.c:
92 * tests/scanner/gtkfrob.h (gtk_frob_language_manager_get_default):
93 fix prototype. (s/()/(void)/).
95 * tools/compiler.c (format_output): fix signed/unsigned warning.
96 Output a prototype for register_typelib() to avoid warnings later.
98 2009-01-26 Johan Dahlin <jdahlin@async.com.br>
100 * tests/everything/everything.c (test_callback):
101 * tests/everything/everything.h:
102 Add a couple of callback tests.
104 2009-01-26 Johan Dahlin <jdahlin@async.com.br>
106 * girepository/ginfo.c (g_base_info_unref):
107 Only unref the repository if it's actually set.
109 2009-01-23 Johan Dahlin <jdahlin@async.com.br>
111 * tests/everything/everything.c (test_enum_param):
112 * tests/everything/everything.h:
114 Add an enum param test function
116 2009-01-21 Johan Dahlin <jdahlin@async.com.br>
119 Post-release version bump
122 2009-01-21 Johan Dahlin <jdahlin@async.com.br>
126 2009-01-21 Johan Dahlin <jdahlin@async.com.br>
128 Bug 562622 – Errordomains missing
130 * giscanner/girwriter.py:
131 * giscanner/glibast.py:
132 * giscanner/glibtransformer.py:
133 * tests/scanner/Makefile.am:
134 * tests/scanner/foo-1.0-expected.gir:
135 * tests/scanner/foo-1.0-expected.tgir:
136 * tests/scanner/foo.c (foo_error_get_type), (foo_error_quark):
137 * tests/scanner/foo.h:
139 2009-01-20 Johan Dahlin <jdahlin@async.com.br>
141 * giscanner/scannerlexer.l:
142 Increase the buffer size to 1M, so
143 gtkalias.h can be parsed.
145 2009-01-20 Johan Dahlin <jdahlin@async.com.br>
147 * giscanner/glibtransformer.py:
148 When trying to map functions to structs, do
149 not require a public structure to exist, should
150 fix Gst gir generation in.
152 2009-01-20 Johan Dahlin <jdahlin@async.com.br>
154 Bug 562615 – Struct methods missing
156 * giscanner/annotationparser.py:
158 * giscanner/girwriter.py:
159 * giscanner/glibast.py:
160 * giscanner/glibtransformer.py:
161 * tests/scanner/foo-1.0-expected.gir:
162 * tests/scanner/foo-1.0-expected.tgir:
164 2009-01-16 Dan Winship <danw@gnome.org>
166 * gir/GL-1.0.gir: add back GLvoid, which got lost during the
167 gir-repository -> gobject-introspection migration
169 2009-01-15 Johan Dahlin <jdahlin@async.com.br>
171 * gir/freetype2-2.0.gir: add FT_Int32
172 * gir/xft-2.0.gir: add XftFont
173 * girepository/gdump.c (g_irepository_dump):
174 Report errors when an invalid type is encountered
175 * giscanner/glibtransformer.py:
176 Make the error message a bit nicer.
178 Part of preparating for gir generating inside pango.
180 2009-01-15 Johan Dahlin <jdahlin@async.com.br>
185 * gir/fontconfig-2.0.gir:
186 * gir/freetype2-2.0.gir:
187 * gir/libxml2-2.0.gir:
188 * gir/xfixes-4.0.gir:
192 Move over the hand-written girs from gir-repository
193 so upstream libraries depending on these can avoid
194 a gir-repository dependency.
196 2009-01-15 Johan Dahlin <jdahlin@async.com.br>
198 Bug 567813 – Everything should be versioned
201 * girepository/Makefile.am:
202 * girepository/girepository.c (init_globals):
203 * girepository/girparser.c (locate_gir):
204 * giscanner/dumper.py:
205 * giscanner/transformer.py:
206 * gobject-introspection-1.0.pc.in:
207 * tests/everything/Makefile.am:
208 * tests/invoke/Makefile.am:
209 * tests/offsets/Makefile.am:
210 * tests/repository/Makefile.am:
211 * tests/scanner/Makefile.am:
214 2009-01-13 Johan Dahlin <jdahlin@async.com.br>
216 Bug 555036 – put gtk-doc in GIR
218 * giscanner/annotationparser.py:
220 * giscanner/girwriter.py:
221 * giscanner/glibast.py:
222 * tests/scanner/annotation-1.0-expected.gir:
223 * tests/scanner/annotation.h:
224 * tests/scanner/foo-1.0-expected.gir:
226 2009-01-13 Johan Dahlin <jdahlin@async.com.br>
228 * giscanner/cachestore.py (CacheStore.load): Catch AttributeError
229 which seems to be occasionally raised for Record.
231 * giscanner/annotationparser.py:
232 Fix a bug where \n was not present in a comment
234 2009-01-12 Johan Dahlin <jdahlin@async.com.br>
236 Bug 562467 – Property annotation
238 * giscanner/annotationparser.py:
239 * tests/scanner/annotation-1.0-expected.gir:
240 * tests/scanner/annotation-1.0-expected.tgir:
241 * tests/scanner/annotation.c (annotation_object_set_property),
242 (annotation_object_get_property), (annotation_object_class_init):
244 Annotations are parsed for properties.
246 2009-01-12 Johan Dahlin <jdahlin@async.com.br>
248 Bug 546739 – Introspection should know precise signal parameter types
250 * giscanner/annotationparser.py:
251 * tests/scanner/annotation-1.0-expected.gir:
252 * tests/scanner/annotation-1.0-expected.tgir:
253 * tests/scanner/annotation.c (annotation_object_class_init):
255 Annotations are parsed for signals, the (type) annotation is introduced.
257 2009-01-12 Johan Dahlin <jdahlin@async.com.br>
259 Bug 563591 – Flags not recognized when there is no introspection data
262 * giscanner/girwriter.py:
263 * giscanner/giscannermodule.c (type_get_is_bitfield):
264 * giscanner/glibast.py:
265 * giscanner/glibtransformer.py:
266 * giscanner/scannerparser.y:
267 * giscanner/sourcescanner.c (gi_source_type_copy):
268 * giscanner/sourcescanner.h:
269 * giscanner/sourcescanner.py:
270 * giscanner/transformer.py:
271 * tests/scanner/foo-1.0-expected.gir:
272 * tests/scanner/foo-1.0-expected.tgir:
273 * tests/scanner/foo.h:
275 Large parts of this patch was done by Jürg Billeter.
277 2009-01-12 Havoc Pennington <hp@pobox.com>
279 Bug 563386 – scanner ignores "const" on boxed return values
281 * tests/everything/everything.c (test_simple_boxed_a_const_return):
282 * tests/everything/everything.h:
284 This adds just the tests specified in the bug above, the fix itself
285 was included in Bug 563794
287 2009-01-03 Andreas Rottmann <a.rottmann@gmx.at>
289 Bug 566404 – Annotations for GLib
291 * gir/glib-2.0.c: Added allow-none annotations for g_thread_init()
292 and g_main_loop_new().
294 2009-01-12 Johan Dahlin <jdahlin@async.com.br>
296 Bug 566419 – Element type of arrays not properly handled in all cases
298 * giscanner/annotationparser.py:
299 * tests/scanner/annotation-1.0-expected.gir:
300 * tests/scanner/annotation-1.0-expected.tgir:
301 * tests/scanner/annotation.c (annotation_object_set_data),
302 (annotation_object_set_data2), (annotation_object_set_data3):
303 * tests/scanner/annotation.h:
305 Based on patch by Andreas Rottmann
307 2009-01-12 Johan Dahlin <jdahlin@async.com.br>
309 Bug 566560 – giscanner.transformer.SkipError
311 * giscanner/transformer.py:
313 Catch SkipError for all nodes, not just functions.
314 Makes it possible to skip unsupported parameter types in
317 2009-01-12 Johan Dahlin <jdahlin@async.com.br>
319 Bug 563794 - Redo annotation parsing & applying
321 Thanks to Colin for helping out considerably in landing this.
323 * giscanner/Makefile.am:
325 * giscanner/dumper.py:
326 * giscanner/girparser.py:
327 * giscanner/giscannermodule.c (pygi_source_scanner_get_comments),
328 (calc_attrs_length), (pygi_collect_attributes), (init_giscanner):
329 * giscanner/glibtransformer.py:
330 * giscanner/scannerlexer.l:
331 * giscanner/sourcescanner.c (gi_source_symbol_unref),
332 (gi_source_scanner_new), (gi_source_scanner_free),
333 (gi_source_scanner_get_comments):
334 * giscanner/sourcescanner.h:
335 * giscanner/sourcescanner.py:
336 * giscanner/transformer.py:
337 * giscanner/xmlwriter.py:
338 * tests/scanner/annotation-1.0-expected.gir:
339 * tests/scanner/annotation-1.0-expected.tgir:
340 * tests/scanner/annotation.c:
341 * tests/scanner/annotation.h:
342 * tests/scanner/foo-1.0-expected.gir:
343 * tests/scanner/foo-1.0-expected.tgir:
344 * tests/scanner/foo.h:
345 * tools/g-ir-scanner:
347 This commit merges the annotation parser rewrite branch.
348 It'll change the annotation parsing to be done completely in python
349 code which will make it easier to do further annotation parsing
352 2009-01-03 Andreas Rottmann <a.rottmann@gmx.at>
354 Bug 563469 – Arrays not treated correctly in struct offset calculation
356 * tests/scanner/foo.h (FooObject): Added field `some_int'.
357 * tests/scanner/foo-1.0-expected.gir,
358 * tests/scanner/foo-1.0-expected.tgir: Adapted.
360 * giscanner/glibtransformer.py (GLibTransformer._create_gobject):
361 carry over object fields from original (struct) node.
362 (GLibTransformer._pair_class_struct): Don't add fields of the
363 class struct to to the node for the class, they should go under a
364 nested <record> element (see also Bug 551738). This is needed as
365 otherwise offset calculation would not work, as the instance
366 fields are mingled with the class fields without a way to
369 2009-01-03 Johan Dahlin <jdahlin@async.com.br>
372 Disable blank line check, it works differently under
373 Python 2.5 from 2.6 and was rather annoying from the start.
375 2008-01-03 Andreas Rottmann <a.rottmann@gmx.at>
377 Bug 556489 – callback annotations
379 * giscanner/transformer.py
381 * tools/generate.c (write_callable_info): Write out the new scope,
382 closure and destroy attributes.
384 * giscanner/transformer.py (Transformer._type_is_callback): New
385 method, checking if a given type is a callback.
386 (Transformer._augment_callback_params): New method; adds
387 information (closure, destroy) to callback parameters.
388 (Transformer._handle_closure, Transformer._handle_destroy): New methods,
389 auxiliary to _augment_callback_params.
390 (Transformer._create_function): Call _augment_callback_params().
391 (Transformer._create_parameter): Handle scope option.
393 (Transformer._create_typedef_callback): New method, creates a
394 callback, and registers it in the typedef namespace
395 (Transformer._create_typedef): Use _create_typedef_callback()
396 instead of the plain _create_callback().
398 * giscanner/ast.py (Parameter): Added callback-related fields.
399 * giscanner/girwriter.py: Write out new Parameter fields.
401 * girepository/girnode.h (GIrNodeParam): Added fields scope,
403 * girepository/gtypelib.h (ArgBlob): Ditto.
404 * girepository/girparser.c (start_parameter): Handle new fields.
406 * girepository/girmodule.c (g_ir_module_build_typelib): Adjust
407 arg_blob_size, bump major version due to this change.
408 * girepository/girnode.c (g_ir_node_get_full_size_internal)
409 (g_ir_node_build_typelib)
410 * girepository/gtypelib.c (g_typelib_check_sanity): ArgBlob size
412 (g_ir_node_build_typelib): Fill in new ArgBlob flags from param.
414 * girepository/girepository.h (GIScope): New enumeration, listing
415 the different possible scopes for callbacks.
417 * girepository/ginfo.c (g_arg_info_get_scope)
418 (g_arg_info_get_closure, g_arg_info_get_destroy): Accessors for
419 callback-related argument indices (callback scope, closure for a
420 callback, destroy notification for a callback).
422 * tests/scanner/: Added testcases for new features.
424 2009-01-03 Jürg Billeter <j@bitron.ch>
427 * giscanner/dumper.py:
428 * giscanner/girparser.py:
429 * giscanner/glibtransformer.py:
430 * giscanner/sourcescanner.py:
431 * giscanner/transformer.py:
432 * giscanner/xmlwriter.py:
434 Fix inconsistencies with PEP8
436 2008-12-21 Johan Dahlin <jdahlin@async.com.br>
439 Annotate transfer, direction and allow none for
440 g_file_load_contents, g_file_load_contents_finish and
441 g_file_load_partial_contents_finish parameters.
443 2008-12-12 Owen Taylor <otaylor@redhat.com>
445 Disable array auto-detection for out-annotated parameters (#563934)
447 If we have a parameter annotated as (out), then having a ctype of
448 'char **' (or similar) doesn't necessarily indicate an array.
450 * giscanner/transformer.py: Skip array-detection logic for
451 (out)-annotated parameters.
452 * tests/scanner/annotation.h tests/scanner/annotation.c
453 tests/scanner/annotation-1.0-expected.gir
454 tests/scanner/annotation-1.0-expected.tgir: Add a test for
455 an (out) string parameter.
457 2008-12-12 Johan Dahlin <jdahlin@async.com.br>
459 * giscanner/dumper.py (DumpCompiler._link): Pass in
460 --tag=CC to libtool to avoid making libtool confused
461 when CC is different from gcc on some systems.
463 2008-12-10 Johan Bilien <jobi@via.ecp.fr>
465 Bug 563998 – Cache the GIBaseInfo for GTypes
467 * girepository/girepository.c (g_irepository_find_by_gtype):
468 add a cache of GType -> GIBaseInfo.
470 2008-12-09 Johan Bilien <jobi@via.ecp.fr>
472 Bug 562545 – Add function taking / returning GValue
474 * tests/everything/everything.[ch]: add a test of function taking and
475 returning "const GValue *"
477 2008-12-09 Johan Dahlin <johan@async.com.br>
479 * giscanner/cachestore.py (CacheStore.store): Use
480 shutil.move instead of os.rename, since it will
481 automatically fall back to copying+remove if the
482 src directory is on a different partition from
485 2008-12-08 Tristan Van Berkom <tristan.van.berkom@gmail.com>
487 Bug 563742 – introspection should record the introduced version of
488 symbols marked with the "Since:" tag
493 * giscanner/girwriter.py:
494 * giscanner/scannerlexer.l:
495 * giscanner/transformer.py:
496 * tests/scanner/annotation-1.0-expected.gir:
497 * tests/scanner/annotation-1.0-expected.tgir:
498 * tests/scanner/annotation.c (annotation_versioned):
499 * tests/scanner/annotation.h:
501 2008-12-08 Johan Dahlin <johan@async.com.br>
503 * giscanner/cachestore.py (_get_cachedir): Don't require
504 HOME to be set and if it set, don't require the
507 2008-12-08 Johan Dahlin <johan@async.com.br>
509 * giscanner/cachestore.py (CacheStore.store): Dump the cache
510 file to a temporary file and rename it the expected filename
511 only when it's completely written.
512 This should make the cache more roboust when run in parallel,
513 and hopefully avoid triggering bugs in Python.
515 2008-12-03 Christophe Fergeau <teuf@gnome.org>
517 Bug 562971 – g-ir-scanner failure on libgpod headers
519 * giscanner/scannerlexer.l: raise YY_BUF_SIZE to 65536 up from the
520 default 16384. Without it, the lexer was aborting with a cryptic
521 error message on source files containing really long comment
524 2008-12-01 Colin Walters <walters@verbum.org>
526 * girepository/gfield.c: Fix memory leak; unref type info we
527 created, not field info
529 2008-11-30 Johan Dahlin <jdahlin@async.com.br>
531 Bug 562289 – Race when removing invalid cache
533 * giscanner/cachestore.py:
534 ENOENT is mapped to a OSError, not IOError.
536 2008-11-27 Johan Dahlin <jdahlin@async.com.br>
538 * gir/glib-2.0.c: Add return value transfer annotation
539 for g_markup_escape_text.
541 2008-11-25 Colin Walters <walters@verbum.org>
543 * tools/g-ir-scanner: Add --libtool option which we expect Automake-using
545 * giscanner/dumper.py: Implement it.
546 * gir/Makefile.am, tests/**/Makefile.am: Use it.
548 2008-11-25 Colin Walters <walters@verbum.org>
550 * tests/scanner/Makefile.am: Remove hand-rolled generation of .tgir; easier
551 to just use a Makefile rule and dependencies. This corresponds with a change
552 made to gir-repository to fix srcdir != builddir issues.
554 2008-11-25 Johan Dahlin <jdahlin@async.com.br>
557 Post release version bump
560 2008-11-25 Johan Dahlin <jdahlin@async.com.br>
565 2008-11-25 Colin Walters <walters@verbum.org>
567 Bug 559705 – Missing association between static methods and classes
569 * docs/typelib-format.txt:
570 * girepository/ginfo.c (g_function_info_get_flags):
571 * girepository/girmodule.c (g_ir_module_build_typelib):
572 * girepository/girnode.c (g_ir_node_get_size),
573 (g_ir_node_build_typelib):
574 * girepository/girparser.c (start_function):
575 * girepository/gtypelib.c (g_typelib_check_sanity),
576 (validate_header), (validate_function_blob):
577 * girepository/gtypelib.h:
579 * giscanner/girwriter.py:
580 * giscanner/glibtransformer.py:
581 * tests/scanner/foo-1.0-expected.gir:
582 * tests/scanner/foo-1.0-expected.tgir:
583 * tests/scanner/foo.h:
585 2008-11-25 Johan Dahlin <jdahlin@async.com.br>
587 * giscanner/ast.py: Define socklen_t as an alias for int32.
589 2008-11-24 Johan Dahlin <jdahlin@async.com.br>
591 * girepository/gdump.c (dump_type): Remove a warning,
592 be less verbose on error on fundamental types.
594 2008-11-23 Johan Dahlin <jdahlin@async.com.br>
596 * giscanner/dumper.py: Add license headers,
597 refactor into a class, avoid some duplication and do some
598 extra pedantic checks.
600 2008-11-23 Johan Dahlin <jdahlin@async.com.br>
602 Make it compilable with -Werror on my system by adding
603 a couple of prototypes and including headers.
605 2008-11-23 Johan Dahlin <jdahlin@async.com.br>
607 Bug 562022 – gobject-introspection needs python headers
609 * configure.ac: fail without python headers present.
612 2008-11-21 Johan Dahlin <jdahlin@async.com.br>
614 Bug 561617 – Return value array annotations
616 * giscanner/transformer.py:
617 * tests/scanner/annotation.c (annotation_return_array):
618 * tests/scanner/annotation.h:
619 Add support for (array) for return value annotations as well.
621 2008-11-20 Johan Bilien <jobi@via.ecp.fr>
623 * tests/everything/everything.[ch]: add a test function which calls a
626 2008-11-19 Johan Dahlin <jdahlin@async.com.br>
628 * giscanner/cachestore.py:
629 Catch ValueError exceptions.
631 2008-11-18 Tommi Komulainen <tommi.komulainen@iki.fi>
633 * tests/scanner/Makefile.am (barapp_SOURCES): fix builddir != srcdir
635 2008-11-18 Andreas Rottmann <a.rottmann@gmx.at>
637 * girepository/girnode.c (g_ir_node_build_typelib): Use sizeof()
638 instead of hard-coding struct sizes.
640 2008-11-18 Owen Taylor <otaylor@redhat.com>
642 Bug 561296 - Add "storage type" to the typelib data for enums
644 In order to set and get enum and flag fields in structures, we need
645 to know the integral type that the enumeration is stored as. We are already
646 computing that at compile time in order to compute struct offsets, so the
647 easiest thing to do is to save that in the typelib.
649 * docs/typelib-format.txt girepository/girnode.[ch] girepository/giroffsets.c
650 girepository/gtypelib.h: Add 'storage_type' to the typelib format for EnumBlob
651 and compute and save it at compile time.
653 * girepository/girepository.h girepository/ginfo.c:
654 Add g_enum_info_get_storage_type().
656 * girepository/gfield.c: Implement reading and writing enum and flags fields
657 based on the storage type.
659 2008-11-18 Owen Taylor <otaylor@redhat.com>
661 Add enums to the Everything test module
663 * tests/everything/everything.[ch]: Add TestEnum and TestFlags to the Everything
664 test module and register them as GTypes.
666 https://bugzilla.gnome.org/show_bug.cgi?id=561296
668 2008-11-18 Johan Dahlin <jdahlin@async.com.br>
670 * giscanner/cachestore.py:
671 Catch BadPickleGet exceptions as well.
673 2008-11-17 Owen Taylor <otaylor@redhat.com>
675 * tests/everything/everything.c: Fix doc comment annotations
676 for test_struct_b_clone() to refer to the right function.
678 2008-11-17 Dan Winship <danw@gnome.org>
680 * giscanner/glibtransformer.py (GLibTransformer.__init__): fix
681 spelling of GHashTable. #561135
683 * tests/scanner/annotation.c (annotation_object_get_hash):
684 * tests/scanner/annotation-1.0-expected.gir:
685 * tests/scanner/annotation-1.0-expected.tgir: add a test of
686 GHashTable annotations
688 2008-11-17 Andreas Rottmann <a.rottmann@gmx.at>
690 * giscanner/ast.py: Change string array match type to be in terms
691 of canonicalized type.
692 * giscanner/transformer.py: Add canonicalize_ctype which gives us
693 a version of a c:type without aliases, so we can deep canonicalize
694 char** to utf8*. Update parse_ctype to use it.
695 * tests/*: Add gtk_init like int*/char*** arg functions for testing.
697 2008-11-16 Colin Walters <walters@verbum.org>
699 * girepository/girepository.c: Ensure we always call init_globals,
700 even if passed a non-default repository.
702 2008-11-16 Colin Walters <walters@verbum.org>
704 Bug 559706 - Interface prerequisites
706 * common.mk: Dep on libgirepository.la for scanner libs so that
707 we rebuild things even if just gdump.c changes.
708 * girepository/gdump.c: Dump prerequisites.
709 * giscanner/ast.py: Add prerequisite list.
710 * giscanner/girparser.py: Parse them from gdump.
711 * giscanner/girwriter.py: Write them.
712 * giscanner/glibtransformer.py: Resolve them.
715 2008-11-16 Owen Taylor <otaylor@redhat.com>
717 Bug 561087 - Respect is_pointer in serialize_type()
719 Add a '*' to the serialization for the cases where we set is_pointer
720 in the type blob we write out depending on node->is_pointer. Don't
721 add the '*' in the cases where is_pointer is set or not set in a
724 http://bugzilla.gnome.org/show_bug.cgi?id=561087
726 2008-11-16 Owen Taylor <otaylor@redhat.com>
728 Bug 560825 – Add size and alignment to typelib
730 Include the size and alignment of structures and unions in the typelib,
731 and add getter methods to retrieve them from GIStructInfo/GIUnionInfo.
733 * docs/typelib-format.txt girepository/gtypelib.h girepository/girnode.c
734 girepository/girmodule.c girepository/gtypelib.c: Add size and alignment
735 to StructBlob and UnionBlob.
737 * girepository/ginfo.c girepository/girepository.h:
738 Add g_[struct|union]_get[size|alignment]().
740 * test/offsets/gen-gitestoffsets: Test overall structure size and alignment.
742 2008-11-16 Owen Taylor <otaylor@redhat.com>
744 Bug 552371 – implement struct field get/set
746 * girepository/gfield.c girepository/girepository.h: Add
747 convenience functions g_field_info_set_field() and
748 g_field_info_get_field() to set and get fields based on the
749 offsets in GIFieldInfo.
751 2008-11-16 Andreas Rottmann <a.rottmann@gmx.at>
753 Bug 560241 - Out-arguments should not be marked as being pointers
756 * girepository/girparser.c: Improved logic for out arguments.
758 2008-11-16 Andreas Rottmann <a.rottmann@gmx.at>
760 Bug 559601 - Pointers in structs/unions unduly treated as arrays
762 * giscanner/transformer.py: Differentiate type creation logic
763 between parameters and struct components.
765 2008-11-15 Colin Walters <walters@verbum.org>
767 * giscanner/dumper.py: Check return code from pkg-config
770 2008-11-14 Johan Dahlin <jdahlin@async.com.br>
772 * tests/everything/everything.c (test_array_int_in),
773 (test_array_gtype_in):
774 * tests/everything/everything.h:
775 Rename the int/gtype array tests. Make the return value
776 useful, an aggregation of the array input values.
778 2008-11-14 Johan Dahlin <jdahlin@async.com.br>
780 * tests/everything/Makefile.am:
781 * tests/everything/everything.c:
782 * tests/everything/everything.h:
783 * tests/everything/gitesttypes.c:
784 * tests/everything/gitesttypes.h:
785 Rename gitesttypes.[ch] to everything.[ch]
787 2008-11-13 Andreas Rottmann <a.rottmann@gmx.at>
789 Bug 560708 – Don't treat arrays that have a length specified as
790 zero-terminated by default
792 * giscanner/transformer.py: Default to non zero terminated for
794 * tests/*: Update, add test for zero vs not.
796 2008-11-13 Andreas Rottmann <a.rottmann@gmx.at>
798 Bug 557788 - Return types for constructors in generated typelib bogus
800 * girepository/girnode.c: Namespace-qualify XREFs; not doing so is
801 obviously broken in the face of duplicate names in different
803 * tests/scanner/*expected.gir: Fix up.
805 2008-11-13 Owen Taylor <otaylor@redhat.com>
807 * girepository/girffi.c: Fix "Unexpected time for time_t"
810 2008-11-13 Colin Walters <walters@verbum.org>
812 Bug 558436 - avoid having scanner load app code
814 * giscanner/cgobject.py: Delete; we no longer load shared
816 * giscanner/dumper.py: Support for linking a library to
817 a stub binary for introspection.
818 * giscanner/glibtransformer.py: Rewrite to use gdump XML
819 from invocation of child binary.
820 * giscanner/transformer.py: Fix up to use fully qualified
821 name in parse tree. Make parse_ctype public so we can use
822 it inside glibtransformer.
823 * tests/scanner/barapp.c: New test, using --program arg
825 * tests/*: Update to use common.mk for invoking scanner.
826 * tools/g-ir-scanner: Add options --program, --program-arg,
828 * docs/g-ir-scanner.1: Update.
830 2008-11-13 Colin Walters <walters@verbum.org>
832 * configure.ac: Depend on Gio, we use it in gdump.c.
833 * girepository/gdump.c: Code to dump GType data to XML.
834 * girepository/girepository.c: Add option group for dumping.
835 * girepository/girepository.h: Define API for the above.
837 2008-11-13 Colin Walters <walters@verbum.org>
839 * common.mk: Add a file to include with Makefile fragments
840 useful for scanner invocation.
842 2008-11-13 Tommi Komulainen <tommi.komulainen@iki.fi>
844 * tests/everything/gitesttypes.c (test_filename_return): Return
845 strings in filename encoding.
847 2008-11-13 Owen Taylor <otaylor@redhat.com>
849 Bug 560253 – Add structure and boxed types to Everything test module
851 * tests/everything/gitesttypes.[ch]: Add examples of:
853 Plain old data structs
854 Plain old data structs with nested fields
856 Plain old data boxed with nested fields
857 More complicated boxed types with internal state
859 2008-11-12 Johan Dahlin <jdahlin@async.com.br>
861 * tests/everything/gitesttypes.c (test_gtype_in):
862 * tests/everything/gitesttypes.h:
863 Add a test of GType arrays, a la gtk_list_store_set_columns.
865 2008-11-12 Owen Taylor <otaylor@redhat.com>
867 Bug 560419 – Cache includes when parsing
869 Keep track of all modules parsed within a GIrParser, and when a
870 module is referenced a second time, use the existing parsed copy
871 instead of reparsing.
873 2008-11-12 Owen Taylor <otaylor@redhat.com>
875 Fix management of ParseContext.includes_modules (#560419)
877 * girepository/girparser.c: Fix some trivial bugs in managing the
878 list of include modules. (Add to module's list twice, not
879 initialized to NULL, not freed.)
881 2008-11-12 Owen Taylor <otaylor@redhat.com>
883 Keep aliases and disguised_structures local to each module (#560419)
885 * girepository/girmodule.[ch]: When parsing, keep keep a separate
886 hash tables of aliases and 'disguised' flags for each module, and
887 store that on the module.
889 After parsing an include merge the aliases/disguised flags to the
892 * girepository/girparser.c: Remove 'prefix_aliases' flag and
893 always prefix aliases/disguised structure types when parsing; this
894 simplifies the code considerably.
896 2008-11-12 Owen Taylor <otaylor@redhat.com>
898 Fix mismatches between .gir name and 'name' attribute (#560419)
900 * tests/boxed.gir tests/constant.gir tests/enum.gir tests/invoke/invoke.c
901 tests/invoke/testfns-1.0.gir tests/object.gir tests/struct.gir: Fix places
902 where the 'name' element of <namespace/> didn't match the filename of the
903 gir, an assumption that the compiler has always expected and now enforces.
905 2008-11-12 Owen Taylor <otaylor@redhat.com>
907 Only allow one <namespace/> element per <repository/> (#560419)
909 * girepository/girparser.c: The logic in girparser.c didn't work
910 very well if there were multiple <namespace/> nodes within a
911 single <repository/> (context->namespace was always the overall
912 filename and not the the name specified in the <namespace/>
913 element for one thing; this would cause aliases to be mis-prefixed
914 in include modules.) Also check that the "name" in the
915 <namespace/> node matches the filename.
917 2008-11-12 Owen Taylor <otaylor@redhat.com>
919 Add a GirParser object to hold the state of a compilation
921 * girepository/girparser.[ch] tools/compiler.c: Add a toplevel
922 GirParser object to hold state that is global across a
923 compilation. Currently just holds the include path, but will
924 eventually also keep a cached list of parsed modules.
926 2008-11-12 Tommi Komulainen <tommi.komulainen@iki.fi>
928 * girepository/girepository.c (find_namespace_latest): Fix
931 2008-11-12 Tommi Komulainen <tommi.komulainen@iki.fi>
933 * configure.ac: use 'introspection' component for bugs
935 2008-11-12 Johan Dahlin <jdahlin@async.com.br>
937 * tests/everything/gitesttypes.c (test_filename_return):
938 * tests/everything/gitesttypes.h:
939 Add a filename return test.
941 2008-11-12 Tommi Komulainen <tommi.komulainen@iki.fi>
943 * tests/offsets/Makefile.am (gitestoffsets.c): fix
944 gen-gitestoffsets invocation with builddir != srcdir
946 2008-11-12 Johan Dahlin <jdahlin@async.com.br>
948 * girepository/girepository.c:
949 Change the element type from utf8 to filename
950 * girepository/girnode.c (g_ir_node_build_typelib):
951 Special case filename equally to utf8 here.
953 2008-11-12 Johan Dahlin <jdahlin@async.com.br>
956 Remove unused variables, add a dependency of girepository.ch, so when
957 they change we rebuild the gir automatically.
959 2008-11-12 Johan Dahlin <jdahlin@async.com.br>
961 * girepository/girepository.c (g_irepository_get_search_path):
962 * girepository/girepository.h:
963 Add a g_irepository_get_search_path, so we can access the search
966 2008-11-12 Johan Bilien <jobi@via.ecp.fr>
968 Bug 560474 – g-ir-compiler crashes when compiling the glib gir
970 * girepository/girparser.c: avoid freeing an uninitialized pointer
972 2008-11-12 Johan Dahlin <jdahlin@async.com.br>
975 * giscanner/glibtransformer.py:
976 * tools/g-ir-scanner:
977 Add a GIRepository-2.0.gir. Change the libtool lookup slightly
978 so we can just pass in --library=foo/bar/baz.la and the scanner
979 does the right thing.
980 Don't warn for _get_type() functions if they don't take any
983 2008-11-11 Owen Taylor <otaylor@redhat.com>
985 Bug 560404 – Prefix types when resolving aliases in included modules
987 * girepository/girparser.c: When resolving aliases in an included
988 module, prefix types before looking them up.
990 2008-11-11 Owen Taylor <otaylor@redhat.com>
992 Compute field offsets and overall size for object structures
994 Bug 560326 – Fails to build Gtk-2.0.typelib with "Unexpected non-pointer
995 field of type object in structure"
997 Do basic computation of field offsets for objects and interfaces;
998 this doesn't attempt to address all of the "mess" for virtual
999 functions described in Bug 560281.
1001 2008-11-11 Tommi Komulainen <tommi.komulainen@iki.fi>
1003 Bug 560308 – g-ir-compiler goes in infinite loop on Gdk-2.0.gir
1005 Based on patch by Johan Bilien.
1007 * giscanner/transformer.py (_create_member, _create_parameter):
1008 Resolve types here as well.
1009 (_resolve_type_name_1): Try resolving using 'ctype' first since
1010 it's least ambiguous. Fixes struct member type resolution with
1011 similarly named types, e.g. Gdk.PangoRendererClass and
1013 * tests/scanner/foo*: Add test.
1015 2008-11-11 Owen Taylor <otaylor@redhat.com>
1017 * girepository/girparser.c: Search provided include dirs before
1018 the default directories.
1020 2008-11-11 Owen Taylor <otaylor@redhat.com>
1022 * girepository/giroffsets.c: Include fully-qualified names in
1025 2008-11-11 Owen Taylor <otaylor@redhat.com>
1027 * girepository/giroffsets.c: Fail gracefully with an informative
1028 error message when recursion is encountered when computing a
1031 2008-11-11 Owen Taylor <otaylor@redhat.com>
1033 * girepository/girparser.c: Remove an unused variable.
1035 2008-11-10 Owen Taylor <otaylor@redhat.com>
1037 Add tests for field offset computations
1039 * tests/offsets/offsets.h: Header file with structure definitions to test
1041 * tests/offsets/gen-gitestoffsets: Generate a C program that computes
1042 field offsets for the structures in offsets.h two ways: using
1043 the information from a generated typelib, and as computed by the
1046 We diff these two versions to test that everything is OK.
1048 2008-11-10 Owen Taylor <otaylor@redhat.com>
1050 Remove field offsets from g-ir-generate output and test inputs
1052 Field offsets are a) architecture dependent so they shouldn't be part
1053 of the architecture-independent gir format which is installed in
1054 datadir. b) Are architecture-dependent so they shouldn't be in test
1057 * girepository/girparser.c: Don't parse offset for fields
1058 * tools/generate.c: Don't parse offset for fields
1059 * tests/*.gir test/scanner/*.tgir: Remove offsets
1061 (Virtual function and discriminator offsets are not removed, as they
1062 aren't fully hooked up to the field-offset computation machinery yet.)
1064 2008-11-10 Owen Taylor <otaylor@redhat.com>
1066 Bug 560252 - Compute field offsets before writing typelib
1068 * girepository/girnode.h: Store the total size and alignment for
1069 GIrNodeStruct/Boxed/Union.
1071 * girepository/giroffset.c: New file implementing computation of
1072 structure field offsets.
1074 * girepository/girnode.c: Compute structure field offsets before
1075 writing types into the typelib.
1077 * docs/typelib-format.txt: Document that a field offset of 0xFFFF
1078 means "unknown". Also fix description of the discriminator_offset
1081 2008-11-10 Owen Taylor <otaylor@redhat.com>
1083 Bug 560250 - Fully parse included modules
1085 For some things, like computing structure offsets to put into the typelib
1086 we need more than just the aliases from included modules. Do a completel
1087 parse of included modules and store in module->included_modules.
1089 Also add g_ir_find_node() to find node information from within the
1090 active set of modules and their includes.
1092 2008-11-10 Owen Taylor <otaylor@redhat.com>
1094 Split g_ir_ffi_get_ffi_type() out from ginvoke.c
1096 Extract a function to convert GITypeTag to ffi_type from the internals
1097 of ginvoke.c. This will be useful in figure out structure alignment.
1099 Also fix handling of gsize and time_t to be portable. (Add a check
1100 to configure.ac to figure out the width of time_t.)
1102 2008-11-10 Owen Taylor <otaylor@redhat.com>
1104 Bug 560248 – "disguised structures"
1106 Certain types like GIConv and GdkAtom are pointers internally but don't
1107 look like pointers when referenced. They have the form.
1109 typedef struct _X *X;
1111 Parse these as structures/records but mark them in the gir with a 'disguised'
1112 attribute so that we know that they need special handling.
1114 In the typelib treat them like any other structure.
1116 2008-11-09 Jürg Billeter <j@bitron.ch>
1119 * giscanner/girwriter.py:
1121 Write throws attribute for virtual functions, fixes bug 559703
1123 2008-11-07 Johan Dahlin <jdahlin@async.com.br>
1125 * giscanner/libtoolimporter.py (LibtoolImporter.find_module): Clear
1126 up some confusion about the second argument to find_module, it's
1127 actually the packages __path__ attribute which we can safely ignore
1129 (LibtoolImporter.load_module): Set module.__loader__ as per PEP 302.
1131 2008-11-07 Owen Taylor <otaylor@redhat.com>
1133 Bug 559737 – Deal with continuations in macros
1135 * giscanner/giscannerlexer.l: Treat continuation lines the same
1136 as regular newlines. This makes the scanner not complain about
1137 #define foo(x) \ <stuff> inside a C file. There's no attempt
1138 however to handle parsing macro definitions split across lines.
1140 2008-11-07 Johan Dahlin <jdahlin@async.com.br>
1142 * giscanner/cachestore.py:
1143 Handle broken cache entries, write only filesystems and
1144 running out of diskspace.
1146 2008-11-07 Owen Taylor <otaylor@redhat.com>
1148 * giscanner/giscannermodule.c (pygi_source_scanner_lex_filename):
1149 Set current_filename before lexing the file so error messages
1150 are reported in the right file.
1152 2008-11-06 Colin Walters <walters@verbum.org>
1154 * tests/everything/*: Add some tests for strv.
1156 2008-11-05 Colin Walters <walters@verbum.org>
1158 * girepository/ginvoke.c (g_function_info_invoke): Don't use
1159 nested scope local variable for error which may go away after
1160 conditional is complete.
1162 2008-11-05 Colin Walters <walters@verbum.org>
1164 * giscanner/scannerlexer.l: Avoid static 256 char buf which we
1165 manipulate hackily; just use GString. This avoids an
1166 uninitialized memory read pointed out by Havoc.
1168 2008-11-04 Johan Dahlin <jdahlin@async.com.br>
1170 * giscanner/__init__.py:
1172 * giscanner/cachestore.py:
1173 * giscanner/cgobject.py:
1174 * giscanner/girparser.py:
1175 * giscanner/girwriter.py:
1176 * giscanner/giscannermodule.c:
1177 * giscanner/glibast.py:
1178 * giscanner/glibtransformer.py:
1179 * giscanner/libtoolimporter.py:
1180 * giscanner/minixpath.py:
1181 * giscanner/odict.py:
1182 * giscanner/sourcescanner.c:
1183 * giscanner/sourcescanner.h:
1184 * giscanner/sourcescanner.py:
1185 * giscanner/transformer.py:
1186 * giscanner/utils.py:
1187 * giscanner/xmlwriter.py:
1189 Relicense the giscanner library under LGPLv2+.
1190 This has been approved by all contributors.
1192 2008-11-01 Owen Taylor <otaylor@redhat.com>
1194 Bug 558848 giparser.py: shared library should be optional
1196 When parsing a .gir, allow the shared-library attribute
1197 of <namespace/> to be missing: this corresponds to the handling
1198 in libgirepository and elsewhere.
1200 2008-11-01 Tommi Komulainen <tommi.komulainen@iki.fi>
1202 Bug 557898 – Fails to build on OSX 10.4
1204 * configure.ac: Check for $shrext_cmds that should be implicitly
1205 available if you're using libtool >= 2.0. If undefined, call
1206 libtool --config explicitly to get its value.
1207 * girepository/gtypelib.c: Remove special case for (non-)Darwin
1208 systems as unneeded.
1210 2008-10-31 Colin Walters <walters@verbum.org>
1212 * COPYING, COPYING.lib, COPYING.tools: Clarify licensing status.
1214 2008-10-31 Johan Dahlin <jdahlin@async.com.br>
1216 * configure.ac: Post release version bump
1219 2008-10-31 Johan Dahlin <jdahlin@async.com.br>
1223 * docs/release-checklist.txt:
1226 2008-10-31 Johan Dahlin <jdahlin@async.com.br>
1228 * Makefile.am: add an upload-release target
1229 * docs/release-checklist.txt:
1230 Release process documentation
1232 2008-10-31 Colin Walters <walters@verbum.org>
1234 Bug 558109 – _g_typelib_init fails to find shared libraries
1236 * transformer/glibtransformer.py: Use ctypes' find_library
1237 on passed libraries and write that for the shared-library
1238 entry. We want to avoid depending on -devel packages.
1240 2008-10-31 Johan Dahlin <jdahlin@async.com.br>
1242 * docs/g-ir-scanner.1:
1243 Document the renaming options.
1245 2008-10-31 Tommi Komulainen <tommi.komulainen@iki.fi>
1247 * giscanner/Makefile.am:
1248 * tests/invoke/Makefile.am:
1249 * tests/repository/Makefile.am: List in-tree libraries first in
1250 LDADD / LIBADD. If installed library is listed first, the
1251 resulting binary will prefer installed version to one in .libs,
1252 possibly making 'make check' behave strangely.
1254 2008-10-30 Tommi Komulainen <tommi.komulainen@iki.fi>
1256 * giscanner/ast.py: map 'id' (ObjC) to 'any' type to stop
1257 gir-repository from choking with gdk/quartz
1259 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
1261 * giscanner/giscannermodule.c (calc_attrs_length),
1262 (pygi_collect_attributes):
1263 * giscanner/xmlwriter.py:
1264 Write a C version of the xml namespace formatter.
1265 Saves 15% of the time it takes to create a gtk gir.
1267 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
1269 * giscanner/xmlwriter.py: Abstract attribute formatting
1270 to a function external to the XMLWriter class.
1272 * giscanner/scannerlexer.l:
1273 Parse and discard __typeof and __attribute.
1275 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
1277 * giscanner/girparser.py:
1278 Remove arguments from the constructor, move them to
1279 separate accessors. Add a new parse_tree method
1280 which takes an element tree instance.
1281 * tools/g-ir-scanner:
1282 Update callsite for this
1284 * giscanner/Makefile.am:
1285 * giscanner/cachestore.py:
1286 * giscanner/transformer.py:
1287 Cache the include parsing. Saves ~25% time when
1288 creating vte (which includes everything up to gtk+).
1290 2008-10-30 Colin Walters <walters@verbum.org>
1292 * giscanner/transformer.py: Don't reparse includes
1293 we've already processed.
1295 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
1297 * giscanner/girparser.py:
1298 * giscanner/transformer.py:
1299 Avoid parsing parameters, types etc when parsing
1300 includes. Should speed up include parsing a bit.
1302 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
1304 * giscanner/girparser.py:
1305 Avoid big if/else and use a dispatch table like
1308 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
1310 * giscanner/transformer.py:
1311 Clean up include parsing and registration.
1313 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
1315 * giscanner/transformer.py:
1318 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
1320 Bug 558383 – builddir != srcdir build fails if giscanner python module not already installed
1323 construct PYTHONPATH just once
1325 * tests/everything/Makefile.am:
1326 * tests/scanner/Makefile.am:
1327 add $(top_srcdir) to PYTHONPATH to
1328 handle builddir != srcdir
1330 * giscanner/libtoolimporter.py:
1331 * giscanner/sourcescanner.py:
1332 Make the libtoolimporter work when distchecking too.
1334 Mostly based on patch by Tommi Komulainen
1336 2008-10-29 Owen Taylor <otaylor@redhat.com>
1338 * giscanner/glibtransformer.py: If a filename of an existing
1339 file is passed to --library, hunt for it directly, rather than
1340 searching for a corresponding library.
1342 2008-10-29 Johan Dahlin <jdahlin@async.com.br>
1344 * giscanner/libtoolimporter.py:
1345 * giscanner/sourcescanner.py:
1346 Clean up the libtool importer a bit. Add a context so we
1347 can use it through a with statement.
1348 Don't just look in the current directory, look in the whole
1351 2008-10-29 Tommi Komulainen <tommi.komulainen@iki.fi>
1353 Bug 558065 – gitesttypes should be installed
1356 * tests/Makefile.am:
1357 * tests/types/Makefile.am -> tests/everything/Makefile.am
1358 * tests/types/gitesttypes.c -> tests/everything/gitesttypes.c
1359 * tests/types/gitesttypes.h -> tests/everything/gitesttypes.h
1360 move tests/types to tests/everything
1362 * tests/everything/Makefile.am: build normal shared library
1363 libgirepository-everything.so.1.0.0 and corresponding typelib
1364 Everything-1.0.typelib
1366 * tests/everything/Makefile.am: explicitly link libtool
1367 versioning with typelib versioning with variables
1369 2008-10-28 Johan Bilien <jobi@via.ecp.fr>
1371 * tools/g-ir-scanner: add LD_LIBRARY_PATH to LPATH before calling ld.
1373 2008-10-27 Johan Bilien <jobi@via.ecp.fr>
1375 * gio/gio-2.0.c: add allow-none annotations, based on the pygobject
1378 2008-10-27 Johan Bilien <jobi@via.ecp.fr>
1380 Bug 558068 – when invoking a method, offset the in arguments by one,
1383 * tests/invoke/invoke.c, tests/invoke/testfns.c,
1384 tests/invoke/testfns-1.0.gir: Add testing of method and constructor.
1385 * girepository/ginvoke.c: do not offset the index of given out
1386 arguments by one for methods, "this" is provided as in argument only.
1388 2008-10-27 Johan Bilien <jobi@via.ecp.fr>
1390 * gir/gio-2.0.c: add annotation for g_file_delete
1392 2008-10-27 Tommi Komulainen <tommi.komulainen@iki.fi>
1394 Bug 558062 – provide and use paths in the .pc file
1396 * gobject-introspection-1.0.pc.in: provide typelibdir variable
1397 for where .typelibs should be installed (callers shouldn't need
1398 to construct paths from bits and pieces)
1400 2008-10-25 Andreas Rottmann <a.rottmann@gmx.at>
1402 Bug 557791 – g_irepository_require() could return a GTypelib *
1404 * girepository/girepository.c: Return GTypelib; this is useful
1405 for low level manipulation.
1407 2008-10-25 Colin Walters <walters@verbum.org>
1409 Bug 557788 – Return types for constructors in generated typelib bogus
1411 * giscanner/glibtransformer.py: Don't resolve ctors incrementally,
1412 rely on end pass resolution.
1414 2008-10-25 Andreas Rottmann <a.rottmann@gmx.at>
1416 Bug 557786 - support fixed size arrays
1418 * girepository/ginfo.c: Add g_type_info_get_array_fixed_size.
1419 * giscanner/scannerparser.y: Retain fixed array size.
1420 * giscanner/ast.py: Add to note.
1421 * giscanner/girwriter.py: Write to gir.
1422 * girepository/girnode.c: Write it to typelib.
1423 * tools/generate.c: Generate.
1424 * tests/*: Add tests.
1426 2008-10-25 Colin Walters <walters@verbum.org>
1428 Bug 557076 - move typelibs to $libdir
1430 * configure.ac: Steal some configury bits from dbus to expand
1432 * gir/Makefile.am: Move to libdir.
1433 * girepository/girepository.c: Stop searching XDG_DATA_DIRS;
1434 instead just look at one hardcoded path in libdir.
1435 * acinclude.m4: Bits from dbus.
1437 2008-10-24 Johan Dahlin <johan@gnome.org>
1439 * girepository/girnode.c (g_ir_node_check_unhandled_members):
1440 Be quiet, do not warn about unhandled members.
1442 2008-10-24 Johan Dahlin <johan@gnome.org>
1444 * girepository/gtypelib.c:
1445 Only use SHLIB_SUFFIX on darwin, otherwise use
1446 G_MODULE_SUFFIX, we cannot get shext_cmds from libtool 2.2.
1448 2008-10-24 Lucas Rocha <lucasr@gnome.org>
1450 Bug 557623 - Constructors shouldn't be flagged as methods.
1452 * girepository/ginfo.c (g_function_info_get_flags): ditto.
1454 2008-10-24 Johan Dahlin <johan@gnome.org>
1456 * giscanner/scannerparser.y:
1457 Check against division by zero for the modula operator.
1458 This fixes header parsing of OSX system headers included
1461 2008-10-24 Johan Dahlin <johan@gnome.org>
1465 Add a CONTRIBUTORS file and dist it.
1467 2008-10-23 Tommi Komulainen <tommi.komulainen@iki.fi>
1469 Bug 556739 – transfer-ownership attribute should be mandatory in .gir
1471 * girepository/girparser.c (parse_param_transfer):
1472 * giscanner/transformer.py (_create_parameter, _create_return):
1473 * giscanner/girwriter.py (_write_return, _write_parameter):
1474 * tools/generate.c (write_callable_info): always write and
1475 require "transfer-ownership" for return-values and parameters
1478 * tests/invoke/testfns-1.0.gir:
1480 * tests/scanner/DrawableAdditions.xml:
1481 * tests/scanner/GtkFrob-1.0-expected.tgir:
1482 * tests/scanner/annotation-1.0-expected.tgir:
1483 * tests/scanner/drawable-1.0-expected.tgir:
1484 * tests/scanner/drawable-injected-1.0-expected.gir:
1485 * tests/scanner/drawable-injected-1.0-expected.tgir:
1486 * tests/scanner/foo-1.0-expected.tgir: Updated
1488 2008-10-23 Tommi Komulainen <tommi.komulainen@iki.fi>
1490 * giscanner/cgobject.py: build fundamental types same way as glib
1492 * giscanner/glibtransformer.py (_type_from_gtype): record GType
1493 when constructing the Type from it
1495 * giscanner/glibtransformer.py (_adjust_transfer): Check whether
1496 the parameter is a GObject from its GType, if available.
1498 * giscanner/glibtransformer.py (_adjust_transfer):
1499 * tests/scanner/foo-1.0-expected.gir:
1500 * tests/scanner/foo-1.0-expected.tgir: deduce
1501 transfer-ownership from GTypes
1503 2008-10-23 Tommi Komulainen <tommi.komulainen@iki.fi>
1505 * giscanner/transformer.py (_create_parameter):
1506 * tests/scanner/foo-1.0-expected.gir: make varargs
1507 transfer-ownership="none"
1509 2008-10-23 Colin Walters <walters@verbum.org>
1511 Bug 556739 - transfer ownership
1513 * giscanner/ast.py: Refactor Parameter/Return to share
1514 common attributes. Add transfer_inferred attribute
1515 which says whether or not we made a guess.
1516 * giscanner/transformer.py: Add much more extensive
1517 heuristics around parameter and return transfer.
1518 * giscanner/glibtransformer.py: Adjust to inspect
1522 2008-10-22 Tommi Komulainen <tommi.komulainen@iki.fi>
1524 Bug 557377 – Add test to ensure annotations survive the roundtrip via typelib
1526 * tests/scanner/Makefile.am:
1527 * tests/scanner/annotation-1.0-expected.tgir:
1528 * tests/scanner/drawable-1.0-expected.tgir:
1529 * tests/scanner/drawable-injected-1.0-expected.tgir:
1530 * tests/scanner/foo-1.0-expected.tgir:
1531 * tests/scanner/GtkFrob-1.0-expected.tgir:
1532 * tests/scanner/utility-1.0-expected.tgir: Add test to ensure
1533 annotations survive the roundtrip via typelib
1535 The expectations are as currently produced by g-ir-generate,
1536 comparison with the .gir files shows there are differences.
1538 2008-10-23 Johan Bilien <jobi@via.ecp.fr>
1540 Bug 557468 – Support for GI_TYPELIB_PATH
1542 * girepository/girepository.c: if the GI_TYPELIB_PATH is set, add the
1543 provided paths to the global search path.
1545 2008-10-22 Tommi Komulainen <tommi.komulainen@iki.fi>
1547 Bug 557379 – g-ir-generate not writing the 'abstract' attribute
1549 * tests/scanner/drawable-1.0-expected.tgir:
1550 * tests/scanner/drawable-injected-1.0-expected.tgir:
1551 * tests/scanner/foo-1.0-expected.tgir:
1552 * tools/generate.c (write_object_info): write 'abstract'
1553 attribute for classes
1555 2008-10-22 Lucas Rocha <lucasr@gnome.org>
1557 * girepository/girmodule.c, girepository/gtypelib.c,
1558 girepository/girparser.[ch]: fix some build warnings.
1560 2008-10-22 Tommi Komulainen <tommi.komulainen@iki.fi>
1562 Bug 557405 – Use 'allow-none' consistently
1564 * docs/typelib-format.txt:
1565 * girepository/ginfo.c (g_arg_info_may_be_null):
1566 * girepository/girnode.c (g_ir_node_build_typelib):
1567 * girepository/girnode.h (struct _GIrNodeParam):
1568 * girepository/girparser.c (start_parameter):
1569 * girepository/girwriter.c (function_generate):
1570 * girepository/gtypelib.h (ArgBlob):
1572 * tests/function.gir:
1573 * tools/generate.c (write_callable_info): Use 'allow-none'
1574 consistently throughout
1576 2008-10-22 Tommi Komulainen <tommi.komulainen@iki.fi>
1578 Bug 557092 – Callback annotations not used
1580 * giscanner/transformer.py (_create_callback): use annotations
1582 * tests/scanner/annotation.h
1583 * tests/scanner/annotation-1.0-expected.gir: add tests
1585 2008-10-21 Colin Walters <walters@verbum.org>
1587 * giscanner/scannerlexer.l: Don't require trailing whitespace after
1588 uncommented parameters.
1591 2008-10-21 Colin Walters <walters@verbum.org>
1593 * girepository/girepository.c: Ensure that when doing an unversioned
1594 require, we prefer items earlier in the search path to later ones.
1596 2008-10-21 Owen Taylor <otaylor@redhat.com>
1598 * giscanner/transformer.py: For string parameters allow transfer annotation
1599 to override the standard automatic guessing based on 'const'.
1601 2008-10-21 Johan Bilien <jobi@via.ecp.fr>
1603 Bug 557241 – "throws" flag for functions
1605 * tests/scanner/drawable-1.0-expected.gir,
1606 tests/scanner/drawable-injected-1.0-expected.gir,
1607 tests/scanner/drawable.[ch]: add simple test for throwing
1608 function (has GError ** as last argument)
1610 * giscanner/ast.py: add a 'throws' flag to Function
1611 * giscanner/glibtransformer.py: if a function's last paramerter is
1612 a GError, set the 'throws' flag and remove that parameter
1613 * giscanner/girwriter.py: write out the 'throws' attribute
1614 * giscanner/girparser.py: support parsing the 'throws' attribute
1616 * tests/repository/gitestthrows.c: add a simple test to check the
1617 throws flag in a typelib and invoke the function
1619 * girepository/ginfo.c, girepository/girnode.[ch],
1620 girepository/girnode.h, girepository/girparser.c,
1621 girepository/girepository.h: Add and parse the GI_FUNCTION_THROWS flag
1623 * girepository/ginvoke.c: if a function throws, add a GError as last
1624 arguments, and propagate the error to the invoker.
1626 2008-10-21 Tommi Komulainen <tommi.komulainen@iki.fi>
1628 * giscanner/transformer.py (_create_parameters): Warn if we see
1629 annotations for unknown parameters. If .h and .c files name
1630 parameters differently, the annotations may be lost.
1632 2008-10-21 Johan Dahlin <johan@gnome.org>
1634 Bug 556358 - don't use libtool internals
1636 * giscanner/Makefile.am:
1637 * giscanner/libtoolimporter.py:
1638 * giscanner/sourcescanner.py:
1639 * giscanner/utils.py:
1640 Add a python meta importer and remove a libtool symlink hack.
1642 2008-10-20 Andreas Rottmann <a.rottmann@gmx.at>
1644 * tests/scanner/Makefile.am (%.typelib): Set PYTHONPATH
1645 and --add-include-path appropriately when invoking the scanner.
1646 * tests/types/Makefile.am (%typelib): Likewise.
1648 2008-10-20 Colin Walters <walters@verbum.org>
1650 Bug 556777 - validate properties
1652 * giscanner/transformer.py: Add option to throw on unknown types.
1653 * giscanner/glibtransformer.py: Use it on properties.
1654 * tests/*: Add a test.
1656 2008-10-20 Colin Walters <walters@verbum.org>
1658 * giscanner/glibast.py: Also register g variants of
1659 default_array_types. This is not beautiful, but
1660 good alternatives aren't easy to come by.
1661 This fixes gchar ** parsing.
1663 2008-10-20 Colin Walters <walters@verbum.org>
1665 * docs/typelib-format.txt, girepository/gtypelib.h:
1666 Take a bit from ObjectInfo to represent abstract flag.
1667 * giscanner/cgobject.py: Expose g_type_get_flags.
1668 * girepository/girepository.h: Add accessor.
1669 * girepository/ginfo.c: Implement it.
1670 * giscanner/ast.py: Add is_abstract flag to generic
1672 * giscanner/glibast.py: Use it.
1673 * giscanner/girwriter.py: Write it.
1674 * girepository/girparser.c: Parse it.
1677 2008-10-20 Tommi Komulainen <tommi.komulainen@iki.fi>
1679 * giscanner/girparser.py (_parse_function): don't lose
1680 'transfer-ownership' attributes when injecting, check for the
1683 2008-10-19 Johan Dahlin <johan@gnome.org>
1685 * giscanner/scannerlexer.l: Parse and ignore __asm.
1687 2008-10-19 Colin Walters <walters@verbum.org>
1689 * giscanner/girparser.py: Parse array length= to ensure
1690 it doesn't get lost from --inject.
1692 2008-10-17 Colin Walters <walters@verbum.org>
1694 Bug 556795 - char ** regression
1696 * giscanner/transformer.py: Fix parsing of ctypes, add some
1697 comments about what's going on.
1698 * tests/*: Add a test for char **.
1700 2008-10-17 Colin Walters <walters@verbum.org>
1702 Bug 556783 - change namespace handling to be more consistent
1704 * giscanner/transformer.py: Eliminate usage of
1705 strip_namespace_object. We now treat --namespace as the default
1706 --strip-prefix; however, if --strip-prefix is specified it
1707 overrides --namespace. This applies to everything except function
1708 names, where we do also strip the namespace.
1709 * giscanner/glibtransformer.py: Remove usage of
1710 strip_namespace_object.
1712 * tests/*: Add skeletal GtkFrob-1.0 test which has different
1713 --namespace and --strip-prefix.
1715 2008-10-17 Tommi Komulainen <tommi.komulainen@iki.fi>
1717 Bug 556732 – generate gir files consistently
1719 * girepository/girparser.c (start_parameter):
1721 * tests/invoke/testfns-1.0.gir:
1722 * tools/generate.c (write_callable_info): write
1723 'transfer-ownership' attribute consistently with both
1724 return-value and parameter elements
1726 2008-10-17 Tommi Komulainen <tommi.komulainen@iki.fi>
1728 Bug 556732 – generate gir files consistently
1730 * tools/generate.c (write_callable_info): write 'direction'
1731 attribute only if other than 'in' to be consistent with
1734 * tests/object.gir: remove direction="in" which is the default
1736 2008-10-17 Tommi Komulainen <tommi.komulainen@iki.fi>
1738 Bug 556732 – generate gir files consistently
1740 * giscanner/ast.py (Field): add readable and writable properties
1741 * giscanner/girparser.py (_parse_field): copy 'readable' and
1742 'writable' attributes
1743 * giscanner/transformer.py (_create_member): create fields as
1745 * giscanner/glibtransformer.py (_introspect_object,
1746 _pair_class_struct): make object instance and class fields
1748 * giscanner/girwriter.py (_write_field):
1749 * tools/generate.c (write_field_info): write field 'readable'
1750 and 'writable' attributes only if non-default (read-only)
1751 * girepository/girparser.c (start_field): in the absence of
1752 attributes assume fields are read-only
1754 * tests/struct.gir: remove redundant readable="1" from fields
1755 * tests/scanner/foo-1.0-expected.gir:
1756 * tests/scanner/utility-1.0-expected.gir: add writable="1" to
1757 all record and union fields
1759 2008-10-17 Tommi Komulainen <tommi.komulainen@iki.fi>
1761 Bug 556732 – generate gir files consistently
1763 * giscanner/girwriter.py (_write_property): write properties
1764 'construct' attribute if set
1765 * tools/generate.c (write_property_info): write properties
1766 'readable' and 'writable' attributes only if non-default
1767 * tests/object.gir: add writable="0"
1768 * tests/scanner/foo-1.0-expected.gir: add construct="1"
1770 2008-10-17 Johan Bilien <jobi@via.ecp.fr>
1772 * gir/glib-2.0.c: added annotations
1774 2008-10-16 Johan Bilien <jobi@via.ecp.fr>
1776 * giscanner/ast.py: Also assume direction=out for size_t*, ssize_t*
1779 2008-10-16 Johan Bilien <jobi@via.ecp.fr>
1781 Bug 556610 – giscanner/girparser.py drops parameter options
1783 * tests/scanner/drawable-injected-1.0-expected.gir,
1784 tests/scanner/DrawableAdditions.xml: added simple test for injection.
1785 * giscanner/ast.py: allow Parameter to take options in the constructor
1786 * giscanner/girparser.py: parse parameter options (transfer,
1787 direction, allow-none)
1789 2008-10-16 Colin Walters <walters@verbum.org>
1791 Bug 556185 - segfault on g_callable_info_get_return_type
1793 Initial patch from John Ehresman.
1795 * tests/repository/*: Add a test using
1796 g_callable_info_get_return_type. Instead of casting a
1797 GITypeInfo directly to a GIRegisteredTypeInfo, we need
1798 to call g_type_info_get_interface.
1800 2008-10-16 Colin Walters <walters@verbum.org>
1802 Bug 556579 - union and struct name misresolved
1804 * giscanner/transformer.py: The calls to _resolve_type_name
1805 for struct/union names was a legacy holdover from when type
1806 resolution had multiple phases. Now it's actively harmful
1807 since we might pull in an identical name from another
1811 2008-10-16 Colin Walters <walters@verbum.org>
1813 Bug 556432 - transfer annotations and defaults
1815 * giscanner/transformer.py: Canonicalize type
1816 after removing *, not before. This ensures that
1817 guchar* is transformed to 'uint8'.
1818 Add some comments here.
1819 * giscanner/glibtransformer.py: Add _adjust_transfer
1820 phase for tweaking GObject transfers.
1823 2008-10-16 Tommi Komulainen <tommi.komulainen@iki.fi>
1825 * configure.ac: enable bunch of gcc warning CFLAGS
1827 2008-10-16 Tommi Komulainen <tommi.komulainen@iki.fi>
1829 Bug 556543 – reduce compiler warnings
1831 * girepository/ginfo.c:
1832 * girepository/girepository.c (register_internal,
1833 count_interfaces, find_interface, find_namespace_version,
1834 parse_version, g_irepository_require):
1835 * girepository/girmodule.c (g_ir_module_build_typelib):
1836 * girepository/girnode.c (init_stats, dump_stats,
1837 _g_irnode_init_stats, _g_irnode_dump_stats,
1838 g_ir_node_can_have_member):
1839 * girepository/girparser.c (firstpass_end_element_handler,
1840 locate_gir, parse_basic, parse_type_internal, resolve_aliases,
1841 start_alias, start_type, end_type_top, parse_include, cleanup,
1843 * girepository/gtypelib.c (validate_function_blob, validate_enum_blob):
1844 * giscanner/giscannermodule.c (directive_get_options,
1845 type_get_child_list):
1846 * giscanner/scannerlexer.l (parse_gtkdoc):
1847 * giscanner/scannerparser.y (ctype_free):
1848 * giscanner/sourcescanner.c:
1849 * giscanner/sourcescanner.h (gi_source_scanner_parse_macros):
1850 * tests/types/gitesttypes.c:
1851 * tools/compiler.c (main):
1852 * tools/generate.c (write_repository): Remove unused variables
1853 and code, add missing includes, declarations and case
1856 2008-10-16 Tommi Komulainen <tommi.komulainen@iki.fi>
1858 Bug 556541 – access union members through UnionBlob rather than
1861 * girepository/ginfo.c (g_union_info_find_method): access union
1862 members through UnionBlob rather than StructBlob
1864 2008-10-15 Colin Walters <walters@verbum.org>
1866 Bug 556331 - clean up includes handling
1868 * tools/g-ir-scanner: Rework command line arguments; now we take
1869 --add-include-path and --include separately.
1870 * giscanner/girwriter.py: Separate name= and version= in include
1872 * giscanner/ast.py: Add Include type.
1873 * giscanner/transformer.py: Cleanups to register_include now that
1874 we don't need to handle mixed filenames and relative arguments.
1875 * girepository/girparser.c: Parse name and version separately;
1876 this fixes a bug as a side effect where we weren't resolving
1877 through aliases for basic types.
1878 * girepository/girepository.c: Fix format string args.
1879 * gir/Makefile.am: Update.
1882 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1884 Bug 556434 – unhandled interface/object/... member types
1886 * girepository/girnode.c (g_ir_node_check_unhandled_members,
1887 g_ir_node_build_typelib): Check all
1888 interface/object/boxed/struct/union members are processed and
1889 abort if they are not. (Mostly callbacks in structs, but also
1890 fields in interfaces.)
1892 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1894 * a/girepository/girnode.c (g_ir_node_build_members,
1895 g_ir_node_build_typelib): refactor common code for processing
1896 members to a function
1898 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1900 * gir/Makefile.am (check-local): check that typelib -> gir -> typelib
1901 transformation is lossless (it's not)
1903 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1905 * tests/Makefile.am: fix tests to compare xml to xml instead of
1906 typelib to xml, and stop on error
1908 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1910 * tools/generate.c (write_type_name, write_type_info,
1911 write_type_info, write_object_info, write_object_info,
1912 write_interface_info, write_error_domain_info): reduce code
1915 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1917 Bug 556174 – parse types for lists etc.
1919 * girepository/girparser.c (end_type_recurse):
1921 * tools/generate.c (write_type_info, write_field_info,
1922 write_callable_info, write_callable_info, write_constant_info,
1923 write_property_info): use nested <type>s for lists and hashes
1925 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1928 * tests/object.gir: remove trailing whitespace from inside
1929 elements to match g-ir-generate output
1931 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1933 * tools/generate.c (xml_printf): quote printf arguments so that
1934 we don't generate invalid XML by writing unescaped double quotes
1935 and such in attributes
1937 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1939 * tools/generate.c (write_field_info, write_callable_info,
1940 write_function_info, write_callback_info, write_struct_info,
1941 write_constant_value, write_signal_info, write_vfunc_info,
1942 write_object_info, write_interface_info, write_union_info,
1943 write_repository): remove unused indent parameters, xmlwriter
1944 keeps track of necessary indentation
1946 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1948 * tools/generate.c (xml_element_new, xml_element_free,
1949 xml_start_element, xml_end_element, xml_end_element_unchecked,
1950 xml_open, xml_close): Keep track of generated XML tree and
1951 handle indentation and closing tags properly.
1952 (write_field_info, write_callable_info, write_function_info,
1953 write_callback_info, write_struct_info, write_value_info,
1954 write_constant_info, write_enum_info, write_signal_info,
1955 write_vfunc_info, write_property_info, write_object_info,
1956 write_interface_info, write_error_domain_info, write_union_info,
1957 write_repository): Use xml_start_element and xml_end_element to
1960 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1962 * tools/generate.c (xml_printf, xml_open, xml_close, xml_free):
1963 (write_type_name, write_type_info, write_field_info,
1964 write_callable_info, write_function_info, write_callback_info,
1965 write_struct_info, write_value_info, write_constant_value,
1966 write_constant_info, write_enum_info, write_signal_info,
1967 write_vfunc_info, write_property_info, write_object_info,
1968 write_interface_info, write_error_domain_info, write_union_info,
1969 write_repository): wrap all FILE access to go through simple xmlwriter
1971 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1973 Bug 556400 – Fails to build on OS X 10.4
1975 * configure.ac: check for functions backtrace and backtrace_symbols
1976 * girepository/girparser.c (backtrace_stderr): Comment out
1977 implementation if the functions are not available.
1978 * gcov.mak (clean-gcov, clean-gcno): always call 'find' with a
1979 directory for better portability
1981 2008-10-15 Johan Bilien <jobi@via.ecp.fr>
1983 Bug 556433 – assume direction = out for int * parameters
1985 * giscanner/ast.py: define a list of types for which, if passed as
1986 reference, we assume a default direction of 'out'
1987 * giscanner/transformer.py: if a type has type pointer to one of the
1988 previously defined types, and no direction is set, assume out.
1989 * tests/scanner/drawable.[ch]: added tests for guessed direction=out
1991 2008-10-15 Johan Bilien <jobi@via.ecp.fr>
1993 * tests/scanner/annotation.c: fixed a few copy-paste errors
1995 2008-10-14 Johan Bilien <jobi@via.ecp.fr>
1997 Bug 556323 – transfer-ownership is wrong for functions returning const
2000 * giscanner/transformer.py: check for a const string as return value,
2001 not just const char*. Suggested by Colin Walters
2002 * tests/scanner/annotation-1.0-expected.gir: updated expected output
2004 2008-10-14 Johan Bilien <jobi@via.ecp.fr>
2006 * girepository/ginfo.c, girepository/girepository.h: add
2007 g_union_info_find_method
2009 2008-10-14 Colin Walters <walters@verbum.org>
2011 * tests/repository/Makefile.am: Reenable repo test.
2012 * tests/repository/gitestrepo.c: Prepend search
2013 path for $(top_builddir)/gir dir so that we don't
2014 require installation for "make check" to pass.
2016 2008-10-13 Jürg Billeter <j@bitron.ch>
2018 * giscanner/glibtransformer.py:
2019 * tests/scanner/annotation-1.0-expected.gir:
2020 * tests/scanner/drawable-1.0-expected.gir:
2021 * tests/scanner/foo-1.0-expected.gir:
2022 * tests/scanner/utility-1.0-expected.gir:
2024 Support fields in GObject structs
2026 2008-10-13 Jürg Billeter <j@bitron.ch>
2028 * giscanner/ast.py: add signed integer and off_t to type_names
2030 2008-10-12 Jürg Billeter <j@bitron.ch>
2032 * giscanner/girparser.py: Parse bits attribute of fields
2034 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
2036 * tests/repository/Makefile.am: run 'gitestrepo' in 'make check'
2037 * tests/repository/gitestrepo.c (main): instantiate
2038 'GCancellable' to ensure the GType is registered before using
2041 2008-10-12 Johan Bilien <jobi@via.ecp.fr>
2043 * giscanner/girparser.py: actually add the parsed constant nodes
2045 2008-10-12 Colin Walters <walters@verbum.org>
2047 * girepository/girepository.c: Don't cast DirEntry to Blob,
2048 actually look it up by offset.
2050 2008-10-12 Johan Bilien <jobi@via.ecp.fr>
2052 * giscanner/girparser.py: parse constant nodes in gir files
2054 2008-10-12 Johan Bilien <jobi@via.ecp.fr>
2056 * giscanner/transformer.py: prefix for constants have an underscore,
2057 so remove them as if they were functions, not objects.
2059 2008-10-12 Johan Bilien <jobi@via.ecp.fr>
2061 * tests/scanner/foo-1.0-expected.gir: add constants to expected gir
2064 2008-10-12 Colin Walters <walters@verbum.org>
2066 Initial patch from Jani Monoses.
2068 * girepository/gtypelib.c: Fix inverted test for success
2071 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
2073 * tools/generate.c (write_callable_info): use "transfer-ownership"
2074 attribute for return values
2076 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
2078 * tools/generate.c (write_callable_info): move "transfer" and
2079 "null-ok" attributes from <function> to <return-value> element
2081 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
2083 * girepository/girparser.c (start_return_value): handle
2084 "transfer-ownership" attribute
2086 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
2088 * girepository/girparser.c (parse_param_transfer):
2089 * tools/generate.c (write_callable_info): use "container" for
2090 container/shallow ownership transfer (not "shallow")
2092 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
2094 * girepository/girparser.c (parse_param_transfer,
2095 start_parameter): Refactor handling of transfer=none/shallow/full
2096 to separate function
2098 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
2100 Bug 556048 – Crash in g_irepository_find_by_gtype
2102 * girepository/gtypelib.h (BLOB_IS_REGISTERED_TYPE): added
2103 * girepository/girepository.c (find_interface): Fix
2104 find_by_gtype case to get the type name from right offset
2106 2008-10-12 Jürg Billeter <j@bitron.ch>
2108 * giscanner/girparser.py: Fix parsing transfer-ownership attribute
2111 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
2113 * girepository/gtypelib.h (RegisteredTypeBlob): make
2114 'unregistered' one bit wide as everywhere else
2116 2008-10-12 Jürg Billeter <j@bitron.ch>
2118 * giscanner/glibtransformer.py:
2119 * tests/scanner/annotation-1.0-expected.gir:
2120 * tests/scanner/drawable-1.0-expected.gir:
2121 * tests/scanner/drawable.h:
2122 * tests/scanner/foo-1.0-expected.gir:
2123 * tests/scanner/utility-1.0-expected.gir:
2125 Readd class records as workaround to not break Gtk typelib
2127 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
2129 * tests/types/Makefile.am: fix typo in gitesttypes namespace
2131 2008-10-12 Jürg Billeter <j@bitron.ch>
2133 * giscanner/glibtransformer.py: Don't generate <record> elements
2135 * tests/scanner/*: Update test cases
2137 2008-10-11 Colin Walters <walters@verbum.org>
2139 Bug 552858: versioning
2141 This is a big patch. You should probably remove your installation
2144 * docs/typelib-format.txt: Add nsversion entry which holds
2145 version of namespace.
2146 * girepository/girepository.h: Add 'version' parameter to
2147 g_irepository_require. This may be NULL. Normally
2148 bindings should pass an explicit version though.
2149 * girepository/girepository.c: Lots of infrastructure to
2150 support versioning. Add some more documentation. Disallow
2151 some usage of NULL namespaces.
2152 * girepository/girmodule.c: Add version parameter.
2153 * girepository/gtypelib.c: Update header size.
2154 * giscanner/ast.py: Add version to Namespace.
2155 * giscanner/girparser.py: Parse version attribute from
2156 XML, pass to Namespace.
2157 * giscanner/girwriter.py: Write out version parameter.
2158 * giscanner/transformer.py: Clean up include registration.
2159 * tests/*: Add version attribute.
2160 * tests/invoke/invoke.c: Don't try looking up test before
2161 it's loaded in repository.
2162 * tools/generate.c: Output version parameter.
2163 * gir/Makefile.am: Add 2.0 version to .gir files.
2165 2008-10-11 Colin Walters <walters@verbum.org>
2167 * giscanner/scannerlexer.l (parse_gtkdoc): Don't lose
2168 if we have mismatched parens.
2170 2008-10-11 Lucas Rocha <lucasr@gnome.org>
2172 * giscanner/girparser.py (_parse_enumeration_bitfield): fix typo
2173 on 'members' variable.
2175 2008-10-11 Colin Walters <walters@verbum.org>
2177 Bug 555947 - update annotations syntax
2179 * giscanner/ast.py: Default to None for transfer. Remove
2180 default transfers for container types; we require this to
2182 * giscanner/girwriter.py: Transfer is now 'none', 'container',
2183 'full' to match repository.
2184 * giscanner/scannerlexer.l: Annotations now are parenthesized.
2185 * giscanner/transformer.py: Update for new annotations syntax.
2188 2008-10-11 Johan Bilien <jobi@litl.com>
2190 * giscanner/scannerparser.y: ignore non-UTF-8 string constants
2192 2008-10-11 Johan Bilien <jobi@litl.com>
2194 Bug 552347: Parse #defines constants
2196 * girepository/gtypelib.c: update the list of value_size
2197 with recently defined type tags
2198 * giscanner/scannerparser.y: brought back parsing of #defined, as
2199 present in older version
2200 * giscanner/giscannermodule.c: bind gi_source_scanner_append_filename
2201 * giscanner/girwriter.py: write out constant tags in the gir
2202 * giscanner/sourcescanner.py: add accessor for const_string
2203 * giscanner/transformer.py, giscanner/glibtransformer.py: handle
2206 2008-10-11 Tommi Komulainen <tommi.komulainen@iki.fi>
2208 Bug 555946: Install a test module exercising all types, transfer
2213 * tests/types/*: Add and install a test module that has functions
2214 accepting and returning most of the basic types to enable bindings
2215 implementors to more easily test their type conversion routines.
2217 2008-10-11 Jürg Billeter <j@bitron.ch>
2219 Bug 552374: Const strings should be identified in the gir.
2221 * giscanner/transformer.py: support string memory management
2222 * tests/scanner/foo.h: use char * and const char *
2223 * tests/scanner/foo-expected.gir: test that
2225 2008-10-11 Johan Dahlin <johan@gnome.org>
2227 * giscanner/girparser.py:
2228 Also parse enums which are not glib types.
2230 2008-10-11 Lucas Rocha <lucasr@gnome.org>
2232 Bug 552370: add one more test for unsigned as a type, not as
2235 * giscanner/ast.py: add 'uint' type name for 'unsigned'.
2236 * test/scanner/foo.h: add function which uses unsigned as a type.
2237 * test/scanner/foo-expected.gir: test that.
2239 2008-10-11 Andreas Rottmann <a.rottmann@gmx.at>
2241 Bug 555712: Struct and union issues
2243 * giscanner/scannerparser.y (struct_declarator): Use information
2244 provided about the bit width of a field.
2245 * giscanner/transformer.py (Transformer._create_member): Pass the
2246 symbol's const_int member to the created field (it represents the
2248 * giscanner/girwriter.py (GIRWriter._write_field): Output 'bits'
2249 field attribute, if present.
2250 * giscanner/ast.py (Field): Add 'bits' member, specifying the
2251 width in bits of the field (only relevant for bitfields).
2254 * giscanner/transformer.py (Transformer._create_typedef_struct)
2255 (Transformer._create_typedef_union): Add calls to _create_struct()
2256 and _create_union(), respectively. This causes the scanner to
2257 generate output for fields of struct and union typedefs.
2260 2008-10-11 Jürg Billeter <j@bitron.ch>
2262 Bug 552370: unsigned not scanned properly
2264 * giscanner/scannerparser.y: combine basic types such as unsigned
2265 int and long long when scanning
2266 * tests/scanner/foo-expected.gir:
2267 * tests/scanner/foo.c: (foo_test_unsigned):
2268 * tests/scanner/foo.h: test that
2270 2008-10-11 Lucas Rocha <lucasr@gnome.org>
2272 Bug 554854: The --typelib-xml and --inject options should reuse
2273 giscanner parser/writer.
2275 * giscanner/ast.py: add constructor list to Struct and Union.
2276 Add new param in Return's contructor to define transfer.
2277 * giscanner/girparser.py: several additions to the parser in order
2278 to have parsing all nodes of the gir xml files.
2279 * tools/g-ir-scanner (typelib_xml_strip, inject): use gir parser
2280 and writer in --inject and --typelib-xml options.
2281 * giscanner/xmlwriter.py: ignore empty attributes instead of
2282 raising an error as this basically exposes a bug in GIRParser.
2283 This should be reverted as soon as the parser is fixed.
2285 2008-10-11 Lucas Rocha <lucasr@gnome.org>
2287 Bug 552376: scanner generates wrong names for enum members when
2288 there's no defined gtype.
2290 * giscanner/utils.py (strip_common_prefix): Always strip common
2291 prefix exactly up to the last "_", and not beyond.
2292 * tests/scanner/foo.h (FooEnumNoType): add FOO_ENUM_NEUF. The point
2293 here is that the first character after the last '_' should should be
2294 the same as the character in the same position on the type name.
2295 * tests/scanner/foo-expected.gir: test that
2297 2008-10-10 Lucas Rocha <lucasr@gnome.org>
2299 Bug 555293: append library_paths to LPATH env variable to work
2300 around a bug in find_library when using ldconfig.
2302 * tools/g-ir-scanner (main): ditto.
2304 2008-10-09 Lucas Rocha <lucasr@gnome.org>
2306 * girepository/girepository.c (register_internal): fix regression on
2307 invoke test case by making sure we load the global module in the
2308 typelib when dealing with inline typelibs.
2309 * girepository/gtypelib.c: a couple of coding style fixes.
2311 2008-10-06 Lucas Rocha <lucasr@gnome.org>
2313 Bug 555294: Add support for multiple shared libraries per typelib.
2315 * girepository/ginvoke.c (g_function_info_invoke),
2316 girepository/ginfo.c(g_registered_type_info_get_g_type): use
2317 g_typelib_symbol instead of g_module_symbol.
2318 * girepository/girepository.h: remove g_typelib_set_module and add
2320 * girepository/gtypelib.[ch] (find_some_symbol, _g_typelib_init,
2321 g_typelib_new_from_memory, g_typelib_new_from_const_memory,
2322 g_typelib_free, g_typelib_symbol): chnage GTypeLib to hold a list of
2323 modules instead of just one. The symbol lookup is now abstracted
2324 behind g_typelib_symbol which tries to find the passed symbol name in
2326 * giscanner/girwriter.py, tools/g-ir-scanner: change scanner to read
2327 and write shared_library attribute as a comma-separated list of libs.
2329 2008-10-06 Colin Walters <walters@verbum.org>
2331 * giscanner/transformer.py: Parse length= annotation as
2332 a parameter name, not a raw int.
2335 2008-10-03 Colin Walters <walters@verbum.org>
2337 Bug 551744: Non-GObject types aren't aggregating ctors and methods
2339 * girepository/gtypelib.c: Allow ctors/methods on struct,union,
2341 * giscanner/glibtransformer.py: Ditto, and GLibBoxed is also a
2345 2008-10-03 Colin Walters <walters@verbum.org>
2347 Bug 554576: scan problem with ev_selection_render_selection()
2349 * giscanner/transformer.py: Only do type resolution once we've
2350 scanned all types. What could happen before is that we'd strip
2351 the namespace from local type "EvSelection" => Selection, and
2352 then later pull a "Selection" from some other namespace because
2353 we hadn't yet seen the local EvSelection. This could come
2354 down to hash table ordering and other things so not easy
2355 to write a test for.
2357 2008-10-03 Lucas Rocha <lucasr@gnome.org>
2359 * giscanner/girwriter.py (_parser_member): fix the last parameter of
2360 GLibEnumMember constructor as it should be the enum member nick.
2362 2008-10-02 Colin Walters <walters@verbum.org>
2364 Bug 552961: remove this parameter for methods
2366 * giscanner/glibtransformer.py: Delete this parameter; it is
2368 * girepository/ginvoke.c: Insert this parameter for methods.
2369 * girepository/gtypelib.c: Remove no longer needed verification of
2370 method this parameter.
2373 2008-09-30 Dan Winship <danw@gnome.org>
2375 Bug 554490: g-ir-scanner gets confused by '\\'
2377 * giscanner/scannerlexer.l (chartext, stringtext): fix use of
2378 backslashes so it will correctly parse '\\' and "\\"
2380 * tests/scanner/annotation.c: add a use of '\\' to make sure that
2383 * giscanner/glibtransformer.py (GLibTransformer.count_type): typo
2385 2008-10-02 Colin Walters <walters@verbum.org>
2387 bug 552393: Note variadic functions
2389 * giscanner/scannerparser.y: Parse ellipsis. Refactor grammar
2390 to use parameter_list directly.
2391 * giscanner/sourcescanner.h: Add ellipsis csymbol type.
2392 * giscanner/ast.py: Add Varargs type.
2393 * giscanner/transformer.py: Check for ellipsis symbol, transform
2395 * girepository/girnode.h: Add varargs flag to in-memory nodes.
2396 Parse varargs functions, but filter them out before we start
2397 compiling the typelib.
2399 2008-10-02 Colin Walters <walters@verbum.org>
2401 Bug 554632: type tag for GType
2403 * girepository/girepository.h, girepository/girepository.c:
2404 Add type tag for GType - it's a special type we don't want
2405 to resolve to just "long".
2406 * docs/typelib-format.txt: Update.
2407 * girepository/girparser.c: Parse it.
2408 * giscanner/glibtransformer.py: Ensure we don't put GType in
2410 * tools/generate.c: Remove hardcoded type list.
2413 2008-09-30 Dan Winship <danw@gnome.org>
2415 Bug 554521: scanner generates wrong names for enum members with
2416 full type name prefix
2418 * giscanner/utils.py (strip_common_prefix): Fix this to strip the
2419 right amount when the entire "first" string is a prefix of
2422 * tests/scanner/foo.h (FooEnumFullname):
2423 * tests/scanner/foo-expected.gir: test that
2425 2008-09-29 Colin Walters <walters@verbum.org>
2427 Bug 552380: Array parameters should be marked in the gir
2429 * giscanner/ast.py: Default char** to utf8[], and guchar* to
2430 uint8[]. Add Array, List, and Map subclasses of Type;
2431 these types can be generic. Return transfer defaults
2432 to true if return value is string or container type.
2433 Delete Sequence type.
2434 * giscanner/scannerlexer.l: Syntax change for annotations;
2435 use <> since it's more readable.
2436 * giscanner/girwriter.py: Write out these changes.
2437 * giscanner/girparser.py: Parse them.
2438 * giscanner/transformer.py: Have a defined set of
2439 both list and map types. When creating a type,
2440 check if the ctype we've parsed is one of them,
2441 if so create a container type subclass as appropriate.
2442 * girepository/girparser.c: Parse in generic types.
2445 2008-09-27 Colin Walters <walters@verbum.org>
2447 * tools/g-ir-scanner: Add --inject option.
2449 2008-09-25 Colin Walters <walters@verbum.org>
2451 Remove non-repository types from GIR
2453 * giscanner/ast.py: The canonical name is 'utf8', not
2455 * giscanner/glibast.py: A few more glib type mappings.
2456 * girepository/girparser.c: We only parse repository types.
2457 * tests/*.gir: Update.
2459 2008-09-23 Colin Walters <walters@verbum.org>
2461 Bug 552566: Add time_t type
2463 We need a type for time_t since it's special in C, and just
2464 mapping it to long precluded bindings from handling it
2467 2008-09-19 Colin Walters <walters@verbum.org>
2469 Bug 552390: Handle capitialization like "DBus" more robustly
2471 The to_underscores function was designed for use against prefixed
2472 names; we need a separate function which will convert names like
2473 DBusFoo into dbus_foo, not d_bus_foo.
2475 2008-09-19 Colin Walters <walters@verbum.org>
2477 Add check to make sure we're not hitting out unresolved types
2479 Validate the "this" argument for methods
2481 Remove heuristic matching of methods to classes based on prefix
2483 It was a broken hack that dated from when we handled underscoring
2484 and capitalization conventions less well.
2486 2008-09-18 Colin Walters <walters@verbum.org>
2488 Bug 552384: Use SHLIB_SUFFIX intead of G_MODULE_SUFFIX for Darwin
2490 On Darwin, the suffix for installed shared libraries (.dylib) is
2491 different from loadable modules (.so). We use a bit of magic shell
2492 script from Behdad Esfahbod to figure out the right suffix.
2494 2008-09-15 Johan Dahlin <johan@gnome.org>
2496 * giscanner/sourcescanner.py (SourceType.type_qualifier): Add
2497 a wrapper for type_qualifier as well.
2499 2008-09-15 Colin Walters <walters@verbum.org>
2501 http://bugzilla.gnome.org/show_bug.cgi?id=552065
2503 * giscanner/ast.py: Add deprecation attributes.
2504 * giscanner/girwriter.py: Write out deprecation data.
2505 * girepository/girparser.c: Relax parsing; deprecated
2506 attribute now includes freeform string.
2507 * giscanner/scannerlexer.l: Parse Deprecated.
2508 * giscanner/transformer.py: Look for deprecated attribute
2510 * tests/scanner/*: Add a Deprecated test.
2512 2008-09-14 Tor Lillqvist <tml@novell.com>
2514 * tests/scanner/Makefile.am (%.typelib): Use $(EXEEXT).
2516 2008-09-14 Colin Walters <walters@verbum.org>
2518 * giscanner/glibtransformer.py: Ignore functions with
2521 2008-09-12 Colin Walters <walters@verbum.org>
2523 * giscanner/glibtransformer.py: Accept Gtk.Type as GType.
2525 2008-09-12 Colin Walters <walters@verbum.org>
2527 * giscanner/ast.py: Bind pid_t to INT for vte.
2529 2008-09-12 Colin Walters <walters@verbum.org>
2531 * giscanner/girparser.py: Parse c:type for boxed records/unions.
2532 * giscanner/glibast.py: Avoid overwriting ctype.
2533 * giscsanner/transformer.py: Try resolving types using the GType names.
2535 2008-09-12 Colin Walters <walters@verbum.org>
2537 * giscanner/minixpath.py: Code to run an "XPath"
2538 assertion against an XML tree, taken from
2539 gir-repository/gir/tests.py.
2540 * giscanner/Makefile.am: Ship it.
2541 * tools/g-ir-scanner: Add --xpath-assertions option.
2542 * gir/GLib-assertions.txt: Add a few assertions.
2543 * gir/Makefile.am: Run them.
2545 2008-09-11 Colin Walters <walters@verbum.org>
2547 http://bugzilla.gnome.org/show_bug.cgi?id=551737
2549 * giscanner/transformer.py: Fix strip_namespace_func to only strip
2550 prefix if it ends with _. Tweak callback stripping to determine
2551 based on presence of _ whether we need to use strip_namespace_func
2552 or strip_namespace_object.
2554 2008-09-09 Owen Taylor <otaylor@redhat.com>
2556 * docs/typelib-format.txt: Wether => Whether
2558 2008-09-08 Colin Walters <walters@verbum.org>
2560 * girepository/girparser.c: Default to "readable" for properties.
2561 * giscanner/ast.py: Add readable, writable etc.
2562 * giscanner/girwriter.py: Writ them.
2563 * giscanner/glibtransformer.py: Inspect them.
2566 2008-09-07 Colin Walters <walters@verbum.org>
2568 * giscanner/cgobject.py: Add comment.
2570 2008-09-07 Colin Walters <walters@verbum.org>
2572 * giscanner/cgobject.py: Also call g_thread_init.
2574 2008-09-07 Colin Walters <walters@verbum.org>
2576 * giscanner/transformer.py: Fix regression by not
2577 stripping prefix before stripping namespace for unions
2580 2008-09-06 Colin Walters <walters@verbum.org>
2582 * giscanner/transformer.py: If a namespace contains
2583 multiple caps, try stripping both gnomekeyring_ and
2586 2008-09-07 Johan Dahlin <johan@gnome.org>
2588 Bug 551162 – giscanner does not recognize asm and __asm__
2589 * giscanner/scannerlexer.l:
2590 Patch by Jani Monoses.
2592 2008-09-06 Colin Walters <walters@verbum.org>
2594 * girepository/girnode.c: Allow gtype_name
2595 and gtype_init in struct and union.
2596 * girepository/girparser.c: Parse glib:
2597 boxed bits for both structure and union.
2598 * girepository/gtypelib.c: Don't barf
2599 if structure is boxed.
2600 * giscanner/girparser.py: Parse new XML
2602 * giscanner/girwriter.py: Write out new
2604 * giscanner/glibast.py: Define new classes
2605 which are both Boxed and Struct/Union, as
2606 well as an "Other" for everything else.
2607 * giscanner/glibtransformer.py: Handle
2608 boxed types specially; we try to merge
2609 them with a struct/union if one exists,
2610 otherwise fall back to generic boxed.
2612 * tools/generate.c: Write out new format.
2614 2008-09-06 Johan Dahlin <johan@gnome.org>
2616 * giscanner/grealpath.h: Include stdlib.h
2618 * docs/g-ir-generate.1: Remove leading %
2620 2008-09-01 Colin Walters <walters@verbum.org>
2622 * girepository/girparser.c: Look at c:type to determine
2623 whether or not an item is a pointer.
2625 2008-09-01 Johan Dahlin <johan@gnome.org>
2627 * tests/scanner/Makefile.am:
2628 Set PYTHONPATH so the scanner can run
2629 even if you didn't install anything.
2631 2008-09-01 Johan Dahlin <johan@gnome.org>
2634 Post-release version bump
2637 2008-09-01 Johan Dahlin <johan@gnome.org>
2641 2008-08-31 Colin Walters <walters@verbum.org>
2643 * giscanner/glibtransformer.py: Quiet info
2646 2008-08-31 Johan Dahlin <johan@gnome.org>
2649 Bump version to 0.5.0
2651 2008-08-31 Colin Walters <walters@verbum.org>
2653 * giscanner/glibtransformer.py: Follow aliases to ensure
2654 we don't get a constructor returning a basic type.
2655 * giscanner/transformer.py: Add function to follow aliases.
2658 2008-08-31 Johan Dahlin <johan@gnome.org>
2660 * giscanner/scannerlexer.l:
2661 * giscanner/scannerparser.y:
2662 * giscanner/sourcescanner.h:
2663 * giscanner/sourcescanner.py:
2664 Parse GCC extensions in the parser instead of just undeffing them
2665 in the pre-processor.
2667 2008-08-31 Johan Dahlin <johan@gnome.org>
2669 * giscanner/glibtransformer.py:
2670 Clean up a huge if. Do not add methods or constructors
2672 * giscanner/utils.py:
2673 second might be longer than first, check that.
2675 2008-08-31 Johan Dahlin <johan@gnome.org>
2680 2008-08-31 Colin Walters <walters@verbum.org>
2682 * girepository/girparser.c: Don't lose if we
2685 2008-08-31 Colin Walters <walters@verbum.org>
2687 * giscanner/glibtransformer.py: Look for libtool
2688 library in current directory
2689 * tests/scanner - Update.
2691 2008-08-30 Colin Walters <walters@verbum.org>
2693 * docs/typelib-format.txt: Add a guint32
2695 * gir/Makefile.am: Dep on Makefile
2696 * girepository/ginfo.c:
2697 * girepository/girepository.c: Clean up
2698 default typelib handling; remove global
2699 default_typelib variable. Ensure we handle
2700 NULL repository in more places.
2701 Support dependency resolution.
2702 Support lazy loading.
2703 * girepository/girepository.h: Remove
2704 g_irepository_unregister; we don't support
2705 unloading typelibs since really they're
2706 process-global. Update for lazy loading
2708 * girepository/girmodule.c: Use g_new0.
2709 Add dependencies to GirModule.
2710 * girepository/girparser.c: Parse dependencies.
2711 * girepository/gtypelib.c: Add 4 bytes for
2713 * tests/Makefile.am: Kill off gobject.gir,
2714 it conflicts with the real one.
2715 * tests/object.gir: Dep on GObject.
2716 * tools/generate.c: Take --includedir
2717 argument to say which directories to search
2718 for typelibs. Print out dependencies.
2720 2008-08-30 Colin Walters <walters@verbum.org>
2722 * giscanner/glibtransformer.py: Reduce warning noise.
2724 2008-08-29 Colin Walters <walters@verbum.org>
2726 * girepository/ginfo.c: Add some assertions regarding
2727 refcounts, just to be sure.
2728 * giscanner/glibtransformer.py: Blacklist a few more
2731 2008-08-29 Colin Walters <walters@verbum.org>
2733 * giscanner/glibtransformer.py: Blacklist a few
2734 functions that use GError oddly
2736 2008-08-29 Colin Walters <walters@verbum.org>
2738 * girepository/gtypelib.c: Don't crash if no
2741 2008-08-29 Colin Walters <walters@verbum.org>
2743 * girepository/girparser.c: Handle chains of aliases
2744 across modules by ensuring we fully qualify aliases
2747 2008-08-29 Colin Walters <walters@verbum.org>
2749 * girepository/girparser.c: Don't search aliases
2752 2008-08-29 Colin Walters <walters@verbum.org>
2754 * girepository/girparser.c: Rewrite type parsing
2755 to handle both GLib parsing case as well as correctly
2756 handling GLib.List and friends. Don't try to treat
2757 e.g. ListStore as a List.
2759 2008-08-29 Colin Walters <walters@verbum.org>
2761 * girepository/gtypelib.c: Add more context
2764 2008-08-29 Colin Walters <walters@verbum.org>
2766 * giscanner/glibtransformer.py: Add some informative
2767 logging messages in corner cases. Be sure we use
2768 the most recent node set instead of a cache
2769 when generating result set.
2770 * tests/: Remove duplicated bits in expected girs
2771 * girepository/girparser.c: Accept both List (for
2772 compiling GLib) and GLib.List (what the scanner
2775 * tools/generate.c: Generate canonical form.
2777 2008-08-29 Johan Dahlin <johan@gnome.org>
2779 * giscanner/config.py.in:
2780 Use datarootdir instead of datadir to avoid
2781 an autoconf warning.
2783 2008-08-29 Johan Dahlin <johan@gnome.org>
2787 * examples/gdk-pixbuf.gidl:
2789 Update and remove old cruft.
2791 2008-08-29 Johan Dahlin <johan@gnome.org>
2794 * docs/g-ir-compiler.1:
2795 * docs/g-ir-generate.1:
2796 * docs/g-ir-scanner.1:
2797 Add man pages for the generator and compiler.
2799 2008-08-29 Johan Dahlin <johan@gnome.org>
2801 * docs/g-ir-scanner.1: Document
2803 * giscanner/Makefile.am:
2804 * giscanner/gidlparser.py:
2805 * giscanner/gidlwriter.py:
2806 * tools/g-ir-scanner:
2807 Remove gidl support.
2809 2008-08-28 Colin Walters <walters@verbum.org>
2811 * tests/scanner/Makefile.am: Pass the right
2812 --includedir args. Add a Makefile dep.
2813 * tools/compiler.c: Pass includedirs down.
2814 * girepository/girparser.c: Actually put
2815 includedirs in context, pass down. Fix
2818 2008-08-28 Colin Walters <walters@verbum.org>
2820 * gir/Makefile.am: Use --includedir
2821 * girepository/girparser.c: Recursively parse
2822 includes to pull in aliases and expand them.
2823 We need this to avoid putting unknown names in
2825 * tools/compiler.c: Add --includedir option.
2826 * giscanner/ast.py: Map size/ssize to types
2829 2008-08-28 Tor Lillqvist <tml@novell.com>
2831 Make check now runs successfully on Windows.
2833 * tools/compiler.c (write_out_typelib): Use binary mode for output
2836 * girepository/girnode.c: Don't print NULL strings.
2838 * tests/invoke/Makefile.am
2839 * tests/scanner/Makefile.am: Use -no-undefined on Windows to
2840 convince libtool to build shared libraries.
2842 * tests/invoke/invoke.c: Don't needlessly include <dlfcn.h>. Use
2843 g_assert() instead of printing out expected errors.
2845 2008-08-28 Tor Lillqvist <tml@novell.com>
2847 * girepository/gtypelib.h: Change type of bitfield fields from
2848 guint to the most suitable smaller type. This makes the struct
2849 sizes match the ones on Linux that the sanity check expects when
2850 using gcc -mms-bitfields on Windows.
2852 2008-08-28 Johan Dahlin <johan@gnome.org>
2857 * giscanner/Makefile.am:
2858 * tests/Makefile.am:
2859 * tests/scanner/Makefile.am:
2860 Make distcheck pass.
2862 2008-08-27 Johan Dahlin <johan@gnome.org>
2864 * giscanner/Makefile.am:
2865 Only send in -no-undefined on Win32 as it breaks on MacOS X.
2867 2008-08-27 Tor Lillqvist <tml@novell.com>
2869 Make g-ir-scanner work on Windows. Still problems with the typelib
2870 code. Changes okayed by jdahlin.
2872 * configure.ac: Check for Windows, set Automake conditional
2873 OS_WIN32. Change backslashes to forward slashes in pyexecdir to
2874 avoid shell quoting issues
2876 * girepository/Makefile.am: Use -no-undefined so that libtool
2877 agrees to build a shared library on Windows.
2879 * girepository/girparser.c (backtrace_stderr): No backtrace() on
2880 Windows. Empty implementation on Windows so far.
2882 * girepository/gtypelib.c (g_typelib_check_sanity): Give more
2883 informative error message for the assertion failures. Tell also
2884 what the expected size of the struct is. Check all sizes first and
2885 fail afterwards if at least one size was different from expected.
2887 * tools/Makefile.am: Reorder libraries into proper logical
2890 * tools/generate.c: Don't include <dlfcn.h>, not used.
2892 * giscanner/Makefile.am: On Windows, link with the Python library,
2893 and install the module DLL as _giscanner.pyd. Remove the
2894 unnecessary import library and libtool library that libtool has
2897 * giscanner/scannerlexer.l: Recognize the gcc __attribute__ syntax
2898 and just skip it. Recognize also two "l" suffixes for long long
2899 constants. Recognize also __inline__.
2901 * giscanner/grealpath.h (g_realpath): Implement on Windows, using
2902 GetFullPathName(). As such, GetFullPathName() does more than the
2903 UNIX realpath(). It also changes relative paths into absolute
2904 paths. But for our purposes that shouldn't matter.
2906 * giscanner/giscannermodule.c (pygi_source_scanner_parse_file): On
2907 Windows the file descriptor passed to us is from Python. Python
2908 Python2.5 uses the msvcr71.dll C library, while mingw-built code
2909 uses msvcrt.dll. On Windows, file descriptors are specific to
2910 which C library is used. So we must find out what underlying OS
2911 handle corresponds to the file descriptor Python passes us, and
2912 then make that into a file descriptor valid for the C library this
2915 * giscanner/sourcescanner.py (_parse): Don't need to bypass
2916 __attribute__ as the lexer now handles it. The definition as empty
2917 was ineffective for mingw anyway, as mingw's _mingw.h undefines
2918 __attribute__. Close the temp file before unlinking it.
2920 * giscanner/cgobject.py: Use correct library name for the gobject
2923 * gir/Makefile.am: Must pass the full basename of the DLLs on
2924 Windows to g-ir-scanner. It's a bit ugly that we have to "know"
2925 that the names of the GLib DLLs are like libglib-2.0-0.dll, but in
2926 reality they won't change, until there is a GLib 3, and then also
2927 the Unix code here needs changing.
2929 Must pass CPPFLAGS to g-ir-scanner when building GLib.gir so that
2932 2008-08-26 Colin Walters <walters@verbum.org>
2934 * girepository/girepository.c: Search
2935 $DATADIR/girepository instead of
2936 $DATADIR/gitypelibs; this naming makes
2937 it clearer that e.g. jgir can install
2939 * gir/Makefile.am: Install there.
2941 2008-08-26 Colin Walters <walters@verbum.org>
2943 * girepository/gtypelib.c (_g_typelib_init): Also
2944 use G_MODULE_SUFFIX instead of hardcoding .so.
2946 2008-08-26 Colin Walters <walters@verbum.org>
2948 * girepository/gtypelib.c (_g_typelib_init): Free
2949 string in the right place.
2951 2008-08-26 Colin Walters <walters@verbum.org>
2953 * girepository/gtypelib.c (_g_typelib_init): Handle
2954 both .la and .so names; this works better in the
2955 uninstalled library case.
2957 2008-08-26 Johan Dahlin <johan@gnome.org>
2960 * giscanner/Makefile.am:
2961 * giscanner/cgobject.py:
2962 * giscanner/config.py.in:
2963 * giscanner/sourcescanner.py:
2964 Avoid undeffing __GNUC__, instead define
2965 __attribute__ & friends. Remove glibconfig.h hack.
2966 This makes gobject-introspection work better on
2967 MacOS X, Thanks to Richard Hult for kind help.
2969 2008-08-25 Colin Walters <walters@verbum.org>
2971 * giscanner/glibtransformer.py: Always print
2974 2008-08-25 Colin Walters <walters@verbum.org>
2976 * giscanner/glibtransformer.py: Skip over
2977 interfaces we don't know.
2979 2008-08-25 Colin Walters <walters@verbum.org>
2981 * girepository/girparser.c: Parse new implements
2982 syntax, drop gapi one.
2983 * tests/object.gir: Update.
2984 * tools/generate.c: Generate new syntax.
2986 2008-08-25 Colin Walters <walters@verbum.org>
2988 * giscanner/ast.py: Add interfaces property
2990 * giscanner/girwriter.py: Write out implemented
2992 * giscanner/glibtransformer.py: Introspect
2993 implemented interfaces.
2994 * tests/scanner/*: Make FooObject implement
2997 2008-08-25 Colin Walters <walters@verbum.org>
2999 * giscanner/glibtransformer.py: More correctly pair
3000 methods; if we have a symbol that starts with
3001 e.g. hippo_canvas look for a matching HippoCanvas
3002 class before accepting e.g. HippoCanvasImage.
3004 2008-08-24 Colin Walters <walters@verbum.org>
3006 * tools/g-ir-scanner: Filter out unknown options from
3009 2008-08-24 Colin Walters <walters@verbum.org>
3011 * giscanner/glibtransformer.py: Fail with better
3012 error if we can't find library.
3014 2008-08-24 Colin Walters <walters@verbum.org>
3016 * tools/g-ir-scanner: Use subprocess instead of
3017 commands, works on Windows and avoids the evil
3020 2008-08-24 Colin Walters <walters@verbum.org>
3022 * giscanner/glibtransformer.py: Skip over
3023 g_object_get_type from GLib trunk.
3025 2008-08-24 Colin Walters <walters@verbum.org>
3027 * girepository/girepository.c (g_irepository_require):
3028 Don't open shared library here; we already do it
3031 2008-08-24 Colin Walters <walters@verbum.org>
3033 * girepository/gtypelib.c: Add context stack so
3034 when we get an error we can print out nicely
3037 2008-08-24 Johan Dahlin <johan@gnome.org>
3039 * girepository/girparser.c (start_glib_boxed), (start_function),
3040 (start_field), (start_alias):
3041 Refactor a couple of parsing functions to be simpler to follow.
3044 2008-08-24 Johan Dahlin <johan@gnome.org>
3046 * girepository/girparser.c (start_function):
3047 Remove left-over code, checking type of function.
3049 2008-08-23 Colin Walters <walters@verbum.org>
3051 * giscanner/config.py: Define DATADIR.
3052 * giscanner/transformer.py: Look in DATADIR.
3054 2008-08-23 Colin Walters <walters@verbum.org>
3056 * girepository/gtypelib.c: Check constructor
3058 * girepository/girnode.c: Small tweaks.
3059 * girepository/ginfo.c: Calculate signature offsets
3061 * girepository/girparser.c: Remove duplicate
3063 * giscanner/glibtransformer.py: Avoid marking
3064 functions which return a basic type as
3067 2008-08-23 Colin Walters <walters@verbum.org>
3069 * girepository/girparser.c: Ignore <include>.
3070 * giscanner/girparser.py: Parse them.
3071 * giscanner/girwriter.py: Generate them.
3072 * giscanner/transformer.py: Process <include>
3073 recursively. Don't require full path for
3074 includes, look in {$XDG_DATA_DIRS}/gir.
3075 * tools/g-ir-scanner: Pass through includes.
3076 * Makefile.am: Remove extra --include
3078 * *-expected.gir: Add expected includes.
3080 2008-08-23 Johan Dahlin <johan@gnome.org>
3082 * tests/scanner/Makefile.am:
3083 * tests/scanner/annotation-expected.gir:
3084 * tests/scanner/drawable-expected.gir:
3085 Avoid duplication in the Makefile, regenerate with new
3086 namespaces (same as the filename)
3088 2008-08-22 Colin Walters <walters@verbum.org>
3090 * girepository/girnode.c: Don't hardcode integers,
3093 2008-08-22 Johan Dahlin <johan@gnome.org>
3095 * giscanner/sourcescanner.py:
3096 Check for ../gobject-introspection-1.0.pc.in to determine
3097 if we run installed or uninstalled.
3099 2008-08-22 Johan Dahlin <johan@gnome.org>
3102 * giscanner/sourcescanner.py:
3103 Send in undefs/defines via writing it directly to stdin
3104 of cpp instead of via arguments.
3106 2008-08-22 Colin Walters <walters@verbum.org>
3108 * tools/generate.c, tools/compiler.c: Default
3110 * all Makefile.am: Update.
3112 2008-08-22 Colin Walters <walters@verbum.org>
3114 * girepository/girparser.c: Pass through
3115 recursive types. Avoid overwriting errors.
3116 * giscanner/xmlwriter.py: Always write the
3118 * tests/*.gir: Adjust.
3119 * tests/scanner/Makefile.am: Build typelibs,
3120 and generate XML from those. Once we
3121 have a good diff mechanism...
3122 * tests/scanner/*-expected.gir: Add XML
3124 * tools/g-ir-scanner: Accept --typelib-xml
3126 * tools/generate.c: Better defaults for transfer.
3128 2008-08-22 Johan Dahlin <johan@gnome.org>
3132 * giscanner/Makefile.am:
3133 * giscanner/config.py.in:
3134 * giscanner/sourcescanner.py:
3135 Use the generated glibconfig.h for all scanner invokations.
3136 Rename it to glibconfig-scanner.h and install it.
3137 Add a config.py which so far contains the include dir.
3139 2008-08-22 Johan Dahlin <johan@gnome.org>
3142 Replace glibconfig.h with our own, do some replacement
3143 for CPP/C features we do not support
3145 2008-08-22 Colin Walters <walters@verbum.org>
3147 * tools/generate.c (write_callable_info): Fix unref
3150 2008-08-22 Colin Walters <walters@verbum.org>
3152 * gobject-introspection-1.0.pc.in: Add g-ir-generate.
3153 * tests/Makefile.am: Support $(DEBUG)
3154 * tools/generate.c: Do immediate close tags if no
3157 2008-08-21 Colin Walters <walters@verbum.org>
3159 * tests/scanner/drawable-expected.gir,
3160 * tests/scanner/drawable.c,
3161 * tests/scanner/drawable.h:
3164 2008-08-21 Colin Walters <walters@verbum.org>
3166 * giscanner/glibtransformer.py: Compute prefix
3167 by searching through the symbol for bits
3168 rather than going directly from ctype; this fixes
3171 2008-08-21 Colin Walters <walters@verbum.org>
3173 * giscanner/glibtransformer.py: Also try squashing
3174 underscores from namespace, fixes webkit_web_view_new.
3176 2008-08-21 Colin Walters <walters@verbum.org>
3178 * giscanner/glibtransformer.py: More ctor work,
3179 avoid having gtk_window_group_new end up under
3182 2008-08-21 Colin Walters <walters@verbum.org>
3184 * giscanner/glibtransformer.py: Much simpler approach
3185 of mapping uscored names to classes.
3186 * giscanner/utils.py: Remove unnecessary function.
3188 2008-08-21 Johan Dahlin <johan@gnome.org>
3190 * girepository/girepository.c (g_irepository_require):
3191 Plug memory leak and avoid using freed memory.
3192 Resolve the whole module path, here as well.
3194 2008-08-21 Colin Walters <walters@verbum.org>
3196 * giscanner/glibtransformer.py: Look up all permutations
3197 of class names when scanning methods/ctors based on
3198 the prefix instead of using the return value. This
3199 associates gtk_window_new with the right class.
3201 2008-08-21 Colin Walters <walters@verbum.org>
3203 * girepository/girmodule.c (g_ir_module_build_typelib):
3204 Revert change to increment header_size; we do that in
3207 2008-08-21 Colin Walters <walters@verbum.org>
3209 * girepository/girnode.c (write_string): Tweak to
3210 use UINT instead of INT. Not likely to matter.
3211 * girepository/girmodule.c (g_ir_module_build_typelib):
3212 Add to header_offset as well for header strings
3213 to match what write_string does.
3214 * girepository/gtypelib.c: Replace is_name with
3215 validate_name, which more strongly validates and
3216 handles errors in a better way. Update all callers.
3217 * giscanner/glibtransformer.py: Handle constructors
3220 2008-08-21 Johan Dahlin <johan@gnome.org>
3222 * gir/Makefile.am (typelibs_DATA): Build and
3223 install the Gio.typelib too
3225 * girepository/gtypelib.c (_g_typelib_init):
3226 Use g_module_build_path to resolve the shlib name
3228 2008-08-21 Colin Walters <walters@verbum.org>
3230 * gir/Makefile.am: CLEANFILES typelibs too.
3232 2008-08-21 Johan Dahlin <johan@gnome.org>
3234 * giscanner/glibtransformer.py:
3235 Do not send .la files through find_library.
3237 2008-08-21 Colin Walters <walters@verbum.org>
3239 * girepository/girparser.c (g_irepository_require):
3240 Fix one small leak in error case.
3242 2008-08-21 Johan Dahlin <johan@gnome.org>
3245 Parse glibconfig.h as well and install the compiled
3248 2008-08-21 Johan Dahlin <johan@gnome.org>
3251 * giscanner/glibtransformer.py:
3252 * tools/g-ir-scanner:
3253 Do not hard-core library names in the Makefile, reuse
3254 ctypes find_library instead.
3256 2008-08-21 Johan Dahlin <johan@gnome.org>
3258 * girepository/girparser.c (resolve_aliases):
3259 Remove compilation warnings
3261 2008-08-21 Johan Dahlin <johan@gnome.org>
3263 * girepository/girepository.c (g_irepository_require):
3264 Rewrap and fix double free bug by leaking a bit.
3266 2008-08-20 Colin Walters <walters@verbum.org>
3268 * girepository/girepository.c: Add new function
3269 g_irepository_get_typelib_path which tells
3270 us from where we loaded a namespace.
3272 2008-08-20 Colin Walters <walters@verbum.org>
3274 * tests/scanner/*-expected.gir: Adjust for
3275 added shared-library.
3276 * giscanner/giwriter.py: Make pylint happy.
3278 2008-08-20 Colin Walters <walters@verbum.org>
3280 * girepository/girmodule.c (g_ir_module_build_typelib):
3281 Calculate size correctly, avoid use-after-free.
3283 2008-08-20 Colin Walters <walters@verbum.org>
3285 * girepository/girepository.c: Remove
3286 g_irepository_register_file in favor of
3287 g_irepository_require. There are two
3288 possible deployment scenarios for typelibs:
3289 First, separate in $DATADIR/gitypelibs/. Second,
3290 they may be embedded in shlibs. However since
3291 the first is now the normal case, the API is
3292 optimized around it.
3294 Refactor internals to look up typelibs for
3295 namespaces just-in-time, but we expect
3296 consumers to call g_irepository_require.
3298 Also, add some docs. No one has died from that
3300 * gir/Makefile.am: Need --library for glib.
3301 * giscanner/girwriter.py: Write out shared-library.
3302 * tools/g-ir-writer: Take the first --library
3303 argument as the target of shared-library. In
3304 the future we should make this nicer with pkg-config
3307 2008-08-20 Colin Walters <walters@verbum.org>
3309 * girepository/girparser.py: And parse them.
3311 2008-08-20 Johan Dahlin <johan@gnome.org>
3313 * giscanner/glibast.py: Add gshort/gushort types
3315 2008-08-20 Colin Walters <walters@verbum.org>
3317 * gir/Makefile.am: Rename .gir files using GI namespace.
3318 * girepository/girepository.c: Use XDG_DATA_DIRS for
3319 looking up typelibs. Also typelibs are now suffixed
3321 * tests/invoke/Makefile.am: Only use metadata.
3322 * girepository/Makefile.am: Remove unnecessary include.
3323 * tests/scanner/Makefile.am: Update using GI namespaces
3324 for scanner includes.
3326 2008-08-20 Colin Walters <walters@verbum.org>
3328 * girepository/transformer.py: Suppress aliases whose
3330 * girepository/ast.py: Define some more aliases.
3332 2008-08-20 Colin Walters <walters@verbum.org>
3334 * girepository/girparser.c: Avoid alias infloops.
3336 2008-08-20 Colin Walters <walters@verbum.org>
3338 * tests/scanner/foo-expected.gir: Fix expected list type.
3340 2008-08-20 Johan Dahlin <johan@gnome.org>
3342 * giscanner/glibtransformer.py (GLibTransformer._resolve_type_name):
3343 Add a workaround for #548689.
3344 We can now compile gtk!
3346 2008-08-20 Colin Walters <walters@verbum.org>
3348 * giscanner/glibtransformer.py: Try to look up
3349 aliases using the c:type too.
3351 2008-08-20 Colin Walters <walters@verbum.org>
3353 * girepository/girparser.c: Parse union fields.
3355 2008-08-20 Johan Dahlin <johan@gnome.org>
3357 * giscanner/ast.py: Make time_t an alias for long
3359 * gir/gio-2.0-good.gir:
3360 * gir/glib-2.0-good.gir:
3361 * gir/gobject-2.0-good.gir:
3363 * giscanner/glibtransformer.py:
3364 Do not delete Class structures, we need them in gdk/gtk.
3365 * tests/scanner/drawable-expected.gir:
3366 * tests/scanner/foo-expected.gir:
3367 * tests/scanner/utility-expected.gir:
3370 2008-08-20 Johan Dahlin <johan@gnome.org>
3372 * tests/scanner/Makefile.am:
3373 * tests/scanner/annotation-expected.gir:
3374 * tests/scanner/annotation.c (annotation_object_class_init),
3375 (annotation_object_init), (annotation_object_method),
3376 (annotation_object_in), (annotation_object_out),
3377 (annotation_object_inout), (annotation_object_inout2),
3378 (annotation_object_inout3), (annotation_object_calleeowns),
3379 (annotation_object_calleesowns), (annotation_object_get_strings),
3380 (annotation_object_with_voidp), (annotation_object_get_objects),
3381 (annotation_object_create_object), (annotation_object_allow_none):
3382 * tests/scanner/annotation.h:
3383 * tests/scanner/foo-expected.gir:
3384 * tests/scanner/foo.c:
3385 * tests/scanner/foo.h:
3386 Split out annotation tests out of foo
3388 2008-08-20 Johan Dahlin <johan@gnome.org>
3390 * tests/scanner/Foo-expected.gir:
3391 * tests/scanner/Makefile.am:
3392 * tests/scanner/foo-expected.gir:
3393 * tests/scanner/foo-object.h:
3394 * tests/scanner/foo.c:
3395 Foo->foo, foo-object.h -> foo.h
3397 2008-08-20 Johan Dahlin <johan@gnome.org>
3399 * tests/scanner/Foo-expected.gir:
3400 * tests/scanner/Makefile.am:
3401 * tests/scanner/drawable-expected.gir:
3402 * tests/scanner/drawable.c (test_drawable_class_init),
3403 (test_drawable_init):
3404 * tests/scanner/drawable.h:
3405 * tests/scanner/foo-object.h:
3406 * tests/scanner/foo.c (foo_boxed_method):
3407 Move the drawable parts out of Foo to its own test.
3409 2008-08-20 Johan Dahlin <johan@gnome.org>
3411 * tests/scanner/Foo-expected.gir:
3412 * tests/scanner/foo-object.h:
3413 * tests/scanner/foo.c (foo_drawable_class_init),
3414 (foo_drawable_init):
3415 Add a based on GdkDrawable which generates
3418 2008-08-19 Colin Walters <walters@verbum.org>
3420 * giscanner/transformer.py: Don't try
3421 to strip prefix before namespace.
3423 2008-08-19 Johan Dahlin <johan@gnome.org>
3425 * giscanner/transformer.py:
3426 * tests/scanner/Foo-expected.gir:
3427 * tests/scanner/foo-object.h:
3428 Add support for typedef void foo type of
3431 2008-08-19 Johan Dahlin <johan@gnome.org>
3434 * giscanner/girwriter.py:
3435 * giscanner/glibtransformer.py:
3436 * giscanner/transformer.py:
3437 * tests/scanner/Foo-expected.gir:
3438 Add basic support for union, base the code much
3439 on Struct. Add a testcase.
3441 2008-08-19 Johan Dahlin <johan@gnome.org>
3443 * tests/scanner/Foo-expected.gir:
3444 * tests/scanner/foo-object.h:
3445 Add a union testcase which the compiler currently
3448 2008-08-19 Johan Dahlin <johan@gnome.org>
3450 * gobject-introspection-1.0.pc.in:
3451 Add a g_ir_compiler variable
3453 2008-08-19 Colin Walters <walters@verbum.org>
3455 * giscanner/ast.py: Rework types to be more closely
3457 * giscanner/girparser.py: Parse more bits.
3458 * giscanner/girwriter.py: Write sequences in a new
3459 way that specifies container type.
3460 * giscanner/glibast.py: Adjust for ast.py changes,
3461 add 'ctype' property to GLibObject and GLibInterface
3462 so we can look things up by it later.
3463 * gicanner/transformer.py: Names is new class holding
3464 the various namespaces we manage. Do not confuse
3465 with Namespace which is toplevel XML node effectively.
3466 Rework all type resolution to go through
3467 _resolve_type_name_1.
3468 * giscanner/glibtransformer.py: Raise UnknownTypeError
3469 instead of ValueError for cleanliness. Add Unresolved
3470 class to mark types whose parent we haven't seen yet.
3471 Use new Names object from transformer.py.
3472 Correctly look up parent=.
3473 Fix type validation to handle sequences.
3474 * tests/scanner/Foo-expected.gir: Update for sequence
3475 work, int instead of int32.
3476 * tools/g-ir-scanner: Add --noclosure option
3477 * gir/Makefile.am: Use --noclosure by default for
3480 2008-08-18 Johan Dahlin <johan@gnome.org>
3482 * gir/gio-2.0-good.gir:
3483 * gir/glib-2.0-good.gir:
3484 * gir/gobject-2.0-good.gir:
3487 2008-08-18 Johan Dahlin <johan@gnome.org>
3490 * giscanner/girparser.py:
3491 * giscanner/girwriter.py:
3492 * giscanner/glibast.py:
3493 * giscanner/glibtransformer.py:
3494 * giscanner/transformer.py:
3495 * tests/scanner/Foo-expected.gir:
3496 * tests/scanner/foo-object.h:
3497 * tests/scanner/utility-expected.gir:
3498 * tests/scanner/utility.h:
3499 Redo type resolving and validation.
3500 Add a couple of new tests.
3501 Patch mostly written by Colin.
3503 2008-08-18 Johan Dahlin <johan@gnome.org>
3506 * giscanner/girparser.py:
3508 * giscanner/transformer.py:
3509 Improve enum parsing for enums without a GType.
3510 Make flags/enum references to other girs work
3511 * giscanner/utils.py:
3513 * tests/scanner/Makefile.am:
3514 * tests/scanner/foo-object.h:
3515 * tests/scanner/utility-expected.gir:
3516 * tests/scanner/utility.h:
3517 Add a new test for external enum references
3519 2008-08-18 Johan Dahlin <johan@gnome.org>
3521 * docs/global-module-registry.txt: Update
3523 * tests/array.gir: Update with new type proposal
3525 * girepository/girepository.c (g_type_tag_to_string):
3526 * girepository/girepository.h:
3527 * girepository/girnode.c (g_ir_node_get_full_size_internal),
3529 * girepository/girnode.h:
3530 Make enum serializing functions public. Clean up some whitespace.
3532 2008-08-17 Johan Dahlin <johan@gnome.org>
3534 * docs/global-module-registry.txt:
3535 Add a document for an on disk module registry format
3537 2008-08-17 Johan Dahlin <johan@gnome.org>
3540 * gir/gio-2.0-good.gir:
3543 2008-08-17 Johan Dahlin <johan@gnome.org>
3546 * gir/glib-2.0-good.gir:
3547 * gir/gobject-2.0-good.gir:
3548 * giscanner/cgobject.py:
3549 * giscanner/glibtransformer.py:
3550 Regenerate GObject & GType.
3551 Avoid warnings when generating gobject-2.0.gir.
3552 Introspect a little more, and skip *_get_type functions.
3554 2008-08-17 Colin Walters <walters@verbum.org>
3556 * gir/glib-2.0.gir, gir/gobject-2.0.gir:
3557 Rename to -good, always generate during build.
3558 * gir/Makefile.am: Ensure .gir files dep on
3559 all scanner sources.
3560 * Makefile.am: Switch build order to ensure
3561 the scanner is ready before we do gir/.
3562 * tools/g-ir-scanner: Look for .git too.
3564 2008-08-17 Johan Dahlin <johan@gnome.org>
3566 * girepository/gtypelib.c (validate_enum_blob):
3567 * giscanner/glibtransformer.py:
3568 * giscanner/transformer.py:
3569 Remove resolve_possible_typedefs, it was unused.
3570 Allow multiple enum values of the sample value in an enum,
3571 since it's actually pretty common.
3572 Register enums so they can be resolved too.
3574 2008-08-16 Johan Dahlin <johan@gnome.org>
3576 * giscanner/girparser.py:
3577 Parse enumeration/bitfield.
3579 2008-08-16 Johan Dahlin <johan@gnome.org>
3581 * giscanner/girparser.py:
3584 2008-08-16 Johan Dahlin <johan@gnome.org>
3586 * giscanner/glibtransformer.py:
3587 Resolve type names for alias targets
3588 * giscanner/transformer.py:
3589 Skip FILE* parameters fow now
3591 2008-08-16 Johan Dahlin <johan@gnome.org>
3594 * gir/gobject-2.0.gir:
3597 * tests/scanner/Makefile.am:
3600 2008-08-15 Colin Walters <walters@verbum.org>
3602 * giscanner/glibtransformer.py: Explicitly construct
3603 new list, since we're deleting as we iterate.
3604 Don't delete all structures which end in Class; just
3605 ones which have a paired GObject.
3606 Fix printing of type warning.
3607 * giscanner/transformer.py: Make strip_namespace_object
3608 be the identity function if it doesn't match the
3611 2008-08-15 Colin Walters <walters@verbum.org>
3613 * giscanner/cgobject.py: Define yet more argument
3614 prototypes; fix prototype for g_type_fundamental.
3616 2008-08-14 Johan Dahlin <johan@gnome.org>
3618 * tests/Makefile.am:
3619 * tests/constant.gir:
3620 * tests/gobject.gir:
3622 * tools/generate.c (write_struct_info):
3623 Fix generator for constant/gobject/struct
3625 2008-08-14 Johan Dahlin <johan@gnome.org>
3627 * tests/Makefile.am:
3629 * tools/generate.c (write_enum_info):
3630 Fix generation of enum/bitfields
3632 2008-08-14 Johan Dahlin <johan@gnome.org>
3634 * girepository/girparser.c (start_field), (start_constant),
3635 (start_type), (end_element_handler):
3636 Clear up constant parsing
3641 * tools/generate.c (write_callable_info), (write_function_info),
3642 (write_callback_info), (write_constant_info), (write_signal_info),
3643 (write_vfunc_info), (write_property_info), (write_object_info),
3644 (write_interface_info):
3645 Constants/Signals are handled now.
3647 2008-08-14 Johan Dahlin <johan@gnome.org>
3649 * girepository/girparser.c (start_type):
3650 Don't require c:type.
3651 * tests/Makefile.am:
3654 Update, remove parts we don't support yet
3655 * tests/roundtrips.sh:
3657 * tools/generate.c (write_type_info), (write_field_info),
3658 (write_callable_info), (write_struct_info):
3659 Make it emit proper gir.
3661 2008-08-14 Johan Dahlin <johan@gnome.org>
3663 * giscanner/transformer.py:
3664 New internal function for adding a new node.
3666 2008-08-14 Johan Dahlin <johan@gnome.org>
3669 Define an internal _H_ variable so we skip parsing both
3670 i18n headers, only one is needed.
3672 Add the glib-2.0.gir too.
3673 * giscanner/glibast.py:
3674 Add gconstpointer as an alias for ANY
3675 * giscanner/transformer.py:
3676 Do not lower case enumeration names per se.
3677 Skip functions which has parameters called 'va_list'
3679 2008-08-14 Colin Walters <walters@verbum.org>
3681 * giscanner/transformer.py: Comment data structures.
3682 Also squash pointers in resolve_type_name to correspond
3683 with what we do for params.
3684 * giscanner/glibtransformer.py: Print warnings in more
3685 situations. Rework checks for method/constructor to
3686 look up in our GType database instead of just checking
3687 for *. Avoid generating <record> for GObject which
3688 duplicate the <class>.
3689 * gir/Makefile.am: Generate glib-2.0.gir and gobject-2.0.gir
3692 2008-08-14 Johan Dahlin <johan@gnome.org>
3694 * giscanner/girwriter.py:
3695 * giscanner/glibast.py:
3696 * giscanner/glibtransformer.py:
3697 * giscanner/transformer.py:
3699 * tests/Makefile.am:
3700 Add pyflakes.py and run it in make check.
3701 Update the source code to fix the errors reported by
3704 2008-08-14 Johan Dahlin <johan@gnome.org>
3707 * giscanner/girparser.py:
3708 * giscanner/glibast.py:
3709 * giscanner/glibtransformer.py:
3710 Refactor the parser a bit.
3711 Add parent type to interfaces and update callsites.
3713 2008-08-14 Johan Dahlin <johan@gnome.org>
3715 * giscanner/glibtransformer.py:
3716 * giscanner/utils.py:
3717 Refactor a bit, avoid isinstance and add a method
3718 for each type we parse.
3720 2008-08-14 Johan Dahlin <johan@gnome.org>
3723 * giscanner/girparser.py:
3724 * giscanner/glibtransformer.py:
3725 * tests/Makefile.am:
3726 Run pep8.py in make check, fix old errors.
3728 2008-08-13 Colin Walters <walters@verbum.org>
3730 * giscanner/girparser.py: Parse records.
3732 2008-08-13 Colin Walters <walters@verbum.org>
3734 * gir/Makefile.am: Install again.
3735 * gir/gobject-2.0.gir: Add some more bits.
3737 2008-08-13 Colin Walters <walters@verbum.org>
3739 * gir/gobject-2.0.gir: Use correct namespace, add GType.
3740 * giscanner/girparser.py: Handle aliases.
3741 * giscanner/transformer.py: Record aliases. Make resolver
3742 functions public; we now call into these explicitly from
3743 glibtransformer. Handle resolving aliases.
3744 * giscanner/glibtransformer.py: Separate our internal namespace
3745 from included ones. Call up into transformer's resolver functions.
3747 2008-08-13 Johan Dahlin <johan@gnome.org>
3749 * girepository/girnode.c (g_ir_node_get_full_size_internal):
3750 * girepository/girparser.c (start_class):
3751 * giscanner/glibtransformer.py:
3752 Allow get_type to be None, set a get_type for GInitiallyUnowned too.
3754 2008-08-13 Johan Dahlin <johan@gnome.org>
3756 * giscanner/cgobject.py:
3757 Register GInitiallyUnowned
3758 * giscanner/girwriter.py:
3759 * giscanner/glibtransformer.py:
3760 Special case GObject/GInitially owned as they are a bit special to use.
3762 2008-08-13 Colin Walters <walters@verbum.org>
3764 * tests/scanner/Foo-expected.gir, tests/scanner/utility-expected.gir:
3765 Object is in GObject namespace.
3767 2008-08-13 Colin Walters <walters@verbum.org>
3769 * giscanner/girparser.py: Fix processing of functions
3772 2008-08-13 Colin Walters <walters@verbum.org>
3774 * giscanner/girparser.py: Parse more than just <class.
3775 * giscanner/glibtransformer.py: Put aliases in a separate
3776 data structure since their name is not canonicall.
3777 * giscanner/transformer.py: Handle resolving type names
3780 2008-08-13 Johan Dahlin <johan@gnome.org>
3782 * tools/g-ir-scanner:
3783 Allow multiple libraries
3784 * giscanner/glibtransformer.py:
3785 Rename load_library to add_library, traverse over all libraries
3786 when trying to resolve a function
3788 2008-08-12 Colin Walters <walters@verbum.org>
3790 * giscanner/transformer.py: Record typedefs as <alias> elements.
3791 Also attempt to look up types in external namespaces.
3792 * giscanner/girwriter.py: Write them.
3793 * giscanner/glibtransformer.py: Rework resolver using real instanceof
3794 checks. Resolve interface methods and properties.
3795 * tests/scanner/foo-object.h: Add a method with typedef.
3796 * tests/scanner/Foo-expected.gir: Update.
3797 * girepository/girnode.c: Debug tweaks.
3798 * girepository/girparser.c: Make a first pass through the XML where we
3799 record all the aliases. This lets us resolve them as we go through the
3801 * gir/Makefile.am: Don't install gobject-2.0.gir; we want that to come
3802 from gir-repository.
3804 2008-08-12 Colin Walters <walters@verbum.org>
3806 * giscanner/glibtransformer.py: Resolve typedefs (e.g. AtkAttributeSet -> GSList).
3807 Correctly do subclasseing in 2nd pass resolution. Handle callbacks in structure
3809 * giscanner/transformer.py: Record typedefs and expose public API for resolving
3811 * tests/scanner/Foo-expected.gir: Fix expected callback types.
3813 2008-08-12 Colin Walters <walters@verbum.org>
3815 * giscanner/glibtransformer.py: Also transform object properties.
3817 2008-08-12 Colin Walters <walters@verbum.org>
3819 * giscanner/glibtransformer.py: Also transform callbacks
3820 and structure field types.
3821 * tests/scanner/Fooe-expected.gir: Update to expect correct
3822 names for callbacks and structs.
3824 2008-08-12 Colin Walters <walters@verbum.org>
3826 * girepository/girparser.c: Handle 'any'.
3827 * tests/scanner/Foo-expected.gir, tests/scanner/foo-object.h:
3828 Add test for void *.
3830 2008-08-12 Colin Walters <walters@verbum.org>
3832 * giscanner/glibtransformer.py: We need to do type
3833 resolution in a second pass after we've seen all the
3834 enums, records, etc.
3836 2008-08-12 Colin Walters <walters@verbum.org>
3838 * tests/scanner/Foo-expected.gir, tests/scanner/foo-object.h:
3839 Add enum return value.
3840 * giscanner/glibtransformer.py: Transform function return types
3843 2008-08-12 Colin Walters <walters@verbum.org>
3845 * tests/scanner/Makefile.am: Dep .gir files on scanner
3846 sources too. Also remove @ so we see scanner invocations.
3848 2008-08-12 Colin Walters <walters@verbum.org>
3850 * girepository/girparser.c, girepository/gtypelib.c,
3851 girepository/gtypelib.h, girepository/girnode.c:
3852 Remove usage of (GAPI-oriented) TypeTag in favor of
3853 GITypeTag from girepository.h.
3855 2008-08-10 Colin Walters <walters@verbum.org>
3857 * tests/roundtrips.sh: Use the correct tests.
3859 2008-08-10 Colin Walters <walters@verbum.org>
3861 * giscanner/cgobject.py: Declare/wrap a few more functions.
3862 Fix parameter types for g_object_new and g_type_fundamental.
3864 2008-08-10 Colin Walters <walters@verbum.org>
3866 * giscanner/cgobject.py: Add new decorator @gwrap which forces
3867 us to declare types for both return value and parameters. The
3868 ctypes default of 'int' is bad because it hides 32/64 bit
3869 problems. Convert all existing functions to use it.
3871 2008-08-09 Johan Dahlin <johan@gnome.org>
3873 * giscanner/__init__.py:
3875 * giscanner/cgobject.py:
3876 * giscanner/gidlparser.py:
3877 * giscanner/gidlwriter.py:
3878 * giscanner/girparser.py:
3879 * giscanner/girwriter.py:
3880 * giscanner/glibast.py:
3881 * giscanner/glibtransformer.py:
3882 * giscanner/odict.py:
3883 * giscanner/sourcescanner.py:
3884 * giscanner/transformer.py:
3885 * giscanner/utils.py:
3886 * giscanner/xmlwriter.py:
3887 * tools/g-ir-scanner:
3891 2008-08-09 Johan Dahlin <johan@gnome.org>
3894 * relaxng/c-types.xml:
3895 * relaxng/g-types.xml:
3896 * relaxng/relaxng.rng:
3898 Remove outdated relaxng schemas.
3900 2008-08-09 Johan Dahlin <johan@gnome.org>
3903 Rename metadata to typelib in variable names,
3906 2008-08-09 Johan Dahlin <johan@gnome.org>
3910 Remove old C scanner, which got rewritten in python.
3912 2008-08-09 Johan Dahlin <johan@gnome.org>
3914 * girepository/Makefile.am:
3915 * tools/Makefile.am:
3916 * tools/girmodule.c:
3917 * tools/girmodule.h:
3920 * tools/girparser.c:
3921 * tools/girparser.h:
3922 * tools/girwriter.c:
3923 * tools/girwriter.h:
3924 Move shared *.[ch] files to girepository from tools
3926 2008-08-09 Johan Dahlin <johan@gnome.org>
3928 * tests/Makefile.am:
3931 * tests/constant.test:
3933 * tests/errors.test:
3934 * tests/function.test:
3935 * tests/gobject.test:
3936 * tests/interface.test:
3937 * tests/object.test:
3938 * tests/struct.test:
3943 Rename *.test to *.gir
3945 2008-08-09 Johan Dahlin <johan@gnome.org>
3948 * tests/Makefile.am:
3949 * tests/parser/Foo-expected.gir:
3950 * tests/parser/Makefile.am:
3951 * tests/parser/foo-object.h:
3952 * tests/parser/foo.c:
3953 * tests/parser/utility-expected.gir:
3954 * tests/parser/utility.c:
3955 * tests/parser/utility.h:
3956 * tests/scanner/Makefile.am:
3957 Rename tests/parser to test/scanner
3959 2008-08-08 Colin Walters <walters@verbum.org>
3961 * tests/roundtrips.sh: Use local .gir files again.
3963 2008-08-08 Colin Walters <walters@verbum.org>
3965 * tests/invoke/Makefile.am: .gir file depends on libtool
3968 2008-08-08 Colin Walters <walters@verbum.org>
3970 * tools/girnode.c: Pass through parent node so we can
3971 print the node whose child is NULL, if that occurs.
3973 2008-08-08 Johan Dahlin <johan@gnome.org>
3975 * tests/Makefile.am:
3976 Disable roundtrip tests which are not yet working
3977 * tests/invoke/testfns.gir:
3980 2008-08-08 Johan Dahlin <johan@gnome.org>
3982 * giscanner/girwriter.py:
3984 * giscanner/glibast.py:
3985 * giscanner/glibtransformer.py:
3986 Swap order of members, to keep it consistent with
3989 2008-08-08 Johan Dahlin <johan@gnome.org>
3991 * girepository/gtypelib.c (validate_header):
3992 * girepository/gtypelib.h:
3994 * giscanner/girwriter.py:
3995 * giscanner/sourcescanner.c (gi_source_symbol_ref),
3996 (gi_source_symbol_unref):
3999 * tests/constant.test:
4001 * tests/errors.test:
4002 * tests/function.test:
4003 * tests/gobject.test:
4004 * tests/interface.test:
4005 * tests/invoke/Makefile.am:
4006 * tests/invoke/testfns.xml:
4007 * tests/object.test:
4008 * tests/parser/Makefile.am:
4009 * tests/roundtrips.sh:
4010 * tests/struct.test:
4015 * tools/Makefile.am:
4016 * tools/compiler.c (main):
4017 * tools/generate.c (write_callable_info), (write_function_info),
4019 * tools/gidlmodule.c:
4020 * tools/gidlmodule.h:
4023 * tools/gidlparser.c:
4024 * tools/gidlparser.h:
4025 * tools/gidlwriter.c:
4026 * tools/gidlwriter.h:
4027 * tools/scanner.c (create_node_from_gtype),
4028 (create_node_from_ctype), (g_igenerator_process_properties),
4029 (g_igenerator_process_signals), (g_igenerator_create_object),
4030 (g_igenerator_create_interface), (g_igenerator_create_boxed),
4031 (g_igenerator_create_enum), (g_igenerator_create_flags),
4032 (g_igenerator_process_function_symbol),
4033 (g_igenerator_process_unregistered_struct_typedef),
4034 (g_igenerator_process_struct_typedef),
4035 (g_igenerator_process_union_typedef),
4036 (g_igenerator_process_enum_typedef),
4037 (g_igenerator_process_function_typedef),
4038 (g_igenerator_process_constant), (g_igenerator_process_symbols),
4039 (g_igenerator_add_module), (g_igenerator_add_include_idl):
4040 Merge in the gir-compiler branch.
4041 Thanks to Philip and Colin for their help.
4043 2008-07-26 Colin Walters <walters@verbum.org>
4045 * tools/Makefile.am (bin_PROGRAMS): Install g-idl-compiler
4046 and g-idl-generate to go along with how we're changing this
4047 module to be installed.
4048 * gobject-introspection-1.0.pc.in: Set up Cflags and Libs.
4050 2008-07-24 Colin Walters <walters@verbum.org>
4052 * girepository/girepository.c (g_irepository_register): Add
4053 environment variable G_IREPOSITORY_VERBOSE so we can print
4054 out what we're doing.
4055 * girepository/girepository.c (g_irepository_register_file):
4056 Add GError error message to g_debug call.
4058 2008-07-08 Jürg Billeter <j@bitron.ch>
4060 * giscanner/glibast.py:
4064 2008-06-21 Johan Dahlin <jdahlin@async.com.br>
4066 * giscanner/girparser.py (GIRParser._parse_api): Ignore a few
4069 2008-06-20 Johan Dahlin <jdahlin@async.com.br>
4072 * giscanner/girwriter.py:
4073 * giscanner/transformer.py:
4074 * tests/parser/Foo-expected.gir:
4075 * tests/parser/foo-object.h:
4076 * tests/parser/foo.c (foo_object_allow_none):
4077 Add support for gtk-doc annotations for allow-none.
4080 2008-06-19 Johan Dahlin <jdahlin@async.com.br>
4083 * giscanner/girwriter.py:
4084 * giscanner/glibast.py:
4085 * giscanner/glibtransformer.py:
4086 * giscanner/transformer.py:
4087 * tests/parser/Foo-expected.gir:
4088 Start using abstract type instead of the raw C types.
4089 Register a bunch of glib types we care about.
4091 2008-06-19 Rob Taylor <rob.taylor@codethink.co.uk>
4096 2008-06-08 Philip Van Hoof <pvanhoof@gnome.org>
4098 * girepository/girepository.c:
4099 * girepository/gtypelib.c:
4100 * girepository/ginfo.c:
4101 * girepository/ginvoke.c:
4102 * girepository/girepository.h:
4103 * girepository/gtypelib.h:
4104 * girepository/gmetadata.c:
4105 * girepository/Makefile.am:
4106 * girepository/gmetadata.h:
4108 * tools/gidlmodule.c:
4111 * tools/gidlmodule.h:
4112 * tools/gidlparser.c:
4114 Renamed GMetadata to GTypelib
4116 2008-06-07 Johan Dahlin <jdahlin@async.com.br>
4118 * giscanner/xmlwriter.py:
4119 Improve line wrapping when > 79 charaters
4121 2008-06-05 Jürg Billeter <j@bitron.ch>
4124 * giscanner/girwriter.py:
4125 * giscanner/transformer.py:
4126 Use <type> element for field types
4127 * tests/parser/Foo-expected.gir:
4130 2008-06-04 Johan Dahlin <jdahlin@async.com.br>
4132 * giscanner/glibtransformer.py:
4133 Fix a bug which prevented GdkEvent from being generated
4135 2008-06-03 Johan Dahlin <jdahlin@async.com.br>
4137 * giscanner/Makefile.am:
4139 * giscanner/girwriter.py:
4140 * giscanner/glibast.py:
4141 * giscanner/glibtransformer.py:
4142 * giscanner/transformer.py:
4143 * giscanner/utils.py:
4144 * tests/parser/Foo-expected.gir:
4145 Improve enum member parsing and introspection
4147 2008-05-31 Johan Dahlin <jdahlin@async.com.br>
4149 * giscanner/scannerparser.y:
4150 * giscanner/sourcescanner.h:
4151 * giscanner/sourcescanner.py:
4152 Add a new source type enum for member.
4153 Use __repr__ for improved debugging
4154 * giscanner/girparser.py:
4156 * giscanner/transformer.py:
4157 Improve parsing of struct members.
4158 * tests/parser/foo-object.h:
4161 2008-05-31 Johan Dahlin <jdahlin@async.com.br>
4163 * giscanner/xmlwriter.py:
4164 Improve error reporting when trying to quote None.
4165 * giscanner/girparser.py:
4166 Do not print warnings when including more complete .gir files
4167 * giscanner/girwriter.py:
4168 Do not require a name for parameters, add a todo for singletons
4169 * giscanner/glibtransformer.py:
4170 Refactor the way structs are done, add a couple of hacks to allow
4172 * giscanner/transformer.py:
4173 Add enough hacks so cairo, atk and pango.gir can be parsed properly
4174 * gobject-introspection-1.0.pc.in:
4175 Export girdir, so we can access gobject-2.0.gir from outside
4177 2008-05-31 Johan Dahlin <jdahlin@async.com.br>
4179 * tools/g-ir-scanner:
4180 * tests/parser/Makefile.am:
4181 Update sys.path before running the parser so we don't have
4182 to setup PYTHONPATH ourselves.
4186 * girepository/Makefile.am:
4187 * giscanner/transformer.py:
4188 * gobject-introspection-1.0.pc.in:
4189 * gobject-introspection.pc.in:
4190 * tools/Makefile.am:
4192 Rename pkg-config name to gobject-introspection-1.0,
4193 Do not installed anything which is not using the gir format.
4194 Disable compililation the old C scanner, but still keep the source
4195 until all the remaning functionallity has been ported.
4197 2008-05-31 Johan Dahlin <jdahlin@async.com.br>
4199 * giscanner/giscannermodule.c (symbol_get_ident): Prevent
4200 a crash when symbol->indent is NULL.
4202 * giscanner/sourcescanner.py (ctype_name): Add ctype_name,
4203 a function to convert a CTYPE symbol to a string
4205 2008-05-24 Johan Dahlin <jdahlin@async.com.br>
4208 * giscanner/girwriter.py:
4209 * giscanner/giscannermodule.c
4210 (pygi_source_scanner_append_filename),
4211 (pygi_source_scanner_parse_file):
4212 * giscanner/glibtransformer.py:
4213 * giscanner/sourcescanner.py:
4214 Revert back to using temporary files to send in headers.
4215 Allow Functions to be passed in as callbacks, add a couple
4216 of try/excepts missing features.
4217 We can now scan pango
4219 2008-05-08 Johan Dahlin <johan@gnome.org>
4221 * giscanner/glibtransformer.py:
4222 * giscanner/transformer.py:
4223 Move namespace stripping glibtransformer->transformer
4225 2008-05-08 Johan Dahlin <johan@gnome.org>
4228 * giscanner/girwriter.py:
4229 * giscanner/glibtransformer.py:
4230 * giscanner/transformer.py:
4231 * tools/g-ir-scanner:
4232 Introduce a namespace ast node
4234 2008-05-05 Johan Dahlin <johan@gnome.org>
4236 * giscanner/__init__.py:
4237 * giscanner/sourcescanner.py:
4238 * giscanner/transformer.py:
4239 Move sourcescanner symbols to the sourcescanner module, instead
4240 of in the global __init__ namespace.
4242 2008-05-03 Johan Dahlin <johan@gnome.org>
4244 * giscanner/glibtransformer.py:
4245 * tools/g-ir-scanner:
4246 Handle missing parameters better, allow - and + in .la dlname
4249 2008-05-03 Johan Dahlin <johan@gnome.org>
4251 * giscanner/__init__.py:
4253 * giscanner/girwriter.py:
4254 * giscanner/glibtransformer.py:
4255 * giscanner/transformer.py:
4256 Parse struct fields properly, improve debugging.
4258 2008-04-29 Johan Dahlin <johan@gnome.org>
4261 * giscanner/girwriter.py:
4262 * giscanner/transformer.py:
4263 * tests/parser/Foo-expected.gir:
4265 Use transfer-ownership everywhere, to mark ownership/calle/caller etc.
4267 2008-04-29 Johan Dahlin <jdahlin@async.com.br>
4270 * docs/g-ir-scanner.1:
4271 * metadata-annotations-proposal.txt:
4272 * metadata-format.txt:
4273 Add a basic, unfinshed man page for g-ir-scanner, move documents into .txt
4275 2008-04-29 Johan Dahlin <jdahlin@async.com.br>
4277 * giscanner/girwriter.py:
4278 * giscanner/glibtransformer.py:
4279 * giscanner/transformer.py:
4280 * giscanner/xmlwriter.py:
4281 * tests/parser/Foo-expected.gir:
4282 * tests/parser/foo-object.h:
4283 Write record/structs to gir file too. Add a couple of tests,
4284 fix an off by one error in xmlwriter.py.
4286 2008-04-28 Johan Dahlin <johan@gnome.org>
4288 * giscanner/xmlwriter.py: Calculate the line length properly,
4289 include the provided extra indentation in the calculation, really.
4291 2008-04-28 Johan Dahlin <jdahlin@async.com.br>
4294 * giscanner/glibast.py:
4295 * giscanner/glibtransformer.py:
4296 * giscanner/transformer.py:
4297 * tools/g-ir-scanner:
4298 Add a --strip-prefix and sort out confusion between names and symbols
4299 for functions and struct + derivaties.
4300 Refactor bootstrap of g-ir-scanner, so we can set options on
4301 Transformer() before parsing everything.
4303 2008-04-28 Johan Dahlin <johan@gnome.org>
4305 * giscanner/transformer.py (Transformer._traverse_one): Avoid recursion
4306 when scanning girepository.h
4308 * giscanner/sourcescanner.py (SourceScanner._preprocess): Define
4309 a __GI_SCANNER__ when we run.
4311 2008-04-28 Johan Dahlin <jdahlin@async.com.br>
4314 * giscanner/girwriter.py:
4315 * giscanner/glibast.py:
4316 * giscanner/glibtransformer.py:
4317 * tests/parser/Foo-expected.gir:
4318 * tests/parser/utility-expected.gir:
4319 Rename most c:identifier to c:type. Add new ones to
4320 class/interface/enum/boxed.
4322 2008-04-28 Johan Dahlin <jdahlin@async.com.br>
4325 * giscanner/girwriter.py:
4326 * giscanner/glibtransformer.py:
4327 * tests/parser/Foo-expected.gidl:
4328 * tests/parser/Makefile.am:
4329 Move c:identifier from return-value to subchild type,
4330 as per Jürgs suggestion
4332 2008-04-28 Johan Dahlin <johan@gnome.org>
4334 * giscanner/girwriter.py:
4335 * tests/parser/Foo-expected.gir:
4336 Write property.type as a child node.
4338 2008-04-27 Johan Dahlin <johan@gnome.org>
4343 * gidl/gobject-2.0.gidl:
4345 * gir/gobject-2.0.gir:
4346 * tests/parser/Makefile.am:
4347 Replace the GObject gidl with a GObject gir.
4349 2008-04-27 Johan Dahlin <johan@gnome.org>
4351 * tools/Makefile.am (bin_SCRIPTS): g-ir-scanner is a script,
4354 * giscanner/xmlwriter.py:
4355 * tests/parser/Foo-expected.gir:
4356 Include indentation in line length calculation
4358 2008-04-27 Johan Dahlin <johan@gnome.org>
4360 * giscanner/girparser.py:
4361 Prettify NS parsing using elementtree.
4363 2008-04-27 Johan Dahlin <johan@gnome.org>
4366 * giscanner/Makefile.am:
4367 * giscanner/girparser.py:
4368 * giscanner/glibtransformer.py:
4369 * tests/parser/Foo-expected.gidl:
4370 * tests/parser/Foo-expected.gir:
4371 * tests/parser/Makefile.am:
4372 * tests/parser/utility-expected.gidl:
4373 * tests/parser/utility-expected.gir:
4374 * tools/g-ir-scanner:
4375 Switch over to GIR as the default format. Add a simple GIDL
4377 Update tests and fix simplify makefiles by depending
4378 on GNU make extensions.
4380 2008-04-27 Johan Dahlin <johan@gnome.org>
4382 * giscanner/xmlwriter.py:
4383 Wrap attributes for lines which are wider than 79 characters
4385 * giscanner/scannerlexer.l:
4386 Allow parenthesis in annotations
4389 * giscanner/gidlwriter.py:
4390 * giscanner/girwriter.py:
4391 * giscanner/glibtransformer.py:
4392 * giscanner/transformer.py:
4393 Add initial sequence support, including annotation.
4394 Refactor type handling a bit.
4396 2008-04-27 Johan Dahlin <johan@gnome.org>
4398 * tests/parser/Foo-expected.gidl:
4399 * tests/parser/foo-object.h:
4400 * tests/parser/foo.c (foo_object_class_init),
4401 (foo_object_get_strings), (foo_object_get_objects):
4402 Add two new functions to check sequence return values.
4403 Also fixes a compilation warning.
4405 2008-04-27 Johan Dahlin <johan@gnome.org>
4407 * giscanner/giscannermodule.c (]): Cast the getter, avoids
4408 a compilation warning.
4410 * tools/Makefile.am (g_ir_scanner_SOURCES):
4411 g-ir-scanner has no sources.
4413 2008-04-25 Johan Dahlin <johan@gnome.org>
4415 * giscanner/Makefile.am:
4417 * giscanner/gidlparser.py:
4418 * giscanner/gidlwriter.py:
4419 * giscanner/girwriter.py:
4420 * giscanner/glibast.py:
4421 * giscanner/glibtransformer.py:
4422 * giscanner/transformer.py:
4423 Split out nodes to ast.py and glibast.py
4425 2008-04-25 Johan Dahlin <jdahlin@async.com.br>
4427 * giscanner/Makefile.am:
4428 * giscanner/gidlparser.py:
4429 * giscanner/gidlwriter.py:
4430 * giscanner/girwriter.py:
4431 * giscanner/glibtransformer.py:
4432 * giscanner/gobjecttreebuilder.py:
4433 * giscanner/transformer.py:
4434 * giscanner/treebuilder.py:
4435 * tools/g-ir-scanner:
4436 Rename treebuilder to transformer and
4437 gobjectreebuilder to glibtransformer.
4439 2008-04-25 Johan Dahlin <jdahlin@async.com.br>
4441 * giscanner/Makefile.am:
4442 * giscanner/__init__.py:
4443 * giscanner/cgobject.py:
4444 * giscanner/gidlparser.py:
4445 * giscanner/gidlwriter.py:
4446 * giscanner/girwriter.py:
4447 * giscanner/gobjecttreebuilder.py:
4448 * giscanner/odict.py:
4449 * giscanner/sourcescanner.py:
4450 * giscanner/treebuilder.py:
4451 * giscanner/xmlwriter.py:
4452 * tools/Makefile.am:
4453 * tools/g-ir-scanner:
4454 Add LGPLv2 license header and install all python files
4456 2008-04-25 Johan Dahlin <jdahlin@async.com.br>
4459 * giscanner/gidlwriter.py:
4460 * giscanner/giscannermodule.c (pygi_source_directive_new),
4461 (directive_get_options), (pygi_source_symbol_new),
4462 (symbol_get_base_type), (pygi_source_type_new),
4463 (type_get_base_type), (type_get_child_list),
4464 (pygi_source_scanner_get_symbols),
4465 (pygi_source_scanner_get_directives):
4466 * giscanner/gobjecttreebuilder.py:
4467 * giscanner/sourcescanner.py:
4468 * giscanner/treebuilder.py:
4469 * tests/parser/foo-object.h:
4470 Add support for virtual methods.
4471 Pair struct FooClass with struct Foo.
4472 Clean up the SourceScanner bindings a bit.
4473 Add a testcase for virtual methods.
4475 2008-04-25 Johan Dahlin <jdahlin@async.com.br>
4477 * giscanner/cgobject.py:
4478 * giscanner/gidlwriter.py:
4479 * giscanner/gobjecttreebuilder.py:
4480 Add support for signals
4482 * tests/parser/foo.c (foo_object_class_init):
4483 * Foo-expected.gidl:
4484 Add a signal and update the expected output.
4486 2008-04-24 Johan Dahlin <jdahlin@async.com.br>
4488 * giscanner/gidlwriter.py:
4489 * giscanner/girwriter.py:
4490 * giscanner/giscannermodule.c (directive_get_name),
4491 (directive_get_value), (directive_get_options),
4492 (symbol_get_directives), (symbol_set_directives),
4493 (pygi_source_scanner_parse_file),
4494 (pygi_source_scanner_lex_filename),
4495 (pygi_source_scanner_get_directives), (init_giscanner):
4496 * giscanner/sourcescanner.c (gi_source_scanner_get_directives):
4497 * giscanner/sourcescanner.h:
4498 * giscanner/sourcescanner.py:
4499 * giscanner/treebuilder.py:
4500 * tools/g-ir-scanner:
4501 Add support for source/header annotations.
4503 2008-04-22 Johan Dahlin <jdahlin@async.com.br>
4505 * giscanner/gidlwriter.py:
4506 * giscanner/girwriter.py:
4507 * giscanner/gobjecttreebuilder.py:
4508 * giscanner/treebuilder.py:
4509 Add support for Callbacks
4511 2008-04-22 Havoc Pennington <hp@pobox.com>
4513 * girepository/ginvoke.c (g_function_info_invoke): If a symbol is
4514 not in metadata->module, look for it in the global module, in case
4515 some other object or the app itself provides the symbol.
4517 2008-04-22 Havoc Pennington <hp@pobox.com>
4519 * girepository/gmetadata.c (_g_metadata_init): hack to avoid
4520 dlopening a library that is already in the main app, by checking
4521 whether one of the lib's symbols is already loaded.
4523 2008-04-22 Johan Dahlin <jdahlin@async.com.br>
4525 * tests/parser/Foo-expected.gidl:
4526 * tests/parser/foo-object.h:
4529 2008-04-22 Havoc Pennington <hp@pobox.com>
4531 * girepository/ginfo.c (g_interface_info_find_method):
4532 Use interface_blob_size not object_blob_size to compute offset.
4534 2008-04-22 Havoc Pennington <hp@pobox.com>
4536 * girepository/gmetadata.c (_g_metadata_init): remove
4537 G_MODULE_BIND_LOCAL flag when loading libraries, since some libs
4538 (Glade and Clutter for example) rely on being loaded globally.
4540 2008-04-22 Havoc Pennington <hp@pobox.com>
4542 * girepository/ginfo.c (g_registered_type_info_get_g_type): new
4543 function to get the GType given a RegisteredTypeInfo
4545 2008-04-22 Johan Dahlin <johan@gnome.org>
4547 * COPYING: Add a LGPL license, to prevent automake to
4548 put in a copy of GPL here. Pointed out by Havoc.
4550 * girepository/ginfo.c (g_info_from_entry), (g_type_info_new),
4551 (g_type_info_is_pointer), (g_type_info_get_tag),
4552 (g_type_info_get_param_type), (g_type_info_get_interface),
4553 (g_type_info_get_array_length), (g_type_info_is_zero_terminated),
4554 (g_type_info_get_n_error_domains), (g_type_info_get_error_domain),
4555 (g_error_domain_info_get_codes), (g_enum_info_get_value),
4556 (g_object_info_get_interface), (g_object_info_get_field),
4557 (g_interface_info_get_prerequisite),
4558 (g_signal_info_get_class_closure), (g_constant_info_get_value):
4559 * girepository/ginvoke.c (get_ffi_type):
4560 * girepository/girepository.h:
4561 * girepository/gmetadata.c (g_metadata_get_dir_entry),
4562 (g_metadata_check_sanity), (validate_header),
4563 (validate_array_type_blob), (validate_iface_type_blob),
4564 (validate_param_type_blob), (validate_error_type_blob),
4565 (validate_type_blob), (validate_constant_blob),
4566 (validate_struct_blob), (validate_enum_blob):
4567 * girepository/gmetadata.h:
4568 * tests/Makefile.am:
4569 * tests/invoke/Makefile.am:
4570 * tests/invoke/invoke.c (main):
4571 * tests/roundtrips.sh:
4572 * tools/Makefile.am:
4573 * tools/compiler.c (format_output), (write_out_metadata), (main):
4574 * tools/generate.c (write_type_name), (write_type_info),
4575 (write_constant_value), (write_enum_info), (load_metadata), (main):
4576 * tools/gidlcompilercontext.c:
4577 * tools/gidlcompilercontext.h:
4578 * tools/gidlcompilerentrynode.c:
4579 * tools/gidlcompilerentrynode.h:
4580 * tools/gidlcompilertypenode.c:
4581 * tools/gidlcompilertypenode.h:
4582 * tools/gidlmodule.c (g_idl_module_build_metadata):
4583 * tools/gidlmodule.h:
4584 * tools/gidlnode.c (init_stats), (dump_stats),
4585 (g_idl_node_get_size), (g_idl_node_get_full_size),
4586 (g_idl_node_cmp), (g_idl_node_can_have_member),
4587 (g_idl_node_add_member), (g_idl_node_param_direction_string),
4588 (parse_int_value), (parse_uint_value), (parse_float_value),
4589 (parse_boolean_value), (find_entry_node), (find_entry),
4590 (serialize_type), (g_idl_node_build_metadata), (write_string):
4592 * tools/gidlparser.c (parse_type_internal):
4593 * tools/quote-file.sh:
4594 Revert revisions 157,149-148,136-129 and 120.
4595 Move back to using g-idl-generate to generate the metadata and
4596 avoids dependency on a c compiler.
4598 2008-04-22 Johan Dahlin <jdahlin@async.com.br>
4600 * giscanner/girwriter.py:
4601 * tools/g-ir-scanner:
4602 Add an initial GIR writer and a --format option to g-ir-scanner
4604 2008-04-21 Johan Dahlin <johan@gnome.org>
4606 * giscanner/cgobject.py: Use ctypes.util.find_library to locate
4607 gobject-2.0 and raise ImportError if not found.
4609 * giscanner/gidlparser.py:
4610 * giscanner/gidlwriter.py:
4611 * giscanner/gobjecttreebuilder.py:
4612 * tools/g-ir-scanner:
4613 Add a --include argument to include types from other idls.
4614 Add a minimalistic GIDL parser (just objects for now)
4615 Implement resolving of external type references and use it to
4616 resolve parent types, argument types and return types.
4618 2008-04-21 Johan Dahlin <johan@gnome.org>
4620 * giscanner/gidlwriter.py:
4621 * giscanner/gobjecttreebuilder.py:
4622 * giscanner/treebuilder.py:
4623 Add support for properties.
4624 Refactor Class/Interface support a bit, to share more code and
4625 always initialize their method attribute to an empty list.
4627 2008-04-21 Johan Dahlin <johan@gnome.org>
4629 * giscanner/cgobject.py:
4630 Add a workaround for a glib bug interface introspection bug
4631 (object_interface_list_properties, object_class_list_properties):
4632 Cast the return value to GParamSpec.
4634 * tests/parser/Foo-expected.gidl: Update
4635 * tests/parser/foo.c: Add a string property
4637 * giscanner/gobjecttreebuilder.py:
4638 After stripping namespaces, remove the original
4639 item to avoid duplication (GtkButton struct and Button object)
4641 2008-04-21 Johan Dahlin <johan@gnome.org>
4643 * giscanner/gobjecttreebuilder.py:
4644 * giscanner/treebuilder.py:
4645 Strip namespaces before objects, so we'll export
4646 GtkButton as Button in the gtk namespace
4648 2008-04-21 Johan Dahlin <johan@gnome.org>
4650 * giscanner/gidlwriter.py:
4651 * giscanner/gobjecttreebuilder.py:
4652 * giscanner/treebuilder.py:
4653 Add constructors for object/boxed types.
4655 2008-04-21 Johan Dahlin <johan@gnome.org>
4657 * giscanner/gidlwriter.py:
4658 * giscanner/gobjecttreebuilder.py:
4659 Add support for boxed types
4661 2008-04-21 Johan Dahlin <johan@gnome.org>
4663 * giscanner/giscannermodule.c: Mark structures as const,
4664 wrap SourceType.const_string.
4666 * tests/parser/foo-object.h: Add a couple of constants.
4668 * giscanner/gidlwriter.py:
4669 * giscanner/gobjecttreebuilder.py:
4670 * giscanner/treebuilder.py:
4671 Add basic support for interfaces
4673 * tools/g-ir-scanner:
4674 Add -o/--output for writing to a file
4676 2008-04-21 Havoc Pennington <hp@redhat.com>
4678 * TODO: add some C API wishlist items I could think of quickly
4680 2008-04-21 Johan Dahlin <jdahlin@async.com.br>
4682 * giscanner/gidlwriter.py:
4683 * giscanner/xmlwriter.py:
4684 Add a simple api for writing tags which can be used
4685 with the new 'with statement' in python 2.5
4687 2008-04-21 Johan Dahlin <johan@gnome.org>
4689 * giscanner/gobjecttreebuilder.py:
4690 Strip namespace and object prefix from method names.
4692 2008-04-21 Johan Dahlin <johan@gnome.org>
4694 * tools/g-ir-scanner (main): Add --pkg option to pass in
4695 pkg-config modules to get cflags from.
4697 * giscanner/gidlwriter.py (GIDLWriter._write_method):
4698 Avoid duplication, reuse function writer for methods.
4700 2008-04-21 Johan Dahlin <jdahlin@async.com.br>
4702 * giscanner/gidlwriter.py:
4703 * giscanner/gobjecttreebuilder.py:
4704 * giscanner/treebuilder.py:
4705 * tools/g-ir-scanner:
4706 Resolve libtool .la files.
4707 Strip name spaces for methods.
4708 Add function symbols
4710 2008-04-20 Johan Dahlin <jdahlin@async.com.br>
4712 * giscanner/cgobject.py:
4713 * giscanner/gidlwriter.py:
4714 * giscanner/gobjecttreebuilder.py:
4715 * giscanner/treebuilder.py:
4716 Add support for classes and methods
4718 2008-04-20 Johan Dahlin <johan@gnome.org>
4720 * giscanner/gidlwriter.py:
4721 * giscanner/gobjecttreebuilder.py:
4722 * giscanner/odict.py:
4723 Avoid conflicts, keep the output ordered similar to
4724 the order of the input.
4725 Add a simple ordered dictionary implemenation
4727 2008-04-19 Johan Dahlin <johan@gnome.org>
4729 * giscanner/cgobject.py:
4730 * giscanner/gidlwriter.py:
4731 * giscanner/gobjecttreebuilder.py:
4732 * tools/g-ir-scanner:
4733 Start introspecting get-type functions.
4734 Implement support for GLib/GFlags GTypes.
4735 Add a ctype based GObject binding.
4737 2008-04-18 Johan Dahlin <jdahlin@async.com.br>
4739 * giscanner/gidlwriter.py:
4740 * giscanner/xmlwriter.py:
4741 * tools/g-ir-scanner:
4742 Add a simplistic gidl writer, which can't do too much.
4744 2008-04-18 Johan Dahlin <johan@gnome.org>
4746 * giscanner/sourcescanner.py:
4747 * giscanner/treebuilder.py:
4748 * tools/g-ir-scanner:
4749 split tree building and source scanning interface to separate files.
4751 2008-04-18 Johan Dahlin <johan@gnome.org>
4753 * tools/g-ir-scanner (Parameter.__init__): Start constructing
4755 - Add support for struct/parameter/return, start parsing of ctypes
4757 * giscanner/giscannermodule.c: wrap GISourceType.child_list and
4760 2008-03-31 Johan Dahlin <johan@gnome.org>
4762 * tools/g-ir-scanner:
4763 Start to build abstract syntax node of scanned sources.
4764 Add support for cpp options.
4766 2008-03-27 Johan Dahlin <johan@gnome.org>
4768 * giscanner/giscannermodule.c:
4769 * giscanner/scannerlexer.l:
4770 * giscanner/sourcescanner.c:
4771 * tools/g-ir-scanner:
4773 Add simple pre-processor using subprocess and a PIPE.
4774 Change the parse_file apis to accept a file descriptor.
4776 2008-03-25 Johan Dahlin <johan@gnome.org>
4778 * giscanner/__init__.py:
4779 * tools/g-ir-scanner:
4780 Fix a typo and add an example python test program.
4782 2008-03-25 Johan Dahlin <johan@gnome.org>
4784 * giscanner/__init__.py:
4785 * giscanner/giscannermodule.c:
4786 * giscanner/sourcescanner.c:
4787 * giscanner/sourcescanner.h:
4788 Add constants and wrap a few more SymbolType fields
4790 2008-03-25 Johan Dahlin <johan@gnome.org>
4794 * giscanner/__init__.py:
4795 * giscanner/giscannermodule.c:
4796 * giscanner/Makefile.am:
4798 Add initial python bindings for the scanner and
4799 depend on python 2.5.
4801 2008-03-25 Johan Dahlin <johan@gnome.org>
4805 * giscanner/Makefile.am:
4806 * giscanner/sourcescanner.c:
4807 * giscanner/sourcescanner.h:
4808 * tools/Makefile.am:
4809 * tools/grealpath.h:
4810 * tools/sourcescanner.c:
4811 * tools/sourcescanner.h:
4813 Move the scanner to a separate library.
4815 2008-03-23 Johan Dahlin <johan@gnome.org>
4817 * tools/Makefile.am:
4820 * tools/scannerlexer.l:
4821 * tools/scannerparser.y:
4822 * tools/sourcescanner.c:
4823 * tools/sourcescanner.h:
4824 Split out the source scanner from the generator.
4825 Rename the symbols used in the scanner to use the gi_ prefix.
4826 This should make it possible to use the raw C parser from
4829 2008-03-23 Johan Dahlin <johan@gnome.org>
4831 * tests/parser/Makefile.am (utility.gidl):
4832 * tests/parser/utility-expected.gidl:
4833 Pass in the gobject.gidl since we're defining a GObject.
4835 2008-03-12 Johan Dahlin <johan@gnome.org>
4837 * relaxng/relaxng.rng:
4838 Add a releaxng in relaxng we can use to validate the relaxngs
4841 2008-03-12 Jürg Billeter <j@bitron.ch>
4843 * tools/scanner.c: (g_igenerator_new):
4844 * tools/scannerparser.y:
4845 Fix compiler warnings.
4847 2008-03-12 Jürg Billeter <j@bitron.ch>
4851 * tools/scannerparser.y:
4852 Start fixing memory management in g-idl-scanner.
4854 2008-03-12 Rob Taylor <rob.taylor@codethink.co.uk>
4856 * tools/gidlcompilercontext.c: (write_compiled):
4857 Fix critical warning when no shlib passed to g-idl-compiler.
4859 2008-03-12 Johan Dahlin <johan@gnome.org>
4861 * tests/parser/utility-expected.gidl:
4862 * tests/parser/utility.h:
4863 Add a get_type-function, so the scanner actually
4864 parses it as an object.
4866 2008-03-12 Johan Dahlin <johan@gnome.org>
4868 * tools/gidlwriter.c (function_generate): Add missing trailing quote.
4871 * tests/parser/Foo-expected.gidl:
4872 * tests/parser/Makefile.am:
4873 * tests/parser/foo-object.h:
4874 * tests/parser/foo.c:
4875 * tests/parser/utility-expected.gidl:
4876 * tests/parser/utility.c:
4877 * tests/parser/utility.h:
4879 Add a new gidl test. 'utility.gidl', which is used to be able
4880 to test external type references. Add a reference to UtilityObject*
4883 2008-03-11 Johan Dahlin <johan@gnome.org>
4887 Remove most global variables
4889 2008-03-11 Philip Van Hoof <me@pvanhoof.be>
4891 * tools/scannerlexer.l:
4893 * tests/parser/Foo-expected.gidl:
4894 * tests/parser/foo.c:
4895 * tests/parser/Makefile.am:
4896 * tests/parser/foo-object.h:
4898 Added a few extra tests. Which resulted in finding a few
4899 bugs. Which resulted in me fixing those bugs
4901 2008-03-11 Rob Taylor <rob.taylor@codethink.co.uk>
4903 * tools/gidlcompilercontext.c: (g_idl_compiler_write_dir_entry),
4904 (g_idl_compiler_write_xref_entry), (g_idl_compiler_add_xref):
4905 Add some comments for strings into generated output for
4908 2008-03-11 Rob Taylor <rob.taylor@codethink.co.uk>
4910 * tools/gidlcompilercontext.c: (write_compiled):
4911 Write out the shlibs variable before writing out the strings
4912 length. Fixes compiler warning when using '-l' flag with
4915 2008-03-11 Johan Dahlin <johan@gnome.org>
4917 * tests/parser/Foo-expected.gidl:
4918 * tests/parser/foo-object.h:
4921 * tools/scannerlexer.l:
4922 Add support for parsing return arguments. Add support for
4923 caller-owns return types.
4924 Patch by Philip Van Hoof.
4926 * tools/scannerparser.y:
4927 Remove parsing of the @deprecated syntax used in headers.
4928 We will support gtk-doc deprecation in the future instead.
4930 2008-03-11 Johan Dahlin <johan@gnome.org>
4932 * tools/compiler.c (main): Coding style fixes
4934 2008-03-10 Johan Dahlin <johan@gnome.org>
4937 Add GCOV_LIBS to GILIBS
4939 2008-03-10 Johan Dahlin <johan@gnome.org>
4941 * tests/parser/Foo-expected.gidl:
4942 * tests/parser/foo.c:
4943 Rename null-ok to direction=out
4945 2008-03-10 Philip Van Hoof <me@pvanhoof.be>
4947 reviewed and extensively tested by Johan
4949 * tests/parser/Foo-expected.gidl:
4950 * tests/parser/foo-object.h:
4951 * tests/parser/foo.c:
4954 * tools/gidlwriter.c:
4957 * tools/scannerlexer.l:
4958 * tools/scannerparser.y:
4960 Add support for scanning for gtk-doc comments inside
4961 C source files. Add tests
4963 2008-03-10 Johan Dahlin <johan@gnome.org>
4965 * tests/parser/Makefile.am:
4966 * tests/parser/foo.c:
4969 * tools/scannerparser.y:
4970 Add an api to lex filenames.
4971 Lex all source .c files passed in on the command line.
4972 Scan sources in a test and a couple of private structures
4973 which should not be included in the generated gidl
4975 2008-03-10 Johan Dahlin <johan@gnome.org>
4977 * tests/invoke/Makefile.am: Make the generated metadata
4978 depend on the g-idl-compiler
4980 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4982 * tools/gidlmodule.c
4983 * tools/gidlmodule.h
4986 Remove the old g-idl-compiler code.
4989 2008-02-22 Mark Doffman <mark.doffman@codethink.co.uk>
4991 * tools/quote-file.sh
4994 Move to using the 'C' struct compiler code.
4996 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4998 * girepository/ginfo.c
5000 Change the way that external references with no namespace
5001 are dealt with. External references with no namespace
5002 are placed into the XML as-if they are a local reference.
5003 This is temporary, but helps with roundtrip tests.
5005 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
5007 * girepository/ginfo.c
5008 Add the ability to get the value of a constant of
5009 type TYPE_TAG_SYMBOL. In the case of a symbol the value
5010 is provided as a string.
5012 This would deal properly with:
5013 typedef char* random;
5014 const random = "A string";
5016 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
5018 * girepository/ginfo.c
5019 * girepository/girepository.h
5021 Add a function to check if an enum is registered or not.
5022 Previously anything testing this relied on the g-type
5023 string offset having a value of 0.
5025 * girepository/gmetadata.c
5026 * girepository/gmetadata.h
5028 Remove unneccesary or erroneous checks. There were two
5029 metadata validation checks which made sure that the blob
5030 sizes were the same as some magic numbers compiled into the code.
5031 This is wrong as it breaks any forwards compatibility that may
5034 Checks were also present that made sure that unregistered type
5035 blobs had a value of 0 in the g-type offset field. This is
5036 unneccessary. If a type blob is unregistered then any value
5037 in its g-type field is simply invalid.
5039 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
5041 * girepository/ginfo.c
5042 * girepository/gmetadata.c
5043 * girepository/gmetadata.h
5045 Change the metadata format to have a standard header
5046 for all the type blobs. Merge the SimpleTypeBlob
5047 and InterfaceTypeBlob into a union. A union of these
5048 two blobs existed previously but was not explicit
5049 in the metadata format.
5051 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
5053 * tools/gidlcompilercontext.c
5054 * tools/gidlcompilercontext.h
5055 * tools/gidlcompilerentrynode.c
5056 * tools/gidlcompilerentrynode.h
5057 * tools/gidlcompilertypenode.c
5058 * tools/gidlcompilertypenode.h
5060 Add code to compile a tree of GIdlNodes to
5061 a 'C' struct representing the metadata.
5062 This is to aid cross-compiling. Previously
5063 the g-idl-compiler created a binary blob with
5064 data written in the byte order and alignment
5065 of the tool rather than the intended target.
5067 Cleaned up and improved by Johan and Robert :-)
5069 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
5071 * girepository/ginvoke.c
5072 * girepository/girepository.h
5073 * girepository/gmetadata.c
5074 * girepository/gmetadata.h
5076 * tools/gidlparser.c
5077 Modify TYPE_TAG_INTERFACE to TYPE_TAG_SYMBOL
5078 to avoid confusion with the interface blob.
5081 * tools/gidlparser.c
5082 Remove magic numbers and replace with type-tag
5083 enumeration symbols.
5085 * girepository/gmetadata.c
5086 Add validate declaration.
5088 2008-03-10 Jürg Billeter <j@bitron.ch>
5090 * tools/gidlparser.c: (parse_type_internal):
5091 * tools/scannerlexer.l:
5092 * tools/scannerparser.y:
5093 Support C99 _Bool type in scanner.
5095 2008-03-10 Jürg Billeter <j@bitron.ch>
5097 * tests/parser/Foo-expected.gidl:
5098 * tests/parser/foo-object.h:
5099 * tests/parser/foo.c: (foo_enum_method):
5100 * tools/scanner.c: (g_igenerator_process_function_symbol):
5101 Don't skip functions that are defined in the namespace of a type
5102 that doesn't support methods, as for example enums.
5104 2008-03-10 Johan Dahlin <johan@gnome.org>
5106 * gidl.dtd: Remove, we're using relaxng for now
5108 * tests/parser/Foo-expected.gidl:
5109 * tests/parser/foo-object.h:
5110 * tests/parser/foo.c:
5111 Rename the enum/flags get_type functions to include the whole type.
5113 2008-03-08 Marc-Andre Lureau <marcandre.lureau@gmail.com>
5115 * tools/gidlwriter.c (enum_generate): added "type-name",
5116 "get-type" and "deprecated" missing arguments.
5117 * tests/parser/Foo-expected.gidl:
5118 * tests/parser/foo-object.h: test enum type, and no type.
5120 2008-03-06 Johan Dahlin <jdahlin@async.com.br>
5123 Consistent checks, add missing 'test'
5125 2008-03-05 Havoc Pennington <hp@redhat.com>
5127 * configure.ac: Take advantage of a libffi.pc if one exists, as it
5128 does on Fedora 8. Make libffi a hard requirement, since it was in
5129 practice anyway (was not really conditional in the code or
5130 makefile, only in configure).
5132 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
5134 reviewed by: Rob Taylor <rob.taylor@codethink.co.uk>
5135 reviewed by: Johan Dahlin <johan@gnome.org>
5137 * tests/Makefile.am:
5138 * tests/roundtrips.sh:
5139 Modify the roundtrips test so that they do not use the
5140 --raw option of the gidl compiler but instead compile a
5141 shared library to use with g_module.
5143 * tests/invoke/Makefile.am:
5144 * tests/invoke/invoke.c:
5145 Modify the invoke tests to build a shared library rather
5146 than use the --raw option.
5148 * tests/invoke/invoke-namespace-find.sh: Removed:
5149 Noone knows why this was here, so removed.
5151 2008-02-19 Rob Taylor <rob.taylor@codethink.co.uk>
5153 * tools/scanner.c: (g_igenerator_process_function_symbol):
5154 Move g_idl_node_can_have_member test later, as it broke spotting
5155 get_type's for nodes that can't have members.
5157 2008-02-18 Rob Taylor <rob.taylor@codethink.co.uk>
5160 * tools/gidlnode.c: (g_idl_node_can_have_member):
5161 Add g_idl_node_can_have_member.
5163 * tools/scanner.c: (g_igenerator_process_function_symbol):
5164 Use g_idl_node_can_have_member to test if we should add a function
5165 as a member of the type node.
5167 2008-02-18 Rob Taylor <rob.taylor@codethink.co.uk>
5169 * gidl/GLib.gidl: Renamed to gidl/gobject-2.0.gidl:
5171 * tests/parser/Makefile.am:
5172 Rename GLib.gidl to gobject-2.0.gidl and install in /usr/share/gidl.
5174 2008-02-18 Rob Taylor <rob.taylor@codethink.co.uk>
5176 * tools/scanner.c: (main):
5177 Ignore -pthread when passed to g-idl-scanner.
5179 2008-02-18 Rob Taylor <rob.taylor@codethink.co.uk>
5181 * tools/grealpath.h: Added:
5182 * tools/scanner.c: (main):
5183 * tools/scannerlexer.l:
5184 * tools/Makefile.am:
5185 Always use absolute paths with symbolic links resolved when
5186 comparing filenames.
5188 2008-02-18 Rob Taylor <rob.taylor@codethink.co.uk>
5190 * gobject-introspection.pc.in:
5191 Provide variables for g-idl-parser, scanner and compiler in the
5194 2008-02-13 Rob Taylor <rob.taylor@codethink.co.uk>
5197 * girepository/Makefile.am:
5198 * tools/Makefile.am:
5199 Rename GCOV_SOURCES to GCOVSOURCES to top automake complaining.
5201 2008-02-10 Johan Dahlin <johan@gnome.org>
5203 * tests/parser/Foo-expected.gidl:
5204 * tests/parser/foo-object.h:
5205 * tests/parser/foo.c: (foo_boxed_copy), (foo_boxed_free),
5206 (foo_boxed_get_type), (foo_boxed_new), (foo_boxed_method):
5209 2008-02-10 Johan Dahlin <johan@gnome.org>
5211 * tests/parser/Foo-expected.gidl:
5212 * tests/parser/foo-object.h:
5213 * tests/parser/foo.c: (foo_enum_get_type), (foo_flags_get_type):
5214 Add enum and flags test.
5216 2008-02-10 Johan Dahlin <johan@gnome.org>
5220 * girepository/Makefile.am:
5221 Make 'make distcheck' work again.
5223 2008-02-10 Johan Dahlin <johan@gnome.org>
5225 * m4/Makefile.am (EXTRA_DIST): its called as-compiler-flag.m4,
5228 * tests/parser/Makefile.am: Only create Foo.gidl when running make
5229 check, eg exclude it from BUILT_SOURCES.
5231 2008-02-08 Rob Taylor <rob.taylor@codethink.co.uk>
5236 * girepository/Makefile.am:
5237 * m4/Makefile.am: Added:
5238 * m4/as-compiler-flag.m4: Added:
5239 * m4/gcov.m4: Added:
5240 * tools/Makefile.am:
5241 Add ability to generate a coverage report.
5242 Adds configure option --enable-gcov and make rule 'check-coverage'.
5244 2008-02-08 Rob Taylor <rob.taylor@codethink.co.uk>
5248 * gidl/Makefile.am: Added:
5249 * girepository/Makefile.am: Added:
5250 * src/Makefile.am: Renamed to tools/Makefile.am:
5251 * src/compiler.c: Renamed to tools/compiler.c:
5252 * src/g-idl-offsets.pl: Renamed to tools/g-idl-offsets.pl:
5253 * src/generate.c: Renamed to tools/generate.c:
5254 * src/gidlmodule.c: Renamed to tools/gidlmodule.c:
5255 * src/gidlmodule.h: Renamed to tools/gidlmodule.h:
5256 * src/gidlnode.c: Renamed to tools/gidlnode.c:
5257 * src/gidlnode.h: Renamed to tools/gidlnode.h:
5258 * src/gidlparser.c: Renamed to tools/gidlparser.c:
5259 * src/gidlparser.h: Renamed to tools/gidlparser.h:
5260 * src/gidlwriter.c: Renamed to tools/gidlwriter.c:
5261 * src/gidlwriter.h: Renamed to tools/gidlwriter.h:
5262 * src/ginfo.c: Renamed to girepository/ginfo.c:
5263 * src/ginvoke.c: Renamed to girepository/ginvoke.c:
5264 * src/girepository.c: Renamed to girepository/girepository.c:
5265 * src/girepository.h: Renamed to girepository/girepository.h:
5266 * src/gmetadata.c: Renamed to girepository/gmetadata.c:
5267 * src/gmetadata.h: Renamed to girepository/gmetadata.h:
5268 * src/scanner.c: Renamed to tools/scanner.c:
5269 * src/scanner.h: Renamed to tools/scanner.h:
5270 * src/scannerlexer.l: Renamed to tools/scannerlexer.l:
5271 * src/scannerparser.y: Renamed to tools/scannerparser.y:
5272 * tests/invoke/Makefile.am:
5273 Split src/ into girepository/ and tools/
5277 * girepository/Makefile.am:
5278 * tests/Makefile.am:
5279 * tests/invoke/Makefile.am:
5280 * tests/parser/Makefile.am:
5281 * tests/roundtrips.sh:
5282 * tools/Makefile.am:
5283 Make distcheck work.
5285 2008-02-04 Rob Taylor <rob.taylor@codethink.co.uk>
5287 * tests/invoke/invoke.c: (main):
5288 * tests/invoke/testfns.c: (test6), (test7):
5289 * tests/invoke/testfns.xml:
5290 Add tests for invokation with a GList argument.
5291 Also tests caller-owns return values.
5293 2008-02-04 Rob Taylor <robtaylor@floopily.org>
5296 Add some documentation for GICallableInfo
5298 2008-02-01 Mark Doffman <mark.doffman@codethink.co.uk>
5301 Correct syntax errors in the DTD file.
5303 * relaxng/c-types.xml:
5304 * relaxng/g-types.xml:
5306 Add a RelaxNG specification for the GObject Introspection XML data.
5307 The Specification has validated all of the test files.
5309 2008-01-25 Rob Taylor <robtaylor@floopily.org>
5311 * tests/roundtrips.sh:
5312 * tests/struct.test:
5313 Add roundtrip tests for structs.
5315 2008-01-11 Johan Dahlin <johan@gnome.org>
5317 * src/scanner.c (g_igenerator_process_function_symbol):
5318 Refactor out g_idle_node_add_member.
5319 (create_node_from_gtype, create_node_from_ctype):
5320 Use case instead of if...else
5321 (get_type_from_type_id):
5322 Rename to create_node_from_gtype
5323 (get_type_from_ctype):
5324 Rename to create_node_from_ctype
5326 Rename ginode -> node, gitype -> type, gifunc -> func.
5328 * src/gidlnode.c (g_idl_node_add_member, g_idl_node_cmp):
5329 Two new functions, refactor out of scanner.c
5331 * src/scanner.c: (g_igenerator_process_function_symbol):
5332 * src/scannerlexer.l:
5333 Do not save the content of the deprecated variable, only
5336 2008-01-11 Johan Dahlin <johan@gnome.org>
5338 * tests/parser/foo-object.h: Add a couple of comment parser tests.
5340 2008-01-11 Jürg Billeter <j@bitron.ch>
5342 * src/scannerlexer.l:
5343 Fix GTK-Doc parsing.
5345 2008-01-11 Jürg Billeter <j@bitron.ch>
5347 * src/scannerlexer.l:
5348 Fix GTK-Doc parsing.
5350 2008-01-11 Jürg Billeter <j@bitron.ch>
5352 * src/scanner.c: (lookup_symbol):
5353 Return unresolved name if we find unknown symbol.
5355 2008-01-11 Jürg Billeter <j@bitron.ch>
5357 * src/scanner.c: (g_igenerator_generate):
5358 Initialize GObject to fix scanning interface properties.
5360 * tests/parser/Foo-expected.gidl:
5361 * tests/parser/foo-object.h:
5362 * tests/parser/foo.c: (foo_interface_get_type):
5363 Test interfaces with GObject prerequisite.
5365 * tests/parser/Makefile.am:
5366 Set G_DEBUG=fatal_warnings to abort test on warnings and criticals.
5368 2007-12-27 Johan Dahlin <johan@gnome.org>
5370 * src/scannerlexer.l:
5371 Parse gtk-doc comments.
5373 * src/gidlwriter.c: (function_generate):
5374 Reorganize, avoid duplication and add support for
5375 writing deprecated functions.
5377 * src/scannerparser.y:
5379 Add new structure CDirective and functions to create/free them.
5381 * src/scanner.c: (g_igenerator_process_function_symbol),
5382 (g_igenerator_process_unregistered_struct_typedef),
5383 (g_igenerator_process_struct_typedef),
5384 (g_igenerator_process_union_typedef),
5385 (g_igenerator_process_enum_typedef),
5386 (g_igenerator_process_function_typedef), (g_igenerator_add_symbol),
5387 (g_igenerator_start_preprocessor):
5388 Parse @deprecated directive for functions.
5389 Remove some more C99isms.
5390 Send in -C to cpp to avoid stripping comments.
5392 * tests/parser/foo-object.h:
5393 * tests/parser/Foo-expected.gidl:
5394 Add deprecated directive
5396 2007-12-27 Johan Dahlin <johan@gnome.org>
5398 * src/scannerlexer.l (intsuffix): Add emacs mode line and
5399 escape ' and " so it looks more like C.
5402 Unlink temporary file used.
5404 2007-12-27 Johan Dahlin <johan@gnome.org>
5406 * src/scanner.c: (g_igenerator_new), (g_igenerator_free),
5407 (g_igenerator_start_preprocessor), (main):
5409 * src/scannerparser.y:
5410 Plug a couple of simple memory leaks.
5412 2007-12-27 Johan Dahlin <johan@gnome.org>
5414 * src/scanner.c: (g_igenerator_parse_macros),
5415 (g_igenerator_start_preprocessor), (g_igenerator_set_verbose),
5418 * src/scannerparser.y:
5419 * tests/parser/Makefile.am:
5421 Improve error reporting, return when the preprocessor fails.
5422 Add a verbose parameter, to aid debugging.
5423 Revert to using a temporary file to communicate between the
5424 preprocessor and the parser, because we need to wait for
5425 the exit code from the pre-processor before starting to parse.
5427 2007-12-16 Johan Dahlin <jdahlin@async.com.br>
5429 * src/Makefile.am: Rename clexer.l to scannerlexer.l and
5430 cparser.y to scannerparser.y
5432 2007-12-11 Johan Dahlin <johan@gnome.org>
5436 * src/scanner.c: (g_igenerator_new):
5438 Get rid of the global the_generator variable.
5440 2007-12-10 Johan Dahlin <johan@gnome.org>
5442 * src/scanner.c (main): Add an output option,
5443 add checks for required parameters
5446 set BUILD_SOURCES and CLEANFILES properly
5448 * src/gidlwriter.c: (g_writer_write_inline), (g_writer_write),
5449 (g_writer_write_indent), (g_writer_write_unindent),
5450 (field_generate), (value_generate), (constant_generate),
5451 (property_generate), (function_generate), (vfunc_generate),
5452 (signal_generate), (interface_generate), (struct_generate),
5453 (union_generate), (boxed_generate), (enum_generate),
5454 (node_generate), (g_writer_write_module), (g_idl_writer_save_file):
5456 * src/scanner.c: (g_igenerator_generate):
5458 * src/scannerwriter.c:
5460 Refactor scannerwriter to only be tied to a GIdlModule and move
5461 it (again!) to gidlwriter.c. Change the writer function to take
5464 2007-12-10 Johan Dahlin <johan@gnome.org>
5467 * src/scanner.c: (g_igenerator_generate):
5469 * src/scannerwriter.c: (g_igenerator_write_inline),
5470 (g_igenerator_write), (g_igenerator_write_indent),
5471 (g_igenerator_write_unindent), (field_generate), (value_generate),
5472 (constant_generate), (property_generate), (function_generate),
5473 (vfunc_generate), (signal_generate), (interface_generate),
5474 (struct_generate), (union_generate), (boxed_generate),
5475 (enum_generate), (node_generate), (module_generate),
5476 (g_scanner_write_file):
5478 Move the scanner gidl writing to a separate source file.
5480 2007-12-10 Johan Dahlin <johan@gnome.org>
5485 Move over all CType construction functions.
5487 * tests/parser/Makefile.am:
5488 Be verbose when printing parsing tests results.
5490 2007-12-10 Johan Dahlin <johan@gnome.org>
5492 * src/scanner.c (g_igenerator_start_preprocessor): Refactor
5493 preprocessor handling to here. Start cpp insteado of cc -E,
5494 always include -U__GNUC__, since it's specific to the preprocessor
5497 * tests/parser/Makefile.am (check-local): Silent diff and skip
5498 -U__GNUC__ which is always defined now
5500 2007-12-10 Johan Dahlin,,, <jdahlin@plasttroll>
5502 reviewed by: <delete if not using a buddy>
5504 * src/scanner.c: (g_igenerator_start_preprocessor), (main):
5505 * tests/parser/Makefile.am:
5507 2007-12-09 Johan Dahlin <johan@gnome.org>
5510 Use GOption for command line options.
5511 (g_igenerator_new, main): Simplify constructor and they way
5512 parameters are passed into it.
5518 * src/gen-introspect.c:
5519 * src/gen-introspect.h:
5521 Rename gen-introspect.[ch] to scanner.[ch]
5523 2007-12-09 Johan Dahlin <johan@gnome.org>
5527 * src/Makefile.am: Rename gen-introspect to g-idl-scanner,
5528 don't make the repository library and the other utilites link against
5531 * src/gen-introspect.c: (g_igenerator_create_object),
5532 (g_igenerator_create_interface), (g_igenerator_create_boxed),
5533 (g_igenerator_create_enum), (g_igenerator_create_flags),
5534 (g_igenerator_process_module_symbol),
5535 (g_igenerator_process_module), (g_igenerator_generate), (main):
5536 * src/gen-introspect.h:
5537 Refactor g_igenerator_process_types into smaller pieces.
5539 * tests/parser/Makefile.am:
5540 Depend on the gen-introspect binary
5542 2007-12-09 Johan Dahlin <johan@gnome.org>
5544 * src/gen-introspect.c (g_igenerator_process_types):
5545 Break into smaller pieces, one for each generated node type.
5547 2007-12-08 Johan Dahlin <johan@gnome.org>
5549 * src/gen-introspect.c: (g_igenerator_process_types),
5550 (g_igenerator_add_module):
5551 * tests/parser/Foo-expected.gidl:
5552 * tests/parser/foo-object.h:
5553 * tests/parser/foo.c: (foo_subobject_class_init),
5554 (foo_subobject_init):
5556 Add a subobject test and make sure to register defined classes
5557 in the lookup symbol hash table.
5559 2007-12-08 Johan Dahlin <johan@gnome.org>
5563 * src/gen-introspect.c: (g_igenerator_new), (lookup_symbol),
5564 (g_igenerator_process_types), (g_igenerator_add_module),
5565 (g_igenerator_add_include_idl), (main):
5566 * src/gen-introspect.h:
5567 * tests/parser/Makefile.am:
5568 * tests/parser/Foo-expected.gidl:
5570 Change the gen-introspect to generate namespaced module names,
5571 such as GLib.Object instead of GObject.
5572 Add a GLib.gidl which introduces GLib.Object and GLib.InitiallyUnowned,
5573 add a --include-idl parameter to gen-introspect,
5574 and update the parser test.
5576 2007-12-08 Johan Dahlin <johan@gnome.org>
5578 * src/gen-introspect.c:
5579 Move main to the end of the file and attempt to make it valid
5582 * tests/parser/Makefile.am (BUILT_SOURCES): Remove .repo here,
5583 we're not quite ready to generate metadata yet.
5588 Add a simple gen-introspect parser test
5590 2007-12-06 Gustavo J. A. M. Carneiro <gjc@gnome.org>
5592 reviewed by: Johan Dahlin <johan@gnome.org>
5595 * gobject-introspection.pc.in:
5597 * src/compiler.c: (format_output), (write_out_metadata), (main):
5598 * src/gen-introspect.c: (main):
5599 * src/gen-introspect.h:
5600 * src/generate.c: (write_callable_info), (write_repository),
5601 (load_metadata), (main):
5602 * src/gidlmodule.c: (g_idl_module_new),
5603 (g_idl_module_build_metadata):
5605 * src/gidlparser.c: (start_element_handler):
5606 * src/ginfo.c: (g_info_new), (g_info_from_entry),
5607 (g_base_info_get_name), (g_base_info_get_namespace),
5608 (g_base_info_is_deprecated), (g_base_info_get_annotation),
5609 (g_base_info_get_metadata), (g_function_info_get_symbol),
5610 (g_function_info_get_flags), (g_function_info_get_property),
5611 (g_function_info_get_vfunc), (signature_offset), (g_type_info_new),
5612 (g_callable_info_may_return_null),
5613 (g_callable_info_get_caller_owns), (g_callable_info_get_n_args),
5614 (g_callable_info_get_arg), (g_arg_info_get_direction),
5615 (g_arg_info_is_return_value), (g_arg_info_is_dipper),
5616 (g_arg_info_is_optional), (g_arg_info_may_be_null),
5617 (g_arg_info_get_ownership_transfer), (g_type_info_is_pointer),
5618 (g_type_info_get_tag), (g_type_info_get_param_type),
5619 (g_type_info_get_interface), (g_type_info_get_array_length),
5620 (g_type_info_is_zero_terminated),
5621 (g_type_info_get_n_error_domains), (g_type_info_get_error_domain),
5622 (g_error_domain_info_get_quark), (g_error_domain_info_get_codes),
5623 (g_value_info_get_value), (g_field_info_get_flags),
5624 (g_field_info_get_size), (g_field_info_get_offset),
5625 (g_registered_type_info_get_type_name),
5626 (g_registered_type_info_get_type_init),
5627 (g_struct_info_get_n_fields), (g_struct_info_get_field),
5628 (g_struct_info_get_n_methods), (g_struct_info_get_method),
5629 (find_method), (g_struct_info_find_method),
5630 (g_enum_info_get_n_values), (g_enum_info_get_value),
5631 (g_object_info_get_parent), (g_object_info_get_type_name),
5632 (g_object_info_get_type_init), (g_object_info_get_n_interfaces),
5633 (g_object_info_get_interface), (g_object_info_get_n_fields),
5634 (g_object_info_get_field), (g_object_info_get_n_properties),
5635 (g_object_info_get_property), (g_object_info_get_n_methods),
5636 (g_object_info_get_method), (g_object_info_find_method),
5637 (g_object_info_get_n_signals), (g_object_info_get_signal),
5638 (g_object_info_get_n_vfuncs), (g_object_info_get_vfunc),
5639 (g_object_info_get_n_constants), (g_object_info_get_constant),
5640 (g_interface_info_get_n_prerequisites),
5641 (g_interface_info_get_prerequisite),
5642 (g_interface_info_get_n_properties),
5643 (g_interface_info_get_property), (g_interface_info_get_n_methods),
5644 (g_interface_info_get_method), (g_interface_info_find_method),
5645 (g_interface_info_get_n_signals), (g_interface_info_get_signal),
5646 (g_interface_info_get_n_vfuncs), (g_interface_info_get_vfunc),
5647 (g_interface_info_get_n_constants),
5648 (g_interface_info_get_constant), (g_property_info_get_flags),
5649 (g_signal_info_get_flags), (g_signal_info_get_class_closure),
5650 (g_signal_info_true_stops_emit), (g_vfunc_info_get_flags),
5651 (g_vfunc_info_get_offset), (g_vfunc_info_get_signal),
5652 (g_constant_info_get_value), (g_union_info_get_n_fields),
5653 (g_union_info_get_field), (g_union_info_get_n_methods),
5654 (g_union_info_get_method), (g_union_info_is_discriminated),
5655 (g_union_info_get_discriminator_offset),
5656 (g_union_info_get_discriminator):
5657 * src/ginvoke.c: (g_function_info_invoke):
5658 * src/girepository.c: (g_irepository_register),
5659 (g_irepository_unregister), (g_irepository_get_default),
5660 (count_interfaces), (g_irepository_get_n_infos), (find_interface),
5661 (g_irepository_get_info), (g_irepository_find_by_name),
5662 (g_irepository_get_shared_library),
5663 (g_irepository_build_search_path), (g_irepository_register_file),
5664 (g_irepository_error_quark):
5665 * src/girepository.h:
5666 * src/gmetadata.c: (g_metadata_get_dir_entry),
5667 (g_metadata_check_sanity), (validate_header),
5668 (validate_array_type_blob), (validate_iface_type_blob),
5669 (validate_param_type_blob), (validate_error_type_blob),
5670 (validate_type_blob), (validate_arg_blob),
5671 (validate_signature_blob), (validate_function_blob),
5672 (validate_callback_blob), (validate_constant_blob),
5673 (validate_value_blob), (validate_field_blob),
5674 (validate_property_blob), (validate_signal_blob),
5675 (validate_vfunc_blob), (validate_struct_blob),
5676 (validate_enum_blob), (validate_object_blob),
5677 (validate_interface_blob), (validate_errordomain_blob),
5678 (validate_union_blob), (validate_blob), (validate_directory),
5679 (validate_annotations), (g_metadata_validate), (_g_metadata_init),
5680 (g_metadata_new_from_memory), (g_metadata_new_from_const_memory),
5681 (g_metadata_new_from_mapped_file), (g_metadata_free),
5682 (g_metadata_set_module), (g_metadata_get_namespace):
5684 * tests/Makefile.am:
5685 * tests/invoke/Makefile.am:
5686 * tests/invoke/invoke-namespace-find.sh:
5687 * tests/invoke/invoke.c: (main):
5689 Add a namespace/shared library mapping. fixes #313268.
5691 2007-12-03 Johan Dahlin <johan@gnome.org>
5693 * src/gidlparser.c (parse_type_internal): Disable char/gchar and
5696 2007-11-30 Jürg Billeter <j@bitron.ch>
5702 * src/gen-introspect.c: (g_idl_node_cmp), (g_igenerator_new),
5703 (g_igenerator_write_inline), (g_igenerator_write),
5704 (g_igenerator_write_indent), (g_igenerator_write_unindent),
5705 (field_generate), (value_generate), (constant_generate),
5706 (property_generate), (function_generate), (vfunc_generate),
5707 (signal_generate), (interface_generate), (struct_generate),
5708 (union_generate), (boxed_generate), (enum_generate),
5709 (node_generate), (module_generate), (get_type_from_type_id),
5710 (str_replace), (g_igenerator_process_properties),
5711 (g_igenerator_process_signals), (g_igenerator_process_types),
5712 (get_type_from_ctype), (g_igenerator_process_function_symbol),
5713 (g_igenerator_process_unregistered_struct_typedef),
5714 (g_igenerator_process_struct_typedef),
5715 (g_igenerator_process_union_typedef),
5716 (g_igenerator_process_enum_typedef),
5717 (g_igenerator_process_function_typedef),
5718 (g_igenerator_process_constant), (g_igenerator_process_symbols),
5719 (g_igenerator_add_symbol), (g_igenerator_is_typedef),
5720 (g_igenerator_generate), (main), (csymbol_new),
5721 (csymbol_get_const_boolean), (ctype_new), (ctype_copy),
5722 (cbasic_type_new), (ctypedef_new), (cstruct_new), (cunion_new),
5723 (cenum_new), (cpointer_new), (carray_new), (cfunction_new),
5724 (eat_hspace), (eat_line), (read_identifier),
5725 (g_igenerator_parse_macros):
5726 * src/gen-introspect.h:
5728 Import gen-introspect to generate introspection information by
5731 2007-11-30 Jürg Billeter <j@bitron.ch>
5733 * src/gidlnode.c: (g_idl_node_new): support creating callback nodes
5735 2007-11-30 Jürg Billeter <j@bitron.ch>
5737 * src/gidlparser.c: (end_element_handler): Don't leave requires
5740 2007-11-29 Johan Dahlin <johan@gnome.org>
5742 * src/gidlparser.c (parse_type_internal): Add char,
5743 gchar and guchar to the builtin types.
5745 2007-11-26 Johan Dahlin <johan@gnome.org>
5747 * src/ginfo.c: (g_object_info_get_type_name),
5748 (g_object_info_get_type_init):
5749 * src/girepository.c: (g_irepository_is_registered):
5750 * src/girepository.h:
5752 Add g_object_info_get_type_name, g_object_info_get_type_init and
5753 g_irepository_is_registered.
5755 2006-08-14 Jürg Billeter <j@bitron.ch>
5757 * src/gidlparser.c: (end_element_handler): Don't leave
5758 namespace and implements states too early.
5761 2007-11-26 Johan Dahlin <johan@gnome.org>
5763 * src/gmetadata.c (validate_struct_blob):
5764 pass blob_type to validate_function_blob instead of
5765 hard-coding BLOB_TYPE_STRUCT.
5767 Patch by Torsten Schoenfeld, fixes #314190
5769 2006-10-03 Torsten Schoenfeld <tsch@cvs.gnome.org>
5771 * src/compiler.c, src/generate.c, src/gidlnode.c,
5772 src/gidlparser.c, src/ginfo.c, src/girepository.c,
5773 tests/invoke/invoke.c, test/invoke/testfns.c: Hush compiler
5774 warnings about return values, signedness mismatches, unused
5775 variables, and unhandles enum values in switch statements.
5777 * tests/invoke/Makefile.am: Don't install the invoke test program.
5778 Add -I ../../src to the cflags used for the test functions files.
5780 2005-08-31 Torsten Schoenfeld <tsch@cvs.gnome.org>
5782 * src/girepository.h: Export g_invoke_error_quark.
5784 2005-08-31 Torsten Schoenfeld <tsch@cvs.gnome.org>
5786 * src/ginvoke.c: Remove the fallback implementation of
5787 g_function_info_invoke since we now formally depend on libffi.
5789 2005-07-25 Matthias Clasen <mclasen@redhat.com>
5791 * src/Makefile, tests/Makefile, tests/invoke/Makefile:
5792 Remove these files from cvs, as they are now generated.
5794 * src/gmetadata.c (validate_iface_type_blob): Don't
5795 complain if blob->pointer is not set, since that
5796 happens for enum and flag types. (#308935, Gustavo
5799 * Commit an autoconf-conversion patch by
5800 Gustavo Carneiro (#308708)
5802 2005-05-24 Matthias Clasen <mclasen@redhat.com>
5804 * src/compiler.c (main): Use it here to validate
5805 the generated metadata.
5807 * src/gmetadata.[hc]: Add code to validate a
5810 * metadata-format.txt: Updates
5812 2005-05-22 Matthias Clasen <mclasen@redhat.com>
5814 * tests/*: Add struct offsets to field and vfunc
5817 * src/generate.c (write_vfunc_info): Write offset
5818 information for vfuncs.
5820 * src/gidlnode.c (g_idl_node_build_metadata): Write
5821 the struct offsets into the metadata.
5823 * src/gidlparser.c: Parse the offset attributes of
5824 field and vfunc elements.
5826 * src/gidlnode.h: Add offset members to field and
5829 2005-05-21 Matthias Clasen <mclasen@redhat.com>
5833 * gidl.dtd: Updates.
5835 * src/g-idl-offsets.pl: A perl script which reads a .gidl
5836 file, creates, compiles and runs a C file, and folds the
5837 resulting struct offsets back into the .gidl file.
5839 2005-05-20 Matthias Clasen <mclasen@redhat.com>
5841 * src/gidlparser.c (start_field): Make fields in objects
5844 * src/gidlmodule.c: Include string.h
5849 * metadata-format.txt: Cleanup basic types.
5850 * src/*: Adapt to the changes.
5851 * tests/*: Adapt to the changes.
5852 * examples/gdk-pixbuf.gidl: Adapt to the changes.
5854 * src/gidlnode.c (g_idl_node_get_size): Report the correct
5855 size for enum blobs.
5856 (g_idl_node_get_full_size): Report the correct size for
5859 * src/gidlmodule.c (g_idl_module_build_metadata): Add some
5860 error checking for blob sizes.
5862 2005-05-19 Matthias Clasen <mclasen@redhat.com>
5864 * src/gidlnode.c (g_idl_node_build_metadata): Correctly handle
5865 interface types for which is_pointer is FALSE, e.g. enums.
5867 * src/gidlnode.c (g_idl_node_get_full_size)
5868 * src/gidlparser.c (parse_type_internal):
5869 * src/generate.c (write_type_info): Support unspecialized
5870 lists, hashtables and errors. Also emit a '*' after these.
5874 2005-05-17 Matthias Clasen <mclasen@redhat.com>
5878 * metadata-format.txt: Cleanups by Maciej Katafiasz.
5880 2005-05-15 Matthias Clasen <mclasen@redhat.com>
5882 * src/*.c: Change the directory to be addressed by
5883 1-based indexes, and use an index of zero to mean
5886 2005-05-15 Matthias Clasen <mclasen@redhat.com>
5888 * tests/roundtrips.sh (SIMPLE_TESTS): Add union.test.
5890 * tests/union.test: Add a union test.
5892 * src/generate.c: Handle unions.
5894 * src/girepository.h:
5895 * src/ginfo.c: Add GIUnionInfo and functions to access it.
5897 * src/gidlnode.c: Handle GIdlNodeUnion nodes.
5899 * src/gidlparser.c (start_union): Parse <union> elements.
5901 * src/gidlnode.h: Add a GIdlNodeUnion.
5903 * gidl.dtd: Add a <union> element.
5905 * src/gmetadata.c (g_metadata_check_sanity): Check
5908 * src/gmetadata.h: Add union_blob_size to Header,
5911 * metadata-format.txt: Add a UnionBlob.
5913 2005-05-13 Matthias Clasen <mclasen@redhat.com>
5915 * tests/*: Update testcases.
5917 * src/generate.c (write_callable_info): Don't forget to
5918 write transfer and null-ok attributes for return types
5921 * src/girepository.h:
5922 * src/ginfo.c (g_callable_info_may_return_null):
5923 New function to find out if a function may return NULL.
5925 * src/compiler.c (format_output): Make the generated
5928 * README: Point to a recent libffi snapshot.
5930 * tests/invoke/*: Some invoke tests.
5932 * src/Makefile: Add ginvoke.c and the necessary
5935 * src/girepository.h (g_function_info_invoke): Add
5938 * src/ginvoke.c (g_function_info_invoke): Initial
5939 implementation of invoke functionality based on libffi.
5941 * src/gidlnode.c (g_idl_node_build_metadata): Pass the
5942 strings and types hash tables in the right order when
5944 (find_entry_node): Free the name parts.
5946 2005-05-12 Johan Dahlin <johan@gnome.org>
5948 * src/generate.c: Generate consistent end tags.
5952 2005-05-12 Matthias Clasen <mclasen@redhat.com>
5956 * src/gidlparser.c (start_function): Actually add
5957 methods to objects. (Steven Walter)
5959 * src/girepository.h:
5960 * src/ginfo.c: Rename Transfer and Direction to
5961 GITransfer and GIDirection. (Torsten Schoenfeld)
5963 * tests/*: Make tests work with the changes in name
5966 * src/gidlnode.c (find_entry_node): Parse qualified
5967 names and generate xref nodes for them if needed. Don't
5968 require all modules to be loaded any more.
5970 * src/gidlmodule.c (g_idl_module_build_metadata): Choke
5973 * src/ginfo.c (g_object_info_get_parent): Return NULL
5974 if blob->parent is 0. Still need to make sure index
5977 * src/generate.c: Generate qualified names when
5978 referring to non-local types. Emit transfer attribute
5981 * src/compiler.c (format_output): Put the function
5982 attributes where gcc accepts them.
5984 2005-05-11 Matthias Clasen <mclasen@redhat.com>
5986 * src/compiler.c (main): Add a --verbose cmdline option
5987 and only log messages if it is specified.
5990 * src/gidlnode.c (init_stats, dump_stats): Collect some
5991 statistics on string and type sharing.
5993 * src/gidlmodule.c (g_idl_module_build_metadata): Use
5994 g_message() instead of fprintf().
5996 * src/gidlnode.c (g_idl_node_free): Make this more robust.
5997 (g_idl_node_get_size): Implement for structs.
5998 (g_idl_node_get_full_size): Handle parent being NULL.
5999 (serialize_type): Handle lookup failures more gracefully.
6001 2005-05-10 Matthias Clasen <mclasen@redhat.com>
6003 * src/gidlnode.c (g_idl_node_get_full_size): Correct the
6004 size calculation for 2-parameter types and for objects.
6006 * src/compiler.c: Add a cmdline option for debug output
6007 and install a log handler to implement it.
6008 * src/gidlnode.c: Add some debug spew.
6012 * src/gidlmodule.c (g_idl_module_build_metadata): Don't
6013 forget to count the module name when calculating the
6014 required size for the metadata.
6017 * src/gidlparser.c: Fix compiler warnings.
6019 2005-05-09 Matthias Clasen <mclasen@redhat.com>
6021 * src/compiler.c (main): Free the option context.
6023 * gidl.dtd: Clean up handling of names. All elements
6024 have a "name", only the elements corresponding to
6025 actual callable functions (function, method, constructor),
6026 have an additional "symbol" attribute holding the
6027 dlsym()-able function name.
6029 * src/generate.c: Adapt to generate xml matching the
6033 * src/gidlnode.c: Adapt to parse the new dtd.
6035 * tests/*.test: Adjust to the new dtd.
6037 * metadata-format.txt:
6038 * src/gmetadata.h: Remove the short_name field
6040 * src/gmetadata.c: Shrink size of ValueBlob to 12.
6041 * src/girepository.h:
6042 * src/ginfo.c (g_value_info_get_short_name): Removed
6044 2005-05-09 Matthias Clasen <mclasen@redhat.com>
6046 * gidl.dtd: Allow constructors for boxed types,
6047 patch by Jonathan Blandford.
6050 2005-05-09 Matthias Clasen <mclasen@redhat.com>
6052 * --- Initial import ---