1 2008-11-12 Owen Taylor <otaylor@redhat.com>
3 Fix management of ParseContext.includes_modules (#560419)
5 * girepository/girparser.c: Fix some trivial bugs in managing the
6 list of include modules. (Add to module's list twice, not
7 initialized to NULL, not freed.)
9 2008-11-12 Owen Taylor <otaylor@redhat.com>
11 Keep aliases and disguised_structures local to each module (#560419)
13 * girepository/girmodule.[ch]: When parsing, keep keep a separate
14 hash tables of aliases and 'disguised' flags for each module, and
15 store that on the module.
17 After parsing an include merge the aliases/disguised flags to the
20 * girepository/girparser.c: Remove 'prefix_aliases' flag and
21 always prefix aliases/disguised structure types when parsing; this
22 simplifies the code considerably.
24 2008-11-12 Owen Taylor <otaylor@redhat.com>
26 Fix mismatches between .gir name and 'name' attribute (#560419)
28 * tests/boxed.gir tests/constant.gir tests/enum.gir tests/invoke/invoke.c
29 tests/invoke/testfns-1.0.gir tests/object.gir tests/struct.gir: Fix places
30 where the 'name' element of <namespace/> didn't match the filename of the
31 gir, an assumption that the compiler has always expected and now enforces.
33 2008-11-12 Owen Taylor <otaylor@redhat.com>
35 Only allow one <namespace/> element per <repository/> (#560419)
37 * girepository/girparser.c: The logic in girparser.c didn't work
38 very well if there were multiple <namespace/> nodes within a
39 single <repository/> (context->namespace was always the overall
40 filename and not the the name specified in the <namespace/>
41 element for one thing; this would cause aliases to be mis-prefixed
42 in include modules.) Also check that the "name" in the
43 <namespace/> node matches the filename.
45 2008-11-12 Owen Taylor <otaylor@redhat.com>
47 Add a GirParser object to hold the state of a compilation
49 * girepository/girparser.[ch] tools/compiler.c: Add a toplevel
50 GirParser object to hold state that is global across a
51 compilation. Currently just holds the include path, but will
52 eventually also keep a cached list of parsed modules.
54 2008-11-12 Tommi Komulainen <tommi.komulainen@iki.fi>
56 * girepository/girepository.c (find_namespace_latest): Fix
59 2008-11-12 Tommi Komulainen <tommi.komulainen@iki.fi>
61 * configure.ac: use 'introspection' component for bugs
63 2008-11-12 Johan Dahlin <jdahlin@async.com.br>
65 * tests/everything/gitesttypes.c (test_filename_return):
66 * tests/everything/gitesttypes.h:
67 Add a filename return test.
69 2008-11-12 Tommi Komulainen <tommi.komulainen@iki.fi>
71 * tests/offsets/Makefile.am (gitestoffsets.c): fix
72 gen-gitestoffsets invocation with builddir != srcdir
74 2008-11-12 Johan Dahlin <jdahlin@async.com.br>
76 * girepository/girepository.c:
77 Change the element type from utf8 to filename
78 * girepository/girnode.c (g_ir_node_build_typelib):
79 Special case filename equally to utf8 here.
81 2008-11-12 Johan Dahlin <jdahlin@async.com.br>
84 Remove unused variables, add a dependency of girepository.ch, so when
85 they change we rebuild the gir automatically.
87 2008-11-12 Johan Dahlin <jdahlin@async.com.br>
89 * girepository/girepository.c (g_irepository_get_search_path):
90 * girepository/girepository.h:
91 Add a g_irepository_get_search_path, so we can access the search
94 2008-11-12 Johan Bilien <jobi@via.ecp.fr>
96 Bug 560474 – g-ir-compiler crashes when compiling the glib gir
98 * girepository/girparser.c: avoid freeing an uninitialized pointer
100 2008-11-12 Johan Dahlin <jdahlin@async.com.br>
103 * giscanner/glibtransformer.py:
104 * tools/g-ir-scanner:
105 Add a GIRepository-2.0.gir. Change the libtool lookup slightly
106 so we can just pass in --library=foo/bar/baz.la and the scanner
107 does the right thing.
108 Don't warn for _get_type() functions if they don't take any
111 2008-11-11 Owen Taylor <otaylor@redhat.com>
113 Bug 560404 – Prefix types when resolving aliases in included modules
115 * girepository/girparser.c: When resolving aliases in an included
116 module, prefix types before looking them up.
118 2008-11-11 Owen Taylor <otaylor@redhat.com>
120 Compute field offsets and overall size for object structures
122 Bug 560326 – Fails to build Gtk-2.0.typelib with "Unexpected non-pointer
123 field of type object in structure"
125 Do basic computation of field offsets for objects and interfaces;
126 this doesn't attempt to address all of the "mess" for virtual
127 functions described in Bug 560281.
129 2008-11-11 Tommi Komulainen <tommi.komulainen@iki.fi>
131 Bug 560308 – g-ir-compiler goes in infinite loop on Gdk-2.0.gir
133 Based on patch by Johan Bilien.
135 * giscanner/transformer.py (_create_member, _create_parameter):
136 Resolve types here as well.
137 (_resolve_type_name_1): Try resolving using 'ctype' first since
138 it's least ambiguous. Fixes struct member type resolution with
139 similarly named types, e.g. Gdk.PangoRendererClass and
141 * tests/scanner/foo*: Add test.
143 2008-11-11 Owen Taylor <otaylor@redhat.com>
145 * girepository/girparser.c: Search provided include dirs before
146 the default directories.
148 2008-11-11 Owen Taylor <otaylor@redhat.com>
150 * girepository/giroffsets.c: Include fully-qualified names in
153 2008-11-11 Owen Taylor <otaylor@redhat.com>
155 * girepository/giroffsets.c: Fail gracefully with an informative
156 error message when recursion is encountered when computing a
159 2008-11-11 Owen Taylor <otaylor@redhat.com>
161 * girepository/girparser.c: Remove an unused variable.
163 2008-11-10 Owen Taylor <otaylor@redhat.com>
165 Add tests for field offset computations
167 * tests/offsets/offsets.h: Header file with structure definitions to test
169 * tests/offsets/gen-gitestoffsets: Generate a C program that computes
170 field offsets for the structures in offsets.h two ways: using
171 the information from a generated typelib, and as computed by the
174 We diff these two versions to test that everything is OK.
176 2008-11-10 Owen Taylor <otaylor@redhat.com>
178 Remove field offsets from g-ir-generate output and test inputs
180 Field offsets are a) architecture dependent so they shouldn't be part
181 of the architecture-independent gir format which is installed in
182 datadir. b) Are architecture-dependent so they shouldn't be in test
185 * girepository/girparser.c: Don't parse offset for fields
186 * tools/generate.c: Don't parse offset for fields
187 * tests/*.gir test/scanner/*.tgir: Remove offsets
189 (Virtual function and discriminator offsets are not removed, as they
190 aren't fully hooked up to the field-offset computation machinery yet.)
192 2008-11-10 Owen Taylor <otaylor@redhat.com>
194 Bug 560252 - Compute field offsets before writing typelib
196 * girepository/girnode.h: Store the total size and alignment for
197 GIrNodeStruct/Boxed/Union.
199 * girepository/giroffset.c: New file implementing computation of
200 structure field offsets.
202 * girepository/girnode.c: Compute structure field offsets before
203 writing types into the typelib.
205 * docs/typelib-format.txt: Document that a field offset of 0xFFFF
206 means "unknown". Also fix description of the discriminator_offset
209 2008-11-10 Owen Taylor <otaylor@redhat.com>
211 Bug 560250 - Fully parse included modules
213 For some things, like computing structure offsets to put into the typelib
214 we need more than just the aliases from included modules. Do a completel
215 parse of included modules and store in module->included_modules.
217 Also add g_ir_find_node() to find node information from within the
218 active set of modules and their includes.
220 2008-11-10 Owen Taylor <otaylor@redhat.com>
222 Split g_ir_ffi_get_ffi_type() out from ginvoke.c
224 Extract a function to convert GITypeTag to ffi_type from the internals
225 of ginvoke.c. This will be useful in figure out structure alignment.
227 Also fix handling of gsize and time_t to be portable. (Add a check
228 to configure.ac to figure out the width of time_t.)
230 2008-11-10 Owen Taylor <otaylor@redhat.com>
232 Bug 560248 – "disguised structures"
234 Certain types like GIConv and GdkAtom are pointers internally but don't
235 look like pointers when referenced. They have the form.
237 typedef struct _X *X;
239 Parse these as structures/records but mark them in the gir with a 'disguised'
240 attribute so that we know that they need special handling.
242 In the typelib treat them like any other structure.
244 2008-11-09 Jürg Billeter <j@bitron.ch>
247 * giscanner/girwriter.py:
249 Write throws attribute for virtual functions, fixes bug 559703
251 2008-11-07 Johan Dahlin <jdahlin@async.com.br>
253 * giscanner/libtoolimporter.py (LibtoolImporter.find_module): Clear
254 up some confusion about the second argument to find_module, it's
255 actually the packages __path__ attribute which we can safely ignore
257 (LibtoolImporter.load_module): Set module.__loader__ as per PEP 302.
259 2008-11-07 Owen Taylor <otaylor@redhat.com>
261 Bug 559737 – Deal with continuations in macros
263 * giscanner/giscannerlexer.l: Treat continuation lines the same
264 as regular newlines. This makes the scanner not complain about
265 #define foo(x) \ <stuff> inside a C file. There's no attempt
266 however to handle parsing macro definitions split across lines.
268 2008-11-07 Johan Dahlin <jdahlin@async.com.br>
270 * giscanner/cachestore.py:
271 Handle broken cache entries, write only filesystems and
272 running out of diskspace.
274 2008-11-07 Owen Taylor <otaylor@redhat.com>
276 * giscanner/giscannermodule.c (pygi_source_scanner_lex_filename):
277 Set current_filename before lexing the file so error messages
278 are reported in the right file.
280 2008-11-06 Colin Walters <walters@verbum.org>
282 * tests/everything/*: Add some tests for strv.
284 2008-11-05 Colin Walters <walters@verbum.org>
286 * girepository/ginvoke.c (g_function_info_invoke): Don't use
287 nested scope local variable for error which may go away after
288 conditional is complete.
290 2008-11-05 Colin Walters <walters@verbum.org>
292 * giscanner/scannerlexer.l: Avoid static 256 char buf which we
293 manipulate hackily; just use GString. This avoids an
294 uninitialized memory read pointed out by Havoc.
296 2008-11-04 Johan Dahlin <jdahlin@async.com.br>
298 * giscanner/__init__.py:
300 * giscanner/cachestore.py:
301 * giscanner/cgobject.py:
302 * giscanner/girparser.py:
303 * giscanner/girwriter.py:
304 * giscanner/giscannermodule.c:
305 * giscanner/glibast.py:
306 * giscanner/glibtransformer.py:
307 * giscanner/libtoolimporter.py:
308 * giscanner/minixpath.py:
309 * giscanner/odict.py:
310 * giscanner/sourcescanner.c:
311 * giscanner/sourcescanner.h:
312 * giscanner/sourcescanner.py:
313 * giscanner/transformer.py:
314 * giscanner/utils.py:
315 * giscanner/xmlwriter.py:
317 Relicense the giscanner library under LGPLv2+.
318 This has been approved by all contributors.
320 2008-11-01 Owen Taylor <otaylor@redhat.com>
322 Bug 558848 giparser.py: shared library should be optional
324 When parsing a .gir, allow the shared-library attribute
325 of <namespace/> to be missing: this corresponds to the handling
326 in libgirepository and elsewhere.
328 2008-11-01 Tommi Komulainen <tommi.komulainen@iki.fi>
330 Bug 557898 – Fails to build on OSX 10.4
332 * configure.ac: Check for $shrext_cmds that should be implicitly
333 available if you're using libtool >= 2.0. If undefined, call
334 libtool --config explicitly to get its value.
335 * girepository/gtypelib.c: Remove special case for (non-)Darwin
338 2008-10-31 Colin Walters <walters@verbum.org>
340 * COPYING, COPYING.lib, COPYING.tools: Clarify licensing status.
342 2008-10-31 Johan Dahlin <jdahlin@async.com.br>
344 * configure.ac: Post release version bump
347 2008-10-31 Johan Dahlin <jdahlin@async.com.br>
351 * docs/release-checklist.txt:
354 2008-10-31 Johan Dahlin <jdahlin@async.com.br>
356 * Makefile.am: add an upload-release target
357 * docs/release-checklist.txt:
358 Release process documentation
360 2008-10-31 Colin Walters <walters@verbum.org>
362 Bug 558109 – _g_typelib_init fails to find shared libraries
364 * transformer/glibtransformer.py: Use ctypes' find_library
365 on passed libraries and write that for the shared-library
366 entry. We want to avoid depending on -devel packages.
368 2008-10-31 Johan Dahlin <jdahlin@async.com.br>
370 * docs/g-ir-scanner.1:
371 Document the renaming options.
373 2008-10-31 Tommi Komulainen <tommi.komulainen@iki.fi>
375 * giscanner/Makefile.am:
376 * tests/invoke/Makefile.am:
377 * tests/repository/Makefile.am: List in-tree libraries first in
378 LDADD / LIBADD. If installed library is listed first, the
379 resulting binary will prefer installed version to one in .libs,
380 possibly making 'make check' behave strangely.
382 2008-10-30 Tommi Komulainen <tommi.komulainen@iki.fi>
384 * giscanner/ast.py: map 'id' (ObjC) to 'any' type to stop
385 gir-repository from choking with gdk/quartz
387 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
389 * giscanner/giscannermodule.c (calc_attrs_length),
390 (pygi_collect_attributes):
391 * giscanner/xmlwriter.py:
392 Write a C version of the xml namespace formatter.
393 Saves 15% of the time it takes to create a gtk gir.
395 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
397 * giscanner/xmlwriter.py: Abstract attribute formatting
398 to a function external to the XMLWriter class.
400 * giscanner/scannerlexer.l:
401 Parse and discard __typeof and __attribute.
403 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
405 * giscanner/girparser.py:
406 Remove arguments from the constructor, move them to
407 separate accessors. Add a new parse_tree method
408 which takes an element tree instance.
409 * tools/g-ir-scanner:
410 Update callsite for this
412 * giscanner/Makefile.am:
413 * giscanner/cachestore.py:
414 * giscanner/transformer.py:
415 Cache the include parsing. Saves ~25% time when
416 creating vte (which includes everything up to gtk+).
418 2008-10-30 Colin Walters <walters@verbum.org>
420 * giscanner/transformer.py: Don't reparse includes
421 we've already processed.
423 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
425 * giscanner/girparser.py:
426 * giscanner/transformer.py:
427 Avoid parsing parameters, types etc when parsing
428 includes. Should speed up include parsing a bit.
430 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
432 * giscanner/girparser.py:
433 Avoid big if/else and use a dispatch table like
436 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
438 * giscanner/transformer.py:
439 Clean up include parsing and registration.
441 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
443 * giscanner/transformer.py:
446 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
448 Bug 558383 – builddir != srcdir build fails if giscanner python module not already installed
451 construct PYTHONPATH just once
453 * tests/everything/Makefile.am:
454 * tests/scanner/Makefile.am:
455 add $(top_srcdir) to PYTHONPATH to
456 handle builddir != srcdir
458 * giscanner/libtoolimporter.py:
459 * giscanner/sourcescanner.py:
460 Make the libtoolimporter work when distchecking too.
462 Mostly based on patch by Tommi Komulainen
464 2008-10-29 Owen Taylor <otaylor@redhat.com>
466 * giscanner/glibtransformer.py: If a filename of an existing
467 file is passed to --library, hunt for it directly, rather than
468 searching for a corresponding library.
470 2008-10-29 Johan Dahlin <jdahlin@async.com.br>
472 * giscanner/libtoolimporter.py:
473 * giscanner/sourcescanner.py:
474 Clean up the libtool importer a bit. Add a context so we
475 can use it through a with statement.
476 Don't just look in the current directory, look in the whole
479 2008-10-29 Tommi Komulainen <tommi.komulainen@iki.fi>
481 Bug 558065 – gitesttypes should be installed
485 * tests/types/Makefile.am -> tests/everything/Makefile.am
486 * tests/types/gitesttypes.c -> tests/everything/gitesttypes.c
487 * tests/types/gitesttypes.h -> tests/everything/gitesttypes.h
488 move tests/types to tests/everything
490 * tests/everything/Makefile.am: build normal shared library
491 libgirepository-everything.so.1.0.0 and corresponding typelib
492 Everything-1.0.typelib
494 * tests/everything/Makefile.am: explicitly link libtool
495 versioning with typelib versioning with variables
497 2008-10-28 Johan Bilien <jobi@via.ecp.fr>
499 * tools/g-ir-scanner: add LD_LIBRARY_PATH to LPATH before calling ld.
501 2008-10-27 Johan Bilien <jobi@via.ecp.fr>
503 * gio/gio-2.0.c: add allow-none annotations, based on the pygobject
506 2008-10-27 Johan Bilien <jobi@via.ecp.fr>
508 Bug 558068 – when invoking a method, offset the in arguments by one,
511 * tests/invoke/invoke.c, tests/invoke/testfns.c,
512 tests/invoke/testfns-1.0.gir: Add testing of method and constructor.
513 * girepository/ginvoke.c: do not offset the index of given out
514 arguments by one for methods, "this" is provided as in argument only.
516 2008-10-27 Johan Bilien <jobi@via.ecp.fr>
518 * gir/gio-2.0.c: add annotation for g_file_delete
520 2008-10-27 Tommi Komulainen <tommi.komulainen@iki.fi>
522 Bug 558062 – provide and use paths in the .pc file
524 * gobject-introspection-1.0.pc.in: provide typelibdir variable
525 for where .typelibs should be installed (callers shouldn't need
526 to construct paths from bits and pieces)
528 2008-10-25 Andreas Rottmann <a.rottmann@gmx.at>
530 Bug 557791 – g_irepository_require() could return a GTypelib *
532 * girepository/girepository.c: Return GTypelib; this is useful
533 for low level manipulation.
535 2008-10-25 Colin Walters <walters@verbum.org>
537 Bug 557788 – Return types for constructors in generated typelib bogus
539 * giscanner/glibtransformer.py: Don't resolve ctors incrementally,
540 rely on end pass resolution.
542 2008-10-25 Andreas Rottmann <a.rottmann@gmx.at>
544 Bug 557786 - support fixed size arrays
546 * girepository/ginfo.c: Add g_type_info_get_array_fixed_size.
547 * giscanner/scannerparser.y: Retain fixed array size.
548 * giscanner/ast.py: Add to note.
549 * giscanner/girwriter.py: Write to gir.
550 * girepository/girnode.c: Write it to typelib.
551 * tools/generate.c: Generate.
552 * tests/*: Add tests.
554 2008-10-25 Colin Walters <walters@verbum.org>
556 Bug 557076 - move typelibs to $libdir
558 * configure.ac: Steal some configury bits from dbus to expand
560 * gir/Makefile.am: Move to libdir.
561 * girepository/girepository.c: Stop searching XDG_DATA_DIRS;
562 instead just look at one hardcoded path in libdir.
563 * acinclude.m4: Bits from dbus.
565 2008-10-24 Johan Dahlin <johan@gnome.org>
567 * girepository/girnode.c (g_ir_node_check_unhandled_members):
568 Be quiet, do not warn about unhandled members.
570 2008-10-24 Johan Dahlin <johan@gnome.org>
572 * girepository/gtypelib.c:
573 Only use SHLIB_SUFFIX on darwin, otherwise use
574 G_MODULE_SUFFIX, we cannot get shext_cmds from libtool 2.2.
576 2008-10-24 Lucas Rocha <lucasr@gnome.org>
578 Bug 557623 - Constructors shouldn't be flagged as methods.
580 * girepository/ginfo.c (g_function_info_get_flags): ditto.
582 2008-10-24 Johan Dahlin <johan@gnome.org>
584 * giscanner/scannerparser.y:
585 Check against division by zero for the modula operator.
586 This fixes header parsing of OSX system headers included
589 2008-10-24 Johan Dahlin <johan@gnome.org>
593 Add a CONTRIBUTORS file and dist it.
595 2008-10-23 Tommi Komulainen <tommi.komulainen@iki.fi>
597 Bug 556739 – transfer-ownership attribute should be mandatory in .gir
599 * girepository/girparser.c (parse_param_transfer):
600 * giscanner/transformer.py (_create_parameter, _create_return):
601 * giscanner/girwriter.py (_write_return, _write_parameter):
602 * tools/generate.c (write_callable_info): always write and
603 require "transfer-ownership" for return-values and parameters
606 * tests/invoke/testfns-1.0.gir:
608 * tests/scanner/DrawableAdditions.xml:
609 * tests/scanner/GtkFrob-1.0-expected.tgir:
610 * tests/scanner/annotation-1.0-expected.tgir:
611 * tests/scanner/drawable-1.0-expected.tgir:
612 * tests/scanner/drawable-injected-1.0-expected.gir:
613 * tests/scanner/drawable-injected-1.0-expected.tgir:
614 * tests/scanner/foo-1.0-expected.tgir: Updated
616 2008-10-23 Tommi Komulainen <tommi.komulainen@iki.fi>
618 * giscanner/cgobject.py: build fundamental types same way as glib
620 * giscanner/glibtransformer.py (_type_from_gtype): record GType
621 when constructing the Type from it
623 * giscanner/glibtransformer.py (_adjust_transfer): Check whether
624 the parameter is a GObject from its GType, if available.
626 * giscanner/glibtransformer.py (_adjust_transfer):
627 * tests/scanner/foo-1.0-expected.gir:
628 * tests/scanner/foo-1.0-expected.tgir: deduce
629 transfer-ownership from GTypes
631 2008-10-23 Tommi Komulainen <tommi.komulainen@iki.fi>
633 * giscanner/transformer.py (_create_parameter):
634 * tests/scanner/foo-1.0-expected.gir: make varargs
635 transfer-ownership="none"
637 2008-10-23 Colin Walters <walters@verbum.org>
639 Bug 556739 - transfer ownership
641 * giscanner/ast.py: Refactor Parameter/Return to share
642 common attributes. Add transfer_inferred attribute
643 which says whether or not we made a guess.
644 * giscanner/transformer.py: Add much more extensive
645 heuristics around parameter and return transfer.
646 * giscanner/glibtransformer.py: Adjust to inspect
650 2008-10-22 Tommi Komulainen <tommi.komulainen@iki.fi>
652 Bug 557377 – Add test to ensure annotations survive the roundtrip via typelib
654 * tests/scanner/Makefile.am:
655 * tests/scanner/annotation-1.0-expected.tgir:
656 * tests/scanner/drawable-1.0-expected.tgir:
657 * tests/scanner/drawable-injected-1.0-expected.tgir:
658 * tests/scanner/foo-1.0-expected.tgir:
659 * tests/scanner/GtkFrob-1.0-expected.tgir:
660 * tests/scanner/utility-1.0-expected.tgir: Add test to ensure
661 annotations survive the roundtrip via typelib
663 The expectations are as currently produced by g-ir-generate,
664 comparison with the .gir files shows there are differences.
666 2008-10-23 Johan Bilien <jobi@via.ecp.fr>
668 Bug 557468 – Support for GI_TYPELIB_PATH
670 * girepository/girepository.c: if the GI_TYPELIB_PATH is set, add the
671 provided paths to the global search path.
673 2008-10-22 Tommi Komulainen <tommi.komulainen@iki.fi>
675 Bug 557379 – g-ir-generate not writing the 'abstract' attribute
677 * tests/scanner/drawable-1.0-expected.tgir:
678 * tests/scanner/drawable-injected-1.0-expected.tgir:
679 * tests/scanner/foo-1.0-expected.tgir:
680 * tools/generate.c (write_object_info): write 'abstract'
681 attribute for classes
683 2008-10-22 Lucas Rocha <lucasr@gnome.org>
685 * girepository/girmodule.c, girepository/gtypelib.c,
686 girepository/girparser.[ch]: fix some build warnings.
688 2008-10-22 Tommi Komulainen <tommi.komulainen@iki.fi>
690 Bug 557405 – Use 'allow-none' consistently
692 * docs/typelib-format.txt:
693 * girepository/ginfo.c (g_arg_info_may_be_null):
694 * girepository/girnode.c (g_ir_node_build_typelib):
695 * girepository/girnode.h (struct _GIrNodeParam):
696 * girepository/girparser.c (start_parameter):
697 * girepository/girwriter.c (function_generate):
698 * girepository/gtypelib.h (ArgBlob):
700 * tests/function.gir:
701 * tools/generate.c (write_callable_info): Use 'allow-none'
702 consistently throughout
704 2008-10-22 Tommi Komulainen <tommi.komulainen@iki.fi>
706 Bug 557092 – Callback annotations not used
708 * giscanner/transformer.py (_create_callback): use annotations
710 * tests/scanner/annotation.h
711 * tests/scanner/annotation-1.0-expected.gir: add tests
713 2008-10-21 Colin Walters <walters@verbum.org>
715 * giscanner/scannerlexer.l: Don't require trailing whitespace after
716 uncommented parameters.
719 2008-10-21 Colin Walters <walters@verbum.org>
721 * girepository/girepository.c: Ensure that when doing an unversioned
722 require, we prefer items earlier in the search path to later ones.
724 2008-10-21 Owen Taylor <otaylor@redhat.com>
726 * giscanner/transformer.py: For string parameters allow transfer annotation
727 to override the standard automatic guessing based on 'const'.
729 2008-10-21 Johan Bilien <jobi@via.ecp.fr>
731 Bug 557241 – "throws" flag for functions
733 * tests/scanner/drawable-1.0-expected.gir,
734 tests/scanner/drawable-injected-1.0-expected.gir,
735 tests/scanner/drawable.[ch]: add simple test for throwing
736 function (has GError ** as last argument)
738 * giscanner/ast.py: add a 'throws' flag to Function
739 * giscanner/glibtransformer.py: if a function's last paramerter is
740 a GError, set the 'throws' flag and remove that parameter
741 * giscanner/girwriter.py: write out the 'throws' attribute
742 * giscanner/girparser.py: support parsing the 'throws' attribute
744 * tests/repository/gitestthrows.c: add a simple test to check the
745 throws flag in a typelib and invoke the function
747 * girepository/ginfo.c, girepository/girnode.[ch],
748 girepository/girnode.h, girepository/girparser.c,
749 girepository/girepository.h: Add and parse the GI_FUNCTION_THROWS flag
751 * girepository/ginvoke.c: if a function throws, add a GError as last
752 arguments, and propagate the error to the invoker.
754 2008-10-21 Tommi Komulainen <tommi.komulainen@iki.fi>
756 * giscanner/transformer.py (_create_parameters): Warn if we see
757 annotations for unknown parameters. If .h and .c files name
758 parameters differently, the annotations may be lost.
760 2008-10-21 Johan Dahlin <johan@gnome.org>
762 Bug 556358 - don't use libtool internals
764 * giscanner/Makefile.am:
765 * giscanner/libtoolimporter.py:
766 * giscanner/sourcescanner.py:
767 * giscanner/utils.py:
768 Add a python meta importer and remove a libtool symlink hack.
770 2008-10-20 Andreas Rottmann <a.rottmann@gmx.at>
772 * tests/scanner/Makefile.am (%.typelib): Set PYTHONPATH
773 and --add-include-path appropriately when invoking the scanner.
774 * tests/types/Makefile.am (%typelib): Likewise.
776 2008-10-20 Colin Walters <walters@verbum.org>
778 Bug 556777 - validate properties
780 * giscanner/transformer.py: Add option to throw on unknown types.
781 * giscanner/glibtransformer.py: Use it on properties.
782 * tests/*: Add a test.
784 2008-10-20 Colin Walters <walters@verbum.org>
786 * giscanner/glibast.py: Also register g variants of
787 default_array_types. This is not beautiful, but
788 good alternatives aren't easy to come by.
789 This fixes gchar ** parsing.
791 2008-10-20 Colin Walters <walters@verbum.org>
793 * docs/typelib-format.txt, girepository/gtypelib.h:
794 Take a bit from ObjectInfo to represent abstract flag.
795 * giscanner/cgobject.py: Expose g_type_get_flags.
796 * girepository/girepository.h: Add accessor.
797 * girepository/ginfo.c: Implement it.
798 * giscanner/ast.py: Add is_abstract flag to generic
800 * giscanner/glibast.py: Use it.
801 * giscanner/girwriter.py: Write it.
802 * girepository/girparser.c: Parse it.
805 2008-10-20 Tommi Komulainen <tommi.komulainen@iki.fi>
807 * giscanner/girparser.py (_parse_function): don't lose
808 'transfer-ownership' attributes when injecting, check for the
811 2008-10-19 Johan Dahlin <johan@gnome.org>
813 * giscanner/scannerlexer.l: Parse and ignore __asm.
815 2008-10-19 Colin Walters <walters@verbum.org>
817 * giscanner/girparser.py: Parse array length= to ensure
818 it doesn't get lost from --inject.
820 2008-10-17 Colin Walters <walters@verbum.org>
822 Bug 556795 - char ** regression
824 * giscanner/transformer.py: Fix parsing of ctypes, add some
825 comments about what's going on.
826 * tests/*: Add a test for char **.
828 2008-10-17 Colin Walters <walters@verbum.org>
830 Bug 556783 - change namespace handling to be more consistent
832 * giscanner/transformer.py: Eliminate usage of
833 strip_namespace_object. We now treat --namespace as the default
834 --strip-prefix; however, if --strip-prefix is specified it
835 overrides --namespace. This applies to everything except function
836 names, where we do also strip the namespace.
837 * giscanner/glibtransformer.py: Remove usage of
838 strip_namespace_object.
840 * tests/*: Add skeletal GtkFrob-1.0 test which has different
841 --namespace and --strip-prefix.
843 2008-10-17 Tommi Komulainen <tommi.komulainen@iki.fi>
845 Bug 556732 – generate gir files consistently
847 * girepository/girparser.c (start_parameter):
849 * tests/invoke/testfns-1.0.gir:
850 * tools/generate.c (write_callable_info): write
851 'transfer-ownership' attribute consistently with both
852 return-value and parameter elements
854 2008-10-17 Tommi Komulainen <tommi.komulainen@iki.fi>
856 Bug 556732 – generate gir files consistently
858 * tools/generate.c (write_callable_info): write 'direction'
859 attribute only if other than 'in' to be consistent with
862 * tests/object.gir: remove direction="in" which is the default
864 2008-10-17 Tommi Komulainen <tommi.komulainen@iki.fi>
866 Bug 556732 – generate gir files consistently
868 * giscanner/ast.py (Field): add readable and writable properties
869 * giscanner/girparser.py (_parse_field): copy 'readable' and
870 'writable' attributes
871 * giscanner/transformer.py (_create_member): create fields as
873 * giscanner/glibtransformer.py (_introspect_object,
874 _pair_class_struct): make object instance and class fields
876 * giscanner/girwriter.py (_write_field):
877 * tools/generate.c (write_field_info): write field 'readable'
878 and 'writable' attributes only if non-default (read-only)
879 * girepository/girparser.c (start_field): in the absence of
880 attributes assume fields are read-only
882 * tests/struct.gir: remove redundant readable="1" from fields
883 * tests/scanner/foo-1.0-expected.gir:
884 * tests/scanner/utility-1.0-expected.gir: add writable="1" to
885 all record and union fields
887 2008-10-17 Tommi Komulainen <tommi.komulainen@iki.fi>
889 Bug 556732 – generate gir files consistently
891 * giscanner/girwriter.py (_write_property): write properties
892 'construct' attribute if set
893 * tools/generate.c (write_property_info): write properties
894 'readable' and 'writable' attributes only if non-default
895 * tests/object.gir: add writable="0"
896 * tests/scanner/foo-1.0-expected.gir: add construct="1"
898 2008-10-17 Johan Bilien <jobi@via.ecp.fr>
900 * gir/glib-2.0.c: added annotations
902 2008-10-16 Johan Bilien <jobi@via.ecp.fr>
904 * giscanner/ast.py: Also assume direction=out for size_t*, ssize_t*
907 2008-10-16 Johan Bilien <jobi@via.ecp.fr>
909 Bug 556610 – giscanner/girparser.py drops parameter options
911 * tests/scanner/drawable-injected-1.0-expected.gir,
912 tests/scanner/DrawableAdditions.xml: added simple test for injection.
913 * giscanner/ast.py: allow Parameter to take options in the constructor
914 * giscanner/girparser.py: parse parameter options (transfer,
915 direction, allow-none)
917 2008-10-16 Colin Walters <walters@verbum.org>
919 Bug 556185 - segfault on g_callable_info_get_return_type
921 Initial patch from John Ehresman.
923 * tests/repository/*: Add a test using
924 g_callable_info_get_return_type. Instead of casting a
925 GITypeInfo directly to a GIRegisteredTypeInfo, we need
926 to call g_type_info_get_interface.
928 2008-10-16 Colin Walters <walters@verbum.org>
930 Bug 556579 - union and struct name misresolved
932 * giscanner/transformer.py: The calls to _resolve_type_name
933 for struct/union names was a legacy holdover from when type
934 resolution had multiple phases. Now it's actively harmful
935 since we might pull in an identical name from another
939 2008-10-16 Colin Walters <walters@verbum.org>
941 Bug 556432 - transfer annotations and defaults
943 * giscanner/transformer.py: Canonicalize type
944 after removing *, not before. This ensures that
945 guchar* is transformed to 'uint8'.
946 Add some comments here.
947 * giscanner/glibtransformer.py: Add _adjust_transfer
948 phase for tweaking GObject transfers.
951 2008-10-16 Tommi Komulainen <tommi.komulainen@iki.fi>
953 * configure.ac: enable bunch of gcc warning CFLAGS
955 2008-10-16 Tommi Komulainen <tommi.komulainen@iki.fi>
957 Bug 556543 – reduce compiler warnings
959 * girepository/ginfo.c:
960 * girepository/girepository.c (register_internal,
961 count_interfaces, find_interface, find_namespace_version,
962 parse_version, g_irepository_require):
963 * girepository/girmodule.c (g_ir_module_build_typelib):
964 * girepository/girnode.c (init_stats, dump_stats,
965 _g_irnode_init_stats, _g_irnode_dump_stats,
966 g_ir_node_can_have_member):
967 * girepository/girparser.c (firstpass_end_element_handler,
968 locate_gir, parse_basic, parse_type_internal, resolve_aliases,
969 start_alias, start_type, end_type_top, parse_include, cleanup,
971 * girepository/gtypelib.c (validate_function_blob, validate_enum_blob):
972 * giscanner/giscannermodule.c (directive_get_options,
973 type_get_child_list):
974 * giscanner/scannerlexer.l (parse_gtkdoc):
975 * giscanner/scannerparser.y (ctype_free):
976 * giscanner/sourcescanner.c:
977 * giscanner/sourcescanner.h (gi_source_scanner_parse_macros):
978 * tests/types/gitesttypes.c:
979 * tools/compiler.c (main):
980 * tools/generate.c (write_repository): Remove unused variables
981 and code, add missing includes, declarations and case
984 2008-10-16 Tommi Komulainen <tommi.komulainen@iki.fi>
986 Bug 556541 – access union members through UnionBlob rather than
989 * girepository/ginfo.c (g_union_info_find_method): access union
990 members through UnionBlob rather than StructBlob
992 2008-10-15 Colin Walters <walters@verbum.org>
994 Bug 556331 - clean up includes handling
996 * tools/g-ir-scanner: Rework command line arguments; now we take
997 --add-include-path and --include separately.
998 * giscanner/girwriter.py: Separate name= and version= in include
1000 * giscanner/ast.py: Add Include type.
1001 * giscanner/transformer.py: Cleanups to register_include now that
1002 we don't need to handle mixed filenames and relative arguments.
1003 * girepository/girparser.c: Parse name and version separately;
1004 this fixes a bug as a side effect where we weren't resolving
1005 through aliases for basic types.
1006 * girepository/girepository.c: Fix format string args.
1007 * gir/Makefile.am: Update.
1010 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1012 Bug 556434 – unhandled interface/object/... member types
1014 * girepository/girnode.c (g_ir_node_check_unhandled_members,
1015 g_ir_node_build_typelib): Check all
1016 interface/object/boxed/struct/union members are processed and
1017 abort if they are not. (Mostly callbacks in structs, but also
1018 fields in interfaces.)
1020 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1022 * a/girepository/girnode.c (g_ir_node_build_members,
1023 g_ir_node_build_typelib): refactor common code for processing
1024 members to a function
1026 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1028 * gir/Makefile.am (check-local): check that typelib -> gir -> typelib
1029 transformation is lossless (it's not)
1031 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1033 * tests/Makefile.am: fix tests to compare xml to xml instead of
1034 typelib to xml, and stop on error
1036 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1038 * tools/generate.c (write_type_name, write_type_info,
1039 write_type_info, write_object_info, write_object_info,
1040 write_interface_info, write_error_domain_info): reduce code
1043 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1045 Bug 556174 – parse types for lists etc.
1047 * girepository/girparser.c (end_type_recurse):
1049 * tools/generate.c (write_type_info, write_field_info,
1050 write_callable_info, write_callable_info, write_constant_info,
1051 write_property_info): use nested <type>s for lists and hashes
1053 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1056 * tests/object.gir: remove trailing whitespace from inside
1057 elements to match g-ir-generate output
1059 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1061 * tools/generate.c (xml_printf): quote printf arguments so that
1062 we don't generate invalid XML by writing unescaped double quotes
1063 and such in attributes
1065 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1067 * tools/generate.c (write_field_info, write_callable_info,
1068 write_function_info, write_callback_info, write_struct_info,
1069 write_constant_value, write_signal_info, write_vfunc_info,
1070 write_object_info, write_interface_info, write_union_info,
1071 write_repository): remove unused indent parameters, xmlwriter
1072 keeps track of necessary indentation
1074 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1076 * tools/generate.c (xml_element_new, xml_element_free,
1077 xml_start_element, xml_end_element, xml_end_element_unchecked,
1078 xml_open, xml_close): Keep track of generated XML tree and
1079 handle indentation and closing tags properly.
1080 (write_field_info, write_callable_info, write_function_info,
1081 write_callback_info, write_struct_info, write_value_info,
1082 write_constant_info, write_enum_info, write_signal_info,
1083 write_vfunc_info, write_property_info, write_object_info,
1084 write_interface_info, write_error_domain_info, write_union_info,
1085 write_repository): Use xml_start_element and xml_end_element to
1088 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1090 * tools/generate.c (xml_printf, xml_open, xml_close, xml_free):
1091 (write_type_name, write_type_info, write_field_info,
1092 write_callable_info, write_function_info, write_callback_info,
1093 write_struct_info, write_value_info, write_constant_value,
1094 write_constant_info, write_enum_info, write_signal_info,
1095 write_vfunc_info, write_property_info, write_object_info,
1096 write_interface_info, write_error_domain_info, write_union_info,
1097 write_repository): wrap all FILE access to go through simple xmlwriter
1099 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1101 Bug 556400 – Fails to build on OS X 10.4
1103 * configure.ac: check for functions backtrace and backtrace_symbols
1104 * girepository/girparser.c (backtrace_stderr): Comment out
1105 implementation if the functions are not available.
1106 * gcov.mak (clean-gcov, clean-gcno): always call 'find' with a
1107 directory for better portability
1109 2008-10-15 Johan Bilien <jobi@via.ecp.fr>
1111 Bug 556433 – assume direction = out for int * parameters
1113 * giscanner/ast.py: define a list of types for which, if passed as
1114 reference, we assume a default direction of 'out'
1115 * giscanner/transformer.py: if a type has type pointer to one of the
1116 previously defined types, and no direction is set, assume out.
1117 * tests/scanner/drawable.[ch]: added tests for guessed direction=out
1119 2008-10-15 Johan Bilien <jobi@via.ecp.fr>
1121 * tests/scanner/annotation.c: fixed a few copy-paste errors
1123 2008-10-14 Johan Bilien <jobi@via.ecp.fr>
1125 Bug 556323 – transfer-ownership is wrong for functions returning const
1128 * giscanner/transformer.py: check for a const string as return value,
1129 not just const char*. Suggested by Colin Walters
1130 * tests/scanner/annotation-1.0-expected.gir: updated expected output
1132 2008-10-14 Johan Bilien <jobi@via.ecp.fr>
1134 * girepository/ginfo.c, girepository/girepository.h: add
1135 g_union_info_find_method
1137 2008-10-14 Colin Walters <walters@verbum.org>
1139 * tests/repository/Makefile.am: Reenable repo test.
1140 * tests/repository/gitestrepo.c: Prepend search
1141 path for $(top_builddir)/gir dir so that we don't
1142 require installation for "make check" to pass.
1144 2008-10-13 Jürg Billeter <j@bitron.ch>
1146 * giscanner/glibtransformer.py:
1147 * tests/scanner/annotation-1.0-expected.gir:
1148 * tests/scanner/drawable-1.0-expected.gir:
1149 * tests/scanner/foo-1.0-expected.gir:
1150 * tests/scanner/utility-1.0-expected.gir:
1152 Support fields in GObject structs
1154 2008-10-13 Jürg Billeter <j@bitron.ch>
1156 * giscanner/ast.py: add signed integer and off_t to type_names
1158 2008-10-12 Jürg Billeter <j@bitron.ch>
1160 * giscanner/girparser.py: Parse bits attribute of fields
1162 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1164 * tests/repository/Makefile.am: run 'gitestrepo' in 'make check'
1165 * tests/repository/gitestrepo.c (main): instantiate
1166 'GCancellable' to ensure the GType is registered before using
1169 2008-10-12 Johan Bilien <jobi@via.ecp.fr>
1171 * giscanner/girparser.py: actually add the parsed constant nodes
1173 2008-10-12 Colin Walters <walters@verbum.org>
1175 * girepository/girepository.c: Don't cast DirEntry to Blob,
1176 actually look it up by offset.
1178 2008-10-12 Johan Bilien <jobi@via.ecp.fr>
1180 * giscanner/girparser.py: parse constant nodes in gir files
1182 2008-10-12 Johan Bilien <jobi@via.ecp.fr>
1184 * giscanner/transformer.py: prefix for constants have an underscore,
1185 so remove them as if they were functions, not objects.
1187 2008-10-12 Johan Bilien <jobi@via.ecp.fr>
1189 * tests/scanner/foo-1.0-expected.gir: add constants to expected gir
1192 2008-10-12 Colin Walters <walters@verbum.org>
1194 Initial patch from Jani Monoses.
1196 * girepository/gtypelib.c: Fix inverted test for success
1199 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1201 * tools/generate.c (write_callable_info): use "transfer-ownership"
1202 attribute for return values
1204 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1206 * tools/generate.c (write_callable_info): move "transfer" and
1207 "null-ok" attributes from <function> to <return-value> element
1209 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1211 * girepository/girparser.c (start_return_value): handle
1212 "transfer-ownership" attribute
1214 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1216 * girepository/girparser.c (parse_param_transfer):
1217 * tools/generate.c (write_callable_info): use "container" for
1218 container/shallow ownership transfer (not "shallow")
1220 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1222 * girepository/girparser.c (parse_param_transfer,
1223 start_parameter): Refactor handling of transfer=none/shallow/full
1224 to separate function
1226 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1228 Bug 556048 – Crash in g_irepository_find_by_gtype
1230 * girepository/gtypelib.h (BLOB_IS_REGISTERED_TYPE): added
1231 * girepository/girepository.c (find_interface): Fix
1232 find_by_gtype case to get the type name from right offset
1234 2008-10-12 Jürg Billeter <j@bitron.ch>
1236 * giscanner/girparser.py: Fix parsing transfer-ownership attribute
1239 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1241 * girepository/gtypelib.h (RegisteredTypeBlob): make
1242 'unregistered' one bit wide as everywhere else
1244 2008-10-12 Jürg Billeter <j@bitron.ch>
1246 * giscanner/glibtransformer.py:
1247 * tests/scanner/annotation-1.0-expected.gir:
1248 * tests/scanner/drawable-1.0-expected.gir:
1249 * tests/scanner/drawable.h:
1250 * tests/scanner/foo-1.0-expected.gir:
1251 * tests/scanner/utility-1.0-expected.gir:
1253 Readd class records as workaround to not break Gtk typelib
1255 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1257 * tests/types/Makefile.am: fix typo in gitesttypes namespace
1259 2008-10-12 Jürg Billeter <j@bitron.ch>
1261 * giscanner/glibtransformer.py: Don't generate <record> elements
1263 * tests/scanner/*: Update test cases
1265 2008-10-11 Colin Walters <walters@verbum.org>
1267 Bug 552858: versioning
1269 This is a big patch. You should probably remove your installation
1272 * docs/typelib-format.txt: Add nsversion entry which holds
1273 version of namespace.
1274 * girepository/girepository.h: Add 'version' parameter to
1275 g_irepository_require. This may be NULL. Normally
1276 bindings should pass an explicit version though.
1277 * girepository/girepository.c: Lots of infrastructure to
1278 support versioning. Add some more documentation. Disallow
1279 some usage of NULL namespaces.
1280 * girepository/girmodule.c: Add version parameter.
1281 * girepository/gtypelib.c: Update header size.
1282 * giscanner/ast.py: Add version to Namespace.
1283 * giscanner/girparser.py: Parse version attribute from
1284 XML, pass to Namespace.
1285 * giscanner/girwriter.py: Write out version parameter.
1286 * giscanner/transformer.py: Clean up include registration.
1287 * tests/*: Add version attribute.
1288 * tests/invoke/invoke.c: Don't try looking up test before
1289 it's loaded in repository.
1290 * tools/generate.c: Output version parameter.
1291 * gir/Makefile.am: Add 2.0 version to .gir files.
1293 2008-10-11 Colin Walters <walters@verbum.org>
1295 * giscanner/scannerlexer.l (parse_gtkdoc): Don't lose
1296 if we have mismatched parens.
1298 2008-10-11 Lucas Rocha <lucasr@gnome.org>
1300 * giscanner/girparser.py (_parse_enumeration_bitfield): fix typo
1301 on 'members' variable.
1303 2008-10-11 Colin Walters <walters@verbum.org>
1305 Bug 555947 - update annotations syntax
1307 * giscanner/ast.py: Default to None for transfer. Remove
1308 default transfers for container types; we require this to
1310 * giscanner/girwriter.py: Transfer is now 'none', 'container',
1311 'full' to match repository.
1312 * giscanner/scannerlexer.l: Annotations now are parenthesized.
1313 * giscanner/transformer.py: Update for new annotations syntax.
1316 2008-10-11 Johan Bilien <jobi@litl.com>
1318 * giscanner/scannerparser.y: ignore non-UTF-8 string constants
1320 2008-10-11 Johan Bilien <jobi@litl.com>
1322 Bug 552347: Parse #defines constants
1324 * girepository/gtypelib.c: update the list of value_size
1325 with recently defined type tags
1326 * giscanner/scannerparser.y: brought back parsing of #defined, as
1327 present in older version
1328 * giscanner/giscannermodule.c: bind gi_source_scanner_append_filename
1329 * giscanner/girwriter.py: write out constant tags in the gir
1330 * giscanner/sourcescanner.py: add accessor for const_string
1331 * giscanner/transformer.py, giscanner/glibtransformer.py: handle
1334 2008-10-11 Tommi Komulainen <tommi.komulainen@iki.fi>
1336 Bug 555946: Install a test module exercising all types, transfer
1341 * tests/types/*: Add and install a test module that has functions
1342 accepting and returning most of the basic types to enable bindings
1343 implementors to more easily test their type conversion routines.
1345 2008-10-11 Jürg Billeter <j@bitron.ch>
1347 Bug 552374: Const strings should be identified in the gir.
1349 * giscanner/transformer.py: support string memory management
1350 * tests/scanner/foo.h: use char * and const char *
1351 * tests/scanner/foo-expected.gir: test that
1353 2008-10-11 Johan Dahlin <johan@gnome.org>
1355 * giscanner/girparser.py:
1356 Also parse enums which are not glib types.
1358 2008-10-11 Lucas Rocha <lucasr@gnome.org>
1360 Bug 552370: add one more test for unsigned as a type, not as
1363 * giscanner/ast.py: add 'uint' type name for 'unsigned'.
1364 * test/scanner/foo.h: add function which uses unsigned as a type.
1365 * test/scanner/foo-expected.gir: test that.
1367 2008-10-11 Andreas Rottmann <a.rottmann@gmx.at>
1369 Bug 555712: Struct and union issues
1371 * giscanner/scannerparser.y (struct_declarator): Use information
1372 provided about the bit width of a field.
1373 * giscanner/transformer.py (Transformer._create_member): Pass the
1374 symbol's const_int member to the created field (it represents the
1376 * giscanner/girwriter.py (GIRWriter._write_field): Output 'bits'
1377 field attribute, if present.
1378 * giscanner/ast.py (Field): Add 'bits' member, specifying the
1379 width in bits of the field (only relevant for bitfields).
1382 * giscanner/transformer.py (Transformer._create_typedef_struct)
1383 (Transformer._create_typedef_union): Add calls to _create_struct()
1384 and _create_union(), respectively. This causes the scanner to
1385 generate output for fields of struct and union typedefs.
1388 2008-10-11 Jürg Billeter <j@bitron.ch>
1390 Bug 552370: unsigned not scanned properly
1392 * giscanner/scannerparser.y: combine basic types such as unsigned
1393 int and long long when scanning
1394 * tests/scanner/foo-expected.gir:
1395 * tests/scanner/foo.c: (foo_test_unsigned):
1396 * tests/scanner/foo.h: test that
1398 2008-10-11 Lucas Rocha <lucasr@gnome.org>
1400 Bug 554854: The --typelib-xml and --inject options should reuse
1401 giscanner parser/writer.
1403 * giscanner/ast.py: add constructor list to Struct and Union.
1404 Add new param in Return's contructor to define transfer.
1405 * giscanner/girparser.py: several additions to the parser in order
1406 to have parsing all nodes of the gir xml files.
1407 * tools/g-ir-scanner (typelib_xml_strip, inject): use gir parser
1408 and writer in --inject and --typelib-xml options.
1409 * giscanner/xmlwriter.py: ignore empty attributes instead of
1410 raising an error as this basically exposes a bug in GIRParser.
1411 This should be reverted as soon as the parser is fixed.
1413 2008-10-11 Lucas Rocha <lucasr@gnome.org>
1415 Bug 552376: scanner generates wrong names for enum members when
1416 there's no defined gtype.
1418 * giscanner/utils.py (strip_common_prefix): Always strip common
1419 prefix exactly up to the last "_", and not beyond.
1420 * tests/scanner/foo.h (FooEnumNoType): add FOO_ENUM_NEUF. The point
1421 here is that the first character after the last '_' should should be
1422 the same as the character in the same position on the type name.
1423 * tests/scanner/foo-expected.gir: test that
1425 2008-10-10 Lucas Rocha <lucasr@gnome.org>
1427 Bug 555293: append library_paths to LPATH env variable to work
1428 around a bug in find_library when using ldconfig.
1430 * tools/g-ir-scanner (main): ditto.
1432 2008-10-09 Lucas Rocha <lucasr@gnome.org>
1434 * girepository/girepository.c (register_internal): fix regression on
1435 invoke test case by making sure we load the global module in the
1436 typelib when dealing with inline typelibs.
1437 * girepository/gtypelib.c: a couple of coding style fixes.
1439 2008-10-06 Lucas Rocha <lucasr@gnome.org>
1441 Bug 555294: Add support for multiple shared libraries per typelib.
1443 * girepository/ginvoke.c (g_function_info_invoke),
1444 girepository/ginfo.c(g_registered_type_info_get_g_type): use
1445 g_typelib_symbol instead of g_module_symbol.
1446 * girepository/girepository.h: remove g_typelib_set_module and add
1448 * girepository/gtypelib.[ch] (find_some_symbol, _g_typelib_init,
1449 g_typelib_new_from_memory, g_typelib_new_from_const_memory,
1450 g_typelib_free, g_typelib_symbol): chnage GTypeLib to hold a list of
1451 modules instead of just one. The symbol lookup is now abstracted
1452 behind g_typelib_symbol which tries to find the passed symbol name in
1454 * giscanner/girwriter.py, tools/g-ir-scanner: change scanner to read
1455 and write shared_library attribute as a comma-separated list of libs.
1457 2008-10-06 Colin Walters <walters@verbum.org>
1459 * giscanner/transformer.py: Parse length= annotation as
1460 a parameter name, not a raw int.
1463 2008-10-03 Colin Walters <walters@verbum.org>
1465 Bug 551744: Non-GObject types aren't aggregating ctors and methods
1467 * girepository/gtypelib.c: Allow ctors/methods on struct,union,
1469 * giscanner/glibtransformer.py: Ditto, and GLibBoxed is also a
1473 2008-10-03 Colin Walters <walters@verbum.org>
1475 Bug 554576: scan problem with ev_selection_render_selection()
1477 * giscanner/transformer.py: Only do type resolution once we've
1478 scanned all types. What could happen before is that we'd strip
1479 the namespace from local type "EvSelection" => Selection, and
1480 then later pull a "Selection" from some other namespace because
1481 we hadn't yet seen the local EvSelection. This could come
1482 down to hash table ordering and other things so not easy
1483 to write a test for.
1485 2008-10-03 Lucas Rocha <lucasr@gnome.org>
1487 * giscanner/girwriter.py (_parser_member): fix the last parameter of
1488 GLibEnumMember constructor as it should be the enum member nick.
1490 2008-10-02 Colin Walters <walters@verbum.org>
1492 Bug 552961: remove this parameter for methods
1494 * giscanner/glibtransformer.py: Delete this parameter; it is
1496 * girepository/ginvoke.c: Insert this parameter for methods.
1497 * girepository/gtypelib.c: Remove no longer needed verification of
1498 method this parameter.
1501 2008-09-30 Dan Winship <danw@gnome.org>
1503 Bug 554490: g-ir-scanner gets confused by '\\'
1505 * giscanner/scannerlexer.l (chartext, stringtext): fix use of
1506 backslashes so it will correctly parse '\\' and "\\"
1508 * tests/scanner/annotation.c: add a use of '\\' to make sure that
1511 * giscanner/glibtransformer.py (GLibTransformer.count_type): typo
1513 2008-10-02 Colin Walters <walters@verbum.org>
1515 bug 552393: Note variadic functions
1517 * giscanner/scannerparser.y: Parse ellipsis. Refactor grammar
1518 to use parameter_list directly.
1519 * giscanner/sourcescanner.h: Add ellipsis csymbol type.
1520 * giscanner/ast.py: Add Varargs type.
1521 * giscanner/transformer.py: Check for ellipsis symbol, transform
1523 * girepository/girnode.h: Add varargs flag to in-memory nodes.
1524 Parse varargs functions, but filter them out before we start
1525 compiling the typelib.
1527 2008-10-02 Colin Walters <walters@verbum.org>
1529 Bug 554632: type tag for GType
1531 * girepository/girepository.h, girepository/girepository.c:
1532 Add type tag for GType - it's a special type we don't want
1533 to resolve to just "long".
1534 * docs/typelib-format.txt: Update.
1535 * girepository/girparser.c: Parse it.
1536 * giscanner/glibtransformer.py: Ensure we don't put GType in
1538 * tools/generate.c: Remove hardcoded type list.
1541 2008-09-30 Dan Winship <danw@gnome.org>
1543 Bug 554521: scanner generates wrong names for enum members with
1544 full type name prefix
1546 * giscanner/utils.py (strip_common_prefix): Fix this to strip the
1547 right amount when the entire "first" string is a prefix of
1550 * tests/scanner/foo.h (FooEnumFullname):
1551 * tests/scanner/foo-expected.gir: test that
1553 2008-09-29 Colin Walters <walters@verbum.org>
1555 Bug 552380: Array parameters should be marked in the gir
1557 * giscanner/ast.py: Default char** to utf8[], and guchar* to
1558 uint8[]. Add Array, List, and Map subclasses of Type;
1559 these types can be generic. Return transfer defaults
1560 to true if return value is string or container type.
1561 Delete Sequence type.
1562 * giscanner/scannerlexer.l: Syntax change for annotations;
1563 use <> since it's more readable.
1564 * giscanner/girwriter.py: Write out these changes.
1565 * giscanner/girparser.py: Parse them.
1566 * giscanner/transformer.py: Have a defined set of
1567 both list and map types. When creating a type,
1568 check if the ctype we've parsed is one of them,
1569 if so create a container type subclass as appropriate.
1570 * girepository/girparser.c: Parse in generic types.
1573 2008-09-27 Colin Walters <walters@verbum.org>
1575 * tools/g-ir-scanner: Add --inject option.
1577 2008-09-25 Colin Walters <walters@verbum.org>
1579 Remove non-repository types from GIR
1581 * giscanner/ast.py: The canonical name is 'utf8', not
1583 * giscanner/glibast.py: A few more glib type mappings.
1584 * girepository/girparser.c: We only parse repository types.
1585 * tests/*.gir: Update.
1587 2008-09-23 Colin Walters <walters@verbum.org>
1589 Bug 552566: Add time_t type
1591 We need a type for time_t since it's special in C, and just
1592 mapping it to long precluded bindings from handling it
1595 2008-09-19 Colin Walters <walters@verbum.org>
1597 Bug 552390: Handle capitialization like "DBus" more robustly
1599 The to_underscores function was designed for use against prefixed
1600 names; we need a separate function which will convert names like
1601 DBusFoo into dbus_foo, not d_bus_foo.
1603 2008-09-19 Colin Walters <walters@verbum.org>
1605 Add check to make sure we're not hitting out unresolved types
1607 Validate the "this" argument for methods
1609 Remove heuristic matching of methods to classes based on prefix
1611 It was a broken hack that dated from when we handled underscoring
1612 and capitalization conventions less well.
1614 2008-09-18 Colin Walters <walters@verbum.org>
1616 Bug 552384: Use SHLIB_SUFFIX intead of G_MODULE_SUFFIX for Darwin
1618 On Darwin, the suffix for installed shared libraries (.dylib) is
1619 different from loadable modules (.so). We use a bit of magic shell
1620 script from Behdad Esfahbod to figure out the right suffix.
1622 2008-09-15 Johan Dahlin <johan@gnome.org>
1624 * giscanner/sourcescanner.py (SourceType.type_qualifier): Add
1625 a wrapper for type_qualifier as well.
1627 2008-09-15 Colin Walters <walters@verbum.org>
1629 http://bugzilla.gnome.org/show_bug.cgi?id=552065
1631 * giscanner/ast.py: Add deprecation attributes.
1632 * giscanner/girwriter.py: Write out deprecation data.
1633 * girepository/girparser.c: Relax parsing; deprecated
1634 attribute now includes freeform string.
1635 * giscanner/scannerlexer.l: Parse Deprecated.
1636 * giscanner/transformer.py: Look for deprecated attribute
1638 * tests/scanner/*: Add a Deprecated test.
1640 2008-09-14 Tor Lillqvist <tml@novell.com>
1642 * tests/scanner/Makefile.am (%.typelib): Use $(EXEEXT).
1644 2008-09-14 Colin Walters <walters@verbum.org>
1646 * giscanner/glibtransformer.py: Ignore functions with
1649 2008-09-12 Colin Walters <walters@verbum.org>
1651 * giscanner/glibtransformer.py: Accept Gtk.Type as GType.
1653 2008-09-12 Colin Walters <walters@verbum.org>
1655 * giscanner/ast.py: Bind pid_t to INT for vte.
1657 2008-09-12 Colin Walters <walters@verbum.org>
1659 * giscanner/girparser.py: Parse c:type for boxed records/unions.
1660 * giscanner/glibast.py: Avoid overwriting ctype.
1661 * giscsanner/transformer.py: Try resolving types using the GType names.
1663 2008-09-12 Colin Walters <walters@verbum.org>
1665 * giscanner/minixpath.py: Code to run an "XPath"
1666 assertion against an XML tree, taken from
1667 gir-repository/gir/tests.py.
1668 * giscanner/Makefile.am: Ship it.
1669 * tools/g-ir-scanner: Add --xpath-assertions option.
1670 * gir/GLib-assertions.txt: Add a few assertions.
1671 * gir/Makefile.am: Run them.
1673 2008-09-11 Colin Walters <walters@verbum.org>
1675 http://bugzilla.gnome.org/show_bug.cgi?id=551737
1677 * giscanner/transformer.py: Fix strip_namespace_func to only strip
1678 prefix if it ends with _. Tweak callback stripping to determine
1679 based on presence of _ whether we need to use strip_namespace_func
1680 or strip_namespace_object.
1682 2008-09-09 Owen Taylor <otaylor@redhat.com>
1684 * docs/typelib-format.txt: Wether => Whether
1686 2008-09-08 Colin Walters <walters@verbum.org>
1688 * girepository/girparser.c: Default to "readable" for properties.
1689 * giscanner/ast.py: Add readable, writable etc.
1690 * giscanner/girwriter.py: Writ them.
1691 * giscanner/glibtransformer.py: Inspect them.
1694 2008-09-07 Colin Walters <walters@verbum.org>
1696 * giscanner/cgobject.py: Add comment.
1698 2008-09-07 Colin Walters <walters@verbum.org>
1700 * giscanner/cgobject.py: Also call g_thread_init.
1702 2008-09-07 Colin Walters <walters@verbum.org>
1704 * giscanner/transformer.py: Fix regression by not
1705 stripping prefix before stripping namespace for unions
1708 2008-09-06 Colin Walters <walters@verbum.org>
1710 * giscanner/transformer.py: If a namespace contains
1711 multiple caps, try stripping both gnomekeyring_ and
1714 2008-09-07 Johan Dahlin <johan@gnome.org>
1716 Bug 551162 – giscanner does not recognize asm and __asm__
1717 * giscanner/scannerlexer.l:
1718 Patch by Jani Monoses.
1720 2008-09-06 Colin Walters <walters@verbum.org>
1722 * girepository/girnode.c: Allow gtype_name
1723 and gtype_init in struct and union.
1724 * girepository/girparser.c: Parse glib:
1725 boxed bits for both structure and union.
1726 * girepository/gtypelib.c: Don't barf
1727 if structure is boxed.
1728 * giscanner/girparser.py: Parse new XML
1730 * giscanner/girwriter.py: Write out new
1732 * giscanner/glibast.py: Define new classes
1733 which are both Boxed and Struct/Union, as
1734 well as an "Other" for everything else.
1735 * giscanner/glibtransformer.py: Handle
1736 boxed types specially; we try to merge
1737 them with a struct/union if one exists,
1738 otherwise fall back to generic boxed.
1740 * tools/generate.c: Write out new format.
1742 2008-09-06 Johan Dahlin <johan@gnome.org>
1744 * giscanner/grealpath.h: Include stdlib.h
1746 * docs/g-ir-generate.1: Remove leading %
1748 2008-09-01 Colin Walters <walters@verbum.org>
1750 * girepository/girparser.c: Look at c:type to determine
1751 whether or not an item is a pointer.
1753 2008-09-01 Johan Dahlin <johan@gnome.org>
1755 * tests/scanner/Makefile.am:
1756 Set PYTHONPATH so the scanner can run
1757 even if you didn't install anything.
1759 2008-09-01 Johan Dahlin <johan@gnome.org>
1762 Post-release version bump
1765 2008-09-01 Johan Dahlin <johan@gnome.org>
1769 2008-08-31 Colin Walters <walters@verbum.org>
1771 * giscanner/glibtransformer.py: Quiet info
1774 2008-08-31 Johan Dahlin <johan@gnome.org>
1777 Bump version to 0.5.0
1779 2008-08-31 Colin Walters <walters@verbum.org>
1781 * giscanner/glibtransformer.py: Follow aliases to ensure
1782 we don't get a constructor returning a basic type.
1783 * giscanner/transformer.py: Add function to follow aliases.
1786 2008-08-31 Johan Dahlin <johan@gnome.org>
1788 * giscanner/scannerlexer.l:
1789 * giscanner/scannerparser.y:
1790 * giscanner/sourcescanner.h:
1791 * giscanner/sourcescanner.py:
1792 Parse GCC extensions in the parser instead of just undeffing them
1793 in the pre-processor.
1795 2008-08-31 Johan Dahlin <johan@gnome.org>
1797 * giscanner/glibtransformer.py:
1798 Clean up a huge if. Do not add methods or constructors
1800 * giscanner/utils.py:
1801 second might be longer than first, check that.
1803 2008-08-31 Johan Dahlin <johan@gnome.org>
1808 2008-08-31 Colin Walters <walters@verbum.org>
1810 * girepository/girparser.c: Don't lose if we
1813 2008-08-31 Colin Walters <walters@verbum.org>
1815 * giscanner/glibtransformer.py: Look for libtool
1816 library in current directory
1817 * tests/scanner - Update.
1819 2008-08-30 Colin Walters <walters@verbum.org>
1821 * docs/typelib-format.txt: Add a guint32
1823 * gir/Makefile.am: Dep on Makefile
1824 * girepository/ginfo.c:
1825 * girepository/girepository.c: Clean up
1826 default typelib handling; remove global
1827 default_typelib variable. Ensure we handle
1828 NULL repository in more places.
1829 Support dependency resolution.
1830 Support lazy loading.
1831 * girepository/girepository.h: Remove
1832 g_irepository_unregister; we don't support
1833 unloading typelibs since really they're
1834 process-global. Update for lazy loading
1836 * girepository/girmodule.c: Use g_new0.
1837 Add dependencies to GirModule.
1838 * girepository/girparser.c: Parse dependencies.
1839 * girepository/gtypelib.c: Add 4 bytes for
1841 * tests/Makefile.am: Kill off gobject.gir,
1842 it conflicts with the real one.
1843 * tests/object.gir: Dep on GObject.
1844 * tools/generate.c: Take --includedir
1845 argument to say which directories to search
1846 for typelibs. Print out dependencies.
1848 2008-08-30 Colin Walters <walters@verbum.org>
1850 * giscanner/glibtransformer.py: Reduce warning noise.
1852 2008-08-29 Colin Walters <walters@verbum.org>
1854 * girepository/ginfo.c: Add some assertions regarding
1855 refcounts, just to be sure.
1856 * giscanner/glibtransformer.py: Blacklist a few more
1859 2008-08-29 Colin Walters <walters@verbum.org>
1861 * giscanner/glibtransformer.py: Blacklist a few
1862 functions that use GError oddly
1864 2008-08-29 Colin Walters <walters@verbum.org>
1866 * girepository/gtypelib.c: Don't crash if no
1869 2008-08-29 Colin Walters <walters@verbum.org>
1871 * girepository/girparser.c: Handle chains of aliases
1872 across modules by ensuring we fully qualify aliases
1875 2008-08-29 Colin Walters <walters@verbum.org>
1877 * girepository/girparser.c: Don't search aliases
1880 2008-08-29 Colin Walters <walters@verbum.org>
1882 * girepository/girparser.c: Rewrite type parsing
1883 to handle both GLib parsing case as well as correctly
1884 handling GLib.List and friends. Don't try to treat
1885 e.g. ListStore as a List.
1887 2008-08-29 Colin Walters <walters@verbum.org>
1889 * girepository/gtypelib.c: Add more context
1892 2008-08-29 Colin Walters <walters@verbum.org>
1894 * giscanner/glibtransformer.py: Add some informative
1895 logging messages in corner cases. Be sure we use
1896 the most recent node set instead of a cache
1897 when generating result set.
1898 * tests/: Remove duplicated bits in expected girs
1899 * girepository/girparser.c: Accept both List (for
1900 compiling GLib) and GLib.List (what the scanner
1903 * tools/generate.c: Generate canonical form.
1905 2008-08-29 Johan Dahlin <johan@gnome.org>
1907 * giscanner/config.py.in:
1908 Use datarootdir instead of datadir to avoid
1909 an autoconf warning.
1911 2008-08-29 Johan Dahlin <johan@gnome.org>
1915 * examples/gdk-pixbuf.gidl:
1917 Update and remove old cruft.
1919 2008-08-29 Johan Dahlin <johan@gnome.org>
1922 * docs/g-ir-compiler.1:
1923 * docs/g-ir-generate.1:
1924 * docs/g-ir-scanner.1:
1925 Add man pages for the generator and compiler.
1927 2008-08-29 Johan Dahlin <johan@gnome.org>
1929 * docs/g-ir-scanner.1: Document
1931 * giscanner/Makefile.am:
1932 * giscanner/gidlparser.py:
1933 * giscanner/gidlwriter.py:
1934 * tools/g-ir-scanner:
1935 Remove gidl support.
1937 2008-08-28 Colin Walters <walters@verbum.org>
1939 * tests/scanner/Makefile.am: Pass the right
1940 --includedir args. Add a Makefile dep.
1941 * tools/compiler.c: Pass includedirs down.
1942 * girepository/girparser.c: Actually put
1943 includedirs in context, pass down. Fix
1946 2008-08-28 Colin Walters <walters@verbum.org>
1948 * gir/Makefile.am: Use --includedir
1949 * girepository/girparser.c: Recursively parse
1950 includes to pull in aliases and expand them.
1951 We need this to avoid putting unknown names in
1953 * tools/compiler.c: Add --includedir option.
1954 * giscanner/ast.py: Map size/ssize to types
1957 2008-08-28 Tor Lillqvist <tml@novell.com>
1959 Make check now runs successfully on Windows.
1961 * tools/compiler.c (write_out_typelib): Use binary mode for output
1964 * girepository/girnode.c: Don't print NULL strings.
1966 * tests/invoke/Makefile.am
1967 * tests/scanner/Makefile.am: Use -no-undefined on Windows to
1968 convince libtool to build shared libraries.
1970 * tests/invoke/invoke.c: Don't needlessly include <dlfcn.h>. Use
1971 g_assert() instead of printing out expected errors.
1973 2008-08-28 Tor Lillqvist <tml@novell.com>
1975 * girepository/gtypelib.h: Change type of bitfield fields from
1976 guint to the most suitable smaller type. This makes the struct
1977 sizes match the ones on Linux that the sanity check expects when
1978 using gcc -mms-bitfields on Windows.
1980 2008-08-28 Johan Dahlin <johan@gnome.org>
1985 * giscanner/Makefile.am:
1986 * tests/Makefile.am:
1987 * tests/scanner/Makefile.am:
1988 Make distcheck pass.
1990 2008-08-27 Johan Dahlin <johan@gnome.org>
1992 * giscanner/Makefile.am:
1993 Only send in -no-undefined on Win32 as it breaks on MacOS X.
1995 2008-08-27 Tor Lillqvist <tml@novell.com>
1997 Make g-ir-scanner work on Windows. Still problems with the typelib
1998 code. Changes okayed by jdahlin.
2000 * configure.ac: Check for Windows, set Automake conditional
2001 OS_WIN32. Change backslashes to forward slashes in pyexecdir to
2002 avoid shell quoting issues
2004 * girepository/Makefile.am: Use -no-undefined so that libtool
2005 agrees to build a shared library on Windows.
2007 * girepository/girparser.c (backtrace_stderr): No backtrace() on
2008 Windows. Empty implementation on Windows so far.
2010 * girepository/gtypelib.c (g_typelib_check_sanity): Give more
2011 informative error message for the assertion failures. Tell also
2012 what the expected size of the struct is. Check all sizes first and
2013 fail afterwards if at least one size was different from expected.
2015 * tools/Makefile.am: Reorder libraries into proper logical
2018 * tools/generate.c: Don't include <dlfcn.h>, not used.
2020 * giscanner/Makefile.am: On Windows, link with the Python library,
2021 and install the module DLL as _giscanner.pyd. Remove the
2022 unnecessary import library and libtool library that libtool has
2025 * giscanner/scannerlexer.l: Recognize the gcc __attribute__ syntax
2026 and just skip it. Recognize also two "l" suffixes for long long
2027 constants. Recognize also __inline__.
2029 * giscanner/grealpath.h (g_realpath): Implement on Windows, using
2030 GetFullPathName(). As such, GetFullPathName() does more than the
2031 UNIX realpath(). It also changes relative paths into absolute
2032 paths. But for our purposes that shouldn't matter.
2034 * giscanner/giscannermodule.c (pygi_source_scanner_parse_file): On
2035 Windows the file descriptor passed to us is from Python. Python
2036 Python2.5 uses the msvcr71.dll C library, while mingw-built code
2037 uses msvcrt.dll. On Windows, file descriptors are specific to
2038 which C library is used. So we must find out what underlying OS
2039 handle corresponds to the file descriptor Python passes us, and
2040 then make that into a file descriptor valid for the C library this
2043 * giscanner/sourcescanner.py (_parse): Don't need to bypass
2044 __attribute__ as the lexer now handles it. The definition as empty
2045 was ineffective for mingw anyway, as mingw's _mingw.h undefines
2046 __attribute__. Close the temp file before unlinking it.
2048 * giscanner/cgobject.py: Use correct library name for the gobject
2051 * gir/Makefile.am: Must pass the full basename of the DLLs on
2052 Windows to g-ir-scanner. It's a bit ugly that we have to "know"
2053 that the names of the GLib DLLs are like libglib-2.0-0.dll, but in
2054 reality they won't change, until there is a GLib 3, and then also
2055 the Unix code here needs changing.
2057 Must pass CPPFLAGS to g-ir-scanner when building GLib.gir so that
2060 2008-08-26 Colin Walters <walters@verbum.org>
2062 * girepository/girepository.c: Search
2063 $DATADIR/girepository instead of
2064 $DATADIR/gitypelibs; this naming makes
2065 it clearer that e.g. jgir can install
2067 * gir/Makefile.am: Install there.
2069 2008-08-26 Colin Walters <walters@verbum.org>
2071 * girepository/gtypelib.c (_g_typelib_init): Also
2072 use G_MODULE_SUFFIX instead of hardcoding .so.
2074 2008-08-26 Colin Walters <walters@verbum.org>
2076 * girepository/gtypelib.c (_g_typelib_init): Free
2077 string in the right place.
2079 2008-08-26 Colin Walters <walters@verbum.org>
2081 * girepository/gtypelib.c (_g_typelib_init): Handle
2082 both .la and .so names; this works better in the
2083 uninstalled library case.
2085 2008-08-26 Johan Dahlin <johan@gnome.org>
2088 * giscanner/Makefile.am:
2089 * giscanner/cgobject.py:
2090 * giscanner/config.py.in:
2091 * giscanner/sourcescanner.py:
2092 Avoid undeffing __GNUC__, instead define
2093 __attribute__ & friends. Remove glibconfig.h hack.
2094 This makes gobject-introspection work better on
2095 MacOS X, Thanks to Richard Hult for kind help.
2097 2008-08-25 Colin Walters <walters@verbum.org>
2099 * giscanner/glibtransformer.py: Always print
2102 2008-08-25 Colin Walters <walters@verbum.org>
2104 * giscanner/glibtransformer.py: Skip over
2105 interfaces we don't know.
2107 2008-08-25 Colin Walters <walters@verbum.org>
2109 * girepository/girparser.c: Parse new implements
2110 syntax, drop gapi one.
2111 * tests/object.gir: Update.
2112 * tools/generate.c: Generate new syntax.
2114 2008-08-25 Colin Walters <walters@verbum.org>
2116 * giscanner/ast.py: Add interfaces property
2118 * giscanner/girwriter.py: Write out implemented
2120 * giscanner/glibtransformer.py: Introspect
2121 implemented interfaces.
2122 * tests/scanner/*: Make FooObject implement
2125 2008-08-25 Colin Walters <walters@verbum.org>
2127 * giscanner/glibtransformer.py: More correctly pair
2128 methods; if we have a symbol that starts with
2129 e.g. hippo_canvas look for a matching HippoCanvas
2130 class before accepting e.g. HippoCanvasImage.
2132 2008-08-24 Colin Walters <walters@verbum.org>
2134 * tools/g-ir-scanner: Filter out unknown options from
2137 2008-08-24 Colin Walters <walters@verbum.org>
2139 * giscanner/glibtransformer.py: Fail with better
2140 error if we can't find library.
2142 2008-08-24 Colin Walters <walters@verbum.org>
2144 * tools/g-ir-scanner: Use subprocess instead of
2145 commands, works on Windows and avoids the evil
2148 2008-08-24 Colin Walters <walters@verbum.org>
2150 * giscanner/glibtransformer.py: Skip over
2151 g_object_get_type from GLib trunk.
2153 2008-08-24 Colin Walters <walters@verbum.org>
2155 * girepository/girepository.c (g_irepository_require):
2156 Don't open shared library here; we already do it
2159 2008-08-24 Colin Walters <walters@verbum.org>
2161 * girepository/gtypelib.c: Add context stack so
2162 when we get an error we can print out nicely
2165 2008-08-24 Johan Dahlin <johan@gnome.org>
2167 * girepository/girparser.c (start_glib_boxed), (start_function),
2168 (start_field), (start_alias):
2169 Refactor a couple of parsing functions to be simpler to follow.
2172 2008-08-24 Johan Dahlin <johan@gnome.org>
2174 * girepository/girparser.c (start_function):
2175 Remove left-over code, checking type of function.
2177 2008-08-23 Colin Walters <walters@verbum.org>
2179 * giscanner/config.py: Define DATADIR.
2180 * giscanner/transformer.py: Look in DATADIR.
2182 2008-08-23 Colin Walters <walters@verbum.org>
2184 * girepository/gtypelib.c: Check constructor
2186 * girepository/girnode.c: Small tweaks.
2187 * girepository/ginfo.c: Calculate signature offsets
2189 * girepository/girparser.c: Remove duplicate
2191 * giscanner/glibtransformer.py: Avoid marking
2192 functions which return a basic type as
2195 2008-08-23 Colin Walters <walters@verbum.org>
2197 * girepository/girparser.c: Ignore <include>.
2198 * giscanner/girparser.py: Parse them.
2199 * giscanner/girwriter.py: Generate them.
2200 * giscanner/transformer.py: Process <include>
2201 recursively. Don't require full path for
2202 includes, look in {$XDG_DATA_DIRS}/gir.
2203 * tools/g-ir-scanner: Pass through includes.
2204 * Makefile.am: Remove extra --include
2206 * *-expected.gir: Add expected includes.
2208 2008-08-23 Johan Dahlin <johan@gnome.org>
2210 * tests/scanner/Makefile.am:
2211 * tests/scanner/annotation-expected.gir:
2212 * tests/scanner/drawable-expected.gir:
2213 Avoid duplication in the Makefile, regenerate with new
2214 namespaces (same as the filename)
2216 2008-08-22 Colin Walters <walters@verbum.org>
2218 * girepository/girnode.c: Don't hardcode integers,
2221 2008-08-22 Johan Dahlin <johan@gnome.org>
2223 * giscanner/sourcescanner.py:
2224 Check for ../gobject-introspection-1.0.pc.in to determine
2225 if we run installed or uninstalled.
2227 2008-08-22 Johan Dahlin <johan@gnome.org>
2230 * giscanner/sourcescanner.py:
2231 Send in undefs/defines via writing it directly to stdin
2232 of cpp instead of via arguments.
2234 2008-08-22 Colin Walters <walters@verbum.org>
2236 * tools/generate.c, tools/compiler.c: Default
2238 * all Makefile.am: Update.
2240 2008-08-22 Colin Walters <walters@verbum.org>
2242 * girepository/girparser.c: Pass through
2243 recursive types. Avoid overwriting errors.
2244 * giscanner/xmlwriter.py: Always write the
2246 * tests/*.gir: Adjust.
2247 * tests/scanner/Makefile.am: Build typelibs,
2248 and generate XML from those. Once we
2249 have a good diff mechanism...
2250 * tests/scanner/*-expected.gir: Add XML
2252 * tools/g-ir-scanner: Accept --typelib-xml
2254 * tools/generate.c: Better defaults for transfer.
2256 2008-08-22 Johan Dahlin <johan@gnome.org>
2260 * giscanner/Makefile.am:
2261 * giscanner/config.py.in:
2262 * giscanner/sourcescanner.py:
2263 Use the generated glibconfig.h for all scanner invokations.
2264 Rename it to glibconfig-scanner.h and install it.
2265 Add a config.py which so far contains the include dir.
2267 2008-08-22 Johan Dahlin <johan@gnome.org>
2270 Replace glibconfig.h with our own, do some replacement
2271 for CPP/C features we do not support
2273 2008-08-22 Colin Walters <walters@verbum.org>
2275 * tools/generate.c (write_callable_info): Fix unref
2278 2008-08-22 Colin Walters <walters@verbum.org>
2280 * gobject-introspection-1.0.pc.in: Add g-ir-generate.
2281 * tests/Makefile.am: Support $(DEBUG)
2282 * tools/generate.c: Do immediate close tags if no
2285 2008-08-21 Colin Walters <walters@verbum.org>
2287 * tests/scanner/drawable-expected.gir,
2288 * tests/scanner/drawable.c,
2289 * tests/scanner/drawable.h:
2292 2008-08-21 Colin Walters <walters@verbum.org>
2294 * giscanner/glibtransformer.py: Compute prefix
2295 by searching through the symbol for bits
2296 rather than going directly from ctype; this fixes
2299 2008-08-21 Colin Walters <walters@verbum.org>
2301 * giscanner/glibtransformer.py: Also try squashing
2302 underscores from namespace, fixes webkit_web_view_new.
2304 2008-08-21 Colin Walters <walters@verbum.org>
2306 * giscanner/glibtransformer.py: More ctor work,
2307 avoid having gtk_window_group_new end up under
2310 2008-08-21 Colin Walters <walters@verbum.org>
2312 * giscanner/glibtransformer.py: Much simpler approach
2313 of mapping uscored names to classes.
2314 * giscanner/utils.py: Remove unnecessary function.
2316 2008-08-21 Johan Dahlin <johan@gnome.org>
2318 * girepository/girepository.c (g_irepository_require):
2319 Plug memory leak and avoid using freed memory.
2320 Resolve the whole module path, here as well.
2322 2008-08-21 Colin Walters <walters@verbum.org>
2324 * giscanner/glibtransformer.py: Look up all permutations
2325 of class names when scanning methods/ctors based on
2326 the prefix instead of using the return value. This
2327 associates gtk_window_new with the right class.
2329 2008-08-21 Colin Walters <walters@verbum.org>
2331 * girepository/girmodule.c (g_ir_module_build_typelib):
2332 Revert change to increment header_size; we do that in
2335 2008-08-21 Colin Walters <walters@verbum.org>
2337 * girepository/girnode.c (write_string): Tweak to
2338 use UINT instead of INT. Not likely to matter.
2339 * girepository/girmodule.c (g_ir_module_build_typelib):
2340 Add to header_offset as well for header strings
2341 to match what write_string does.
2342 * girepository/gtypelib.c: Replace is_name with
2343 validate_name, which more strongly validates and
2344 handles errors in a better way. Update all callers.
2345 * giscanner/glibtransformer.py: Handle constructors
2348 2008-08-21 Johan Dahlin <johan@gnome.org>
2350 * gir/Makefile.am (typelibs_DATA): Build and
2351 install the Gio.typelib too
2353 * girepository/gtypelib.c (_g_typelib_init):
2354 Use g_module_build_path to resolve the shlib name
2356 2008-08-21 Colin Walters <walters@verbum.org>
2358 * gir/Makefile.am: CLEANFILES typelibs too.
2360 2008-08-21 Johan Dahlin <johan@gnome.org>
2362 * giscanner/glibtransformer.py:
2363 Do not send .la files through find_library.
2365 2008-08-21 Colin Walters <walters@verbum.org>
2367 * girepository/girparser.c (g_irepository_require):
2368 Fix one small leak in error case.
2370 2008-08-21 Johan Dahlin <johan@gnome.org>
2373 Parse glibconfig.h as well and install the compiled
2376 2008-08-21 Johan Dahlin <johan@gnome.org>
2379 * giscanner/glibtransformer.py:
2380 * tools/g-ir-scanner:
2381 Do not hard-core library names in the Makefile, reuse
2382 ctypes find_library instead.
2384 2008-08-21 Johan Dahlin <johan@gnome.org>
2386 * girepository/girparser.c (resolve_aliases):
2387 Remove compilation warnings
2389 2008-08-21 Johan Dahlin <johan@gnome.org>
2391 * girepository/girepository.c (g_irepository_require):
2392 Rewrap and fix double free bug by leaking a bit.
2394 2008-08-20 Colin Walters <walters@verbum.org>
2396 * girepository/girepository.c: Add new function
2397 g_irepository_get_typelib_path which tells
2398 us from where we loaded a namespace.
2400 2008-08-20 Colin Walters <walters@verbum.org>
2402 * tests/scanner/*-expected.gir: Adjust for
2403 added shared-library.
2404 * giscanner/giwriter.py: Make pylint happy.
2406 2008-08-20 Colin Walters <walters@verbum.org>
2408 * girepository/girmodule.c (g_ir_module_build_typelib):
2409 Calculate size correctly, avoid use-after-free.
2411 2008-08-20 Colin Walters <walters@verbum.org>
2413 * girepository/girepository.c: Remove
2414 g_irepository_register_file in favor of
2415 g_irepository_require. There are two
2416 possible deployment scenarios for typelibs:
2417 First, separate in $DATADIR/gitypelibs/. Second,
2418 they may be embedded in shlibs. However since
2419 the first is now the normal case, the API is
2420 optimized around it.
2422 Refactor internals to look up typelibs for
2423 namespaces just-in-time, but we expect
2424 consumers to call g_irepository_require.
2426 Also, add some docs. No one has died from that
2428 * gir/Makefile.am: Need --library for glib.
2429 * giscanner/girwriter.py: Write out shared-library.
2430 * tools/g-ir-writer: Take the first --library
2431 argument as the target of shared-library. In
2432 the future we should make this nicer with pkg-config
2435 2008-08-20 Colin Walters <walters@verbum.org>
2437 * girepository/girparser.py: And parse them.
2439 2008-08-20 Johan Dahlin <johan@gnome.org>
2441 * giscanner/glibast.py: Add gshort/gushort types
2443 2008-08-20 Colin Walters <walters@verbum.org>
2445 * gir/Makefile.am: Rename .gir files using GI namespace.
2446 * girepository/girepository.c: Use XDG_DATA_DIRS for
2447 looking up typelibs. Also typelibs are now suffixed
2449 * tests/invoke/Makefile.am: Only use metadata.
2450 * girepository/Makefile.am: Remove unnecessary include.
2451 * tests/scanner/Makefile.am: Update using GI namespaces
2452 for scanner includes.
2454 2008-08-20 Colin Walters <walters@verbum.org>
2456 * girepository/transformer.py: Suppress aliases whose
2458 * girepository/ast.py: Define some more aliases.
2460 2008-08-20 Colin Walters <walters@verbum.org>
2462 * girepository/girparser.c: Avoid alias infloops.
2464 2008-08-20 Colin Walters <walters@verbum.org>
2466 * tests/scanner/foo-expected.gir: Fix expected list type.
2468 2008-08-20 Johan Dahlin <johan@gnome.org>
2470 * giscanner/glibtransformer.py (GLibTransformer._resolve_type_name):
2471 Add a workaround for #548689.
2472 We can now compile gtk!
2474 2008-08-20 Colin Walters <walters@verbum.org>
2476 * giscanner/glibtransformer.py: Try to look up
2477 aliases using the c:type too.
2479 2008-08-20 Colin Walters <walters@verbum.org>
2481 * girepository/girparser.c: Parse union fields.
2483 2008-08-20 Johan Dahlin <johan@gnome.org>
2485 * giscanner/ast.py: Make time_t an alias for long
2487 * gir/gio-2.0-good.gir:
2488 * gir/glib-2.0-good.gir:
2489 * gir/gobject-2.0-good.gir:
2491 * giscanner/glibtransformer.py:
2492 Do not delete Class structures, we need them in gdk/gtk.
2493 * tests/scanner/drawable-expected.gir:
2494 * tests/scanner/foo-expected.gir:
2495 * tests/scanner/utility-expected.gir:
2498 2008-08-20 Johan Dahlin <johan@gnome.org>
2500 * tests/scanner/Makefile.am:
2501 * tests/scanner/annotation-expected.gir:
2502 * tests/scanner/annotation.c (annotation_object_class_init),
2503 (annotation_object_init), (annotation_object_method),
2504 (annotation_object_in), (annotation_object_out),
2505 (annotation_object_inout), (annotation_object_inout2),
2506 (annotation_object_inout3), (annotation_object_calleeowns),
2507 (annotation_object_calleesowns), (annotation_object_get_strings),
2508 (annotation_object_with_voidp), (annotation_object_get_objects),
2509 (annotation_object_create_object), (annotation_object_allow_none):
2510 * tests/scanner/annotation.h:
2511 * tests/scanner/foo-expected.gir:
2512 * tests/scanner/foo.c:
2513 * tests/scanner/foo.h:
2514 Split out annotation tests out of foo
2516 2008-08-20 Johan Dahlin <johan@gnome.org>
2518 * tests/scanner/Foo-expected.gir:
2519 * tests/scanner/Makefile.am:
2520 * tests/scanner/foo-expected.gir:
2521 * tests/scanner/foo-object.h:
2522 * tests/scanner/foo.c:
2523 Foo->foo, foo-object.h -> foo.h
2525 2008-08-20 Johan Dahlin <johan@gnome.org>
2527 * tests/scanner/Foo-expected.gir:
2528 * tests/scanner/Makefile.am:
2529 * tests/scanner/drawable-expected.gir:
2530 * tests/scanner/drawable.c (test_drawable_class_init),
2531 (test_drawable_init):
2532 * tests/scanner/drawable.h:
2533 * tests/scanner/foo-object.h:
2534 * tests/scanner/foo.c (foo_boxed_method):
2535 Move the drawable parts out of Foo to its own test.
2537 2008-08-20 Johan Dahlin <johan@gnome.org>
2539 * tests/scanner/Foo-expected.gir:
2540 * tests/scanner/foo-object.h:
2541 * tests/scanner/foo.c (foo_drawable_class_init),
2542 (foo_drawable_init):
2543 Add a based on GdkDrawable which generates
2546 2008-08-19 Colin Walters <walters@verbum.org>
2548 * giscanner/transformer.py: Don't try
2549 to strip prefix before namespace.
2551 2008-08-19 Johan Dahlin <johan@gnome.org>
2553 * giscanner/transformer.py:
2554 * tests/scanner/Foo-expected.gir:
2555 * tests/scanner/foo-object.h:
2556 Add support for typedef void foo type of
2559 2008-08-19 Johan Dahlin <johan@gnome.org>
2562 * giscanner/girwriter.py:
2563 * giscanner/glibtransformer.py:
2564 * giscanner/transformer.py:
2565 * tests/scanner/Foo-expected.gir:
2566 Add basic support for union, base the code much
2567 on Struct. Add a testcase.
2569 2008-08-19 Johan Dahlin <johan@gnome.org>
2571 * tests/scanner/Foo-expected.gir:
2572 * tests/scanner/foo-object.h:
2573 Add a union testcase which the compiler currently
2576 2008-08-19 Johan Dahlin <johan@gnome.org>
2578 * gobject-introspection-1.0.pc.in:
2579 Add a g_ir_compiler variable
2581 2008-08-19 Colin Walters <walters@verbum.org>
2583 * giscanner/ast.py: Rework types to be more closely
2585 * giscanner/girparser.py: Parse more bits.
2586 * giscanner/girwriter.py: Write sequences in a new
2587 way that specifies container type.
2588 * giscanner/glibast.py: Adjust for ast.py changes,
2589 add 'ctype' property to GLibObject and GLibInterface
2590 so we can look things up by it later.
2591 * gicanner/transformer.py: Names is new class holding
2592 the various namespaces we manage. Do not confuse
2593 with Namespace which is toplevel XML node effectively.
2594 Rework all type resolution to go through
2595 _resolve_type_name_1.
2596 * giscanner/glibtransformer.py: Raise UnknownTypeError
2597 instead of ValueError for cleanliness. Add Unresolved
2598 class to mark types whose parent we haven't seen yet.
2599 Use new Names object from transformer.py.
2600 Correctly look up parent=.
2601 Fix type validation to handle sequences.
2602 * tests/scanner/Foo-expected.gir: Update for sequence
2603 work, int instead of int32.
2604 * tools/g-ir-scanner: Add --noclosure option
2605 * gir/Makefile.am: Use --noclosure by default for
2608 2008-08-18 Johan Dahlin <johan@gnome.org>
2610 * gir/gio-2.0-good.gir:
2611 * gir/glib-2.0-good.gir:
2612 * gir/gobject-2.0-good.gir:
2615 2008-08-18 Johan Dahlin <johan@gnome.org>
2618 * giscanner/girparser.py:
2619 * giscanner/girwriter.py:
2620 * giscanner/glibast.py:
2621 * giscanner/glibtransformer.py:
2622 * giscanner/transformer.py:
2623 * tests/scanner/Foo-expected.gir:
2624 * tests/scanner/foo-object.h:
2625 * tests/scanner/utility-expected.gir:
2626 * tests/scanner/utility.h:
2627 Redo type resolving and validation.
2628 Add a couple of new tests.
2629 Patch mostly written by Colin.
2631 2008-08-18 Johan Dahlin <johan@gnome.org>
2634 * giscanner/girparser.py:
2636 * giscanner/transformer.py:
2637 Improve enum parsing for enums without a GType.
2638 Make flags/enum references to other girs work
2639 * giscanner/utils.py:
2641 * tests/scanner/Makefile.am:
2642 * tests/scanner/foo-object.h:
2643 * tests/scanner/utility-expected.gir:
2644 * tests/scanner/utility.h:
2645 Add a new test for external enum references
2647 2008-08-18 Johan Dahlin <johan@gnome.org>
2649 * docs/global-module-registry.txt: Update
2651 * tests/array.gir: Update with new type proposal
2653 * girepository/girepository.c (g_type_tag_to_string):
2654 * girepository/girepository.h:
2655 * girepository/girnode.c (g_ir_node_get_full_size_internal),
2657 * girepository/girnode.h:
2658 Make enum serializing functions public. Clean up some whitespace.
2660 2008-08-17 Johan Dahlin <johan@gnome.org>
2662 * docs/global-module-registry.txt:
2663 Add a document for an on disk module registry format
2665 2008-08-17 Johan Dahlin <johan@gnome.org>
2668 * gir/gio-2.0-good.gir:
2671 2008-08-17 Johan Dahlin <johan@gnome.org>
2674 * gir/glib-2.0-good.gir:
2675 * gir/gobject-2.0-good.gir:
2676 * giscanner/cgobject.py:
2677 * giscanner/glibtransformer.py:
2678 Regenerate GObject & GType.
2679 Avoid warnings when generating gobject-2.0.gir.
2680 Introspect a little more, and skip *_get_type functions.
2682 2008-08-17 Colin Walters <walters@verbum.org>
2684 * gir/glib-2.0.gir, gir/gobject-2.0.gir:
2685 Rename to -good, always generate during build.
2686 * gir/Makefile.am: Ensure .gir files dep on
2687 all scanner sources.
2688 * Makefile.am: Switch build order to ensure
2689 the scanner is ready before we do gir/.
2690 * tools/g-ir-scanner: Look for .git too.
2692 2008-08-17 Johan Dahlin <johan@gnome.org>
2694 * girepository/gtypelib.c (validate_enum_blob):
2695 * giscanner/glibtransformer.py:
2696 * giscanner/transformer.py:
2697 Remove resolve_possible_typedefs, it was unused.
2698 Allow multiple enum values of the sample value in an enum,
2699 since it's actually pretty common.
2700 Register enums so they can be resolved too.
2702 2008-08-16 Johan Dahlin <johan@gnome.org>
2704 * giscanner/girparser.py:
2705 Parse enumeration/bitfield.
2707 2008-08-16 Johan Dahlin <johan@gnome.org>
2709 * giscanner/girparser.py:
2712 2008-08-16 Johan Dahlin <johan@gnome.org>
2714 * giscanner/glibtransformer.py:
2715 Resolve type names for alias targets
2716 * giscanner/transformer.py:
2717 Skip FILE* parameters fow now
2719 2008-08-16 Johan Dahlin <johan@gnome.org>
2722 * gir/gobject-2.0.gir:
2725 * tests/scanner/Makefile.am:
2728 2008-08-15 Colin Walters <walters@verbum.org>
2730 * giscanner/glibtransformer.py: Explicitly construct
2731 new list, since we're deleting as we iterate.
2732 Don't delete all structures which end in Class; just
2733 ones which have a paired GObject.
2734 Fix printing of type warning.
2735 * giscanner/transformer.py: Make strip_namespace_object
2736 be the identity function if it doesn't match the
2739 2008-08-15 Colin Walters <walters@verbum.org>
2741 * giscanner/cgobject.py: Define yet more argument
2742 prototypes; fix prototype for g_type_fundamental.
2744 2008-08-14 Johan Dahlin <johan@gnome.org>
2746 * tests/Makefile.am:
2747 * tests/constant.gir:
2748 * tests/gobject.gir:
2750 * tools/generate.c (write_struct_info):
2751 Fix generator for constant/gobject/struct
2753 2008-08-14 Johan Dahlin <johan@gnome.org>
2755 * tests/Makefile.am:
2757 * tools/generate.c (write_enum_info):
2758 Fix generation of enum/bitfields
2760 2008-08-14 Johan Dahlin <johan@gnome.org>
2762 * girepository/girparser.c (start_field), (start_constant),
2763 (start_type), (end_element_handler):
2764 Clear up constant parsing
2769 * tools/generate.c (write_callable_info), (write_function_info),
2770 (write_callback_info), (write_constant_info), (write_signal_info),
2771 (write_vfunc_info), (write_property_info), (write_object_info),
2772 (write_interface_info):
2773 Constants/Signals are handled now.
2775 2008-08-14 Johan Dahlin <johan@gnome.org>
2777 * girepository/girparser.c (start_type):
2778 Don't require c:type.
2779 * tests/Makefile.am:
2782 Update, remove parts we don't support yet
2783 * tests/roundtrips.sh:
2785 * tools/generate.c (write_type_info), (write_field_info),
2786 (write_callable_info), (write_struct_info):
2787 Make it emit proper gir.
2789 2008-08-14 Johan Dahlin <johan@gnome.org>
2791 * giscanner/transformer.py:
2792 New internal function for adding a new node.
2794 2008-08-14 Johan Dahlin <johan@gnome.org>
2797 Define an internal _H_ variable so we skip parsing both
2798 i18n headers, only one is needed.
2800 Add the glib-2.0.gir too.
2801 * giscanner/glibast.py:
2802 Add gconstpointer as an alias for ANY
2803 * giscanner/transformer.py:
2804 Do not lower case enumeration names per se.
2805 Skip functions which has parameters called 'va_list'
2807 2008-08-14 Colin Walters <walters@verbum.org>
2809 * giscanner/transformer.py: Comment data structures.
2810 Also squash pointers in resolve_type_name to correspond
2811 with what we do for params.
2812 * giscanner/glibtransformer.py: Print warnings in more
2813 situations. Rework checks for method/constructor to
2814 look up in our GType database instead of just checking
2815 for *. Avoid generating <record> for GObject which
2816 duplicate the <class>.
2817 * gir/Makefile.am: Generate glib-2.0.gir and gobject-2.0.gir
2820 2008-08-14 Johan Dahlin <johan@gnome.org>
2822 * giscanner/girwriter.py:
2823 * giscanner/glibast.py:
2824 * giscanner/glibtransformer.py:
2825 * giscanner/transformer.py:
2827 * tests/Makefile.am:
2828 Add pyflakes.py and run it in make check.
2829 Update the source code to fix the errors reported by
2832 2008-08-14 Johan Dahlin <johan@gnome.org>
2835 * giscanner/girparser.py:
2836 * giscanner/glibast.py:
2837 * giscanner/glibtransformer.py:
2838 Refactor the parser a bit.
2839 Add parent type to interfaces and update callsites.
2841 2008-08-14 Johan Dahlin <johan@gnome.org>
2843 * giscanner/glibtransformer.py:
2844 * giscanner/utils.py:
2845 Refactor a bit, avoid isinstance and add a method
2846 for each type we parse.
2848 2008-08-14 Johan Dahlin <johan@gnome.org>
2851 * giscanner/girparser.py:
2852 * giscanner/glibtransformer.py:
2853 * tests/Makefile.am:
2854 Run pep8.py in make check, fix old errors.
2856 2008-08-13 Colin Walters <walters@verbum.org>
2858 * giscanner/girparser.py: Parse records.
2860 2008-08-13 Colin Walters <walters@verbum.org>
2862 * gir/Makefile.am: Install again.
2863 * gir/gobject-2.0.gir: Add some more bits.
2865 2008-08-13 Colin Walters <walters@verbum.org>
2867 * gir/gobject-2.0.gir: Use correct namespace, add GType.
2868 * giscanner/girparser.py: Handle aliases.
2869 * giscanner/transformer.py: Record aliases. Make resolver
2870 functions public; we now call into these explicitly from
2871 glibtransformer. Handle resolving aliases.
2872 * giscanner/glibtransformer.py: Separate our internal namespace
2873 from included ones. Call up into transformer's resolver functions.
2875 2008-08-13 Johan Dahlin <johan@gnome.org>
2877 * girepository/girnode.c (g_ir_node_get_full_size_internal):
2878 * girepository/girparser.c (start_class):
2879 * giscanner/glibtransformer.py:
2880 Allow get_type to be None, set a get_type for GInitiallyUnowned too.
2882 2008-08-13 Johan Dahlin <johan@gnome.org>
2884 * giscanner/cgobject.py:
2885 Register GInitiallyUnowned
2886 * giscanner/girwriter.py:
2887 * giscanner/glibtransformer.py:
2888 Special case GObject/GInitially owned as they are a bit special to use.
2890 2008-08-13 Colin Walters <walters@verbum.org>
2892 * tests/scanner/Foo-expected.gir, tests/scanner/utility-expected.gir:
2893 Object is in GObject namespace.
2895 2008-08-13 Colin Walters <walters@verbum.org>
2897 * giscanner/girparser.py: Fix processing of functions
2900 2008-08-13 Colin Walters <walters@verbum.org>
2902 * giscanner/girparser.py: Parse more than just <class.
2903 * giscanner/glibtransformer.py: Put aliases in a separate
2904 data structure since their name is not canonicall.
2905 * giscanner/transformer.py: Handle resolving type names
2908 2008-08-13 Johan Dahlin <johan@gnome.org>
2910 * tools/g-ir-scanner:
2911 Allow multiple libraries
2912 * giscanner/glibtransformer.py:
2913 Rename load_library to add_library, traverse over all libraries
2914 when trying to resolve a function
2916 2008-08-12 Colin Walters <walters@verbum.org>
2918 * giscanner/transformer.py: Record typedefs as <alias> elements.
2919 Also attempt to look up types in external namespaces.
2920 * giscanner/girwriter.py: Write them.
2921 * giscanner/glibtransformer.py: Rework resolver using real instanceof
2922 checks. Resolve interface methods and properties.
2923 * tests/scanner/foo-object.h: Add a method with typedef.
2924 * tests/scanner/Foo-expected.gir: Update.
2925 * girepository/girnode.c: Debug tweaks.
2926 * girepository/girparser.c: Make a first pass through the XML where we
2927 record all the aliases. This lets us resolve them as we go through the
2929 * gir/Makefile.am: Don't install gobject-2.0.gir; we want that to come
2930 from gir-repository.
2932 2008-08-12 Colin Walters <walters@verbum.org>
2934 * giscanner/glibtransformer.py: Resolve typedefs (e.g. AtkAttributeSet -> GSList).
2935 Correctly do subclasseing in 2nd pass resolution. Handle callbacks in structure
2937 * giscanner/transformer.py: Record typedefs and expose public API for resolving
2939 * tests/scanner/Foo-expected.gir: Fix expected callback types.
2941 2008-08-12 Colin Walters <walters@verbum.org>
2943 * giscanner/glibtransformer.py: Also transform object properties.
2945 2008-08-12 Colin Walters <walters@verbum.org>
2947 * giscanner/glibtransformer.py: Also transform callbacks
2948 and structure field types.
2949 * tests/scanner/Fooe-expected.gir: Update to expect correct
2950 names for callbacks and structs.
2952 2008-08-12 Colin Walters <walters@verbum.org>
2954 * girepository/girparser.c: Handle 'any'.
2955 * tests/scanner/Foo-expected.gir, tests/scanner/foo-object.h:
2956 Add test for void *.
2958 2008-08-12 Colin Walters <walters@verbum.org>
2960 * giscanner/glibtransformer.py: We need to do type
2961 resolution in a second pass after we've seen all the
2962 enums, records, etc.
2964 2008-08-12 Colin Walters <walters@verbum.org>
2966 * tests/scanner/Foo-expected.gir, tests/scanner/foo-object.h:
2967 Add enum return value.
2968 * giscanner/glibtransformer.py: Transform function return types
2971 2008-08-12 Colin Walters <walters@verbum.org>
2973 * tests/scanner/Makefile.am: Dep .gir files on scanner
2974 sources too. Also remove @ so we see scanner invocations.
2976 2008-08-12 Colin Walters <walters@verbum.org>
2978 * girepository/girparser.c, girepository/gtypelib.c,
2979 girepository/gtypelib.h, girepository/girnode.c:
2980 Remove usage of (GAPI-oriented) TypeTag in favor of
2981 GITypeTag from girepository.h.
2983 2008-08-10 Colin Walters <walters@verbum.org>
2985 * tests/roundtrips.sh: Use the correct tests.
2987 2008-08-10 Colin Walters <walters@verbum.org>
2989 * giscanner/cgobject.py: Declare/wrap a few more functions.
2990 Fix parameter types for g_object_new and g_type_fundamental.
2992 2008-08-10 Colin Walters <walters@verbum.org>
2994 * giscanner/cgobject.py: Add new decorator @gwrap which forces
2995 us to declare types for both return value and parameters. The
2996 ctypes default of 'int' is bad because it hides 32/64 bit
2997 problems. Convert all existing functions to use it.
2999 2008-08-09 Johan Dahlin <johan@gnome.org>
3001 * giscanner/__init__.py:
3003 * giscanner/cgobject.py:
3004 * giscanner/gidlparser.py:
3005 * giscanner/gidlwriter.py:
3006 * giscanner/girparser.py:
3007 * giscanner/girwriter.py:
3008 * giscanner/glibast.py:
3009 * giscanner/glibtransformer.py:
3010 * giscanner/odict.py:
3011 * giscanner/sourcescanner.py:
3012 * giscanner/transformer.py:
3013 * giscanner/utils.py:
3014 * giscanner/xmlwriter.py:
3015 * tools/g-ir-scanner:
3019 2008-08-09 Johan Dahlin <johan@gnome.org>
3022 * relaxng/c-types.xml:
3023 * relaxng/g-types.xml:
3024 * relaxng/relaxng.rng:
3026 Remove outdated relaxng schemas.
3028 2008-08-09 Johan Dahlin <johan@gnome.org>
3031 Rename metadata to typelib in variable names,
3034 2008-08-09 Johan Dahlin <johan@gnome.org>
3038 Remove old C scanner, which got rewritten in python.
3040 2008-08-09 Johan Dahlin <johan@gnome.org>
3042 * girepository/Makefile.am:
3043 * tools/Makefile.am:
3044 * tools/girmodule.c:
3045 * tools/girmodule.h:
3048 * tools/girparser.c:
3049 * tools/girparser.h:
3050 * tools/girwriter.c:
3051 * tools/girwriter.h:
3052 Move shared *.[ch] files to girepository from tools
3054 2008-08-09 Johan Dahlin <johan@gnome.org>
3056 * tests/Makefile.am:
3059 * tests/constant.test:
3061 * tests/errors.test:
3062 * tests/function.test:
3063 * tests/gobject.test:
3064 * tests/interface.test:
3065 * tests/object.test:
3066 * tests/struct.test:
3071 Rename *.test to *.gir
3073 2008-08-09 Johan Dahlin <johan@gnome.org>
3076 * tests/Makefile.am:
3077 * tests/parser/Foo-expected.gir:
3078 * tests/parser/Makefile.am:
3079 * tests/parser/foo-object.h:
3080 * tests/parser/foo.c:
3081 * tests/parser/utility-expected.gir:
3082 * tests/parser/utility.c:
3083 * tests/parser/utility.h:
3084 * tests/scanner/Makefile.am:
3085 Rename tests/parser to test/scanner
3087 2008-08-08 Colin Walters <walters@verbum.org>
3089 * tests/roundtrips.sh: Use local .gir files again.
3091 2008-08-08 Colin Walters <walters@verbum.org>
3093 * tests/invoke/Makefile.am: .gir file depends on libtool
3096 2008-08-08 Colin Walters <walters@verbum.org>
3098 * tools/girnode.c: Pass through parent node so we can
3099 print the node whose child is NULL, if that occurs.
3101 2008-08-08 Johan Dahlin <johan@gnome.org>
3103 * tests/Makefile.am:
3104 Disable roundtrip tests which are not yet working
3105 * tests/invoke/testfns.gir:
3108 2008-08-08 Johan Dahlin <johan@gnome.org>
3110 * giscanner/girwriter.py:
3112 * giscanner/glibast.py:
3113 * giscanner/glibtransformer.py:
3114 Swap order of members, to keep it consistent with
3117 2008-08-08 Johan Dahlin <johan@gnome.org>
3119 * girepository/gtypelib.c (validate_header):
3120 * girepository/gtypelib.h:
3122 * giscanner/girwriter.py:
3123 * giscanner/sourcescanner.c (gi_source_symbol_ref),
3124 (gi_source_symbol_unref):
3127 * tests/constant.test:
3129 * tests/errors.test:
3130 * tests/function.test:
3131 * tests/gobject.test:
3132 * tests/interface.test:
3133 * tests/invoke/Makefile.am:
3134 * tests/invoke/testfns.xml:
3135 * tests/object.test:
3136 * tests/parser/Makefile.am:
3137 * tests/roundtrips.sh:
3138 * tests/struct.test:
3143 * tools/Makefile.am:
3144 * tools/compiler.c (main):
3145 * tools/generate.c (write_callable_info), (write_function_info),
3147 * tools/gidlmodule.c:
3148 * tools/gidlmodule.h:
3151 * tools/gidlparser.c:
3152 * tools/gidlparser.h:
3153 * tools/gidlwriter.c:
3154 * tools/gidlwriter.h:
3155 * tools/scanner.c (create_node_from_gtype),
3156 (create_node_from_ctype), (g_igenerator_process_properties),
3157 (g_igenerator_process_signals), (g_igenerator_create_object),
3158 (g_igenerator_create_interface), (g_igenerator_create_boxed),
3159 (g_igenerator_create_enum), (g_igenerator_create_flags),
3160 (g_igenerator_process_function_symbol),
3161 (g_igenerator_process_unregistered_struct_typedef),
3162 (g_igenerator_process_struct_typedef),
3163 (g_igenerator_process_union_typedef),
3164 (g_igenerator_process_enum_typedef),
3165 (g_igenerator_process_function_typedef),
3166 (g_igenerator_process_constant), (g_igenerator_process_symbols),
3167 (g_igenerator_add_module), (g_igenerator_add_include_idl):
3168 Merge in the gir-compiler branch.
3169 Thanks to Philip and Colin for their help.
3171 2008-07-26 Colin Walters <walters@verbum.org>
3173 * tools/Makefile.am (bin_PROGRAMS): Install g-idl-compiler
3174 and g-idl-generate to go along with how we're changing this
3175 module to be installed.
3176 * gobject-introspection-1.0.pc.in: Set up Cflags and Libs.
3178 2008-07-24 Colin Walters <walters@verbum.org>
3180 * girepository/girepository.c (g_irepository_register): Add
3181 environment variable G_IREPOSITORY_VERBOSE so we can print
3182 out what we're doing.
3183 * girepository/girepository.c (g_irepository_register_file):
3184 Add GError error message to g_debug call.
3186 2008-07-08 Jürg Billeter <j@bitron.ch>
3188 * giscanner/glibast.py:
3192 2008-06-21 Johan Dahlin <jdahlin@async.com.br>
3194 * giscanner/girparser.py (GIRParser._parse_api): Ignore a few
3197 2008-06-20 Johan Dahlin <jdahlin@async.com.br>
3200 * giscanner/girwriter.py:
3201 * giscanner/transformer.py:
3202 * tests/parser/Foo-expected.gir:
3203 * tests/parser/foo-object.h:
3204 * tests/parser/foo.c (foo_object_allow_none):
3205 Add support for gtk-doc annotations for allow-none.
3208 2008-06-19 Johan Dahlin <jdahlin@async.com.br>
3211 * giscanner/girwriter.py:
3212 * giscanner/glibast.py:
3213 * giscanner/glibtransformer.py:
3214 * giscanner/transformer.py:
3215 * tests/parser/Foo-expected.gir:
3216 Start using abstract type instead of the raw C types.
3217 Register a bunch of glib types we care about.
3219 2008-06-19 Rob Taylor <rob.taylor@codethink.co.uk>
3224 2008-06-08 Philip Van Hoof <pvanhoof@gnome.org>
3226 * girepository/girepository.c:
3227 * girepository/gtypelib.c:
3228 * girepository/ginfo.c:
3229 * girepository/ginvoke.c:
3230 * girepository/girepository.h:
3231 * girepository/gtypelib.h:
3232 * girepository/gmetadata.c:
3233 * girepository/Makefile.am:
3234 * girepository/gmetadata.h:
3236 * tools/gidlmodule.c:
3239 * tools/gidlmodule.h:
3240 * tools/gidlparser.c:
3242 Renamed GMetadata to GTypelib
3244 2008-06-07 Johan Dahlin <jdahlin@async.com.br>
3246 * giscanner/xmlwriter.py:
3247 Improve line wrapping when > 79 charaters
3249 2008-06-05 Jürg Billeter <j@bitron.ch>
3252 * giscanner/girwriter.py:
3253 * giscanner/transformer.py:
3254 Use <type> element for field types
3255 * tests/parser/Foo-expected.gir:
3258 2008-06-04 Johan Dahlin <jdahlin@async.com.br>
3260 * giscanner/glibtransformer.py:
3261 Fix a bug which prevented GdkEvent from being generated
3263 2008-06-03 Johan Dahlin <jdahlin@async.com.br>
3265 * giscanner/Makefile.am:
3267 * giscanner/girwriter.py:
3268 * giscanner/glibast.py:
3269 * giscanner/glibtransformer.py:
3270 * giscanner/transformer.py:
3271 * giscanner/utils.py:
3272 * tests/parser/Foo-expected.gir:
3273 Improve enum member parsing and introspection
3275 2008-05-31 Johan Dahlin <jdahlin@async.com.br>
3277 * giscanner/scannerparser.y:
3278 * giscanner/sourcescanner.h:
3279 * giscanner/sourcescanner.py:
3280 Add a new source type enum for member.
3281 Use __repr__ for improved debugging
3282 * giscanner/girparser.py:
3284 * giscanner/transformer.py:
3285 Improve parsing of struct members.
3286 * tests/parser/foo-object.h:
3289 2008-05-31 Johan Dahlin <jdahlin@async.com.br>
3291 * giscanner/xmlwriter.py:
3292 Improve error reporting when trying to quote None.
3293 * giscanner/girparser.py:
3294 Do not print warnings when including more complete .gir files
3295 * giscanner/girwriter.py:
3296 Do not require a name for parameters, add a todo for singletons
3297 * giscanner/glibtransformer.py:
3298 Refactor the way structs are done, add a couple of hacks to allow
3300 * giscanner/transformer.py:
3301 Add enough hacks so cairo, atk and pango.gir can be parsed properly
3302 * gobject-introspection-1.0.pc.in:
3303 Export girdir, so we can access gobject-2.0.gir from outside
3305 2008-05-31 Johan Dahlin <jdahlin@async.com.br>
3307 * tools/g-ir-scanner:
3308 * tests/parser/Makefile.am:
3309 Update sys.path before running the parser so we don't have
3310 to setup PYTHONPATH ourselves.
3314 * girepository/Makefile.am:
3315 * giscanner/transformer.py:
3316 * gobject-introspection-1.0.pc.in:
3317 * gobject-introspection.pc.in:
3318 * tools/Makefile.am:
3320 Rename pkg-config name to gobject-introspection-1.0,
3321 Do not installed anything which is not using the gir format.
3322 Disable compililation the old C scanner, but still keep the source
3323 until all the remaning functionallity has been ported.
3325 2008-05-31 Johan Dahlin <jdahlin@async.com.br>
3327 * giscanner/giscannermodule.c (symbol_get_ident): Prevent
3328 a crash when symbol->indent is NULL.
3330 * giscanner/sourcescanner.py (ctype_name): Add ctype_name,
3331 a function to convert a CTYPE symbol to a string
3333 2008-05-24 Johan Dahlin <jdahlin@async.com.br>
3336 * giscanner/girwriter.py:
3337 * giscanner/giscannermodule.c
3338 (pygi_source_scanner_append_filename),
3339 (pygi_source_scanner_parse_file):
3340 * giscanner/glibtransformer.py:
3341 * giscanner/sourcescanner.py:
3342 Revert back to using temporary files to send in headers.
3343 Allow Functions to be passed in as callbacks, add a couple
3344 of try/excepts missing features.
3345 We can now scan pango
3347 2008-05-08 Johan Dahlin <johan@gnome.org>
3349 * giscanner/glibtransformer.py:
3350 * giscanner/transformer.py:
3351 Move namespace stripping glibtransformer->transformer
3353 2008-05-08 Johan Dahlin <johan@gnome.org>
3356 * giscanner/girwriter.py:
3357 * giscanner/glibtransformer.py:
3358 * giscanner/transformer.py:
3359 * tools/g-ir-scanner:
3360 Introduce a namespace ast node
3362 2008-05-05 Johan Dahlin <johan@gnome.org>
3364 * giscanner/__init__.py:
3365 * giscanner/sourcescanner.py:
3366 * giscanner/transformer.py:
3367 Move sourcescanner symbols to the sourcescanner module, instead
3368 of in the global __init__ namespace.
3370 2008-05-03 Johan Dahlin <johan@gnome.org>
3372 * giscanner/glibtransformer.py:
3373 * tools/g-ir-scanner:
3374 Handle missing parameters better, allow - and + in .la dlname
3377 2008-05-03 Johan Dahlin <johan@gnome.org>
3379 * giscanner/__init__.py:
3381 * giscanner/girwriter.py:
3382 * giscanner/glibtransformer.py:
3383 * giscanner/transformer.py:
3384 Parse struct fields properly, improve debugging.
3386 2008-04-29 Johan Dahlin <johan@gnome.org>
3389 * giscanner/girwriter.py:
3390 * giscanner/transformer.py:
3391 * tests/parser/Foo-expected.gir:
3393 Use transfer-ownership everywhere, to mark ownership/calle/caller etc.
3395 2008-04-29 Johan Dahlin <jdahlin@async.com.br>
3398 * docs/g-ir-scanner.1:
3399 * metadata-annotations-proposal.txt:
3400 * metadata-format.txt:
3401 Add a basic, unfinshed man page for g-ir-scanner, move documents into .txt
3403 2008-04-29 Johan Dahlin <jdahlin@async.com.br>
3405 * giscanner/girwriter.py:
3406 * giscanner/glibtransformer.py:
3407 * giscanner/transformer.py:
3408 * giscanner/xmlwriter.py:
3409 * tests/parser/Foo-expected.gir:
3410 * tests/parser/foo-object.h:
3411 Write record/structs to gir file too. Add a couple of tests,
3412 fix an off by one error in xmlwriter.py.
3414 2008-04-28 Johan Dahlin <johan@gnome.org>
3416 * giscanner/xmlwriter.py: Calculate the line length properly,
3417 include the provided extra indentation in the calculation, really.
3419 2008-04-28 Johan Dahlin <jdahlin@async.com.br>
3422 * giscanner/glibast.py:
3423 * giscanner/glibtransformer.py:
3424 * giscanner/transformer.py:
3425 * tools/g-ir-scanner:
3426 Add a --strip-prefix and sort out confusion between names and symbols
3427 for functions and struct + derivaties.
3428 Refactor bootstrap of g-ir-scanner, so we can set options on
3429 Transformer() before parsing everything.
3431 2008-04-28 Johan Dahlin <johan@gnome.org>
3433 * giscanner/transformer.py (Transformer._traverse_one): Avoid recursion
3434 when scanning girepository.h
3436 * giscanner/sourcescanner.py (SourceScanner._preprocess): Define
3437 a __GI_SCANNER__ when we run.
3439 2008-04-28 Johan Dahlin <jdahlin@async.com.br>
3442 * giscanner/girwriter.py:
3443 * giscanner/glibast.py:
3444 * giscanner/glibtransformer.py:
3445 * tests/parser/Foo-expected.gir:
3446 * tests/parser/utility-expected.gir:
3447 Rename most c:identifier to c:type. Add new ones to
3448 class/interface/enum/boxed.
3450 2008-04-28 Johan Dahlin <jdahlin@async.com.br>
3453 * giscanner/girwriter.py:
3454 * giscanner/glibtransformer.py:
3455 * tests/parser/Foo-expected.gidl:
3456 * tests/parser/Makefile.am:
3457 Move c:identifier from return-value to subchild type,
3458 as per Jürgs suggestion
3460 2008-04-28 Johan Dahlin <johan@gnome.org>
3462 * giscanner/girwriter.py:
3463 * tests/parser/Foo-expected.gir:
3464 Write property.type as a child node.
3466 2008-04-27 Johan Dahlin <johan@gnome.org>
3471 * gidl/gobject-2.0.gidl:
3473 * gir/gobject-2.0.gir:
3474 * tests/parser/Makefile.am:
3475 Replace the GObject gidl with a GObject gir.
3477 2008-04-27 Johan Dahlin <johan@gnome.org>
3479 * tools/Makefile.am (bin_SCRIPTS): g-ir-scanner is a script,
3482 * giscanner/xmlwriter.py:
3483 * tests/parser/Foo-expected.gir:
3484 Include indentation in line length calculation
3486 2008-04-27 Johan Dahlin <johan@gnome.org>
3488 * giscanner/girparser.py:
3489 Prettify NS parsing using elementtree.
3491 2008-04-27 Johan Dahlin <johan@gnome.org>
3494 * giscanner/Makefile.am:
3495 * giscanner/girparser.py:
3496 * giscanner/glibtransformer.py:
3497 * tests/parser/Foo-expected.gidl:
3498 * tests/parser/Foo-expected.gir:
3499 * tests/parser/Makefile.am:
3500 * tests/parser/utility-expected.gidl:
3501 * tests/parser/utility-expected.gir:
3502 * tools/g-ir-scanner:
3503 Switch over to GIR as the default format. Add a simple GIDL
3505 Update tests and fix simplify makefiles by depending
3506 on GNU make extensions.
3508 2008-04-27 Johan Dahlin <johan@gnome.org>
3510 * giscanner/xmlwriter.py:
3511 Wrap attributes for lines which are wider than 79 characters
3513 * giscanner/scannerlexer.l:
3514 Allow parenthesis in annotations
3517 * giscanner/gidlwriter.py:
3518 * giscanner/girwriter.py:
3519 * giscanner/glibtransformer.py:
3520 * giscanner/transformer.py:
3521 Add initial sequence support, including annotation.
3522 Refactor type handling a bit.
3524 2008-04-27 Johan Dahlin <johan@gnome.org>
3526 * tests/parser/Foo-expected.gidl:
3527 * tests/parser/foo-object.h:
3528 * tests/parser/foo.c (foo_object_class_init),
3529 (foo_object_get_strings), (foo_object_get_objects):
3530 Add two new functions to check sequence return values.
3531 Also fixes a compilation warning.
3533 2008-04-27 Johan Dahlin <johan@gnome.org>
3535 * giscanner/giscannermodule.c (]): Cast the getter, avoids
3536 a compilation warning.
3538 * tools/Makefile.am (g_ir_scanner_SOURCES):
3539 g-ir-scanner has no sources.
3541 2008-04-25 Johan Dahlin <johan@gnome.org>
3543 * giscanner/Makefile.am:
3545 * giscanner/gidlparser.py:
3546 * giscanner/gidlwriter.py:
3547 * giscanner/girwriter.py:
3548 * giscanner/glibast.py:
3549 * giscanner/glibtransformer.py:
3550 * giscanner/transformer.py:
3551 Split out nodes to ast.py and glibast.py
3553 2008-04-25 Johan Dahlin <jdahlin@async.com.br>
3555 * giscanner/Makefile.am:
3556 * giscanner/gidlparser.py:
3557 * giscanner/gidlwriter.py:
3558 * giscanner/girwriter.py:
3559 * giscanner/glibtransformer.py:
3560 * giscanner/gobjecttreebuilder.py:
3561 * giscanner/transformer.py:
3562 * giscanner/treebuilder.py:
3563 * tools/g-ir-scanner:
3564 Rename treebuilder to transformer and
3565 gobjectreebuilder to glibtransformer.
3567 2008-04-25 Johan Dahlin <jdahlin@async.com.br>
3569 * giscanner/Makefile.am:
3570 * giscanner/__init__.py:
3571 * giscanner/cgobject.py:
3572 * giscanner/gidlparser.py:
3573 * giscanner/gidlwriter.py:
3574 * giscanner/girwriter.py:
3575 * giscanner/gobjecttreebuilder.py:
3576 * giscanner/odict.py:
3577 * giscanner/sourcescanner.py:
3578 * giscanner/treebuilder.py:
3579 * giscanner/xmlwriter.py:
3580 * tools/Makefile.am:
3581 * tools/g-ir-scanner:
3582 Add LGPLv2 license header and install all python files
3584 2008-04-25 Johan Dahlin <jdahlin@async.com.br>
3587 * giscanner/gidlwriter.py:
3588 * giscanner/giscannermodule.c (pygi_source_directive_new),
3589 (directive_get_options), (pygi_source_symbol_new),
3590 (symbol_get_base_type), (pygi_source_type_new),
3591 (type_get_base_type), (type_get_child_list),
3592 (pygi_source_scanner_get_symbols),
3593 (pygi_source_scanner_get_directives):
3594 * giscanner/gobjecttreebuilder.py:
3595 * giscanner/sourcescanner.py:
3596 * giscanner/treebuilder.py:
3597 * tests/parser/foo-object.h:
3598 Add support for virtual methods.
3599 Pair struct FooClass with struct Foo.
3600 Clean up the SourceScanner bindings a bit.
3601 Add a testcase for virtual methods.
3603 2008-04-25 Johan Dahlin <jdahlin@async.com.br>
3605 * giscanner/cgobject.py:
3606 * giscanner/gidlwriter.py:
3607 * giscanner/gobjecttreebuilder.py:
3608 Add support for signals
3610 * tests/parser/foo.c (foo_object_class_init):
3611 * Foo-expected.gidl:
3612 Add a signal and update the expected output.
3614 2008-04-24 Johan Dahlin <jdahlin@async.com.br>
3616 * giscanner/gidlwriter.py:
3617 * giscanner/girwriter.py:
3618 * giscanner/giscannermodule.c (directive_get_name),
3619 (directive_get_value), (directive_get_options),
3620 (symbol_get_directives), (symbol_set_directives),
3621 (pygi_source_scanner_parse_file),
3622 (pygi_source_scanner_lex_filename),
3623 (pygi_source_scanner_get_directives), (init_giscanner):
3624 * giscanner/sourcescanner.c (gi_source_scanner_get_directives):
3625 * giscanner/sourcescanner.h:
3626 * giscanner/sourcescanner.py:
3627 * giscanner/treebuilder.py:
3628 * tools/g-ir-scanner:
3629 Add support for source/header annotations.
3631 2008-04-22 Johan Dahlin <jdahlin@async.com.br>
3633 * giscanner/gidlwriter.py:
3634 * giscanner/girwriter.py:
3635 * giscanner/gobjecttreebuilder.py:
3636 * giscanner/treebuilder.py:
3637 Add support for Callbacks
3639 2008-04-22 Havoc Pennington <hp@pobox.com>
3641 * girepository/ginvoke.c (g_function_info_invoke): If a symbol is
3642 not in metadata->module, look for it in the global module, in case
3643 some other object or the app itself provides the symbol.
3645 2008-04-22 Havoc Pennington <hp@pobox.com>
3647 * girepository/gmetadata.c (_g_metadata_init): hack to avoid
3648 dlopening a library that is already in the main app, by checking
3649 whether one of the lib's symbols is already loaded.
3651 2008-04-22 Johan Dahlin <jdahlin@async.com.br>
3653 * tests/parser/Foo-expected.gidl:
3654 * tests/parser/foo-object.h:
3657 2008-04-22 Havoc Pennington <hp@pobox.com>
3659 * girepository/ginfo.c (g_interface_info_find_method):
3660 Use interface_blob_size not object_blob_size to compute offset.
3662 2008-04-22 Havoc Pennington <hp@pobox.com>
3664 * girepository/gmetadata.c (_g_metadata_init): remove
3665 G_MODULE_BIND_LOCAL flag when loading libraries, since some libs
3666 (Glade and Clutter for example) rely on being loaded globally.
3668 2008-04-22 Havoc Pennington <hp@pobox.com>
3670 * girepository/ginfo.c (g_registered_type_info_get_g_type): new
3671 function to get the GType given a RegisteredTypeInfo
3673 2008-04-22 Johan Dahlin <johan@gnome.org>
3675 * COPYING: Add a LGPL license, to prevent automake to
3676 put in a copy of GPL here. Pointed out by Havoc.
3678 * girepository/ginfo.c (g_info_from_entry), (g_type_info_new),
3679 (g_type_info_is_pointer), (g_type_info_get_tag),
3680 (g_type_info_get_param_type), (g_type_info_get_interface),
3681 (g_type_info_get_array_length), (g_type_info_is_zero_terminated),
3682 (g_type_info_get_n_error_domains), (g_type_info_get_error_domain),
3683 (g_error_domain_info_get_codes), (g_enum_info_get_value),
3684 (g_object_info_get_interface), (g_object_info_get_field),
3685 (g_interface_info_get_prerequisite),
3686 (g_signal_info_get_class_closure), (g_constant_info_get_value):
3687 * girepository/ginvoke.c (get_ffi_type):
3688 * girepository/girepository.h:
3689 * girepository/gmetadata.c (g_metadata_get_dir_entry),
3690 (g_metadata_check_sanity), (validate_header),
3691 (validate_array_type_blob), (validate_iface_type_blob),
3692 (validate_param_type_blob), (validate_error_type_blob),
3693 (validate_type_blob), (validate_constant_blob),
3694 (validate_struct_blob), (validate_enum_blob):
3695 * girepository/gmetadata.h:
3696 * tests/Makefile.am:
3697 * tests/invoke/Makefile.am:
3698 * tests/invoke/invoke.c (main):
3699 * tests/roundtrips.sh:
3700 * tools/Makefile.am:
3701 * tools/compiler.c (format_output), (write_out_metadata), (main):
3702 * tools/generate.c (write_type_name), (write_type_info),
3703 (write_constant_value), (write_enum_info), (load_metadata), (main):
3704 * tools/gidlcompilercontext.c:
3705 * tools/gidlcompilercontext.h:
3706 * tools/gidlcompilerentrynode.c:
3707 * tools/gidlcompilerentrynode.h:
3708 * tools/gidlcompilertypenode.c:
3709 * tools/gidlcompilertypenode.h:
3710 * tools/gidlmodule.c (g_idl_module_build_metadata):
3711 * tools/gidlmodule.h:
3712 * tools/gidlnode.c (init_stats), (dump_stats),
3713 (g_idl_node_get_size), (g_idl_node_get_full_size),
3714 (g_idl_node_cmp), (g_idl_node_can_have_member),
3715 (g_idl_node_add_member), (g_idl_node_param_direction_string),
3716 (parse_int_value), (parse_uint_value), (parse_float_value),
3717 (parse_boolean_value), (find_entry_node), (find_entry),
3718 (serialize_type), (g_idl_node_build_metadata), (write_string):
3720 * tools/gidlparser.c (parse_type_internal):
3721 * tools/quote-file.sh:
3722 Revert revisions 157,149-148,136-129 and 120.
3723 Move back to using g-idl-generate to generate the metadata and
3724 avoids dependency on a c compiler.
3726 2008-04-22 Johan Dahlin <jdahlin@async.com.br>
3728 * giscanner/girwriter.py:
3729 * tools/g-ir-scanner:
3730 Add an initial GIR writer and a --format option to g-ir-scanner
3732 2008-04-21 Johan Dahlin <johan@gnome.org>
3734 * giscanner/cgobject.py: Use ctypes.util.find_library to locate
3735 gobject-2.0 and raise ImportError if not found.
3737 * giscanner/gidlparser.py:
3738 * giscanner/gidlwriter.py:
3739 * giscanner/gobjecttreebuilder.py:
3740 * tools/g-ir-scanner:
3741 Add a --include argument to include types from other idls.
3742 Add a minimalistic GIDL parser (just objects for now)
3743 Implement resolving of external type references and use it to
3744 resolve parent types, argument types and return types.
3746 2008-04-21 Johan Dahlin <johan@gnome.org>
3748 * giscanner/gidlwriter.py:
3749 * giscanner/gobjecttreebuilder.py:
3750 * giscanner/treebuilder.py:
3751 Add support for properties.
3752 Refactor Class/Interface support a bit, to share more code and
3753 always initialize their method attribute to an empty list.
3755 2008-04-21 Johan Dahlin <johan@gnome.org>
3757 * giscanner/cgobject.py:
3758 Add a workaround for a glib bug interface introspection bug
3759 (object_interface_list_properties, object_class_list_properties):
3760 Cast the return value to GParamSpec.
3762 * tests/parser/Foo-expected.gidl: Update
3763 * tests/parser/foo.c: Add a string property
3765 * giscanner/gobjecttreebuilder.py:
3766 After stripping namespaces, remove the original
3767 item to avoid duplication (GtkButton struct and Button object)
3769 2008-04-21 Johan Dahlin <johan@gnome.org>
3771 * giscanner/gobjecttreebuilder.py:
3772 * giscanner/treebuilder.py:
3773 Strip namespaces before objects, so we'll export
3774 GtkButton as Button in the gtk namespace
3776 2008-04-21 Johan Dahlin <johan@gnome.org>
3778 * giscanner/gidlwriter.py:
3779 * giscanner/gobjecttreebuilder.py:
3780 * giscanner/treebuilder.py:
3781 Add constructors for object/boxed types.
3783 2008-04-21 Johan Dahlin <johan@gnome.org>
3785 * giscanner/gidlwriter.py:
3786 * giscanner/gobjecttreebuilder.py:
3787 Add support for boxed types
3789 2008-04-21 Johan Dahlin <johan@gnome.org>
3791 * giscanner/giscannermodule.c: Mark structures as const,
3792 wrap SourceType.const_string.
3794 * tests/parser/foo-object.h: Add a couple of constants.
3796 * giscanner/gidlwriter.py:
3797 * giscanner/gobjecttreebuilder.py:
3798 * giscanner/treebuilder.py:
3799 Add basic support for interfaces
3801 * tools/g-ir-scanner:
3802 Add -o/--output for writing to a file
3804 2008-04-21 Havoc Pennington <hp@redhat.com>
3806 * TODO: add some C API wishlist items I could think of quickly
3808 2008-04-21 Johan Dahlin <jdahlin@async.com.br>
3810 * giscanner/gidlwriter.py:
3811 * giscanner/xmlwriter.py:
3812 Add a simple api for writing tags which can be used
3813 with the new 'with statement' in python 2.5
3815 2008-04-21 Johan Dahlin <johan@gnome.org>
3817 * giscanner/gobjecttreebuilder.py:
3818 Strip namespace and object prefix from method names.
3820 2008-04-21 Johan Dahlin <johan@gnome.org>
3822 * tools/g-ir-scanner (main): Add --pkg option to pass in
3823 pkg-config modules to get cflags from.
3825 * giscanner/gidlwriter.py (GIDLWriter._write_method):
3826 Avoid duplication, reuse function writer for methods.
3828 2008-04-21 Johan Dahlin <jdahlin@async.com.br>
3830 * giscanner/gidlwriter.py:
3831 * giscanner/gobjecttreebuilder.py:
3832 * giscanner/treebuilder.py:
3833 * tools/g-ir-scanner:
3834 Resolve libtool .la files.
3835 Strip name spaces for methods.
3836 Add function symbols
3838 2008-04-20 Johan Dahlin <jdahlin@async.com.br>
3840 * giscanner/cgobject.py:
3841 * giscanner/gidlwriter.py:
3842 * giscanner/gobjecttreebuilder.py:
3843 * giscanner/treebuilder.py:
3844 Add support for classes and methods
3846 2008-04-20 Johan Dahlin <johan@gnome.org>
3848 * giscanner/gidlwriter.py:
3849 * giscanner/gobjecttreebuilder.py:
3850 * giscanner/odict.py:
3851 Avoid conflicts, keep the output ordered similar to
3852 the order of the input.
3853 Add a simple ordered dictionary implemenation
3855 2008-04-19 Johan Dahlin <johan@gnome.org>
3857 * giscanner/cgobject.py:
3858 * giscanner/gidlwriter.py:
3859 * giscanner/gobjecttreebuilder.py:
3860 * tools/g-ir-scanner:
3861 Start introspecting get-type functions.
3862 Implement support for GLib/GFlags GTypes.
3863 Add a ctype based GObject binding.
3865 2008-04-18 Johan Dahlin <jdahlin@async.com.br>
3867 * giscanner/gidlwriter.py:
3868 * giscanner/xmlwriter.py:
3869 * tools/g-ir-scanner:
3870 Add a simplistic gidl writer, which can't do too much.
3872 2008-04-18 Johan Dahlin <johan@gnome.org>
3874 * giscanner/sourcescanner.py:
3875 * giscanner/treebuilder.py:
3876 * tools/g-ir-scanner:
3877 split tree building and source scanning interface to separate files.
3879 2008-04-18 Johan Dahlin <johan@gnome.org>
3881 * tools/g-ir-scanner (Parameter.__init__): Start constructing
3883 - Add support for struct/parameter/return, start parsing of ctypes
3885 * giscanner/giscannermodule.c: wrap GISourceType.child_list and
3888 2008-03-31 Johan Dahlin <johan@gnome.org>
3890 * tools/g-ir-scanner:
3891 Start to build abstract syntax node of scanned sources.
3892 Add support for cpp options.
3894 2008-03-27 Johan Dahlin <johan@gnome.org>
3896 * giscanner/giscannermodule.c:
3897 * giscanner/scannerlexer.l:
3898 * giscanner/sourcescanner.c:
3899 * tools/g-ir-scanner:
3901 Add simple pre-processor using subprocess and a PIPE.
3902 Change the parse_file apis to accept a file descriptor.
3904 2008-03-25 Johan Dahlin <johan@gnome.org>
3906 * giscanner/__init__.py:
3907 * tools/g-ir-scanner:
3908 Fix a typo and add an example python test program.
3910 2008-03-25 Johan Dahlin <johan@gnome.org>
3912 * giscanner/__init__.py:
3913 * giscanner/giscannermodule.c:
3914 * giscanner/sourcescanner.c:
3915 * giscanner/sourcescanner.h:
3916 Add constants and wrap a few more SymbolType fields
3918 2008-03-25 Johan Dahlin <johan@gnome.org>
3922 * giscanner/__init__.py:
3923 * giscanner/giscannermodule.c:
3924 * giscanner/Makefile.am:
3926 Add initial python bindings for the scanner and
3927 depend on python 2.5.
3929 2008-03-25 Johan Dahlin <johan@gnome.org>
3933 * giscanner/Makefile.am:
3934 * giscanner/sourcescanner.c:
3935 * giscanner/sourcescanner.h:
3936 * tools/Makefile.am:
3937 * tools/grealpath.h:
3938 * tools/sourcescanner.c:
3939 * tools/sourcescanner.h:
3941 Move the scanner to a separate library.
3943 2008-03-23 Johan Dahlin <johan@gnome.org>
3945 * tools/Makefile.am:
3948 * tools/scannerlexer.l:
3949 * tools/scannerparser.y:
3950 * tools/sourcescanner.c:
3951 * tools/sourcescanner.h:
3952 Split out the source scanner from the generator.
3953 Rename the symbols used in the scanner to use the gi_ prefix.
3954 This should make it possible to use the raw C parser from
3957 2008-03-23 Johan Dahlin <johan@gnome.org>
3959 * tests/parser/Makefile.am (utility.gidl):
3960 * tests/parser/utility-expected.gidl:
3961 Pass in the gobject.gidl since we're defining a GObject.
3963 2008-03-12 Johan Dahlin <johan@gnome.org>
3965 * relaxng/relaxng.rng:
3966 Add a releaxng in relaxng we can use to validate the relaxngs
3969 2008-03-12 Jürg Billeter <j@bitron.ch>
3971 * tools/scanner.c: (g_igenerator_new):
3972 * tools/scannerparser.y:
3973 Fix compiler warnings.
3975 2008-03-12 Jürg Billeter <j@bitron.ch>
3979 * tools/scannerparser.y:
3980 Start fixing memory management in g-idl-scanner.
3982 2008-03-12 Rob Taylor <rob.taylor@codethink.co.uk>
3984 * tools/gidlcompilercontext.c: (write_compiled):
3985 Fix critical warning when no shlib passed to g-idl-compiler.
3987 2008-03-12 Johan Dahlin <johan@gnome.org>
3989 * tests/parser/utility-expected.gidl:
3990 * tests/parser/utility.h:
3991 Add a get_type-function, so the scanner actually
3992 parses it as an object.
3994 2008-03-12 Johan Dahlin <johan@gnome.org>
3996 * tools/gidlwriter.c (function_generate): Add missing trailing quote.
3999 * tests/parser/Foo-expected.gidl:
4000 * tests/parser/Makefile.am:
4001 * tests/parser/foo-object.h:
4002 * tests/parser/foo.c:
4003 * tests/parser/utility-expected.gidl:
4004 * tests/parser/utility.c:
4005 * tests/parser/utility.h:
4007 Add a new gidl test. 'utility.gidl', which is used to be able
4008 to test external type references. Add a reference to UtilityObject*
4011 2008-03-11 Johan Dahlin <johan@gnome.org>
4015 Remove most global variables
4017 2008-03-11 Philip Van Hoof <me@pvanhoof.be>
4019 * tools/scannerlexer.l:
4021 * tests/parser/Foo-expected.gidl:
4022 * tests/parser/foo.c:
4023 * tests/parser/Makefile.am:
4024 * tests/parser/foo-object.h:
4026 Added a few extra tests. Which resulted in finding a few
4027 bugs. Which resulted in me fixing those bugs
4029 2008-03-11 Rob Taylor <rob.taylor@codethink.co.uk>
4031 * tools/gidlcompilercontext.c: (g_idl_compiler_write_dir_entry),
4032 (g_idl_compiler_write_xref_entry), (g_idl_compiler_add_xref):
4033 Add some comments for strings into generated output for
4036 2008-03-11 Rob Taylor <rob.taylor@codethink.co.uk>
4038 * tools/gidlcompilercontext.c: (write_compiled):
4039 Write out the shlibs variable before writing out the strings
4040 length. Fixes compiler warning when using '-l' flag with
4043 2008-03-11 Johan Dahlin <johan@gnome.org>
4045 * tests/parser/Foo-expected.gidl:
4046 * tests/parser/foo-object.h:
4049 * tools/scannerlexer.l:
4050 Add support for parsing return arguments. Add support for
4051 caller-owns return types.
4052 Patch by Philip Van Hoof.
4054 * tools/scannerparser.y:
4055 Remove parsing of the @deprecated syntax used in headers.
4056 We will support gtk-doc deprecation in the future instead.
4058 2008-03-11 Johan Dahlin <johan@gnome.org>
4060 * tools/compiler.c (main): Coding style fixes
4062 2008-03-10 Johan Dahlin <johan@gnome.org>
4065 Add GCOV_LIBS to GILIBS
4067 2008-03-10 Johan Dahlin <johan@gnome.org>
4069 * tests/parser/Foo-expected.gidl:
4070 * tests/parser/foo.c:
4071 Rename null-ok to direction=out
4073 2008-03-10 Philip Van Hoof <me@pvanhoof.be>
4075 reviewed and extensively tested by Johan
4077 * tests/parser/Foo-expected.gidl:
4078 * tests/parser/foo-object.h:
4079 * tests/parser/foo.c:
4082 * tools/gidlwriter.c:
4085 * tools/scannerlexer.l:
4086 * tools/scannerparser.y:
4088 Add support for scanning for gtk-doc comments inside
4089 C source files. Add tests
4091 2008-03-10 Johan Dahlin <johan@gnome.org>
4093 * tests/parser/Makefile.am:
4094 * tests/parser/foo.c:
4097 * tools/scannerparser.y:
4098 Add an api to lex filenames.
4099 Lex all source .c files passed in on the command line.
4100 Scan sources in a test and a couple of private structures
4101 which should not be included in the generated gidl
4103 2008-03-10 Johan Dahlin <johan@gnome.org>
4105 * tests/invoke/Makefile.am: Make the generated metadata
4106 depend on the g-idl-compiler
4108 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4110 * tools/gidlmodule.c
4111 * tools/gidlmodule.h
4114 Remove the old g-idl-compiler code.
4117 2008-02-22 Mark Doffman <mark.doffman@codethink.co.uk>
4119 * tools/quote-file.sh
4122 Move to using the 'C' struct compiler code.
4124 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4126 * girepository/ginfo.c
4128 Change the way that external references with no namespace
4129 are dealt with. External references with no namespace
4130 are placed into the XML as-if they are a local reference.
4131 This is temporary, but helps with roundtrip tests.
4133 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4135 * girepository/ginfo.c
4136 Add the ability to get the value of a constant of
4137 type TYPE_TAG_SYMBOL. In the case of a symbol the value
4138 is provided as a string.
4140 This would deal properly with:
4141 typedef char* random;
4142 const random = "A string";
4144 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4146 * girepository/ginfo.c
4147 * girepository/girepository.h
4149 Add a function to check if an enum is registered or not.
4150 Previously anything testing this relied on the g-type
4151 string offset having a value of 0.
4153 * girepository/gmetadata.c
4154 * girepository/gmetadata.h
4156 Remove unneccesary or erroneous checks. There were two
4157 metadata validation checks which made sure that the blob
4158 sizes were the same as some magic numbers compiled into the code.
4159 This is wrong as it breaks any forwards compatibility that may
4162 Checks were also present that made sure that unregistered type
4163 blobs had a value of 0 in the g-type offset field. This is
4164 unneccessary. If a type blob is unregistered then any value
4165 in its g-type field is simply invalid.
4167 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4169 * girepository/ginfo.c
4170 * girepository/gmetadata.c
4171 * girepository/gmetadata.h
4173 Change the metadata format to have a standard header
4174 for all the type blobs. Merge the SimpleTypeBlob
4175 and InterfaceTypeBlob into a union. A union of these
4176 two blobs existed previously but was not explicit
4177 in the metadata format.
4179 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4181 * tools/gidlcompilercontext.c
4182 * tools/gidlcompilercontext.h
4183 * tools/gidlcompilerentrynode.c
4184 * tools/gidlcompilerentrynode.h
4185 * tools/gidlcompilertypenode.c
4186 * tools/gidlcompilertypenode.h
4188 Add code to compile a tree of GIdlNodes to
4189 a 'C' struct representing the metadata.
4190 This is to aid cross-compiling. Previously
4191 the g-idl-compiler created a binary blob with
4192 data written in the byte order and alignment
4193 of the tool rather than the intended target.
4195 Cleaned up and improved by Johan and Robert :-)
4197 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4199 * girepository/ginvoke.c
4200 * girepository/girepository.h
4201 * girepository/gmetadata.c
4202 * girepository/gmetadata.h
4204 * tools/gidlparser.c
4205 Modify TYPE_TAG_INTERFACE to TYPE_TAG_SYMBOL
4206 to avoid confusion with the interface blob.
4209 * tools/gidlparser.c
4210 Remove magic numbers and replace with type-tag
4211 enumeration symbols.
4213 * girepository/gmetadata.c
4214 Add validate declaration.
4216 2008-03-10 Jürg Billeter <j@bitron.ch>
4218 * tools/gidlparser.c: (parse_type_internal):
4219 * tools/scannerlexer.l:
4220 * tools/scannerparser.y:
4221 Support C99 _Bool type in scanner.
4223 2008-03-10 Jürg Billeter <j@bitron.ch>
4225 * tests/parser/Foo-expected.gidl:
4226 * tests/parser/foo-object.h:
4227 * tests/parser/foo.c: (foo_enum_method):
4228 * tools/scanner.c: (g_igenerator_process_function_symbol):
4229 Don't skip functions that are defined in the namespace of a type
4230 that doesn't support methods, as for example enums.
4232 2008-03-10 Johan Dahlin <johan@gnome.org>
4234 * gidl.dtd: Remove, we're using relaxng for now
4236 * tests/parser/Foo-expected.gidl:
4237 * tests/parser/foo-object.h:
4238 * tests/parser/foo.c:
4239 Rename the enum/flags get_type functions to include the whole type.
4241 2008-03-08 Marc-Andre Lureau <marcandre.lureau@gmail.com>
4243 * tools/gidlwriter.c (enum_generate): added "type-name",
4244 "get-type" and "deprecated" missing arguments.
4245 * tests/parser/Foo-expected.gidl:
4246 * tests/parser/foo-object.h: test enum type, and no type.
4248 2008-03-06 Johan Dahlin <jdahlin@async.com.br>
4251 Consistent checks, add missing 'test'
4253 2008-03-05 Havoc Pennington <hp@redhat.com>
4255 * configure.ac: Take advantage of a libffi.pc if one exists, as it
4256 does on Fedora 8. Make libffi a hard requirement, since it was in
4257 practice anyway (was not really conditional in the code or
4258 makefile, only in configure).
4260 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4262 reviewed by: Rob Taylor <rob.taylor@codethink.co.uk>
4263 reviewed by: Johan Dahlin <johan@gnome.org>
4265 * tests/Makefile.am:
4266 * tests/roundtrips.sh:
4267 Modify the roundtrips test so that they do not use the
4268 --raw option of the gidl compiler but instead compile a
4269 shared library to use with g_module.
4271 * tests/invoke/Makefile.am:
4272 * tests/invoke/invoke.c:
4273 Modify the invoke tests to build a shared library rather
4274 than use the --raw option.
4276 * tests/invoke/invoke-namespace-find.sh: Removed:
4277 Noone knows why this was here, so removed.
4279 2008-02-19 Rob Taylor <rob.taylor@codethink.co.uk>
4281 * tools/scanner.c: (g_igenerator_process_function_symbol):
4282 Move g_idl_node_can_have_member test later, as it broke spotting
4283 get_type's for nodes that can't have members.
4285 2008-02-18 Rob Taylor <rob.taylor@codethink.co.uk>
4288 * tools/gidlnode.c: (g_idl_node_can_have_member):
4289 Add g_idl_node_can_have_member.
4291 * tools/scanner.c: (g_igenerator_process_function_symbol):
4292 Use g_idl_node_can_have_member to test if we should add a function
4293 as a member of the type node.
4295 2008-02-18 Rob Taylor <rob.taylor@codethink.co.uk>
4297 * gidl/GLib.gidl: Renamed to gidl/gobject-2.0.gidl:
4299 * tests/parser/Makefile.am:
4300 Rename GLib.gidl to gobject-2.0.gidl and install in /usr/share/gidl.
4302 2008-02-18 Rob Taylor <rob.taylor@codethink.co.uk>
4304 * tools/scanner.c: (main):
4305 Ignore -pthread when passed to g-idl-scanner.
4307 2008-02-18 Rob Taylor <rob.taylor@codethink.co.uk>
4309 * tools/grealpath.h: Added:
4310 * tools/scanner.c: (main):
4311 * tools/scannerlexer.l:
4312 * tools/Makefile.am:
4313 Always use absolute paths with symbolic links resolved when
4314 comparing filenames.
4316 2008-02-18 Rob Taylor <rob.taylor@codethink.co.uk>
4318 * gobject-introspection.pc.in:
4319 Provide variables for g-idl-parser, scanner and compiler in the
4322 2008-02-13 Rob Taylor <rob.taylor@codethink.co.uk>
4325 * girepository/Makefile.am:
4326 * tools/Makefile.am:
4327 Rename GCOV_SOURCES to GCOVSOURCES to top automake complaining.
4329 2008-02-10 Johan Dahlin <johan@gnome.org>
4331 * tests/parser/Foo-expected.gidl:
4332 * tests/parser/foo-object.h:
4333 * tests/parser/foo.c: (foo_boxed_copy), (foo_boxed_free),
4334 (foo_boxed_get_type), (foo_boxed_new), (foo_boxed_method):
4337 2008-02-10 Johan Dahlin <johan@gnome.org>
4339 * tests/parser/Foo-expected.gidl:
4340 * tests/parser/foo-object.h:
4341 * tests/parser/foo.c: (foo_enum_get_type), (foo_flags_get_type):
4342 Add enum and flags test.
4344 2008-02-10 Johan Dahlin <johan@gnome.org>
4348 * girepository/Makefile.am:
4349 Make 'make distcheck' work again.
4351 2008-02-10 Johan Dahlin <johan@gnome.org>
4353 * m4/Makefile.am (EXTRA_DIST): its called as-compiler-flag.m4,
4356 * tests/parser/Makefile.am: Only create Foo.gidl when running make
4357 check, eg exclude it from BUILT_SOURCES.
4359 2008-02-08 Rob Taylor <rob.taylor@codethink.co.uk>
4364 * girepository/Makefile.am:
4365 * m4/Makefile.am: Added:
4366 * m4/as-compiler-flag.m4: Added:
4367 * m4/gcov.m4: Added:
4368 * tools/Makefile.am:
4369 Add ability to generate a coverage report.
4370 Adds configure option --enable-gcov and make rule 'check-coverage'.
4372 2008-02-08 Rob Taylor <rob.taylor@codethink.co.uk>
4376 * gidl/Makefile.am: Added:
4377 * girepository/Makefile.am: Added:
4378 * src/Makefile.am: Renamed to tools/Makefile.am:
4379 * src/compiler.c: Renamed to tools/compiler.c:
4380 * src/g-idl-offsets.pl: Renamed to tools/g-idl-offsets.pl:
4381 * src/generate.c: Renamed to tools/generate.c:
4382 * src/gidlmodule.c: Renamed to tools/gidlmodule.c:
4383 * src/gidlmodule.h: Renamed to tools/gidlmodule.h:
4384 * src/gidlnode.c: Renamed to tools/gidlnode.c:
4385 * src/gidlnode.h: Renamed to tools/gidlnode.h:
4386 * src/gidlparser.c: Renamed to tools/gidlparser.c:
4387 * src/gidlparser.h: Renamed to tools/gidlparser.h:
4388 * src/gidlwriter.c: Renamed to tools/gidlwriter.c:
4389 * src/gidlwriter.h: Renamed to tools/gidlwriter.h:
4390 * src/ginfo.c: Renamed to girepository/ginfo.c:
4391 * src/ginvoke.c: Renamed to girepository/ginvoke.c:
4392 * src/girepository.c: Renamed to girepository/girepository.c:
4393 * src/girepository.h: Renamed to girepository/girepository.h:
4394 * src/gmetadata.c: Renamed to girepository/gmetadata.c:
4395 * src/gmetadata.h: Renamed to girepository/gmetadata.h:
4396 * src/scanner.c: Renamed to tools/scanner.c:
4397 * src/scanner.h: Renamed to tools/scanner.h:
4398 * src/scannerlexer.l: Renamed to tools/scannerlexer.l:
4399 * src/scannerparser.y: Renamed to tools/scannerparser.y:
4400 * tests/invoke/Makefile.am:
4401 Split src/ into girepository/ and tools/
4405 * girepository/Makefile.am:
4406 * tests/Makefile.am:
4407 * tests/invoke/Makefile.am:
4408 * tests/parser/Makefile.am:
4409 * tests/roundtrips.sh:
4410 * tools/Makefile.am:
4411 Make distcheck work.
4413 2008-02-04 Rob Taylor <rob.taylor@codethink.co.uk>
4415 * tests/invoke/invoke.c: (main):
4416 * tests/invoke/testfns.c: (test6), (test7):
4417 * tests/invoke/testfns.xml:
4418 Add tests for invokation with a GList argument.
4419 Also tests caller-owns return values.
4421 2008-02-04 Rob Taylor <robtaylor@floopily.org>
4424 Add some documentation for GICallableInfo
4426 2008-02-01 Mark Doffman <mark.doffman@codethink.co.uk>
4429 Correct syntax errors in the DTD file.
4431 * relaxng/c-types.xml:
4432 * relaxng/g-types.xml:
4434 Add a RelaxNG specification for the GObject Introspection XML data.
4435 The Specification has validated all of the test files.
4437 2008-01-25 Rob Taylor <robtaylor@floopily.org>
4439 * tests/roundtrips.sh:
4440 * tests/struct.test:
4441 Add roundtrip tests for structs.
4443 2008-01-11 Johan Dahlin <johan@gnome.org>
4445 * src/scanner.c (g_igenerator_process_function_symbol):
4446 Refactor out g_idle_node_add_member.
4447 (create_node_from_gtype, create_node_from_ctype):
4448 Use case instead of if...else
4449 (get_type_from_type_id):
4450 Rename to create_node_from_gtype
4451 (get_type_from_ctype):
4452 Rename to create_node_from_ctype
4454 Rename ginode -> node, gitype -> type, gifunc -> func.
4456 * src/gidlnode.c (g_idl_node_add_member, g_idl_node_cmp):
4457 Two new functions, refactor out of scanner.c
4459 * src/scanner.c: (g_igenerator_process_function_symbol):
4460 * src/scannerlexer.l:
4461 Do not save the content of the deprecated variable, only
4464 2008-01-11 Johan Dahlin <johan@gnome.org>
4466 * tests/parser/foo-object.h: Add a couple of comment parser tests.
4468 2008-01-11 Jürg Billeter <j@bitron.ch>
4470 * src/scannerlexer.l:
4471 Fix GTK-Doc parsing.
4473 2008-01-11 Jürg Billeter <j@bitron.ch>
4475 * src/scannerlexer.l:
4476 Fix GTK-Doc parsing.
4478 2008-01-11 Jürg Billeter <j@bitron.ch>
4480 * src/scanner.c: (lookup_symbol):
4481 Return unresolved name if we find unknown symbol.
4483 2008-01-11 Jürg Billeter <j@bitron.ch>
4485 * src/scanner.c: (g_igenerator_generate):
4486 Initialize GObject to fix scanning interface properties.
4488 * tests/parser/Foo-expected.gidl:
4489 * tests/parser/foo-object.h:
4490 * tests/parser/foo.c: (foo_interface_get_type):
4491 Test interfaces with GObject prerequisite.
4493 * tests/parser/Makefile.am:
4494 Set G_DEBUG=fatal_warnings to abort test on warnings and criticals.
4496 2007-12-27 Johan Dahlin <johan@gnome.org>
4498 * src/scannerlexer.l:
4499 Parse gtk-doc comments.
4501 * src/gidlwriter.c: (function_generate):
4502 Reorganize, avoid duplication and add support for
4503 writing deprecated functions.
4505 * src/scannerparser.y:
4507 Add new structure CDirective and functions to create/free them.
4509 * src/scanner.c: (g_igenerator_process_function_symbol),
4510 (g_igenerator_process_unregistered_struct_typedef),
4511 (g_igenerator_process_struct_typedef),
4512 (g_igenerator_process_union_typedef),
4513 (g_igenerator_process_enum_typedef),
4514 (g_igenerator_process_function_typedef), (g_igenerator_add_symbol),
4515 (g_igenerator_start_preprocessor):
4516 Parse @deprecated directive for functions.
4517 Remove some more C99isms.
4518 Send in -C to cpp to avoid stripping comments.
4520 * tests/parser/foo-object.h:
4521 * tests/parser/Foo-expected.gidl:
4522 Add deprecated directive
4524 2007-12-27 Johan Dahlin <johan@gnome.org>
4526 * src/scannerlexer.l (intsuffix): Add emacs mode line and
4527 escape ' and " so it looks more like C.
4530 Unlink temporary file used.
4532 2007-12-27 Johan Dahlin <johan@gnome.org>
4534 * src/scanner.c: (g_igenerator_new), (g_igenerator_free),
4535 (g_igenerator_start_preprocessor), (main):
4537 * src/scannerparser.y:
4538 Plug a couple of simple memory leaks.
4540 2007-12-27 Johan Dahlin <johan@gnome.org>
4542 * src/scanner.c: (g_igenerator_parse_macros),
4543 (g_igenerator_start_preprocessor), (g_igenerator_set_verbose),
4546 * src/scannerparser.y:
4547 * tests/parser/Makefile.am:
4549 Improve error reporting, return when the preprocessor fails.
4550 Add a verbose parameter, to aid debugging.
4551 Revert to using a temporary file to communicate between the
4552 preprocessor and the parser, because we need to wait for
4553 the exit code from the pre-processor before starting to parse.
4555 2007-12-16 Johan Dahlin <jdahlin@async.com.br>
4557 * src/Makefile.am: Rename clexer.l to scannerlexer.l and
4558 cparser.y to scannerparser.y
4560 2007-12-11 Johan Dahlin <johan@gnome.org>
4564 * src/scanner.c: (g_igenerator_new):
4566 Get rid of the global the_generator variable.
4568 2007-12-10 Johan Dahlin <johan@gnome.org>
4570 * src/scanner.c (main): Add an output option,
4571 add checks for required parameters
4574 set BUILD_SOURCES and CLEANFILES properly
4576 * src/gidlwriter.c: (g_writer_write_inline), (g_writer_write),
4577 (g_writer_write_indent), (g_writer_write_unindent),
4578 (field_generate), (value_generate), (constant_generate),
4579 (property_generate), (function_generate), (vfunc_generate),
4580 (signal_generate), (interface_generate), (struct_generate),
4581 (union_generate), (boxed_generate), (enum_generate),
4582 (node_generate), (g_writer_write_module), (g_idl_writer_save_file):
4584 * src/scanner.c: (g_igenerator_generate):
4586 * src/scannerwriter.c:
4588 Refactor scannerwriter to only be tied to a GIdlModule and move
4589 it (again!) to gidlwriter.c. Change the writer function to take
4592 2007-12-10 Johan Dahlin <johan@gnome.org>
4595 * src/scanner.c: (g_igenerator_generate):
4597 * src/scannerwriter.c: (g_igenerator_write_inline),
4598 (g_igenerator_write), (g_igenerator_write_indent),
4599 (g_igenerator_write_unindent), (field_generate), (value_generate),
4600 (constant_generate), (property_generate), (function_generate),
4601 (vfunc_generate), (signal_generate), (interface_generate),
4602 (struct_generate), (union_generate), (boxed_generate),
4603 (enum_generate), (node_generate), (module_generate),
4604 (g_scanner_write_file):
4606 Move the scanner gidl writing to a separate source file.
4608 2007-12-10 Johan Dahlin <johan@gnome.org>
4613 Move over all CType construction functions.
4615 * tests/parser/Makefile.am:
4616 Be verbose when printing parsing tests results.
4618 2007-12-10 Johan Dahlin <johan@gnome.org>
4620 * src/scanner.c (g_igenerator_start_preprocessor): Refactor
4621 preprocessor handling to here. Start cpp insteado of cc -E,
4622 always include -U__GNUC__, since it's specific to the preprocessor
4625 * tests/parser/Makefile.am (check-local): Silent diff and skip
4626 -U__GNUC__ which is always defined now
4628 2007-12-10 Johan Dahlin,,, <jdahlin@plasttroll>
4630 reviewed by: <delete if not using a buddy>
4632 * src/scanner.c: (g_igenerator_start_preprocessor), (main):
4633 * tests/parser/Makefile.am:
4635 2007-12-09 Johan Dahlin <johan@gnome.org>
4638 Use GOption for command line options.
4639 (g_igenerator_new, main): Simplify constructor and they way
4640 parameters are passed into it.
4646 * src/gen-introspect.c:
4647 * src/gen-introspect.h:
4649 Rename gen-introspect.[ch] to scanner.[ch]
4651 2007-12-09 Johan Dahlin <johan@gnome.org>
4655 * src/Makefile.am: Rename gen-introspect to g-idl-scanner,
4656 don't make the repository library and the other utilites link against
4659 * src/gen-introspect.c: (g_igenerator_create_object),
4660 (g_igenerator_create_interface), (g_igenerator_create_boxed),
4661 (g_igenerator_create_enum), (g_igenerator_create_flags),
4662 (g_igenerator_process_module_symbol),
4663 (g_igenerator_process_module), (g_igenerator_generate), (main):
4664 * src/gen-introspect.h:
4665 Refactor g_igenerator_process_types into smaller pieces.
4667 * tests/parser/Makefile.am:
4668 Depend on the gen-introspect binary
4670 2007-12-09 Johan Dahlin <johan@gnome.org>
4672 * src/gen-introspect.c (g_igenerator_process_types):
4673 Break into smaller pieces, one for each generated node type.
4675 2007-12-08 Johan Dahlin <johan@gnome.org>
4677 * src/gen-introspect.c: (g_igenerator_process_types),
4678 (g_igenerator_add_module):
4679 * tests/parser/Foo-expected.gidl:
4680 * tests/parser/foo-object.h:
4681 * tests/parser/foo.c: (foo_subobject_class_init),
4682 (foo_subobject_init):
4684 Add a subobject test and make sure to register defined classes
4685 in the lookup symbol hash table.
4687 2007-12-08 Johan Dahlin <johan@gnome.org>
4691 * src/gen-introspect.c: (g_igenerator_new), (lookup_symbol),
4692 (g_igenerator_process_types), (g_igenerator_add_module),
4693 (g_igenerator_add_include_idl), (main):
4694 * src/gen-introspect.h:
4695 * tests/parser/Makefile.am:
4696 * tests/parser/Foo-expected.gidl:
4698 Change the gen-introspect to generate namespaced module names,
4699 such as GLib.Object instead of GObject.
4700 Add a GLib.gidl which introduces GLib.Object and GLib.InitiallyUnowned,
4701 add a --include-idl parameter to gen-introspect,
4702 and update the parser test.
4704 2007-12-08 Johan Dahlin <johan@gnome.org>
4706 * src/gen-introspect.c:
4707 Move main to the end of the file and attempt to make it valid
4710 * tests/parser/Makefile.am (BUILT_SOURCES): Remove .repo here,
4711 we're not quite ready to generate metadata yet.
4716 Add a simple gen-introspect parser test
4718 2007-12-06 Gustavo J. A. M. Carneiro <gjc@gnome.org>
4720 reviewed by: Johan Dahlin <johan@gnome.org>
4723 * gobject-introspection.pc.in:
4725 * src/compiler.c: (format_output), (write_out_metadata), (main):
4726 * src/gen-introspect.c: (main):
4727 * src/gen-introspect.h:
4728 * src/generate.c: (write_callable_info), (write_repository),
4729 (load_metadata), (main):
4730 * src/gidlmodule.c: (g_idl_module_new),
4731 (g_idl_module_build_metadata):
4733 * src/gidlparser.c: (start_element_handler):
4734 * src/ginfo.c: (g_info_new), (g_info_from_entry),
4735 (g_base_info_get_name), (g_base_info_get_namespace),
4736 (g_base_info_is_deprecated), (g_base_info_get_annotation),
4737 (g_base_info_get_metadata), (g_function_info_get_symbol),
4738 (g_function_info_get_flags), (g_function_info_get_property),
4739 (g_function_info_get_vfunc), (signature_offset), (g_type_info_new),
4740 (g_callable_info_may_return_null),
4741 (g_callable_info_get_caller_owns), (g_callable_info_get_n_args),
4742 (g_callable_info_get_arg), (g_arg_info_get_direction),
4743 (g_arg_info_is_return_value), (g_arg_info_is_dipper),
4744 (g_arg_info_is_optional), (g_arg_info_may_be_null),
4745 (g_arg_info_get_ownership_transfer), (g_type_info_is_pointer),
4746 (g_type_info_get_tag), (g_type_info_get_param_type),
4747 (g_type_info_get_interface), (g_type_info_get_array_length),
4748 (g_type_info_is_zero_terminated),
4749 (g_type_info_get_n_error_domains), (g_type_info_get_error_domain),
4750 (g_error_domain_info_get_quark), (g_error_domain_info_get_codes),
4751 (g_value_info_get_value), (g_field_info_get_flags),
4752 (g_field_info_get_size), (g_field_info_get_offset),
4753 (g_registered_type_info_get_type_name),
4754 (g_registered_type_info_get_type_init),
4755 (g_struct_info_get_n_fields), (g_struct_info_get_field),
4756 (g_struct_info_get_n_methods), (g_struct_info_get_method),
4757 (find_method), (g_struct_info_find_method),
4758 (g_enum_info_get_n_values), (g_enum_info_get_value),
4759 (g_object_info_get_parent), (g_object_info_get_type_name),
4760 (g_object_info_get_type_init), (g_object_info_get_n_interfaces),
4761 (g_object_info_get_interface), (g_object_info_get_n_fields),
4762 (g_object_info_get_field), (g_object_info_get_n_properties),
4763 (g_object_info_get_property), (g_object_info_get_n_methods),
4764 (g_object_info_get_method), (g_object_info_find_method),
4765 (g_object_info_get_n_signals), (g_object_info_get_signal),
4766 (g_object_info_get_n_vfuncs), (g_object_info_get_vfunc),
4767 (g_object_info_get_n_constants), (g_object_info_get_constant),
4768 (g_interface_info_get_n_prerequisites),
4769 (g_interface_info_get_prerequisite),
4770 (g_interface_info_get_n_properties),
4771 (g_interface_info_get_property), (g_interface_info_get_n_methods),
4772 (g_interface_info_get_method), (g_interface_info_find_method),
4773 (g_interface_info_get_n_signals), (g_interface_info_get_signal),
4774 (g_interface_info_get_n_vfuncs), (g_interface_info_get_vfunc),
4775 (g_interface_info_get_n_constants),
4776 (g_interface_info_get_constant), (g_property_info_get_flags),
4777 (g_signal_info_get_flags), (g_signal_info_get_class_closure),
4778 (g_signal_info_true_stops_emit), (g_vfunc_info_get_flags),
4779 (g_vfunc_info_get_offset), (g_vfunc_info_get_signal),
4780 (g_constant_info_get_value), (g_union_info_get_n_fields),
4781 (g_union_info_get_field), (g_union_info_get_n_methods),
4782 (g_union_info_get_method), (g_union_info_is_discriminated),
4783 (g_union_info_get_discriminator_offset),
4784 (g_union_info_get_discriminator):
4785 * src/ginvoke.c: (g_function_info_invoke):
4786 * src/girepository.c: (g_irepository_register),
4787 (g_irepository_unregister), (g_irepository_get_default),
4788 (count_interfaces), (g_irepository_get_n_infos), (find_interface),
4789 (g_irepository_get_info), (g_irepository_find_by_name),
4790 (g_irepository_get_shared_library),
4791 (g_irepository_build_search_path), (g_irepository_register_file),
4792 (g_irepository_error_quark):
4793 * src/girepository.h:
4794 * src/gmetadata.c: (g_metadata_get_dir_entry),
4795 (g_metadata_check_sanity), (validate_header),
4796 (validate_array_type_blob), (validate_iface_type_blob),
4797 (validate_param_type_blob), (validate_error_type_blob),
4798 (validate_type_blob), (validate_arg_blob),
4799 (validate_signature_blob), (validate_function_blob),
4800 (validate_callback_blob), (validate_constant_blob),
4801 (validate_value_blob), (validate_field_blob),
4802 (validate_property_blob), (validate_signal_blob),
4803 (validate_vfunc_blob), (validate_struct_blob),
4804 (validate_enum_blob), (validate_object_blob),
4805 (validate_interface_blob), (validate_errordomain_blob),
4806 (validate_union_blob), (validate_blob), (validate_directory),
4807 (validate_annotations), (g_metadata_validate), (_g_metadata_init),
4808 (g_metadata_new_from_memory), (g_metadata_new_from_const_memory),
4809 (g_metadata_new_from_mapped_file), (g_metadata_free),
4810 (g_metadata_set_module), (g_metadata_get_namespace):
4812 * tests/Makefile.am:
4813 * tests/invoke/Makefile.am:
4814 * tests/invoke/invoke-namespace-find.sh:
4815 * tests/invoke/invoke.c: (main):
4817 Add a namespace/shared library mapping. fixes #313268.
4819 2007-12-03 Johan Dahlin <johan@gnome.org>
4821 * src/gidlparser.c (parse_type_internal): Disable char/gchar and
4824 2007-11-30 Jürg Billeter <j@bitron.ch>
4830 * src/gen-introspect.c: (g_idl_node_cmp), (g_igenerator_new),
4831 (g_igenerator_write_inline), (g_igenerator_write),
4832 (g_igenerator_write_indent), (g_igenerator_write_unindent),
4833 (field_generate), (value_generate), (constant_generate),
4834 (property_generate), (function_generate), (vfunc_generate),
4835 (signal_generate), (interface_generate), (struct_generate),
4836 (union_generate), (boxed_generate), (enum_generate),
4837 (node_generate), (module_generate), (get_type_from_type_id),
4838 (str_replace), (g_igenerator_process_properties),
4839 (g_igenerator_process_signals), (g_igenerator_process_types),
4840 (get_type_from_ctype), (g_igenerator_process_function_symbol),
4841 (g_igenerator_process_unregistered_struct_typedef),
4842 (g_igenerator_process_struct_typedef),
4843 (g_igenerator_process_union_typedef),
4844 (g_igenerator_process_enum_typedef),
4845 (g_igenerator_process_function_typedef),
4846 (g_igenerator_process_constant), (g_igenerator_process_symbols),
4847 (g_igenerator_add_symbol), (g_igenerator_is_typedef),
4848 (g_igenerator_generate), (main), (csymbol_new),
4849 (csymbol_get_const_boolean), (ctype_new), (ctype_copy),
4850 (cbasic_type_new), (ctypedef_new), (cstruct_new), (cunion_new),
4851 (cenum_new), (cpointer_new), (carray_new), (cfunction_new),
4852 (eat_hspace), (eat_line), (read_identifier),
4853 (g_igenerator_parse_macros):
4854 * src/gen-introspect.h:
4856 Import gen-introspect to generate introspection information by
4859 2007-11-30 Jürg Billeter <j@bitron.ch>
4861 * src/gidlnode.c: (g_idl_node_new): support creating callback nodes
4863 2007-11-30 Jürg Billeter <j@bitron.ch>
4865 * src/gidlparser.c: (end_element_handler): Don't leave requires
4868 2007-11-29 Johan Dahlin <johan@gnome.org>
4870 * src/gidlparser.c (parse_type_internal): Add char,
4871 gchar and guchar to the builtin types.
4873 2007-11-26 Johan Dahlin <johan@gnome.org>
4875 * src/ginfo.c: (g_object_info_get_type_name),
4876 (g_object_info_get_type_init):
4877 * src/girepository.c: (g_irepository_is_registered):
4878 * src/girepository.h:
4880 Add g_object_info_get_type_name, g_object_info_get_type_init and
4881 g_irepository_is_registered.
4883 2006-08-14 Jürg Billeter <j@bitron.ch>
4885 * src/gidlparser.c: (end_element_handler): Don't leave
4886 namespace and implements states too early.
4889 2007-11-26 Johan Dahlin <johan@gnome.org>
4891 * src/gmetadata.c (validate_struct_blob):
4892 pass blob_type to validate_function_blob instead of
4893 hard-coding BLOB_TYPE_STRUCT.
4895 Patch by Torsten Schoenfeld, fixes #314190
4897 2006-10-03 Torsten Schoenfeld <tsch@cvs.gnome.org>
4899 * src/compiler.c, src/generate.c, src/gidlnode.c,
4900 src/gidlparser.c, src/ginfo.c, src/girepository.c,
4901 tests/invoke/invoke.c, test/invoke/testfns.c: Hush compiler
4902 warnings about return values, signedness mismatches, unused
4903 variables, and unhandles enum values in switch statements.
4905 * tests/invoke/Makefile.am: Don't install the invoke test program.
4906 Add -I ../../src to the cflags used for the test functions files.
4908 2005-08-31 Torsten Schoenfeld <tsch@cvs.gnome.org>
4910 * src/girepository.h: Export g_invoke_error_quark.
4912 2005-08-31 Torsten Schoenfeld <tsch@cvs.gnome.org>
4914 * src/ginvoke.c: Remove the fallback implementation of
4915 g_function_info_invoke since we now formally depend on libffi.
4917 2005-07-25 Matthias Clasen <mclasen@redhat.com>
4919 * src/Makefile, tests/Makefile, tests/invoke/Makefile:
4920 Remove these files from cvs, as they are now generated.
4922 * src/gmetadata.c (validate_iface_type_blob): Don't
4923 complain if blob->pointer is not set, since that
4924 happens for enum and flag types. (#308935, Gustavo
4927 * Commit an autoconf-conversion patch by
4928 Gustavo Carneiro (#308708)
4930 2005-05-24 Matthias Clasen <mclasen@redhat.com>
4932 * src/compiler.c (main): Use it here to validate
4933 the generated metadata.
4935 * src/gmetadata.[hc]: Add code to validate a
4938 * metadata-format.txt: Updates
4940 2005-05-22 Matthias Clasen <mclasen@redhat.com>
4942 * tests/*: Add struct offsets to field and vfunc
4945 * src/generate.c (write_vfunc_info): Write offset
4946 information for vfuncs.
4948 * src/gidlnode.c (g_idl_node_build_metadata): Write
4949 the struct offsets into the metadata.
4951 * src/gidlparser.c: Parse the offset attributes of
4952 field and vfunc elements.
4954 * src/gidlnode.h: Add offset members to field and
4957 2005-05-21 Matthias Clasen <mclasen@redhat.com>
4961 * gidl.dtd: Updates.
4963 * src/g-idl-offsets.pl: A perl script which reads a .gidl
4964 file, creates, compiles and runs a C file, and folds the
4965 resulting struct offsets back into the .gidl file.
4967 2005-05-20 Matthias Clasen <mclasen@redhat.com>
4969 * src/gidlparser.c (start_field): Make fields in objects
4972 * src/gidlmodule.c: Include string.h
4977 * metadata-format.txt: Cleanup basic types.
4978 * src/*: Adapt to the changes.
4979 * tests/*: Adapt to the changes.
4980 * examples/gdk-pixbuf.gidl: Adapt to the changes.
4982 * src/gidlnode.c (g_idl_node_get_size): Report the correct
4983 size for enum blobs.
4984 (g_idl_node_get_full_size): Report the correct size for
4987 * src/gidlmodule.c (g_idl_module_build_metadata): Add some
4988 error checking for blob sizes.
4990 2005-05-19 Matthias Clasen <mclasen@redhat.com>
4992 * src/gidlnode.c (g_idl_node_build_metadata): Correctly handle
4993 interface types for which is_pointer is FALSE, e.g. enums.
4995 * src/gidlnode.c (g_idl_node_get_full_size)
4996 * src/gidlparser.c (parse_type_internal):
4997 * src/generate.c (write_type_info): Support unspecialized
4998 lists, hashtables and errors. Also emit a '*' after these.
5002 2005-05-17 Matthias Clasen <mclasen@redhat.com>
5006 * metadata-format.txt: Cleanups by Maciej Katafiasz.
5008 2005-05-15 Matthias Clasen <mclasen@redhat.com>
5010 * src/*.c: Change the directory to be addressed by
5011 1-based indexes, and use an index of zero to mean
5014 2005-05-15 Matthias Clasen <mclasen@redhat.com>
5016 * tests/roundtrips.sh (SIMPLE_TESTS): Add union.test.
5018 * tests/union.test: Add a union test.
5020 * src/generate.c: Handle unions.
5022 * src/girepository.h:
5023 * src/ginfo.c: Add GIUnionInfo and functions to access it.
5025 * src/gidlnode.c: Handle GIdlNodeUnion nodes.
5027 * src/gidlparser.c (start_union): Parse <union> elements.
5029 * src/gidlnode.h: Add a GIdlNodeUnion.
5031 * gidl.dtd: Add a <union> element.
5033 * src/gmetadata.c (g_metadata_check_sanity): Check
5036 * src/gmetadata.h: Add union_blob_size to Header,
5039 * metadata-format.txt: Add a UnionBlob.
5041 2005-05-13 Matthias Clasen <mclasen@redhat.com>
5043 * tests/*: Update testcases.
5045 * src/generate.c (write_callable_info): Don't forget to
5046 write transfer and null-ok attributes for return types
5049 * src/girepository.h:
5050 * src/ginfo.c (g_callable_info_may_return_null):
5051 New function to find out if a function may return NULL.
5053 * src/compiler.c (format_output): Make the generated
5056 * README: Point to a recent libffi snapshot.
5058 * tests/invoke/*: Some invoke tests.
5060 * src/Makefile: Add ginvoke.c and the necessary
5063 * src/girepository.h (g_function_info_invoke): Add
5066 * src/ginvoke.c (g_function_info_invoke): Initial
5067 implementation of invoke functionality based on libffi.
5069 * src/gidlnode.c (g_idl_node_build_metadata): Pass the
5070 strings and types hash tables in the right order when
5072 (find_entry_node): Free the name parts.
5074 2005-05-12 Johan Dahlin <johan@gnome.org>
5076 * src/generate.c: Generate consistent end tags.
5080 2005-05-12 Matthias Clasen <mclasen@redhat.com>
5084 * src/gidlparser.c (start_function): Actually add
5085 methods to objects. (Steven Walter)
5087 * src/girepository.h:
5088 * src/ginfo.c: Rename Transfer and Direction to
5089 GITransfer and GIDirection. (Torsten Schoenfeld)
5091 * tests/*: Make tests work with the changes in name
5094 * src/gidlnode.c (find_entry_node): Parse qualified
5095 names and generate xref nodes for them if needed. Don't
5096 require all modules to be loaded any more.
5098 * src/gidlmodule.c (g_idl_module_build_metadata): Choke
5101 * src/ginfo.c (g_object_info_get_parent): Return NULL
5102 if blob->parent is 0. Still need to make sure index
5105 * src/generate.c: Generate qualified names when
5106 referring to non-local types. Emit transfer attribute
5109 * src/compiler.c (format_output): Put the function
5110 attributes where gcc accepts them.
5112 2005-05-11 Matthias Clasen <mclasen@redhat.com>
5114 * src/compiler.c (main): Add a --verbose cmdline option
5115 and only log messages if it is specified.
5118 * src/gidlnode.c (init_stats, dump_stats): Collect some
5119 statistics on string and type sharing.
5121 * src/gidlmodule.c (g_idl_module_build_metadata): Use
5122 g_message() instead of fprintf().
5124 * src/gidlnode.c (g_idl_node_free): Make this more robust.
5125 (g_idl_node_get_size): Implement for structs.
5126 (g_idl_node_get_full_size): Handle parent being NULL.
5127 (serialize_type): Handle lookup failures more gracefully.
5129 2005-05-10 Matthias Clasen <mclasen@redhat.com>
5131 * src/gidlnode.c (g_idl_node_get_full_size): Correct the
5132 size calculation for 2-parameter types and for objects.
5134 * src/compiler.c: Add a cmdline option for debug output
5135 and install a log handler to implement it.
5136 * src/gidlnode.c: Add some debug spew.
5140 * src/gidlmodule.c (g_idl_module_build_metadata): Don't
5141 forget to count the module name when calculating the
5142 required size for the metadata.
5145 * src/gidlparser.c: Fix compiler warnings.
5147 2005-05-09 Matthias Clasen <mclasen@redhat.com>
5149 * src/compiler.c (main): Free the option context.
5151 * gidl.dtd: Clean up handling of names. All elements
5152 have a "name", only the elements corresponding to
5153 actual callable functions (function, method, constructor),
5154 have an additional "symbol" attribute holding the
5155 dlsym()-able function name.
5157 * src/generate.c: Adapt to generate xml matching the
5161 * src/gidlnode.c: Adapt to parse the new dtd.
5163 * tests/*.test: Adjust to the new dtd.
5165 * metadata-format.txt:
5166 * src/gmetadata.h: Remove the short_name field
5168 * src/gmetadata.c: Shrink size of ValueBlob to 12.
5169 * src/girepository.h:
5170 * src/ginfo.c (g_value_info_get_short_name): Removed
5172 2005-05-09 Matthias Clasen <mclasen@redhat.com>
5174 * gidl.dtd: Allow constructors for boxed types,
5175 patch by Jonathan Blandford.
5178 2005-05-09 Matthias Clasen <mclasen@redhat.com>
5180 * --- Initial import ---