1 2008-11-13 Andreas Rottmann <a.rottmann@gmx.at>
3 Bug 560708 – Don't treat arrays that have a length specified as
4 zero-terminated by default
6 * giscanner/transformer.py: Default to non zero terminated for
8 * tests/*: Update, add test for zero vs not.
10 2008-11-13 Andreas Rottmann <a.rottmann@gmx.at>
12 Bug 557788 - Return types for constructors in generated typelib bogus
14 * girepository/girnode.c: Namespace-qualify XREFs; not doing so is
15 obviously broken in the face of duplicate names in different
17 * tests/scanner/*expected.gir: Fix up.
19 2008-11-13 Owen Taylor <otaylor@redhat.com>
21 * girepository/girffi.c: Fix "Unexpected time for time_t"
24 2008-11-13 Colin Walters <walters@verbum.org>
26 Bug 558436 - avoid having scanner load app code
28 * giscanner/cgobject.py: Delete; we no longer load shared
30 * giscanner/dumper.py: Support for linking a library to
31 a stub binary for introspection.
32 * giscanner/glibtransformer.py: Rewrite to use gdump XML
33 from invocation of child binary.
34 * giscanner/transformer.py: Fix up to use fully qualified
35 name in parse tree. Make parse_ctype public so we can use
36 it inside glibtransformer.
37 * tests/scanner/barapp.c: New test, using --program arg
39 * tests/*: Update to use common.mk for invoking scanner.
40 * tools/g-ir-scanner: Add options --program, --program-arg,
42 * docs/g-ir-scanner.1: Update.
44 2008-11-13 Colin Walters <walters@verbum.org>
46 * configure.ac: Depend on Gio, we use it in gdump.c.
47 * girepository/gdump.c: Code to dump GType data to XML.
48 * girepository/girepository.c: Add option group for dumping.
49 * girepository/girepository.h: Define API for the above.
51 2008-11-13 Colin Walters <walters@verbum.org>
53 * common.mk: Add a file to include with Makefile fragments
54 useful for scanner invocation.
56 2008-11-13 Tommi Komulainen <tommi.komulainen@iki.fi>
58 * tests/everything/gitesttypes.c (test_filename_return): Return
59 strings in filename encoding.
61 2008-11-13 Owen Taylor <otaylor@redhat.com>
63 Bug 560253 – Add structure and boxed types to Everything test module
65 * tests/everything/gitesttypes.[ch]: Add examples of:
67 Plain old data structs
68 Plain old data structs with nested fields
70 Plain old data boxed with nested fields
71 More complicated boxed types with internal state
73 2008-11-12 Johan Dahlin <jdahlin@async.com.br>
75 * tests/everything/gitesttypes.c (test_gtype_in):
76 * tests/everything/gitesttypes.h:
77 Add a test of GType arrays, a la gtk_list_store_set_columns.
79 2008-11-12 Owen Taylor <otaylor@redhat.com>
81 Bug 560419 – Cache includes when parsing
83 Keep track of all modules parsed within a GIrParser, and when a
84 module is referenced a second time, use the existing parsed copy
87 2008-11-12 Owen Taylor <otaylor@redhat.com>
89 Fix management of ParseContext.includes_modules (#560419)
91 * girepository/girparser.c: Fix some trivial bugs in managing the
92 list of include modules. (Add to module's list twice, not
93 initialized to NULL, not freed.)
95 2008-11-12 Owen Taylor <otaylor@redhat.com>
97 Keep aliases and disguised_structures local to each module (#560419)
99 * girepository/girmodule.[ch]: When parsing, keep keep a separate
100 hash tables of aliases and 'disguised' flags for each module, and
101 store that on the module.
103 After parsing an include merge the aliases/disguised flags to the
106 * girepository/girparser.c: Remove 'prefix_aliases' flag and
107 always prefix aliases/disguised structure types when parsing; this
108 simplifies the code considerably.
110 2008-11-12 Owen Taylor <otaylor@redhat.com>
112 Fix mismatches between .gir name and 'name' attribute (#560419)
114 * tests/boxed.gir tests/constant.gir tests/enum.gir tests/invoke/invoke.c
115 tests/invoke/testfns-1.0.gir tests/object.gir tests/struct.gir: Fix places
116 where the 'name' element of <namespace/> didn't match the filename of the
117 gir, an assumption that the compiler has always expected and now enforces.
119 2008-11-12 Owen Taylor <otaylor@redhat.com>
121 Only allow one <namespace/> element per <repository/> (#560419)
123 * girepository/girparser.c: The logic in girparser.c didn't work
124 very well if there were multiple <namespace/> nodes within a
125 single <repository/> (context->namespace was always the overall
126 filename and not the the name specified in the <namespace/>
127 element for one thing; this would cause aliases to be mis-prefixed
128 in include modules.) Also check that the "name" in the
129 <namespace/> node matches the filename.
131 2008-11-12 Owen Taylor <otaylor@redhat.com>
133 Add a GirParser object to hold the state of a compilation
135 * girepository/girparser.[ch] tools/compiler.c: Add a toplevel
136 GirParser object to hold state that is global across a
137 compilation. Currently just holds the include path, but will
138 eventually also keep a cached list of parsed modules.
140 2008-11-12 Tommi Komulainen <tommi.komulainen@iki.fi>
142 * girepository/girepository.c (find_namespace_latest): Fix
145 2008-11-12 Tommi Komulainen <tommi.komulainen@iki.fi>
147 * configure.ac: use 'introspection' component for bugs
149 2008-11-12 Johan Dahlin <jdahlin@async.com.br>
151 * tests/everything/gitesttypes.c (test_filename_return):
152 * tests/everything/gitesttypes.h:
153 Add a filename return test.
155 2008-11-12 Tommi Komulainen <tommi.komulainen@iki.fi>
157 * tests/offsets/Makefile.am (gitestoffsets.c): fix
158 gen-gitestoffsets invocation with builddir != srcdir
160 2008-11-12 Johan Dahlin <jdahlin@async.com.br>
162 * girepository/girepository.c:
163 Change the element type from utf8 to filename
164 * girepository/girnode.c (g_ir_node_build_typelib):
165 Special case filename equally to utf8 here.
167 2008-11-12 Johan Dahlin <jdahlin@async.com.br>
170 Remove unused variables, add a dependency of girepository.ch, so when
171 they change we rebuild the gir automatically.
173 2008-11-12 Johan Dahlin <jdahlin@async.com.br>
175 * girepository/girepository.c (g_irepository_get_search_path):
176 * girepository/girepository.h:
177 Add a g_irepository_get_search_path, so we can access the search
180 2008-11-12 Johan Bilien <jobi@via.ecp.fr>
182 Bug 560474 – g-ir-compiler crashes when compiling the glib gir
184 * girepository/girparser.c: avoid freeing an uninitialized pointer
186 2008-11-12 Johan Dahlin <jdahlin@async.com.br>
189 * giscanner/glibtransformer.py:
190 * tools/g-ir-scanner:
191 Add a GIRepository-2.0.gir. Change the libtool lookup slightly
192 so we can just pass in --library=foo/bar/baz.la and the scanner
193 does the right thing.
194 Don't warn for _get_type() functions if they don't take any
197 2008-11-11 Owen Taylor <otaylor@redhat.com>
199 Bug 560404 – Prefix types when resolving aliases in included modules
201 * girepository/girparser.c: When resolving aliases in an included
202 module, prefix types before looking them up.
204 2008-11-11 Owen Taylor <otaylor@redhat.com>
206 Compute field offsets and overall size for object structures
208 Bug 560326 – Fails to build Gtk-2.0.typelib with "Unexpected non-pointer
209 field of type object in structure"
211 Do basic computation of field offsets for objects and interfaces;
212 this doesn't attempt to address all of the "mess" for virtual
213 functions described in Bug 560281.
215 2008-11-11 Tommi Komulainen <tommi.komulainen@iki.fi>
217 Bug 560308 – g-ir-compiler goes in infinite loop on Gdk-2.0.gir
219 Based on patch by Johan Bilien.
221 * giscanner/transformer.py (_create_member, _create_parameter):
222 Resolve types here as well.
223 (_resolve_type_name_1): Try resolving using 'ctype' first since
224 it's least ambiguous. Fixes struct member type resolution with
225 similarly named types, e.g. Gdk.PangoRendererClass and
227 * tests/scanner/foo*: Add test.
229 2008-11-11 Owen Taylor <otaylor@redhat.com>
231 * girepository/girparser.c: Search provided include dirs before
232 the default directories.
234 2008-11-11 Owen Taylor <otaylor@redhat.com>
236 * girepository/giroffsets.c: Include fully-qualified names in
239 2008-11-11 Owen Taylor <otaylor@redhat.com>
241 * girepository/giroffsets.c: Fail gracefully with an informative
242 error message when recursion is encountered when computing a
245 2008-11-11 Owen Taylor <otaylor@redhat.com>
247 * girepository/girparser.c: Remove an unused variable.
249 2008-11-10 Owen Taylor <otaylor@redhat.com>
251 Add tests for field offset computations
253 * tests/offsets/offsets.h: Header file with structure definitions to test
255 * tests/offsets/gen-gitestoffsets: Generate a C program that computes
256 field offsets for the structures in offsets.h two ways: using
257 the information from a generated typelib, and as computed by the
260 We diff these two versions to test that everything is OK.
262 2008-11-10 Owen Taylor <otaylor@redhat.com>
264 Remove field offsets from g-ir-generate output and test inputs
266 Field offsets are a) architecture dependent so they shouldn't be part
267 of the architecture-independent gir format which is installed in
268 datadir. b) Are architecture-dependent so they shouldn't be in test
271 * girepository/girparser.c: Don't parse offset for fields
272 * tools/generate.c: Don't parse offset for fields
273 * tests/*.gir test/scanner/*.tgir: Remove offsets
275 (Virtual function and discriminator offsets are not removed, as they
276 aren't fully hooked up to the field-offset computation machinery yet.)
278 2008-11-10 Owen Taylor <otaylor@redhat.com>
280 Bug 560252 - Compute field offsets before writing typelib
282 * girepository/girnode.h: Store the total size and alignment for
283 GIrNodeStruct/Boxed/Union.
285 * girepository/giroffset.c: New file implementing computation of
286 structure field offsets.
288 * girepository/girnode.c: Compute structure field offsets before
289 writing types into the typelib.
291 * docs/typelib-format.txt: Document that a field offset of 0xFFFF
292 means "unknown". Also fix description of the discriminator_offset
295 2008-11-10 Owen Taylor <otaylor@redhat.com>
297 Bug 560250 - Fully parse included modules
299 For some things, like computing structure offsets to put into the typelib
300 we need more than just the aliases from included modules. Do a completel
301 parse of included modules and store in module->included_modules.
303 Also add g_ir_find_node() to find node information from within the
304 active set of modules and their includes.
306 2008-11-10 Owen Taylor <otaylor@redhat.com>
308 Split g_ir_ffi_get_ffi_type() out from ginvoke.c
310 Extract a function to convert GITypeTag to ffi_type from the internals
311 of ginvoke.c. This will be useful in figure out structure alignment.
313 Also fix handling of gsize and time_t to be portable. (Add a check
314 to configure.ac to figure out the width of time_t.)
316 2008-11-10 Owen Taylor <otaylor@redhat.com>
318 Bug 560248 – "disguised structures"
320 Certain types like GIConv and GdkAtom are pointers internally but don't
321 look like pointers when referenced. They have the form.
323 typedef struct _X *X;
325 Parse these as structures/records but mark them in the gir with a 'disguised'
326 attribute so that we know that they need special handling.
328 In the typelib treat them like any other structure.
330 2008-11-09 Jürg Billeter <j@bitron.ch>
333 * giscanner/girwriter.py:
335 Write throws attribute for virtual functions, fixes bug 559703
337 2008-11-07 Johan Dahlin <jdahlin@async.com.br>
339 * giscanner/libtoolimporter.py (LibtoolImporter.find_module): Clear
340 up some confusion about the second argument to find_module, it's
341 actually the packages __path__ attribute which we can safely ignore
343 (LibtoolImporter.load_module): Set module.__loader__ as per PEP 302.
345 2008-11-07 Owen Taylor <otaylor@redhat.com>
347 Bug 559737 – Deal with continuations in macros
349 * giscanner/giscannerlexer.l: Treat continuation lines the same
350 as regular newlines. This makes the scanner not complain about
351 #define foo(x) \ <stuff> inside a C file. There's no attempt
352 however to handle parsing macro definitions split across lines.
354 2008-11-07 Johan Dahlin <jdahlin@async.com.br>
356 * giscanner/cachestore.py:
357 Handle broken cache entries, write only filesystems and
358 running out of diskspace.
360 2008-11-07 Owen Taylor <otaylor@redhat.com>
362 * giscanner/giscannermodule.c (pygi_source_scanner_lex_filename):
363 Set current_filename before lexing the file so error messages
364 are reported in the right file.
366 2008-11-06 Colin Walters <walters@verbum.org>
368 * tests/everything/*: Add some tests for strv.
370 2008-11-05 Colin Walters <walters@verbum.org>
372 * girepository/ginvoke.c (g_function_info_invoke): Don't use
373 nested scope local variable for error which may go away after
374 conditional is complete.
376 2008-11-05 Colin Walters <walters@verbum.org>
378 * giscanner/scannerlexer.l: Avoid static 256 char buf which we
379 manipulate hackily; just use GString. This avoids an
380 uninitialized memory read pointed out by Havoc.
382 2008-11-04 Johan Dahlin <jdahlin@async.com.br>
384 * giscanner/__init__.py:
386 * giscanner/cachestore.py:
387 * giscanner/cgobject.py:
388 * giscanner/girparser.py:
389 * giscanner/girwriter.py:
390 * giscanner/giscannermodule.c:
391 * giscanner/glibast.py:
392 * giscanner/glibtransformer.py:
393 * giscanner/libtoolimporter.py:
394 * giscanner/minixpath.py:
395 * giscanner/odict.py:
396 * giscanner/sourcescanner.c:
397 * giscanner/sourcescanner.h:
398 * giscanner/sourcescanner.py:
399 * giscanner/transformer.py:
400 * giscanner/utils.py:
401 * giscanner/xmlwriter.py:
403 Relicense the giscanner library under LGPLv2+.
404 This has been approved by all contributors.
406 2008-11-01 Owen Taylor <otaylor@redhat.com>
408 Bug 558848 giparser.py: shared library should be optional
410 When parsing a .gir, allow the shared-library attribute
411 of <namespace/> to be missing: this corresponds to the handling
412 in libgirepository and elsewhere.
414 2008-11-01 Tommi Komulainen <tommi.komulainen@iki.fi>
416 Bug 557898 – Fails to build on OSX 10.4
418 * configure.ac: Check for $shrext_cmds that should be implicitly
419 available if you're using libtool >= 2.0. If undefined, call
420 libtool --config explicitly to get its value.
421 * girepository/gtypelib.c: Remove special case for (non-)Darwin
424 2008-10-31 Colin Walters <walters@verbum.org>
426 * COPYING, COPYING.lib, COPYING.tools: Clarify licensing status.
428 2008-10-31 Johan Dahlin <jdahlin@async.com.br>
430 * configure.ac: Post release version bump
433 2008-10-31 Johan Dahlin <jdahlin@async.com.br>
437 * docs/release-checklist.txt:
440 2008-10-31 Johan Dahlin <jdahlin@async.com.br>
442 * Makefile.am: add an upload-release target
443 * docs/release-checklist.txt:
444 Release process documentation
446 2008-10-31 Colin Walters <walters@verbum.org>
448 Bug 558109 – _g_typelib_init fails to find shared libraries
450 * transformer/glibtransformer.py: Use ctypes' find_library
451 on passed libraries and write that for the shared-library
452 entry. We want to avoid depending on -devel packages.
454 2008-10-31 Johan Dahlin <jdahlin@async.com.br>
456 * docs/g-ir-scanner.1:
457 Document the renaming options.
459 2008-10-31 Tommi Komulainen <tommi.komulainen@iki.fi>
461 * giscanner/Makefile.am:
462 * tests/invoke/Makefile.am:
463 * tests/repository/Makefile.am: List in-tree libraries first in
464 LDADD / LIBADD. If installed library is listed first, the
465 resulting binary will prefer installed version to one in .libs,
466 possibly making 'make check' behave strangely.
468 2008-10-30 Tommi Komulainen <tommi.komulainen@iki.fi>
470 * giscanner/ast.py: map 'id' (ObjC) to 'any' type to stop
471 gir-repository from choking with gdk/quartz
473 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
475 * giscanner/giscannermodule.c (calc_attrs_length),
476 (pygi_collect_attributes):
477 * giscanner/xmlwriter.py:
478 Write a C version of the xml namespace formatter.
479 Saves 15% of the time it takes to create a gtk gir.
481 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
483 * giscanner/xmlwriter.py: Abstract attribute formatting
484 to a function external to the XMLWriter class.
486 * giscanner/scannerlexer.l:
487 Parse and discard __typeof and __attribute.
489 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
491 * giscanner/girparser.py:
492 Remove arguments from the constructor, move them to
493 separate accessors. Add a new parse_tree method
494 which takes an element tree instance.
495 * tools/g-ir-scanner:
496 Update callsite for this
498 * giscanner/Makefile.am:
499 * giscanner/cachestore.py:
500 * giscanner/transformer.py:
501 Cache the include parsing. Saves ~25% time when
502 creating vte (which includes everything up to gtk+).
504 2008-10-30 Colin Walters <walters@verbum.org>
506 * giscanner/transformer.py: Don't reparse includes
507 we've already processed.
509 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
511 * giscanner/girparser.py:
512 * giscanner/transformer.py:
513 Avoid parsing parameters, types etc when parsing
514 includes. Should speed up include parsing a bit.
516 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
518 * giscanner/girparser.py:
519 Avoid big if/else and use a dispatch table like
522 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
524 * giscanner/transformer.py:
525 Clean up include parsing and registration.
527 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
529 * giscanner/transformer.py:
532 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
534 Bug 558383 – builddir != srcdir build fails if giscanner python module not already installed
537 construct PYTHONPATH just once
539 * tests/everything/Makefile.am:
540 * tests/scanner/Makefile.am:
541 add $(top_srcdir) to PYTHONPATH to
542 handle builddir != srcdir
544 * giscanner/libtoolimporter.py:
545 * giscanner/sourcescanner.py:
546 Make the libtoolimporter work when distchecking too.
548 Mostly based on patch by Tommi Komulainen
550 2008-10-29 Owen Taylor <otaylor@redhat.com>
552 * giscanner/glibtransformer.py: If a filename of an existing
553 file is passed to --library, hunt for it directly, rather than
554 searching for a corresponding library.
556 2008-10-29 Johan Dahlin <jdahlin@async.com.br>
558 * giscanner/libtoolimporter.py:
559 * giscanner/sourcescanner.py:
560 Clean up the libtool importer a bit. Add a context so we
561 can use it through a with statement.
562 Don't just look in the current directory, look in the whole
565 2008-10-29 Tommi Komulainen <tommi.komulainen@iki.fi>
567 Bug 558065 – gitesttypes should be installed
571 * tests/types/Makefile.am -> tests/everything/Makefile.am
572 * tests/types/gitesttypes.c -> tests/everything/gitesttypes.c
573 * tests/types/gitesttypes.h -> tests/everything/gitesttypes.h
574 move tests/types to tests/everything
576 * tests/everything/Makefile.am: build normal shared library
577 libgirepository-everything.so.1.0.0 and corresponding typelib
578 Everything-1.0.typelib
580 * tests/everything/Makefile.am: explicitly link libtool
581 versioning with typelib versioning with variables
583 2008-10-28 Johan Bilien <jobi@via.ecp.fr>
585 * tools/g-ir-scanner: add LD_LIBRARY_PATH to LPATH before calling ld.
587 2008-10-27 Johan Bilien <jobi@via.ecp.fr>
589 * gio/gio-2.0.c: add allow-none annotations, based on the pygobject
592 2008-10-27 Johan Bilien <jobi@via.ecp.fr>
594 Bug 558068 – when invoking a method, offset the in arguments by one,
597 * tests/invoke/invoke.c, tests/invoke/testfns.c,
598 tests/invoke/testfns-1.0.gir: Add testing of method and constructor.
599 * girepository/ginvoke.c: do not offset the index of given out
600 arguments by one for methods, "this" is provided as in argument only.
602 2008-10-27 Johan Bilien <jobi@via.ecp.fr>
604 * gir/gio-2.0.c: add annotation for g_file_delete
606 2008-10-27 Tommi Komulainen <tommi.komulainen@iki.fi>
608 Bug 558062 – provide and use paths in the .pc file
610 * gobject-introspection-1.0.pc.in: provide typelibdir variable
611 for where .typelibs should be installed (callers shouldn't need
612 to construct paths from bits and pieces)
614 2008-10-25 Andreas Rottmann <a.rottmann@gmx.at>
616 Bug 557791 – g_irepository_require() could return a GTypelib *
618 * girepository/girepository.c: Return GTypelib; this is useful
619 for low level manipulation.
621 2008-10-25 Colin Walters <walters@verbum.org>
623 Bug 557788 – Return types for constructors in generated typelib bogus
625 * giscanner/glibtransformer.py: Don't resolve ctors incrementally,
626 rely on end pass resolution.
628 2008-10-25 Andreas Rottmann <a.rottmann@gmx.at>
630 Bug 557786 - support fixed size arrays
632 * girepository/ginfo.c: Add g_type_info_get_array_fixed_size.
633 * giscanner/scannerparser.y: Retain fixed array size.
634 * giscanner/ast.py: Add to note.
635 * giscanner/girwriter.py: Write to gir.
636 * girepository/girnode.c: Write it to typelib.
637 * tools/generate.c: Generate.
638 * tests/*: Add tests.
640 2008-10-25 Colin Walters <walters@verbum.org>
642 Bug 557076 - move typelibs to $libdir
644 * configure.ac: Steal some configury bits from dbus to expand
646 * gir/Makefile.am: Move to libdir.
647 * girepository/girepository.c: Stop searching XDG_DATA_DIRS;
648 instead just look at one hardcoded path in libdir.
649 * acinclude.m4: Bits from dbus.
651 2008-10-24 Johan Dahlin <johan@gnome.org>
653 * girepository/girnode.c (g_ir_node_check_unhandled_members):
654 Be quiet, do not warn about unhandled members.
656 2008-10-24 Johan Dahlin <johan@gnome.org>
658 * girepository/gtypelib.c:
659 Only use SHLIB_SUFFIX on darwin, otherwise use
660 G_MODULE_SUFFIX, we cannot get shext_cmds from libtool 2.2.
662 2008-10-24 Lucas Rocha <lucasr@gnome.org>
664 Bug 557623 - Constructors shouldn't be flagged as methods.
666 * girepository/ginfo.c (g_function_info_get_flags): ditto.
668 2008-10-24 Johan Dahlin <johan@gnome.org>
670 * giscanner/scannerparser.y:
671 Check against division by zero for the modula operator.
672 This fixes header parsing of OSX system headers included
675 2008-10-24 Johan Dahlin <johan@gnome.org>
679 Add a CONTRIBUTORS file and dist it.
681 2008-10-23 Tommi Komulainen <tommi.komulainen@iki.fi>
683 Bug 556739 – transfer-ownership attribute should be mandatory in .gir
685 * girepository/girparser.c (parse_param_transfer):
686 * giscanner/transformer.py (_create_parameter, _create_return):
687 * giscanner/girwriter.py (_write_return, _write_parameter):
688 * tools/generate.c (write_callable_info): always write and
689 require "transfer-ownership" for return-values and parameters
692 * tests/invoke/testfns-1.0.gir:
694 * tests/scanner/DrawableAdditions.xml:
695 * tests/scanner/GtkFrob-1.0-expected.tgir:
696 * tests/scanner/annotation-1.0-expected.tgir:
697 * tests/scanner/drawable-1.0-expected.tgir:
698 * tests/scanner/drawable-injected-1.0-expected.gir:
699 * tests/scanner/drawable-injected-1.0-expected.tgir:
700 * tests/scanner/foo-1.0-expected.tgir: Updated
702 2008-10-23 Tommi Komulainen <tommi.komulainen@iki.fi>
704 * giscanner/cgobject.py: build fundamental types same way as glib
706 * giscanner/glibtransformer.py (_type_from_gtype): record GType
707 when constructing the Type from it
709 * giscanner/glibtransformer.py (_adjust_transfer): Check whether
710 the parameter is a GObject from its GType, if available.
712 * giscanner/glibtransformer.py (_adjust_transfer):
713 * tests/scanner/foo-1.0-expected.gir:
714 * tests/scanner/foo-1.0-expected.tgir: deduce
715 transfer-ownership from GTypes
717 2008-10-23 Tommi Komulainen <tommi.komulainen@iki.fi>
719 * giscanner/transformer.py (_create_parameter):
720 * tests/scanner/foo-1.0-expected.gir: make varargs
721 transfer-ownership="none"
723 2008-10-23 Colin Walters <walters@verbum.org>
725 Bug 556739 - transfer ownership
727 * giscanner/ast.py: Refactor Parameter/Return to share
728 common attributes. Add transfer_inferred attribute
729 which says whether or not we made a guess.
730 * giscanner/transformer.py: Add much more extensive
731 heuristics around parameter and return transfer.
732 * giscanner/glibtransformer.py: Adjust to inspect
736 2008-10-22 Tommi Komulainen <tommi.komulainen@iki.fi>
738 Bug 557377 – Add test to ensure annotations survive the roundtrip via typelib
740 * tests/scanner/Makefile.am:
741 * tests/scanner/annotation-1.0-expected.tgir:
742 * tests/scanner/drawable-1.0-expected.tgir:
743 * tests/scanner/drawable-injected-1.0-expected.tgir:
744 * tests/scanner/foo-1.0-expected.tgir:
745 * tests/scanner/GtkFrob-1.0-expected.tgir:
746 * tests/scanner/utility-1.0-expected.tgir: Add test to ensure
747 annotations survive the roundtrip via typelib
749 The expectations are as currently produced by g-ir-generate,
750 comparison with the .gir files shows there are differences.
752 2008-10-23 Johan Bilien <jobi@via.ecp.fr>
754 Bug 557468 – Support for GI_TYPELIB_PATH
756 * girepository/girepository.c: if the GI_TYPELIB_PATH is set, add the
757 provided paths to the global search path.
759 2008-10-22 Tommi Komulainen <tommi.komulainen@iki.fi>
761 Bug 557379 – g-ir-generate not writing the 'abstract' attribute
763 * tests/scanner/drawable-1.0-expected.tgir:
764 * tests/scanner/drawable-injected-1.0-expected.tgir:
765 * tests/scanner/foo-1.0-expected.tgir:
766 * tools/generate.c (write_object_info): write 'abstract'
767 attribute for classes
769 2008-10-22 Lucas Rocha <lucasr@gnome.org>
771 * girepository/girmodule.c, girepository/gtypelib.c,
772 girepository/girparser.[ch]: fix some build warnings.
774 2008-10-22 Tommi Komulainen <tommi.komulainen@iki.fi>
776 Bug 557405 – Use 'allow-none' consistently
778 * docs/typelib-format.txt:
779 * girepository/ginfo.c (g_arg_info_may_be_null):
780 * girepository/girnode.c (g_ir_node_build_typelib):
781 * girepository/girnode.h (struct _GIrNodeParam):
782 * girepository/girparser.c (start_parameter):
783 * girepository/girwriter.c (function_generate):
784 * girepository/gtypelib.h (ArgBlob):
786 * tests/function.gir:
787 * tools/generate.c (write_callable_info): Use 'allow-none'
788 consistently throughout
790 2008-10-22 Tommi Komulainen <tommi.komulainen@iki.fi>
792 Bug 557092 – Callback annotations not used
794 * giscanner/transformer.py (_create_callback): use annotations
796 * tests/scanner/annotation.h
797 * tests/scanner/annotation-1.0-expected.gir: add tests
799 2008-10-21 Colin Walters <walters@verbum.org>
801 * giscanner/scannerlexer.l: Don't require trailing whitespace after
802 uncommented parameters.
805 2008-10-21 Colin Walters <walters@verbum.org>
807 * girepository/girepository.c: Ensure that when doing an unversioned
808 require, we prefer items earlier in the search path to later ones.
810 2008-10-21 Owen Taylor <otaylor@redhat.com>
812 * giscanner/transformer.py: For string parameters allow transfer annotation
813 to override the standard automatic guessing based on 'const'.
815 2008-10-21 Johan Bilien <jobi@via.ecp.fr>
817 Bug 557241 – "throws" flag for functions
819 * tests/scanner/drawable-1.0-expected.gir,
820 tests/scanner/drawable-injected-1.0-expected.gir,
821 tests/scanner/drawable.[ch]: add simple test for throwing
822 function (has GError ** as last argument)
824 * giscanner/ast.py: add a 'throws' flag to Function
825 * giscanner/glibtransformer.py: if a function's last paramerter is
826 a GError, set the 'throws' flag and remove that parameter
827 * giscanner/girwriter.py: write out the 'throws' attribute
828 * giscanner/girparser.py: support parsing the 'throws' attribute
830 * tests/repository/gitestthrows.c: add a simple test to check the
831 throws flag in a typelib and invoke the function
833 * girepository/ginfo.c, girepository/girnode.[ch],
834 girepository/girnode.h, girepository/girparser.c,
835 girepository/girepository.h: Add and parse the GI_FUNCTION_THROWS flag
837 * girepository/ginvoke.c: if a function throws, add a GError as last
838 arguments, and propagate the error to the invoker.
840 2008-10-21 Tommi Komulainen <tommi.komulainen@iki.fi>
842 * giscanner/transformer.py (_create_parameters): Warn if we see
843 annotations for unknown parameters. If .h and .c files name
844 parameters differently, the annotations may be lost.
846 2008-10-21 Johan Dahlin <johan@gnome.org>
848 Bug 556358 - don't use libtool internals
850 * giscanner/Makefile.am:
851 * giscanner/libtoolimporter.py:
852 * giscanner/sourcescanner.py:
853 * giscanner/utils.py:
854 Add a python meta importer and remove a libtool symlink hack.
856 2008-10-20 Andreas Rottmann <a.rottmann@gmx.at>
858 * tests/scanner/Makefile.am (%.typelib): Set PYTHONPATH
859 and --add-include-path appropriately when invoking the scanner.
860 * tests/types/Makefile.am (%typelib): Likewise.
862 2008-10-20 Colin Walters <walters@verbum.org>
864 Bug 556777 - validate properties
866 * giscanner/transformer.py: Add option to throw on unknown types.
867 * giscanner/glibtransformer.py: Use it on properties.
868 * tests/*: Add a test.
870 2008-10-20 Colin Walters <walters@verbum.org>
872 * giscanner/glibast.py: Also register g variants of
873 default_array_types. This is not beautiful, but
874 good alternatives aren't easy to come by.
875 This fixes gchar ** parsing.
877 2008-10-20 Colin Walters <walters@verbum.org>
879 * docs/typelib-format.txt, girepository/gtypelib.h:
880 Take a bit from ObjectInfo to represent abstract flag.
881 * giscanner/cgobject.py: Expose g_type_get_flags.
882 * girepository/girepository.h: Add accessor.
883 * girepository/ginfo.c: Implement it.
884 * giscanner/ast.py: Add is_abstract flag to generic
886 * giscanner/glibast.py: Use it.
887 * giscanner/girwriter.py: Write it.
888 * girepository/girparser.c: Parse it.
891 2008-10-20 Tommi Komulainen <tommi.komulainen@iki.fi>
893 * giscanner/girparser.py (_parse_function): don't lose
894 'transfer-ownership' attributes when injecting, check for the
897 2008-10-19 Johan Dahlin <johan@gnome.org>
899 * giscanner/scannerlexer.l: Parse and ignore __asm.
901 2008-10-19 Colin Walters <walters@verbum.org>
903 * giscanner/girparser.py: Parse array length= to ensure
904 it doesn't get lost from --inject.
906 2008-10-17 Colin Walters <walters@verbum.org>
908 Bug 556795 - char ** regression
910 * giscanner/transformer.py: Fix parsing of ctypes, add some
911 comments about what's going on.
912 * tests/*: Add a test for char **.
914 2008-10-17 Colin Walters <walters@verbum.org>
916 Bug 556783 - change namespace handling to be more consistent
918 * giscanner/transformer.py: Eliminate usage of
919 strip_namespace_object. We now treat --namespace as the default
920 --strip-prefix; however, if --strip-prefix is specified it
921 overrides --namespace. This applies to everything except function
922 names, where we do also strip the namespace.
923 * giscanner/glibtransformer.py: Remove usage of
924 strip_namespace_object.
926 * tests/*: Add skeletal GtkFrob-1.0 test which has different
927 --namespace and --strip-prefix.
929 2008-10-17 Tommi Komulainen <tommi.komulainen@iki.fi>
931 Bug 556732 – generate gir files consistently
933 * girepository/girparser.c (start_parameter):
935 * tests/invoke/testfns-1.0.gir:
936 * tools/generate.c (write_callable_info): write
937 'transfer-ownership' attribute consistently with both
938 return-value and parameter elements
940 2008-10-17 Tommi Komulainen <tommi.komulainen@iki.fi>
942 Bug 556732 – generate gir files consistently
944 * tools/generate.c (write_callable_info): write 'direction'
945 attribute only if other than 'in' to be consistent with
948 * tests/object.gir: remove direction="in" which is the default
950 2008-10-17 Tommi Komulainen <tommi.komulainen@iki.fi>
952 Bug 556732 – generate gir files consistently
954 * giscanner/ast.py (Field): add readable and writable properties
955 * giscanner/girparser.py (_parse_field): copy 'readable' and
956 'writable' attributes
957 * giscanner/transformer.py (_create_member): create fields as
959 * giscanner/glibtransformer.py (_introspect_object,
960 _pair_class_struct): make object instance and class fields
962 * giscanner/girwriter.py (_write_field):
963 * tools/generate.c (write_field_info): write field 'readable'
964 and 'writable' attributes only if non-default (read-only)
965 * girepository/girparser.c (start_field): in the absence of
966 attributes assume fields are read-only
968 * tests/struct.gir: remove redundant readable="1" from fields
969 * tests/scanner/foo-1.0-expected.gir:
970 * tests/scanner/utility-1.0-expected.gir: add writable="1" to
971 all record and union fields
973 2008-10-17 Tommi Komulainen <tommi.komulainen@iki.fi>
975 Bug 556732 – generate gir files consistently
977 * giscanner/girwriter.py (_write_property): write properties
978 'construct' attribute if set
979 * tools/generate.c (write_property_info): write properties
980 'readable' and 'writable' attributes only if non-default
981 * tests/object.gir: add writable="0"
982 * tests/scanner/foo-1.0-expected.gir: add construct="1"
984 2008-10-17 Johan Bilien <jobi@via.ecp.fr>
986 * gir/glib-2.0.c: added annotations
988 2008-10-16 Johan Bilien <jobi@via.ecp.fr>
990 * giscanner/ast.py: Also assume direction=out for size_t*, ssize_t*
993 2008-10-16 Johan Bilien <jobi@via.ecp.fr>
995 Bug 556610 – giscanner/girparser.py drops parameter options
997 * tests/scanner/drawable-injected-1.0-expected.gir,
998 tests/scanner/DrawableAdditions.xml: added simple test for injection.
999 * giscanner/ast.py: allow Parameter to take options in the constructor
1000 * giscanner/girparser.py: parse parameter options (transfer,
1001 direction, allow-none)
1003 2008-10-16 Colin Walters <walters@verbum.org>
1005 Bug 556185 - segfault on g_callable_info_get_return_type
1007 Initial patch from John Ehresman.
1009 * tests/repository/*: Add a test using
1010 g_callable_info_get_return_type. Instead of casting a
1011 GITypeInfo directly to a GIRegisteredTypeInfo, we need
1012 to call g_type_info_get_interface.
1014 2008-10-16 Colin Walters <walters@verbum.org>
1016 Bug 556579 - union and struct name misresolved
1018 * giscanner/transformer.py: The calls to _resolve_type_name
1019 for struct/union names was a legacy holdover from when type
1020 resolution had multiple phases. Now it's actively harmful
1021 since we might pull in an identical name from another
1025 2008-10-16 Colin Walters <walters@verbum.org>
1027 Bug 556432 - transfer annotations and defaults
1029 * giscanner/transformer.py: Canonicalize type
1030 after removing *, not before. This ensures that
1031 guchar* is transformed to 'uint8'.
1032 Add some comments here.
1033 * giscanner/glibtransformer.py: Add _adjust_transfer
1034 phase for tweaking GObject transfers.
1037 2008-10-16 Tommi Komulainen <tommi.komulainen@iki.fi>
1039 * configure.ac: enable bunch of gcc warning CFLAGS
1041 2008-10-16 Tommi Komulainen <tommi.komulainen@iki.fi>
1043 Bug 556543 – reduce compiler warnings
1045 * girepository/ginfo.c:
1046 * girepository/girepository.c (register_internal,
1047 count_interfaces, find_interface, find_namespace_version,
1048 parse_version, g_irepository_require):
1049 * girepository/girmodule.c (g_ir_module_build_typelib):
1050 * girepository/girnode.c (init_stats, dump_stats,
1051 _g_irnode_init_stats, _g_irnode_dump_stats,
1052 g_ir_node_can_have_member):
1053 * girepository/girparser.c (firstpass_end_element_handler,
1054 locate_gir, parse_basic, parse_type_internal, resolve_aliases,
1055 start_alias, start_type, end_type_top, parse_include, cleanup,
1057 * girepository/gtypelib.c (validate_function_blob, validate_enum_blob):
1058 * giscanner/giscannermodule.c (directive_get_options,
1059 type_get_child_list):
1060 * giscanner/scannerlexer.l (parse_gtkdoc):
1061 * giscanner/scannerparser.y (ctype_free):
1062 * giscanner/sourcescanner.c:
1063 * giscanner/sourcescanner.h (gi_source_scanner_parse_macros):
1064 * tests/types/gitesttypes.c:
1065 * tools/compiler.c (main):
1066 * tools/generate.c (write_repository): Remove unused variables
1067 and code, add missing includes, declarations and case
1070 2008-10-16 Tommi Komulainen <tommi.komulainen@iki.fi>
1072 Bug 556541 – access union members through UnionBlob rather than
1075 * girepository/ginfo.c (g_union_info_find_method): access union
1076 members through UnionBlob rather than StructBlob
1078 2008-10-15 Colin Walters <walters@verbum.org>
1080 Bug 556331 - clean up includes handling
1082 * tools/g-ir-scanner: Rework command line arguments; now we take
1083 --add-include-path and --include separately.
1084 * giscanner/girwriter.py: Separate name= and version= in include
1086 * giscanner/ast.py: Add Include type.
1087 * giscanner/transformer.py: Cleanups to register_include now that
1088 we don't need to handle mixed filenames and relative arguments.
1089 * girepository/girparser.c: Parse name and version separately;
1090 this fixes a bug as a side effect where we weren't resolving
1091 through aliases for basic types.
1092 * girepository/girepository.c: Fix format string args.
1093 * gir/Makefile.am: Update.
1096 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1098 Bug 556434 – unhandled interface/object/... member types
1100 * girepository/girnode.c (g_ir_node_check_unhandled_members,
1101 g_ir_node_build_typelib): Check all
1102 interface/object/boxed/struct/union members are processed and
1103 abort if they are not. (Mostly callbacks in structs, but also
1104 fields in interfaces.)
1106 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1108 * a/girepository/girnode.c (g_ir_node_build_members,
1109 g_ir_node_build_typelib): refactor common code for processing
1110 members to a function
1112 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1114 * gir/Makefile.am (check-local): check that typelib -> gir -> typelib
1115 transformation is lossless (it's not)
1117 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1119 * tests/Makefile.am: fix tests to compare xml to xml instead of
1120 typelib to xml, and stop on error
1122 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1124 * tools/generate.c (write_type_name, write_type_info,
1125 write_type_info, write_object_info, write_object_info,
1126 write_interface_info, write_error_domain_info): reduce code
1129 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1131 Bug 556174 – parse types for lists etc.
1133 * girepository/girparser.c (end_type_recurse):
1135 * tools/generate.c (write_type_info, write_field_info,
1136 write_callable_info, write_callable_info, write_constant_info,
1137 write_property_info): use nested <type>s for lists and hashes
1139 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1142 * tests/object.gir: remove trailing whitespace from inside
1143 elements to match g-ir-generate output
1145 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1147 * tools/generate.c (xml_printf): quote printf arguments so that
1148 we don't generate invalid XML by writing unescaped double quotes
1149 and such in attributes
1151 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1153 * tools/generate.c (write_field_info, write_callable_info,
1154 write_function_info, write_callback_info, write_struct_info,
1155 write_constant_value, write_signal_info, write_vfunc_info,
1156 write_object_info, write_interface_info, write_union_info,
1157 write_repository): remove unused indent parameters, xmlwriter
1158 keeps track of necessary indentation
1160 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1162 * tools/generate.c (xml_element_new, xml_element_free,
1163 xml_start_element, xml_end_element, xml_end_element_unchecked,
1164 xml_open, xml_close): Keep track of generated XML tree and
1165 handle indentation and closing tags properly.
1166 (write_field_info, write_callable_info, write_function_info,
1167 write_callback_info, write_struct_info, write_value_info,
1168 write_constant_info, write_enum_info, write_signal_info,
1169 write_vfunc_info, write_property_info, write_object_info,
1170 write_interface_info, write_error_domain_info, write_union_info,
1171 write_repository): Use xml_start_element and xml_end_element to
1174 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1176 * tools/generate.c (xml_printf, xml_open, xml_close, xml_free):
1177 (write_type_name, write_type_info, write_field_info,
1178 write_callable_info, write_function_info, write_callback_info,
1179 write_struct_info, write_value_info, write_constant_value,
1180 write_constant_info, write_enum_info, write_signal_info,
1181 write_vfunc_info, write_property_info, write_object_info,
1182 write_interface_info, write_error_domain_info, write_union_info,
1183 write_repository): wrap all FILE access to go through simple xmlwriter
1185 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1187 Bug 556400 – Fails to build on OS X 10.4
1189 * configure.ac: check for functions backtrace and backtrace_symbols
1190 * girepository/girparser.c (backtrace_stderr): Comment out
1191 implementation if the functions are not available.
1192 * gcov.mak (clean-gcov, clean-gcno): always call 'find' with a
1193 directory for better portability
1195 2008-10-15 Johan Bilien <jobi@via.ecp.fr>
1197 Bug 556433 – assume direction = out for int * parameters
1199 * giscanner/ast.py: define a list of types for which, if passed as
1200 reference, we assume a default direction of 'out'
1201 * giscanner/transformer.py: if a type has type pointer to one of the
1202 previously defined types, and no direction is set, assume out.
1203 * tests/scanner/drawable.[ch]: added tests for guessed direction=out
1205 2008-10-15 Johan Bilien <jobi@via.ecp.fr>
1207 * tests/scanner/annotation.c: fixed a few copy-paste errors
1209 2008-10-14 Johan Bilien <jobi@via.ecp.fr>
1211 Bug 556323 – transfer-ownership is wrong for functions returning const
1214 * giscanner/transformer.py: check for a const string as return value,
1215 not just const char*. Suggested by Colin Walters
1216 * tests/scanner/annotation-1.0-expected.gir: updated expected output
1218 2008-10-14 Johan Bilien <jobi@via.ecp.fr>
1220 * girepository/ginfo.c, girepository/girepository.h: add
1221 g_union_info_find_method
1223 2008-10-14 Colin Walters <walters@verbum.org>
1225 * tests/repository/Makefile.am: Reenable repo test.
1226 * tests/repository/gitestrepo.c: Prepend search
1227 path for $(top_builddir)/gir dir so that we don't
1228 require installation for "make check" to pass.
1230 2008-10-13 Jürg Billeter <j@bitron.ch>
1232 * giscanner/glibtransformer.py:
1233 * tests/scanner/annotation-1.0-expected.gir:
1234 * tests/scanner/drawable-1.0-expected.gir:
1235 * tests/scanner/foo-1.0-expected.gir:
1236 * tests/scanner/utility-1.0-expected.gir:
1238 Support fields in GObject structs
1240 2008-10-13 Jürg Billeter <j@bitron.ch>
1242 * giscanner/ast.py: add signed integer and off_t to type_names
1244 2008-10-12 Jürg Billeter <j@bitron.ch>
1246 * giscanner/girparser.py: Parse bits attribute of fields
1248 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1250 * tests/repository/Makefile.am: run 'gitestrepo' in 'make check'
1251 * tests/repository/gitestrepo.c (main): instantiate
1252 'GCancellable' to ensure the GType is registered before using
1255 2008-10-12 Johan Bilien <jobi@via.ecp.fr>
1257 * giscanner/girparser.py: actually add the parsed constant nodes
1259 2008-10-12 Colin Walters <walters@verbum.org>
1261 * girepository/girepository.c: Don't cast DirEntry to Blob,
1262 actually look it up by offset.
1264 2008-10-12 Johan Bilien <jobi@via.ecp.fr>
1266 * giscanner/girparser.py: parse constant nodes in gir files
1268 2008-10-12 Johan Bilien <jobi@via.ecp.fr>
1270 * giscanner/transformer.py: prefix for constants have an underscore,
1271 so remove them as if they were functions, not objects.
1273 2008-10-12 Johan Bilien <jobi@via.ecp.fr>
1275 * tests/scanner/foo-1.0-expected.gir: add constants to expected gir
1278 2008-10-12 Colin Walters <walters@verbum.org>
1280 Initial patch from Jani Monoses.
1282 * girepository/gtypelib.c: Fix inverted test for success
1285 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1287 * tools/generate.c (write_callable_info): use "transfer-ownership"
1288 attribute for return values
1290 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1292 * tools/generate.c (write_callable_info): move "transfer" and
1293 "null-ok" attributes from <function> to <return-value> element
1295 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1297 * girepository/girparser.c (start_return_value): handle
1298 "transfer-ownership" attribute
1300 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1302 * girepository/girparser.c (parse_param_transfer):
1303 * tools/generate.c (write_callable_info): use "container" for
1304 container/shallow ownership transfer (not "shallow")
1306 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1308 * girepository/girparser.c (parse_param_transfer,
1309 start_parameter): Refactor handling of transfer=none/shallow/full
1310 to separate function
1312 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1314 Bug 556048 – Crash in g_irepository_find_by_gtype
1316 * girepository/gtypelib.h (BLOB_IS_REGISTERED_TYPE): added
1317 * girepository/girepository.c (find_interface): Fix
1318 find_by_gtype case to get the type name from right offset
1320 2008-10-12 Jürg Billeter <j@bitron.ch>
1322 * giscanner/girparser.py: Fix parsing transfer-ownership attribute
1325 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1327 * girepository/gtypelib.h (RegisteredTypeBlob): make
1328 'unregistered' one bit wide as everywhere else
1330 2008-10-12 Jürg Billeter <j@bitron.ch>
1332 * giscanner/glibtransformer.py:
1333 * tests/scanner/annotation-1.0-expected.gir:
1334 * tests/scanner/drawable-1.0-expected.gir:
1335 * tests/scanner/drawable.h:
1336 * tests/scanner/foo-1.0-expected.gir:
1337 * tests/scanner/utility-1.0-expected.gir:
1339 Readd class records as workaround to not break Gtk typelib
1341 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1343 * tests/types/Makefile.am: fix typo in gitesttypes namespace
1345 2008-10-12 Jürg Billeter <j@bitron.ch>
1347 * giscanner/glibtransformer.py: Don't generate <record> elements
1349 * tests/scanner/*: Update test cases
1351 2008-10-11 Colin Walters <walters@verbum.org>
1353 Bug 552858: versioning
1355 This is a big patch. You should probably remove your installation
1358 * docs/typelib-format.txt: Add nsversion entry which holds
1359 version of namespace.
1360 * girepository/girepository.h: Add 'version' parameter to
1361 g_irepository_require. This may be NULL. Normally
1362 bindings should pass an explicit version though.
1363 * girepository/girepository.c: Lots of infrastructure to
1364 support versioning. Add some more documentation. Disallow
1365 some usage of NULL namespaces.
1366 * girepository/girmodule.c: Add version parameter.
1367 * girepository/gtypelib.c: Update header size.
1368 * giscanner/ast.py: Add version to Namespace.
1369 * giscanner/girparser.py: Parse version attribute from
1370 XML, pass to Namespace.
1371 * giscanner/girwriter.py: Write out version parameter.
1372 * giscanner/transformer.py: Clean up include registration.
1373 * tests/*: Add version attribute.
1374 * tests/invoke/invoke.c: Don't try looking up test before
1375 it's loaded in repository.
1376 * tools/generate.c: Output version parameter.
1377 * gir/Makefile.am: Add 2.0 version to .gir files.
1379 2008-10-11 Colin Walters <walters@verbum.org>
1381 * giscanner/scannerlexer.l (parse_gtkdoc): Don't lose
1382 if we have mismatched parens.
1384 2008-10-11 Lucas Rocha <lucasr@gnome.org>
1386 * giscanner/girparser.py (_parse_enumeration_bitfield): fix typo
1387 on 'members' variable.
1389 2008-10-11 Colin Walters <walters@verbum.org>
1391 Bug 555947 - update annotations syntax
1393 * giscanner/ast.py: Default to None for transfer. Remove
1394 default transfers for container types; we require this to
1396 * giscanner/girwriter.py: Transfer is now 'none', 'container',
1397 'full' to match repository.
1398 * giscanner/scannerlexer.l: Annotations now are parenthesized.
1399 * giscanner/transformer.py: Update for new annotations syntax.
1402 2008-10-11 Johan Bilien <jobi@litl.com>
1404 * giscanner/scannerparser.y: ignore non-UTF-8 string constants
1406 2008-10-11 Johan Bilien <jobi@litl.com>
1408 Bug 552347: Parse #defines constants
1410 * girepository/gtypelib.c: update the list of value_size
1411 with recently defined type tags
1412 * giscanner/scannerparser.y: brought back parsing of #defined, as
1413 present in older version
1414 * giscanner/giscannermodule.c: bind gi_source_scanner_append_filename
1415 * giscanner/girwriter.py: write out constant tags in the gir
1416 * giscanner/sourcescanner.py: add accessor for const_string
1417 * giscanner/transformer.py, giscanner/glibtransformer.py: handle
1420 2008-10-11 Tommi Komulainen <tommi.komulainen@iki.fi>
1422 Bug 555946: Install a test module exercising all types, transfer
1427 * tests/types/*: Add and install a test module that has functions
1428 accepting and returning most of the basic types to enable bindings
1429 implementors to more easily test their type conversion routines.
1431 2008-10-11 Jürg Billeter <j@bitron.ch>
1433 Bug 552374: Const strings should be identified in the gir.
1435 * giscanner/transformer.py: support string memory management
1436 * tests/scanner/foo.h: use char * and const char *
1437 * tests/scanner/foo-expected.gir: test that
1439 2008-10-11 Johan Dahlin <johan@gnome.org>
1441 * giscanner/girparser.py:
1442 Also parse enums which are not glib types.
1444 2008-10-11 Lucas Rocha <lucasr@gnome.org>
1446 Bug 552370: add one more test for unsigned as a type, not as
1449 * giscanner/ast.py: add 'uint' type name for 'unsigned'.
1450 * test/scanner/foo.h: add function which uses unsigned as a type.
1451 * test/scanner/foo-expected.gir: test that.
1453 2008-10-11 Andreas Rottmann <a.rottmann@gmx.at>
1455 Bug 555712: Struct and union issues
1457 * giscanner/scannerparser.y (struct_declarator): Use information
1458 provided about the bit width of a field.
1459 * giscanner/transformer.py (Transformer._create_member): Pass the
1460 symbol's const_int member to the created field (it represents the
1462 * giscanner/girwriter.py (GIRWriter._write_field): Output 'bits'
1463 field attribute, if present.
1464 * giscanner/ast.py (Field): Add 'bits' member, specifying the
1465 width in bits of the field (only relevant for bitfields).
1468 * giscanner/transformer.py (Transformer._create_typedef_struct)
1469 (Transformer._create_typedef_union): Add calls to _create_struct()
1470 and _create_union(), respectively. This causes the scanner to
1471 generate output for fields of struct and union typedefs.
1474 2008-10-11 Jürg Billeter <j@bitron.ch>
1476 Bug 552370: unsigned not scanned properly
1478 * giscanner/scannerparser.y: combine basic types such as unsigned
1479 int and long long when scanning
1480 * tests/scanner/foo-expected.gir:
1481 * tests/scanner/foo.c: (foo_test_unsigned):
1482 * tests/scanner/foo.h: test that
1484 2008-10-11 Lucas Rocha <lucasr@gnome.org>
1486 Bug 554854: The --typelib-xml and --inject options should reuse
1487 giscanner parser/writer.
1489 * giscanner/ast.py: add constructor list to Struct and Union.
1490 Add new param in Return's contructor to define transfer.
1491 * giscanner/girparser.py: several additions to the parser in order
1492 to have parsing all nodes of the gir xml files.
1493 * tools/g-ir-scanner (typelib_xml_strip, inject): use gir parser
1494 and writer in --inject and --typelib-xml options.
1495 * giscanner/xmlwriter.py: ignore empty attributes instead of
1496 raising an error as this basically exposes a bug in GIRParser.
1497 This should be reverted as soon as the parser is fixed.
1499 2008-10-11 Lucas Rocha <lucasr@gnome.org>
1501 Bug 552376: scanner generates wrong names for enum members when
1502 there's no defined gtype.
1504 * giscanner/utils.py (strip_common_prefix): Always strip common
1505 prefix exactly up to the last "_", and not beyond.
1506 * tests/scanner/foo.h (FooEnumNoType): add FOO_ENUM_NEUF. The point
1507 here is that the first character after the last '_' should should be
1508 the same as the character in the same position on the type name.
1509 * tests/scanner/foo-expected.gir: test that
1511 2008-10-10 Lucas Rocha <lucasr@gnome.org>
1513 Bug 555293: append library_paths to LPATH env variable to work
1514 around a bug in find_library when using ldconfig.
1516 * tools/g-ir-scanner (main): ditto.
1518 2008-10-09 Lucas Rocha <lucasr@gnome.org>
1520 * girepository/girepository.c (register_internal): fix regression on
1521 invoke test case by making sure we load the global module in the
1522 typelib when dealing with inline typelibs.
1523 * girepository/gtypelib.c: a couple of coding style fixes.
1525 2008-10-06 Lucas Rocha <lucasr@gnome.org>
1527 Bug 555294: Add support for multiple shared libraries per typelib.
1529 * girepository/ginvoke.c (g_function_info_invoke),
1530 girepository/ginfo.c(g_registered_type_info_get_g_type): use
1531 g_typelib_symbol instead of g_module_symbol.
1532 * girepository/girepository.h: remove g_typelib_set_module and add
1534 * girepository/gtypelib.[ch] (find_some_symbol, _g_typelib_init,
1535 g_typelib_new_from_memory, g_typelib_new_from_const_memory,
1536 g_typelib_free, g_typelib_symbol): chnage GTypeLib to hold a list of
1537 modules instead of just one. The symbol lookup is now abstracted
1538 behind g_typelib_symbol which tries to find the passed symbol name in
1540 * giscanner/girwriter.py, tools/g-ir-scanner: change scanner to read
1541 and write shared_library attribute as a comma-separated list of libs.
1543 2008-10-06 Colin Walters <walters@verbum.org>
1545 * giscanner/transformer.py: Parse length= annotation as
1546 a parameter name, not a raw int.
1549 2008-10-03 Colin Walters <walters@verbum.org>
1551 Bug 551744: Non-GObject types aren't aggregating ctors and methods
1553 * girepository/gtypelib.c: Allow ctors/methods on struct,union,
1555 * giscanner/glibtransformer.py: Ditto, and GLibBoxed is also a
1559 2008-10-03 Colin Walters <walters@verbum.org>
1561 Bug 554576: scan problem with ev_selection_render_selection()
1563 * giscanner/transformer.py: Only do type resolution once we've
1564 scanned all types. What could happen before is that we'd strip
1565 the namespace from local type "EvSelection" => Selection, and
1566 then later pull a "Selection" from some other namespace because
1567 we hadn't yet seen the local EvSelection. This could come
1568 down to hash table ordering and other things so not easy
1569 to write a test for.
1571 2008-10-03 Lucas Rocha <lucasr@gnome.org>
1573 * giscanner/girwriter.py (_parser_member): fix the last parameter of
1574 GLibEnumMember constructor as it should be the enum member nick.
1576 2008-10-02 Colin Walters <walters@verbum.org>
1578 Bug 552961: remove this parameter for methods
1580 * giscanner/glibtransformer.py: Delete this parameter; it is
1582 * girepository/ginvoke.c: Insert this parameter for methods.
1583 * girepository/gtypelib.c: Remove no longer needed verification of
1584 method this parameter.
1587 2008-09-30 Dan Winship <danw@gnome.org>
1589 Bug 554490: g-ir-scanner gets confused by '\\'
1591 * giscanner/scannerlexer.l (chartext, stringtext): fix use of
1592 backslashes so it will correctly parse '\\' and "\\"
1594 * tests/scanner/annotation.c: add a use of '\\' to make sure that
1597 * giscanner/glibtransformer.py (GLibTransformer.count_type): typo
1599 2008-10-02 Colin Walters <walters@verbum.org>
1601 bug 552393: Note variadic functions
1603 * giscanner/scannerparser.y: Parse ellipsis. Refactor grammar
1604 to use parameter_list directly.
1605 * giscanner/sourcescanner.h: Add ellipsis csymbol type.
1606 * giscanner/ast.py: Add Varargs type.
1607 * giscanner/transformer.py: Check for ellipsis symbol, transform
1609 * girepository/girnode.h: Add varargs flag to in-memory nodes.
1610 Parse varargs functions, but filter them out before we start
1611 compiling the typelib.
1613 2008-10-02 Colin Walters <walters@verbum.org>
1615 Bug 554632: type tag for GType
1617 * girepository/girepository.h, girepository/girepository.c:
1618 Add type tag for GType - it's a special type we don't want
1619 to resolve to just "long".
1620 * docs/typelib-format.txt: Update.
1621 * girepository/girparser.c: Parse it.
1622 * giscanner/glibtransformer.py: Ensure we don't put GType in
1624 * tools/generate.c: Remove hardcoded type list.
1627 2008-09-30 Dan Winship <danw@gnome.org>
1629 Bug 554521: scanner generates wrong names for enum members with
1630 full type name prefix
1632 * giscanner/utils.py (strip_common_prefix): Fix this to strip the
1633 right amount when the entire "first" string is a prefix of
1636 * tests/scanner/foo.h (FooEnumFullname):
1637 * tests/scanner/foo-expected.gir: test that
1639 2008-09-29 Colin Walters <walters@verbum.org>
1641 Bug 552380: Array parameters should be marked in the gir
1643 * giscanner/ast.py: Default char** to utf8[], and guchar* to
1644 uint8[]. Add Array, List, and Map subclasses of Type;
1645 these types can be generic. Return transfer defaults
1646 to true if return value is string or container type.
1647 Delete Sequence type.
1648 * giscanner/scannerlexer.l: Syntax change for annotations;
1649 use <> since it's more readable.
1650 * giscanner/girwriter.py: Write out these changes.
1651 * giscanner/girparser.py: Parse them.
1652 * giscanner/transformer.py: Have a defined set of
1653 both list and map types. When creating a type,
1654 check if the ctype we've parsed is one of them,
1655 if so create a container type subclass as appropriate.
1656 * girepository/girparser.c: Parse in generic types.
1659 2008-09-27 Colin Walters <walters@verbum.org>
1661 * tools/g-ir-scanner: Add --inject option.
1663 2008-09-25 Colin Walters <walters@verbum.org>
1665 Remove non-repository types from GIR
1667 * giscanner/ast.py: The canonical name is 'utf8', not
1669 * giscanner/glibast.py: A few more glib type mappings.
1670 * girepository/girparser.c: We only parse repository types.
1671 * tests/*.gir: Update.
1673 2008-09-23 Colin Walters <walters@verbum.org>
1675 Bug 552566: Add time_t type
1677 We need a type for time_t since it's special in C, and just
1678 mapping it to long precluded bindings from handling it
1681 2008-09-19 Colin Walters <walters@verbum.org>
1683 Bug 552390: Handle capitialization like "DBus" more robustly
1685 The to_underscores function was designed for use against prefixed
1686 names; we need a separate function which will convert names like
1687 DBusFoo into dbus_foo, not d_bus_foo.
1689 2008-09-19 Colin Walters <walters@verbum.org>
1691 Add check to make sure we're not hitting out unresolved types
1693 Validate the "this" argument for methods
1695 Remove heuristic matching of methods to classes based on prefix
1697 It was a broken hack that dated from when we handled underscoring
1698 and capitalization conventions less well.
1700 2008-09-18 Colin Walters <walters@verbum.org>
1702 Bug 552384: Use SHLIB_SUFFIX intead of G_MODULE_SUFFIX for Darwin
1704 On Darwin, the suffix for installed shared libraries (.dylib) is
1705 different from loadable modules (.so). We use a bit of magic shell
1706 script from Behdad Esfahbod to figure out the right suffix.
1708 2008-09-15 Johan Dahlin <johan@gnome.org>
1710 * giscanner/sourcescanner.py (SourceType.type_qualifier): Add
1711 a wrapper for type_qualifier as well.
1713 2008-09-15 Colin Walters <walters@verbum.org>
1715 http://bugzilla.gnome.org/show_bug.cgi?id=552065
1717 * giscanner/ast.py: Add deprecation attributes.
1718 * giscanner/girwriter.py: Write out deprecation data.
1719 * girepository/girparser.c: Relax parsing; deprecated
1720 attribute now includes freeform string.
1721 * giscanner/scannerlexer.l: Parse Deprecated.
1722 * giscanner/transformer.py: Look for deprecated attribute
1724 * tests/scanner/*: Add a Deprecated test.
1726 2008-09-14 Tor Lillqvist <tml@novell.com>
1728 * tests/scanner/Makefile.am (%.typelib): Use $(EXEEXT).
1730 2008-09-14 Colin Walters <walters@verbum.org>
1732 * giscanner/glibtransformer.py: Ignore functions with
1735 2008-09-12 Colin Walters <walters@verbum.org>
1737 * giscanner/glibtransformer.py: Accept Gtk.Type as GType.
1739 2008-09-12 Colin Walters <walters@verbum.org>
1741 * giscanner/ast.py: Bind pid_t to INT for vte.
1743 2008-09-12 Colin Walters <walters@verbum.org>
1745 * giscanner/girparser.py: Parse c:type for boxed records/unions.
1746 * giscanner/glibast.py: Avoid overwriting ctype.
1747 * giscsanner/transformer.py: Try resolving types using the GType names.
1749 2008-09-12 Colin Walters <walters@verbum.org>
1751 * giscanner/minixpath.py: Code to run an "XPath"
1752 assertion against an XML tree, taken from
1753 gir-repository/gir/tests.py.
1754 * giscanner/Makefile.am: Ship it.
1755 * tools/g-ir-scanner: Add --xpath-assertions option.
1756 * gir/GLib-assertions.txt: Add a few assertions.
1757 * gir/Makefile.am: Run them.
1759 2008-09-11 Colin Walters <walters@verbum.org>
1761 http://bugzilla.gnome.org/show_bug.cgi?id=551737
1763 * giscanner/transformer.py: Fix strip_namespace_func to only strip
1764 prefix if it ends with _. Tweak callback stripping to determine
1765 based on presence of _ whether we need to use strip_namespace_func
1766 or strip_namespace_object.
1768 2008-09-09 Owen Taylor <otaylor@redhat.com>
1770 * docs/typelib-format.txt: Wether => Whether
1772 2008-09-08 Colin Walters <walters@verbum.org>
1774 * girepository/girparser.c: Default to "readable" for properties.
1775 * giscanner/ast.py: Add readable, writable etc.
1776 * giscanner/girwriter.py: Writ them.
1777 * giscanner/glibtransformer.py: Inspect them.
1780 2008-09-07 Colin Walters <walters@verbum.org>
1782 * giscanner/cgobject.py: Add comment.
1784 2008-09-07 Colin Walters <walters@verbum.org>
1786 * giscanner/cgobject.py: Also call g_thread_init.
1788 2008-09-07 Colin Walters <walters@verbum.org>
1790 * giscanner/transformer.py: Fix regression by not
1791 stripping prefix before stripping namespace for unions
1794 2008-09-06 Colin Walters <walters@verbum.org>
1796 * giscanner/transformer.py: If a namespace contains
1797 multiple caps, try stripping both gnomekeyring_ and
1800 2008-09-07 Johan Dahlin <johan@gnome.org>
1802 Bug 551162 – giscanner does not recognize asm and __asm__
1803 * giscanner/scannerlexer.l:
1804 Patch by Jani Monoses.
1806 2008-09-06 Colin Walters <walters@verbum.org>
1808 * girepository/girnode.c: Allow gtype_name
1809 and gtype_init in struct and union.
1810 * girepository/girparser.c: Parse glib:
1811 boxed bits for both structure and union.
1812 * girepository/gtypelib.c: Don't barf
1813 if structure is boxed.
1814 * giscanner/girparser.py: Parse new XML
1816 * giscanner/girwriter.py: Write out new
1818 * giscanner/glibast.py: Define new classes
1819 which are both Boxed and Struct/Union, as
1820 well as an "Other" for everything else.
1821 * giscanner/glibtransformer.py: Handle
1822 boxed types specially; we try to merge
1823 them with a struct/union if one exists,
1824 otherwise fall back to generic boxed.
1826 * tools/generate.c: Write out new format.
1828 2008-09-06 Johan Dahlin <johan@gnome.org>
1830 * giscanner/grealpath.h: Include stdlib.h
1832 * docs/g-ir-generate.1: Remove leading %
1834 2008-09-01 Colin Walters <walters@verbum.org>
1836 * girepository/girparser.c: Look at c:type to determine
1837 whether or not an item is a pointer.
1839 2008-09-01 Johan Dahlin <johan@gnome.org>
1841 * tests/scanner/Makefile.am:
1842 Set PYTHONPATH so the scanner can run
1843 even if you didn't install anything.
1845 2008-09-01 Johan Dahlin <johan@gnome.org>
1848 Post-release version bump
1851 2008-09-01 Johan Dahlin <johan@gnome.org>
1855 2008-08-31 Colin Walters <walters@verbum.org>
1857 * giscanner/glibtransformer.py: Quiet info
1860 2008-08-31 Johan Dahlin <johan@gnome.org>
1863 Bump version to 0.5.0
1865 2008-08-31 Colin Walters <walters@verbum.org>
1867 * giscanner/glibtransformer.py: Follow aliases to ensure
1868 we don't get a constructor returning a basic type.
1869 * giscanner/transformer.py: Add function to follow aliases.
1872 2008-08-31 Johan Dahlin <johan@gnome.org>
1874 * giscanner/scannerlexer.l:
1875 * giscanner/scannerparser.y:
1876 * giscanner/sourcescanner.h:
1877 * giscanner/sourcescanner.py:
1878 Parse GCC extensions in the parser instead of just undeffing them
1879 in the pre-processor.
1881 2008-08-31 Johan Dahlin <johan@gnome.org>
1883 * giscanner/glibtransformer.py:
1884 Clean up a huge if. Do not add methods or constructors
1886 * giscanner/utils.py:
1887 second might be longer than first, check that.
1889 2008-08-31 Johan Dahlin <johan@gnome.org>
1894 2008-08-31 Colin Walters <walters@verbum.org>
1896 * girepository/girparser.c: Don't lose if we
1899 2008-08-31 Colin Walters <walters@verbum.org>
1901 * giscanner/glibtransformer.py: Look for libtool
1902 library in current directory
1903 * tests/scanner - Update.
1905 2008-08-30 Colin Walters <walters@verbum.org>
1907 * docs/typelib-format.txt: Add a guint32
1909 * gir/Makefile.am: Dep on Makefile
1910 * girepository/ginfo.c:
1911 * girepository/girepository.c: Clean up
1912 default typelib handling; remove global
1913 default_typelib variable. Ensure we handle
1914 NULL repository in more places.
1915 Support dependency resolution.
1916 Support lazy loading.
1917 * girepository/girepository.h: Remove
1918 g_irepository_unregister; we don't support
1919 unloading typelibs since really they're
1920 process-global. Update for lazy loading
1922 * girepository/girmodule.c: Use g_new0.
1923 Add dependencies to GirModule.
1924 * girepository/girparser.c: Parse dependencies.
1925 * girepository/gtypelib.c: Add 4 bytes for
1927 * tests/Makefile.am: Kill off gobject.gir,
1928 it conflicts with the real one.
1929 * tests/object.gir: Dep on GObject.
1930 * tools/generate.c: Take --includedir
1931 argument to say which directories to search
1932 for typelibs. Print out dependencies.
1934 2008-08-30 Colin Walters <walters@verbum.org>
1936 * giscanner/glibtransformer.py: Reduce warning noise.
1938 2008-08-29 Colin Walters <walters@verbum.org>
1940 * girepository/ginfo.c: Add some assertions regarding
1941 refcounts, just to be sure.
1942 * giscanner/glibtransformer.py: Blacklist a few more
1945 2008-08-29 Colin Walters <walters@verbum.org>
1947 * giscanner/glibtransformer.py: Blacklist a few
1948 functions that use GError oddly
1950 2008-08-29 Colin Walters <walters@verbum.org>
1952 * girepository/gtypelib.c: Don't crash if no
1955 2008-08-29 Colin Walters <walters@verbum.org>
1957 * girepository/girparser.c: Handle chains of aliases
1958 across modules by ensuring we fully qualify aliases
1961 2008-08-29 Colin Walters <walters@verbum.org>
1963 * girepository/girparser.c: Don't search aliases
1966 2008-08-29 Colin Walters <walters@verbum.org>
1968 * girepository/girparser.c: Rewrite type parsing
1969 to handle both GLib parsing case as well as correctly
1970 handling GLib.List and friends. Don't try to treat
1971 e.g. ListStore as a List.
1973 2008-08-29 Colin Walters <walters@verbum.org>
1975 * girepository/gtypelib.c: Add more context
1978 2008-08-29 Colin Walters <walters@verbum.org>
1980 * giscanner/glibtransformer.py: Add some informative
1981 logging messages in corner cases. Be sure we use
1982 the most recent node set instead of a cache
1983 when generating result set.
1984 * tests/: Remove duplicated bits in expected girs
1985 * girepository/girparser.c: Accept both List (for
1986 compiling GLib) and GLib.List (what the scanner
1989 * tools/generate.c: Generate canonical form.
1991 2008-08-29 Johan Dahlin <johan@gnome.org>
1993 * giscanner/config.py.in:
1994 Use datarootdir instead of datadir to avoid
1995 an autoconf warning.
1997 2008-08-29 Johan Dahlin <johan@gnome.org>
2001 * examples/gdk-pixbuf.gidl:
2003 Update and remove old cruft.
2005 2008-08-29 Johan Dahlin <johan@gnome.org>
2008 * docs/g-ir-compiler.1:
2009 * docs/g-ir-generate.1:
2010 * docs/g-ir-scanner.1:
2011 Add man pages for the generator and compiler.
2013 2008-08-29 Johan Dahlin <johan@gnome.org>
2015 * docs/g-ir-scanner.1: Document
2017 * giscanner/Makefile.am:
2018 * giscanner/gidlparser.py:
2019 * giscanner/gidlwriter.py:
2020 * tools/g-ir-scanner:
2021 Remove gidl support.
2023 2008-08-28 Colin Walters <walters@verbum.org>
2025 * tests/scanner/Makefile.am: Pass the right
2026 --includedir args. Add a Makefile dep.
2027 * tools/compiler.c: Pass includedirs down.
2028 * girepository/girparser.c: Actually put
2029 includedirs in context, pass down. Fix
2032 2008-08-28 Colin Walters <walters@verbum.org>
2034 * gir/Makefile.am: Use --includedir
2035 * girepository/girparser.c: Recursively parse
2036 includes to pull in aliases and expand them.
2037 We need this to avoid putting unknown names in
2039 * tools/compiler.c: Add --includedir option.
2040 * giscanner/ast.py: Map size/ssize to types
2043 2008-08-28 Tor Lillqvist <tml@novell.com>
2045 Make check now runs successfully on Windows.
2047 * tools/compiler.c (write_out_typelib): Use binary mode for output
2050 * girepository/girnode.c: Don't print NULL strings.
2052 * tests/invoke/Makefile.am
2053 * tests/scanner/Makefile.am: Use -no-undefined on Windows to
2054 convince libtool to build shared libraries.
2056 * tests/invoke/invoke.c: Don't needlessly include <dlfcn.h>. Use
2057 g_assert() instead of printing out expected errors.
2059 2008-08-28 Tor Lillqvist <tml@novell.com>
2061 * girepository/gtypelib.h: Change type of bitfield fields from
2062 guint to the most suitable smaller type. This makes the struct
2063 sizes match the ones on Linux that the sanity check expects when
2064 using gcc -mms-bitfields on Windows.
2066 2008-08-28 Johan Dahlin <johan@gnome.org>
2071 * giscanner/Makefile.am:
2072 * tests/Makefile.am:
2073 * tests/scanner/Makefile.am:
2074 Make distcheck pass.
2076 2008-08-27 Johan Dahlin <johan@gnome.org>
2078 * giscanner/Makefile.am:
2079 Only send in -no-undefined on Win32 as it breaks on MacOS X.
2081 2008-08-27 Tor Lillqvist <tml@novell.com>
2083 Make g-ir-scanner work on Windows. Still problems with the typelib
2084 code. Changes okayed by jdahlin.
2086 * configure.ac: Check for Windows, set Automake conditional
2087 OS_WIN32. Change backslashes to forward slashes in pyexecdir to
2088 avoid shell quoting issues
2090 * girepository/Makefile.am: Use -no-undefined so that libtool
2091 agrees to build a shared library on Windows.
2093 * girepository/girparser.c (backtrace_stderr): No backtrace() on
2094 Windows. Empty implementation on Windows so far.
2096 * girepository/gtypelib.c (g_typelib_check_sanity): Give more
2097 informative error message for the assertion failures. Tell also
2098 what the expected size of the struct is. Check all sizes first and
2099 fail afterwards if at least one size was different from expected.
2101 * tools/Makefile.am: Reorder libraries into proper logical
2104 * tools/generate.c: Don't include <dlfcn.h>, not used.
2106 * giscanner/Makefile.am: On Windows, link with the Python library,
2107 and install the module DLL as _giscanner.pyd. Remove the
2108 unnecessary import library and libtool library that libtool has
2111 * giscanner/scannerlexer.l: Recognize the gcc __attribute__ syntax
2112 and just skip it. Recognize also two "l" suffixes for long long
2113 constants. Recognize also __inline__.
2115 * giscanner/grealpath.h (g_realpath): Implement on Windows, using
2116 GetFullPathName(). As such, GetFullPathName() does more than the
2117 UNIX realpath(). It also changes relative paths into absolute
2118 paths. But for our purposes that shouldn't matter.
2120 * giscanner/giscannermodule.c (pygi_source_scanner_parse_file): On
2121 Windows the file descriptor passed to us is from Python. Python
2122 Python2.5 uses the msvcr71.dll C library, while mingw-built code
2123 uses msvcrt.dll. On Windows, file descriptors are specific to
2124 which C library is used. So we must find out what underlying OS
2125 handle corresponds to the file descriptor Python passes us, and
2126 then make that into a file descriptor valid for the C library this
2129 * giscanner/sourcescanner.py (_parse): Don't need to bypass
2130 __attribute__ as the lexer now handles it. The definition as empty
2131 was ineffective for mingw anyway, as mingw's _mingw.h undefines
2132 __attribute__. Close the temp file before unlinking it.
2134 * giscanner/cgobject.py: Use correct library name for the gobject
2137 * gir/Makefile.am: Must pass the full basename of the DLLs on
2138 Windows to g-ir-scanner. It's a bit ugly that we have to "know"
2139 that the names of the GLib DLLs are like libglib-2.0-0.dll, but in
2140 reality they won't change, until there is a GLib 3, and then also
2141 the Unix code here needs changing.
2143 Must pass CPPFLAGS to g-ir-scanner when building GLib.gir so that
2146 2008-08-26 Colin Walters <walters@verbum.org>
2148 * girepository/girepository.c: Search
2149 $DATADIR/girepository instead of
2150 $DATADIR/gitypelibs; this naming makes
2151 it clearer that e.g. jgir can install
2153 * gir/Makefile.am: Install there.
2155 2008-08-26 Colin Walters <walters@verbum.org>
2157 * girepository/gtypelib.c (_g_typelib_init): Also
2158 use G_MODULE_SUFFIX instead of hardcoding .so.
2160 2008-08-26 Colin Walters <walters@verbum.org>
2162 * girepository/gtypelib.c (_g_typelib_init): Free
2163 string in the right place.
2165 2008-08-26 Colin Walters <walters@verbum.org>
2167 * girepository/gtypelib.c (_g_typelib_init): Handle
2168 both .la and .so names; this works better in the
2169 uninstalled library case.
2171 2008-08-26 Johan Dahlin <johan@gnome.org>
2174 * giscanner/Makefile.am:
2175 * giscanner/cgobject.py:
2176 * giscanner/config.py.in:
2177 * giscanner/sourcescanner.py:
2178 Avoid undeffing __GNUC__, instead define
2179 __attribute__ & friends. Remove glibconfig.h hack.
2180 This makes gobject-introspection work better on
2181 MacOS X, Thanks to Richard Hult for kind help.
2183 2008-08-25 Colin Walters <walters@verbum.org>
2185 * giscanner/glibtransformer.py: Always print
2188 2008-08-25 Colin Walters <walters@verbum.org>
2190 * giscanner/glibtransformer.py: Skip over
2191 interfaces we don't know.
2193 2008-08-25 Colin Walters <walters@verbum.org>
2195 * girepository/girparser.c: Parse new implements
2196 syntax, drop gapi one.
2197 * tests/object.gir: Update.
2198 * tools/generate.c: Generate new syntax.
2200 2008-08-25 Colin Walters <walters@verbum.org>
2202 * giscanner/ast.py: Add interfaces property
2204 * giscanner/girwriter.py: Write out implemented
2206 * giscanner/glibtransformer.py: Introspect
2207 implemented interfaces.
2208 * tests/scanner/*: Make FooObject implement
2211 2008-08-25 Colin Walters <walters@verbum.org>
2213 * giscanner/glibtransformer.py: More correctly pair
2214 methods; if we have a symbol that starts with
2215 e.g. hippo_canvas look for a matching HippoCanvas
2216 class before accepting e.g. HippoCanvasImage.
2218 2008-08-24 Colin Walters <walters@verbum.org>
2220 * tools/g-ir-scanner: Filter out unknown options from
2223 2008-08-24 Colin Walters <walters@verbum.org>
2225 * giscanner/glibtransformer.py: Fail with better
2226 error if we can't find library.
2228 2008-08-24 Colin Walters <walters@verbum.org>
2230 * tools/g-ir-scanner: Use subprocess instead of
2231 commands, works on Windows and avoids the evil
2234 2008-08-24 Colin Walters <walters@verbum.org>
2236 * giscanner/glibtransformer.py: Skip over
2237 g_object_get_type from GLib trunk.
2239 2008-08-24 Colin Walters <walters@verbum.org>
2241 * girepository/girepository.c (g_irepository_require):
2242 Don't open shared library here; we already do it
2245 2008-08-24 Colin Walters <walters@verbum.org>
2247 * girepository/gtypelib.c: Add context stack so
2248 when we get an error we can print out nicely
2251 2008-08-24 Johan Dahlin <johan@gnome.org>
2253 * girepository/girparser.c (start_glib_boxed), (start_function),
2254 (start_field), (start_alias):
2255 Refactor a couple of parsing functions to be simpler to follow.
2258 2008-08-24 Johan Dahlin <johan@gnome.org>
2260 * girepository/girparser.c (start_function):
2261 Remove left-over code, checking type of function.
2263 2008-08-23 Colin Walters <walters@verbum.org>
2265 * giscanner/config.py: Define DATADIR.
2266 * giscanner/transformer.py: Look in DATADIR.
2268 2008-08-23 Colin Walters <walters@verbum.org>
2270 * girepository/gtypelib.c: Check constructor
2272 * girepository/girnode.c: Small tweaks.
2273 * girepository/ginfo.c: Calculate signature offsets
2275 * girepository/girparser.c: Remove duplicate
2277 * giscanner/glibtransformer.py: Avoid marking
2278 functions which return a basic type as
2281 2008-08-23 Colin Walters <walters@verbum.org>
2283 * girepository/girparser.c: Ignore <include>.
2284 * giscanner/girparser.py: Parse them.
2285 * giscanner/girwriter.py: Generate them.
2286 * giscanner/transformer.py: Process <include>
2287 recursively. Don't require full path for
2288 includes, look in {$XDG_DATA_DIRS}/gir.
2289 * tools/g-ir-scanner: Pass through includes.
2290 * Makefile.am: Remove extra --include
2292 * *-expected.gir: Add expected includes.
2294 2008-08-23 Johan Dahlin <johan@gnome.org>
2296 * tests/scanner/Makefile.am:
2297 * tests/scanner/annotation-expected.gir:
2298 * tests/scanner/drawable-expected.gir:
2299 Avoid duplication in the Makefile, regenerate with new
2300 namespaces (same as the filename)
2302 2008-08-22 Colin Walters <walters@verbum.org>
2304 * girepository/girnode.c: Don't hardcode integers,
2307 2008-08-22 Johan Dahlin <johan@gnome.org>
2309 * giscanner/sourcescanner.py:
2310 Check for ../gobject-introspection-1.0.pc.in to determine
2311 if we run installed or uninstalled.
2313 2008-08-22 Johan Dahlin <johan@gnome.org>
2316 * giscanner/sourcescanner.py:
2317 Send in undefs/defines via writing it directly to stdin
2318 of cpp instead of via arguments.
2320 2008-08-22 Colin Walters <walters@verbum.org>
2322 * tools/generate.c, tools/compiler.c: Default
2324 * all Makefile.am: Update.
2326 2008-08-22 Colin Walters <walters@verbum.org>
2328 * girepository/girparser.c: Pass through
2329 recursive types. Avoid overwriting errors.
2330 * giscanner/xmlwriter.py: Always write the
2332 * tests/*.gir: Adjust.
2333 * tests/scanner/Makefile.am: Build typelibs,
2334 and generate XML from those. Once we
2335 have a good diff mechanism...
2336 * tests/scanner/*-expected.gir: Add XML
2338 * tools/g-ir-scanner: Accept --typelib-xml
2340 * tools/generate.c: Better defaults for transfer.
2342 2008-08-22 Johan Dahlin <johan@gnome.org>
2346 * giscanner/Makefile.am:
2347 * giscanner/config.py.in:
2348 * giscanner/sourcescanner.py:
2349 Use the generated glibconfig.h for all scanner invokations.
2350 Rename it to glibconfig-scanner.h and install it.
2351 Add a config.py which so far contains the include dir.
2353 2008-08-22 Johan Dahlin <johan@gnome.org>
2356 Replace glibconfig.h with our own, do some replacement
2357 for CPP/C features we do not support
2359 2008-08-22 Colin Walters <walters@verbum.org>
2361 * tools/generate.c (write_callable_info): Fix unref
2364 2008-08-22 Colin Walters <walters@verbum.org>
2366 * gobject-introspection-1.0.pc.in: Add g-ir-generate.
2367 * tests/Makefile.am: Support $(DEBUG)
2368 * tools/generate.c: Do immediate close tags if no
2371 2008-08-21 Colin Walters <walters@verbum.org>
2373 * tests/scanner/drawable-expected.gir,
2374 * tests/scanner/drawable.c,
2375 * tests/scanner/drawable.h:
2378 2008-08-21 Colin Walters <walters@verbum.org>
2380 * giscanner/glibtransformer.py: Compute prefix
2381 by searching through the symbol for bits
2382 rather than going directly from ctype; this fixes
2385 2008-08-21 Colin Walters <walters@verbum.org>
2387 * giscanner/glibtransformer.py: Also try squashing
2388 underscores from namespace, fixes webkit_web_view_new.
2390 2008-08-21 Colin Walters <walters@verbum.org>
2392 * giscanner/glibtransformer.py: More ctor work,
2393 avoid having gtk_window_group_new end up under
2396 2008-08-21 Colin Walters <walters@verbum.org>
2398 * giscanner/glibtransformer.py: Much simpler approach
2399 of mapping uscored names to classes.
2400 * giscanner/utils.py: Remove unnecessary function.
2402 2008-08-21 Johan Dahlin <johan@gnome.org>
2404 * girepository/girepository.c (g_irepository_require):
2405 Plug memory leak and avoid using freed memory.
2406 Resolve the whole module path, here as well.
2408 2008-08-21 Colin Walters <walters@verbum.org>
2410 * giscanner/glibtransformer.py: Look up all permutations
2411 of class names when scanning methods/ctors based on
2412 the prefix instead of using the return value. This
2413 associates gtk_window_new with the right class.
2415 2008-08-21 Colin Walters <walters@verbum.org>
2417 * girepository/girmodule.c (g_ir_module_build_typelib):
2418 Revert change to increment header_size; we do that in
2421 2008-08-21 Colin Walters <walters@verbum.org>
2423 * girepository/girnode.c (write_string): Tweak to
2424 use UINT instead of INT. Not likely to matter.
2425 * girepository/girmodule.c (g_ir_module_build_typelib):
2426 Add to header_offset as well for header strings
2427 to match what write_string does.
2428 * girepository/gtypelib.c: Replace is_name with
2429 validate_name, which more strongly validates and
2430 handles errors in a better way. Update all callers.
2431 * giscanner/glibtransformer.py: Handle constructors
2434 2008-08-21 Johan Dahlin <johan@gnome.org>
2436 * gir/Makefile.am (typelibs_DATA): Build and
2437 install the Gio.typelib too
2439 * girepository/gtypelib.c (_g_typelib_init):
2440 Use g_module_build_path to resolve the shlib name
2442 2008-08-21 Colin Walters <walters@verbum.org>
2444 * gir/Makefile.am: CLEANFILES typelibs too.
2446 2008-08-21 Johan Dahlin <johan@gnome.org>
2448 * giscanner/glibtransformer.py:
2449 Do not send .la files through find_library.
2451 2008-08-21 Colin Walters <walters@verbum.org>
2453 * girepository/girparser.c (g_irepository_require):
2454 Fix one small leak in error case.
2456 2008-08-21 Johan Dahlin <johan@gnome.org>
2459 Parse glibconfig.h as well and install the compiled
2462 2008-08-21 Johan Dahlin <johan@gnome.org>
2465 * giscanner/glibtransformer.py:
2466 * tools/g-ir-scanner:
2467 Do not hard-core library names in the Makefile, reuse
2468 ctypes find_library instead.
2470 2008-08-21 Johan Dahlin <johan@gnome.org>
2472 * girepository/girparser.c (resolve_aliases):
2473 Remove compilation warnings
2475 2008-08-21 Johan Dahlin <johan@gnome.org>
2477 * girepository/girepository.c (g_irepository_require):
2478 Rewrap and fix double free bug by leaking a bit.
2480 2008-08-20 Colin Walters <walters@verbum.org>
2482 * girepository/girepository.c: Add new function
2483 g_irepository_get_typelib_path which tells
2484 us from where we loaded a namespace.
2486 2008-08-20 Colin Walters <walters@verbum.org>
2488 * tests/scanner/*-expected.gir: Adjust for
2489 added shared-library.
2490 * giscanner/giwriter.py: Make pylint happy.
2492 2008-08-20 Colin Walters <walters@verbum.org>
2494 * girepository/girmodule.c (g_ir_module_build_typelib):
2495 Calculate size correctly, avoid use-after-free.
2497 2008-08-20 Colin Walters <walters@verbum.org>
2499 * girepository/girepository.c: Remove
2500 g_irepository_register_file in favor of
2501 g_irepository_require. There are two
2502 possible deployment scenarios for typelibs:
2503 First, separate in $DATADIR/gitypelibs/. Second,
2504 they may be embedded in shlibs. However since
2505 the first is now the normal case, the API is
2506 optimized around it.
2508 Refactor internals to look up typelibs for
2509 namespaces just-in-time, but we expect
2510 consumers to call g_irepository_require.
2512 Also, add some docs. No one has died from that
2514 * gir/Makefile.am: Need --library for glib.
2515 * giscanner/girwriter.py: Write out shared-library.
2516 * tools/g-ir-writer: Take the first --library
2517 argument as the target of shared-library. In
2518 the future we should make this nicer with pkg-config
2521 2008-08-20 Colin Walters <walters@verbum.org>
2523 * girepository/girparser.py: And parse them.
2525 2008-08-20 Johan Dahlin <johan@gnome.org>
2527 * giscanner/glibast.py: Add gshort/gushort types
2529 2008-08-20 Colin Walters <walters@verbum.org>
2531 * gir/Makefile.am: Rename .gir files using GI namespace.
2532 * girepository/girepository.c: Use XDG_DATA_DIRS for
2533 looking up typelibs. Also typelibs are now suffixed
2535 * tests/invoke/Makefile.am: Only use metadata.
2536 * girepository/Makefile.am: Remove unnecessary include.
2537 * tests/scanner/Makefile.am: Update using GI namespaces
2538 for scanner includes.
2540 2008-08-20 Colin Walters <walters@verbum.org>
2542 * girepository/transformer.py: Suppress aliases whose
2544 * girepository/ast.py: Define some more aliases.
2546 2008-08-20 Colin Walters <walters@verbum.org>
2548 * girepository/girparser.c: Avoid alias infloops.
2550 2008-08-20 Colin Walters <walters@verbum.org>
2552 * tests/scanner/foo-expected.gir: Fix expected list type.
2554 2008-08-20 Johan Dahlin <johan@gnome.org>
2556 * giscanner/glibtransformer.py (GLibTransformer._resolve_type_name):
2557 Add a workaround for #548689.
2558 We can now compile gtk!
2560 2008-08-20 Colin Walters <walters@verbum.org>
2562 * giscanner/glibtransformer.py: Try to look up
2563 aliases using the c:type too.
2565 2008-08-20 Colin Walters <walters@verbum.org>
2567 * girepository/girparser.c: Parse union fields.
2569 2008-08-20 Johan Dahlin <johan@gnome.org>
2571 * giscanner/ast.py: Make time_t an alias for long
2573 * gir/gio-2.0-good.gir:
2574 * gir/glib-2.0-good.gir:
2575 * gir/gobject-2.0-good.gir:
2577 * giscanner/glibtransformer.py:
2578 Do not delete Class structures, we need them in gdk/gtk.
2579 * tests/scanner/drawable-expected.gir:
2580 * tests/scanner/foo-expected.gir:
2581 * tests/scanner/utility-expected.gir:
2584 2008-08-20 Johan Dahlin <johan@gnome.org>
2586 * tests/scanner/Makefile.am:
2587 * tests/scanner/annotation-expected.gir:
2588 * tests/scanner/annotation.c (annotation_object_class_init),
2589 (annotation_object_init), (annotation_object_method),
2590 (annotation_object_in), (annotation_object_out),
2591 (annotation_object_inout), (annotation_object_inout2),
2592 (annotation_object_inout3), (annotation_object_calleeowns),
2593 (annotation_object_calleesowns), (annotation_object_get_strings),
2594 (annotation_object_with_voidp), (annotation_object_get_objects),
2595 (annotation_object_create_object), (annotation_object_allow_none):
2596 * tests/scanner/annotation.h:
2597 * tests/scanner/foo-expected.gir:
2598 * tests/scanner/foo.c:
2599 * tests/scanner/foo.h:
2600 Split out annotation tests out of foo
2602 2008-08-20 Johan Dahlin <johan@gnome.org>
2604 * tests/scanner/Foo-expected.gir:
2605 * tests/scanner/Makefile.am:
2606 * tests/scanner/foo-expected.gir:
2607 * tests/scanner/foo-object.h:
2608 * tests/scanner/foo.c:
2609 Foo->foo, foo-object.h -> foo.h
2611 2008-08-20 Johan Dahlin <johan@gnome.org>
2613 * tests/scanner/Foo-expected.gir:
2614 * tests/scanner/Makefile.am:
2615 * tests/scanner/drawable-expected.gir:
2616 * tests/scanner/drawable.c (test_drawable_class_init),
2617 (test_drawable_init):
2618 * tests/scanner/drawable.h:
2619 * tests/scanner/foo-object.h:
2620 * tests/scanner/foo.c (foo_boxed_method):
2621 Move the drawable parts out of Foo to its own test.
2623 2008-08-20 Johan Dahlin <johan@gnome.org>
2625 * tests/scanner/Foo-expected.gir:
2626 * tests/scanner/foo-object.h:
2627 * tests/scanner/foo.c (foo_drawable_class_init),
2628 (foo_drawable_init):
2629 Add a based on GdkDrawable which generates
2632 2008-08-19 Colin Walters <walters@verbum.org>
2634 * giscanner/transformer.py: Don't try
2635 to strip prefix before namespace.
2637 2008-08-19 Johan Dahlin <johan@gnome.org>
2639 * giscanner/transformer.py:
2640 * tests/scanner/Foo-expected.gir:
2641 * tests/scanner/foo-object.h:
2642 Add support for typedef void foo type of
2645 2008-08-19 Johan Dahlin <johan@gnome.org>
2648 * giscanner/girwriter.py:
2649 * giscanner/glibtransformer.py:
2650 * giscanner/transformer.py:
2651 * tests/scanner/Foo-expected.gir:
2652 Add basic support for union, base the code much
2653 on Struct. Add a testcase.
2655 2008-08-19 Johan Dahlin <johan@gnome.org>
2657 * tests/scanner/Foo-expected.gir:
2658 * tests/scanner/foo-object.h:
2659 Add a union testcase which the compiler currently
2662 2008-08-19 Johan Dahlin <johan@gnome.org>
2664 * gobject-introspection-1.0.pc.in:
2665 Add a g_ir_compiler variable
2667 2008-08-19 Colin Walters <walters@verbum.org>
2669 * giscanner/ast.py: Rework types to be more closely
2671 * giscanner/girparser.py: Parse more bits.
2672 * giscanner/girwriter.py: Write sequences in a new
2673 way that specifies container type.
2674 * giscanner/glibast.py: Adjust for ast.py changes,
2675 add 'ctype' property to GLibObject and GLibInterface
2676 so we can look things up by it later.
2677 * gicanner/transformer.py: Names is new class holding
2678 the various namespaces we manage. Do not confuse
2679 with Namespace which is toplevel XML node effectively.
2680 Rework all type resolution to go through
2681 _resolve_type_name_1.
2682 * giscanner/glibtransformer.py: Raise UnknownTypeError
2683 instead of ValueError for cleanliness. Add Unresolved
2684 class to mark types whose parent we haven't seen yet.
2685 Use new Names object from transformer.py.
2686 Correctly look up parent=.
2687 Fix type validation to handle sequences.
2688 * tests/scanner/Foo-expected.gir: Update for sequence
2689 work, int instead of int32.
2690 * tools/g-ir-scanner: Add --noclosure option
2691 * gir/Makefile.am: Use --noclosure by default for
2694 2008-08-18 Johan Dahlin <johan@gnome.org>
2696 * gir/gio-2.0-good.gir:
2697 * gir/glib-2.0-good.gir:
2698 * gir/gobject-2.0-good.gir:
2701 2008-08-18 Johan Dahlin <johan@gnome.org>
2704 * giscanner/girparser.py:
2705 * giscanner/girwriter.py:
2706 * giscanner/glibast.py:
2707 * giscanner/glibtransformer.py:
2708 * giscanner/transformer.py:
2709 * tests/scanner/Foo-expected.gir:
2710 * tests/scanner/foo-object.h:
2711 * tests/scanner/utility-expected.gir:
2712 * tests/scanner/utility.h:
2713 Redo type resolving and validation.
2714 Add a couple of new tests.
2715 Patch mostly written by Colin.
2717 2008-08-18 Johan Dahlin <johan@gnome.org>
2720 * giscanner/girparser.py:
2722 * giscanner/transformer.py:
2723 Improve enum parsing for enums without a GType.
2724 Make flags/enum references to other girs work
2725 * giscanner/utils.py:
2727 * tests/scanner/Makefile.am:
2728 * tests/scanner/foo-object.h:
2729 * tests/scanner/utility-expected.gir:
2730 * tests/scanner/utility.h:
2731 Add a new test for external enum references
2733 2008-08-18 Johan Dahlin <johan@gnome.org>
2735 * docs/global-module-registry.txt: Update
2737 * tests/array.gir: Update with new type proposal
2739 * girepository/girepository.c (g_type_tag_to_string):
2740 * girepository/girepository.h:
2741 * girepository/girnode.c (g_ir_node_get_full_size_internal),
2743 * girepository/girnode.h:
2744 Make enum serializing functions public. Clean up some whitespace.
2746 2008-08-17 Johan Dahlin <johan@gnome.org>
2748 * docs/global-module-registry.txt:
2749 Add a document for an on disk module registry format
2751 2008-08-17 Johan Dahlin <johan@gnome.org>
2754 * gir/gio-2.0-good.gir:
2757 2008-08-17 Johan Dahlin <johan@gnome.org>
2760 * gir/glib-2.0-good.gir:
2761 * gir/gobject-2.0-good.gir:
2762 * giscanner/cgobject.py:
2763 * giscanner/glibtransformer.py:
2764 Regenerate GObject & GType.
2765 Avoid warnings when generating gobject-2.0.gir.
2766 Introspect a little more, and skip *_get_type functions.
2768 2008-08-17 Colin Walters <walters@verbum.org>
2770 * gir/glib-2.0.gir, gir/gobject-2.0.gir:
2771 Rename to -good, always generate during build.
2772 * gir/Makefile.am: Ensure .gir files dep on
2773 all scanner sources.
2774 * Makefile.am: Switch build order to ensure
2775 the scanner is ready before we do gir/.
2776 * tools/g-ir-scanner: Look for .git too.
2778 2008-08-17 Johan Dahlin <johan@gnome.org>
2780 * girepository/gtypelib.c (validate_enum_blob):
2781 * giscanner/glibtransformer.py:
2782 * giscanner/transformer.py:
2783 Remove resolve_possible_typedefs, it was unused.
2784 Allow multiple enum values of the sample value in an enum,
2785 since it's actually pretty common.
2786 Register enums so they can be resolved too.
2788 2008-08-16 Johan Dahlin <johan@gnome.org>
2790 * giscanner/girparser.py:
2791 Parse enumeration/bitfield.
2793 2008-08-16 Johan Dahlin <johan@gnome.org>
2795 * giscanner/girparser.py:
2798 2008-08-16 Johan Dahlin <johan@gnome.org>
2800 * giscanner/glibtransformer.py:
2801 Resolve type names for alias targets
2802 * giscanner/transformer.py:
2803 Skip FILE* parameters fow now
2805 2008-08-16 Johan Dahlin <johan@gnome.org>
2808 * gir/gobject-2.0.gir:
2811 * tests/scanner/Makefile.am:
2814 2008-08-15 Colin Walters <walters@verbum.org>
2816 * giscanner/glibtransformer.py: Explicitly construct
2817 new list, since we're deleting as we iterate.
2818 Don't delete all structures which end in Class; just
2819 ones which have a paired GObject.
2820 Fix printing of type warning.
2821 * giscanner/transformer.py: Make strip_namespace_object
2822 be the identity function if it doesn't match the
2825 2008-08-15 Colin Walters <walters@verbum.org>
2827 * giscanner/cgobject.py: Define yet more argument
2828 prototypes; fix prototype for g_type_fundamental.
2830 2008-08-14 Johan Dahlin <johan@gnome.org>
2832 * tests/Makefile.am:
2833 * tests/constant.gir:
2834 * tests/gobject.gir:
2836 * tools/generate.c (write_struct_info):
2837 Fix generator for constant/gobject/struct
2839 2008-08-14 Johan Dahlin <johan@gnome.org>
2841 * tests/Makefile.am:
2843 * tools/generate.c (write_enum_info):
2844 Fix generation of enum/bitfields
2846 2008-08-14 Johan Dahlin <johan@gnome.org>
2848 * girepository/girparser.c (start_field), (start_constant),
2849 (start_type), (end_element_handler):
2850 Clear up constant parsing
2855 * tools/generate.c (write_callable_info), (write_function_info),
2856 (write_callback_info), (write_constant_info), (write_signal_info),
2857 (write_vfunc_info), (write_property_info), (write_object_info),
2858 (write_interface_info):
2859 Constants/Signals are handled now.
2861 2008-08-14 Johan Dahlin <johan@gnome.org>
2863 * girepository/girparser.c (start_type):
2864 Don't require c:type.
2865 * tests/Makefile.am:
2868 Update, remove parts we don't support yet
2869 * tests/roundtrips.sh:
2871 * tools/generate.c (write_type_info), (write_field_info),
2872 (write_callable_info), (write_struct_info):
2873 Make it emit proper gir.
2875 2008-08-14 Johan Dahlin <johan@gnome.org>
2877 * giscanner/transformer.py:
2878 New internal function for adding a new node.
2880 2008-08-14 Johan Dahlin <johan@gnome.org>
2883 Define an internal _H_ variable so we skip parsing both
2884 i18n headers, only one is needed.
2886 Add the glib-2.0.gir too.
2887 * giscanner/glibast.py:
2888 Add gconstpointer as an alias for ANY
2889 * giscanner/transformer.py:
2890 Do not lower case enumeration names per se.
2891 Skip functions which has parameters called 'va_list'
2893 2008-08-14 Colin Walters <walters@verbum.org>
2895 * giscanner/transformer.py: Comment data structures.
2896 Also squash pointers in resolve_type_name to correspond
2897 with what we do for params.
2898 * giscanner/glibtransformer.py: Print warnings in more
2899 situations. Rework checks for method/constructor to
2900 look up in our GType database instead of just checking
2901 for *. Avoid generating <record> for GObject which
2902 duplicate the <class>.
2903 * gir/Makefile.am: Generate glib-2.0.gir and gobject-2.0.gir
2906 2008-08-14 Johan Dahlin <johan@gnome.org>
2908 * giscanner/girwriter.py:
2909 * giscanner/glibast.py:
2910 * giscanner/glibtransformer.py:
2911 * giscanner/transformer.py:
2913 * tests/Makefile.am:
2914 Add pyflakes.py and run it in make check.
2915 Update the source code to fix the errors reported by
2918 2008-08-14 Johan Dahlin <johan@gnome.org>
2921 * giscanner/girparser.py:
2922 * giscanner/glibast.py:
2923 * giscanner/glibtransformer.py:
2924 Refactor the parser a bit.
2925 Add parent type to interfaces and update callsites.
2927 2008-08-14 Johan Dahlin <johan@gnome.org>
2929 * giscanner/glibtransformer.py:
2930 * giscanner/utils.py:
2931 Refactor a bit, avoid isinstance and add a method
2932 for each type we parse.
2934 2008-08-14 Johan Dahlin <johan@gnome.org>
2937 * giscanner/girparser.py:
2938 * giscanner/glibtransformer.py:
2939 * tests/Makefile.am:
2940 Run pep8.py in make check, fix old errors.
2942 2008-08-13 Colin Walters <walters@verbum.org>
2944 * giscanner/girparser.py: Parse records.
2946 2008-08-13 Colin Walters <walters@verbum.org>
2948 * gir/Makefile.am: Install again.
2949 * gir/gobject-2.0.gir: Add some more bits.
2951 2008-08-13 Colin Walters <walters@verbum.org>
2953 * gir/gobject-2.0.gir: Use correct namespace, add GType.
2954 * giscanner/girparser.py: Handle aliases.
2955 * giscanner/transformer.py: Record aliases. Make resolver
2956 functions public; we now call into these explicitly from
2957 glibtransformer. Handle resolving aliases.
2958 * giscanner/glibtransformer.py: Separate our internal namespace
2959 from included ones. Call up into transformer's resolver functions.
2961 2008-08-13 Johan Dahlin <johan@gnome.org>
2963 * girepository/girnode.c (g_ir_node_get_full_size_internal):
2964 * girepository/girparser.c (start_class):
2965 * giscanner/glibtransformer.py:
2966 Allow get_type to be None, set a get_type for GInitiallyUnowned too.
2968 2008-08-13 Johan Dahlin <johan@gnome.org>
2970 * giscanner/cgobject.py:
2971 Register GInitiallyUnowned
2972 * giscanner/girwriter.py:
2973 * giscanner/glibtransformer.py:
2974 Special case GObject/GInitially owned as they are a bit special to use.
2976 2008-08-13 Colin Walters <walters@verbum.org>
2978 * tests/scanner/Foo-expected.gir, tests/scanner/utility-expected.gir:
2979 Object is in GObject namespace.
2981 2008-08-13 Colin Walters <walters@verbum.org>
2983 * giscanner/girparser.py: Fix processing of functions
2986 2008-08-13 Colin Walters <walters@verbum.org>
2988 * giscanner/girparser.py: Parse more than just <class.
2989 * giscanner/glibtransformer.py: Put aliases in a separate
2990 data structure since their name is not canonicall.
2991 * giscanner/transformer.py: Handle resolving type names
2994 2008-08-13 Johan Dahlin <johan@gnome.org>
2996 * tools/g-ir-scanner:
2997 Allow multiple libraries
2998 * giscanner/glibtransformer.py:
2999 Rename load_library to add_library, traverse over all libraries
3000 when trying to resolve a function
3002 2008-08-12 Colin Walters <walters@verbum.org>
3004 * giscanner/transformer.py: Record typedefs as <alias> elements.
3005 Also attempt to look up types in external namespaces.
3006 * giscanner/girwriter.py: Write them.
3007 * giscanner/glibtransformer.py: Rework resolver using real instanceof
3008 checks. Resolve interface methods and properties.
3009 * tests/scanner/foo-object.h: Add a method with typedef.
3010 * tests/scanner/Foo-expected.gir: Update.
3011 * girepository/girnode.c: Debug tweaks.
3012 * girepository/girparser.c: Make a first pass through the XML where we
3013 record all the aliases. This lets us resolve them as we go through the
3015 * gir/Makefile.am: Don't install gobject-2.0.gir; we want that to come
3016 from gir-repository.
3018 2008-08-12 Colin Walters <walters@verbum.org>
3020 * giscanner/glibtransformer.py: Resolve typedefs (e.g. AtkAttributeSet -> GSList).
3021 Correctly do subclasseing in 2nd pass resolution. Handle callbacks in structure
3023 * giscanner/transformer.py: Record typedefs and expose public API for resolving
3025 * tests/scanner/Foo-expected.gir: Fix expected callback types.
3027 2008-08-12 Colin Walters <walters@verbum.org>
3029 * giscanner/glibtransformer.py: Also transform object properties.
3031 2008-08-12 Colin Walters <walters@verbum.org>
3033 * giscanner/glibtransformer.py: Also transform callbacks
3034 and structure field types.
3035 * tests/scanner/Fooe-expected.gir: Update to expect correct
3036 names for callbacks and structs.
3038 2008-08-12 Colin Walters <walters@verbum.org>
3040 * girepository/girparser.c: Handle 'any'.
3041 * tests/scanner/Foo-expected.gir, tests/scanner/foo-object.h:
3042 Add test for void *.
3044 2008-08-12 Colin Walters <walters@verbum.org>
3046 * giscanner/glibtransformer.py: We need to do type
3047 resolution in a second pass after we've seen all the
3048 enums, records, etc.
3050 2008-08-12 Colin Walters <walters@verbum.org>
3052 * tests/scanner/Foo-expected.gir, tests/scanner/foo-object.h:
3053 Add enum return value.
3054 * giscanner/glibtransformer.py: Transform function return types
3057 2008-08-12 Colin Walters <walters@verbum.org>
3059 * tests/scanner/Makefile.am: Dep .gir files on scanner
3060 sources too. Also remove @ so we see scanner invocations.
3062 2008-08-12 Colin Walters <walters@verbum.org>
3064 * girepository/girparser.c, girepository/gtypelib.c,
3065 girepository/gtypelib.h, girepository/girnode.c:
3066 Remove usage of (GAPI-oriented) TypeTag in favor of
3067 GITypeTag from girepository.h.
3069 2008-08-10 Colin Walters <walters@verbum.org>
3071 * tests/roundtrips.sh: Use the correct tests.
3073 2008-08-10 Colin Walters <walters@verbum.org>
3075 * giscanner/cgobject.py: Declare/wrap a few more functions.
3076 Fix parameter types for g_object_new and g_type_fundamental.
3078 2008-08-10 Colin Walters <walters@verbum.org>
3080 * giscanner/cgobject.py: Add new decorator @gwrap which forces
3081 us to declare types for both return value and parameters. The
3082 ctypes default of 'int' is bad because it hides 32/64 bit
3083 problems. Convert all existing functions to use it.
3085 2008-08-09 Johan Dahlin <johan@gnome.org>
3087 * giscanner/__init__.py:
3089 * giscanner/cgobject.py:
3090 * giscanner/gidlparser.py:
3091 * giscanner/gidlwriter.py:
3092 * giscanner/girparser.py:
3093 * giscanner/girwriter.py:
3094 * giscanner/glibast.py:
3095 * giscanner/glibtransformer.py:
3096 * giscanner/odict.py:
3097 * giscanner/sourcescanner.py:
3098 * giscanner/transformer.py:
3099 * giscanner/utils.py:
3100 * giscanner/xmlwriter.py:
3101 * tools/g-ir-scanner:
3105 2008-08-09 Johan Dahlin <johan@gnome.org>
3108 * relaxng/c-types.xml:
3109 * relaxng/g-types.xml:
3110 * relaxng/relaxng.rng:
3112 Remove outdated relaxng schemas.
3114 2008-08-09 Johan Dahlin <johan@gnome.org>
3117 Rename metadata to typelib in variable names,
3120 2008-08-09 Johan Dahlin <johan@gnome.org>
3124 Remove old C scanner, which got rewritten in python.
3126 2008-08-09 Johan Dahlin <johan@gnome.org>
3128 * girepository/Makefile.am:
3129 * tools/Makefile.am:
3130 * tools/girmodule.c:
3131 * tools/girmodule.h:
3134 * tools/girparser.c:
3135 * tools/girparser.h:
3136 * tools/girwriter.c:
3137 * tools/girwriter.h:
3138 Move shared *.[ch] files to girepository from tools
3140 2008-08-09 Johan Dahlin <johan@gnome.org>
3142 * tests/Makefile.am:
3145 * tests/constant.test:
3147 * tests/errors.test:
3148 * tests/function.test:
3149 * tests/gobject.test:
3150 * tests/interface.test:
3151 * tests/object.test:
3152 * tests/struct.test:
3157 Rename *.test to *.gir
3159 2008-08-09 Johan Dahlin <johan@gnome.org>
3162 * tests/Makefile.am:
3163 * tests/parser/Foo-expected.gir:
3164 * tests/parser/Makefile.am:
3165 * tests/parser/foo-object.h:
3166 * tests/parser/foo.c:
3167 * tests/parser/utility-expected.gir:
3168 * tests/parser/utility.c:
3169 * tests/parser/utility.h:
3170 * tests/scanner/Makefile.am:
3171 Rename tests/parser to test/scanner
3173 2008-08-08 Colin Walters <walters@verbum.org>
3175 * tests/roundtrips.sh: Use local .gir files again.
3177 2008-08-08 Colin Walters <walters@verbum.org>
3179 * tests/invoke/Makefile.am: .gir file depends on libtool
3182 2008-08-08 Colin Walters <walters@verbum.org>
3184 * tools/girnode.c: Pass through parent node so we can
3185 print the node whose child is NULL, if that occurs.
3187 2008-08-08 Johan Dahlin <johan@gnome.org>
3189 * tests/Makefile.am:
3190 Disable roundtrip tests which are not yet working
3191 * tests/invoke/testfns.gir:
3194 2008-08-08 Johan Dahlin <johan@gnome.org>
3196 * giscanner/girwriter.py:
3198 * giscanner/glibast.py:
3199 * giscanner/glibtransformer.py:
3200 Swap order of members, to keep it consistent with
3203 2008-08-08 Johan Dahlin <johan@gnome.org>
3205 * girepository/gtypelib.c (validate_header):
3206 * girepository/gtypelib.h:
3208 * giscanner/girwriter.py:
3209 * giscanner/sourcescanner.c (gi_source_symbol_ref),
3210 (gi_source_symbol_unref):
3213 * tests/constant.test:
3215 * tests/errors.test:
3216 * tests/function.test:
3217 * tests/gobject.test:
3218 * tests/interface.test:
3219 * tests/invoke/Makefile.am:
3220 * tests/invoke/testfns.xml:
3221 * tests/object.test:
3222 * tests/parser/Makefile.am:
3223 * tests/roundtrips.sh:
3224 * tests/struct.test:
3229 * tools/Makefile.am:
3230 * tools/compiler.c (main):
3231 * tools/generate.c (write_callable_info), (write_function_info),
3233 * tools/gidlmodule.c:
3234 * tools/gidlmodule.h:
3237 * tools/gidlparser.c:
3238 * tools/gidlparser.h:
3239 * tools/gidlwriter.c:
3240 * tools/gidlwriter.h:
3241 * tools/scanner.c (create_node_from_gtype),
3242 (create_node_from_ctype), (g_igenerator_process_properties),
3243 (g_igenerator_process_signals), (g_igenerator_create_object),
3244 (g_igenerator_create_interface), (g_igenerator_create_boxed),
3245 (g_igenerator_create_enum), (g_igenerator_create_flags),
3246 (g_igenerator_process_function_symbol),
3247 (g_igenerator_process_unregistered_struct_typedef),
3248 (g_igenerator_process_struct_typedef),
3249 (g_igenerator_process_union_typedef),
3250 (g_igenerator_process_enum_typedef),
3251 (g_igenerator_process_function_typedef),
3252 (g_igenerator_process_constant), (g_igenerator_process_symbols),
3253 (g_igenerator_add_module), (g_igenerator_add_include_idl):
3254 Merge in the gir-compiler branch.
3255 Thanks to Philip and Colin for their help.
3257 2008-07-26 Colin Walters <walters@verbum.org>
3259 * tools/Makefile.am (bin_PROGRAMS): Install g-idl-compiler
3260 and g-idl-generate to go along with how we're changing this
3261 module to be installed.
3262 * gobject-introspection-1.0.pc.in: Set up Cflags and Libs.
3264 2008-07-24 Colin Walters <walters@verbum.org>
3266 * girepository/girepository.c (g_irepository_register): Add
3267 environment variable G_IREPOSITORY_VERBOSE so we can print
3268 out what we're doing.
3269 * girepository/girepository.c (g_irepository_register_file):
3270 Add GError error message to g_debug call.
3272 2008-07-08 Jürg Billeter <j@bitron.ch>
3274 * giscanner/glibast.py:
3278 2008-06-21 Johan Dahlin <jdahlin@async.com.br>
3280 * giscanner/girparser.py (GIRParser._parse_api): Ignore a few
3283 2008-06-20 Johan Dahlin <jdahlin@async.com.br>
3286 * giscanner/girwriter.py:
3287 * giscanner/transformer.py:
3288 * tests/parser/Foo-expected.gir:
3289 * tests/parser/foo-object.h:
3290 * tests/parser/foo.c (foo_object_allow_none):
3291 Add support for gtk-doc annotations for allow-none.
3294 2008-06-19 Johan Dahlin <jdahlin@async.com.br>
3297 * giscanner/girwriter.py:
3298 * giscanner/glibast.py:
3299 * giscanner/glibtransformer.py:
3300 * giscanner/transformer.py:
3301 * tests/parser/Foo-expected.gir:
3302 Start using abstract type instead of the raw C types.
3303 Register a bunch of glib types we care about.
3305 2008-06-19 Rob Taylor <rob.taylor@codethink.co.uk>
3310 2008-06-08 Philip Van Hoof <pvanhoof@gnome.org>
3312 * girepository/girepository.c:
3313 * girepository/gtypelib.c:
3314 * girepository/ginfo.c:
3315 * girepository/ginvoke.c:
3316 * girepository/girepository.h:
3317 * girepository/gtypelib.h:
3318 * girepository/gmetadata.c:
3319 * girepository/Makefile.am:
3320 * girepository/gmetadata.h:
3322 * tools/gidlmodule.c:
3325 * tools/gidlmodule.h:
3326 * tools/gidlparser.c:
3328 Renamed GMetadata to GTypelib
3330 2008-06-07 Johan Dahlin <jdahlin@async.com.br>
3332 * giscanner/xmlwriter.py:
3333 Improve line wrapping when > 79 charaters
3335 2008-06-05 Jürg Billeter <j@bitron.ch>
3338 * giscanner/girwriter.py:
3339 * giscanner/transformer.py:
3340 Use <type> element for field types
3341 * tests/parser/Foo-expected.gir:
3344 2008-06-04 Johan Dahlin <jdahlin@async.com.br>
3346 * giscanner/glibtransformer.py:
3347 Fix a bug which prevented GdkEvent from being generated
3349 2008-06-03 Johan Dahlin <jdahlin@async.com.br>
3351 * giscanner/Makefile.am:
3353 * giscanner/girwriter.py:
3354 * giscanner/glibast.py:
3355 * giscanner/glibtransformer.py:
3356 * giscanner/transformer.py:
3357 * giscanner/utils.py:
3358 * tests/parser/Foo-expected.gir:
3359 Improve enum member parsing and introspection
3361 2008-05-31 Johan Dahlin <jdahlin@async.com.br>
3363 * giscanner/scannerparser.y:
3364 * giscanner/sourcescanner.h:
3365 * giscanner/sourcescanner.py:
3366 Add a new source type enum for member.
3367 Use __repr__ for improved debugging
3368 * giscanner/girparser.py:
3370 * giscanner/transformer.py:
3371 Improve parsing of struct members.
3372 * tests/parser/foo-object.h:
3375 2008-05-31 Johan Dahlin <jdahlin@async.com.br>
3377 * giscanner/xmlwriter.py:
3378 Improve error reporting when trying to quote None.
3379 * giscanner/girparser.py:
3380 Do not print warnings when including more complete .gir files
3381 * giscanner/girwriter.py:
3382 Do not require a name for parameters, add a todo for singletons
3383 * giscanner/glibtransformer.py:
3384 Refactor the way structs are done, add a couple of hacks to allow
3386 * giscanner/transformer.py:
3387 Add enough hacks so cairo, atk and pango.gir can be parsed properly
3388 * gobject-introspection-1.0.pc.in:
3389 Export girdir, so we can access gobject-2.0.gir from outside
3391 2008-05-31 Johan Dahlin <jdahlin@async.com.br>
3393 * tools/g-ir-scanner:
3394 * tests/parser/Makefile.am:
3395 Update sys.path before running the parser so we don't have
3396 to setup PYTHONPATH ourselves.
3400 * girepository/Makefile.am:
3401 * giscanner/transformer.py:
3402 * gobject-introspection-1.0.pc.in:
3403 * gobject-introspection.pc.in:
3404 * tools/Makefile.am:
3406 Rename pkg-config name to gobject-introspection-1.0,
3407 Do not installed anything which is not using the gir format.
3408 Disable compililation the old C scanner, but still keep the source
3409 until all the remaning functionallity has been ported.
3411 2008-05-31 Johan Dahlin <jdahlin@async.com.br>
3413 * giscanner/giscannermodule.c (symbol_get_ident): Prevent
3414 a crash when symbol->indent is NULL.
3416 * giscanner/sourcescanner.py (ctype_name): Add ctype_name,
3417 a function to convert a CTYPE symbol to a string
3419 2008-05-24 Johan Dahlin <jdahlin@async.com.br>
3422 * giscanner/girwriter.py:
3423 * giscanner/giscannermodule.c
3424 (pygi_source_scanner_append_filename),
3425 (pygi_source_scanner_parse_file):
3426 * giscanner/glibtransformer.py:
3427 * giscanner/sourcescanner.py:
3428 Revert back to using temporary files to send in headers.
3429 Allow Functions to be passed in as callbacks, add a couple
3430 of try/excepts missing features.
3431 We can now scan pango
3433 2008-05-08 Johan Dahlin <johan@gnome.org>
3435 * giscanner/glibtransformer.py:
3436 * giscanner/transformer.py:
3437 Move namespace stripping glibtransformer->transformer
3439 2008-05-08 Johan Dahlin <johan@gnome.org>
3442 * giscanner/girwriter.py:
3443 * giscanner/glibtransformer.py:
3444 * giscanner/transformer.py:
3445 * tools/g-ir-scanner:
3446 Introduce a namespace ast node
3448 2008-05-05 Johan Dahlin <johan@gnome.org>
3450 * giscanner/__init__.py:
3451 * giscanner/sourcescanner.py:
3452 * giscanner/transformer.py:
3453 Move sourcescanner symbols to the sourcescanner module, instead
3454 of in the global __init__ namespace.
3456 2008-05-03 Johan Dahlin <johan@gnome.org>
3458 * giscanner/glibtransformer.py:
3459 * tools/g-ir-scanner:
3460 Handle missing parameters better, allow - and + in .la dlname
3463 2008-05-03 Johan Dahlin <johan@gnome.org>
3465 * giscanner/__init__.py:
3467 * giscanner/girwriter.py:
3468 * giscanner/glibtransformer.py:
3469 * giscanner/transformer.py:
3470 Parse struct fields properly, improve debugging.
3472 2008-04-29 Johan Dahlin <johan@gnome.org>
3475 * giscanner/girwriter.py:
3476 * giscanner/transformer.py:
3477 * tests/parser/Foo-expected.gir:
3479 Use transfer-ownership everywhere, to mark ownership/calle/caller etc.
3481 2008-04-29 Johan Dahlin <jdahlin@async.com.br>
3484 * docs/g-ir-scanner.1:
3485 * metadata-annotations-proposal.txt:
3486 * metadata-format.txt:
3487 Add a basic, unfinshed man page for g-ir-scanner, move documents into .txt
3489 2008-04-29 Johan Dahlin <jdahlin@async.com.br>
3491 * giscanner/girwriter.py:
3492 * giscanner/glibtransformer.py:
3493 * giscanner/transformer.py:
3494 * giscanner/xmlwriter.py:
3495 * tests/parser/Foo-expected.gir:
3496 * tests/parser/foo-object.h:
3497 Write record/structs to gir file too. Add a couple of tests,
3498 fix an off by one error in xmlwriter.py.
3500 2008-04-28 Johan Dahlin <johan@gnome.org>
3502 * giscanner/xmlwriter.py: Calculate the line length properly,
3503 include the provided extra indentation in the calculation, really.
3505 2008-04-28 Johan Dahlin <jdahlin@async.com.br>
3508 * giscanner/glibast.py:
3509 * giscanner/glibtransformer.py:
3510 * giscanner/transformer.py:
3511 * tools/g-ir-scanner:
3512 Add a --strip-prefix and sort out confusion between names and symbols
3513 for functions and struct + derivaties.
3514 Refactor bootstrap of g-ir-scanner, so we can set options on
3515 Transformer() before parsing everything.
3517 2008-04-28 Johan Dahlin <johan@gnome.org>
3519 * giscanner/transformer.py (Transformer._traverse_one): Avoid recursion
3520 when scanning girepository.h
3522 * giscanner/sourcescanner.py (SourceScanner._preprocess): Define
3523 a __GI_SCANNER__ when we run.
3525 2008-04-28 Johan Dahlin <jdahlin@async.com.br>
3528 * giscanner/girwriter.py:
3529 * giscanner/glibast.py:
3530 * giscanner/glibtransformer.py:
3531 * tests/parser/Foo-expected.gir:
3532 * tests/parser/utility-expected.gir:
3533 Rename most c:identifier to c:type. Add new ones to
3534 class/interface/enum/boxed.
3536 2008-04-28 Johan Dahlin <jdahlin@async.com.br>
3539 * giscanner/girwriter.py:
3540 * giscanner/glibtransformer.py:
3541 * tests/parser/Foo-expected.gidl:
3542 * tests/parser/Makefile.am:
3543 Move c:identifier from return-value to subchild type,
3544 as per Jürgs suggestion
3546 2008-04-28 Johan Dahlin <johan@gnome.org>
3548 * giscanner/girwriter.py:
3549 * tests/parser/Foo-expected.gir:
3550 Write property.type as a child node.
3552 2008-04-27 Johan Dahlin <johan@gnome.org>
3557 * gidl/gobject-2.0.gidl:
3559 * gir/gobject-2.0.gir:
3560 * tests/parser/Makefile.am:
3561 Replace the GObject gidl with a GObject gir.
3563 2008-04-27 Johan Dahlin <johan@gnome.org>
3565 * tools/Makefile.am (bin_SCRIPTS): g-ir-scanner is a script,
3568 * giscanner/xmlwriter.py:
3569 * tests/parser/Foo-expected.gir:
3570 Include indentation in line length calculation
3572 2008-04-27 Johan Dahlin <johan@gnome.org>
3574 * giscanner/girparser.py:
3575 Prettify NS parsing using elementtree.
3577 2008-04-27 Johan Dahlin <johan@gnome.org>
3580 * giscanner/Makefile.am:
3581 * giscanner/girparser.py:
3582 * giscanner/glibtransformer.py:
3583 * tests/parser/Foo-expected.gidl:
3584 * tests/parser/Foo-expected.gir:
3585 * tests/parser/Makefile.am:
3586 * tests/parser/utility-expected.gidl:
3587 * tests/parser/utility-expected.gir:
3588 * tools/g-ir-scanner:
3589 Switch over to GIR as the default format. Add a simple GIDL
3591 Update tests and fix simplify makefiles by depending
3592 on GNU make extensions.
3594 2008-04-27 Johan Dahlin <johan@gnome.org>
3596 * giscanner/xmlwriter.py:
3597 Wrap attributes for lines which are wider than 79 characters
3599 * giscanner/scannerlexer.l:
3600 Allow parenthesis in annotations
3603 * giscanner/gidlwriter.py:
3604 * giscanner/girwriter.py:
3605 * giscanner/glibtransformer.py:
3606 * giscanner/transformer.py:
3607 Add initial sequence support, including annotation.
3608 Refactor type handling a bit.
3610 2008-04-27 Johan Dahlin <johan@gnome.org>
3612 * tests/parser/Foo-expected.gidl:
3613 * tests/parser/foo-object.h:
3614 * tests/parser/foo.c (foo_object_class_init),
3615 (foo_object_get_strings), (foo_object_get_objects):
3616 Add two new functions to check sequence return values.
3617 Also fixes a compilation warning.
3619 2008-04-27 Johan Dahlin <johan@gnome.org>
3621 * giscanner/giscannermodule.c (]): Cast the getter, avoids
3622 a compilation warning.
3624 * tools/Makefile.am (g_ir_scanner_SOURCES):
3625 g-ir-scanner has no sources.
3627 2008-04-25 Johan Dahlin <johan@gnome.org>
3629 * giscanner/Makefile.am:
3631 * giscanner/gidlparser.py:
3632 * giscanner/gidlwriter.py:
3633 * giscanner/girwriter.py:
3634 * giscanner/glibast.py:
3635 * giscanner/glibtransformer.py:
3636 * giscanner/transformer.py:
3637 Split out nodes to ast.py and glibast.py
3639 2008-04-25 Johan Dahlin <jdahlin@async.com.br>
3641 * giscanner/Makefile.am:
3642 * giscanner/gidlparser.py:
3643 * giscanner/gidlwriter.py:
3644 * giscanner/girwriter.py:
3645 * giscanner/glibtransformer.py:
3646 * giscanner/gobjecttreebuilder.py:
3647 * giscanner/transformer.py:
3648 * giscanner/treebuilder.py:
3649 * tools/g-ir-scanner:
3650 Rename treebuilder to transformer and
3651 gobjectreebuilder to glibtransformer.
3653 2008-04-25 Johan Dahlin <jdahlin@async.com.br>
3655 * giscanner/Makefile.am:
3656 * giscanner/__init__.py:
3657 * giscanner/cgobject.py:
3658 * giscanner/gidlparser.py:
3659 * giscanner/gidlwriter.py:
3660 * giscanner/girwriter.py:
3661 * giscanner/gobjecttreebuilder.py:
3662 * giscanner/odict.py:
3663 * giscanner/sourcescanner.py:
3664 * giscanner/treebuilder.py:
3665 * giscanner/xmlwriter.py:
3666 * tools/Makefile.am:
3667 * tools/g-ir-scanner:
3668 Add LGPLv2 license header and install all python files
3670 2008-04-25 Johan Dahlin <jdahlin@async.com.br>
3673 * giscanner/gidlwriter.py:
3674 * giscanner/giscannermodule.c (pygi_source_directive_new),
3675 (directive_get_options), (pygi_source_symbol_new),
3676 (symbol_get_base_type), (pygi_source_type_new),
3677 (type_get_base_type), (type_get_child_list),
3678 (pygi_source_scanner_get_symbols),
3679 (pygi_source_scanner_get_directives):
3680 * giscanner/gobjecttreebuilder.py:
3681 * giscanner/sourcescanner.py:
3682 * giscanner/treebuilder.py:
3683 * tests/parser/foo-object.h:
3684 Add support for virtual methods.
3685 Pair struct FooClass with struct Foo.
3686 Clean up the SourceScanner bindings a bit.
3687 Add a testcase for virtual methods.
3689 2008-04-25 Johan Dahlin <jdahlin@async.com.br>
3691 * giscanner/cgobject.py:
3692 * giscanner/gidlwriter.py:
3693 * giscanner/gobjecttreebuilder.py:
3694 Add support for signals
3696 * tests/parser/foo.c (foo_object_class_init):
3697 * Foo-expected.gidl:
3698 Add a signal and update the expected output.
3700 2008-04-24 Johan Dahlin <jdahlin@async.com.br>
3702 * giscanner/gidlwriter.py:
3703 * giscanner/girwriter.py:
3704 * giscanner/giscannermodule.c (directive_get_name),
3705 (directive_get_value), (directive_get_options),
3706 (symbol_get_directives), (symbol_set_directives),
3707 (pygi_source_scanner_parse_file),
3708 (pygi_source_scanner_lex_filename),
3709 (pygi_source_scanner_get_directives), (init_giscanner):
3710 * giscanner/sourcescanner.c (gi_source_scanner_get_directives):
3711 * giscanner/sourcescanner.h:
3712 * giscanner/sourcescanner.py:
3713 * giscanner/treebuilder.py:
3714 * tools/g-ir-scanner:
3715 Add support for source/header annotations.
3717 2008-04-22 Johan Dahlin <jdahlin@async.com.br>
3719 * giscanner/gidlwriter.py:
3720 * giscanner/girwriter.py:
3721 * giscanner/gobjecttreebuilder.py:
3722 * giscanner/treebuilder.py:
3723 Add support for Callbacks
3725 2008-04-22 Havoc Pennington <hp@pobox.com>
3727 * girepository/ginvoke.c (g_function_info_invoke): If a symbol is
3728 not in metadata->module, look for it in the global module, in case
3729 some other object or the app itself provides the symbol.
3731 2008-04-22 Havoc Pennington <hp@pobox.com>
3733 * girepository/gmetadata.c (_g_metadata_init): hack to avoid
3734 dlopening a library that is already in the main app, by checking
3735 whether one of the lib's symbols is already loaded.
3737 2008-04-22 Johan Dahlin <jdahlin@async.com.br>
3739 * tests/parser/Foo-expected.gidl:
3740 * tests/parser/foo-object.h:
3743 2008-04-22 Havoc Pennington <hp@pobox.com>
3745 * girepository/ginfo.c (g_interface_info_find_method):
3746 Use interface_blob_size not object_blob_size to compute offset.
3748 2008-04-22 Havoc Pennington <hp@pobox.com>
3750 * girepository/gmetadata.c (_g_metadata_init): remove
3751 G_MODULE_BIND_LOCAL flag when loading libraries, since some libs
3752 (Glade and Clutter for example) rely on being loaded globally.
3754 2008-04-22 Havoc Pennington <hp@pobox.com>
3756 * girepository/ginfo.c (g_registered_type_info_get_g_type): new
3757 function to get the GType given a RegisteredTypeInfo
3759 2008-04-22 Johan Dahlin <johan@gnome.org>
3761 * COPYING: Add a LGPL license, to prevent automake to
3762 put in a copy of GPL here. Pointed out by Havoc.
3764 * girepository/ginfo.c (g_info_from_entry), (g_type_info_new),
3765 (g_type_info_is_pointer), (g_type_info_get_tag),
3766 (g_type_info_get_param_type), (g_type_info_get_interface),
3767 (g_type_info_get_array_length), (g_type_info_is_zero_terminated),
3768 (g_type_info_get_n_error_domains), (g_type_info_get_error_domain),
3769 (g_error_domain_info_get_codes), (g_enum_info_get_value),
3770 (g_object_info_get_interface), (g_object_info_get_field),
3771 (g_interface_info_get_prerequisite),
3772 (g_signal_info_get_class_closure), (g_constant_info_get_value):
3773 * girepository/ginvoke.c (get_ffi_type):
3774 * girepository/girepository.h:
3775 * girepository/gmetadata.c (g_metadata_get_dir_entry),
3776 (g_metadata_check_sanity), (validate_header),
3777 (validate_array_type_blob), (validate_iface_type_blob),
3778 (validate_param_type_blob), (validate_error_type_blob),
3779 (validate_type_blob), (validate_constant_blob),
3780 (validate_struct_blob), (validate_enum_blob):
3781 * girepository/gmetadata.h:
3782 * tests/Makefile.am:
3783 * tests/invoke/Makefile.am:
3784 * tests/invoke/invoke.c (main):
3785 * tests/roundtrips.sh:
3786 * tools/Makefile.am:
3787 * tools/compiler.c (format_output), (write_out_metadata), (main):
3788 * tools/generate.c (write_type_name), (write_type_info),
3789 (write_constant_value), (write_enum_info), (load_metadata), (main):
3790 * tools/gidlcompilercontext.c:
3791 * tools/gidlcompilercontext.h:
3792 * tools/gidlcompilerentrynode.c:
3793 * tools/gidlcompilerentrynode.h:
3794 * tools/gidlcompilertypenode.c:
3795 * tools/gidlcompilertypenode.h:
3796 * tools/gidlmodule.c (g_idl_module_build_metadata):
3797 * tools/gidlmodule.h:
3798 * tools/gidlnode.c (init_stats), (dump_stats),
3799 (g_idl_node_get_size), (g_idl_node_get_full_size),
3800 (g_idl_node_cmp), (g_idl_node_can_have_member),
3801 (g_idl_node_add_member), (g_idl_node_param_direction_string),
3802 (parse_int_value), (parse_uint_value), (parse_float_value),
3803 (parse_boolean_value), (find_entry_node), (find_entry),
3804 (serialize_type), (g_idl_node_build_metadata), (write_string):
3806 * tools/gidlparser.c (parse_type_internal):
3807 * tools/quote-file.sh:
3808 Revert revisions 157,149-148,136-129 and 120.
3809 Move back to using g-idl-generate to generate the metadata and
3810 avoids dependency on a c compiler.
3812 2008-04-22 Johan Dahlin <jdahlin@async.com.br>
3814 * giscanner/girwriter.py:
3815 * tools/g-ir-scanner:
3816 Add an initial GIR writer and a --format option to g-ir-scanner
3818 2008-04-21 Johan Dahlin <johan@gnome.org>
3820 * giscanner/cgobject.py: Use ctypes.util.find_library to locate
3821 gobject-2.0 and raise ImportError if not found.
3823 * giscanner/gidlparser.py:
3824 * giscanner/gidlwriter.py:
3825 * giscanner/gobjecttreebuilder.py:
3826 * tools/g-ir-scanner:
3827 Add a --include argument to include types from other idls.
3828 Add a minimalistic GIDL parser (just objects for now)
3829 Implement resolving of external type references and use it to
3830 resolve parent types, argument types and return types.
3832 2008-04-21 Johan Dahlin <johan@gnome.org>
3834 * giscanner/gidlwriter.py:
3835 * giscanner/gobjecttreebuilder.py:
3836 * giscanner/treebuilder.py:
3837 Add support for properties.
3838 Refactor Class/Interface support a bit, to share more code and
3839 always initialize their method attribute to an empty list.
3841 2008-04-21 Johan Dahlin <johan@gnome.org>
3843 * giscanner/cgobject.py:
3844 Add a workaround for a glib bug interface introspection bug
3845 (object_interface_list_properties, object_class_list_properties):
3846 Cast the return value to GParamSpec.
3848 * tests/parser/Foo-expected.gidl: Update
3849 * tests/parser/foo.c: Add a string property
3851 * giscanner/gobjecttreebuilder.py:
3852 After stripping namespaces, remove the original
3853 item to avoid duplication (GtkButton struct and Button object)
3855 2008-04-21 Johan Dahlin <johan@gnome.org>
3857 * giscanner/gobjecttreebuilder.py:
3858 * giscanner/treebuilder.py:
3859 Strip namespaces before objects, so we'll export
3860 GtkButton as Button in the gtk namespace
3862 2008-04-21 Johan Dahlin <johan@gnome.org>
3864 * giscanner/gidlwriter.py:
3865 * giscanner/gobjecttreebuilder.py:
3866 * giscanner/treebuilder.py:
3867 Add constructors for object/boxed types.
3869 2008-04-21 Johan Dahlin <johan@gnome.org>
3871 * giscanner/gidlwriter.py:
3872 * giscanner/gobjecttreebuilder.py:
3873 Add support for boxed types
3875 2008-04-21 Johan Dahlin <johan@gnome.org>
3877 * giscanner/giscannermodule.c: Mark structures as const,
3878 wrap SourceType.const_string.
3880 * tests/parser/foo-object.h: Add a couple of constants.
3882 * giscanner/gidlwriter.py:
3883 * giscanner/gobjecttreebuilder.py:
3884 * giscanner/treebuilder.py:
3885 Add basic support for interfaces
3887 * tools/g-ir-scanner:
3888 Add -o/--output for writing to a file
3890 2008-04-21 Havoc Pennington <hp@redhat.com>
3892 * TODO: add some C API wishlist items I could think of quickly
3894 2008-04-21 Johan Dahlin <jdahlin@async.com.br>
3896 * giscanner/gidlwriter.py:
3897 * giscanner/xmlwriter.py:
3898 Add a simple api for writing tags which can be used
3899 with the new 'with statement' in python 2.5
3901 2008-04-21 Johan Dahlin <johan@gnome.org>
3903 * giscanner/gobjecttreebuilder.py:
3904 Strip namespace and object prefix from method names.
3906 2008-04-21 Johan Dahlin <johan@gnome.org>
3908 * tools/g-ir-scanner (main): Add --pkg option to pass in
3909 pkg-config modules to get cflags from.
3911 * giscanner/gidlwriter.py (GIDLWriter._write_method):
3912 Avoid duplication, reuse function writer for methods.
3914 2008-04-21 Johan Dahlin <jdahlin@async.com.br>
3916 * giscanner/gidlwriter.py:
3917 * giscanner/gobjecttreebuilder.py:
3918 * giscanner/treebuilder.py:
3919 * tools/g-ir-scanner:
3920 Resolve libtool .la files.
3921 Strip name spaces for methods.
3922 Add function symbols
3924 2008-04-20 Johan Dahlin <jdahlin@async.com.br>
3926 * giscanner/cgobject.py:
3927 * giscanner/gidlwriter.py:
3928 * giscanner/gobjecttreebuilder.py:
3929 * giscanner/treebuilder.py:
3930 Add support for classes and methods
3932 2008-04-20 Johan Dahlin <johan@gnome.org>
3934 * giscanner/gidlwriter.py:
3935 * giscanner/gobjecttreebuilder.py:
3936 * giscanner/odict.py:
3937 Avoid conflicts, keep the output ordered similar to
3938 the order of the input.
3939 Add a simple ordered dictionary implemenation
3941 2008-04-19 Johan Dahlin <johan@gnome.org>
3943 * giscanner/cgobject.py:
3944 * giscanner/gidlwriter.py:
3945 * giscanner/gobjecttreebuilder.py:
3946 * tools/g-ir-scanner:
3947 Start introspecting get-type functions.
3948 Implement support for GLib/GFlags GTypes.
3949 Add a ctype based GObject binding.
3951 2008-04-18 Johan Dahlin <jdahlin@async.com.br>
3953 * giscanner/gidlwriter.py:
3954 * giscanner/xmlwriter.py:
3955 * tools/g-ir-scanner:
3956 Add a simplistic gidl writer, which can't do too much.
3958 2008-04-18 Johan Dahlin <johan@gnome.org>
3960 * giscanner/sourcescanner.py:
3961 * giscanner/treebuilder.py:
3962 * tools/g-ir-scanner:
3963 split tree building and source scanning interface to separate files.
3965 2008-04-18 Johan Dahlin <johan@gnome.org>
3967 * tools/g-ir-scanner (Parameter.__init__): Start constructing
3969 - Add support for struct/parameter/return, start parsing of ctypes
3971 * giscanner/giscannermodule.c: wrap GISourceType.child_list and
3974 2008-03-31 Johan Dahlin <johan@gnome.org>
3976 * tools/g-ir-scanner:
3977 Start to build abstract syntax node of scanned sources.
3978 Add support for cpp options.
3980 2008-03-27 Johan Dahlin <johan@gnome.org>
3982 * giscanner/giscannermodule.c:
3983 * giscanner/scannerlexer.l:
3984 * giscanner/sourcescanner.c:
3985 * tools/g-ir-scanner:
3987 Add simple pre-processor using subprocess and a PIPE.
3988 Change the parse_file apis to accept a file descriptor.
3990 2008-03-25 Johan Dahlin <johan@gnome.org>
3992 * giscanner/__init__.py:
3993 * tools/g-ir-scanner:
3994 Fix a typo and add an example python test program.
3996 2008-03-25 Johan Dahlin <johan@gnome.org>
3998 * giscanner/__init__.py:
3999 * giscanner/giscannermodule.c:
4000 * giscanner/sourcescanner.c:
4001 * giscanner/sourcescanner.h:
4002 Add constants and wrap a few more SymbolType fields
4004 2008-03-25 Johan Dahlin <johan@gnome.org>
4008 * giscanner/__init__.py:
4009 * giscanner/giscannermodule.c:
4010 * giscanner/Makefile.am:
4012 Add initial python bindings for the scanner and
4013 depend on python 2.5.
4015 2008-03-25 Johan Dahlin <johan@gnome.org>
4019 * giscanner/Makefile.am:
4020 * giscanner/sourcescanner.c:
4021 * giscanner/sourcescanner.h:
4022 * tools/Makefile.am:
4023 * tools/grealpath.h:
4024 * tools/sourcescanner.c:
4025 * tools/sourcescanner.h:
4027 Move the scanner to a separate library.
4029 2008-03-23 Johan Dahlin <johan@gnome.org>
4031 * tools/Makefile.am:
4034 * tools/scannerlexer.l:
4035 * tools/scannerparser.y:
4036 * tools/sourcescanner.c:
4037 * tools/sourcescanner.h:
4038 Split out the source scanner from the generator.
4039 Rename the symbols used in the scanner to use the gi_ prefix.
4040 This should make it possible to use the raw C parser from
4043 2008-03-23 Johan Dahlin <johan@gnome.org>
4045 * tests/parser/Makefile.am (utility.gidl):
4046 * tests/parser/utility-expected.gidl:
4047 Pass in the gobject.gidl since we're defining a GObject.
4049 2008-03-12 Johan Dahlin <johan@gnome.org>
4051 * relaxng/relaxng.rng:
4052 Add a releaxng in relaxng we can use to validate the relaxngs
4055 2008-03-12 Jürg Billeter <j@bitron.ch>
4057 * tools/scanner.c: (g_igenerator_new):
4058 * tools/scannerparser.y:
4059 Fix compiler warnings.
4061 2008-03-12 Jürg Billeter <j@bitron.ch>
4065 * tools/scannerparser.y:
4066 Start fixing memory management in g-idl-scanner.
4068 2008-03-12 Rob Taylor <rob.taylor@codethink.co.uk>
4070 * tools/gidlcompilercontext.c: (write_compiled):
4071 Fix critical warning when no shlib passed to g-idl-compiler.
4073 2008-03-12 Johan Dahlin <johan@gnome.org>
4075 * tests/parser/utility-expected.gidl:
4076 * tests/parser/utility.h:
4077 Add a get_type-function, so the scanner actually
4078 parses it as an object.
4080 2008-03-12 Johan Dahlin <johan@gnome.org>
4082 * tools/gidlwriter.c (function_generate): Add missing trailing quote.
4085 * tests/parser/Foo-expected.gidl:
4086 * tests/parser/Makefile.am:
4087 * tests/parser/foo-object.h:
4088 * tests/parser/foo.c:
4089 * tests/parser/utility-expected.gidl:
4090 * tests/parser/utility.c:
4091 * tests/parser/utility.h:
4093 Add a new gidl test. 'utility.gidl', which is used to be able
4094 to test external type references. Add a reference to UtilityObject*
4097 2008-03-11 Johan Dahlin <johan@gnome.org>
4101 Remove most global variables
4103 2008-03-11 Philip Van Hoof <me@pvanhoof.be>
4105 * tools/scannerlexer.l:
4107 * tests/parser/Foo-expected.gidl:
4108 * tests/parser/foo.c:
4109 * tests/parser/Makefile.am:
4110 * tests/parser/foo-object.h:
4112 Added a few extra tests. Which resulted in finding a few
4113 bugs. Which resulted in me fixing those bugs
4115 2008-03-11 Rob Taylor <rob.taylor@codethink.co.uk>
4117 * tools/gidlcompilercontext.c: (g_idl_compiler_write_dir_entry),
4118 (g_idl_compiler_write_xref_entry), (g_idl_compiler_add_xref):
4119 Add some comments for strings into generated output for
4122 2008-03-11 Rob Taylor <rob.taylor@codethink.co.uk>
4124 * tools/gidlcompilercontext.c: (write_compiled):
4125 Write out the shlibs variable before writing out the strings
4126 length. Fixes compiler warning when using '-l' flag with
4129 2008-03-11 Johan Dahlin <johan@gnome.org>
4131 * tests/parser/Foo-expected.gidl:
4132 * tests/parser/foo-object.h:
4135 * tools/scannerlexer.l:
4136 Add support for parsing return arguments. Add support for
4137 caller-owns return types.
4138 Patch by Philip Van Hoof.
4140 * tools/scannerparser.y:
4141 Remove parsing of the @deprecated syntax used in headers.
4142 We will support gtk-doc deprecation in the future instead.
4144 2008-03-11 Johan Dahlin <johan@gnome.org>
4146 * tools/compiler.c (main): Coding style fixes
4148 2008-03-10 Johan Dahlin <johan@gnome.org>
4151 Add GCOV_LIBS to GILIBS
4153 2008-03-10 Johan Dahlin <johan@gnome.org>
4155 * tests/parser/Foo-expected.gidl:
4156 * tests/parser/foo.c:
4157 Rename null-ok to direction=out
4159 2008-03-10 Philip Van Hoof <me@pvanhoof.be>
4161 reviewed and extensively tested by Johan
4163 * tests/parser/Foo-expected.gidl:
4164 * tests/parser/foo-object.h:
4165 * tests/parser/foo.c:
4168 * tools/gidlwriter.c:
4171 * tools/scannerlexer.l:
4172 * tools/scannerparser.y:
4174 Add support for scanning for gtk-doc comments inside
4175 C source files. Add tests
4177 2008-03-10 Johan Dahlin <johan@gnome.org>
4179 * tests/parser/Makefile.am:
4180 * tests/parser/foo.c:
4183 * tools/scannerparser.y:
4184 Add an api to lex filenames.
4185 Lex all source .c files passed in on the command line.
4186 Scan sources in a test and a couple of private structures
4187 which should not be included in the generated gidl
4189 2008-03-10 Johan Dahlin <johan@gnome.org>
4191 * tests/invoke/Makefile.am: Make the generated metadata
4192 depend on the g-idl-compiler
4194 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4196 * tools/gidlmodule.c
4197 * tools/gidlmodule.h
4200 Remove the old g-idl-compiler code.
4203 2008-02-22 Mark Doffman <mark.doffman@codethink.co.uk>
4205 * tools/quote-file.sh
4208 Move to using the 'C' struct compiler code.
4210 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4212 * girepository/ginfo.c
4214 Change the way that external references with no namespace
4215 are dealt with. External references with no namespace
4216 are placed into the XML as-if they are a local reference.
4217 This is temporary, but helps with roundtrip tests.
4219 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4221 * girepository/ginfo.c
4222 Add the ability to get the value of a constant of
4223 type TYPE_TAG_SYMBOL. In the case of a symbol the value
4224 is provided as a string.
4226 This would deal properly with:
4227 typedef char* random;
4228 const random = "A string";
4230 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4232 * girepository/ginfo.c
4233 * girepository/girepository.h
4235 Add a function to check if an enum is registered or not.
4236 Previously anything testing this relied on the g-type
4237 string offset having a value of 0.
4239 * girepository/gmetadata.c
4240 * girepository/gmetadata.h
4242 Remove unneccesary or erroneous checks. There were two
4243 metadata validation checks which made sure that the blob
4244 sizes were the same as some magic numbers compiled into the code.
4245 This is wrong as it breaks any forwards compatibility that may
4248 Checks were also present that made sure that unregistered type
4249 blobs had a value of 0 in the g-type offset field. This is
4250 unneccessary. If a type blob is unregistered then any value
4251 in its g-type field is simply invalid.
4253 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4255 * girepository/ginfo.c
4256 * girepository/gmetadata.c
4257 * girepository/gmetadata.h
4259 Change the metadata format to have a standard header
4260 for all the type blobs. Merge the SimpleTypeBlob
4261 and InterfaceTypeBlob into a union. A union of these
4262 two blobs existed previously but was not explicit
4263 in the metadata format.
4265 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4267 * tools/gidlcompilercontext.c
4268 * tools/gidlcompilercontext.h
4269 * tools/gidlcompilerentrynode.c
4270 * tools/gidlcompilerentrynode.h
4271 * tools/gidlcompilertypenode.c
4272 * tools/gidlcompilertypenode.h
4274 Add code to compile a tree of GIdlNodes to
4275 a 'C' struct representing the metadata.
4276 This is to aid cross-compiling. Previously
4277 the g-idl-compiler created a binary blob with
4278 data written in the byte order and alignment
4279 of the tool rather than the intended target.
4281 Cleaned up and improved by Johan and Robert :-)
4283 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4285 * girepository/ginvoke.c
4286 * girepository/girepository.h
4287 * girepository/gmetadata.c
4288 * girepository/gmetadata.h
4290 * tools/gidlparser.c
4291 Modify TYPE_TAG_INTERFACE to TYPE_TAG_SYMBOL
4292 to avoid confusion with the interface blob.
4295 * tools/gidlparser.c
4296 Remove magic numbers and replace with type-tag
4297 enumeration symbols.
4299 * girepository/gmetadata.c
4300 Add validate declaration.
4302 2008-03-10 Jürg Billeter <j@bitron.ch>
4304 * tools/gidlparser.c: (parse_type_internal):
4305 * tools/scannerlexer.l:
4306 * tools/scannerparser.y:
4307 Support C99 _Bool type in scanner.
4309 2008-03-10 Jürg Billeter <j@bitron.ch>
4311 * tests/parser/Foo-expected.gidl:
4312 * tests/parser/foo-object.h:
4313 * tests/parser/foo.c: (foo_enum_method):
4314 * tools/scanner.c: (g_igenerator_process_function_symbol):
4315 Don't skip functions that are defined in the namespace of a type
4316 that doesn't support methods, as for example enums.
4318 2008-03-10 Johan Dahlin <johan@gnome.org>
4320 * gidl.dtd: Remove, we're using relaxng for now
4322 * tests/parser/Foo-expected.gidl:
4323 * tests/parser/foo-object.h:
4324 * tests/parser/foo.c:
4325 Rename the enum/flags get_type functions to include the whole type.
4327 2008-03-08 Marc-Andre Lureau <marcandre.lureau@gmail.com>
4329 * tools/gidlwriter.c (enum_generate): added "type-name",
4330 "get-type" and "deprecated" missing arguments.
4331 * tests/parser/Foo-expected.gidl:
4332 * tests/parser/foo-object.h: test enum type, and no type.
4334 2008-03-06 Johan Dahlin <jdahlin@async.com.br>
4337 Consistent checks, add missing 'test'
4339 2008-03-05 Havoc Pennington <hp@redhat.com>
4341 * configure.ac: Take advantage of a libffi.pc if one exists, as it
4342 does on Fedora 8. Make libffi a hard requirement, since it was in
4343 practice anyway (was not really conditional in the code or
4344 makefile, only in configure).
4346 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4348 reviewed by: Rob Taylor <rob.taylor@codethink.co.uk>
4349 reviewed by: Johan Dahlin <johan@gnome.org>
4351 * tests/Makefile.am:
4352 * tests/roundtrips.sh:
4353 Modify the roundtrips test so that they do not use the
4354 --raw option of the gidl compiler but instead compile a
4355 shared library to use with g_module.
4357 * tests/invoke/Makefile.am:
4358 * tests/invoke/invoke.c:
4359 Modify the invoke tests to build a shared library rather
4360 than use the --raw option.
4362 * tests/invoke/invoke-namespace-find.sh: Removed:
4363 Noone knows why this was here, so removed.
4365 2008-02-19 Rob Taylor <rob.taylor@codethink.co.uk>
4367 * tools/scanner.c: (g_igenerator_process_function_symbol):
4368 Move g_idl_node_can_have_member test later, as it broke spotting
4369 get_type's for nodes that can't have members.
4371 2008-02-18 Rob Taylor <rob.taylor@codethink.co.uk>
4374 * tools/gidlnode.c: (g_idl_node_can_have_member):
4375 Add g_idl_node_can_have_member.
4377 * tools/scanner.c: (g_igenerator_process_function_symbol):
4378 Use g_idl_node_can_have_member to test if we should add a function
4379 as a member of the type node.
4381 2008-02-18 Rob Taylor <rob.taylor@codethink.co.uk>
4383 * gidl/GLib.gidl: Renamed to gidl/gobject-2.0.gidl:
4385 * tests/parser/Makefile.am:
4386 Rename GLib.gidl to gobject-2.0.gidl and install in /usr/share/gidl.
4388 2008-02-18 Rob Taylor <rob.taylor@codethink.co.uk>
4390 * tools/scanner.c: (main):
4391 Ignore -pthread when passed to g-idl-scanner.
4393 2008-02-18 Rob Taylor <rob.taylor@codethink.co.uk>
4395 * tools/grealpath.h: Added:
4396 * tools/scanner.c: (main):
4397 * tools/scannerlexer.l:
4398 * tools/Makefile.am:
4399 Always use absolute paths with symbolic links resolved when
4400 comparing filenames.
4402 2008-02-18 Rob Taylor <rob.taylor@codethink.co.uk>
4404 * gobject-introspection.pc.in:
4405 Provide variables for g-idl-parser, scanner and compiler in the
4408 2008-02-13 Rob Taylor <rob.taylor@codethink.co.uk>
4411 * girepository/Makefile.am:
4412 * tools/Makefile.am:
4413 Rename GCOV_SOURCES to GCOVSOURCES to top automake complaining.
4415 2008-02-10 Johan Dahlin <johan@gnome.org>
4417 * tests/parser/Foo-expected.gidl:
4418 * tests/parser/foo-object.h:
4419 * tests/parser/foo.c: (foo_boxed_copy), (foo_boxed_free),
4420 (foo_boxed_get_type), (foo_boxed_new), (foo_boxed_method):
4423 2008-02-10 Johan Dahlin <johan@gnome.org>
4425 * tests/parser/Foo-expected.gidl:
4426 * tests/parser/foo-object.h:
4427 * tests/parser/foo.c: (foo_enum_get_type), (foo_flags_get_type):
4428 Add enum and flags test.
4430 2008-02-10 Johan Dahlin <johan@gnome.org>
4434 * girepository/Makefile.am:
4435 Make 'make distcheck' work again.
4437 2008-02-10 Johan Dahlin <johan@gnome.org>
4439 * m4/Makefile.am (EXTRA_DIST): its called as-compiler-flag.m4,
4442 * tests/parser/Makefile.am: Only create Foo.gidl when running make
4443 check, eg exclude it from BUILT_SOURCES.
4445 2008-02-08 Rob Taylor <rob.taylor@codethink.co.uk>
4450 * girepository/Makefile.am:
4451 * m4/Makefile.am: Added:
4452 * m4/as-compiler-flag.m4: Added:
4453 * m4/gcov.m4: Added:
4454 * tools/Makefile.am:
4455 Add ability to generate a coverage report.
4456 Adds configure option --enable-gcov and make rule 'check-coverage'.
4458 2008-02-08 Rob Taylor <rob.taylor@codethink.co.uk>
4462 * gidl/Makefile.am: Added:
4463 * girepository/Makefile.am: Added:
4464 * src/Makefile.am: Renamed to tools/Makefile.am:
4465 * src/compiler.c: Renamed to tools/compiler.c:
4466 * src/g-idl-offsets.pl: Renamed to tools/g-idl-offsets.pl:
4467 * src/generate.c: Renamed to tools/generate.c:
4468 * src/gidlmodule.c: Renamed to tools/gidlmodule.c:
4469 * src/gidlmodule.h: Renamed to tools/gidlmodule.h:
4470 * src/gidlnode.c: Renamed to tools/gidlnode.c:
4471 * src/gidlnode.h: Renamed to tools/gidlnode.h:
4472 * src/gidlparser.c: Renamed to tools/gidlparser.c:
4473 * src/gidlparser.h: Renamed to tools/gidlparser.h:
4474 * src/gidlwriter.c: Renamed to tools/gidlwriter.c:
4475 * src/gidlwriter.h: Renamed to tools/gidlwriter.h:
4476 * src/ginfo.c: Renamed to girepository/ginfo.c:
4477 * src/ginvoke.c: Renamed to girepository/ginvoke.c:
4478 * src/girepository.c: Renamed to girepository/girepository.c:
4479 * src/girepository.h: Renamed to girepository/girepository.h:
4480 * src/gmetadata.c: Renamed to girepository/gmetadata.c:
4481 * src/gmetadata.h: Renamed to girepository/gmetadata.h:
4482 * src/scanner.c: Renamed to tools/scanner.c:
4483 * src/scanner.h: Renamed to tools/scanner.h:
4484 * src/scannerlexer.l: Renamed to tools/scannerlexer.l:
4485 * src/scannerparser.y: Renamed to tools/scannerparser.y:
4486 * tests/invoke/Makefile.am:
4487 Split src/ into girepository/ and tools/
4491 * girepository/Makefile.am:
4492 * tests/Makefile.am:
4493 * tests/invoke/Makefile.am:
4494 * tests/parser/Makefile.am:
4495 * tests/roundtrips.sh:
4496 * tools/Makefile.am:
4497 Make distcheck work.
4499 2008-02-04 Rob Taylor <rob.taylor@codethink.co.uk>
4501 * tests/invoke/invoke.c: (main):
4502 * tests/invoke/testfns.c: (test6), (test7):
4503 * tests/invoke/testfns.xml:
4504 Add tests for invokation with a GList argument.
4505 Also tests caller-owns return values.
4507 2008-02-04 Rob Taylor <robtaylor@floopily.org>
4510 Add some documentation for GICallableInfo
4512 2008-02-01 Mark Doffman <mark.doffman@codethink.co.uk>
4515 Correct syntax errors in the DTD file.
4517 * relaxng/c-types.xml:
4518 * relaxng/g-types.xml:
4520 Add a RelaxNG specification for the GObject Introspection XML data.
4521 The Specification has validated all of the test files.
4523 2008-01-25 Rob Taylor <robtaylor@floopily.org>
4525 * tests/roundtrips.sh:
4526 * tests/struct.test:
4527 Add roundtrip tests for structs.
4529 2008-01-11 Johan Dahlin <johan@gnome.org>
4531 * src/scanner.c (g_igenerator_process_function_symbol):
4532 Refactor out g_idle_node_add_member.
4533 (create_node_from_gtype, create_node_from_ctype):
4534 Use case instead of if...else
4535 (get_type_from_type_id):
4536 Rename to create_node_from_gtype
4537 (get_type_from_ctype):
4538 Rename to create_node_from_ctype
4540 Rename ginode -> node, gitype -> type, gifunc -> func.
4542 * src/gidlnode.c (g_idl_node_add_member, g_idl_node_cmp):
4543 Two new functions, refactor out of scanner.c
4545 * src/scanner.c: (g_igenerator_process_function_symbol):
4546 * src/scannerlexer.l:
4547 Do not save the content of the deprecated variable, only
4550 2008-01-11 Johan Dahlin <johan@gnome.org>
4552 * tests/parser/foo-object.h: Add a couple of comment parser tests.
4554 2008-01-11 Jürg Billeter <j@bitron.ch>
4556 * src/scannerlexer.l:
4557 Fix GTK-Doc parsing.
4559 2008-01-11 Jürg Billeter <j@bitron.ch>
4561 * src/scannerlexer.l:
4562 Fix GTK-Doc parsing.
4564 2008-01-11 Jürg Billeter <j@bitron.ch>
4566 * src/scanner.c: (lookup_symbol):
4567 Return unresolved name if we find unknown symbol.
4569 2008-01-11 Jürg Billeter <j@bitron.ch>
4571 * src/scanner.c: (g_igenerator_generate):
4572 Initialize GObject to fix scanning interface properties.
4574 * tests/parser/Foo-expected.gidl:
4575 * tests/parser/foo-object.h:
4576 * tests/parser/foo.c: (foo_interface_get_type):
4577 Test interfaces with GObject prerequisite.
4579 * tests/parser/Makefile.am:
4580 Set G_DEBUG=fatal_warnings to abort test on warnings and criticals.
4582 2007-12-27 Johan Dahlin <johan@gnome.org>
4584 * src/scannerlexer.l:
4585 Parse gtk-doc comments.
4587 * src/gidlwriter.c: (function_generate):
4588 Reorganize, avoid duplication and add support for
4589 writing deprecated functions.
4591 * src/scannerparser.y:
4593 Add new structure CDirective and functions to create/free them.
4595 * src/scanner.c: (g_igenerator_process_function_symbol),
4596 (g_igenerator_process_unregistered_struct_typedef),
4597 (g_igenerator_process_struct_typedef),
4598 (g_igenerator_process_union_typedef),
4599 (g_igenerator_process_enum_typedef),
4600 (g_igenerator_process_function_typedef), (g_igenerator_add_symbol),
4601 (g_igenerator_start_preprocessor):
4602 Parse @deprecated directive for functions.
4603 Remove some more C99isms.
4604 Send in -C to cpp to avoid stripping comments.
4606 * tests/parser/foo-object.h:
4607 * tests/parser/Foo-expected.gidl:
4608 Add deprecated directive
4610 2007-12-27 Johan Dahlin <johan@gnome.org>
4612 * src/scannerlexer.l (intsuffix): Add emacs mode line and
4613 escape ' and " so it looks more like C.
4616 Unlink temporary file used.
4618 2007-12-27 Johan Dahlin <johan@gnome.org>
4620 * src/scanner.c: (g_igenerator_new), (g_igenerator_free),
4621 (g_igenerator_start_preprocessor), (main):
4623 * src/scannerparser.y:
4624 Plug a couple of simple memory leaks.
4626 2007-12-27 Johan Dahlin <johan@gnome.org>
4628 * src/scanner.c: (g_igenerator_parse_macros),
4629 (g_igenerator_start_preprocessor), (g_igenerator_set_verbose),
4632 * src/scannerparser.y:
4633 * tests/parser/Makefile.am:
4635 Improve error reporting, return when the preprocessor fails.
4636 Add a verbose parameter, to aid debugging.
4637 Revert to using a temporary file to communicate between the
4638 preprocessor and the parser, because we need to wait for
4639 the exit code from the pre-processor before starting to parse.
4641 2007-12-16 Johan Dahlin <jdahlin@async.com.br>
4643 * src/Makefile.am: Rename clexer.l to scannerlexer.l and
4644 cparser.y to scannerparser.y
4646 2007-12-11 Johan Dahlin <johan@gnome.org>
4650 * src/scanner.c: (g_igenerator_new):
4652 Get rid of the global the_generator variable.
4654 2007-12-10 Johan Dahlin <johan@gnome.org>
4656 * src/scanner.c (main): Add an output option,
4657 add checks for required parameters
4660 set BUILD_SOURCES and CLEANFILES properly
4662 * src/gidlwriter.c: (g_writer_write_inline), (g_writer_write),
4663 (g_writer_write_indent), (g_writer_write_unindent),
4664 (field_generate), (value_generate), (constant_generate),
4665 (property_generate), (function_generate), (vfunc_generate),
4666 (signal_generate), (interface_generate), (struct_generate),
4667 (union_generate), (boxed_generate), (enum_generate),
4668 (node_generate), (g_writer_write_module), (g_idl_writer_save_file):
4670 * src/scanner.c: (g_igenerator_generate):
4672 * src/scannerwriter.c:
4674 Refactor scannerwriter to only be tied to a GIdlModule and move
4675 it (again!) to gidlwriter.c. Change the writer function to take
4678 2007-12-10 Johan Dahlin <johan@gnome.org>
4681 * src/scanner.c: (g_igenerator_generate):
4683 * src/scannerwriter.c: (g_igenerator_write_inline),
4684 (g_igenerator_write), (g_igenerator_write_indent),
4685 (g_igenerator_write_unindent), (field_generate), (value_generate),
4686 (constant_generate), (property_generate), (function_generate),
4687 (vfunc_generate), (signal_generate), (interface_generate),
4688 (struct_generate), (union_generate), (boxed_generate),
4689 (enum_generate), (node_generate), (module_generate),
4690 (g_scanner_write_file):
4692 Move the scanner gidl writing to a separate source file.
4694 2007-12-10 Johan Dahlin <johan@gnome.org>
4699 Move over all CType construction functions.
4701 * tests/parser/Makefile.am:
4702 Be verbose when printing parsing tests results.
4704 2007-12-10 Johan Dahlin <johan@gnome.org>
4706 * src/scanner.c (g_igenerator_start_preprocessor): Refactor
4707 preprocessor handling to here. Start cpp insteado of cc -E,
4708 always include -U__GNUC__, since it's specific to the preprocessor
4711 * tests/parser/Makefile.am (check-local): Silent diff and skip
4712 -U__GNUC__ which is always defined now
4714 2007-12-10 Johan Dahlin,,, <jdahlin@plasttroll>
4716 reviewed by: <delete if not using a buddy>
4718 * src/scanner.c: (g_igenerator_start_preprocessor), (main):
4719 * tests/parser/Makefile.am:
4721 2007-12-09 Johan Dahlin <johan@gnome.org>
4724 Use GOption for command line options.
4725 (g_igenerator_new, main): Simplify constructor and they way
4726 parameters are passed into it.
4732 * src/gen-introspect.c:
4733 * src/gen-introspect.h:
4735 Rename gen-introspect.[ch] to scanner.[ch]
4737 2007-12-09 Johan Dahlin <johan@gnome.org>
4741 * src/Makefile.am: Rename gen-introspect to g-idl-scanner,
4742 don't make the repository library and the other utilites link against
4745 * src/gen-introspect.c: (g_igenerator_create_object),
4746 (g_igenerator_create_interface), (g_igenerator_create_boxed),
4747 (g_igenerator_create_enum), (g_igenerator_create_flags),
4748 (g_igenerator_process_module_symbol),
4749 (g_igenerator_process_module), (g_igenerator_generate), (main):
4750 * src/gen-introspect.h:
4751 Refactor g_igenerator_process_types into smaller pieces.
4753 * tests/parser/Makefile.am:
4754 Depend on the gen-introspect binary
4756 2007-12-09 Johan Dahlin <johan@gnome.org>
4758 * src/gen-introspect.c (g_igenerator_process_types):
4759 Break into smaller pieces, one for each generated node type.
4761 2007-12-08 Johan Dahlin <johan@gnome.org>
4763 * src/gen-introspect.c: (g_igenerator_process_types),
4764 (g_igenerator_add_module):
4765 * tests/parser/Foo-expected.gidl:
4766 * tests/parser/foo-object.h:
4767 * tests/parser/foo.c: (foo_subobject_class_init),
4768 (foo_subobject_init):
4770 Add a subobject test and make sure to register defined classes
4771 in the lookup symbol hash table.
4773 2007-12-08 Johan Dahlin <johan@gnome.org>
4777 * src/gen-introspect.c: (g_igenerator_new), (lookup_symbol),
4778 (g_igenerator_process_types), (g_igenerator_add_module),
4779 (g_igenerator_add_include_idl), (main):
4780 * src/gen-introspect.h:
4781 * tests/parser/Makefile.am:
4782 * tests/parser/Foo-expected.gidl:
4784 Change the gen-introspect to generate namespaced module names,
4785 such as GLib.Object instead of GObject.
4786 Add a GLib.gidl which introduces GLib.Object and GLib.InitiallyUnowned,
4787 add a --include-idl parameter to gen-introspect,
4788 and update the parser test.
4790 2007-12-08 Johan Dahlin <johan@gnome.org>
4792 * src/gen-introspect.c:
4793 Move main to the end of the file and attempt to make it valid
4796 * tests/parser/Makefile.am (BUILT_SOURCES): Remove .repo here,
4797 we're not quite ready to generate metadata yet.
4802 Add a simple gen-introspect parser test
4804 2007-12-06 Gustavo J. A. M. Carneiro <gjc@gnome.org>
4806 reviewed by: Johan Dahlin <johan@gnome.org>
4809 * gobject-introspection.pc.in:
4811 * src/compiler.c: (format_output), (write_out_metadata), (main):
4812 * src/gen-introspect.c: (main):
4813 * src/gen-introspect.h:
4814 * src/generate.c: (write_callable_info), (write_repository),
4815 (load_metadata), (main):
4816 * src/gidlmodule.c: (g_idl_module_new),
4817 (g_idl_module_build_metadata):
4819 * src/gidlparser.c: (start_element_handler):
4820 * src/ginfo.c: (g_info_new), (g_info_from_entry),
4821 (g_base_info_get_name), (g_base_info_get_namespace),
4822 (g_base_info_is_deprecated), (g_base_info_get_annotation),
4823 (g_base_info_get_metadata), (g_function_info_get_symbol),
4824 (g_function_info_get_flags), (g_function_info_get_property),
4825 (g_function_info_get_vfunc), (signature_offset), (g_type_info_new),
4826 (g_callable_info_may_return_null),
4827 (g_callable_info_get_caller_owns), (g_callable_info_get_n_args),
4828 (g_callable_info_get_arg), (g_arg_info_get_direction),
4829 (g_arg_info_is_return_value), (g_arg_info_is_dipper),
4830 (g_arg_info_is_optional), (g_arg_info_may_be_null),
4831 (g_arg_info_get_ownership_transfer), (g_type_info_is_pointer),
4832 (g_type_info_get_tag), (g_type_info_get_param_type),
4833 (g_type_info_get_interface), (g_type_info_get_array_length),
4834 (g_type_info_is_zero_terminated),
4835 (g_type_info_get_n_error_domains), (g_type_info_get_error_domain),
4836 (g_error_domain_info_get_quark), (g_error_domain_info_get_codes),
4837 (g_value_info_get_value), (g_field_info_get_flags),
4838 (g_field_info_get_size), (g_field_info_get_offset),
4839 (g_registered_type_info_get_type_name),
4840 (g_registered_type_info_get_type_init),
4841 (g_struct_info_get_n_fields), (g_struct_info_get_field),
4842 (g_struct_info_get_n_methods), (g_struct_info_get_method),
4843 (find_method), (g_struct_info_find_method),
4844 (g_enum_info_get_n_values), (g_enum_info_get_value),
4845 (g_object_info_get_parent), (g_object_info_get_type_name),
4846 (g_object_info_get_type_init), (g_object_info_get_n_interfaces),
4847 (g_object_info_get_interface), (g_object_info_get_n_fields),
4848 (g_object_info_get_field), (g_object_info_get_n_properties),
4849 (g_object_info_get_property), (g_object_info_get_n_methods),
4850 (g_object_info_get_method), (g_object_info_find_method),
4851 (g_object_info_get_n_signals), (g_object_info_get_signal),
4852 (g_object_info_get_n_vfuncs), (g_object_info_get_vfunc),
4853 (g_object_info_get_n_constants), (g_object_info_get_constant),
4854 (g_interface_info_get_n_prerequisites),
4855 (g_interface_info_get_prerequisite),
4856 (g_interface_info_get_n_properties),
4857 (g_interface_info_get_property), (g_interface_info_get_n_methods),
4858 (g_interface_info_get_method), (g_interface_info_find_method),
4859 (g_interface_info_get_n_signals), (g_interface_info_get_signal),
4860 (g_interface_info_get_n_vfuncs), (g_interface_info_get_vfunc),
4861 (g_interface_info_get_n_constants),
4862 (g_interface_info_get_constant), (g_property_info_get_flags),
4863 (g_signal_info_get_flags), (g_signal_info_get_class_closure),
4864 (g_signal_info_true_stops_emit), (g_vfunc_info_get_flags),
4865 (g_vfunc_info_get_offset), (g_vfunc_info_get_signal),
4866 (g_constant_info_get_value), (g_union_info_get_n_fields),
4867 (g_union_info_get_field), (g_union_info_get_n_methods),
4868 (g_union_info_get_method), (g_union_info_is_discriminated),
4869 (g_union_info_get_discriminator_offset),
4870 (g_union_info_get_discriminator):
4871 * src/ginvoke.c: (g_function_info_invoke):
4872 * src/girepository.c: (g_irepository_register),
4873 (g_irepository_unregister), (g_irepository_get_default),
4874 (count_interfaces), (g_irepository_get_n_infos), (find_interface),
4875 (g_irepository_get_info), (g_irepository_find_by_name),
4876 (g_irepository_get_shared_library),
4877 (g_irepository_build_search_path), (g_irepository_register_file),
4878 (g_irepository_error_quark):
4879 * src/girepository.h:
4880 * src/gmetadata.c: (g_metadata_get_dir_entry),
4881 (g_metadata_check_sanity), (validate_header),
4882 (validate_array_type_blob), (validate_iface_type_blob),
4883 (validate_param_type_blob), (validate_error_type_blob),
4884 (validate_type_blob), (validate_arg_blob),
4885 (validate_signature_blob), (validate_function_blob),
4886 (validate_callback_blob), (validate_constant_blob),
4887 (validate_value_blob), (validate_field_blob),
4888 (validate_property_blob), (validate_signal_blob),
4889 (validate_vfunc_blob), (validate_struct_blob),
4890 (validate_enum_blob), (validate_object_blob),
4891 (validate_interface_blob), (validate_errordomain_blob),
4892 (validate_union_blob), (validate_blob), (validate_directory),
4893 (validate_annotations), (g_metadata_validate), (_g_metadata_init),
4894 (g_metadata_new_from_memory), (g_metadata_new_from_const_memory),
4895 (g_metadata_new_from_mapped_file), (g_metadata_free),
4896 (g_metadata_set_module), (g_metadata_get_namespace):
4898 * tests/Makefile.am:
4899 * tests/invoke/Makefile.am:
4900 * tests/invoke/invoke-namespace-find.sh:
4901 * tests/invoke/invoke.c: (main):
4903 Add a namespace/shared library mapping. fixes #313268.
4905 2007-12-03 Johan Dahlin <johan@gnome.org>
4907 * src/gidlparser.c (parse_type_internal): Disable char/gchar and
4910 2007-11-30 Jürg Billeter <j@bitron.ch>
4916 * src/gen-introspect.c: (g_idl_node_cmp), (g_igenerator_new),
4917 (g_igenerator_write_inline), (g_igenerator_write),
4918 (g_igenerator_write_indent), (g_igenerator_write_unindent),
4919 (field_generate), (value_generate), (constant_generate),
4920 (property_generate), (function_generate), (vfunc_generate),
4921 (signal_generate), (interface_generate), (struct_generate),
4922 (union_generate), (boxed_generate), (enum_generate),
4923 (node_generate), (module_generate), (get_type_from_type_id),
4924 (str_replace), (g_igenerator_process_properties),
4925 (g_igenerator_process_signals), (g_igenerator_process_types),
4926 (get_type_from_ctype), (g_igenerator_process_function_symbol),
4927 (g_igenerator_process_unregistered_struct_typedef),
4928 (g_igenerator_process_struct_typedef),
4929 (g_igenerator_process_union_typedef),
4930 (g_igenerator_process_enum_typedef),
4931 (g_igenerator_process_function_typedef),
4932 (g_igenerator_process_constant), (g_igenerator_process_symbols),
4933 (g_igenerator_add_symbol), (g_igenerator_is_typedef),
4934 (g_igenerator_generate), (main), (csymbol_new),
4935 (csymbol_get_const_boolean), (ctype_new), (ctype_copy),
4936 (cbasic_type_new), (ctypedef_new), (cstruct_new), (cunion_new),
4937 (cenum_new), (cpointer_new), (carray_new), (cfunction_new),
4938 (eat_hspace), (eat_line), (read_identifier),
4939 (g_igenerator_parse_macros):
4940 * src/gen-introspect.h:
4942 Import gen-introspect to generate introspection information by
4945 2007-11-30 Jürg Billeter <j@bitron.ch>
4947 * src/gidlnode.c: (g_idl_node_new): support creating callback nodes
4949 2007-11-30 Jürg Billeter <j@bitron.ch>
4951 * src/gidlparser.c: (end_element_handler): Don't leave requires
4954 2007-11-29 Johan Dahlin <johan@gnome.org>
4956 * src/gidlparser.c (parse_type_internal): Add char,
4957 gchar and guchar to the builtin types.
4959 2007-11-26 Johan Dahlin <johan@gnome.org>
4961 * src/ginfo.c: (g_object_info_get_type_name),
4962 (g_object_info_get_type_init):
4963 * src/girepository.c: (g_irepository_is_registered):
4964 * src/girepository.h:
4966 Add g_object_info_get_type_name, g_object_info_get_type_init and
4967 g_irepository_is_registered.
4969 2006-08-14 Jürg Billeter <j@bitron.ch>
4971 * src/gidlparser.c: (end_element_handler): Don't leave
4972 namespace and implements states too early.
4975 2007-11-26 Johan Dahlin <johan@gnome.org>
4977 * src/gmetadata.c (validate_struct_blob):
4978 pass blob_type to validate_function_blob instead of
4979 hard-coding BLOB_TYPE_STRUCT.
4981 Patch by Torsten Schoenfeld, fixes #314190
4983 2006-10-03 Torsten Schoenfeld <tsch@cvs.gnome.org>
4985 * src/compiler.c, src/generate.c, src/gidlnode.c,
4986 src/gidlparser.c, src/ginfo.c, src/girepository.c,
4987 tests/invoke/invoke.c, test/invoke/testfns.c: Hush compiler
4988 warnings about return values, signedness mismatches, unused
4989 variables, and unhandles enum values in switch statements.
4991 * tests/invoke/Makefile.am: Don't install the invoke test program.
4992 Add -I ../../src to the cflags used for the test functions files.
4994 2005-08-31 Torsten Schoenfeld <tsch@cvs.gnome.org>
4996 * src/girepository.h: Export g_invoke_error_quark.
4998 2005-08-31 Torsten Schoenfeld <tsch@cvs.gnome.org>
5000 * src/ginvoke.c: Remove the fallback implementation of
5001 g_function_info_invoke since we now formally depend on libffi.
5003 2005-07-25 Matthias Clasen <mclasen@redhat.com>
5005 * src/Makefile, tests/Makefile, tests/invoke/Makefile:
5006 Remove these files from cvs, as they are now generated.
5008 * src/gmetadata.c (validate_iface_type_blob): Don't
5009 complain if blob->pointer is not set, since that
5010 happens for enum and flag types. (#308935, Gustavo
5013 * Commit an autoconf-conversion patch by
5014 Gustavo Carneiro (#308708)
5016 2005-05-24 Matthias Clasen <mclasen@redhat.com>
5018 * src/compiler.c (main): Use it here to validate
5019 the generated metadata.
5021 * src/gmetadata.[hc]: Add code to validate a
5024 * metadata-format.txt: Updates
5026 2005-05-22 Matthias Clasen <mclasen@redhat.com>
5028 * tests/*: Add struct offsets to field and vfunc
5031 * src/generate.c (write_vfunc_info): Write offset
5032 information for vfuncs.
5034 * src/gidlnode.c (g_idl_node_build_metadata): Write
5035 the struct offsets into the metadata.
5037 * src/gidlparser.c: Parse the offset attributes of
5038 field and vfunc elements.
5040 * src/gidlnode.h: Add offset members to field and
5043 2005-05-21 Matthias Clasen <mclasen@redhat.com>
5047 * gidl.dtd: Updates.
5049 * src/g-idl-offsets.pl: A perl script which reads a .gidl
5050 file, creates, compiles and runs a C file, and folds the
5051 resulting struct offsets back into the .gidl file.
5053 2005-05-20 Matthias Clasen <mclasen@redhat.com>
5055 * src/gidlparser.c (start_field): Make fields in objects
5058 * src/gidlmodule.c: Include string.h
5063 * metadata-format.txt: Cleanup basic types.
5064 * src/*: Adapt to the changes.
5065 * tests/*: Adapt to the changes.
5066 * examples/gdk-pixbuf.gidl: Adapt to the changes.
5068 * src/gidlnode.c (g_idl_node_get_size): Report the correct
5069 size for enum blobs.
5070 (g_idl_node_get_full_size): Report the correct size for
5073 * src/gidlmodule.c (g_idl_module_build_metadata): Add some
5074 error checking for blob sizes.
5076 2005-05-19 Matthias Clasen <mclasen@redhat.com>
5078 * src/gidlnode.c (g_idl_node_build_metadata): Correctly handle
5079 interface types for which is_pointer is FALSE, e.g. enums.
5081 * src/gidlnode.c (g_idl_node_get_full_size)
5082 * src/gidlparser.c (parse_type_internal):
5083 * src/generate.c (write_type_info): Support unspecialized
5084 lists, hashtables and errors. Also emit a '*' after these.
5088 2005-05-17 Matthias Clasen <mclasen@redhat.com>
5092 * metadata-format.txt: Cleanups by Maciej Katafiasz.
5094 2005-05-15 Matthias Clasen <mclasen@redhat.com>
5096 * src/*.c: Change the directory to be addressed by
5097 1-based indexes, and use an index of zero to mean
5100 2005-05-15 Matthias Clasen <mclasen@redhat.com>
5102 * tests/roundtrips.sh (SIMPLE_TESTS): Add union.test.
5104 * tests/union.test: Add a union test.
5106 * src/generate.c: Handle unions.
5108 * src/girepository.h:
5109 * src/ginfo.c: Add GIUnionInfo and functions to access it.
5111 * src/gidlnode.c: Handle GIdlNodeUnion nodes.
5113 * src/gidlparser.c (start_union): Parse <union> elements.
5115 * src/gidlnode.h: Add a GIdlNodeUnion.
5117 * gidl.dtd: Add a <union> element.
5119 * src/gmetadata.c (g_metadata_check_sanity): Check
5122 * src/gmetadata.h: Add union_blob_size to Header,
5125 * metadata-format.txt: Add a UnionBlob.
5127 2005-05-13 Matthias Clasen <mclasen@redhat.com>
5129 * tests/*: Update testcases.
5131 * src/generate.c (write_callable_info): Don't forget to
5132 write transfer and null-ok attributes for return types
5135 * src/girepository.h:
5136 * src/ginfo.c (g_callable_info_may_return_null):
5137 New function to find out if a function may return NULL.
5139 * src/compiler.c (format_output): Make the generated
5142 * README: Point to a recent libffi snapshot.
5144 * tests/invoke/*: Some invoke tests.
5146 * src/Makefile: Add ginvoke.c and the necessary
5149 * src/girepository.h (g_function_info_invoke): Add
5152 * src/ginvoke.c (g_function_info_invoke): Initial
5153 implementation of invoke functionality based on libffi.
5155 * src/gidlnode.c (g_idl_node_build_metadata): Pass the
5156 strings and types hash tables in the right order when
5158 (find_entry_node): Free the name parts.
5160 2005-05-12 Johan Dahlin <johan@gnome.org>
5162 * src/generate.c: Generate consistent end tags.
5166 2005-05-12 Matthias Clasen <mclasen@redhat.com>
5170 * src/gidlparser.c (start_function): Actually add
5171 methods to objects. (Steven Walter)
5173 * src/girepository.h:
5174 * src/ginfo.c: Rename Transfer and Direction to
5175 GITransfer and GIDirection. (Torsten Schoenfeld)
5177 * tests/*: Make tests work with the changes in name
5180 * src/gidlnode.c (find_entry_node): Parse qualified
5181 names and generate xref nodes for them if needed. Don't
5182 require all modules to be loaded any more.
5184 * src/gidlmodule.c (g_idl_module_build_metadata): Choke
5187 * src/ginfo.c (g_object_info_get_parent): Return NULL
5188 if blob->parent is 0. Still need to make sure index
5191 * src/generate.c: Generate qualified names when
5192 referring to non-local types. Emit transfer attribute
5195 * src/compiler.c (format_output): Put the function
5196 attributes where gcc accepts them.
5198 2005-05-11 Matthias Clasen <mclasen@redhat.com>
5200 * src/compiler.c (main): Add a --verbose cmdline option
5201 and only log messages if it is specified.
5204 * src/gidlnode.c (init_stats, dump_stats): Collect some
5205 statistics on string and type sharing.
5207 * src/gidlmodule.c (g_idl_module_build_metadata): Use
5208 g_message() instead of fprintf().
5210 * src/gidlnode.c (g_idl_node_free): Make this more robust.
5211 (g_idl_node_get_size): Implement for structs.
5212 (g_idl_node_get_full_size): Handle parent being NULL.
5213 (serialize_type): Handle lookup failures more gracefully.
5215 2005-05-10 Matthias Clasen <mclasen@redhat.com>
5217 * src/gidlnode.c (g_idl_node_get_full_size): Correct the
5218 size calculation for 2-parameter types and for objects.
5220 * src/compiler.c: Add a cmdline option for debug output
5221 and install a log handler to implement it.
5222 * src/gidlnode.c: Add some debug spew.
5226 * src/gidlmodule.c (g_idl_module_build_metadata): Don't
5227 forget to count the module name when calculating the
5228 required size for the metadata.
5231 * src/gidlparser.c: Fix compiler warnings.
5233 2005-05-09 Matthias Clasen <mclasen@redhat.com>
5235 * src/compiler.c (main): Free the option context.
5237 * gidl.dtd: Clean up handling of names. All elements
5238 have a "name", only the elements corresponding to
5239 actual callable functions (function, method, constructor),
5240 have an additional "symbol" attribute holding the
5241 dlsym()-able function name.
5243 * src/generate.c: Adapt to generate xml matching the
5247 * src/gidlnode.c: Adapt to parse the new dtd.
5249 * tests/*.test: Adjust to the new dtd.
5251 * metadata-format.txt:
5252 * src/gmetadata.h: Remove the short_name field
5254 * src/gmetadata.c: Shrink size of ValueBlob to 12.
5255 * src/girepository.h:
5256 * src/ginfo.c (g_value_info_get_short_name): Removed
5258 2005-05-09 Matthias Clasen <mclasen@redhat.com>
5260 * gidl.dtd: Allow constructors for boxed types,
5261 patch by Jonathan Blandford.
5264 2005-05-09 Matthias Clasen <mclasen@redhat.com>
5266 * --- Initial import ---