1 2009-01-15 Johan Dahlin <jdahlin@async.com.br>
3 Bug 567813 – Everything should be versioned
6 * girepository/Makefile.am:
7 * girepository/girepository.c (init_globals):
8 * girepository/girparser.c (locate_gir):
10 * giscanner/transformer.py:
11 * gobject-introspection-1.0.pc.in:
12 * tests/everything/Makefile.am:
13 * tests/invoke/Makefile.am:
14 * tests/offsets/Makefile.am:
15 * tests/repository/Makefile.am:
16 * tests/scanner/Makefile.am:
19 2009-01-13 Johan Dahlin <jdahlin@async.com.br>
21 Bug 555036 – put gtk-doc in GIR
23 * giscanner/annotationparser.py:
25 * giscanner/girwriter.py:
26 * giscanner/glibast.py:
27 * tests/scanner/annotation-1.0-expected.gir:
28 * tests/scanner/annotation.h:
29 * tests/scanner/foo-1.0-expected.gir:
31 2009-01-13 Johan Dahlin <jdahlin@async.com.br>
33 * giscanner/cachestore.py (CacheStore.load): Catch AttributeError
34 which seems to be occasionally raised for Record.
36 * giscanner/annotationparser.py:
37 Fix a bug where \n was not present in a comment
39 2009-01-12 Johan Dahlin <jdahlin@async.com.br>
41 Bug 562467 – Property annotation
43 * giscanner/annotationparser.py:
44 * tests/scanner/annotation-1.0-expected.gir:
45 * tests/scanner/annotation-1.0-expected.tgir:
46 * tests/scanner/annotation.c (annotation_object_set_property),
47 (annotation_object_get_property), (annotation_object_class_init):
49 Annotations are parsed for properties.
51 2009-01-12 Johan Dahlin <jdahlin@async.com.br>
53 Bug 546739 – Introspection should know precise signal parameter types
55 * giscanner/annotationparser.py:
56 * tests/scanner/annotation-1.0-expected.gir:
57 * tests/scanner/annotation-1.0-expected.tgir:
58 * tests/scanner/annotation.c (annotation_object_class_init):
60 Annotations are parsed for signals, the (type) annotation is introduced.
62 2009-01-12 Johan Dahlin <jdahlin@async.com.br>
64 Bug 563591 – Flags not recognized when there is no introspection data
67 * giscanner/girwriter.py:
68 * giscanner/giscannermodule.c (type_get_is_bitfield):
69 * giscanner/glibast.py:
70 * giscanner/glibtransformer.py:
71 * giscanner/scannerparser.y:
72 * giscanner/sourcescanner.c (gi_source_type_copy):
73 * giscanner/sourcescanner.h:
74 * giscanner/sourcescanner.py:
75 * giscanner/transformer.py:
76 * tests/scanner/foo-1.0-expected.gir:
77 * tests/scanner/foo-1.0-expected.tgir:
78 * tests/scanner/foo.h:
80 Large parts of this patch was done by Jürg Billeter.
82 2009-01-12 Havoc Pennington <hp@pobox.com>
84 Bug 563386 – scanner ignores "const" on boxed return values
86 * tests/everything/everything.c (test_simple_boxed_a_const_return):
87 * tests/everything/everything.h:
89 This adds just the tests specified in the bug above, the fix itself
90 was included in Bug 563794
92 2009-01-03 Andreas Rottmann <a.rottmann@gmx.at>
94 Bug 566404 – Annotations for GLib
96 * gir/glib-2.0.c: Added allow-none annotations for g_thread_init()
97 and g_main_loop_new().
99 2009-01-12 Johan Dahlin <jdahlin@async.com.br>
101 Bug 566419 – Element type of arrays not properly handled in all cases
103 * giscanner/annotationparser.py:
104 * tests/scanner/annotation-1.0-expected.gir:
105 * tests/scanner/annotation-1.0-expected.tgir:
106 * tests/scanner/annotation.c (annotation_object_set_data),
107 (annotation_object_set_data2), (annotation_object_set_data3):
108 * tests/scanner/annotation.h:
110 Based on patch by Andreas Rottmann
112 2009-01-12 Johan Dahlin <jdahlin@async.com.br>
114 Bug 566560 – giscanner.transformer.SkipError
116 * giscanner/transformer.py:
118 Catch SkipError for all nodes, not just functions.
119 Makes it possible to skip unsupported parameter types in
122 2009-01-12 Johan Dahlin <jdahlin@async.com.br>
124 Bug 563794 - Redo annotation parsing & applying
126 Thanks to Colin for helping out considerably in landing this.
128 * giscanner/Makefile.am:
130 * giscanner/dumper.py:
131 * giscanner/girparser.py:
132 * giscanner/giscannermodule.c (pygi_source_scanner_get_comments),
133 (calc_attrs_length), (pygi_collect_attributes), (init_giscanner):
134 * giscanner/glibtransformer.py:
135 * giscanner/scannerlexer.l:
136 * giscanner/sourcescanner.c (gi_source_symbol_unref),
137 (gi_source_scanner_new), (gi_source_scanner_free),
138 (gi_source_scanner_get_comments):
139 * giscanner/sourcescanner.h:
140 * giscanner/sourcescanner.py:
141 * giscanner/transformer.py:
142 * giscanner/xmlwriter.py:
143 * tests/scanner/annotation-1.0-expected.gir:
144 * tests/scanner/annotation-1.0-expected.tgir:
145 * tests/scanner/annotation.c:
146 * tests/scanner/annotation.h:
147 * tests/scanner/foo-1.0-expected.gir:
148 * tests/scanner/foo-1.0-expected.tgir:
149 * tests/scanner/foo.h:
150 * tools/g-ir-scanner:
152 This commit merges the annotation parser rewrite branch.
153 It'll change the annotation parsing to be done completely in python
154 code which will make it easier to do further annotation parsing
157 2009-01-03 Andreas Rottmann <a.rottmann@gmx.at>
159 Bug 563469 – Arrays not treated correctly in struct offset calculation
161 * tests/scanner/foo.h (FooObject): Added field `some_int'.
162 * tests/scanner/foo-1.0-expected.gir,
163 * tests/scanner/foo-1.0-expected.tgir: Adapted.
165 * giscanner/glibtransformer.py (GLibTransformer._create_gobject):
166 carry over object fields from original (struct) node.
167 (GLibTransformer._pair_class_struct): Don't add fields of the
168 class struct to to the node for the class, they should go under a
169 nested <record> element (see also Bug 551738). This is needed as
170 otherwise offset calculation would not work, as the instance
171 fields are mingled with the class fields without a way to
174 2009-01-03 Johan Dahlin <jdahlin@async.com.br>
177 Disable blank line check, it works differently under
178 Python 2.5 from 2.6 and was rather annoying from the start.
180 2008-01-03 Andreas Rottmann <a.rottmann@gmx.at>
182 Bug 556489 – callback annotations
184 * giscanner/transformer.py
186 * tools/generate.c (write_callable_info): Write out the new scope,
187 closure and destroy attributes.
189 * giscanner/transformer.py (Transformer._type_is_callback): New
190 method, checking if a given type is a callback.
191 (Transformer._augment_callback_params): New method; adds
192 information (closure, destroy) to callback parameters.
193 (Transformer._handle_closure, Transformer._handle_destroy): New methods,
194 auxiliary to _augment_callback_params.
195 (Transformer._create_function): Call _augment_callback_params().
196 (Transformer._create_parameter): Handle scope option.
198 (Transformer._create_typedef_callback): New method, creates a
199 callback, and registers it in the typedef namespace
200 (Transformer._create_typedef): Use _create_typedef_callback()
201 instead of the plain _create_callback().
203 * giscanner/ast.py (Parameter): Added callback-related fields.
204 * giscanner/girwriter.py: Write out new Parameter fields.
206 * girepository/girnode.h (GIrNodeParam): Added fields scope,
208 * girepository/gtypelib.h (ArgBlob): Ditto.
209 * girepository/girparser.c (start_parameter): Handle new fields.
211 * girepository/girmodule.c (g_ir_module_build_typelib): Adjust
212 arg_blob_size, bump major version due to this change.
213 * girepository/girnode.c (g_ir_node_get_full_size_internal)
214 (g_ir_node_build_typelib)
215 * girepository/gtypelib.c (g_typelib_check_sanity): ArgBlob size
217 (g_ir_node_build_typelib): Fill in new ArgBlob flags from param.
219 * girepository/girepository.h (GIScope): New enumeration, listing
220 the different possible scopes for callbacks.
222 * girepository/ginfo.c (g_arg_info_get_scope)
223 (g_arg_info_get_closure, g_arg_info_get_destroy): Accessors for
224 callback-related argument indices (callback scope, closure for a
225 callback, destroy notification for a callback).
227 * tests/scanner/: Added testcases for new features.
229 2009-01-03 Jürg Billeter <j@bitron.ch>
232 * giscanner/dumper.py:
233 * giscanner/girparser.py:
234 * giscanner/glibtransformer.py:
235 * giscanner/sourcescanner.py:
236 * giscanner/transformer.py:
237 * giscanner/xmlwriter.py:
239 Fix inconsistencies with PEP8
241 2008-12-21 Johan Dahlin <jdahlin@async.com.br>
244 Annotate transfer, direction and allow none for
245 g_file_load_contents, g_file_load_contents_finish and
246 g_file_load_partial_contents_finish parameters.
248 2008-12-12 Owen Taylor <otaylor@redhat.com>
250 Disable array auto-detection for out-annotated parameters (#563934)
252 If we have a parameter annotated as (out), then having a ctype of
253 'char **' (or similar) doesn't necessarily indicate an array.
255 * giscanner/transformer.py: Skip array-detection logic for
256 (out)-annotated parameters.
257 * tests/scanner/annotation.h tests/scanner/annotation.c
258 tests/scanner/annotation-1.0-expected.gir
259 tests/scanner/annotation-1.0-expected.tgir: Add a test for
260 an (out) string parameter.
262 2008-12-12 Johan Dahlin <jdahlin@async.com.br>
264 * giscanner/dumper.py (DumpCompiler._link): Pass in
265 --tag=CC to libtool to avoid making libtool confused
266 when CC is different from gcc on some systems.
268 2008-12-10 Johan Bilien <jobi@via.ecp.fr>
270 Bug 563998 – Cache the GIBaseInfo for GTypes
272 * girepository/girepository.c (g_irepository_find_by_gtype):
273 add a cache of GType -> GIBaseInfo.
275 2008-12-09 Johan Bilien <jobi@via.ecp.fr>
277 Bug 562545 – Add function taking / returning GValue
279 * tests/everything/everything.[ch]: add a test of function taking and
280 returning "const GValue *"
282 2008-12-09 Johan Dahlin <johan@async.com.br>
284 * giscanner/cachestore.py (CacheStore.store): Use
285 shutil.move instead of os.rename, since it will
286 automatically fall back to copying+remove if the
287 src directory is on a different partition from
290 2008-12-08 Tristan Van Berkom <tristan.van.berkom@gmail.com>
292 Bug 563742 – introspection should record the introduced version of
293 symbols marked with the "Since:" tag
298 * giscanner/girwriter.py:
299 * giscanner/scannerlexer.l:
300 * giscanner/transformer.py:
301 * tests/scanner/annotation-1.0-expected.gir:
302 * tests/scanner/annotation-1.0-expected.tgir:
303 * tests/scanner/annotation.c (annotation_versioned):
304 * tests/scanner/annotation.h:
306 2008-12-08 Johan Dahlin <johan@async.com.br>
308 * giscanner/cachestore.py (_get_cachedir): Don't require
309 HOME to be set and if it set, don't require the
312 2008-12-08 Johan Dahlin <johan@async.com.br>
314 * giscanner/cachestore.py (CacheStore.store): Dump the cache
315 file to a temporary file and rename it the expected filename
316 only when it's completely written.
317 This should make the cache more roboust when run in parallel,
318 and hopefully avoid triggering bugs in Python.
320 2008-12-03 Christophe Fergeau <teuf@gnome.org>
322 Bug 562971 – g-ir-scanner failure on libgpod headers
324 * giscanner/scannerlexer.l: raise YY_BUF_SIZE to 65536 up from the
325 default 16384. Without it, the lexer was aborting with a cryptic
326 error message on source files containing really long comment
329 2008-12-01 Colin Walters <walters@verbum.org>
331 * girepository/gfield.c: Fix memory leak; unref type info we
332 created, not field info
334 2008-11-30 Johan Dahlin <jdahlin@async.com.br>
336 Bug 562289 – Race when removing invalid cache
338 * giscanner/cachestore.py:
339 ENOENT is mapped to a OSError, not IOError.
341 2008-11-27 Johan Dahlin <jdahlin@async.com.br>
343 * gir/glib-2.0.c: Add return value transfer annotation
344 for g_markup_escape_text.
346 2008-11-25 Colin Walters <walters@verbum.org>
348 * tools/g-ir-scanner: Add --libtool option which we expect Automake-using
350 * giscanner/dumper.py: Implement it.
351 * gir/Makefile.am, tests/**/Makefile.am: Use it.
353 2008-11-25 Colin Walters <walters@verbum.org>
355 * tests/scanner/Makefile.am: Remove hand-rolled generation of .tgir; easier
356 to just use a Makefile rule and dependencies. This corresponds with a change
357 made to gir-repository to fix srcdir != builddir issues.
359 2008-11-25 Johan Dahlin <jdahlin@async.com.br>
362 Post release version bump
365 2008-11-25 Johan Dahlin <jdahlin@async.com.br>
370 2008-11-25 Colin Walters <walters@verbum.org>
372 Bug 559705 – Missing association between static methods and classes
374 * docs/typelib-format.txt:
375 * girepository/ginfo.c (g_function_info_get_flags):
376 * girepository/girmodule.c (g_ir_module_build_typelib):
377 * girepository/girnode.c (g_ir_node_get_size),
378 (g_ir_node_build_typelib):
379 * girepository/girparser.c (start_function):
380 * girepository/gtypelib.c (g_typelib_check_sanity),
381 (validate_header), (validate_function_blob):
382 * girepository/gtypelib.h:
384 * giscanner/girwriter.py:
385 * giscanner/glibtransformer.py:
386 * tests/scanner/foo-1.0-expected.gir:
387 * tests/scanner/foo-1.0-expected.tgir:
388 * tests/scanner/foo.h:
390 2008-11-25 Johan Dahlin <jdahlin@async.com.br>
392 * giscanner/ast.py: Define socklen_t as an alias for int32.
394 2008-11-24 Johan Dahlin <jdahlin@async.com.br>
396 * girepository/gdump.c (dump_type): Remove a warning,
397 be less verbose on error on fundamental types.
399 2008-11-23 Johan Dahlin <jdahlin@async.com.br>
401 * giscanner/dumper.py: Add license headers,
402 refactor into a class, avoid some duplication and do some
403 extra pedantic checks.
405 2008-11-23 Johan Dahlin <jdahlin@async.com.br>
407 Make it compilable with -Werror on my system by adding
408 a couple of prototypes and including headers.
410 2008-11-23 Johan Dahlin <jdahlin@async.com.br>
412 Bug 562022 – gobject-introspection needs python headers
414 * configure.ac: fail without python headers present.
417 2008-11-21 Johan Dahlin <jdahlin@async.com.br>
419 Bug 561617 – Return value array annotations
421 * giscanner/transformer.py:
422 * tests/scanner/annotation.c (annotation_return_array):
423 * tests/scanner/annotation.h:
424 Add support for (array) for return value annotations as well.
426 2008-11-20 Johan Bilien <jobi@via.ecp.fr>
428 * tests/everything/everything.[ch]: add a test function which calls a
431 2008-11-19 Johan Dahlin <jdahlin@async.com.br>
433 * giscanner/cachestore.py:
434 Catch ValueError exceptions.
436 2008-11-18 Tommi Komulainen <tommi.komulainen@iki.fi>
438 * tests/scanner/Makefile.am (barapp_SOURCES): fix builddir != srcdir
440 2008-11-18 Andreas Rottmann <a.rottmann@gmx.at>
442 * girepository/girnode.c (g_ir_node_build_typelib): Use sizeof()
443 instead of hard-coding struct sizes.
445 2008-11-18 Owen Taylor <otaylor@redhat.com>
447 Bug 561296 - Add "storage type" to the typelib data for enums
449 In order to set and get enum and flag fields in structures, we need
450 to know the integral type that the enumeration is stored as. We are already
451 computing that at compile time in order to compute struct offsets, so the
452 easiest thing to do is to save that in the typelib.
454 * docs/typelib-format.txt girepository/girnode.[ch] girepository/giroffsets.c
455 girepository/gtypelib.h: Add 'storage_type' to the typelib format for EnumBlob
456 and compute and save it at compile time.
458 * girepository/girepository.h girepository/ginfo.c:
459 Add g_enum_info_get_storage_type().
461 * girepository/gfield.c: Implement reading and writing enum and flags fields
462 based on the storage type.
464 2008-11-18 Owen Taylor <otaylor@redhat.com>
466 Add enums to the Everything test module
468 * tests/everything/everything.[ch]: Add TestEnum and TestFlags to the Everything
469 test module and register them as GTypes.
471 https://bugzilla.gnome.org/show_bug.cgi?id=561296
473 2008-11-18 Johan Dahlin <jdahlin@async.com.br>
475 * giscanner/cachestore.py:
476 Catch BadPickleGet exceptions as well.
478 2008-11-17 Owen Taylor <otaylor@redhat.com>
480 * tests/everything/everything.c: Fix doc comment annotations
481 for test_struct_b_clone() to refer to the right function.
483 2008-11-17 Dan Winship <danw@gnome.org>
485 * giscanner/glibtransformer.py (GLibTransformer.__init__): fix
486 spelling of GHashTable. #561135
488 * tests/scanner/annotation.c (annotation_object_get_hash):
489 * tests/scanner/annotation-1.0-expected.gir:
490 * tests/scanner/annotation-1.0-expected.tgir: add a test of
491 GHashTable annotations
493 2008-11-17 Andreas Rottmann <a.rottmann@gmx.at>
495 * giscanner/ast.py: Change string array match type to be in terms
496 of canonicalized type.
497 * giscanner/transformer.py: Add canonicalize_ctype which gives us
498 a version of a c:type without aliases, so we can deep canonicalize
499 char** to utf8*. Update parse_ctype to use it.
500 * tests/*: Add gtk_init like int*/char*** arg functions for testing.
502 2008-11-16 Colin Walters <walters@verbum.org>
504 * girepository/girepository.c: Ensure we always call init_globals,
505 even if passed a non-default repository.
507 2008-11-16 Colin Walters <walters@verbum.org>
509 Bug 559706 - Interface prerequisites
511 * common.mk: Dep on libgirepository.la for scanner libs so that
512 we rebuild things even if just gdump.c changes.
513 * girepository/gdump.c: Dump prerequisites.
514 * giscanner/ast.py: Add prerequisite list.
515 * giscanner/girparser.py: Parse them from gdump.
516 * giscanner/girwriter.py: Write them.
517 * giscanner/glibtransformer.py: Resolve them.
520 2008-11-16 Owen Taylor <otaylor@redhat.com>
522 Bug 561087 - Respect is_pointer in serialize_type()
524 Add a '*' to the serialization for the cases where we set is_pointer
525 in the type blob we write out depending on node->is_pointer. Don't
526 add the '*' in the cases where is_pointer is set or not set in a
529 http://bugzilla.gnome.org/show_bug.cgi?id=561087
531 2008-11-16 Owen Taylor <otaylor@redhat.com>
533 Bug 560825 – Add size and alignment to typelib
535 Include the size and alignment of structures and unions in the typelib,
536 and add getter methods to retrieve them from GIStructInfo/GIUnionInfo.
538 * docs/typelib-format.txt girepository/gtypelib.h girepository/girnode.c
539 girepository/girmodule.c girepository/gtypelib.c: Add size and alignment
540 to StructBlob and UnionBlob.
542 * girepository/ginfo.c girepository/girepository.h:
543 Add g_[struct|union]_get[size|alignment]().
545 * test/offsets/gen-gitestoffsets: Test overall structure size and alignment.
547 2008-11-16 Owen Taylor <otaylor@redhat.com>
549 Bug 552371 – implement struct field get/set
551 * girepository/gfield.c girepository/girepository.h: Add
552 convenience functions g_field_info_set_field() and
553 g_field_info_get_field() to set and get fields based on the
554 offsets in GIFieldInfo.
556 2008-11-16 Andreas Rottmann <a.rottmann@gmx.at>
558 Bug 560241 - Out-arguments should not be marked as being pointers
561 * girepository/girparser.c: Improved logic for out arguments.
563 2008-11-16 Andreas Rottmann <a.rottmann@gmx.at>
565 Bug 559601 - Pointers in structs/unions unduly treated as arrays
567 * giscanner/transformer.py: Differentiate type creation logic
568 between parameters and struct components.
570 2008-11-15 Colin Walters <walters@verbum.org>
572 * giscanner/dumper.py: Check return code from pkg-config
575 2008-11-14 Johan Dahlin <jdahlin@async.com.br>
577 * tests/everything/everything.c (test_array_int_in),
578 (test_array_gtype_in):
579 * tests/everything/everything.h:
580 Rename the int/gtype array tests. Make the return value
581 useful, an aggregation of the array input values.
583 2008-11-14 Johan Dahlin <jdahlin@async.com.br>
585 * tests/everything/Makefile.am:
586 * tests/everything/everything.c:
587 * tests/everything/everything.h:
588 * tests/everything/gitesttypes.c:
589 * tests/everything/gitesttypes.h:
590 Rename gitesttypes.[ch] to everything.[ch]
592 2008-11-13 Andreas Rottmann <a.rottmann@gmx.at>
594 Bug 560708 – Don't treat arrays that have a length specified as
595 zero-terminated by default
597 * giscanner/transformer.py: Default to non zero terminated for
599 * tests/*: Update, add test for zero vs not.
601 2008-11-13 Andreas Rottmann <a.rottmann@gmx.at>
603 Bug 557788 - Return types for constructors in generated typelib bogus
605 * girepository/girnode.c: Namespace-qualify XREFs; not doing so is
606 obviously broken in the face of duplicate names in different
608 * tests/scanner/*expected.gir: Fix up.
610 2008-11-13 Owen Taylor <otaylor@redhat.com>
612 * girepository/girffi.c: Fix "Unexpected time for time_t"
615 2008-11-13 Colin Walters <walters@verbum.org>
617 Bug 558436 - avoid having scanner load app code
619 * giscanner/cgobject.py: Delete; we no longer load shared
621 * giscanner/dumper.py: Support for linking a library to
622 a stub binary for introspection.
623 * giscanner/glibtransformer.py: Rewrite to use gdump XML
624 from invocation of child binary.
625 * giscanner/transformer.py: Fix up to use fully qualified
626 name in parse tree. Make parse_ctype public so we can use
627 it inside glibtransformer.
628 * tests/scanner/barapp.c: New test, using --program arg
630 * tests/*: Update to use common.mk for invoking scanner.
631 * tools/g-ir-scanner: Add options --program, --program-arg,
633 * docs/g-ir-scanner.1: Update.
635 2008-11-13 Colin Walters <walters@verbum.org>
637 * configure.ac: Depend on Gio, we use it in gdump.c.
638 * girepository/gdump.c: Code to dump GType data to XML.
639 * girepository/girepository.c: Add option group for dumping.
640 * girepository/girepository.h: Define API for the above.
642 2008-11-13 Colin Walters <walters@verbum.org>
644 * common.mk: Add a file to include with Makefile fragments
645 useful for scanner invocation.
647 2008-11-13 Tommi Komulainen <tommi.komulainen@iki.fi>
649 * tests/everything/gitesttypes.c (test_filename_return): Return
650 strings in filename encoding.
652 2008-11-13 Owen Taylor <otaylor@redhat.com>
654 Bug 560253 – Add structure and boxed types to Everything test module
656 * tests/everything/gitesttypes.[ch]: Add examples of:
658 Plain old data structs
659 Plain old data structs with nested fields
661 Plain old data boxed with nested fields
662 More complicated boxed types with internal state
664 2008-11-12 Johan Dahlin <jdahlin@async.com.br>
666 * tests/everything/gitesttypes.c (test_gtype_in):
667 * tests/everything/gitesttypes.h:
668 Add a test of GType arrays, a la gtk_list_store_set_columns.
670 2008-11-12 Owen Taylor <otaylor@redhat.com>
672 Bug 560419 – Cache includes when parsing
674 Keep track of all modules parsed within a GIrParser, and when a
675 module is referenced a second time, use the existing parsed copy
676 instead of reparsing.
678 2008-11-12 Owen Taylor <otaylor@redhat.com>
680 Fix management of ParseContext.includes_modules (#560419)
682 * girepository/girparser.c: Fix some trivial bugs in managing the
683 list of include modules. (Add to module's list twice, not
684 initialized to NULL, not freed.)
686 2008-11-12 Owen Taylor <otaylor@redhat.com>
688 Keep aliases and disguised_structures local to each module (#560419)
690 * girepository/girmodule.[ch]: When parsing, keep keep a separate
691 hash tables of aliases and 'disguised' flags for each module, and
692 store that on the module.
694 After parsing an include merge the aliases/disguised flags to the
697 * girepository/girparser.c: Remove 'prefix_aliases' flag and
698 always prefix aliases/disguised structure types when parsing; this
699 simplifies the code considerably.
701 2008-11-12 Owen Taylor <otaylor@redhat.com>
703 Fix mismatches between .gir name and 'name' attribute (#560419)
705 * tests/boxed.gir tests/constant.gir tests/enum.gir tests/invoke/invoke.c
706 tests/invoke/testfns-1.0.gir tests/object.gir tests/struct.gir: Fix places
707 where the 'name' element of <namespace/> didn't match the filename of the
708 gir, an assumption that the compiler has always expected and now enforces.
710 2008-11-12 Owen Taylor <otaylor@redhat.com>
712 Only allow one <namespace/> element per <repository/> (#560419)
714 * girepository/girparser.c: The logic in girparser.c didn't work
715 very well if there were multiple <namespace/> nodes within a
716 single <repository/> (context->namespace was always the overall
717 filename and not the the name specified in the <namespace/>
718 element for one thing; this would cause aliases to be mis-prefixed
719 in include modules.) Also check that the "name" in the
720 <namespace/> node matches the filename.
722 2008-11-12 Owen Taylor <otaylor@redhat.com>
724 Add a GirParser object to hold the state of a compilation
726 * girepository/girparser.[ch] tools/compiler.c: Add a toplevel
727 GirParser object to hold state that is global across a
728 compilation. Currently just holds the include path, but will
729 eventually also keep a cached list of parsed modules.
731 2008-11-12 Tommi Komulainen <tommi.komulainen@iki.fi>
733 * girepository/girepository.c (find_namespace_latest): Fix
736 2008-11-12 Tommi Komulainen <tommi.komulainen@iki.fi>
738 * configure.ac: use 'introspection' component for bugs
740 2008-11-12 Johan Dahlin <jdahlin@async.com.br>
742 * tests/everything/gitesttypes.c (test_filename_return):
743 * tests/everything/gitesttypes.h:
744 Add a filename return test.
746 2008-11-12 Tommi Komulainen <tommi.komulainen@iki.fi>
748 * tests/offsets/Makefile.am (gitestoffsets.c): fix
749 gen-gitestoffsets invocation with builddir != srcdir
751 2008-11-12 Johan Dahlin <jdahlin@async.com.br>
753 * girepository/girepository.c:
754 Change the element type from utf8 to filename
755 * girepository/girnode.c (g_ir_node_build_typelib):
756 Special case filename equally to utf8 here.
758 2008-11-12 Johan Dahlin <jdahlin@async.com.br>
761 Remove unused variables, add a dependency of girepository.ch, so when
762 they change we rebuild the gir automatically.
764 2008-11-12 Johan Dahlin <jdahlin@async.com.br>
766 * girepository/girepository.c (g_irepository_get_search_path):
767 * girepository/girepository.h:
768 Add a g_irepository_get_search_path, so we can access the search
771 2008-11-12 Johan Bilien <jobi@via.ecp.fr>
773 Bug 560474 – g-ir-compiler crashes when compiling the glib gir
775 * girepository/girparser.c: avoid freeing an uninitialized pointer
777 2008-11-12 Johan Dahlin <jdahlin@async.com.br>
780 * giscanner/glibtransformer.py:
781 * tools/g-ir-scanner:
782 Add a GIRepository-2.0.gir. Change the libtool lookup slightly
783 so we can just pass in --library=foo/bar/baz.la and the scanner
784 does the right thing.
785 Don't warn for _get_type() functions if they don't take any
788 2008-11-11 Owen Taylor <otaylor@redhat.com>
790 Bug 560404 – Prefix types when resolving aliases in included modules
792 * girepository/girparser.c: When resolving aliases in an included
793 module, prefix types before looking them up.
795 2008-11-11 Owen Taylor <otaylor@redhat.com>
797 Compute field offsets and overall size for object structures
799 Bug 560326 – Fails to build Gtk-2.0.typelib with "Unexpected non-pointer
800 field of type object in structure"
802 Do basic computation of field offsets for objects and interfaces;
803 this doesn't attempt to address all of the "mess" for virtual
804 functions described in Bug 560281.
806 2008-11-11 Tommi Komulainen <tommi.komulainen@iki.fi>
808 Bug 560308 – g-ir-compiler goes in infinite loop on Gdk-2.0.gir
810 Based on patch by Johan Bilien.
812 * giscanner/transformer.py (_create_member, _create_parameter):
813 Resolve types here as well.
814 (_resolve_type_name_1): Try resolving using 'ctype' first since
815 it's least ambiguous. Fixes struct member type resolution with
816 similarly named types, e.g. Gdk.PangoRendererClass and
818 * tests/scanner/foo*: Add test.
820 2008-11-11 Owen Taylor <otaylor@redhat.com>
822 * girepository/girparser.c: Search provided include dirs before
823 the default directories.
825 2008-11-11 Owen Taylor <otaylor@redhat.com>
827 * girepository/giroffsets.c: Include fully-qualified names in
830 2008-11-11 Owen Taylor <otaylor@redhat.com>
832 * girepository/giroffsets.c: Fail gracefully with an informative
833 error message when recursion is encountered when computing a
836 2008-11-11 Owen Taylor <otaylor@redhat.com>
838 * girepository/girparser.c: Remove an unused variable.
840 2008-11-10 Owen Taylor <otaylor@redhat.com>
842 Add tests for field offset computations
844 * tests/offsets/offsets.h: Header file with structure definitions to test
846 * tests/offsets/gen-gitestoffsets: Generate a C program that computes
847 field offsets for the structures in offsets.h two ways: using
848 the information from a generated typelib, and as computed by the
851 We diff these two versions to test that everything is OK.
853 2008-11-10 Owen Taylor <otaylor@redhat.com>
855 Remove field offsets from g-ir-generate output and test inputs
857 Field offsets are a) architecture dependent so they shouldn't be part
858 of the architecture-independent gir format which is installed in
859 datadir. b) Are architecture-dependent so they shouldn't be in test
862 * girepository/girparser.c: Don't parse offset for fields
863 * tools/generate.c: Don't parse offset for fields
864 * tests/*.gir test/scanner/*.tgir: Remove offsets
866 (Virtual function and discriminator offsets are not removed, as they
867 aren't fully hooked up to the field-offset computation machinery yet.)
869 2008-11-10 Owen Taylor <otaylor@redhat.com>
871 Bug 560252 - Compute field offsets before writing typelib
873 * girepository/girnode.h: Store the total size and alignment for
874 GIrNodeStruct/Boxed/Union.
876 * girepository/giroffset.c: New file implementing computation of
877 structure field offsets.
879 * girepository/girnode.c: Compute structure field offsets before
880 writing types into the typelib.
882 * docs/typelib-format.txt: Document that a field offset of 0xFFFF
883 means "unknown". Also fix description of the discriminator_offset
886 2008-11-10 Owen Taylor <otaylor@redhat.com>
888 Bug 560250 - Fully parse included modules
890 For some things, like computing structure offsets to put into the typelib
891 we need more than just the aliases from included modules. Do a completel
892 parse of included modules and store in module->included_modules.
894 Also add g_ir_find_node() to find node information from within the
895 active set of modules and their includes.
897 2008-11-10 Owen Taylor <otaylor@redhat.com>
899 Split g_ir_ffi_get_ffi_type() out from ginvoke.c
901 Extract a function to convert GITypeTag to ffi_type from the internals
902 of ginvoke.c. This will be useful in figure out structure alignment.
904 Also fix handling of gsize and time_t to be portable. (Add a check
905 to configure.ac to figure out the width of time_t.)
907 2008-11-10 Owen Taylor <otaylor@redhat.com>
909 Bug 560248 – "disguised structures"
911 Certain types like GIConv and GdkAtom are pointers internally but don't
912 look like pointers when referenced. They have the form.
914 typedef struct _X *X;
916 Parse these as structures/records but mark them in the gir with a 'disguised'
917 attribute so that we know that they need special handling.
919 In the typelib treat them like any other structure.
921 2008-11-09 Jürg Billeter <j@bitron.ch>
924 * giscanner/girwriter.py:
926 Write throws attribute for virtual functions, fixes bug 559703
928 2008-11-07 Johan Dahlin <jdahlin@async.com.br>
930 * giscanner/libtoolimporter.py (LibtoolImporter.find_module): Clear
931 up some confusion about the second argument to find_module, it's
932 actually the packages __path__ attribute which we can safely ignore
934 (LibtoolImporter.load_module): Set module.__loader__ as per PEP 302.
936 2008-11-07 Owen Taylor <otaylor@redhat.com>
938 Bug 559737 – Deal with continuations in macros
940 * giscanner/giscannerlexer.l: Treat continuation lines the same
941 as regular newlines. This makes the scanner not complain about
942 #define foo(x) \ <stuff> inside a C file. There's no attempt
943 however to handle parsing macro definitions split across lines.
945 2008-11-07 Johan Dahlin <jdahlin@async.com.br>
947 * giscanner/cachestore.py:
948 Handle broken cache entries, write only filesystems and
949 running out of diskspace.
951 2008-11-07 Owen Taylor <otaylor@redhat.com>
953 * giscanner/giscannermodule.c (pygi_source_scanner_lex_filename):
954 Set current_filename before lexing the file so error messages
955 are reported in the right file.
957 2008-11-06 Colin Walters <walters@verbum.org>
959 * tests/everything/*: Add some tests for strv.
961 2008-11-05 Colin Walters <walters@verbum.org>
963 * girepository/ginvoke.c (g_function_info_invoke): Don't use
964 nested scope local variable for error which may go away after
965 conditional is complete.
967 2008-11-05 Colin Walters <walters@verbum.org>
969 * giscanner/scannerlexer.l: Avoid static 256 char buf which we
970 manipulate hackily; just use GString. This avoids an
971 uninitialized memory read pointed out by Havoc.
973 2008-11-04 Johan Dahlin <jdahlin@async.com.br>
975 * giscanner/__init__.py:
977 * giscanner/cachestore.py:
978 * giscanner/cgobject.py:
979 * giscanner/girparser.py:
980 * giscanner/girwriter.py:
981 * giscanner/giscannermodule.c:
982 * giscanner/glibast.py:
983 * giscanner/glibtransformer.py:
984 * giscanner/libtoolimporter.py:
985 * giscanner/minixpath.py:
986 * giscanner/odict.py:
987 * giscanner/sourcescanner.c:
988 * giscanner/sourcescanner.h:
989 * giscanner/sourcescanner.py:
990 * giscanner/transformer.py:
991 * giscanner/utils.py:
992 * giscanner/xmlwriter.py:
994 Relicense the giscanner library under LGPLv2+.
995 This has been approved by all contributors.
997 2008-11-01 Owen Taylor <otaylor@redhat.com>
999 Bug 558848 giparser.py: shared library should be optional
1001 When parsing a .gir, allow the shared-library attribute
1002 of <namespace/> to be missing: this corresponds to the handling
1003 in libgirepository and elsewhere.
1005 2008-11-01 Tommi Komulainen <tommi.komulainen@iki.fi>
1007 Bug 557898 – Fails to build on OSX 10.4
1009 * configure.ac: Check for $shrext_cmds that should be implicitly
1010 available if you're using libtool >= 2.0. If undefined, call
1011 libtool --config explicitly to get its value.
1012 * girepository/gtypelib.c: Remove special case for (non-)Darwin
1013 systems as unneeded.
1015 2008-10-31 Colin Walters <walters@verbum.org>
1017 * COPYING, COPYING.lib, COPYING.tools: Clarify licensing status.
1019 2008-10-31 Johan Dahlin <jdahlin@async.com.br>
1021 * configure.ac: Post release version bump
1024 2008-10-31 Johan Dahlin <jdahlin@async.com.br>
1028 * docs/release-checklist.txt:
1031 2008-10-31 Johan Dahlin <jdahlin@async.com.br>
1033 * Makefile.am: add an upload-release target
1034 * docs/release-checklist.txt:
1035 Release process documentation
1037 2008-10-31 Colin Walters <walters@verbum.org>
1039 Bug 558109 – _g_typelib_init fails to find shared libraries
1041 * transformer/glibtransformer.py: Use ctypes' find_library
1042 on passed libraries and write that for the shared-library
1043 entry. We want to avoid depending on -devel packages.
1045 2008-10-31 Johan Dahlin <jdahlin@async.com.br>
1047 * docs/g-ir-scanner.1:
1048 Document the renaming options.
1050 2008-10-31 Tommi Komulainen <tommi.komulainen@iki.fi>
1052 * giscanner/Makefile.am:
1053 * tests/invoke/Makefile.am:
1054 * tests/repository/Makefile.am: List in-tree libraries first in
1055 LDADD / LIBADD. If installed library is listed first, the
1056 resulting binary will prefer installed version to one in .libs,
1057 possibly making 'make check' behave strangely.
1059 2008-10-30 Tommi Komulainen <tommi.komulainen@iki.fi>
1061 * giscanner/ast.py: map 'id' (ObjC) to 'any' type to stop
1062 gir-repository from choking with gdk/quartz
1064 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
1066 * giscanner/giscannermodule.c (calc_attrs_length),
1067 (pygi_collect_attributes):
1068 * giscanner/xmlwriter.py:
1069 Write a C version of the xml namespace formatter.
1070 Saves 15% of the time it takes to create a gtk gir.
1072 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
1074 * giscanner/xmlwriter.py: Abstract attribute formatting
1075 to a function external to the XMLWriter class.
1077 * giscanner/scannerlexer.l:
1078 Parse and discard __typeof and __attribute.
1080 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
1082 * giscanner/girparser.py:
1083 Remove arguments from the constructor, move them to
1084 separate accessors. Add a new parse_tree method
1085 which takes an element tree instance.
1086 * tools/g-ir-scanner:
1087 Update callsite for this
1089 * giscanner/Makefile.am:
1090 * giscanner/cachestore.py:
1091 * giscanner/transformer.py:
1092 Cache the include parsing. Saves ~25% time when
1093 creating vte (which includes everything up to gtk+).
1095 2008-10-30 Colin Walters <walters@verbum.org>
1097 * giscanner/transformer.py: Don't reparse includes
1098 we've already processed.
1100 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
1102 * giscanner/girparser.py:
1103 * giscanner/transformer.py:
1104 Avoid parsing parameters, types etc when parsing
1105 includes. Should speed up include parsing a bit.
1107 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
1109 * giscanner/girparser.py:
1110 Avoid big if/else and use a dispatch table like
1113 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
1115 * giscanner/transformer.py:
1116 Clean up include parsing and registration.
1118 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
1120 * giscanner/transformer.py:
1123 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
1125 Bug 558383 – builddir != srcdir build fails if giscanner python module not already installed
1128 construct PYTHONPATH just once
1130 * tests/everything/Makefile.am:
1131 * tests/scanner/Makefile.am:
1132 add $(top_srcdir) to PYTHONPATH to
1133 handle builddir != srcdir
1135 * giscanner/libtoolimporter.py:
1136 * giscanner/sourcescanner.py:
1137 Make the libtoolimporter work when distchecking too.
1139 Mostly based on patch by Tommi Komulainen
1141 2008-10-29 Owen Taylor <otaylor@redhat.com>
1143 * giscanner/glibtransformer.py: If a filename of an existing
1144 file is passed to --library, hunt for it directly, rather than
1145 searching for a corresponding library.
1147 2008-10-29 Johan Dahlin <jdahlin@async.com.br>
1149 * giscanner/libtoolimporter.py:
1150 * giscanner/sourcescanner.py:
1151 Clean up the libtool importer a bit. Add a context so we
1152 can use it through a with statement.
1153 Don't just look in the current directory, look in the whole
1156 2008-10-29 Tommi Komulainen <tommi.komulainen@iki.fi>
1158 Bug 558065 – gitesttypes should be installed
1161 * tests/Makefile.am:
1162 * tests/types/Makefile.am -> tests/everything/Makefile.am
1163 * tests/types/gitesttypes.c -> tests/everything/gitesttypes.c
1164 * tests/types/gitesttypes.h -> tests/everything/gitesttypes.h
1165 move tests/types to tests/everything
1167 * tests/everything/Makefile.am: build normal shared library
1168 libgirepository-everything.so.1.0.0 and corresponding typelib
1169 Everything-1.0.typelib
1171 * tests/everything/Makefile.am: explicitly link libtool
1172 versioning with typelib versioning with variables
1174 2008-10-28 Johan Bilien <jobi@via.ecp.fr>
1176 * tools/g-ir-scanner: add LD_LIBRARY_PATH to LPATH before calling ld.
1178 2008-10-27 Johan Bilien <jobi@via.ecp.fr>
1180 * gio/gio-2.0.c: add allow-none annotations, based on the pygobject
1183 2008-10-27 Johan Bilien <jobi@via.ecp.fr>
1185 Bug 558068 – when invoking a method, offset the in arguments by one,
1188 * tests/invoke/invoke.c, tests/invoke/testfns.c,
1189 tests/invoke/testfns-1.0.gir: Add testing of method and constructor.
1190 * girepository/ginvoke.c: do not offset the index of given out
1191 arguments by one for methods, "this" is provided as in argument only.
1193 2008-10-27 Johan Bilien <jobi@via.ecp.fr>
1195 * gir/gio-2.0.c: add annotation for g_file_delete
1197 2008-10-27 Tommi Komulainen <tommi.komulainen@iki.fi>
1199 Bug 558062 – provide and use paths in the .pc file
1201 * gobject-introspection-1.0.pc.in: provide typelibdir variable
1202 for where .typelibs should be installed (callers shouldn't need
1203 to construct paths from bits and pieces)
1205 2008-10-25 Andreas Rottmann <a.rottmann@gmx.at>
1207 Bug 557791 – g_irepository_require() could return a GTypelib *
1209 * girepository/girepository.c: Return GTypelib; this is useful
1210 for low level manipulation.
1212 2008-10-25 Colin Walters <walters@verbum.org>
1214 Bug 557788 – Return types for constructors in generated typelib bogus
1216 * giscanner/glibtransformer.py: Don't resolve ctors incrementally,
1217 rely on end pass resolution.
1219 2008-10-25 Andreas Rottmann <a.rottmann@gmx.at>
1221 Bug 557786 - support fixed size arrays
1223 * girepository/ginfo.c: Add g_type_info_get_array_fixed_size.
1224 * giscanner/scannerparser.y: Retain fixed array size.
1225 * giscanner/ast.py: Add to note.
1226 * giscanner/girwriter.py: Write to gir.
1227 * girepository/girnode.c: Write it to typelib.
1228 * tools/generate.c: Generate.
1229 * tests/*: Add tests.
1231 2008-10-25 Colin Walters <walters@verbum.org>
1233 Bug 557076 - move typelibs to $libdir
1235 * configure.ac: Steal some configury bits from dbus to expand
1237 * gir/Makefile.am: Move to libdir.
1238 * girepository/girepository.c: Stop searching XDG_DATA_DIRS;
1239 instead just look at one hardcoded path in libdir.
1240 * acinclude.m4: Bits from dbus.
1242 2008-10-24 Johan Dahlin <johan@gnome.org>
1244 * girepository/girnode.c (g_ir_node_check_unhandled_members):
1245 Be quiet, do not warn about unhandled members.
1247 2008-10-24 Johan Dahlin <johan@gnome.org>
1249 * girepository/gtypelib.c:
1250 Only use SHLIB_SUFFIX on darwin, otherwise use
1251 G_MODULE_SUFFIX, we cannot get shext_cmds from libtool 2.2.
1253 2008-10-24 Lucas Rocha <lucasr@gnome.org>
1255 Bug 557623 - Constructors shouldn't be flagged as methods.
1257 * girepository/ginfo.c (g_function_info_get_flags): ditto.
1259 2008-10-24 Johan Dahlin <johan@gnome.org>
1261 * giscanner/scannerparser.y:
1262 Check against division by zero for the modula operator.
1263 This fixes header parsing of OSX system headers included
1266 2008-10-24 Johan Dahlin <johan@gnome.org>
1270 Add a CONTRIBUTORS file and dist it.
1272 2008-10-23 Tommi Komulainen <tommi.komulainen@iki.fi>
1274 Bug 556739 – transfer-ownership attribute should be mandatory in .gir
1276 * girepository/girparser.c (parse_param_transfer):
1277 * giscanner/transformer.py (_create_parameter, _create_return):
1278 * giscanner/girwriter.py (_write_return, _write_parameter):
1279 * tools/generate.c (write_callable_info): always write and
1280 require "transfer-ownership" for return-values and parameters
1283 * tests/invoke/testfns-1.0.gir:
1285 * tests/scanner/DrawableAdditions.xml:
1286 * tests/scanner/GtkFrob-1.0-expected.tgir:
1287 * tests/scanner/annotation-1.0-expected.tgir:
1288 * tests/scanner/drawable-1.0-expected.tgir:
1289 * tests/scanner/drawable-injected-1.0-expected.gir:
1290 * tests/scanner/drawable-injected-1.0-expected.tgir:
1291 * tests/scanner/foo-1.0-expected.tgir: Updated
1293 2008-10-23 Tommi Komulainen <tommi.komulainen@iki.fi>
1295 * giscanner/cgobject.py: build fundamental types same way as glib
1297 * giscanner/glibtransformer.py (_type_from_gtype): record GType
1298 when constructing the Type from it
1300 * giscanner/glibtransformer.py (_adjust_transfer): Check whether
1301 the parameter is a GObject from its GType, if available.
1303 * giscanner/glibtransformer.py (_adjust_transfer):
1304 * tests/scanner/foo-1.0-expected.gir:
1305 * tests/scanner/foo-1.0-expected.tgir: deduce
1306 transfer-ownership from GTypes
1308 2008-10-23 Tommi Komulainen <tommi.komulainen@iki.fi>
1310 * giscanner/transformer.py (_create_parameter):
1311 * tests/scanner/foo-1.0-expected.gir: make varargs
1312 transfer-ownership="none"
1314 2008-10-23 Colin Walters <walters@verbum.org>
1316 Bug 556739 - transfer ownership
1318 * giscanner/ast.py: Refactor Parameter/Return to share
1319 common attributes. Add transfer_inferred attribute
1320 which says whether or not we made a guess.
1321 * giscanner/transformer.py: Add much more extensive
1322 heuristics around parameter and return transfer.
1323 * giscanner/glibtransformer.py: Adjust to inspect
1327 2008-10-22 Tommi Komulainen <tommi.komulainen@iki.fi>
1329 Bug 557377 – Add test to ensure annotations survive the roundtrip via typelib
1331 * tests/scanner/Makefile.am:
1332 * tests/scanner/annotation-1.0-expected.tgir:
1333 * tests/scanner/drawable-1.0-expected.tgir:
1334 * tests/scanner/drawable-injected-1.0-expected.tgir:
1335 * tests/scanner/foo-1.0-expected.tgir:
1336 * tests/scanner/GtkFrob-1.0-expected.tgir:
1337 * tests/scanner/utility-1.0-expected.tgir: Add test to ensure
1338 annotations survive the roundtrip via typelib
1340 The expectations are as currently produced by g-ir-generate,
1341 comparison with the .gir files shows there are differences.
1343 2008-10-23 Johan Bilien <jobi@via.ecp.fr>
1345 Bug 557468 – Support for GI_TYPELIB_PATH
1347 * girepository/girepository.c: if the GI_TYPELIB_PATH is set, add the
1348 provided paths to the global search path.
1350 2008-10-22 Tommi Komulainen <tommi.komulainen@iki.fi>
1352 Bug 557379 – g-ir-generate not writing the 'abstract' attribute
1354 * tests/scanner/drawable-1.0-expected.tgir:
1355 * tests/scanner/drawable-injected-1.0-expected.tgir:
1356 * tests/scanner/foo-1.0-expected.tgir:
1357 * tools/generate.c (write_object_info): write 'abstract'
1358 attribute for classes
1360 2008-10-22 Lucas Rocha <lucasr@gnome.org>
1362 * girepository/girmodule.c, girepository/gtypelib.c,
1363 girepository/girparser.[ch]: fix some build warnings.
1365 2008-10-22 Tommi Komulainen <tommi.komulainen@iki.fi>
1367 Bug 557405 – Use 'allow-none' consistently
1369 * docs/typelib-format.txt:
1370 * girepository/ginfo.c (g_arg_info_may_be_null):
1371 * girepository/girnode.c (g_ir_node_build_typelib):
1372 * girepository/girnode.h (struct _GIrNodeParam):
1373 * girepository/girparser.c (start_parameter):
1374 * girepository/girwriter.c (function_generate):
1375 * girepository/gtypelib.h (ArgBlob):
1377 * tests/function.gir:
1378 * tools/generate.c (write_callable_info): Use 'allow-none'
1379 consistently throughout
1381 2008-10-22 Tommi Komulainen <tommi.komulainen@iki.fi>
1383 Bug 557092 – Callback annotations not used
1385 * giscanner/transformer.py (_create_callback): use annotations
1387 * tests/scanner/annotation.h
1388 * tests/scanner/annotation-1.0-expected.gir: add tests
1390 2008-10-21 Colin Walters <walters@verbum.org>
1392 * giscanner/scannerlexer.l: Don't require trailing whitespace after
1393 uncommented parameters.
1396 2008-10-21 Colin Walters <walters@verbum.org>
1398 * girepository/girepository.c: Ensure that when doing an unversioned
1399 require, we prefer items earlier in the search path to later ones.
1401 2008-10-21 Owen Taylor <otaylor@redhat.com>
1403 * giscanner/transformer.py: For string parameters allow transfer annotation
1404 to override the standard automatic guessing based on 'const'.
1406 2008-10-21 Johan Bilien <jobi@via.ecp.fr>
1408 Bug 557241 – "throws" flag for functions
1410 * tests/scanner/drawable-1.0-expected.gir,
1411 tests/scanner/drawable-injected-1.0-expected.gir,
1412 tests/scanner/drawable.[ch]: add simple test for throwing
1413 function (has GError ** as last argument)
1415 * giscanner/ast.py: add a 'throws' flag to Function
1416 * giscanner/glibtransformer.py: if a function's last paramerter is
1417 a GError, set the 'throws' flag and remove that parameter
1418 * giscanner/girwriter.py: write out the 'throws' attribute
1419 * giscanner/girparser.py: support parsing the 'throws' attribute
1421 * tests/repository/gitestthrows.c: add a simple test to check the
1422 throws flag in a typelib and invoke the function
1424 * girepository/ginfo.c, girepository/girnode.[ch],
1425 girepository/girnode.h, girepository/girparser.c,
1426 girepository/girepository.h: Add and parse the GI_FUNCTION_THROWS flag
1428 * girepository/ginvoke.c: if a function throws, add a GError as last
1429 arguments, and propagate the error to the invoker.
1431 2008-10-21 Tommi Komulainen <tommi.komulainen@iki.fi>
1433 * giscanner/transformer.py (_create_parameters): Warn if we see
1434 annotations for unknown parameters. If .h and .c files name
1435 parameters differently, the annotations may be lost.
1437 2008-10-21 Johan Dahlin <johan@gnome.org>
1439 Bug 556358 - don't use libtool internals
1441 * giscanner/Makefile.am:
1442 * giscanner/libtoolimporter.py:
1443 * giscanner/sourcescanner.py:
1444 * giscanner/utils.py:
1445 Add a python meta importer and remove a libtool symlink hack.
1447 2008-10-20 Andreas Rottmann <a.rottmann@gmx.at>
1449 * tests/scanner/Makefile.am (%.typelib): Set PYTHONPATH
1450 and --add-include-path appropriately when invoking the scanner.
1451 * tests/types/Makefile.am (%typelib): Likewise.
1453 2008-10-20 Colin Walters <walters@verbum.org>
1455 Bug 556777 - validate properties
1457 * giscanner/transformer.py: Add option to throw on unknown types.
1458 * giscanner/glibtransformer.py: Use it on properties.
1459 * tests/*: Add a test.
1461 2008-10-20 Colin Walters <walters@verbum.org>
1463 * giscanner/glibast.py: Also register g variants of
1464 default_array_types. This is not beautiful, but
1465 good alternatives aren't easy to come by.
1466 This fixes gchar ** parsing.
1468 2008-10-20 Colin Walters <walters@verbum.org>
1470 * docs/typelib-format.txt, girepository/gtypelib.h:
1471 Take a bit from ObjectInfo to represent abstract flag.
1472 * giscanner/cgobject.py: Expose g_type_get_flags.
1473 * girepository/girepository.h: Add accessor.
1474 * girepository/ginfo.c: Implement it.
1475 * giscanner/ast.py: Add is_abstract flag to generic
1477 * giscanner/glibast.py: Use it.
1478 * giscanner/girwriter.py: Write it.
1479 * girepository/girparser.c: Parse it.
1482 2008-10-20 Tommi Komulainen <tommi.komulainen@iki.fi>
1484 * giscanner/girparser.py (_parse_function): don't lose
1485 'transfer-ownership' attributes when injecting, check for the
1488 2008-10-19 Johan Dahlin <johan@gnome.org>
1490 * giscanner/scannerlexer.l: Parse and ignore __asm.
1492 2008-10-19 Colin Walters <walters@verbum.org>
1494 * giscanner/girparser.py: Parse array length= to ensure
1495 it doesn't get lost from --inject.
1497 2008-10-17 Colin Walters <walters@verbum.org>
1499 Bug 556795 - char ** regression
1501 * giscanner/transformer.py: Fix parsing of ctypes, add some
1502 comments about what's going on.
1503 * tests/*: Add a test for char **.
1505 2008-10-17 Colin Walters <walters@verbum.org>
1507 Bug 556783 - change namespace handling to be more consistent
1509 * giscanner/transformer.py: Eliminate usage of
1510 strip_namespace_object. We now treat --namespace as the default
1511 --strip-prefix; however, if --strip-prefix is specified it
1512 overrides --namespace. This applies to everything except function
1513 names, where we do also strip the namespace.
1514 * giscanner/glibtransformer.py: Remove usage of
1515 strip_namespace_object.
1517 * tests/*: Add skeletal GtkFrob-1.0 test which has different
1518 --namespace and --strip-prefix.
1520 2008-10-17 Tommi Komulainen <tommi.komulainen@iki.fi>
1522 Bug 556732 – generate gir files consistently
1524 * girepository/girparser.c (start_parameter):
1526 * tests/invoke/testfns-1.0.gir:
1527 * tools/generate.c (write_callable_info): write
1528 'transfer-ownership' attribute consistently with both
1529 return-value and parameter elements
1531 2008-10-17 Tommi Komulainen <tommi.komulainen@iki.fi>
1533 Bug 556732 – generate gir files consistently
1535 * tools/generate.c (write_callable_info): write 'direction'
1536 attribute only if other than 'in' to be consistent with
1539 * tests/object.gir: remove direction="in" which is the default
1541 2008-10-17 Tommi Komulainen <tommi.komulainen@iki.fi>
1543 Bug 556732 – generate gir files consistently
1545 * giscanner/ast.py (Field): add readable and writable properties
1546 * giscanner/girparser.py (_parse_field): copy 'readable' and
1547 'writable' attributes
1548 * giscanner/transformer.py (_create_member): create fields as
1550 * giscanner/glibtransformer.py (_introspect_object,
1551 _pair_class_struct): make object instance and class fields
1553 * giscanner/girwriter.py (_write_field):
1554 * tools/generate.c (write_field_info): write field 'readable'
1555 and 'writable' attributes only if non-default (read-only)
1556 * girepository/girparser.c (start_field): in the absence of
1557 attributes assume fields are read-only
1559 * tests/struct.gir: remove redundant readable="1" from fields
1560 * tests/scanner/foo-1.0-expected.gir:
1561 * tests/scanner/utility-1.0-expected.gir: add writable="1" to
1562 all record and union fields
1564 2008-10-17 Tommi Komulainen <tommi.komulainen@iki.fi>
1566 Bug 556732 – generate gir files consistently
1568 * giscanner/girwriter.py (_write_property): write properties
1569 'construct' attribute if set
1570 * tools/generate.c (write_property_info): write properties
1571 'readable' and 'writable' attributes only if non-default
1572 * tests/object.gir: add writable="0"
1573 * tests/scanner/foo-1.0-expected.gir: add construct="1"
1575 2008-10-17 Johan Bilien <jobi@via.ecp.fr>
1577 * gir/glib-2.0.c: added annotations
1579 2008-10-16 Johan Bilien <jobi@via.ecp.fr>
1581 * giscanner/ast.py: Also assume direction=out for size_t*, ssize_t*
1584 2008-10-16 Johan Bilien <jobi@via.ecp.fr>
1586 Bug 556610 – giscanner/girparser.py drops parameter options
1588 * tests/scanner/drawable-injected-1.0-expected.gir,
1589 tests/scanner/DrawableAdditions.xml: added simple test for injection.
1590 * giscanner/ast.py: allow Parameter to take options in the constructor
1591 * giscanner/girparser.py: parse parameter options (transfer,
1592 direction, allow-none)
1594 2008-10-16 Colin Walters <walters@verbum.org>
1596 Bug 556185 - segfault on g_callable_info_get_return_type
1598 Initial patch from John Ehresman.
1600 * tests/repository/*: Add a test using
1601 g_callable_info_get_return_type. Instead of casting a
1602 GITypeInfo directly to a GIRegisteredTypeInfo, we need
1603 to call g_type_info_get_interface.
1605 2008-10-16 Colin Walters <walters@verbum.org>
1607 Bug 556579 - union and struct name misresolved
1609 * giscanner/transformer.py: The calls to _resolve_type_name
1610 for struct/union names was a legacy holdover from when type
1611 resolution had multiple phases. Now it's actively harmful
1612 since we might pull in an identical name from another
1616 2008-10-16 Colin Walters <walters@verbum.org>
1618 Bug 556432 - transfer annotations and defaults
1620 * giscanner/transformer.py: Canonicalize type
1621 after removing *, not before. This ensures that
1622 guchar* is transformed to 'uint8'.
1623 Add some comments here.
1624 * giscanner/glibtransformer.py: Add _adjust_transfer
1625 phase for tweaking GObject transfers.
1628 2008-10-16 Tommi Komulainen <tommi.komulainen@iki.fi>
1630 * configure.ac: enable bunch of gcc warning CFLAGS
1632 2008-10-16 Tommi Komulainen <tommi.komulainen@iki.fi>
1634 Bug 556543 – reduce compiler warnings
1636 * girepository/ginfo.c:
1637 * girepository/girepository.c (register_internal,
1638 count_interfaces, find_interface, find_namespace_version,
1639 parse_version, g_irepository_require):
1640 * girepository/girmodule.c (g_ir_module_build_typelib):
1641 * girepository/girnode.c (init_stats, dump_stats,
1642 _g_irnode_init_stats, _g_irnode_dump_stats,
1643 g_ir_node_can_have_member):
1644 * girepository/girparser.c (firstpass_end_element_handler,
1645 locate_gir, parse_basic, parse_type_internal, resolve_aliases,
1646 start_alias, start_type, end_type_top, parse_include, cleanup,
1648 * girepository/gtypelib.c (validate_function_blob, validate_enum_blob):
1649 * giscanner/giscannermodule.c (directive_get_options,
1650 type_get_child_list):
1651 * giscanner/scannerlexer.l (parse_gtkdoc):
1652 * giscanner/scannerparser.y (ctype_free):
1653 * giscanner/sourcescanner.c:
1654 * giscanner/sourcescanner.h (gi_source_scanner_parse_macros):
1655 * tests/types/gitesttypes.c:
1656 * tools/compiler.c (main):
1657 * tools/generate.c (write_repository): Remove unused variables
1658 and code, add missing includes, declarations and case
1661 2008-10-16 Tommi Komulainen <tommi.komulainen@iki.fi>
1663 Bug 556541 – access union members through UnionBlob rather than
1666 * girepository/ginfo.c (g_union_info_find_method): access union
1667 members through UnionBlob rather than StructBlob
1669 2008-10-15 Colin Walters <walters@verbum.org>
1671 Bug 556331 - clean up includes handling
1673 * tools/g-ir-scanner: Rework command line arguments; now we take
1674 --add-include-path and --include separately.
1675 * giscanner/girwriter.py: Separate name= and version= in include
1677 * giscanner/ast.py: Add Include type.
1678 * giscanner/transformer.py: Cleanups to register_include now that
1679 we don't need to handle mixed filenames and relative arguments.
1680 * girepository/girparser.c: Parse name and version separately;
1681 this fixes a bug as a side effect where we weren't resolving
1682 through aliases for basic types.
1683 * girepository/girepository.c: Fix format string args.
1684 * gir/Makefile.am: Update.
1687 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1689 Bug 556434 – unhandled interface/object/... member types
1691 * girepository/girnode.c (g_ir_node_check_unhandled_members,
1692 g_ir_node_build_typelib): Check all
1693 interface/object/boxed/struct/union members are processed and
1694 abort if they are not. (Mostly callbacks in structs, but also
1695 fields in interfaces.)
1697 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1699 * a/girepository/girnode.c (g_ir_node_build_members,
1700 g_ir_node_build_typelib): refactor common code for processing
1701 members to a function
1703 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1705 * gir/Makefile.am (check-local): check that typelib -> gir -> typelib
1706 transformation is lossless (it's not)
1708 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1710 * tests/Makefile.am: fix tests to compare xml to xml instead of
1711 typelib to xml, and stop on error
1713 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1715 * tools/generate.c (write_type_name, write_type_info,
1716 write_type_info, write_object_info, write_object_info,
1717 write_interface_info, write_error_domain_info): reduce code
1720 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1722 Bug 556174 – parse types for lists etc.
1724 * girepository/girparser.c (end_type_recurse):
1726 * tools/generate.c (write_type_info, write_field_info,
1727 write_callable_info, write_callable_info, write_constant_info,
1728 write_property_info): use nested <type>s for lists and hashes
1730 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1733 * tests/object.gir: remove trailing whitespace from inside
1734 elements to match g-ir-generate output
1736 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1738 * tools/generate.c (xml_printf): quote printf arguments so that
1739 we don't generate invalid XML by writing unescaped double quotes
1740 and such in attributes
1742 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1744 * tools/generate.c (write_field_info, write_callable_info,
1745 write_function_info, write_callback_info, write_struct_info,
1746 write_constant_value, write_signal_info, write_vfunc_info,
1747 write_object_info, write_interface_info, write_union_info,
1748 write_repository): remove unused indent parameters, xmlwriter
1749 keeps track of necessary indentation
1751 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1753 * tools/generate.c (xml_element_new, xml_element_free,
1754 xml_start_element, xml_end_element, xml_end_element_unchecked,
1755 xml_open, xml_close): Keep track of generated XML tree and
1756 handle indentation and closing tags properly.
1757 (write_field_info, write_callable_info, write_function_info,
1758 write_callback_info, write_struct_info, write_value_info,
1759 write_constant_info, write_enum_info, write_signal_info,
1760 write_vfunc_info, write_property_info, write_object_info,
1761 write_interface_info, write_error_domain_info, write_union_info,
1762 write_repository): Use xml_start_element and xml_end_element to
1765 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1767 * tools/generate.c (xml_printf, xml_open, xml_close, xml_free):
1768 (write_type_name, write_type_info, write_field_info,
1769 write_callable_info, write_function_info, write_callback_info,
1770 write_struct_info, write_value_info, write_constant_value,
1771 write_constant_info, write_enum_info, write_signal_info,
1772 write_vfunc_info, write_property_info, write_object_info,
1773 write_interface_info, write_error_domain_info, write_union_info,
1774 write_repository): wrap all FILE access to go through simple xmlwriter
1776 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1778 Bug 556400 – Fails to build on OS X 10.4
1780 * configure.ac: check for functions backtrace and backtrace_symbols
1781 * girepository/girparser.c (backtrace_stderr): Comment out
1782 implementation if the functions are not available.
1783 * gcov.mak (clean-gcov, clean-gcno): always call 'find' with a
1784 directory for better portability
1786 2008-10-15 Johan Bilien <jobi@via.ecp.fr>
1788 Bug 556433 – assume direction = out for int * parameters
1790 * giscanner/ast.py: define a list of types for which, if passed as
1791 reference, we assume a default direction of 'out'
1792 * giscanner/transformer.py: if a type has type pointer to one of the
1793 previously defined types, and no direction is set, assume out.
1794 * tests/scanner/drawable.[ch]: added tests for guessed direction=out
1796 2008-10-15 Johan Bilien <jobi@via.ecp.fr>
1798 * tests/scanner/annotation.c: fixed a few copy-paste errors
1800 2008-10-14 Johan Bilien <jobi@via.ecp.fr>
1802 Bug 556323 – transfer-ownership is wrong for functions returning const
1805 * giscanner/transformer.py: check for a const string as return value,
1806 not just const char*. Suggested by Colin Walters
1807 * tests/scanner/annotation-1.0-expected.gir: updated expected output
1809 2008-10-14 Johan Bilien <jobi@via.ecp.fr>
1811 * girepository/ginfo.c, girepository/girepository.h: add
1812 g_union_info_find_method
1814 2008-10-14 Colin Walters <walters@verbum.org>
1816 * tests/repository/Makefile.am: Reenable repo test.
1817 * tests/repository/gitestrepo.c: Prepend search
1818 path for $(top_builddir)/gir dir so that we don't
1819 require installation for "make check" to pass.
1821 2008-10-13 Jürg Billeter <j@bitron.ch>
1823 * giscanner/glibtransformer.py:
1824 * tests/scanner/annotation-1.0-expected.gir:
1825 * tests/scanner/drawable-1.0-expected.gir:
1826 * tests/scanner/foo-1.0-expected.gir:
1827 * tests/scanner/utility-1.0-expected.gir:
1829 Support fields in GObject structs
1831 2008-10-13 Jürg Billeter <j@bitron.ch>
1833 * giscanner/ast.py: add signed integer and off_t to type_names
1835 2008-10-12 Jürg Billeter <j@bitron.ch>
1837 * giscanner/girparser.py: Parse bits attribute of fields
1839 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1841 * tests/repository/Makefile.am: run 'gitestrepo' in 'make check'
1842 * tests/repository/gitestrepo.c (main): instantiate
1843 'GCancellable' to ensure the GType is registered before using
1846 2008-10-12 Johan Bilien <jobi@via.ecp.fr>
1848 * giscanner/girparser.py: actually add the parsed constant nodes
1850 2008-10-12 Colin Walters <walters@verbum.org>
1852 * girepository/girepository.c: Don't cast DirEntry to Blob,
1853 actually look it up by offset.
1855 2008-10-12 Johan Bilien <jobi@via.ecp.fr>
1857 * giscanner/girparser.py: parse constant nodes in gir files
1859 2008-10-12 Johan Bilien <jobi@via.ecp.fr>
1861 * giscanner/transformer.py: prefix for constants have an underscore,
1862 so remove them as if they were functions, not objects.
1864 2008-10-12 Johan Bilien <jobi@via.ecp.fr>
1866 * tests/scanner/foo-1.0-expected.gir: add constants to expected gir
1869 2008-10-12 Colin Walters <walters@verbum.org>
1871 Initial patch from Jani Monoses.
1873 * girepository/gtypelib.c: Fix inverted test for success
1876 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1878 * tools/generate.c (write_callable_info): use "transfer-ownership"
1879 attribute for return values
1881 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1883 * tools/generate.c (write_callable_info): move "transfer" and
1884 "null-ok" attributes from <function> to <return-value> element
1886 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1888 * girepository/girparser.c (start_return_value): handle
1889 "transfer-ownership" attribute
1891 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1893 * girepository/girparser.c (parse_param_transfer):
1894 * tools/generate.c (write_callable_info): use "container" for
1895 container/shallow ownership transfer (not "shallow")
1897 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1899 * girepository/girparser.c (parse_param_transfer,
1900 start_parameter): Refactor handling of transfer=none/shallow/full
1901 to separate function
1903 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1905 Bug 556048 – Crash in g_irepository_find_by_gtype
1907 * girepository/gtypelib.h (BLOB_IS_REGISTERED_TYPE): added
1908 * girepository/girepository.c (find_interface): Fix
1909 find_by_gtype case to get the type name from right offset
1911 2008-10-12 Jürg Billeter <j@bitron.ch>
1913 * giscanner/girparser.py: Fix parsing transfer-ownership attribute
1916 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1918 * girepository/gtypelib.h (RegisteredTypeBlob): make
1919 'unregistered' one bit wide as everywhere else
1921 2008-10-12 Jürg Billeter <j@bitron.ch>
1923 * giscanner/glibtransformer.py:
1924 * tests/scanner/annotation-1.0-expected.gir:
1925 * tests/scanner/drawable-1.0-expected.gir:
1926 * tests/scanner/drawable.h:
1927 * tests/scanner/foo-1.0-expected.gir:
1928 * tests/scanner/utility-1.0-expected.gir:
1930 Readd class records as workaround to not break Gtk typelib
1932 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1934 * tests/types/Makefile.am: fix typo in gitesttypes namespace
1936 2008-10-12 Jürg Billeter <j@bitron.ch>
1938 * giscanner/glibtransformer.py: Don't generate <record> elements
1940 * tests/scanner/*: Update test cases
1942 2008-10-11 Colin Walters <walters@verbum.org>
1944 Bug 552858: versioning
1946 This is a big patch. You should probably remove your installation
1949 * docs/typelib-format.txt: Add nsversion entry which holds
1950 version of namespace.
1951 * girepository/girepository.h: Add 'version' parameter to
1952 g_irepository_require. This may be NULL. Normally
1953 bindings should pass an explicit version though.
1954 * girepository/girepository.c: Lots of infrastructure to
1955 support versioning. Add some more documentation. Disallow
1956 some usage of NULL namespaces.
1957 * girepository/girmodule.c: Add version parameter.
1958 * girepository/gtypelib.c: Update header size.
1959 * giscanner/ast.py: Add version to Namespace.
1960 * giscanner/girparser.py: Parse version attribute from
1961 XML, pass to Namespace.
1962 * giscanner/girwriter.py: Write out version parameter.
1963 * giscanner/transformer.py: Clean up include registration.
1964 * tests/*: Add version attribute.
1965 * tests/invoke/invoke.c: Don't try looking up test before
1966 it's loaded in repository.
1967 * tools/generate.c: Output version parameter.
1968 * gir/Makefile.am: Add 2.0 version to .gir files.
1970 2008-10-11 Colin Walters <walters@verbum.org>
1972 * giscanner/scannerlexer.l (parse_gtkdoc): Don't lose
1973 if we have mismatched parens.
1975 2008-10-11 Lucas Rocha <lucasr@gnome.org>
1977 * giscanner/girparser.py (_parse_enumeration_bitfield): fix typo
1978 on 'members' variable.
1980 2008-10-11 Colin Walters <walters@verbum.org>
1982 Bug 555947 - update annotations syntax
1984 * giscanner/ast.py: Default to None for transfer. Remove
1985 default transfers for container types; we require this to
1987 * giscanner/girwriter.py: Transfer is now 'none', 'container',
1988 'full' to match repository.
1989 * giscanner/scannerlexer.l: Annotations now are parenthesized.
1990 * giscanner/transformer.py: Update for new annotations syntax.
1993 2008-10-11 Johan Bilien <jobi@litl.com>
1995 * giscanner/scannerparser.y: ignore non-UTF-8 string constants
1997 2008-10-11 Johan Bilien <jobi@litl.com>
1999 Bug 552347: Parse #defines constants
2001 * girepository/gtypelib.c: update the list of value_size
2002 with recently defined type tags
2003 * giscanner/scannerparser.y: brought back parsing of #defined, as
2004 present in older version
2005 * giscanner/giscannermodule.c: bind gi_source_scanner_append_filename
2006 * giscanner/girwriter.py: write out constant tags in the gir
2007 * giscanner/sourcescanner.py: add accessor for const_string
2008 * giscanner/transformer.py, giscanner/glibtransformer.py: handle
2011 2008-10-11 Tommi Komulainen <tommi.komulainen@iki.fi>
2013 Bug 555946: Install a test module exercising all types, transfer
2018 * tests/types/*: Add and install a test module that has functions
2019 accepting and returning most of the basic types to enable bindings
2020 implementors to more easily test their type conversion routines.
2022 2008-10-11 Jürg Billeter <j@bitron.ch>
2024 Bug 552374: Const strings should be identified in the gir.
2026 * giscanner/transformer.py: support string memory management
2027 * tests/scanner/foo.h: use char * and const char *
2028 * tests/scanner/foo-expected.gir: test that
2030 2008-10-11 Johan Dahlin <johan@gnome.org>
2032 * giscanner/girparser.py:
2033 Also parse enums which are not glib types.
2035 2008-10-11 Lucas Rocha <lucasr@gnome.org>
2037 Bug 552370: add one more test for unsigned as a type, not as
2040 * giscanner/ast.py: add 'uint' type name for 'unsigned'.
2041 * test/scanner/foo.h: add function which uses unsigned as a type.
2042 * test/scanner/foo-expected.gir: test that.
2044 2008-10-11 Andreas Rottmann <a.rottmann@gmx.at>
2046 Bug 555712: Struct and union issues
2048 * giscanner/scannerparser.y (struct_declarator): Use information
2049 provided about the bit width of a field.
2050 * giscanner/transformer.py (Transformer._create_member): Pass the
2051 symbol's const_int member to the created field (it represents the
2053 * giscanner/girwriter.py (GIRWriter._write_field): Output 'bits'
2054 field attribute, if present.
2055 * giscanner/ast.py (Field): Add 'bits' member, specifying the
2056 width in bits of the field (only relevant for bitfields).
2059 * giscanner/transformer.py (Transformer._create_typedef_struct)
2060 (Transformer._create_typedef_union): Add calls to _create_struct()
2061 and _create_union(), respectively. This causes the scanner to
2062 generate output for fields of struct and union typedefs.
2065 2008-10-11 Jürg Billeter <j@bitron.ch>
2067 Bug 552370: unsigned not scanned properly
2069 * giscanner/scannerparser.y: combine basic types such as unsigned
2070 int and long long when scanning
2071 * tests/scanner/foo-expected.gir:
2072 * tests/scanner/foo.c: (foo_test_unsigned):
2073 * tests/scanner/foo.h: test that
2075 2008-10-11 Lucas Rocha <lucasr@gnome.org>
2077 Bug 554854: The --typelib-xml and --inject options should reuse
2078 giscanner parser/writer.
2080 * giscanner/ast.py: add constructor list to Struct and Union.
2081 Add new param in Return's contructor to define transfer.
2082 * giscanner/girparser.py: several additions to the parser in order
2083 to have parsing all nodes of the gir xml files.
2084 * tools/g-ir-scanner (typelib_xml_strip, inject): use gir parser
2085 and writer in --inject and --typelib-xml options.
2086 * giscanner/xmlwriter.py: ignore empty attributes instead of
2087 raising an error as this basically exposes a bug in GIRParser.
2088 This should be reverted as soon as the parser is fixed.
2090 2008-10-11 Lucas Rocha <lucasr@gnome.org>
2092 Bug 552376: scanner generates wrong names for enum members when
2093 there's no defined gtype.
2095 * giscanner/utils.py (strip_common_prefix): Always strip common
2096 prefix exactly up to the last "_", and not beyond.
2097 * tests/scanner/foo.h (FooEnumNoType): add FOO_ENUM_NEUF. The point
2098 here is that the first character after the last '_' should should be
2099 the same as the character in the same position on the type name.
2100 * tests/scanner/foo-expected.gir: test that
2102 2008-10-10 Lucas Rocha <lucasr@gnome.org>
2104 Bug 555293: append library_paths to LPATH env variable to work
2105 around a bug in find_library when using ldconfig.
2107 * tools/g-ir-scanner (main): ditto.
2109 2008-10-09 Lucas Rocha <lucasr@gnome.org>
2111 * girepository/girepository.c (register_internal): fix regression on
2112 invoke test case by making sure we load the global module in the
2113 typelib when dealing with inline typelibs.
2114 * girepository/gtypelib.c: a couple of coding style fixes.
2116 2008-10-06 Lucas Rocha <lucasr@gnome.org>
2118 Bug 555294: Add support for multiple shared libraries per typelib.
2120 * girepository/ginvoke.c (g_function_info_invoke),
2121 girepository/ginfo.c(g_registered_type_info_get_g_type): use
2122 g_typelib_symbol instead of g_module_symbol.
2123 * girepository/girepository.h: remove g_typelib_set_module and add
2125 * girepository/gtypelib.[ch] (find_some_symbol, _g_typelib_init,
2126 g_typelib_new_from_memory, g_typelib_new_from_const_memory,
2127 g_typelib_free, g_typelib_symbol): chnage GTypeLib to hold a list of
2128 modules instead of just one. The symbol lookup is now abstracted
2129 behind g_typelib_symbol which tries to find the passed symbol name in
2131 * giscanner/girwriter.py, tools/g-ir-scanner: change scanner to read
2132 and write shared_library attribute as a comma-separated list of libs.
2134 2008-10-06 Colin Walters <walters@verbum.org>
2136 * giscanner/transformer.py: Parse length= annotation as
2137 a parameter name, not a raw int.
2140 2008-10-03 Colin Walters <walters@verbum.org>
2142 Bug 551744: Non-GObject types aren't aggregating ctors and methods
2144 * girepository/gtypelib.c: Allow ctors/methods on struct,union,
2146 * giscanner/glibtransformer.py: Ditto, and GLibBoxed is also a
2150 2008-10-03 Colin Walters <walters@verbum.org>
2152 Bug 554576: scan problem with ev_selection_render_selection()
2154 * giscanner/transformer.py: Only do type resolution once we've
2155 scanned all types. What could happen before is that we'd strip
2156 the namespace from local type "EvSelection" => Selection, and
2157 then later pull a "Selection" from some other namespace because
2158 we hadn't yet seen the local EvSelection. This could come
2159 down to hash table ordering and other things so not easy
2160 to write a test for.
2162 2008-10-03 Lucas Rocha <lucasr@gnome.org>
2164 * giscanner/girwriter.py (_parser_member): fix the last parameter of
2165 GLibEnumMember constructor as it should be the enum member nick.
2167 2008-10-02 Colin Walters <walters@verbum.org>
2169 Bug 552961: remove this parameter for methods
2171 * giscanner/glibtransformer.py: Delete this parameter; it is
2173 * girepository/ginvoke.c: Insert this parameter for methods.
2174 * girepository/gtypelib.c: Remove no longer needed verification of
2175 method this parameter.
2178 2008-09-30 Dan Winship <danw@gnome.org>
2180 Bug 554490: g-ir-scanner gets confused by '\\'
2182 * giscanner/scannerlexer.l (chartext, stringtext): fix use of
2183 backslashes so it will correctly parse '\\' and "\\"
2185 * tests/scanner/annotation.c: add a use of '\\' to make sure that
2188 * giscanner/glibtransformer.py (GLibTransformer.count_type): typo
2190 2008-10-02 Colin Walters <walters@verbum.org>
2192 bug 552393: Note variadic functions
2194 * giscanner/scannerparser.y: Parse ellipsis. Refactor grammar
2195 to use parameter_list directly.
2196 * giscanner/sourcescanner.h: Add ellipsis csymbol type.
2197 * giscanner/ast.py: Add Varargs type.
2198 * giscanner/transformer.py: Check for ellipsis symbol, transform
2200 * girepository/girnode.h: Add varargs flag to in-memory nodes.
2201 Parse varargs functions, but filter them out before we start
2202 compiling the typelib.
2204 2008-10-02 Colin Walters <walters@verbum.org>
2206 Bug 554632: type tag for GType
2208 * girepository/girepository.h, girepository/girepository.c:
2209 Add type tag for GType - it's a special type we don't want
2210 to resolve to just "long".
2211 * docs/typelib-format.txt: Update.
2212 * girepository/girparser.c: Parse it.
2213 * giscanner/glibtransformer.py: Ensure we don't put GType in
2215 * tools/generate.c: Remove hardcoded type list.
2218 2008-09-30 Dan Winship <danw@gnome.org>
2220 Bug 554521: scanner generates wrong names for enum members with
2221 full type name prefix
2223 * giscanner/utils.py (strip_common_prefix): Fix this to strip the
2224 right amount when the entire "first" string is a prefix of
2227 * tests/scanner/foo.h (FooEnumFullname):
2228 * tests/scanner/foo-expected.gir: test that
2230 2008-09-29 Colin Walters <walters@verbum.org>
2232 Bug 552380: Array parameters should be marked in the gir
2234 * giscanner/ast.py: Default char** to utf8[], and guchar* to
2235 uint8[]. Add Array, List, and Map subclasses of Type;
2236 these types can be generic. Return transfer defaults
2237 to true if return value is string or container type.
2238 Delete Sequence type.
2239 * giscanner/scannerlexer.l: Syntax change for annotations;
2240 use <> since it's more readable.
2241 * giscanner/girwriter.py: Write out these changes.
2242 * giscanner/girparser.py: Parse them.
2243 * giscanner/transformer.py: Have a defined set of
2244 both list and map types. When creating a type,
2245 check if the ctype we've parsed is one of them,
2246 if so create a container type subclass as appropriate.
2247 * girepository/girparser.c: Parse in generic types.
2250 2008-09-27 Colin Walters <walters@verbum.org>
2252 * tools/g-ir-scanner: Add --inject option.
2254 2008-09-25 Colin Walters <walters@verbum.org>
2256 Remove non-repository types from GIR
2258 * giscanner/ast.py: The canonical name is 'utf8', not
2260 * giscanner/glibast.py: A few more glib type mappings.
2261 * girepository/girparser.c: We only parse repository types.
2262 * tests/*.gir: Update.
2264 2008-09-23 Colin Walters <walters@verbum.org>
2266 Bug 552566: Add time_t type
2268 We need a type for time_t since it's special in C, and just
2269 mapping it to long precluded bindings from handling it
2272 2008-09-19 Colin Walters <walters@verbum.org>
2274 Bug 552390: Handle capitialization like "DBus" more robustly
2276 The to_underscores function was designed for use against prefixed
2277 names; we need a separate function which will convert names like
2278 DBusFoo into dbus_foo, not d_bus_foo.
2280 2008-09-19 Colin Walters <walters@verbum.org>
2282 Add check to make sure we're not hitting out unresolved types
2284 Validate the "this" argument for methods
2286 Remove heuristic matching of methods to classes based on prefix
2288 It was a broken hack that dated from when we handled underscoring
2289 and capitalization conventions less well.
2291 2008-09-18 Colin Walters <walters@verbum.org>
2293 Bug 552384: Use SHLIB_SUFFIX intead of G_MODULE_SUFFIX for Darwin
2295 On Darwin, the suffix for installed shared libraries (.dylib) is
2296 different from loadable modules (.so). We use a bit of magic shell
2297 script from Behdad Esfahbod to figure out the right suffix.
2299 2008-09-15 Johan Dahlin <johan@gnome.org>
2301 * giscanner/sourcescanner.py (SourceType.type_qualifier): Add
2302 a wrapper for type_qualifier as well.
2304 2008-09-15 Colin Walters <walters@verbum.org>
2306 http://bugzilla.gnome.org/show_bug.cgi?id=552065
2308 * giscanner/ast.py: Add deprecation attributes.
2309 * giscanner/girwriter.py: Write out deprecation data.
2310 * girepository/girparser.c: Relax parsing; deprecated
2311 attribute now includes freeform string.
2312 * giscanner/scannerlexer.l: Parse Deprecated.
2313 * giscanner/transformer.py: Look for deprecated attribute
2315 * tests/scanner/*: Add a Deprecated test.
2317 2008-09-14 Tor Lillqvist <tml@novell.com>
2319 * tests/scanner/Makefile.am (%.typelib): Use $(EXEEXT).
2321 2008-09-14 Colin Walters <walters@verbum.org>
2323 * giscanner/glibtransformer.py: Ignore functions with
2326 2008-09-12 Colin Walters <walters@verbum.org>
2328 * giscanner/glibtransformer.py: Accept Gtk.Type as GType.
2330 2008-09-12 Colin Walters <walters@verbum.org>
2332 * giscanner/ast.py: Bind pid_t to INT for vte.
2334 2008-09-12 Colin Walters <walters@verbum.org>
2336 * giscanner/girparser.py: Parse c:type for boxed records/unions.
2337 * giscanner/glibast.py: Avoid overwriting ctype.
2338 * giscsanner/transformer.py: Try resolving types using the GType names.
2340 2008-09-12 Colin Walters <walters@verbum.org>
2342 * giscanner/minixpath.py: Code to run an "XPath"
2343 assertion against an XML tree, taken from
2344 gir-repository/gir/tests.py.
2345 * giscanner/Makefile.am: Ship it.
2346 * tools/g-ir-scanner: Add --xpath-assertions option.
2347 * gir/GLib-assertions.txt: Add a few assertions.
2348 * gir/Makefile.am: Run them.
2350 2008-09-11 Colin Walters <walters@verbum.org>
2352 http://bugzilla.gnome.org/show_bug.cgi?id=551737
2354 * giscanner/transformer.py: Fix strip_namespace_func to only strip
2355 prefix if it ends with _. Tweak callback stripping to determine
2356 based on presence of _ whether we need to use strip_namespace_func
2357 or strip_namespace_object.
2359 2008-09-09 Owen Taylor <otaylor@redhat.com>
2361 * docs/typelib-format.txt: Wether => Whether
2363 2008-09-08 Colin Walters <walters@verbum.org>
2365 * girepository/girparser.c: Default to "readable" for properties.
2366 * giscanner/ast.py: Add readable, writable etc.
2367 * giscanner/girwriter.py: Writ them.
2368 * giscanner/glibtransformer.py: Inspect them.
2371 2008-09-07 Colin Walters <walters@verbum.org>
2373 * giscanner/cgobject.py: Add comment.
2375 2008-09-07 Colin Walters <walters@verbum.org>
2377 * giscanner/cgobject.py: Also call g_thread_init.
2379 2008-09-07 Colin Walters <walters@verbum.org>
2381 * giscanner/transformer.py: Fix regression by not
2382 stripping prefix before stripping namespace for unions
2385 2008-09-06 Colin Walters <walters@verbum.org>
2387 * giscanner/transformer.py: If a namespace contains
2388 multiple caps, try stripping both gnomekeyring_ and
2391 2008-09-07 Johan Dahlin <johan@gnome.org>
2393 Bug 551162 – giscanner does not recognize asm and __asm__
2394 * giscanner/scannerlexer.l:
2395 Patch by Jani Monoses.
2397 2008-09-06 Colin Walters <walters@verbum.org>
2399 * girepository/girnode.c: Allow gtype_name
2400 and gtype_init in struct and union.
2401 * girepository/girparser.c: Parse glib:
2402 boxed bits for both structure and union.
2403 * girepository/gtypelib.c: Don't barf
2404 if structure is boxed.
2405 * giscanner/girparser.py: Parse new XML
2407 * giscanner/girwriter.py: Write out new
2409 * giscanner/glibast.py: Define new classes
2410 which are both Boxed and Struct/Union, as
2411 well as an "Other" for everything else.
2412 * giscanner/glibtransformer.py: Handle
2413 boxed types specially; we try to merge
2414 them with a struct/union if one exists,
2415 otherwise fall back to generic boxed.
2417 * tools/generate.c: Write out new format.
2419 2008-09-06 Johan Dahlin <johan@gnome.org>
2421 * giscanner/grealpath.h: Include stdlib.h
2423 * docs/g-ir-generate.1: Remove leading %
2425 2008-09-01 Colin Walters <walters@verbum.org>
2427 * girepository/girparser.c: Look at c:type to determine
2428 whether or not an item is a pointer.
2430 2008-09-01 Johan Dahlin <johan@gnome.org>
2432 * tests/scanner/Makefile.am:
2433 Set PYTHONPATH so the scanner can run
2434 even if you didn't install anything.
2436 2008-09-01 Johan Dahlin <johan@gnome.org>
2439 Post-release version bump
2442 2008-09-01 Johan Dahlin <johan@gnome.org>
2446 2008-08-31 Colin Walters <walters@verbum.org>
2448 * giscanner/glibtransformer.py: Quiet info
2451 2008-08-31 Johan Dahlin <johan@gnome.org>
2454 Bump version to 0.5.0
2456 2008-08-31 Colin Walters <walters@verbum.org>
2458 * giscanner/glibtransformer.py: Follow aliases to ensure
2459 we don't get a constructor returning a basic type.
2460 * giscanner/transformer.py: Add function to follow aliases.
2463 2008-08-31 Johan Dahlin <johan@gnome.org>
2465 * giscanner/scannerlexer.l:
2466 * giscanner/scannerparser.y:
2467 * giscanner/sourcescanner.h:
2468 * giscanner/sourcescanner.py:
2469 Parse GCC extensions in the parser instead of just undeffing them
2470 in the pre-processor.
2472 2008-08-31 Johan Dahlin <johan@gnome.org>
2474 * giscanner/glibtransformer.py:
2475 Clean up a huge if. Do not add methods or constructors
2477 * giscanner/utils.py:
2478 second might be longer than first, check that.
2480 2008-08-31 Johan Dahlin <johan@gnome.org>
2485 2008-08-31 Colin Walters <walters@verbum.org>
2487 * girepository/girparser.c: Don't lose if we
2490 2008-08-31 Colin Walters <walters@verbum.org>
2492 * giscanner/glibtransformer.py: Look for libtool
2493 library in current directory
2494 * tests/scanner - Update.
2496 2008-08-30 Colin Walters <walters@verbum.org>
2498 * docs/typelib-format.txt: Add a guint32
2500 * gir/Makefile.am: Dep on Makefile
2501 * girepository/ginfo.c:
2502 * girepository/girepository.c: Clean up
2503 default typelib handling; remove global
2504 default_typelib variable. Ensure we handle
2505 NULL repository in more places.
2506 Support dependency resolution.
2507 Support lazy loading.
2508 * girepository/girepository.h: Remove
2509 g_irepository_unregister; we don't support
2510 unloading typelibs since really they're
2511 process-global. Update for lazy loading
2513 * girepository/girmodule.c: Use g_new0.
2514 Add dependencies to GirModule.
2515 * girepository/girparser.c: Parse dependencies.
2516 * girepository/gtypelib.c: Add 4 bytes for
2518 * tests/Makefile.am: Kill off gobject.gir,
2519 it conflicts with the real one.
2520 * tests/object.gir: Dep on GObject.
2521 * tools/generate.c: Take --includedir
2522 argument to say which directories to search
2523 for typelibs. Print out dependencies.
2525 2008-08-30 Colin Walters <walters@verbum.org>
2527 * giscanner/glibtransformer.py: Reduce warning noise.
2529 2008-08-29 Colin Walters <walters@verbum.org>
2531 * girepository/ginfo.c: Add some assertions regarding
2532 refcounts, just to be sure.
2533 * giscanner/glibtransformer.py: Blacklist a few more
2536 2008-08-29 Colin Walters <walters@verbum.org>
2538 * giscanner/glibtransformer.py: Blacklist a few
2539 functions that use GError oddly
2541 2008-08-29 Colin Walters <walters@verbum.org>
2543 * girepository/gtypelib.c: Don't crash if no
2546 2008-08-29 Colin Walters <walters@verbum.org>
2548 * girepository/girparser.c: Handle chains of aliases
2549 across modules by ensuring we fully qualify aliases
2552 2008-08-29 Colin Walters <walters@verbum.org>
2554 * girepository/girparser.c: Don't search aliases
2557 2008-08-29 Colin Walters <walters@verbum.org>
2559 * girepository/girparser.c: Rewrite type parsing
2560 to handle both GLib parsing case as well as correctly
2561 handling GLib.List and friends. Don't try to treat
2562 e.g. ListStore as a List.
2564 2008-08-29 Colin Walters <walters@verbum.org>
2566 * girepository/gtypelib.c: Add more context
2569 2008-08-29 Colin Walters <walters@verbum.org>
2571 * giscanner/glibtransformer.py: Add some informative
2572 logging messages in corner cases. Be sure we use
2573 the most recent node set instead of a cache
2574 when generating result set.
2575 * tests/: Remove duplicated bits in expected girs
2576 * girepository/girparser.c: Accept both List (for
2577 compiling GLib) and GLib.List (what the scanner
2580 * tools/generate.c: Generate canonical form.
2582 2008-08-29 Johan Dahlin <johan@gnome.org>
2584 * giscanner/config.py.in:
2585 Use datarootdir instead of datadir to avoid
2586 an autoconf warning.
2588 2008-08-29 Johan Dahlin <johan@gnome.org>
2592 * examples/gdk-pixbuf.gidl:
2594 Update and remove old cruft.
2596 2008-08-29 Johan Dahlin <johan@gnome.org>
2599 * docs/g-ir-compiler.1:
2600 * docs/g-ir-generate.1:
2601 * docs/g-ir-scanner.1:
2602 Add man pages for the generator and compiler.
2604 2008-08-29 Johan Dahlin <johan@gnome.org>
2606 * docs/g-ir-scanner.1: Document
2608 * giscanner/Makefile.am:
2609 * giscanner/gidlparser.py:
2610 * giscanner/gidlwriter.py:
2611 * tools/g-ir-scanner:
2612 Remove gidl support.
2614 2008-08-28 Colin Walters <walters@verbum.org>
2616 * tests/scanner/Makefile.am: Pass the right
2617 --includedir args. Add a Makefile dep.
2618 * tools/compiler.c: Pass includedirs down.
2619 * girepository/girparser.c: Actually put
2620 includedirs in context, pass down. Fix
2623 2008-08-28 Colin Walters <walters@verbum.org>
2625 * gir/Makefile.am: Use --includedir
2626 * girepository/girparser.c: Recursively parse
2627 includes to pull in aliases and expand them.
2628 We need this to avoid putting unknown names in
2630 * tools/compiler.c: Add --includedir option.
2631 * giscanner/ast.py: Map size/ssize to types
2634 2008-08-28 Tor Lillqvist <tml@novell.com>
2636 Make check now runs successfully on Windows.
2638 * tools/compiler.c (write_out_typelib): Use binary mode for output
2641 * girepository/girnode.c: Don't print NULL strings.
2643 * tests/invoke/Makefile.am
2644 * tests/scanner/Makefile.am: Use -no-undefined on Windows to
2645 convince libtool to build shared libraries.
2647 * tests/invoke/invoke.c: Don't needlessly include <dlfcn.h>. Use
2648 g_assert() instead of printing out expected errors.
2650 2008-08-28 Tor Lillqvist <tml@novell.com>
2652 * girepository/gtypelib.h: Change type of bitfield fields from
2653 guint to the most suitable smaller type. This makes the struct
2654 sizes match the ones on Linux that the sanity check expects when
2655 using gcc -mms-bitfields on Windows.
2657 2008-08-28 Johan Dahlin <johan@gnome.org>
2662 * giscanner/Makefile.am:
2663 * tests/Makefile.am:
2664 * tests/scanner/Makefile.am:
2665 Make distcheck pass.
2667 2008-08-27 Johan Dahlin <johan@gnome.org>
2669 * giscanner/Makefile.am:
2670 Only send in -no-undefined on Win32 as it breaks on MacOS X.
2672 2008-08-27 Tor Lillqvist <tml@novell.com>
2674 Make g-ir-scanner work on Windows. Still problems with the typelib
2675 code. Changes okayed by jdahlin.
2677 * configure.ac: Check for Windows, set Automake conditional
2678 OS_WIN32. Change backslashes to forward slashes in pyexecdir to
2679 avoid shell quoting issues
2681 * girepository/Makefile.am: Use -no-undefined so that libtool
2682 agrees to build a shared library on Windows.
2684 * girepository/girparser.c (backtrace_stderr): No backtrace() on
2685 Windows. Empty implementation on Windows so far.
2687 * girepository/gtypelib.c (g_typelib_check_sanity): Give more
2688 informative error message for the assertion failures. Tell also
2689 what the expected size of the struct is. Check all sizes first and
2690 fail afterwards if at least one size was different from expected.
2692 * tools/Makefile.am: Reorder libraries into proper logical
2695 * tools/generate.c: Don't include <dlfcn.h>, not used.
2697 * giscanner/Makefile.am: On Windows, link with the Python library,
2698 and install the module DLL as _giscanner.pyd. Remove the
2699 unnecessary import library and libtool library that libtool has
2702 * giscanner/scannerlexer.l: Recognize the gcc __attribute__ syntax
2703 and just skip it. Recognize also two "l" suffixes for long long
2704 constants. Recognize also __inline__.
2706 * giscanner/grealpath.h (g_realpath): Implement on Windows, using
2707 GetFullPathName(). As such, GetFullPathName() does more than the
2708 UNIX realpath(). It also changes relative paths into absolute
2709 paths. But for our purposes that shouldn't matter.
2711 * giscanner/giscannermodule.c (pygi_source_scanner_parse_file): On
2712 Windows the file descriptor passed to us is from Python. Python
2713 Python2.5 uses the msvcr71.dll C library, while mingw-built code
2714 uses msvcrt.dll. On Windows, file descriptors are specific to
2715 which C library is used. So we must find out what underlying OS
2716 handle corresponds to the file descriptor Python passes us, and
2717 then make that into a file descriptor valid for the C library this
2720 * giscanner/sourcescanner.py (_parse): Don't need to bypass
2721 __attribute__ as the lexer now handles it. The definition as empty
2722 was ineffective for mingw anyway, as mingw's _mingw.h undefines
2723 __attribute__. Close the temp file before unlinking it.
2725 * giscanner/cgobject.py: Use correct library name for the gobject
2728 * gir/Makefile.am: Must pass the full basename of the DLLs on
2729 Windows to g-ir-scanner. It's a bit ugly that we have to "know"
2730 that the names of the GLib DLLs are like libglib-2.0-0.dll, but in
2731 reality they won't change, until there is a GLib 3, and then also
2732 the Unix code here needs changing.
2734 Must pass CPPFLAGS to g-ir-scanner when building GLib.gir so that
2737 2008-08-26 Colin Walters <walters@verbum.org>
2739 * girepository/girepository.c: Search
2740 $DATADIR/girepository instead of
2741 $DATADIR/gitypelibs; this naming makes
2742 it clearer that e.g. jgir can install
2744 * gir/Makefile.am: Install there.
2746 2008-08-26 Colin Walters <walters@verbum.org>
2748 * girepository/gtypelib.c (_g_typelib_init): Also
2749 use G_MODULE_SUFFIX instead of hardcoding .so.
2751 2008-08-26 Colin Walters <walters@verbum.org>
2753 * girepository/gtypelib.c (_g_typelib_init): Free
2754 string in the right place.
2756 2008-08-26 Colin Walters <walters@verbum.org>
2758 * girepository/gtypelib.c (_g_typelib_init): Handle
2759 both .la and .so names; this works better in the
2760 uninstalled library case.
2762 2008-08-26 Johan Dahlin <johan@gnome.org>
2765 * giscanner/Makefile.am:
2766 * giscanner/cgobject.py:
2767 * giscanner/config.py.in:
2768 * giscanner/sourcescanner.py:
2769 Avoid undeffing __GNUC__, instead define
2770 __attribute__ & friends. Remove glibconfig.h hack.
2771 This makes gobject-introspection work better on
2772 MacOS X, Thanks to Richard Hult for kind help.
2774 2008-08-25 Colin Walters <walters@verbum.org>
2776 * giscanner/glibtransformer.py: Always print
2779 2008-08-25 Colin Walters <walters@verbum.org>
2781 * giscanner/glibtransformer.py: Skip over
2782 interfaces we don't know.
2784 2008-08-25 Colin Walters <walters@verbum.org>
2786 * girepository/girparser.c: Parse new implements
2787 syntax, drop gapi one.
2788 * tests/object.gir: Update.
2789 * tools/generate.c: Generate new syntax.
2791 2008-08-25 Colin Walters <walters@verbum.org>
2793 * giscanner/ast.py: Add interfaces property
2795 * giscanner/girwriter.py: Write out implemented
2797 * giscanner/glibtransformer.py: Introspect
2798 implemented interfaces.
2799 * tests/scanner/*: Make FooObject implement
2802 2008-08-25 Colin Walters <walters@verbum.org>
2804 * giscanner/glibtransformer.py: More correctly pair
2805 methods; if we have a symbol that starts with
2806 e.g. hippo_canvas look for a matching HippoCanvas
2807 class before accepting e.g. HippoCanvasImage.
2809 2008-08-24 Colin Walters <walters@verbum.org>
2811 * tools/g-ir-scanner: Filter out unknown options from
2814 2008-08-24 Colin Walters <walters@verbum.org>
2816 * giscanner/glibtransformer.py: Fail with better
2817 error if we can't find library.
2819 2008-08-24 Colin Walters <walters@verbum.org>
2821 * tools/g-ir-scanner: Use subprocess instead of
2822 commands, works on Windows and avoids the evil
2825 2008-08-24 Colin Walters <walters@verbum.org>
2827 * giscanner/glibtransformer.py: Skip over
2828 g_object_get_type from GLib trunk.
2830 2008-08-24 Colin Walters <walters@verbum.org>
2832 * girepository/girepository.c (g_irepository_require):
2833 Don't open shared library here; we already do it
2836 2008-08-24 Colin Walters <walters@verbum.org>
2838 * girepository/gtypelib.c: Add context stack so
2839 when we get an error we can print out nicely
2842 2008-08-24 Johan Dahlin <johan@gnome.org>
2844 * girepository/girparser.c (start_glib_boxed), (start_function),
2845 (start_field), (start_alias):
2846 Refactor a couple of parsing functions to be simpler to follow.
2849 2008-08-24 Johan Dahlin <johan@gnome.org>
2851 * girepository/girparser.c (start_function):
2852 Remove left-over code, checking type of function.
2854 2008-08-23 Colin Walters <walters@verbum.org>
2856 * giscanner/config.py: Define DATADIR.
2857 * giscanner/transformer.py: Look in DATADIR.
2859 2008-08-23 Colin Walters <walters@verbum.org>
2861 * girepository/gtypelib.c: Check constructor
2863 * girepository/girnode.c: Small tweaks.
2864 * girepository/ginfo.c: Calculate signature offsets
2866 * girepository/girparser.c: Remove duplicate
2868 * giscanner/glibtransformer.py: Avoid marking
2869 functions which return a basic type as
2872 2008-08-23 Colin Walters <walters@verbum.org>
2874 * girepository/girparser.c: Ignore <include>.
2875 * giscanner/girparser.py: Parse them.
2876 * giscanner/girwriter.py: Generate them.
2877 * giscanner/transformer.py: Process <include>
2878 recursively. Don't require full path for
2879 includes, look in {$XDG_DATA_DIRS}/gir.
2880 * tools/g-ir-scanner: Pass through includes.
2881 * Makefile.am: Remove extra --include
2883 * *-expected.gir: Add expected includes.
2885 2008-08-23 Johan Dahlin <johan@gnome.org>
2887 * tests/scanner/Makefile.am:
2888 * tests/scanner/annotation-expected.gir:
2889 * tests/scanner/drawable-expected.gir:
2890 Avoid duplication in the Makefile, regenerate with new
2891 namespaces (same as the filename)
2893 2008-08-22 Colin Walters <walters@verbum.org>
2895 * girepository/girnode.c: Don't hardcode integers,
2898 2008-08-22 Johan Dahlin <johan@gnome.org>
2900 * giscanner/sourcescanner.py:
2901 Check for ../gobject-introspection-1.0.pc.in to determine
2902 if we run installed or uninstalled.
2904 2008-08-22 Johan Dahlin <johan@gnome.org>
2907 * giscanner/sourcescanner.py:
2908 Send in undefs/defines via writing it directly to stdin
2909 of cpp instead of via arguments.
2911 2008-08-22 Colin Walters <walters@verbum.org>
2913 * tools/generate.c, tools/compiler.c: Default
2915 * all Makefile.am: Update.
2917 2008-08-22 Colin Walters <walters@verbum.org>
2919 * girepository/girparser.c: Pass through
2920 recursive types. Avoid overwriting errors.
2921 * giscanner/xmlwriter.py: Always write the
2923 * tests/*.gir: Adjust.
2924 * tests/scanner/Makefile.am: Build typelibs,
2925 and generate XML from those. Once we
2926 have a good diff mechanism...
2927 * tests/scanner/*-expected.gir: Add XML
2929 * tools/g-ir-scanner: Accept --typelib-xml
2931 * tools/generate.c: Better defaults for transfer.
2933 2008-08-22 Johan Dahlin <johan@gnome.org>
2937 * giscanner/Makefile.am:
2938 * giscanner/config.py.in:
2939 * giscanner/sourcescanner.py:
2940 Use the generated glibconfig.h for all scanner invokations.
2941 Rename it to glibconfig-scanner.h and install it.
2942 Add a config.py which so far contains the include dir.
2944 2008-08-22 Johan Dahlin <johan@gnome.org>
2947 Replace glibconfig.h with our own, do some replacement
2948 for CPP/C features we do not support
2950 2008-08-22 Colin Walters <walters@verbum.org>
2952 * tools/generate.c (write_callable_info): Fix unref
2955 2008-08-22 Colin Walters <walters@verbum.org>
2957 * gobject-introspection-1.0.pc.in: Add g-ir-generate.
2958 * tests/Makefile.am: Support $(DEBUG)
2959 * tools/generate.c: Do immediate close tags if no
2962 2008-08-21 Colin Walters <walters@verbum.org>
2964 * tests/scanner/drawable-expected.gir,
2965 * tests/scanner/drawable.c,
2966 * tests/scanner/drawable.h:
2969 2008-08-21 Colin Walters <walters@verbum.org>
2971 * giscanner/glibtransformer.py: Compute prefix
2972 by searching through the symbol for bits
2973 rather than going directly from ctype; this fixes
2976 2008-08-21 Colin Walters <walters@verbum.org>
2978 * giscanner/glibtransformer.py: Also try squashing
2979 underscores from namespace, fixes webkit_web_view_new.
2981 2008-08-21 Colin Walters <walters@verbum.org>
2983 * giscanner/glibtransformer.py: More ctor work,
2984 avoid having gtk_window_group_new end up under
2987 2008-08-21 Colin Walters <walters@verbum.org>
2989 * giscanner/glibtransformer.py: Much simpler approach
2990 of mapping uscored names to classes.
2991 * giscanner/utils.py: Remove unnecessary function.
2993 2008-08-21 Johan Dahlin <johan@gnome.org>
2995 * girepository/girepository.c (g_irepository_require):
2996 Plug memory leak and avoid using freed memory.
2997 Resolve the whole module path, here as well.
2999 2008-08-21 Colin Walters <walters@verbum.org>
3001 * giscanner/glibtransformer.py: Look up all permutations
3002 of class names when scanning methods/ctors based on
3003 the prefix instead of using the return value. This
3004 associates gtk_window_new with the right class.
3006 2008-08-21 Colin Walters <walters@verbum.org>
3008 * girepository/girmodule.c (g_ir_module_build_typelib):
3009 Revert change to increment header_size; we do that in
3012 2008-08-21 Colin Walters <walters@verbum.org>
3014 * girepository/girnode.c (write_string): Tweak to
3015 use UINT instead of INT. Not likely to matter.
3016 * girepository/girmodule.c (g_ir_module_build_typelib):
3017 Add to header_offset as well for header strings
3018 to match what write_string does.
3019 * girepository/gtypelib.c: Replace is_name with
3020 validate_name, which more strongly validates and
3021 handles errors in a better way. Update all callers.
3022 * giscanner/glibtransformer.py: Handle constructors
3025 2008-08-21 Johan Dahlin <johan@gnome.org>
3027 * gir/Makefile.am (typelibs_DATA): Build and
3028 install the Gio.typelib too
3030 * girepository/gtypelib.c (_g_typelib_init):
3031 Use g_module_build_path to resolve the shlib name
3033 2008-08-21 Colin Walters <walters@verbum.org>
3035 * gir/Makefile.am: CLEANFILES typelibs too.
3037 2008-08-21 Johan Dahlin <johan@gnome.org>
3039 * giscanner/glibtransformer.py:
3040 Do not send .la files through find_library.
3042 2008-08-21 Colin Walters <walters@verbum.org>
3044 * girepository/girparser.c (g_irepository_require):
3045 Fix one small leak in error case.
3047 2008-08-21 Johan Dahlin <johan@gnome.org>
3050 Parse glibconfig.h as well and install the compiled
3053 2008-08-21 Johan Dahlin <johan@gnome.org>
3056 * giscanner/glibtransformer.py:
3057 * tools/g-ir-scanner:
3058 Do not hard-core library names in the Makefile, reuse
3059 ctypes find_library instead.
3061 2008-08-21 Johan Dahlin <johan@gnome.org>
3063 * girepository/girparser.c (resolve_aliases):
3064 Remove compilation warnings
3066 2008-08-21 Johan Dahlin <johan@gnome.org>
3068 * girepository/girepository.c (g_irepository_require):
3069 Rewrap and fix double free bug by leaking a bit.
3071 2008-08-20 Colin Walters <walters@verbum.org>
3073 * girepository/girepository.c: Add new function
3074 g_irepository_get_typelib_path which tells
3075 us from where we loaded a namespace.
3077 2008-08-20 Colin Walters <walters@verbum.org>
3079 * tests/scanner/*-expected.gir: Adjust for
3080 added shared-library.
3081 * giscanner/giwriter.py: Make pylint happy.
3083 2008-08-20 Colin Walters <walters@verbum.org>
3085 * girepository/girmodule.c (g_ir_module_build_typelib):
3086 Calculate size correctly, avoid use-after-free.
3088 2008-08-20 Colin Walters <walters@verbum.org>
3090 * girepository/girepository.c: Remove
3091 g_irepository_register_file in favor of
3092 g_irepository_require. There are two
3093 possible deployment scenarios for typelibs:
3094 First, separate in $DATADIR/gitypelibs/. Second,
3095 they may be embedded in shlibs. However since
3096 the first is now the normal case, the API is
3097 optimized around it.
3099 Refactor internals to look up typelibs for
3100 namespaces just-in-time, but we expect
3101 consumers to call g_irepository_require.
3103 Also, add some docs. No one has died from that
3105 * gir/Makefile.am: Need --library for glib.
3106 * giscanner/girwriter.py: Write out shared-library.
3107 * tools/g-ir-writer: Take the first --library
3108 argument as the target of shared-library. In
3109 the future we should make this nicer with pkg-config
3112 2008-08-20 Colin Walters <walters@verbum.org>
3114 * girepository/girparser.py: And parse them.
3116 2008-08-20 Johan Dahlin <johan@gnome.org>
3118 * giscanner/glibast.py: Add gshort/gushort types
3120 2008-08-20 Colin Walters <walters@verbum.org>
3122 * gir/Makefile.am: Rename .gir files using GI namespace.
3123 * girepository/girepository.c: Use XDG_DATA_DIRS for
3124 looking up typelibs. Also typelibs are now suffixed
3126 * tests/invoke/Makefile.am: Only use metadata.
3127 * girepository/Makefile.am: Remove unnecessary include.
3128 * tests/scanner/Makefile.am: Update using GI namespaces
3129 for scanner includes.
3131 2008-08-20 Colin Walters <walters@verbum.org>
3133 * girepository/transformer.py: Suppress aliases whose
3135 * girepository/ast.py: Define some more aliases.
3137 2008-08-20 Colin Walters <walters@verbum.org>
3139 * girepository/girparser.c: Avoid alias infloops.
3141 2008-08-20 Colin Walters <walters@verbum.org>
3143 * tests/scanner/foo-expected.gir: Fix expected list type.
3145 2008-08-20 Johan Dahlin <johan@gnome.org>
3147 * giscanner/glibtransformer.py (GLibTransformer._resolve_type_name):
3148 Add a workaround for #548689.
3149 We can now compile gtk!
3151 2008-08-20 Colin Walters <walters@verbum.org>
3153 * giscanner/glibtransformer.py: Try to look up
3154 aliases using the c:type too.
3156 2008-08-20 Colin Walters <walters@verbum.org>
3158 * girepository/girparser.c: Parse union fields.
3160 2008-08-20 Johan Dahlin <johan@gnome.org>
3162 * giscanner/ast.py: Make time_t an alias for long
3164 * gir/gio-2.0-good.gir:
3165 * gir/glib-2.0-good.gir:
3166 * gir/gobject-2.0-good.gir:
3168 * giscanner/glibtransformer.py:
3169 Do not delete Class structures, we need them in gdk/gtk.
3170 * tests/scanner/drawable-expected.gir:
3171 * tests/scanner/foo-expected.gir:
3172 * tests/scanner/utility-expected.gir:
3175 2008-08-20 Johan Dahlin <johan@gnome.org>
3177 * tests/scanner/Makefile.am:
3178 * tests/scanner/annotation-expected.gir:
3179 * tests/scanner/annotation.c (annotation_object_class_init),
3180 (annotation_object_init), (annotation_object_method),
3181 (annotation_object_in), (annotation_object_out),
3182 (annotation_object_inout), (annotation_object_inout2),
3183 (annotation_object_inout3), (annotation_object_calleeowns),
3184 (annotation_object_calleesowns), (annotation_object_get_strings),
3185 (annotation_object_with_voidp), (annotation_object_get_objects),
3186 (annotation_object_create_object), (annotation_object_allow_none):
3187 * tests/scanner/annotation.h:
3188 * tests/scanner/foo-expected.gir:
3189 * tests/scanner/foo.c:
3190 * tests/scanner/foo.h:
3191 Split out annotation tests out of foo
3193 2008-08-20 Johan Dahlin <johan@gnome.org>
3195 * tests/scanner/Foo-expected.gir:
3196 * tests/scanner/Makefile.am:
3197 * tests/scanner/foo-expected.gir:
3198 * tests/scanner/foo-object.h:
3199 * tests/scanner/foo.c:
3200 Foo->foo, foo-object.h -> foo.h
3202 2008-08-20 Johan Dahlin <johan@gnome.org>
3204 * tests/scanner/Foo-expected.gir:
3205 * tests/scanner/Makefile.am:
3206 * tests/scanner/drawable-expected.gir:
3207 * tests/scanner/drawable.c (test_drawable_class_init),
3208 (test_drawable_init):
3209 * tests/scanner/drawable.h:
3210 * tests/scanner/foo-object.h:
3211 * tests/scanner/foo.c (foo_boxed_method):
3212 Move the drawable parts out of Foo to its own test.
3214 2008-08-20 Johan Dahlin <johan@gnome.org>
3216 * tests/scanner/Foo-expected.gir:
3217 * tests/scanner/foo-object.h:
3218 * tests/scanner/foo.c (foo_drawable_class_init),
3219 (foo_drawable_init):
3220 Add a based on GdkDrawable which generates
3223 2008-08-19 Colin Walters <walters@verbum.org>
3225 * giscanner/transformer.py: Don't try
3226 to strip prefix before namespace.
3228 2008-08-19 Johan Dahlin <johan@gnome.org>
3230 * giscanner/transformer.py:
3231 * tests/scanner/Foo-expected.gir:
3232 * tests/scanner/foo-object.h:
3233 Add support for typedef void foo type of
3236 2008-08-19 Johan Dahlin <johan@gnome.org>
3239 * giscanner/girwriter.py:
3240 * giscanner/glibtransformer.py:
3241 * giscanner/transformer.py:
3242 * tests/scanner/Foo-expected.gir:
3243 Add basic support for union, base the code much
3244 on Struct. Add a testcase.
3246 2008-08-19 Johan Dahlin <johan@gnome.org>
3248 * tests/scanner/Foo-expected.gir:
3249 * tests/scanner/foo-object.h:
3250 Add a union testcase which the compiler currently
3253 2008-08-19 Johan Dahlin <johan@gnome.org>
3255 * gobject-introspection-1.0.pc.in:
3256 Add a g_ir_compiler variable
3258 2008-08-19 Colin Walters <walters@verbum.org>
3260 * giscanner/ast.py: Rework types to be more closely
3262 * giscanner/girparser.py: Parse more bits.
3263 * giscanner/girwriter.py: Write sequences in a new
3264 way that specifies container type.
3265 * giscanner/glibast.py: Adjust for ast.py changes,
3266 add 'ctype' property to GLibObject and GLibInterface
3267 so we can look things up by it later.
3268 * gicanner/transformer.py: Names is new class holding
3269 the various namespaces we manage. Do not confuse
3270 with Namespace which is toplevel XML node effectively.
3271 Rework all type resolution to go through
3272 _resolve_type_name_1.
3273 * giscanner/glibtransformer.py: Raise UnknownTypeError
3274 instead of ValueError for cleanliness. Add Unresolved
3275 class to mark types whose parent we haven't seen yet.
3276 Use new Names object from transformer.py.
3277 Correctly look up parent=.
3278 Fix type validation to handle sequences.
3279 * tests/scanner/Foo-expected.gir: Update for sequence
3280 work, int instead of int32.
3281 * tools/g-ir-scanner: Add --noclosure option
3282 * gir/Makefile.am: Use --noclosure by default for
3285 2008-08-18 Johan Dahlin <johan@gnome.org>
3287 * gir/gio-2.0-good.gir:
3288 * gir/glib-2.0-good.gir:
3289 * gir/gobject-2.0-good.gir:
3292 2008-08-18 Johan Dahlin <johan@gnome.org>
3295 * giscanner/girparser.py:
3296 * giscanner/girwriter.py:
3297 * giscanner/glibast.py:
3298 * giscanner/glibtransformer.py:
3299 * giscanner/transformer.py:
3300 * tests/scanner/Foo-expected.gir:
3301 * tests/scanner/foo-object.h:
3302 * tests/scanner/utility-expected.gir:
3303 * tests/scanner/utility.h:
3304 Redo type resolving and validation.
3305 Add a couple of new tests.
3306 Patch mostly written by Colin.
3308 2008-08-18 Johan Dahlin <johan@gnome.org>
3311 * giscanner/girparser.py:
3313 * giscanner/transformer.py:
3314 Improve enum parsing for enums without a GType.
3315 Make flags/enum references to other girs work
3316 * giscanner/utils.py:
3318 * tests/scanner/Makefile.am:
3319 * tests/scanner/foo-object.h:
3320 * tests/scanner/utility-expected.gir:
3321 * tests/scanner/utility.h:
3322 Add a new test for external enum references
3324 2008-08-18 Johan Dahlin <johan@gnome.org>
3326 * docs/global-module-registry.txt: Update
3328 * tests/array.gir: Update with new type proposal
3330 * girepository/girepository.c (g_type_tag_to_string):
3331 * girepository/girepository.h:
3332 * girepository/girnode.c (g_ir_node_get_full_size_internal),
3334 * girepository/girnode.h:
3335 Make enum serializing functions public. Clean up some whitespace.
3337 2008-08-17 Johan Dahlin <johan@gnome.org>
3339 * docs/global-module-registry.txt:
3340 Add a document for an on disk module registry format
3342 2008-08-17 Johan Dahlin <johan@gnome.org>
3345 * gir/gio-2.0-good.gir:
3348 2008-08-17 Johan Dahlin <johan@gnome.org>
3351 * gir/glib-2.0-good.gir:
3352 * gir/gobject-2.0-good.gir:
3353 * giscanner/cgobject.py:
3354 * giscanner/glibtransformer.py:
3355 Regenerate GObject & GType.
3356 Avoid warnings when generating gobject-2.0.gir.
3357 Introspect a little more, and skip *_get_type functions.
3359 2008-08-17 Colin Walters <walters@verbum.org>
3361 * gir/glib-2.0.gir, gir/gobject-2.0.gir:
3362 Rename to -good, always generate during build.
3363 * gir/Makefile.am: Ensure .gir files dep on
3364 all scanner sources.
3365 * Makefile.am: Switch build order to ensure
3366 the scanner is ready before we do gir/.
3367 * tools/g-ir-scanner: Look for .git too.
3369 2008-08-17 Johan Dahlin <johan@gnome.org>
3371 * girepository/gtypelib.c (validate_enum_blob):
3372 * giscanner/glibtransformer.py:
3373 * giscanner/transformer.py:
3374 Remove resolve_possible_typedefs, it was unused.
3375 Allow multiple enum values of the sample value in an enum,
3376 since it's actually pretty common.
3377 Register enums so they can be resolved too.
3379 2008-08-16 Johan Dahlin <johan@gnome.org>
3381 * giscanner/girparser.py:
3382 Parse enumeration/bitfield.
3384 2008-08-16 Johan Dahlin <johan@gnome.org>
3386 * giscanner/girparser.py:
3389 2008-08-16 Johan Dahlin <johan@gnome.org>
3391 * giscanner/glibtransformer.py:
3392 Resolve type names for alias targets
3393 * giscanner/transformer.py:
3394 Skip FILE* parameters fow now
3396 2008-08-16 Johan Dahlin <johan@gnome.org>
3399 * gir/gobject-2.0.gir:
3402 * tests/scanner/Makefile.am:
3405 2008-08-15 Colin Walters <walters@verbum.org>
3407 * giscanner/glibtransformer.py: Explicitly construct
3408 new list, since we're deleting as we iterate.
3409 Don't delete all structures which end in Class; just
3410 ones which have a paired GObject.
3411 Fix printing of type warning.
3412 * giscanner/transformer.py: Make strip_namespace_object
3413 be the identity function if it doesn't match the
3416 2008-08-15 Colin Walters <walters@verbum.org>
3418 * giscanner/cgobject.py: Define yet more argument
3419 prototypes; fix prototype for g_type_fundamental.
3421 2008-08-14 Johan Dahlin <johan@gnome.org>
3423 * tests/Makefile.am:
3424 * tests/constant.gir:
3425 * tests/gobject.gir:
3427 * tools/generate.c (write_struct_info):
3428 Fix generator for constant/gobject/struct
3430 2008-08-14 Johan Dahlin <johan@gnome.org>
3432 * tests/Makefile.am:
3434 * tools/generate.c (write_enum_info):
3435 Fix generation of enum/bitfields
3437 2008-08-14 Johan Dahlin <johan@gnome.org>
3439 * girepository/girparser.c (start_field), (start_constant),
3440 (start_type), (end_element_handler):
3441 Clear up constant parsing
3446 * tools/generate.c (write_callable_info), (write_function_info),
3447 (write_callback_info), (write_constant_info), (write_signal_info),
3448 (write_vfunc_info), (write_property_info), (write_object_info),
3449 (write_interface_info):
3450 Constants/Signals are handled now.
3452 2008-08-14 Johan Dahlin <johan@gnome.org>
3454 * girepository/girparser.c (start_type):
3455 Don't require c:type.
3456 * tests/Makefile.am:
3459 Update, remove parts we don't support yet
3460 * tests/roundtrips.sh:
3462 * tools/generate.c (write_type_info), (write_field_info),
3463 (write_callable_info), (write_struct_info):
3464 Make it emit proper gir.
3466 2008-08-14 Johan Dahlin <johan@gnome.org>
3468 * giscanner/transformer.py:
3469 New internal function for adding a new node.
3471 2008-08-14 Johan Dahlin <johan@gnome.org>
3474 Define an internal _H_ variable so we skip parsing both
3475 i18n headers, only one is needed.
3477 Add the glib-2.0.gir too.
3478 * giscanner/glibast.py:
3479 Add gconstpointer as an alias for ANY
3480 * giscanner/transformer.py:
3481 Do not lower case enumeration names per se.
3482 Skip functions which has parameters called 'va_list'
3484 2008-08-14 Colin Walters <walters@verbum.org>
3486 * giscanner/transformer.py: Comment data structures.
3487 Also squash pointers in resolve_type_name to correspond
3488 with what we do for params.
3489 * giscanner/glibtransformer.py: Print warnings in more
3490 situations. Rework checks for method/constructor to
3491 look up in our GType database instead of just checking
3492 for *. Avoid generating <record> for GObject which
3493 duplicate the <class>.
3494 * gir/Makefile.am: Generate glib-2.0.gir and gobject-2.0.gir
3497 2008-08-14 Johan Dahlin <johan@gnome.org>
3499 * giscanner/girwriter.py:
3500 * giscanner/glibast.py:
3501 * giscanner/glibtransformer.py:
3502 * giscanner/transformer.py:
3504 * tests/Makefile.am:
3505 Add pyflakes.py and run it in make check.
3506 Update the source code to fix the errors reported by
3509 2008-08-14 Johan Dahlin <johan@gnome.org>
3512 * giscanner/girparser.py:
3513 * giscanner/glibast.py:
3514 * giscanner/glibtransformer.py:
3515 Refactor the parser a bit.
3516 Add parent type to interfaces and update callsites.
3518 2008-08-14 Johan Dahlin <johan@gnome.org>
3520 * giscanner/glibtransformer.py:
3521 * giscanner/utils.py:
3522 Refactor a bit, avoid isinstance and add a method
3523 for each type we parse.
3525 2008-08-14 Johan Dahlin <johan@gnome.org>
3528 * giscanner/girparser.py:
3529 * giscanner/glibtransformer.py:
3530 * tests/Makefile.am:
3531 Run pep8.py in make check, fix old errors.
3533 2008-08-13 Colin Walters <walters@verbum.org>
3535 * giscanner/girparser.py: Parse records.
3537 2008-08-13 Colin Walters <walters@verbum.org>
3539 * gir/Makefile.am: Install again.
3540 * gir/gobject-2.0.gir: Add some more bits.
3542 2008-08-13 Colin Walters <walters@verbum.org>
3544 * gir/gobject-2.0.gir: Use correct namespace, add GType.
3545 * giscanner/girparser.py: Handle aliases.
3546 * giscanner/transformer.py: Record aliases. Make resolver
3547 functions public; we now call into these explicitly from
3548 glibtransformer. Handle resolving aliases.
3549 * giscanner/glibtransformer.py: Separate our internal namespace
3550 from included ones. Call up into transformer's resolver functions.
3552 2008-08-13 Johan Dahlin <johan@gnome.org>
3554 * girepository/girnode.c (g_ir_node_get_full_size_internal):
3555 * girepository/girparser.c (start_class):
3556 * giscanner/glibtransformer.py:
3557 Allow get_type to be None, set a get_type for GInitiallyUnowned too.
3559 2008-08-13 Johan Dahlin <johan@gnome.org>
3561 * giscanner/cgobject.py:
3562 Register GInitiallyUnowned
3563 * giscanner/girwriter.py:
3564 * giscanner/glibtransformer.py:
3565 Special case GObject/GInitially owned as they are a bit special to use.
3567 2008-08-13 Colin Walters <walters@verbum.org>
3569 * tests/scanner/Foo-expected.gir, tests/scanner/utility-expected.gir:
3570 Object is in GObject namespace.
3572 2008-08-13 Colin Walters <walters@verbum.org>
3574 * giscanner/girparser.py: Fix processing of functions
3577 2008-08-13 Colin Walters <walters@verbum.org>
3579 * giscanner/girparser.py: Parse more than just <class.
3580 * giscanner/glibtransformer.py: Put aliases in a separate
3581 data structure since their name is not canonicall.
3582 * giscanner/transformer.py: Handle resolving type names
3585 2008-08-13 Johan Dahlin <johan@gnome.org>
3587 * tools/g-ir-scanner:
3588 Allow multiple libraries
3589 * giscanner/glibtransformer.py:
3590 Rename load_library to add_library, traverse over all libraries
3591 when trying to resolve a function
3593 2008-08-12 Colin Walters <walters@verbum.org>
3595 * giscanner/transformer.py: Record typedefs as <alias> elements.
3596 Also attempt to look up types in external namespaces.
3597 * giscanner/girwriter.py: Write them.
3598 * giscanner/glibtransformer.py: Rework resolver using real instanceof
3599 checks. Resolve interface methods and properties.
3600 * tests/scanner/foo-object.h: Add a method with typedef.
3601 * tests/scanner/Foo-expected.gir: Update.
3602 * girepository/girnode.c: Debug tweaks.
3603 * girepository/girparser.c: Make a first pass through the XML where we
3604 record all the aliases. This lets us resolve them as we go through the
3606 * gir/Makefile.am: Don't install gobject-2.0.gir; we want that to come
3607 from gir-repository.
3609 2008-08-12 Colin Walters <walters@verbum.org>
3611 * giscanner/glibtransformer.py: Resolve typedefs (e.g. AtkAttributeSet -> GSList).
3612 Correctly do subclasseing in 2nd pass resolution. Handle callbacks in structure
3614 * giscanner/transformer.py: Record typedefs and expose public API for resolving
3616 * tests/scanner/Foo-expected.gir: Fix expected callback types.
3618 2008-08-12 Colin Walters <walters@verbum.org>
3620 * giscanner/glibtransformer.py: Also transform object properties.
3622 2008-08-12 Colin Walters <walters@verbum.org>
3624 * giscanner/glibtransformer.py: Also transform callbacks
3625 and structure field types.
3626 * tests/scanner/Fooe-expected.gir: Update to expect correct
3627 names for callbacks and structs.
3629 2008-08-12 Colin Walters <walters@verbum.org>
3631 * girepository/girparser.c: Handle 'any'.
3632 * tests/scanner/Foo-expected.gir, tests/scanner/foo-object.h:
3633 Add test for void *.
3635 2008-08-12 Colin Walters <walters@verbum.org>
3637 * giscanner/glibtransformer.py: We need to do type
3638 resolution in a second pass after we've seen all the
3639 enums, records, etc.
3641 2008-08-12 Colin Walters <walters@verbum.org>
3643 * tests/scanner/Foo-expected.gir, tests/scanner/foo-object.h:
3644 Add enum return value.
3645 * giscanner/glibtransformer.py: Transform function return types
3648 2008-08-12 Colin Walters <walters@verbum.org>
3650 * tests/scanner/Makefile.am: Dep .gir files on scanner
3651 sources too. Also remove @ so we see scanner invocations.
3653 2008-08-12 Colin Walters <walters@verbum.org>
3655 * girepository/girparser.c, girepository/gtypelib.c,
3656 girepository/gtypelib.h, girepository/girnode.c:
3657 Remove usage of (GAPI-oriented) TypeTag in favor of
3658 GITypeTag from girepository.h.
3660 2008-08-10 Colin Walters <walters@verbum.org>
3662 * tests/roundtrips.sh: Use the correct tests.
3664 2008-08-10 Colin Walters <walters@verbum.org>
3666 * giscanner/cgobject.py: Declare/wrap a few more functions.
3667 Fix parameter types for g_object_new and g_type_fundamental.
3669 2008-08-10 Colin Walters <walters@verbum.org>
3671 * giscanner/cgobject.py: Add new decorator @gwrap which forces
3672 us to declare types for both return value and parameters. The
3673 ctypes default of 'int' is bad because it hides 32/64 bit
3674 problems. Convert all existing functions to use it.
3676 2008-08-09 Johan Dahlin <johan@gnome.org>
3678 * giscanner/__init__.py:
3680 * giscanner/cgobject.py:
3681 * giscanner/gidlparser.py:
3682 * giscanner/gidlwriter.py:
3683 * giscanner/girparser.py:
3684 * giscanner/girwriter.py:
3685 * giscanner/glibast.py:
3686 * giscanner/glibtransformer.py:
3687 * giscanner/odict.py:
3688 * giscanner/sourcescanner.py:
3689 * giscanner/transformer.py:
3690 * giscanner/utils.py:
3691 * giscanner/xmlwriter.py:
3692 * tools/g-ir-scanner:
3696 2008-08-09 Johan Dahlin <johan@gnome.org>
3699 * relaxng/c-types.xml:
3700 * relaxng/g-types.xml:
3701 * relaxng/relaxng.rng:
3703 Remove outdated relaxng schemas.
3705 2008-08-09 Johan Dahlin <johan@gnome.org>
3708 Rename metadata to typelib in variable names,
3711 2008-08-09 Johan Dahlin <johan@gnome.org>
3715 Remove old C scanner, which got rewritten in python.
3717 2008-08-09 Johan Dahlin <johan@gnome.org>
3719 * girepository/Makefile.am:
3720 * tools/Makefile.am:
3721 * tools/girmodule.c:
3722 * tools/girmodule.h:
3725 * tools/girparser.c:
3726 * tools/girparser.h:
3727 * tools/girwriter.c:
3728 * tools/girwriter.h:
3729 Move shared *.[ch] files to girepository from tools
3731 2008-08-09 Johan Dahlin <johan@gnome.org>
3733 * tests/Makefile.am:
3736 * tests/constant.test:
3738 * tests/errors.test:
3739 * tests/function.test:
3740 * tests/gobject.test:
3741 * tests/interface.test:
3742 * tests/object.test:
3743 * tests/struct.test:
3748 Rename *.test to *.gir
3750 2008-08-09 Johan Dahlin <johan@gnome.org>
3753 * tests/Makefile.am:
3754 * tests/parser/Foo-expected.gir:
3755 * tests/parser/Makefile.am:
3756 * tests/parser/foo-object.h:
3757 * tests/parser/foo.c:
3758 * tests/parser/utility-expected.gir:
3759 * tests/parser/utility.c:
3760 * tests/parser/utility.h:
3761 * tests/scanner/Makefile.am:
3762 Rename tests/parser to test/scanner
3764 2008-08-08 Colin Walters <walters@verbum.org>
3766 * tests/roundtrips.sh: Use local .gir files again.
3768 2008-08-08 Colin Walters <walters@verbum.org>
3770 * tests/invoke/Makefile.am: .gir file depends on libtool
3773 2008-08-08 Colin Walters <walters@verbum.org>
3775 * tools/girnode.c: Pass through parent node so we can
3776 print the node whose child is NULL, if that occurs.
3778 2008-08-08 Johan Dahlin <johan@gnome.org>
3780 * tests/Makefile.am:
3781 Disable roundtrip tests which are not yet working
3782 * tests/invoke/testfns.gir:
3785 2008-08-08 Johan Dahlin <johan@gnome.org>
3787 * giscanner/girwriter.py:
3789 * giscanner/glibast.py:
3790 * giscanner/glibtransformer.py:
3791 Swap order of members, to keep it consistent with
3794 2008-08-08 Johan Dahlin <johan@gnome.org>
3796 * girepository/gtypelib.c (validate_header):
3797 * girepository/gtypelib.h:
3799 * giscanner/girwriter.py:
3800 * giscanner/sourcescanner.c (gi_source_symbol_ref),
3801 (gi_source_symbol_unref):
3804 * tests/constant.test:
3806 * tests/errors.test:
3807 * tests/function.test:
3808 * tests/gobject.test:
3809 * tests/interface.test:
3810 * tests/invoke/Makefile.am:
3811 * tests/invoke/testfns.xml:
3812 * tests/object.test:
3813 * tests/parser/Makefile.am:
3814 * tests/roundtrips.sh:
3815 * tests/struct.test:
3820 * tools/Makefile.am:
3821 * tools/compiler.c (main):
3822 * tools/generate.c (write_callable_info), (write_function_info),
3824 * tools/gidlmodule.c:
3825 * tools/gidlmodule.h:
3828 * tools/gidlparser.c:
3829 * tools/gidlparser.h:
3830 * tools/gidlwriter.c:
3831 * tools/gidlwriter.h:
3832 * tools/scanner.c (create_node_from_gtype),
3833 (create_node_from_ctype), (g_igenerator_process_properties),
3834 (g_igenerator_process_signals), (g_igenerator_create_object),
3835 (g_igenerator_create_interface), (g_igenerator_create_boxed),
3836 (g_igenerator_create_enum), (g_igenerator_create_flags),
3837 (g_igenerator_process_function_symbol),
3838 (g_igenerator_process_unregistered_struct_typedef),
3839 (g_igenerator_process_struct_typedef),
3840 (g_igenerator_process_union_typedef),
3841 (g_igenerator_process_enum_typedef),
3842 (g_igenerator_process_function_typedef),
3843 (g_igenerator_process_constant), (g_igenerator_process_symbols),
3844 (g_igenerator_add_module), (g_igenerator_add_include_idl):
3845 Merge in the gir-compiler branch.
3846 Thanks to Philip and Colin for their help.
3848 2008-07-26 Colin Walters <walters@verbum.org>
3850 * tools/Makefile.am (bin_PROGRAMS): Install g-idl-compiler
3851 and g-idl-generate to go along with how we're changing this
3852 module to be installed.
3853 * gobject-introspection-1.0.pc.in: Set up Cflags and Libs.
3855 2008-07-24 Colin Walters <walters@verbum.org>
3857 * girepository/girepository.c (g_irepository_register): Add
3858 environment variable G_IREPOSITORY_VERBOSE so we can print
3859 out what we're doing.
3860 * girepository/girepository.c (g_irepository_register_file):
3861 Add GError error message to g_debug call.
3863 2008-07-08 Jürg Billeter <j@bitron.ch>
3865 * giscanner/glibast.py:
3869 2008-06-21 Johan Dahlin <jdahlin@async.com.br>
3871 * giscanner/girparser.py (GIRParser._parse_api): Ignore a few
3874 2008-06-20 Johan Dahlin <jdahlin@async.com.br>
3877 * giscanner/girwriter.py:
3878 * giscanner/transformer.py:
3879 * tests/parser/Foo-expected.gir:
3880 * tests/parser/foo-object.h:
3881 * tests/parser/foo.c (foo_object_allow_none):
3882 Add support for gtk-doc annotations for allow-none.
3885 2008-06-19 Johan Dahlin <jdahlin@async.com.br>
3888 * giscanner/girwriter.py:
3889 * giscanner/glibast.py:
3890 * giscanner/glibtransformer.py:
3891 * giscanner/transformer.py:
3892 * tests/parser/Foo-expected.gir:
3893 Start using abstract type instead of the raw C types.
3894 Register a bunch of glib types we care about.
3896 2008-06-19 Rob Taylor <rob.taylor@codethink.co.uk>
3901 2008-06-08 Philip Van Hoof <pvanhoof@gnome.org>
3903 * girepository/girepository.c:
3904 * girepository/gtypelib.c:
3905 * girepository/ginfo.c:
3906 * girepository/ginvoke.c:
3907 * girepository/girepository.h:
3908 * girepository/gtypelib.h:
3909 * girepository/gmetadata.c:
3910 * girepository/Makefile.am:
3911 * girepository/gmetadata.h:
3913 * tools/gidlmodule.c:
3916 * tools/gidlmodule.h:
3917 * tools/gidlparser.c:
3919 Renamed GMetadata to GTypelib
3921 2008-06-07 Johan Dahlin <jdahlin@async.com.br>
3923 * giscanner/xmlwriter.py:
3924 Improve line wrapping when > 79 charaters
3926 2008-06-05 Jürg Billeter <j@bitron.ch>
3929 * giscanner/girwriter.py:
3930 * giscanner/transformer.py:
3931 Use <type> element for field types
3932 * tests/parser/Foo-expected.gir:
3935 2008-06-04 Johan Dahlin <jdahlin@async.com.br>
3937 * giscanner/glibtransformer.py:
3938 Fix a bug which prevented GdkEvent from being generated
3940 2008-06-03 Johan Dahlin <jdahlin@async.com.br>
3942 * giscanner/Makefile.am:
3944 * giscanner/girwriter.py:
3945 * giscanner/glibast.py:
3946 * giscanner/glibtransformer.py:
3947 * giscanner/transformer.py:
3948 * giscanner/utils.py:
3949 * tests/parser/Foo-expected.gir:
3950 Improve enum member parsing and introspection
3952 2008-05-31 Johan Dahlin <jdahlin@async.com.br>
3954 * giscanner/scannerparser.y:
3955 * giscanner/sourcescanner.h:
3956 * giscanner/sourcescanner.py:
3957 Add a new source type enum for member.
3958 Use __repr__ for improved debugging
3959 * giscanner/girparser.py:
3961 * giscanner/transformer.py:
3962 Improve parsing of struct members.
3963 * tests/parser/foo-object.h:
3966 2008-05-31 Johan Dahlin <jdahlin@async.com.br>
3968 * giscanner/xmlwriter.py:
3969 Improve error reporting when trying to quote None.
3970 * giscanner/girparser.py:
3971 Do not print warnings when including more complete .gir files
3972 * giscanner/girwriter.py:
3973 Do not require a name for parameters, add a todo for singletons
3974 * giscanner/glibtransformer.py:
3975 Refactor the way structs are done, add a couple of hacks to allow
3977 * giscanner/transformer.py:
3978 Add enough hacks so cairo, atk and pango.gir can be parsed properly
3979 * gobject-introspection-1.0.pc.in:
3980 Export girdir, so we can access gobject-2.0.gir from outside
3982 2008-05-31 Johan Dahlin <jdahlin@async.com.br>
3984 * tools/g-ir-scanner:
3985 * tests/parser/Makefile.am:
3986 Update sys.path before running the parser so we don't have
3987 to setup PYTHONPATH ourselves.
3991 * girepository/Makefile.am:
3992 * giscanner/transformer.py:
3993 * gobject-introspection-1.0.pc.in:
3994 * gobject-introspection.pc.in:
3995 * tools/Makefile.am:
3997 Rename pkg-config name to gobject-introspection-1.0,
3998 Do not installed anything which is not using the gir format.
3999 Disable compililation the old C scanner, but still keep the source
4000 until all the remaning functionallity has been ported.
4002 2008-05-31 Johan Dahlin <jdahlin@async.com.br>
4004 * giscanner/giscannermodule.c (symbol_get_ident): Prevent
4005 a crash when symbol->indent is NULL.
4007 * giscanner/sourcescanner.py (ctype_name): Add ctype_name,
4008 a function to convert a CTYPE symbol to a string
4010 2008-05-24 Johan Dahlin <jdahlin@async.com.br>
4013 * giscanner/girwriter.py:
4014 * giscanner/giscannermodule.c
4015 (pygi_source_scanner_append_filename),
4016 (pygi_source_scanner_parse_file):
4017 * giscanner/glibtransformer.py:
4018 * giscanner/sourcescanner.py:
4019 Revert back to using temporary files to send in headers.
4020 Allow Functions to be passed in as callbacks, add a couple
4021 of try/excepts missing features.
4022 We can now scan pango
4024 2008-05-08 Johan Dahlin <johan@gnome.org>
4026 * giscanner/glibtransformer.py:
4027 * giscanner/transformer.py:
4028 Move namespace stripping glibtransformer->transformer
4030 2008-05-08 Johan Dahlin <johan@gnome.org>
4033 * giscanner/girwriter.py:
4034 * giscanner/glibtransformer.py:
4035 * giscanner/transformer.py:
4036 * tools/g-ir-scanner:
4037 Introduce a namespace ast node
4039 2008-05-05 Johan Dahlin <johan@gnome.org>
4041 * giscanner/__init__.py:
4042 * giscanner/sourcescanner.py:
4043 * giscanner/transformer.py:
4044 Move sourcescanner symbols to the sourcescanner module, instead
4045 of in the global __init__ namespace.
4047 2008-05-03 Johan Dahlin <johan@gnome.org>
4049 * giscanner/glibtransformer.py:
4050 * tools/g-ir-scanner:
4051 Handle missing parameters better, allow - and + in .la dlname
4054 2008-05-03 Johan Dahlin <johan@gnome.org>
4056 * giscanner/__init__.py:
4058 * giscanner/girwriter.py:
4059 * giscanner/glibtransformer.py:
4060 * giscanner/transformer.py:
4061 Parse struct fields properly, improve debugging.
4063 2008-04-29 Johan Dahlin <johan@gnome.org>
4066 * giscanner/girwriter.py:
4067 * giscanner/transformer.py:
4068 * tests/parser/Foo-expected.gir:
4070 Use transfer-ownership everywhere, to mark ownership/calle/caller etc.
4072 2008-04-29 Johan Dahlin <jdahlin@async.com.br>
4075 * docs/g-ir-scanner.1:
4076 * metadata-annotations-proposal.txt:
4077 * metadata-format.txt:
4078 Add a basic, unfinshed man page for g-ir-scanner, move documents into .txt
4080 2008-04-29 Johan Dahlin <jdahlin@async.com.br>
4082 * giscanner/girwriter.py:
4083 * giscanner/glibtransformer.py:
4084 * giscanner/transformer.py:
4085 * giscanner/xmlwriter.py:
4086 * tests/parser/Foo-expected.gir:
4087 * tests/parser/foo-object.h:
4088 Write record/structs to gir file too. Add a couple of tests,
4089 fix an off by one error in xmlwriter.py.
4091 2008-04-28 Johan Dahlin <johan@gnome.org>
4093 * giscanner/xmlwriter.py: Calculate the line length properly,
4094 include the provided extra indentation in the calculation, really.
4096 2008-04-28 Johan Dahlin <jdahlin@async.com.br>
4099 * giscanner/glibast.py:
4100 * giscanner/glibtransformer.py:
4101 * giscanner/transformer.py:
4102 * tools/g-ir-scanner:
4103 Add a --strip-prefix and sort out confusion between names and symbols
4104 for functions and struct + derivaties.
4105 Refactor bootstrap of g-ir-scanner, so we can set options on
4106 Transformer() before parsing everything.
4108 2008-04-28 Johan Dahlin <johan@gnome.org>
4110 * giscanner/transformer.py (Transformer._traverse_one): Avoid recursion
4111 when scanning girepository.h
4113 * giscanner/sourcescanner.py (SourceScanner._preprocess): Define
4114 a __GI_SCANNER__ when we run.
4116 2008-04-28 Johan Dahlin <jdahlin@async.com.br>
4119 * giscanner/girwriter.py:
4120 * giscanner/glibast.py:
4121 * giscanner/glibtransformer.py:
4122 * tests/parser/Foo-expected.gir:
4123 * tests/parser/utility-expected.gir:
4124 Rename most c:identifier to c:type. Add new ones to
4125 class/interface/enum/boxed.
4127 2008-04-28 Johan Dahlin <jdahlin@async.com.br>
4130 * giscanner/girwriter.py:
4131 * giscanner/glibtransformer.py:
4132 * tests/parser/Foo-expected.gidl:
4133 * tests/parser/Makefile.am:
4134 Move c:identifier from return-value to subchild type,
4135 as per Jürgs suggestion
4137 2008-04-28 Johan Dahlin <johan@gnome.org>
4139 * giscanner/girwriter.py:
4140 * tests/parser/Foo-expected.gir:
4141 Write property.type as a child node.
4143 2008-04-27 Johan Dahlin <johan@gnome.org>
4148 * gidl/gobject-2.0.gidl:
4150 * gir/gobject-2.0.gir:
4151 * tests/parser/Makefile.am:
4152 Replace the GObject gidl with a GObject gir.
4154 2008-04-27 Johan Dahlin <johan@gnome.org>
4156 * tools/Makefile.am (bin_SCRIPTS): g-ir-scanner is a script,
4159 * giscanner/xmlwriter.py:
4160 * tests/parser/Foo-expected.gir:
4161 Include indentation in line length calculation
4163 2008-04-27 Johan Dahlin <johan@gnome.org>
4165 * giscanner/girparser.py:
4166 Prettify NS parsing using elementtree.
4168 2008-04-27 Johan Dahlin <johan@gnome.org>
4171 * giscanner/Makefile.am:
4172 * giscanner/girparser.py:
4173 * giscanner/glibtransformer.py:
4174 * tests/parser/Foo-expected.gidl:
4175 * tests/parser/Foo-expected.gir:
4176 * tests/parser/Makefile.am:
4177 * tests/parser/utility-expected.gidl:
4178 * tests/parser/utility-expected.gir:
4179 * tools/g-ir-scanner:
4180 Switch over to GIR as the default format. Add a simple GIDL
4182 Update tests and fix simplify makefiles by depending
4183 on GNU make extensions.
4185 2008-04-27 Johan Dahlin <johan@gnome.org>
4187 * giscanner/xmlwriter.py:
4188 Wrap attributes for lines which are wider than 79 characters
4190 * giscanner/scannerlexer.l:
4191 Allow parenthesis in annotations
4194 * giscanner/gidlwriter.py:
4195 * giscanner/girwriter.py:
4196 * giscanner/glibtransformer.py:
4197 * giscanner/transformer.py:
4198 Add initial sequence support, including annotation.
4199 Refactor type handling a bit.
4201 2008-04-27 Johan Dahlin <johan@gnome.org>
4203 * tests/parser/Foo-expected.gidl:
4204 * tests/parser/foo-object.h:
4205 * tests/parser/foo.c (foo_object_class_init),
4206 (foo_object_get_strings), (foo_object_get_objects):
4207 Add two new functions to check sequence return values.
4208 Also fixes a compilation warning.
4210 2008-04-27 Johan Dahlin <johan@gnome.org>
4212 * giscanner/giscannermodule.c (]): Cast the getter, avoids
4213 a compilation warning.
4215 * tools/Makefile.am (g_ir_scanner_SOURCES):
4216 g-ir-scanner has no sources.
4218 2008-04-25 Johan Dahlin <johan@gnome.org>
4220 * giscanner/Makefile.am:
4222 * giscanner/gidlparser.py:
4223 * giscanner/gidlwriter.py:
4224 * giscanner/girwriter.py:
4225 * giscanner/glibast.py:
4226 * giscanner/glibtransformer.py:
4227 * giscanner/transformer.py:
4228 Split out nodes to ast.py and glibast.py
4230 2008-04-25 Johan Dahlin <jdahlin@async.com.br>
4232 * giscanner/Makefile.am:
4233 * giscanner/gidlparser.py:
4234 * giscanner/gidlwriter.py:
4235 * giscanner/girwriter.py:
4236 * giscanner/glibtransformer.py:
4237 * giscanner/gobjecttreebuilder.py:
4238 * giscanner/transformer.py:
4239 * giscanner/treebuilder.py:
4240 * tools/g-ir-scanner:
4241 Rename treebuilder to transformer and
4242 gobjectreebuilder to glibtransformer.
4244 2008-04-25 Johan Dahlin <jdahlin@async.com.br>
4246 * giscanner/Makefile.am:
4247 * giscanner/__init__.py:
4248 * giscanner/cgobject.py:
4249 * giscanner/gidlparser.py:
4250 * giscanner/gidlwriter.py:
4251 * giscanner/girwriter.py:
4252 * giscanner/gobjecttreebuilder.py:
4253 * giscanner/odict.py:
4254 * giscanner/sourcescanner.py:
4255 * giscanner/treebuilder.py:
4256 * giscanner/xmlwriter.py:
4257 * tools/Makefile.am:
4258 * tools/g-ir-scanner:
4259 Add LGPLv2 license header and install all python files
4261 2008-04-25 Johan Dahlin <jdahlin@async.com.br>
4264 * giscanner/gidlwriter.py:
4265 * giscanner/giscannermodule.c (pygi_source_directive_new),
4266 (directive_get_options), (pygi_source_symbol_new),
4267 (symbol_get_base_type), (pygi_source_type_new),
4268 (type_get_base_type), (type_get_child_list),
4269 (pygi_source_scanner_get_symbols),
4270 (pygi_source_scanner_get_directives):
4271 * giscanner/gobjecttreebuilder.py:
4272 * giscanner/sourcescanner.py:
4273 * giscanner/treebuilder.py:
4274 * tests/parser/foo-object.h:
4275 Add support for virtual methods.
4276 Pair struct FooClass with struct Foo.
4277 Clean up the SourceScanner bindings a bit.
4278 Add a testcase for virtual methods.
4280 2008-04-25 Johan Dahlin <jdahlin@async.com.br>
4282 * giscanner/cgobject.py:
4283 * giscanner/gidlwriter.py:
4284 * giscanner/gobjecttreebuilder.py:
4285 Add support for signals
4287 * tests/parser/foo.c (foo_object_class_init):
4288 * Foo-expected.gidl:
4289 Add a signal and update the expected output.
4291 2008-04-24 Johan Dahlin <jdahlin@async.com.br>
4293 * giscanner/gidlwriter.py:
4294 * giscanner/girwriter.py:
4295 * giscanner/giscannermodule.c (directive_get_name),
4296 (directive_get_value), (directive_get_options),
4297 (symbol_get_directives), (symbol_set_directives),
4298 (pygi_source_scanner_parse_file),
4299 (pygi_source_scanner_lex_filename),
4300 (pygi_source_scanner_get_directives), (init_giscanner):
4301 * giscanner/sourcescanner.c (gi_source_scanner_get_directives):
4302 * giscanner/sourcescanner.h:
4303 * giscanner/sourcescanner.py:
4304 * giscanner/treebuilder.py:
4305 * tools/g-ir-scanner:
4306 Add support for source/header annotations.
4308 2008-04-22 Johan Dahlin <jdahlin@async.com.br>
4310 * giscanner/gidlwriter.py:
4311 * giscanner/girwriter.py:
4312 * giscanner/gobjecttreebuilder.py:
4313 * giscanner/treebuilder.py:
4314 Add support for Callbacks
4316 2008-04-22 Havoc Pennington <hp@pobox.com>
4318 * girepository/ginvoke.c (g_function_info_invoke): If a symbol is
4319 not in metadata->module, look for it in the global module, in case
4320 some other object or the app itself provides the symbol.
4322 2008-04-22 Havoc Pennington <hp@pobox.com>
4324 * girepository/gmetadata.c (_g_metadata_init): hack to avoid
4325 dlopening a library that is already in the main app, by checking
4326 whether one of the lib's symbols is already loaded.
4328 2008-04-22 Johan Dahlin <jdahlin@async.com.br>
4330 * tests/parser/Foo-expected.gidl:
4331 * tests/parser/foo-object.h:
4334 2008-04-22 Havoc Pennington <hp@pobox.com>
4336 * girepository/ginfo.c (g_interface_info_find_method):
4337 Use interface_blob_size not object_blob_size to compute offset.
4339 2008-04-22 Havoc Pennington <hp@pobox.com>
4341 * girepository/gmetadata.c (_g_metadata_init): remove
4342 G_MODULE_BIND_LOCAL flag when loading libraries, since some libs
4343 (Glade and Clutter for example) rely on being loaded globally.
4345 2008-04-22 Havoc Pennington <hp@pobox.com>
4347 * girepository/ginfo.c (g_registered_type_info_get_g_type): new
4348 function to get the GType given a RegisteredTypeInfo
4350 2008-04-22 Johan Dahlin <johan@gnome.org>
4352 * COPYING: Add a LGPL license, to prevent automake to
4353 put in a copy of GPL here. Pointed out by Havoc.
4355 * girepository/ginfo.c (g_info_from_entry), (g_type_info_new),
4356 (g_type_info_is_pointer), (g_type_info_get_tag),
4357 (g_type_info_get_param_type), (g_type_info_get_interface),
4358 (g_type_info_get_array_length), (g_type_info_is_zero_terminated),
4359 (g_type_info_get_n_error_domains), (g_type_info_get_error_domain),
4360 (g_error_domain_info_get_codes), (g_enum_info_get_value),
4361 (g_object_info_get_interface), (g_object_info_get_field),
4362 (g_interface_info_get_prerequisite),
4363 (g_signal_info_get_class_closure), (g_constant_info_get_value):
4364 * girepository/ginvoke.c (get_ffi_type):
4365 * girepository/girepository.h:
4366 * girepository/gmetadata.c (g_metadata_get_dir_entry),
4367 (g_metadata_check_sanity), (validate_header),
4368 (validate_array_type_blob), (validate_iface_type_blob),
4369 (validate_param_type_blob), (validate_error_type_blob),
4370 (validate_type_blob), (validate_constant_blob),
4371 (validate_struct_blob), (validate_enum_blob):
4372 * girepository/gmetadata.h:
4373 * tests/Makefile.am:
4374 * tests/invoke/Makefile.am:
4375 * tests/invoke/invoke.c (main):
4376 * tests/roundtrips.sh:
4377 * tools/Makefile.am:
4378 * tools/compiler.c (format_output), (write_out_metadata), (main):
4379 * tools/generate.c (write_type_name), (write_type_info),
4380 (write_constant_value), (write_enum_info), (load_metadata), (main):
4381 * tools/gidlcompilercontext.c:
4382 * tools/gidlcompilercontext.h:
4383 * tools/gidlcompilerentrynode.c:
4384 * tools/gidlcompilerentrynode.h:
4385 * tools/gidlcompilertypenode.c:
4386 * tools/gidlcompilertypenode.h:
4387 * tools/gidlmodule.c (g_idl_module_build_metadata):
4388 * tools/gidlmodule.h:
4389 * tools/gidlnode.c (init_stats), (dump_stats),
4390 (g_idl_node_get_size), (g_idl_node_get_full_size),
4391 (g_idl_node_cmp), (g_idl_node_can_have_member),
4392 (g_idl_node_add_member), (g_idl_node_param_direction_string),
4393 (parse_int_value), (parse_uint_value), (parse_float_value),
4394 (parse_boolean_value), (find_entry_node), (find_entry),
4395 (serialize_type), (g_idl_node_build_metadata), (write_string):
4397 * tools/gidlparser.c (parse_type_internal):
4398 * tools/quote-file.sh:
4399 Revert revisions 157,149-148,136-129 and 120.
4400 Move back to using g-idl-generate to generate the metadata and
4401 avoids dependency on a c compiler.
4403 2008-04-22 Johan Dahlin <jdahlin@async.com.br>
4405 * giscanner/girwriter.py:
4406 * tools/g-ir-scanner:
4407 Add an initial GIR writer and a --format option to g-ir-scanner
4409 2008-04-21 Johan Dahlin <johan@gnome.org>
4411 * giscanner/cgobject.py: Use ctypes.util.find_library to locate
4412 gobject-2.0 and raise ImportError if not found.
4414 * giscanner/gidlparser.py:
4415 * giscanner/gidlwriter.py:
4416 * giscanner/gobjecttreebuilder.py:
4417 * tools/g-ir-scanner:
4418 Add a --include argument to include types from other idls.
4419 Add a minimalistic GIDL parser (just objects for now)
4420 Implement resolving of external type references and use it to
4421 resolve parent types, argument types and return types.
4423 2008-04-21 Johan Dahlin <johan@gnome.org>
4425 * giscanner/gidlwriter.py:
4426 * giscanner/gobjecttreebuilder.py:
4427 * giscanner/treebuilder.py:
4428 Add support for properties.
4429 Refactor Class/Interface support a bit, to share more code and
4430 always initialize their method attribute to an empty list.
4432 2008-04-21 Johan Dahlin <johan@gnome.org>
4434 * giscanner/cgobject.py:
4435 Add a workaround for a glib bug interface introspection bug
4436 (object_interface_list_properties, object_class_list_properties):
4437 Cast the return value to GParamSpec.
4439 * tests/parser/Foo-expected.gidl: Update
4440 * tests/parser/foo.c: Add a string property
4442 * giscanner/gobjecttreebuilder.py:
4443 After stripping namespaces, remove the original
4444 item to avoid duplication (GtkButton struct and Button object)
4446 2008-04-21 Johan Dahlin <johan@gnome.org>
4448 * giscanner/gobjecttreebuilder.py:
4449 * giscanner/treebuilder.py:
4450 Strip namespaces before objects, so we'll export
4451 GtkButton as Button in the gtk namespace
4453 2008-04-21 Johan Dahlin <johan@gnome.org>
4455 * giscanner/gidlwriter.py:
4456 * giscanner/gobjecttreebuilder.py:
4457 * giscanner/treebuilder.py:
4458 Add constructors for object/boxed types.
4460 2008-04-21 Johan Dahlin <johan@gnome.org>
4462 * giscanner/gidlwriter.py:
4463 * giscanner/gobjecttreebuilder.py:
4464 Add support for boxed types
4466 2008-04-21 Johan Dahlin <johan@gnome.org>
4468 * giscanner/giscannermodule.c: Mark structures as const,
4469 wrap SourceType.const_string.
4471 * tests/parser/foo-object.h: Add a couple of constants.
4473 * giscanner/gidlwriter.py:
4474 * giscanner/gobjecttreebuilder.py:
4475 * giscanner/treebuilder.py:
4476 Add basic support for interfaces
4478 * tools/g-ir-scanner:
4479 Add -o/--output for writing to a file
4481 2008-04-21 Havoc Pennington <hp@redhat.com>
4483 * TODO: add some C API wishlist items I could think of quickly
4485 2008-04-21 Johan Dahlin <jdahlin@async.com.br>
4487 * giscanner/gidlwriter.py:
4488 * giscanner/xmlwriter.py:
4489 Add a simple api for writing tags which can be used
4490 with the new 'with statement' in python 2.5
4492 2008-04-21 Johan Dahlin <johan@gnome.org>
4494 * giscanner/gobjecttreebuilder.py:
4495 Strip namespace and object prefix from method names.
4497 2008-04-21 Johan Dahlin <johan@gnome.org>
4499 * tools/g-ir-scanner (main): Add --pkg option to pass in
4500 pkg-config modules to get cflags from.
4502 * giscanner/gidlwriter.py (GIDLWriter._write_method):
4503 Avoid duplication, reuse function writer for methods.
4505 2008-04-21 Johan Dahlin <jdahlin@async.com.br>
4507 * giscanner/gidlwriter.py:
4508 * giscanner/gobjecttreebuilder.py:
4509 * giscanner/treebuilder.py:
4510 * tools/g-ir-scanner:
4511 Resolve libtool .la files.
4512 Strip name spaces for methods.
4513 Add function symbols
4515 2008-04-20 Johan Dahlin <jdahlin@async.com.br>
4517 * giscanner/cgobject.py:
4518 * giscanner/gidlwriter.py:
4519 * giscanner/gobjecttreebuilder.py:
4520 * giscanner/treebuilder.py:
4521 Add support for classes and methods
4523 2008-04-20 Johan Dahlin <johan@gnome.org>
4525 * giscanner/gidlwriter.py:
4526 * giscanner/gobjecttreebuilder.py:
4527 * giscanner/odict.py:
4528 Avoid conflicts, keep the output ordered similar to
4529 the order of the input.
4530 Add a simple ordered dictionary implemenation
4532 2008-04-19 Johan Dahlin <johan@gnome.org>
4534 * giscanner/cgobject.py:
4535 * giscanner/gidlwriter.py:
4536 * giscanner/gobjecttreebuilder.py:
4537 * tools/g-ir-scanner:
4538 Start introspecting get-type functions.
4539 Implement support for GLib/GFlags GTypes.
4540 Add a ctype based GObject binding.
4542 2008-04-18 Johan Dahlin <jdahlin@async.com.br>
4544 * giscanner/gidlwriter.py:
4545 * giscanner/xmlwriter.py:
4546 * tools/g-ir-scanner:
4547 Add a simplistic gidl writer, which can't do too much.
4549 2008-04-18 Johan Dahlin <johan@gnome.org>
4551 * giscanner/sourcescanner.py:
4552 * giscanner/treebuilder.py:
4553 * tools/g-ir-scanner:
4554 split tree building and source scanning interface to separate files.
4556 2008-04-18 Johan Dahlin <johan@gnome.org>
4558 * tools/g-ir-scanner (Parameter.__init__): Start constructing
4560 - Add support for struct/parameter/return, start parsing of ctypes
4562 * giscanner/giscannermodule.c: wrap GISourceType.child_list and
4565 2008-03-31 Johan Dahlin <johan@gnome.org>
4567 * tools/g-ir-scanner:
4568 Start to build abstract syntax node of scanned sources.
4569 Add support for cpp options.
4571 2008-03-27 Johan Dahlin <johan@gnome.org>
4573 * giscanner/giscannermodule.c:
4574 * giscanner/scannerlexer.l:
4575 * giscanner/sourcescanner.c:
4576 * tools/g-ir-scanner:
4578 Add simple pre-processor using subprocess and a PIPE.
4579 Change the parse_file apis to accept a file descriptor.
4581 2008-03-25 Johan Dahlin <johan@gnome.org>
4583 * giscanner/__init__.py:
4584 * tools/g-ir-scanner:
4585 Fix a typo and add an example python test program.
4587 2008-03-25 Johan Dahlin <johan@gnome.org>
4589 * giscanner/__init__.py:
4590 * giscanner/giscannermodule.c:
4591 * giscanner/sourcescanner.c:
4592 * giscanner/sourcescanner.h:
4593 Add constants and wrap a few more SymbolType fields
4595 2008-03-25 Johan Dahlin <johan@gnome.org>
4599 * giscanner/__init__.py:
4600 * giscanner/giscannermodule.c:
4601 * giscanner/Makefile.am:
4603 Add initial python bindings for the scanner and
4604 depend on python 2.5.
4606 2008-03-25 Johan Dahlin <johan@gnome.org>
4610 * giscanner/Makefile.am:
4611 * giscanner/sourcescanner.c:
4612 * giscanner/sourcescanner.h:
4613 * tools/Makefile.am:
4614 * tools/grealpath.h:
4615 * tools/sourcescanner.c:
4616 * tools/sourcescanner.h:
4618 Move the scanner to a separate library.
4620 2008-03-23 Johan Dahlin <johan@gnome.org>
4622 * tools/Makefile.am:
4625 * tools/scannerlexer.l:
4626 * tools/scannerparser.y:
4627 * tools/sourcescanner.c:
4628 * tools/sourcescanner.h:
4629 Split out the source scanner from the generator.
4630 Rename the symbols used in the scanner to use the gi_ prefix.
4631 This should make it possible to use the raw C parser from
4634 2008-03-23 Johan Dahlin <johan@gnome.org>
4636 * tests/parser/Makefile.am (utility.gidl):
4637 * tests/parser/utility-expected.gidl:
4638 Pass in the gobject.gidl since we're defining a GObject.
4640 2008-03-12 Johan Dahlin <johan@gnome.org>
4642 * relaxng/relaxng.rng:
4643 Add a releaxng in relaxng we can use to validate the relaxngs
4646 2008-03-12 Jürg Billeter <j@bitron.ch>
4648 * tools/scanner.c: (g_igenerator_new):
4649 * tools/scannerparser.y:
4650 Fix compiler warnings.
4652 2008-03-12 Jürg Billeter <j@bitron.ch>
4656 * tools/scannerparser.y:
4657 Start fixing memory management in g-idl-scanner.
4659 2008-03-12 Rob Taylor <rob.taylor@codethink.co.uk>
4661 * tools/gidlcompilercontext.c: (write_compiled):
4662 Fix critical warning when no shlib passed to g-idl-compiler.
4664 2008-03-12 Johan Dahlin <johan@gnome.org>
4666 * tests/parser/utility-expected.gidl:
4667 * tests/parser/utility.h:
4668 Add a get_type-function, so the scanner actually
4669 parses it as an object.
4671 2008-03-12 Johan Dahlin <johan@gnome.org>
4673 * tools/gidlwriter.c (function_generate): Add missing trailing quote.
4676 * tests/parser/Foo-expected.gidl:
4677 * tests/parser/Makefile.am:
4678 * tests/parser/foo-object.h:
4679 * tests/parser/foo.c:
4680 * tests/parser/utility-expected.gidl:
4681 * tests/parser/utility.c:
4682 * tests/parser/utility.h:
4684 Add a new gidl test. 'utility.gidl', which is used to be able
4685 to test external type references. Add a reference to UtilityObject*
4688 2008-03-11 Johan Dahlin <johan@gnome.org>
4692 Remove most global variables
4694 2008-03-11 Philip Van Hoof <me@pvanhoof.be>
4696 * tools/scannerlexer.l:
4698 * tests/parser/Foo-expected.gidl:
4699 * tests/parser/foo.c:
4700 * tests/parser/Makefile.am:
4701 * tests/parser/foo-object.h:
4703 Added a few extra tests. Which resulted in finding a few
4704 bugs. Which resulted in me fixing those bugs
4706 2008-03-11 Rob Taylor <rob.taylor@codethink.co.uk>
4708 * tools/gidlcompilercontext.c: (g_idl_compiler_write_dir_entry),
4709 (g_idl_compiler_write_xref_entry), (g_idl_compiler_add_xref):
4710 Add some comments for strings into generated output for
4713 2008-03-11 Rob Taylor <rob.taylor@codethink.co.uk>
4715 * tools/gidlcompilercontext.c: (write_compiled):
4716 Write out the shlibs variable before writing out the strings
4717 length. Fixes compiler warning when using '-l' flag with
4720 2008-03-11 Johan Dahlin <johan@gnome.org>
4722 * tests/parser/Foo-expected.gidl:
4723 * tests/parser/foo-object.h:
4726 * tools/scannerlexer.l:
4727 Add support for parsing return arguments. Add support for
4728 caller-owns return types.
4729 Patch by Philip Van Hoof.
4731 * tools/scannerparser.y:
4732 Remove parsing of the @deprecated syntax used in headers.
4733 We will support gtk-doc deprecation in the future instead.
4735 2008-03-11 Johan Dahlin <johan@gnome.org>
4737 * tools/compiler.c (main): Coding style fixes
4739 2008-03-10 Johan Dahlin <johan@gnome.org>
4742 Add GCOV_LIBS to GILIBS
4744 2008-03-10 Johan Dahlin <johan@gnome.org>
4746 * tests/parser/Foo-expected.gidl:
4747 * tests/parser/foo.c:
4748 Rename null-ok to direction=out
4750 2008-03-10 Philip Van Hoof <me@pvanhoof.be>
4752 reviewed and extensively tested by Johan
4754 * tests/parser/Foo-expected.gidl:
4755 * tests/parser/foo-object.h:
4756 * tests/parser/foo.c:
4759 * tools/gidlwriter.c:
4762 * tools/scannerlexer.l:
4763 * tools/scannerparser.y:
4765 Add support for scanning for gtk-doc comments inside
4766 C source files. Add tests
4768 2008-03-10 Johan Dahlin <johan@gnome.org>
4770 * tests/parser/Makefile.am:
4771 * tests/parser/foo.c:
4774 * tools/scannerparser.y:
4775 Add an api to lex filenames.
4776 Lex all source .c files passed in on the command line.
4777 Scan sources in a test and a couple of private structures
4778 which should not be included in the generated gidl
4780 2008-03-10 Johan Dahlin <johan@gnome.org>
4782 * tests/invoke/Makefile.am: Make the generated metadata
4783 depend on the g-idl-compiler
4785 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4787 * tools/gidlmodule.c
4788 * tools/gidlmodule.h
4791 Remove the old g-idl-compiler code.
4794 2008-02-22 Mark Doffman <mark.doffman@codethink.co.uk>
4796 * tools/quote-file.sh
4799 Move to using the 'C' struct compiler code.
4801 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4803 * girepository/ginfo.c
4805 Change the way that external references with no namespace
4806 are dealt with. External references with no namespace
4807 are placed into the XML as-if they are a local reference.
4808 This is temporary, but helps with roundtrip tests.
4810 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4812 * girepository/ginfo.c
4813 Add the ability to get the value of a constant of
4814 type TYPE_TAG_SYMBOL. In the case of a symbol the value
4815 is provided as a string.
4817 This would deal properly with:
4818 typedef char* random;
4819 const random = "A string";
4821 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4823 * girepository/ginfo.c
4824 * girepository/girepository.h
4826 Add a function to check if an enum is registered or not.
4827 Previously anything testing this relied on the g-type
4828 string offset having a value of 0.
4830 * girepository/gmetadata.c
4831 * girepository/gmetadata.h
4833 Remove unneccesary or erroneous checks. There were two
4834 metadata validation checks which made sure that the blob
4835 sizes were the same as some magic numbers compiled into the code.
4836 This is wrong as it breaks any forwards compatibility that may
4839 Checks were also present that made sure that unregistered type
4840 blobs had a value of 0 in the g-type offset field. This is
4841 unneccessary. If a type blob is unregistered then any value
4842 in its g-type field is simply invalid.
4844 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4846 * girepository/ginfo.c
4847 * girepository/gmetadata.c
4848 * girepository/gmetadata.h
4850 Change the metadata format to have a standard header
4851 for all the type blobs. Merge the SimpleTypeBlob
4852 and InterfaceTypeBlob into a union. A union of these
4853 two blobs existed previously but was not explicit
4854 in the metadata format.
4856 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4858 * tools/gidlcompilercontext.c
4859 * tools/gidlcompilercontext.h
4860 * tools/gidlcompilerentrynode.c
4861 * tools/gidlcompilerentrynode.h
4862 * tools/gidlcompilertypenode.c
4863 * tools/gidlcompilertypenode.h
4865 Add code to compile a tree of GIdlNodes to
4866 a 'C' struct representing the metadata.
4867 This is to aid cross-compiling. Previously
4868 the g-idl-compiler created a binary blob with
4869 data written in the byte order and alignment
4870 of the tool rather than the intended target.
4872 Cleaned up and improved by Johan and Robert :-)
4874 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4876 * girepository/ginvoke.c
4877 * girepository/girepository.h
4878 * girepository/gmetadata.c
4879 * girepository/gmetadata.h
4881 * tools/gidlparser.c
4882 Modify TYPE_TAG_INTERFACE to TYPE_TAG_SYMBOL
4883 to avoid confusion with the interface blob.
4886 * tools/gidlparser.c
4887 Remove magic numbers and replace with type-tag
4888 enumeration symbols.
4890 * girepository/gmetadata.c
4891 Add validate declaration.
4893 2008-03-10 Jürg Billeter <j@bitron.ch>
4895 * tools/gidlparser.c: (parse_type_internal):
4896 * tools/scannerlexer.l:
4897 * tools/scannerparser.y:
4898 Support C99 _Bool type in scanner.
4900 2008-03-10 Jürg Billeter <j@bitron.ch>
4902 * tests/parser/Foo-expected.gidl:
4903 * tests/parser/foo-object.h:
4904 * tests/parser/foo.c: (foo_enum_method):
4905 * tools/scanner.c: (g_igenerator_process_function_symbol):
4906 Don't skip functions that are defined in the namespace of a type
4907 that doesn't support methods, as for example enums.
4909 2008-03-10 Johan Dahlin <johan@gnome.org>
4911 * gidl.dtd: Remove, we're using relaxng for now
4913 * tests/parser/Foo-expected.gidl:
4914 * tests/parser/foo-object.h:
4915 * tests/parser/foo.c:
4916 Rename the enum/flags get_type functions to include the whole type.
4918 2008-03-08 Marc-Andre Lureau <marcandre.lureau@gmail.com>
4920 * tools/gidlwriter.c (enum_generate): added "type-name",
4921 "get-type" and "deprecated" missing arguments.
4922 * tests/parser/Foo-expected.gidl:
4923 * tests/parser/foo-object.h: test enum type, and no type.
4925 2008-03-06 Johan Dahlin <jdahlin@async.com.br>
4928 Consistent checks, add missing 'test'
4930 2008-03-05 Havoc Pennington <hp@redhat.com>
4932 * configure.ac: Take advantage of a libffi.pc if one exists, as it
4933 does on Fedora 8. Make libffi a hard requirement, since it was in
4934 practice anyway (was not really conditional in the code or
4935 makefile, only in configure).
4937 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4939 reviewed by: Rob Taylor <rob.taylor@codethink.co.uk>
4940 reviewed by: Johan Dahlin <johan@gnome.org>
4942 * tests/Makefile.am:
4943 * tests/roundtrips.sh:
4944 Modify the roundtrips test so that they do not use the
4945 --raw option of the gidl compiler but instead compile a
4946 shared library to use with g_module.
4948 * tests/invoke/Makefile.am:
4949 * tests/invoke/invoke.c:
4950 Modify the invoke tests to build a shared library rather
4951 than use the --raw option.
4953 * tests/invoke/invoke-namespace-find.sh: Removed:
4954 Noone knows why this was here, so removed.
4956 2008-02-19 Rob Taylor <rob.taylor@codethink.co.uk>
4958 * tools/scanner.c: (g_igenerator_process_function_symbol):
4959 Move g_idl_node_can_have_member test later, as it broke spotting
4960 get_type's for nodes that can't have members.
4962 2008-02-18 Rob Taylor <rob.taylor@codethink.co.uk>
4965 * tools/gidlnode.c: (g_idl_node_can_have_member):
4966 Add g_idl_node_can_have_member.
4968 * tools/scanner.c: (g_igenerator_process_function_symbol):
4969 Use g_idl_node_can_have_member to test if we should add a function
4970 as a member of the type node.
4972 2008-02-18 Rob Taylor <rob.taylor@codethink.co.uk>
4974 * gidl/GLib.gidl: Renamed to gidl/gobject-2.0.gidl:
4976 * tests/parser/Makefile.am:
4977 Rename GLib.gidl to gobject-2.0.gidl and install in /usr/share/gidl.
4979 2008-02-18 Rob Taylor <rob.taylor@codethink.co.uk>
4981 * tools/scanner.c: (main):
4982 Ignore -pthread when passed to g-idl-scanner.
4984 2008-02-18 Rob Taylor <rob.taylor@codethink.co.uk>
4986 * tools/grealpath.h: Added:
4987 * tools/scanner.c: (main):
4988 * tools/scannerlexer.l:
4989 * tools/Makefile.am:
4990 Always use absolute paths with symbolic links resolved when
4991 comparing filenames.
4993 2008-02-18 Rob Taylor <rob.taylor@codethink.co.uk>
4995 * gobject-introspection.pc.in:
4996 Provide variables for g-idl-parser, scanner and compiler in the
4999 2008-02-13 Rob Taylor <rob.taylor@codethink.co.uk>
5002 * girepository/Makefile.am:
5003 * tools/Makefile.am:
5004 Rename GCOV_SOURCES to GCOVSOURCES to top automake complaining.
5006 2008-02-10 Johan Dahlin <johan@gnome.org>
5008 * tests/parser/Foo-expected.gidl:
5009 * tests/parser/foo-object.h:
5010 * tests/parser/foo.c: (foo_boxed_copy), (foo_boxed_free),
5011 (foo_boxed_get_type), (foo_boxed_new), (foo_boxed_method):
5014 2008-02-10 Johan Dahlin <johan@gnome.org>
5016 * tests/parser/Foo-expected.gidl:
5017 * tests/parser/foo-object.h:
5018 * tests/parser/foo.c: (foo_enum_get_type), (foo_flags_get_type):
5019 Add enum and flags test.
5021 2008-02-10 Johan Dahlin <johan@gnome.org>
5025 * girepository/Makefile.am:
5026 Make 'make distcheck' work again.
5028 2008-02-10 Johan Dahlin <johan@gnome.org>
5030 * m4/Makefile.am (EXTRA_DIST): its called as-compiler-flag.m4,
5033 * tests/parser/Makefile.am: Only create Foo.gidl when running make
5034 check, eg exclude it from BUILT_SOURCES.
5036 2008-02-08 Rob Taylor <rob.taylor@codethink.co.uk>
5041 * girepository/Makefile.am:
5042 * m4/Makefile.am: Added:
5043 * m4/as-compiler-flag.m4: Added:
5044 * m4/gcov.m4: Added:
5045 * tools/Makefile.am:
5046 Add ability to generate a coverage report.
5047 Adds configure option --enable-gcov and make rule 'check-coverage'.
5049 2008-02-08 Rob Taylor <rob.taylor@codethink.co.uk>
5053 * gidl/Makefile.am: Added:
5054 * girepository/Makefile.am: Added:
5055 * src/Makefile.am: Renamed to tools/Makefile.am:
5056 * src/compiler.c: Renamed to tools/compiler.c:
5057 * src/g-idl-offsets.pl: Renamed to tools/g-idl-offsets.pl:
5058 * src/generate.c: Renamed to tools/generate.c:
5059 * src/gidlmodule.c: Renamed to tools/gidlmodule.c:
5060 * src/gidlmodule.h: Renamed to tools/gidlmodule.h:
5061 * src/gidlnode.c: Renamed to tools/gidlnode.c:
5062 * src/gidlnode.h: Renamed to tools/gidlnode.h:
5063 * src/gidlparser.c: Renamed to tools/gidlparser.c:
5064 * src/gidlparser.h: Renamed to tools/gidlparser.h:
5065 * src/gidlwriter.c: Renamed to tools/gidlwriter.c:
5066 * src/gidlwriter.h: Renamed to tools/gidlwriter.h:
5067 * src/ginfo.c: Renamed to girepository/ginfo.c:
5068 * src/ginvoke.c: Renamed to girepository/ginvoke.c:
5069 * src/girepository.c: Renamed to girepository/girepository.c:
5070 * src/girepository.h: Renamed to girepository/girepository.h:
5071 * src/gmetadata.c: Renamed to girepository/gmetadata.c:
5072 * src/gmetadata.h: Renamed to girepository/gmetadata.h:
5073 * src/scanner.c: Renamed to tools/scanner.c:
5074 * src/scanner.h: Renamed to tools/scanner.h:
5075 * src/scannerlexer.l: Renamed to tools/scannerlexer.l:
5076 * src/scannerparser.y: Renamed to tools/scannerparser.y:
5077 * tests/invoke/Makefile.am:
5078 Split src/ into girepository/ and tools/
5082 * girepository/Makefile.am:
5083 * tests/Makefile.am:
5084 * tests/invoke/Makefile.am:
5085 * tests/parser/Makefile.am:
5086 * tests/roundtrips.sh:
5087 * tools/Makefile.am:
5088 Make distcheck work.
5090 2008-02-04 Rob Taylor <rob.taylor@codethink.co.uk>
5092 * tests/invoke/invoke.c: (main):
5093 * tests/invoke/testfns.c: (test6), (test7):
5094 * tests/invoke/testfns.xml:
5095 Add tests for invokation with a GList argument.
5096 Also tests caller-owns return values.
5098 2008-02-04 Rob Taylor <robtaylor@floopily.org>
5101 Add some documentation for GICallableInfo
5103 2008-02-01 Mark Doffman <mark.doffman@codethink.co.uk>
5106 Correct syntax errors in the DTD file.
5108 * relaxng/c-types.xml:
5109 * relaxng/g-types.xml:
5111 Add a RelaxNG specification for the GObject Introspection XML data.
5112 The Specification has validated all of the test files.
5114 2008-01-25 Rob Taylor <robtaylor@floopily.org>
5116 * tests/roundtrips.sh:
5117 * tests/struct.test:
5118 Add roundtrip tests for structs.
5120 2008-01-11 Johan Dahlin <johan@gnome.org>
5122 * src/scanner.c (g_igenerator_process_function_symbol):
5123 Refactor out g_idle_node_add_member.
5124 (create_node_from_gtype, create_node_from_ctype):
5125 Use case instead of if...else
5126 (get_type_from_type_id):
5127 Rename to create_node_from_gtype
5128 (get_type_from_ctype):
5129 Rename to create_node_from_ctype
5131 Rename ginode -> node, gitype -> type, gifunc -> func.
5133 * src/gidlnode.c (g_idl_node_add_member, g_idl_node_cmp):
5134 Two new functions, refactor out of scanner.c
5136 * src/scanner.c: (g_igenerator_process_function_symbol):
5137 * src/scannerlexer.l:
5138 Do not save the content of the deprecated variable, only
5141 2008-01-11 Johan Dahlin <johan@gnome.org>
5143 * tests/parser/foo-object.h: Add a couple of comment parser tests.
5145 2008-01-11 Jürg Billeter <j@bitron.ch>
5147 * src/scannerlexer.l:
5148 Fix GTK-Doc parsing.
5150 2008-01-11 Jürg Billeter <j@bitron.ch>
5152 * src/scannerlexer.l:
5153 Fix GTK-Doc parsing.
5155 2008-01-11 Jürg Billeter <j@bitron.ch>
5157 * src/scanner.c: (lookup_symbol):
5158 Return unresolved name if we find unknown symbol.
5160 2008-01-11 Jürg Billeter <j@bitron.ch>
5162 * src/scanner.c: (g_igenerator_generate):
5163 Initialize GObject to fix scanning interface properties.
5165 * tests/parser/Foo-expected.gidl:
5166 * tests/parser/foo-object.h:
5167 * tests/parser/foo.c: (foo_interface_get_type):
5168 Test interfaces with GObject prerequisite.
5170 * tests/parser/Makefile.am:
5171 Set G_DEBUG=fatal_warnings to abort test on warnings and criticals.
5173 2007-12-27 Johan Dahlin <johan@gnome.org>
5175 * src/scannerlexer.l:
5176 Parse gtk-doc comments.
5178 * src/gidlwriter.c: (function_generate):
5179 Reorganize, avoid duplication and add support for
5180 writing deprecated functions.
5182 * src/scannerparser.y:
5184 Add new structure CDirective and functions to create/free them.
5186 * src/scanner.c: (g_igenerator_process_function_symbol),
5187 (g_igenerator_process_unregistered_struct_typedef),
5188 (g_igenerator_process_struct_typedef),
5189 (g_igenerator_process_union_typedef),
5190 (g_igenerator_process_enum_typedef),
5191 (g_igenerator_process_function_typedef), (g_igenerator_add_symbol),
5192 (g_igenerator_start_preprocessor):
5193 Parse @deprecated directive for functions.
5194 Remove some more C99isms.
5195 Send in -C to cpp to avoid stripping comments.
5197 * tests/parser/foo-object.h:
5198 * tests/parser/Foo-expected.gidl:
5199 Add deprecated directive
5201 2007-12-27 Johan Dahlin <johan@gnome.org>
5203 * src/scannerlexer.l (intsuffix): Add emacs mode line and
5204 escape ' and " so it looks more like C.
5207 Unlink temporary file used.
5209 2007-12-27 Johan Dahlin <johan@gnome.org>
5211 * src/scanner.c: (g_igenerator_new), (g_igenerator_free),
5212 (g_igenerator_start_preprocessor), (main):
5214 * src/scannerparser.y:
5215 Plug a couple of simple memory leaks.
5217 2007-12-27 Johan Dahlin <johan@gnome.org>
5219 * src/scanner.c: (g_igenerator_parse_macros),
5220 (g_igenerator_start_preprocessor), (g_igenerator_set_verbose),
5223 * src/scannerparser.y:
5224 * tests/parser/Makefile.am:
5226 Improve error reporting, return when the preprocessor fails.
5227 Add a verbose parameter, to aid debugging.
5228 Revert to using a temporary file to communicate between the
5229 preprocessor and the parser, because we need to wait for
5230 the exit code from the pre-processor before starting to parse.
5232 2007-12-16 Johan Dahlin <jdahlin@async.com.br>
5234 * src/Makefile.am: Rename clexer.l to scannerlexer.l and
5235 cparser.y to scannerparser.y
5237 2007-12-11 Johan Dahlin <johan@gnome.org>
5241 * src/scanner.c: (g_igenerator_new):
5243 Get rid of the global the_generator variable.
5245 2007-12-10 Johan Dahlin <johan@gnome.org>
5247 * src/scanner.c (main): Add an output option,
5248 add checks for required parameters
5251 set BUILD_SOURCES and CLEANFILES properly
5253 * src/gidlwriter.c: (g_writer_write_inline), (g_writer_write),
5254 (g_writer_write_indent), (g_writer_write_unindent),
5255 (field_generate), (value_generate), (constant_generate),
5256 (property_generate), (function_generate), (vfunc_generate),
5257 (signal_generate), (interface_generate), (struct_generate),
5258 (union_generate), (boxed_generate), (enum_generate),
5259 (node_generate), (g_writer_write_module), (g_idl_writer_save_file):
5261 * src/scanner.c: (g_igenerator_generate):
5263 * src/scannerwriter.c:
5265 Refactor scannerwriter to only be tied to a GIdlModule and move
5266 it (again!) to gidlwriter.c. Change the writer function to take
5269 2007-12-10 Johan Dahlin <johan@gnome.org>
5272 * src/scanner.c: (g_igenerator_generate):
5274 * src/scannerwriter.c: (g_igenerator_write_inline),
5275 (g_igenerator_write), (g_igenerator_write_indent),
5276 (g_igenerator_write_unindent), (field_generate), (value_generate),
5277 (constant_generate), (property_generate), (function_generate),
5278 (vfunc_generate), (signal_generate), (interface_generate),
5279 (struct_generate), (union_generate), (boxed_generate),
5280 (enum_generate), (node_generate), (module_generate),
5281 (g_scanner_write_file):
5283 Move the scanner gidl writing to a separate source file.
5285 2007-12-10 Johan Dahlin <johan@gnome.org>
5290 Move over all CType construction functions.
5292 * tests/parser/Makefile.am:
5293 Be verbose when printing parsing tests results.
5295 2007-12-10 Johan Dahlin <johan@gnome.org>
5297 * src/scanner.c (g_igenerator_start_preprocessor): Refactor
5298 preprocessor handling to here. Start cpp insteado of cc -E,
5299 always include -U__GNUC__, since it's specific to the preprocessor
5302 * tests/parser/Makefile.am (check-local): Silent diff and skip
5303 -U__GNUC__ which is always defined now
5305 2007-12-10 Johan Dahlin,,, <jdahlin@plasttroll>
5307 reviewed by: <delete if not using a buddy>
5309 * src/scanner.c: (g_igenerator_start_preprocessor), (main):
5310 * tests/parser/Makefile.am:
5312 2007-12-09 Johan Dahlin <johan@gnome.org>
5315 Use GOption for command line options.
5316 (g_igenerator_new, main): Simplify constructor and they way
5317 parameters are passed into it.
5323 * src/gen-introspect.c:
5324 * src/gen-introspect.h:
5326 Rename gen-introspect.[ch] to scanner.[ch]
5328 2007-12-09 Johan Dahlin <johan@gnome.org>
5332 * src/Makefile.am: Rename gen-introspect to g-idl-scanner,
5333 don't make the repository library and the other utilites link against
5336 * src/gen-introspect.c: (g_igenerator_create_object),
5337 (g_igenerator_create_interface), (g_igenerator_create_boxed),
5338 (g_igenerator_create_enum), (g_igenerator_create_flags),
5339 (g_igenerator_process_module_symbol),
5340 (g_igenerator_process_module), (g_igenerator_generate), (main):
5341 * src/gen-introspect.h:
5342 Refactor g_igenerator_process_types into smaller pieces.
5344 * tests/parser/Makefile.am:
5345 Depend on the gen-introspect binary
5347 2007-12-09 Johan Dahlin <johan@gnome.org>
5349 * src/gen-introspect.c (g_igenerator_process_types):
5350 Break into smaller pieces, one for each generated node type.
5352 2007-12-08 Johan Dahlin <johan@gnome.org>
5354 * src/gen-introspect.c: (g_igenerator_process_types),
5355 (g_igenerator_add_module):
5356 * tests/parser/Foo-expected.gidl:
5357 * tests/parser/foo-object.h:
5358 * tests/parser/foo.c: (foo_subobject_class_init),
5359 (foo_subobject_init):
5361 Add a subobject test and make sure to register defined classes
5362 in the lookup symbol hash table.
5364 2007-12-08 Johan Dahlin <johan@gnome.org>
5368 * src/gen-introspect.c: (g_igenerator_new), (lookup_symbol),
5369 (g_igenerator_process_types), (g_igenerator_add_module),
5370 (g_igenerator_add_include_idl), (main):
5371 * src/gen-introspect.h:
5372 * tests/parser/Makefile.am:
5373 * tests/parser/Foo-expected.gidl:
5375 Change the gen-introspect to generate namespaced module names,
5376 such as GLib.Object instead of GObject.
5377 Add a GLib.gidl which introduces GLib.Object and GLib.InitiallyUnowned,
5378 add a --include-idl parameter to gen-introspect,
5379 and update the parser test.
5381 2007-12-08 Johan Dahlin <johan@gnome.org>
5383 * src/gen-introspect.c:
5384 Move main to the end of the file and attempt to make it valid
5387 * tests/parser/Makefile.am (BUILT_SOURCES): Remove .repo here,
5388 we're not quite ready to generate metadata yet.
5393 Add a simple gen-introspect parser test
5395 2007-12-06 Gustavo J. A. M. Carneiro <gjc@gnome.org>
5397 reviewed by: Johan Dahlin <johan@gnome.org>
5400 * gobject-introspection.pc.in:
5402 * src/compiler.c: (format_output), (write_out_metadata), (main):
5403 * src/gen-introspect.c: (main):
5404 * src/gen-introspect.h:
5405 * src/generate.c: (write_callable_info), (write_repository),
5406 (load_metadata), (main):
5407 * src/gidlmodule.c: (g_idl_module_new),
5408 (g_idl_module_build_metadata):
5410 * src/gidlparser.c: (start_element_handler):
5411 * src/ginfo.c: (g_info_new), (g_info_from_entry),
5412 (g_base_info_get_name), (g_base_info_get_namespace),
5413 (g_base_info_is_deprecated), (g_base_info_get_annotation),
5414 (g_base_info_get_metadata), (g_function_info_get_symbol),
5415 (g_function_info_get_flags), (g_function_info_get_property),
5416 (g_function_info_get_vfunc), (signature_offset), (g_type_info_new),
5417 (g_callable_info_may_return_null),
5418 (g_callable_info_get_caller_owns), (g_callable_info_get_n_args),
5419 (g_callable_info_get_arg), (g_arg_info_get_direction),
5420 (g_arg_info_is_return_value), (g_arg_info_is_dipper),
5421 (g_arg_info_is_optional), (g_arg_info_may_be_null),
5422 (g_arg_info_get_ownership_transfer), (g_type_info_is_pointer),
5423 (g_type_info_get_tag), (g_type_info_get_param_type),
5424 (g_type_info_get_interface), (g_type_info_get_array_length),
5425 (g_type_info_is_zero_terminated),
5426 (g_type_info_get_n_error_domains), (g_type_info_get_error_domain),
5427 (g_error_domain_info_get_quark), (g_error_domain_info_get_codes),
5428 (g_value_info_get_value), (g_field_info_get_flags),
5429 (g_field_info_get_size), (g_field_info_get_offset),
5430 (g_registered_type_info_get_type_name),
5431 (g_registered_type_info_get_type_init),
5432 (g_struct_info_get_n_fields), (g_struct_info_get_field),
5433 (g_struct_info_get_n_methods), (g_struct_info_get_method),
5434 (find_method), (g_struct_info_find_method),
5435 (g_enum_info_get_n_values), (g_enum_info_get_value),
5436 (g_object_info_get_parent), (g_object_info_get_type_name),
5437 (g_object_info_get_type_init), (g_object_info_get_n_interfaces),
5438 (g_object_info_get_interface), (g_object_info_get_n_fields),
5439 (g_object_info_get_field), (g_object_info_get_n_properties),
5440 (g_object_info_get_property), (g_object_info_get_n_methods),
5441 (g_object_info_get_method), (g_object_info_find_method),
5442 (g_object_info_get_n_signals), (g_object_info_get_signal),
5443 (g_object_info_get_n_vfuncs), (g_object_info_get_vfunc),
5444 (g_object_info_get_n_constants), (g_object_info_get_constant),
5445 (g_interface_info_get_n_prerequisites),
5446 (g_interface_info_get_prerequisite),
5447 (g_interface_info_get_n_properties),
5448 (g_interface_info_get_property), (g_interface_info_get_n_methods),
5449 (g_interface_info_get_method), (g_interface_info_find_method),
5450 (g_interface_info_get_n_signals), (g_interface_info_get_signal),
5451 (g_interface_info_get_n_vfuncs), (g_interface_info_get_vfunc),
5452 (g_interface_info_get_n_constants),
5453 (g_interface_info_get_constant), (g_property_info_get_flags),
5454 (g_signal_info_get_flags), (g_signal_info_get_class_closure),
5455 (g_signal_info_true_stops_emit), (g_vfunc_info_get_flags),
5456 (g_vfunc_info_get_offset), (g_vfunc_info_get_signal),
5457 (g_constant_info_get_value), (g_union_info_get_n_fields),
5458 (g_union_info_get_field), (g_union_info_get_n_methods),
5459 (g_union_info_get_method), (g_union_info_is_discriminated),
5460 (g_union_info_get_discriminator_offset),
5461 (g_union_info_get_discriminator):
5462 * src/ginvoke.c: (g_function_info_invoke):
5463 * src/girepository.c: (g_irepository_register),
5464 (g_irepository_unregister), (g_irepository_get_default),
5465 (count_interfaces), (g_irepository_get_n_infos), (find_interface),
5466 (g_irepository_get_info), (g_irepository_find_by_name),
5467 (g_irepository_get_shared_library),
5468 (g_irepository_build_search_path), (g_irepository_register_file),
5469 (g_irepository_error_quark):
5470 * src/girepository.h:
5471 * src/gmetadata.c: (g_metadata_get_dir_entry),
5472 (g_metadata_check_sanity), (validate_header),
5473 (validate_array_type_blob), (validate_iface_type_blob),
5474 (validate_param_type_blob), (validate_error_type_blob),
5475 (validate_type_blob), (validate_arg_blob),
5476 (validate_signature_blob), (validate_function_blob),
5477 (validate_callback_blob), (validate_constant_blob),
5478 (validate_value_blob), (validate_field_blob),
5479 (validate_property_blob), (validate_signal_blob),
5480 (validate_vfunc_blob), (validate_struct_blob),
5481 (validate_enum_blob), (validate_object_blob),
5482 (validate_interface_blob), (validate_errordomain_blob),
5483 (validate_union_blob), (validate_blob), (validate_directory),
5484 (validate_annotations), (g_metadata_validate), (_g_metadata_init),
5485 (g_metadata_new_from_memory), (g_metadata_new_from_const_memory),
5486 (g_metadata_new_from_mapped_file), (g_metadata_free),
5487 (g_metadata_set_module), (g_metadata_get_namespace):
5489 * tests/Makefile.am:
5490 * tests/invoke/Makefile.am:
5491 * tests/invoke/invoke-namespace-find.sh:
5492 * tests/invoke/invoke.c: (main):
5494 Add a namespace/shared library mapping. fixes #313268.
5496 2007-12-03 Johan Dahlin <johan@gnome.org>
5498 * src/gidlparser.c (parse_type_internal): Disable char/gchar and
5501 2007-11-30 Jürg Billeter <j@bitron.ch>
5507 * src/gen-introspect.c: (g_idl_node_cmp), (g_igenerator_new),
5508 (g_igenerator_write_inline), (g_igenerator_write),
5509 (g_igenerator_write_indent), (g_igenerator_write_unindent),
5510 (field_generate), (value_generate), (constant_generate),
5511 (property_generate), (function_generate), (vfunc_generate),
5512 (signal_generate), (interface_generate), (struct_generate),
5513 (union_generate), (boxed_generate), (enum_generate),
5514 (node_generate), (module_generate), (get_type_from_type_id),
5515 (str_replace), (g_igenerator_process_properties),
5516 (g_igenerator_process_signals), (g_igenerator_process_types),
5517 (get_type_from_ctype), (g_igenerator_process_function_symbol),
5518 (g_igenerator_process_unregistered_struct_typedef),
5519 (g_igenerator_process_struct_typedef),
5520 (g_igenerator_process_union_typedef),
5521 (g_igenerator_process_enum_typedef),
5522 (g_igenerator_process_function_typedef),
5523 (g_igenerator_process_constant), (g_igenerator_process_symbols),
5524 (g_igenerator_add_symbol), (g_igenerator_is_typedef),
5525 (g_igenerator_generate), (main), (csymbol_new),
5526 (csymbol_get_const_boolean), (ctype_new), (ctype_copy),
5527 (cbasic_type_new), (ctypedef_new), (cstruct_new), (cunion_new),
5528 (cenum_new), (cpointer_new), (carray_new), (cfunction_new),
5529 (eat_hspace), (eat_line), (read_identifier),
5530 (g_igenerator_parse_macros):
5531 * src/gen-introspect.h:
5533 Import gen-introspect to generate introspection information by
5536 2007-11-30 Jürg Billeter <j@bitron.ch>
5538 * src/gidlnode.c: (g_idl_node_new): support creating callback nodes
5540 2007-11-30 Jürg Billeter <j@bitron.ch>
5542 * src/gidlparser.c: (end_element_handler): Don't leave requires
5545 2007-11-29 Johan Dahlin <johan@gnome.org>
5547 * src/gidlparser.c (parse_type_internal): Add char,
5548 gchar and guchar to the builtin types.
5550 2007-11-26 Johan Dahlin <johan@gnome.org>
5552 * src/ginfo.c: (g_object_info_get_type_name),
5553 (g_object_info_get_type_init):
5554 * src/girepository.c: (g_irepository_is_registered):
5555 * src/girepository.h:
5557 Add g_object_info_get_type_name, g_object_info_get_type_init and
5558 g_irepository_is_registered.
5560 2006-08-14 Jürg Billeter <j@bitron.ch>
5562 * src/gidlparser.c: (end_element_handler): Don't leave
5563 namespace and implements states too early.
5566 2007-11-26 Johan Dahlin <johan@gnome.org>
5568 * src/gmetadata.c (validate_struct_blob):
5569 pass blob_type to validate_function_blob instead of
5570 hard-coding BLOB_TYPE_STRUCT.
5572 Patch by Torsten Schoenfeld, fixes #314190
5574 2006-10-03 Torsten Schoenfeld <tsch@cvs.gnome.org>
5576 * src/compiler.c, src/generate.c, src/gidlnode.c,
5577 src/gidlparser.c, src/ginfo.c, src/girepository.c,
5578 tests/invoke/invoke.c, test/invoke/testfns.c: Hush compiler
5579 warnings about return values, signedness mismatches, unused
5580 variables, and unhandles enum values in switch statements.
5582 * tests/invoke/Makefile.am: Don't install the invoke test program.
5583 Add -I ../../src to the cflags used for the test functions files.
5585 2005-08-31 Torsten Schoenfeld <tsch@cvs.gnome.org>
5587 * src/girepository.h: Export g_invoke_error_quark.
5589 2005-08-31 Torsten Schoenfeld <tsch@cvs.gnome.org>
5591 * src/ginvoke.c: Remove the fallback implementation of
5592 g_function_info_invoke since we now formally depend on libffi.
5594 2005-07-25 Matthias Clasen <mclasen@redhat.com>
5596 * src/Makefile, tests/Makefile, tests/invoke/Makefile:
5597 Remove these files from cvs, as they are now generated.
5599 * src/gmetadata.c (validate_iface_type_blob): Don't
5600 complain if blob->pointer is not set, since that
5601 happens for enum and flag types. (#308935, Gustavo
5604 * Commit an autoconf-conversion patch by
5605 Gustavo Carneiro (#308708)
5607 2005-05-24 Matthias Clasen <mclasen@redhat.com>
5609 * src/compiler.c (main): Use it here to validate
5610 the generated metadata.
5612 * src/gmetadata.[hc]: Add code to validate a
5615 * metadata-format.txt: Updates
5617 2005-05-22 Matthias Clasen <mclasen@redhat.com>
5619 * tests/*: Add struct offsets to field and vfunc
5622 * src/generate.c (write_vfunc_info): Write offset
5623 information for vfuncs.
5625 * src/gidlnode.c (g_idl_node_build_metadata): Write
5626 the struct offsets into the metadata.
5628 * src/gidlparser.c: Parse the offset attributes of
5629 field and vfunc elements.
5631 * src/gidlnode.h: Add offset members to field and
5634 2005-05-21 Matthias Clasen <mclasen@redhat.com>
5638 * gidl.dtd: Updates.
5640 * src/g-idl-offsets.pl: A perl script which reads a .gidl
5641 file, creates, compiles and runs a C file, and folds the
5642 resulting struct offsets back into the .gidl file.
5644 2005-05-20 Matthias Clasen <mclasen@redhat.com>
5646 * src/gidlparser.c (start_field): Make fields in objects
5649 * src/gidlmodule.c: Include string.h
5654 * metadata-format.txt: Cleanup basic types.
5655 * src/*: Adapt to the changes.
5656 * tests/*: Adapt to the changes.
5657 * examples/gdk-pixbuf.gidl: Adapt to the changes.
5659 * src/gidlnode.c (g_idl_node_get_size): Report the correct
5660 size for enum blobs.
5661 (g_idl_node_get_full_size): Report the correct size for
5664 * src/gidlmodule.c (g_idl_module_build_metadata): Add some
5665 error checking for blob sizes.
5667 2005-05-19 Matthias Clasen <mclasen@redhat.com>
5669 * src/gidlnode.c (g_idl_node_build_metadata): Correctly handle
5670 interface types for which is_pointer is FALSE, e.g. enums.
5672 * src/gidlnode.c (g_idl_node_get_full_size)
5673 * src/gidlparser.c (parse_type_internal):
5674 * src/generate.c (write_type_info): Support unspecialized
5675 lists, hashtables and errors. Also emit a '*' after these.
5679 2005-05-17 Matthias Clasen <mclasen@redhat.com>
5683 * metadata-format.txt: Cleanups by Maciej Katafiasz.
5685 2005-05-15 Matthias Clasen <mclasen@redhat.com>
5687 * src/*.c: Change the directory to be addressed by
5688 1-based indexes, and use an index of zero to mean
5691 2005-05-15 Matthias Clasen <mclasen@redhat.com>
5693 * tests/roundtrips.sh (SIMPLE_TESTS): Add union.test.
5695 * tests/union.test: Add a union test.
5697 * src/generate.c: Handle unions.
5699 * src/girepository.h:
5700 * src/ginfo.c: Add GIUnionInfo and functions to access it.
5702 * src/gidlnode.c: Handle GIdlNodeUnion nodes.
5704 * src/gidlparser.c (start_union): Parse <union> elements.
5706 * src/gidlnode.h: Add a GIdlNodeUnion.
5708 * gidl.dtd: Add a <union> element.
5710 * src/gmetadata.c (g_metadata_check_sanity): Check
5713 * src/gmetadata.h: Add union_blob_size to Header,
5716 * metadata-format.txt: Add a UnionBlob.
5718 2005-05-13 Matthias Clasen <mclasen@redhat.com>
5720 * tests/*: Update testcases.
5722 * src/generate.c (write_callable_info): Don't forget to
5723 write transfer and null-ok attributes for return types
5726 * src/girepository.h:
5727 * src/ginfo.c (g_callable_info_may_return_null):
5728 New function to find out if a function may return NULL.
5730 * src/compiler.c (format_output): Make the generated
5733 * README: Point to a recent libffi snapshot.
5735 * tests/invoke/*: Some invoke tests.
5737 * src/Makefile: Add ginvoke.c and the necessary
5740 * src/girepository.h (g_function_info_invoke): Add
5743 * src/ginvoke.c (g_function_info_invoke): Initial
5744 implementation of invoke functionality based on libffi.
5746 * src/gidlnode.c (g_idl_node_build_metadata): Pass the
5747 strings and types hash tables in the right order when
5749 (find_entry_node): Free the name parts.
5751 2005-05-12 Johan Dahlin <johan@gnome.org>
5753 * src/generate.c: Generate consistent end tags.
5757 2005-05-12 Matthias Clasen <mclasen@redhat.com>
5761 * src/gidlparser.c (start_function): Actually add
5762 methods to objects. (Steven Walter)
5764 * src/girepository.h:
5765 * src/ginfo.c: Rename Transfer and Direction to
5766 GITransfer and GIDirection. (Torsten Schoenfeld)
5768 * tests/*: Make tests work with the changes in name
5771 * src/gidlnode.c (find_entry_node): Parse qualified
5772 names and generate xref nodes for them if needed. Don't
5773 require all modules to be loaded any more.
5775 * src/gidlmodule.c (g_idl_module_build_metadata): Choke
5778 * src/ginfo.c (g_object_info_get_parent): Return NULL
5779 if blob->parent is 0. Still need to make sure index
5782 * src/generate.c: Generate qualified names when
5783 referring to non-local types. Emit transfer attribute
5786 * src/compiler.c (format_output): Put the function
5787 attributes where gcc accepts them.
5789 2005-05-11 Matthias Clasen <mclasen@redhat.com>
5791 * src/compiler.c (main): Add a --verbose cmdline option
5792 and only log messages if it is specified.
5795 * src/gidlnode.c (init_stats, dump_stats): Collect some
5796 statistics on string and type sharing.
5798 * src/gidlmodule.c (g_idl_module_build_metadata): Use
5799 g_message() instead of fprintf().
5801 * src/gidlnode.c (g_idl_node_free): Make this more robust.
5802 (g_idl_node_get_size): Implement for structs.
5803 (g_idl_node_get_full_size): Handle parent being NULL.
5804 (serialize_type): Handle lookup failures more gracefully.
5806 2005-05-10 Matthias Clasen <mclasen@redhat.com>
5808 * src/gidlnode.c (g_idl_node_get_full_size): Correct the
5809 size calculation for 2-parameter types and for objects.
5811 * src/compiler.c: Add a cmdline option for debug output
5812 and install a log handler to implement it.
5813 * src/gidlnode.c: Add some debug spew.
5817 * src/gidlmodule.c (g_idl_module_build_metadata): Don't
5818 forget to count the module name when calculating the
5819 required size for the metadata.
5822 * src/gidlparser.c: Fix compiler warnings.
5824 2005-05-09 Matthias Clasen <mclasen@redhat.com>
5826 * src/compiler.c (main): Free the option context.
5828 * gidl.dtd: Clean up handling of names. All elements
5829 have a "name", only the elements corresponding to
5830 actual callable functions (function, method, constructor),
5831 have an additional "symbol" attribute holding the
5832 dlsym()-able function name.
5834 * src/generate.c: Adapt to generate xml matching the
5838 * src/gidlnode.c: Adapt to parse the new dtd.
5840 * tests/*.test: Adjust to the new dtd.
5842 * metadata-format.txt:
5843 * src/gmetadata.h: Remove the short_name field
5845 * src/gmetadata.c: Shrink size of ValueBlob to 12.
5846 * src/girepository.h:
5847 * src/ginfo.c (g_value_info_get_short_name): Removed
5849 2005-05-09 Matthias Clasen <mclasen@redhat.com>
5851 * gidl.dtd: Allow constructors for boxed types,
5852 patch by Jonathan Blandford.
5855 2005-05-09 Matthias Clasen <mclasen@redhat.com>
5857 * --- Initial import ---