1 2008-11-16 Andreas Rottmann <a.rottmann@gmx.at>
3 Bug 560241 - Out-arguments should not be marked as being pointers
6 * giscanner/transformer.py: Differentiate type creation logic
7 between parameters and struct components.
9 2008-11-15 Colin Walters <walters@verbum.org>
11 * giscanner/dumper.py: Check return code from pkg-config
14 2008-11-14 Johan Dahlin <jdahlin@async.com.br>
16 * tests/everything/everything.c (test_array_int_in),
17 (test_array_gtype_in):
18 * tests/everything/everything.h:
19 Rename the int/gtype array tests. Make the return value
20 useful, an aggregation of the array input values.
22 2008-11-14 Johan Dahlin <jdahlin@async.com.br>
24 * tests/everything/Makefile.am:
25 * tests/everything/everything.c:
26 * tests/everything/everything.h:
27 * tests/everything/gitesttypes.c:
28 * tests/everything/gitesttypes.h:
29 Rename gitesttypes.[ch] to everything.[ch]
31 2008-11-13 Andreas Rottmann <a.rottmann@gmx.at>
33 Bug 560708 – Don't treat arrays that have a length specified as
34 zero-terminated by default
36 * giscanner/transformer.py: Default to non zero terminated for
38 * tests/*: Update, add test for zero vs not.
40 2008-11-13 Andreas Rottmann <a.rottmann@gmx.at>
42 Bug 557788 - Return types for constructors in generated typelib bogus
44 * girepository/girnode.c: Namespace-qualify XREFs; not doing so is
45 obviously broken in the face of duplicate names in different
47 * tests/scanner/*expected.gir: Fix up.
49 2008-11-13 Owen Taylor <otaylor@redhat.com>
51 * girepository/girffi.c: Fix "Unexpected time for time_t"
54 2008-11-13 Colin Walters <walters@verbum.org>
56 Bug 558436 - avoid having scanner load app code
58 * giscanner/cgobject.py: Delete; we no longer load shared
60 * giscanner/dumper.py: Support for linking a library to
61 a stub binary for introspection.
62 * giscanner/glibtransformer.py: Rewrite to use gdump XML
63 from invocation of child binary.
64 * giscanner/transformer.py: Fix up to use fully qualified
65 name in parse tree. Make parse_ctype public so we can use
66 it inside glibtransformer.
67 * tests/scanner/barapp.c: New test, using --program arg
69 * tests/*: Update to use common.mk for invoking scanner.
70 * tools/g-ir-scanner: Add options --program, --program-arg,
72 * docs/g-ir-scanner.1: Update.
74 2008-11-13 Colin Walters <walters@verbum.org>
76 * configure.ac: Depend on Gio, we use it in gdump.c.
77 * girepository/gdump.c: Code to dump GType data to XML.
78 * girepository/girepository.c: Add option group for dumping.
79 * girepository/girepository.h: Define API for the above.
81 2008-11-13 Colin Walters <walters@verbum.org>
83 * common.mk: Add a file to include with Makefile fragments
84 useful for scanner invocation.
86 2008-11-13 Tommi Komulainen <tommi.komulainen@iki.fi>
88 * tests/everything/gitesttypes.c (test_filename_return): Return
89 strings in filename encoding.
91 2008-11-13 Owen Taylor <otaylor@redhat.com>
93 Bug 560253 – Add structure and boxed types to Everything test module
95 * tests/everything/gitesttypes.[ch]: Add examples of:
97 Plain old data structs
98 Plain old data structs with nested fields
100 Plain old data boxed with nested fields
101 More complicated boxed types with internal state
103 2008-11-12 Johan Dahlin <jdahlin@async.com.br>
105 * tests/everything/gitesttypes.c (test_gtype_in):
106 * tests/everything/gitesttypes.h:
107 Add a test of GType arrays, a la gtk_list_store_set_columns.
109 2008-11-12 Owen Taylor <otaylor@redhat.com>
111 Bug 560419 – Cache includes when parsing
113 Keep track of all modules parsed within a GIrParser, and when a
114 module is referenced a second time, use the existing parsed copy
115 instead of reparsing.
117 2008-11-12 Owen Taylor <otaylor@redhat.com>
119 Fix management of ParseContext.includes_modules (#560419)
121 * girepository/girparser.c: Fix some trivial bugs in managing the
122 list of include modules. (Add to module's list twice, not
123 initialized to NULL, not freed.)
125 2008-11-12 Owen Taylor <otaylor@redhat.com>
127 Keep aliases and disguised_structures local to each module (#560419)
129 * girepository/girmodule.[ch]: When parsing, keep keep a separate
130 hash tables of aliases and 'disguised' flags for each module, and
131 store that on the module.
133 After parsing an include merge the aliases/disguised flags to the
136 * girepository/girparser.c: Remove 'prefix_aliases' flag and
137 always prefix aliases/disguised structure types when parsing; this
138 simplifies the code considerably.
140 2008-11-12 Owen Taylor <otaylor@redhat.com>
142 Fix mismatches between .gir name and 'name' attribute (#560419)
144 * tests/boxed.gir tests/constant.gir tests/enum.gir tests/invoke/invoke.c
145 tests/invoke/testfns-1.0.gir tests/object.gir tests/struct.gir: Fix places
146 where the 'name' element of <namespace/> didn't match the filename of the
147 gir, an assumption that the compiler has always expected and now enforces.
149 2008-11-12 Owen Taylor <otaylor@redhat.com>
151 Only allow one <namespace/> element per <repository/> (#560419)
153 * girepository/girparser.c: The logic in girparser.c didn't work
154 very well if there were multiple <namespace/> nodes within a
155 single <repository/> (context->namespace was always the overall
156 filename and not the the name specified in the <namespace/>
157 element for one thing; this would cause aliases to be mis-prefixed
158 in include modules.) Also check that the "name" in the
159 <namespace/> node matches the filename.
161 2008-11-12 Owen Taylor <otaylor@redhat.com>
163 Add a GirParser object to hold the state of a compilation
165 * girepository/girparser.[ch] tools/compiler.c: Add a toplevel
166 GirParser object to hold state that is global across a
167 compilation. Currently just holds the include path, but will
168 eventually also keep a cached list of parsed modules.
170 2008-11-12 Tommi Komulainen <tommi.komulainen@iki.fi>
172 * girepository/girepository.c (find_namespace_latest): Fix
175 2008-11-12 Tommi Komulainen <tommi.komulainen@iki.fi>
177 * configure.ac: use 'introspection' component for bugs
179 2008-11-12 Johan Dahlin <jdahlin@async.com.br>
181 * tests/everything/gitesttypes.c (test_filename_return):
182 * tests/everything/gitesttypes.h:
183 Add a filename return test.
185 2008-11-12 Tommi Komulainen <tommi.komulainen@iki.fi>
187 * tests/offsets/Makefile.am (gitestoffsets.c): fix
188 gen-gitestoffsets invocation with builddir != srcdir
190 2008-11-12 Johan Dahlin <jdahlin@async.com.br>
192 * girepository/girepository.c:
193 Change the element type from utf8 to filename
194 * girepository/girnode.c (g_ir_node_build_typelib):
195 Special case filename equally to utf8 here.
197 2008-11-12 Johan Dahlin <jdahlin@async.com.br>
200 Remove unused variables, add a dependency of girepository.ch, so when
201 they change we rebuild the gir automatically.
203 2008-11-12 Johan Dahlin <jdahlin@async.com.br>
205 * girepository/girepository.c (g_irepository_get_search_path):
206 * girepository/girepository.h:
207 Add a g_irepository_get_search_path, so we can access the search
210 2008-11-12 Johan Bilien <jobi@via.ecp.fr>
212 Bug 560474 – g-ir-compiler crashes when compiling the glib gir
214 * girepository/girparser.c: avoid freeing an uninitialized pointer
216 2008-11-12 Johan Dahlin <jdahlin@async.com.br>
219 * giscanner/glibtransformer.py:
220 * tools/g-ir-scanner:
221 Add a GIRepository-2.0.gir. Change the libtool lookup slightly
222 so we can just pass in --library=foo/bar/baz.la and the scanner
223 does the right thing.
224 Don't warn for _get_type() functions if they don't take any
227 2008-11-11 Owen Taylor <otaylor@redhat.com>
229 Bug 560404 – Prefix types when resolving aliases in included modules
231 * girepository/girparser.c: When resolving aliases in an included
232 module, prefix types before looking them up.
234 2008-11-11 Owen Taylor <otaylor@redhat.com>
236 Compute field offsets and overall size for object structures
238 Bug 560326 – Fails to build Gtk-2.0.typelib with "Unexpected non-pointer
239 field of type object in structure"
241 Do basic computation of field offsets for objects and interfaces;
242 this doesn't attempt to address all of the "mess" for virtual
243 functions described in Bug 560281.
245 2008-11-11 Tommi Komulainen <tommi.komulainen@iki.fi>
247 Bug 560308 – g-ir-compiler goes in infinite loop on Gdk-2.0.gir
249 Based on patch by Johan Bilien.
251 * giscanner/transformer.py (_create_member, _create_parameter):
252 Resolve types here as well.
253 (_resolve_type_name_1): Try resolving using 'ctype' first since
254 it's least ambiguous. Fixes struct member type resolution with
255 similarly named types, e.g. Gdk.PangoRendererClass and
257 * tests/scanner/foo*: Add test.
259 2008-11-11 Owen Taylor <otaylor@redhat.com>
261 * girepository/girparser.c: Search provided include dirs before
262 the default directories.
264 2008-11-11 Owen Taylor <otaylor@redhat.com>
266 * girepository/giroffsets.c: Include fully-qualified names in
269 2008-11-11 Owen Taylor <otaylor@redhat.com>
271 * girepository/giroffsets.c: Fail gracefully with an informative
272 error message when recursion is encountered when computing a
275 2008-11-11 Owen Taylor <otaylor@redhat.com>
277 * girepository/girparser.c: Remove an unused variable.
279 2008-11-10 Owen Taylor <otaylor@redhat.com>
281 Add tests for field offset computations
283 * tests/offsets/offsets.h: Header file with structure definitions to test
285 * tests/offsets/gen-gitestoffsets: Generate a C program that computes
286 field offsets for the structures in offsets.h two ways: using
287 the information from a generated typelib, and as computed by the
290 We diff these two versions to test that everything is OK.
292 2008-11-10 Owen Taylor <otaylor@redhat.com>
294 Remove field offsets from g-ir-generate output and test inputs
296 Field offsets are a) architecture dependent so they shouldn't be part
297 of the architecture-independent gir format which is installed in
298 datadir. b) Are architecture-dependent so they shouldn't be in test
301 * girepository/girparser.c: Don't parse offset for fields
302 * tools/generate.c: Don't parse offset for fields
303 * tests/*.gir test/scanner/*.tgir: Remove offsets
305 (Virtual function and discriminator offsets are not removed, as they
306 aren't fully hooked up to the field-offset computation machinery yet.)
308 2008-11-10 Owen Taylor <otaylor@redhat.com>
310 Bug 560252 - Compute field offsets before writing typelib
312 * girepository/girnode.h: Store the total size and alignment for
313 GIrNodeStruct/Boxed/Union.
315 * girepository/giroffset.c: New file implementing computation of
316 structure field offsets.
318 * girepository/girnode.c: Compute structure field offsets before
319 writing types into the typelib.
321 * docs/typelib-format.txt: Document that a field offset of 0xFFFF
322 means "unknown". Also fix description of the discriminator_offset
325 2008-11-10 Owen Taylor <otaylor@redhat.com>
327 Bug 560250 - Fully parse included modules
329 For some things, like computing structure offsets to put into the typelib
330 we need more than just the aliases from included modules. Do a completel
331 parse of included modules and store in module->included_modules.
333 Also add g_ir_find_node() to find node information from within the
334 active set of modules and their includes.
336 2008-11-10 Owen Taylor <otaylor@redhat.com>
338 Split g_ir_ffi_get_ffi_type() out from ginvoke.c
340 Extract a function to convert GITypeTag to ffi_type from the internals
341 of ginvoke.c. This will be useful in figure out structure alignment.
343 Also fix handling of gsize and time_t to be portable. (Add a check
344 to configure.ac to figure out the width of time_t.)
346 2008-11-10 Owen Taylor <otaylor@redhat.com>
348 Bug 560248 – "disguised structures"
350 Certain types like GIConv and GdkAtom are pointers internally but don't
351 look like pointers when referenced. They have the form.
353 typedef struct _X *X;
355 Parse these as structures/records but mark them in the gir with a 'disguised'
356 attribute so that we know that they need special handling.
358 In the typelib treat them like any other structure.
360 2008-11-09 Jürg Billeter <j@bitron.ch>
363 * giscanner/girwriter.py:
365 Write throws attribute for virtual functions, fixes bug 559703
367 2008-11-07 Johan Dahlin <jdahlin@async.com.br>
369 * giscanner/libtoolimporter.py (LibtoolImporter.find_module): Clear
370 up some confusion about the second argument to find_module, it's
371 actually the packages __path__ attribute which we can safely ignore
373 (LibtoolImporter.load_module): Set module.__loader__ as per PEP 302.
375 2008-11-07 Owen Taylor <otaylor@redhat.com>
377 Bug 559737 – Deal with continuations in macros
379 * giscanner/giscannerlexer.l: Treat continuation lines the same
380 as regular newlines. This makes the scanner not complain about
381 #define foo(x) \ <stuff> inside a C file. There's no attempt
382 however to handle parsing macro definitions split across lines.
384 2008-11-07 Johan Dahlin <jdahlin@async.com.br>
386 * giscanner/cachestore.py:
387 Handle broken cache entries, write only filesystems and
388 running out of diskspace.
390 2008-11-07 Owen Taylor <otaylor@redhat.com>
392 * giscanner/giscannermodule.c (pygi_source_scanner_lex_filename):
393 Set current_filename before lexing the file so error messages
394 are reported in the right file.
396 2008-11-06 Colin Walters <walters@verbum.org>
398 * tests/everything/*: Add some tests for strv.
400 2008-11-05 Colin Walters <walters@verbum.org>
402 * girepository/ginvoke.c (g_function_info_invoke): Don't use
403 nested scope local variable for error which may go away after
404 conditional is complete.
406 2008-11-05 Colin Walters <walters@verbum.org>
408 * giscanner/scannerlexer.l: Avoid static 256 char buf which we
409 manipulate hackily; just use GString. This avoids an
410 uninitialized memory read pointed out by Havoc.
412 2008-11-04 Johan Dahlin <jdahlin@async.com.br>
414 * giscanner/__init__.py:
416 * giscanner/cachestore.py:
417 * giscanner/cgobject.py:
418 * giscanner/girparser.py:
419 * giscanner/girwriter.py:
420 * giscanner/giscannermodule.c:
421 * giscanner/glibast.py:
422 * giscanner/glibtransformer.py:
423 * giscanner/libtoolimporter.py:
424 * giscanner/minixpath.py:
425 * giscanner/odict.py:
426 * giscanner/sourcescanner.c:
427 * giscanner/sourcescanner.h:
428 * giscanner/sourcescanner.py:
429 * giscanner/transformer.py:
430 * giscanner/utils.py:
431 * giscanner/xmlwriter.py:
433 Relicense the giscanner library under LGPLv2+.
434 This has been approved by all contributors.
436 2008-11-01 Owen Taylor <otaylor@redhat.com>
438 Bug 558848 giparser.py: shared library should be optional
440 When parsing a .gir, allow the shared-library attribute
441 of <namespace/> to be missing: this corresponds to the handling
442 in libgirepository and elsewhere.
444 2008-11-01 Tommi Komulainen <tommi.komulainen@iki.fi>
446 Bug 557898 – Fails to build on OSX 10.4
448 * configure.ac: Check for $shrext_cmds that should be implicitly
449 available if you're using libtool >= 2.0. If undefined, call
450 libtool --config explicitly to get its value.
451 * girepository/gtypelib.c: Remove special case for (non-)Darwin
454 2008-10-31 Colin Walters <walters@verbum.org>
456 * COPYING, COPYING.lib, COPYING.tools: Clarify licensing status.
458 2008-10-31 Johan Dahlin <jdahlin@async.com.br>
460 * configure.ac: Post release version bump
463 2008-10-31 Johan Dahlin <jdahlin@async.com.br>
467 * docs/release-checklist.txt:
470 2008-10-31 Johan Dahlin <jdahlin@async.com.br>
472 * Makefile.am: add an upload-release target
473 * docs/release-checklist.txt:
474 Release process documentation
476 2008-10-31 Colin Walters <walters@verbum.org>
478 Bug 558109 – _g_typelib_init fails to find shared libraries
480 * transformer/glibtransformer.py: Use ctypes' find_library
481 on passed libraries and write that for the shared-library
482 entry. We want to avoid depending on -devel packages.
484 2008-10-31 Johan Dahlin <jdahlin@async.com.br>
486 * docs/g-ir-scanner.1:
487 Document the renaming options.
489 2008-10-31 Tommi Komulainen <tommi.komulainen@iki.fi>
491 * giscanner/Makefile.am:
492 * tests/invoke/Makefile.am:
493 * tests/repository/Makefile.am: List in-tree libraries first in
494 LDADD / LIBADD. If installed library is listed first, the
495 resulting binary will prefer installed version to one in .libs,
496 possibly making 'make check' behave strangely.
498 2008-10-30 Tommi Komulainen <tommi.komulainen@iki.fi>
500 * giscanner/ast.py: map 'id' (ObjC) to 'any' type to stop
501 gir-repository from choking with gdk/quartz
503 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
505 * giscanner/giscannermodule.c (calc_attrs_length),
506 (pygi_collect_attributes):
507 * giscanner/xmlwriter.py:
508 Write a C version of the xml namespace formatter.
509 Saves 15% of the time it takes to create a gtk gir.
511 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
513 * giscanner/xmlwriter.py: Abstract attribute formatting
514 to a function external to the XMLWriter class.
516 * giscanner/scannerlexer.l:
517 Parse and discard __typeof and __attribute.
519 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
521 * giscanner/girparser.py:
522 Remove arguments from the constructor, move them to
523 separate accessors. Add a new parse_tree method
524 which takes an element tree instance.
525 * tools/g-ir-scanner:
526 Update callsite for this
528 * giscanner/Makefile.am:
529 * giscanner/cachestore.py:
530 * giscanner/transformer.py:
531 Cache the include parsing. Saves ~25% time when
532 creating vte (which includes everything up to gtk+).
534 2008-10-30 Colin Walters <walters@verbum.org>
536 * giscanner/transformer.py: Don't reparse includes
537 we've already processed.
539 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
541 * giscanner/girparser.py:
542 * giscanner/transformer.py:
543 Avoid parsing parameters, types etc when parsing
544 includes. Should speed up include parsing a bit.
546 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
548 * giscanner/girparser.py:
549 Avoid big if/else and use a dispatch table like
552 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
554 * giscanner/transformer.py:
555 Clean up include parsing and registration.
557 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
559 * giscanner/transformer.py:
562 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
564 Bug 558383 – builddir != srcdir build fails if giscanner python module not already installed
567 construct PYTHONPATH just once
569 * tests/everything/Makefile.am:
570 * tests/scanner/Makefile.am:
571 add $(top_srcdir) to PYTHONPATH to
572 handle builddir != srcdir
574 * giscanner/libtoolimporter.py:
575 * giscanner/sourcescanner.py:
576 Make the libtoolimporter work when distchecking too.
578 Mostly based on patch by Tommi Komulainen
580 2008-10-29 Owen Taylor <otaylor@redhat.com>
582 * giscanner/glibtransformer.py: If a filename of an existing
583 file is passed to --library, hunt for it directly, rather than
584 searching for a corresponding library.
586 2008-10-29 Johan Dahlin <jdahlin@async.com.br>
588 * giscanner/libtoolimporter.py:
589 * giscanner/sourcescanner.py:
590 Clean up the libtool importer a bit. Add a context so we
591 can use it through a with statement.
592 Don't just look in the current directory, look in the whole
595 2008-10-29 Tommi Komulainen <tommi.komulainen@iki.fi>
597 Bug 558065 – gitesttypes should be installed
601 * tests/types/Makefile.am -> tests/everything/Makefile.am
602 * tests/types/gitesttypes.c -> tests/everything/gitesttypes.c
603 * tests/types/gitesttypes.h -> tests/everything/gitesttypes.h
604 move tests/types to tests/everything
606 * tests/everything/Makefile.am: build normal shared library
607 libgirepository-everything.so.1.0.0 and corresponding typelib
608 Everything-1.0.typelib
610 * tests/everything/Makefile.am: explicitly link libtool
611 versioning with typelib versioning with variables
613 2008-10-28 Johan Bilien <jobi@via.ecp.fr>
615 * tools/g-ir-scanner: add LD_LIBRARY_PATH to LPATH before calling ld.
617 2008-10-27 Johan Bilien <jobi@via.ecp.fr>
619 * gio/gio-2.0.c: add allow-none annotations, based on the pygobject
622 2008-10-27 Johan Bilien <jobi@via.ecp.fr>
624 Bug 558068 – when invoking a method, offset the in arguments by one,
627 * tests/invoke/invoke.c, tests/invoke/testfns.c,
628 tests/invoke/testfns-1.0.gir: Add testing of method and constructor.
629 * girepository/ginvoke.c: do not offset the index of given out
630 arguments by one for methods, "this" is provided as in argument only.
632 2008-10-27 Johan Bilien <jobi@via.ecp.fr>
634 * gir/gio-2.0.c: add annotation for g_file_delete
636 2008-10-27 Tommi Komulainen <tommi.komulainen@iki.fi>
638 Bug 558062 – provide and use paths in the .pc file
640 * gobject-introspection-1.0.pc.in: provide typelibdir variable
641 for where .typelibs should be installed (callers shouldn't need
642 to construct paths from bits and pieces)
644 2008-10-25 Andreas Rottmann <a.rottmann@gmx.at>
646 Bug 557791 – g_irepository_require() could return a GTypelib *
648 * girepository/girepository.c: Return GTypelib; this is useful
649 for low level manipulation.
651 2008-10-25 Colin Walters <walters@verbum.org>
653 Bug 557788 – Return types for constructors in generated typelib bogus
655 * giscanner/glibtransformer.py: Don't resolve ctors incrementally,
656 rely on end pass resolution.
658 2008-10-25 Andreas Rottmann <a.rottmann@gmx.at>
660 Bug 557786 - support fixed size arrays
662 * girepository/ginfo.c: Add g_type_info_get_array_fixed_size.
663 * giscanner/scannerparser.y: Retain fixed array size.
664 * giscanner/ast.py: Add to note.
665 * giscanner/girwriter.py: Write to gir.
666 * girepository/girnode.c: Write it to typelib.
667 * tools/generate.c: Generate.
668 * tests/*: Add tests.
670 2008-10-25 Colin Walters <walters@verbum.org>
672 Bug 557076 - move typelibs to $libdir
674 * configure.ac: Steal some configury bits from dbus to expand
676 * gir/Makefile.am: Move to libdir.
677 * girepository/girepository.c: Stop searching XDG_DATA_DIRS;
678 instead just look at one hardcoded path in libdir.
679 * acinclude.m4: Bits from dbus.
681 2008-10-24 Johan Dahlin <johan@gnome.org>
683 * girepository/girnode.c (g_ir_node_check_unhandled_members):
684 Be quiet, do not warn about unhandled members.
686 2008-10-24 Johan Dahlin <johan@gnome.org>
688 * girepository/gtypelib.c:
689 Only use SHLIB_SUFFIX on darwin, otherwise use
690 G_MODULE_SUFFIX, we cannot get shext_cmds from libtool 2.2.
692 2008-10-24 Lucas Rocha <lucasr@gnome.org>
694 Bug 557623 - Constructors shouldn't be flagged as methods.
696 * girepository/ginfo.c (g_function_info_get_flags): ditto.
698 2008-10-24 Johan Dahlin <johan@gnome.org>
700 * giscanner/scannerparser.y:
701 Check against division by zero for the modula operator.
702 This fixes header parsing of OSX system headers included
705 2008-10-24 Johan Dahlin <johan@gnome.org>
709 Add a CONTRIBUTORS file and dist it.
711 2008-10-23 Tommi Komulainen <tommi.komulainen@iki.fi>
713 Bug 556739 – transfer-ownership attribute should be mandatory in .gir
715 * girepository/girparser.c (parse_param_transfer):
716 * giscanner/transformer.py (_create_parameter, _create_return):
717 * giscanner/girwriter.py (_write_return, _write_parameter):
718 * tools/generate.c (write_callable_info): always write and
719 require "transfer-ownership" for return-values and parameters
722 * tests/invoke/testfns-1.0.gir:
724 * tests/scanner/DrawableAdditions.xml:
725 * tests/scanner/GtkFrob-1.0-expected.tgir:
726 * tests/scanner/annotation-1.0-expected.tgir:
727 * tests/scanner/drawable-1.0-expected.tgir:
728 * tests/scanner/drawable-injected-1.0-expected.gir:
729 * tests/scanner/drawable-injected-1.0-expected.tgir:
730 * tests/scanner/foo-1.0-expected.tgir: Updated
732 2008-10-23 Tommi Komulainen <tommi.komulainen@iki.fi>
734 * giscanner/cgobject.py: build fundamental types same way as glib
736 * giscanner/glibtransformer.py (_type_from_gtype): record GType
737 when constructing the Type from it
739 * giscanner/glibtransformer.py (_adjust_transfer): Check whether
740 the parameter is a GObject from its GType, if available.
742 * giscanner/glibtransformer.py (_adjust_transfer):
743 * tests/scanner/foo-1.0-expected.gir:
744 * tests/scanner/foo-1.0-expected.tgir: deduce
745 transfer-ownership from GTypes
747 2008-10-23 Tommi Komulainen <tommi.komulainen@iki.fi>
749 * giscanner/transformer.py (_create_parameter):
750 * tests/scanner/foo-1.0-expected.gir: make varargs
751 transfer-ownership="none"
753 2008-10-23 Colin Walters <walters@verbum.org>
755 Bug 556739 - transfer ownership
757 * giscanner/ast.py: Refactor Parameter/Return to share
758 common attributes. Add transfer_inferred attribute
759 which says whether or not we made a guess.
760 * giscanner/transformer.py: Add much more extensive
761 heuristics around parameter and return transfer.
762 * giscanner/glibtransformer.py: Adjust to inspect
766 2008-10-22 Tommi Komulainen <tommi.komulainen@iki.fi>
768 Bug 557377 – Add test to ensure annotations survive the roundtrip via typelib
770 * tests/scanner/Makefile.am:
771 * tests/scanner/annotation-1.0-expected.tgir:
772 * tests/scanner/drawable-1.0-expected.tgir:
773 * tests/scanner/drawable-injected-1.0-expected.tgir:
774 * tests/scanner/foo-1.0-expected.tgir:
775 * tests/scanner/GtkFrob-1.0-expected.tgir:
776 * tests/scanner/utility-1.0-expected.tgir: Add test to ensure
777 annotations survive the roundtrip via typelib
779 The expectations are as currently produced by g-ir-generate,
780 comparison with the .gir files shows there are differences.
782 2008-10-23 Johan Bilien <jobi@via.ecp.fr>
784 Bug 557468 – Support for GI_TYPELIB_PATH
786 * girepository/girepository.c: if the GI_TYPELIB_PATH is set, add the
787 provided paths to the global search path.
789 2008-10-22 Tommi Komulainen <tommi.komulainen@iki.fi>
791 Bug 557379 – g-ir-generate not writing the 'abstract' attribute
793 * tests/scanner/drawable-1.0-expected.tgir:
794 * tests/scanner/drawable-injected-1.0-expected.tgir:
795 * tests/scanner/foo-1.0-expected.tgir:
796 * tools/generate.c (write_object_info): write 'abstract'
797 attribute for classes
799 2008-10-22 Lucas Rocha <lucasr@gnome.org>
801 * girepository/girmodule.c, girepository/gtypelib.c,
802 girepository/girparser.[ch]: fix some build warnings.
804 2008-10-22 Tommi Komulainen <tommi.komulainen@iki.fi>
806 Bug 557405 – Use 'allow-none' consistently
808 * docs/typelib-format.txt:
809 * girepository/ginfo.c (g_arg_info_may_be_null):
810 * girepository/girnode.c (g_ir_node_build_typelib):
811 * girepository/girnode.h (struct _GIrNodeParam):
812 * girepository/girparser.c (start_parameter):
813 * girepository/girwriter.c (function_generate):
814 * girepository/gtypelib.h (ArgBlob):
816 * tests/function.gir:
817 * tools/generate.c (write_callable_info): Use 'allow-none'
818 consistently throughout
820 2008-10-22 Tommi Komulainen <tommi.komulainen@iki.fi>
822 Bug 557092 – Callback annotations not used
824 * giscanner/transformer.py (_create_callback): use annotations
826 * tests/scanner/annotation.h
827 * tests/scanner/annotation-1.0-expected.gir: add tests
829 2008-10-21 Colin Walters <walters@verbum.org>
831 * giscanner/scannerlexer.l: Don't require trailing whitespace after
832 uncommented parameters.
835 2008-10-21 Colin Walters <walters@verbum.org>
837 * girepository/girepository.c: Ensure that when doing an unversioned
838 require, we prefer items earlier in the search path to later ones.
840 2008-10-21 Owen Taylor <otaylor@redhat.com>
842 * giscanner/transformer.py: For string parameters allow transfer annotation
843 to override the standard automatic guessing based on 'const'.
845 2008-10-21 Johan Bilien <jobi@via.ecp.fr>
847 Bug 557241 – "throws" flag for functions
849 * tests/scanner/drawable-1.0-expected.gir,
850 tests/scanner/drawable-injected-1.0-expected.gir,
851 tests/scanner/drawable.[ch]: add simple test for throwing
852 function (has GError ** as last argument)
854 * giscanner/ast.py: add a 'throws' flag to Function
855 * giscanner/glibtransformer.py: if a function's last paramerter is
856 a GError, set the 'throws' flag and remove that parameter
857 * giscanner/girwriter.py: write out the 'throws' attribute
858 * giscanner/girparser.py: support parsing the 'throws' attribute
860 * tests/repository/gitestthrows.c: add a simple test to check the
861 throws flag in a typelib and invoke the function
863 * girepository/ginfo.c, girepository/girnode.[ch],
864 girepository/girnode.h, girepository/girparser.c,
865 girepository/girepository.h: Add and parse the GI_FUNCTION_THROWS flag
867 * girepository/ginvoke.c: if a function throws, add a GError as last
868 arguments, and propagate the error to the invoker.
870 2008-10-21 Tommi Komulainen <tommi.komulainen@iki.fi>
872 * giscanner/transformer.py (_create_parameters): Warn if we see
873 annotations for unknown parameters. If .h and .c files name
874 parameters differently, the annotations may be lost.
876 2008-10-21 Johan Dahlin <johan@gnome.org>
878 Bug 556358 - don't use libtool internals
880 * giscanner/Makefile.am:
881 * giscanner/libtoolimporter.py:
882 * giscanner/sourcescanner.py:
883 * giscanner/utils.py:
884 Add a python meta importer and remove a libtool symlink hack.
886 2008-10-20 Andreas Rottmann <a.rottmann@gmx.at>
888 * tests/scanner/Makefile.am (%.typelib): Set PYTHONPATH
889 and --add-include-path appropriately when invoking the scanner.
890 * tests/types/Makefile.am (%typelib): Likewise.
892 2008-10-20 Colin Walters <walters@verbum.org>
894 Bug 556777 - validate properties
896 * giscanner/transformer.py: Add option to throw on unknown types.
897 * giscanner/glibtransformer.py: Use it on properties.
898 * tests/*: Add a test.
900 2008-10-20 Colin Walters <walters@verbum.org>
902 * giscanner/glibast.py: Also register g variants of
903 default_array_types. This is not beautiful, but
904 good alternatives aren't easy to come by.
905 This fixes gchar ** parsing.
907 2008-10-20 Colin Walters <walters@verbum.org>
909 * docs/typelib-format.txt, girepository/gtypelib.h:
910 Take a bit from ObjectInfo to represent abstract flag.
911 * giscanner/cgobject.py: Expose g_type_get_flags.
912 * girepository/girepository.h: Add accessor.
913 * girepository/ginfo.c: Implement it.
914 * giscanner/ast.py: Add is_abstract flag to generic
916 * giscanner/glibast.py: Use it.
917 * giscanner/girwriter.py: Write it.
918 * girepository/girparser.c: Parse it.
921 2008-10-20 Tommi Komulainen <tommi.komulainen@iki.fi>
923 * giscanner/girparser.py (_parse_function): don't lose
924 'transfer-ownership' attributes when injecting, check for the
927 2008-10-19 Johan Dahlin <johan@gnome.org>
929 * giscanner/scannerlexer.l: Parse and ignore __asm.
931 2008-10-19 Colin Walters <walters@verbum.org>
933 * giscanner/girparser.py: Parse array length= to ensure
934 it doesn't get lost from --inject.
936 2008-10-17 Colin Walters <walters@verbum.org>
938 Bug 556795 - char ** regression
940 * giscanner/transformer.py: Fix parsing of ctypes, add some
941 comments about what's going on.
942 * tests/*: Add a test for char **.
944 2008-10-17 Colin Walters <walters@verbum.org>
946 Bug 556783 - change namespace handling to be more consistent
948 * giscanner/transformer.py: Eliminate usage of
949 strip_namespace_object. We now treat --namespace as the default
950 --strip-prefix; however, if --strip-prefix is specified it
951 overrides --namespace. This applies to everything except function
952 names, where we do also strip the namespace.
953 * giscanner/glibtransformer.py: Remove usage of
954 strip_namespace_object.
956 * tests/*: Add skeletal GtkFrob-1.0 test which has different
957 --namespace and --strip-prefix.
959 2008-10-17 Tommi Komulainen <tommi.komulainen@iki.fi>
961 Bug 556732 – generate gir files consistently
963 * girepository/girparser.c (start_parameter):
965 * tests/invoke/testfns-1.0.gir:
966 * tools/generate.c (write_callable_info): write
967 'transfer-ownership' attribute consistently with both
968 return-value and parameter elements
970 2008-10-17 Tommi Komulainen <tommi.komulainen@iki.fi>
972 Bug 556732 – generate gir files consistently
974 * tools/generate.c (write_callable_info): write 'direction'
975 attribute only if other than 'in' to be consistent with
978 * tests/object.gir: remove direction="in" which is the default
980 2008-10-17 Tommi Komulainen <tommi.komulainen@iki.fi>
982 Bug 556732 – generate gir files consistently
984 * giscanner/ast.py (Field): add readable and writable properties
985 * giscanner/girparser.py (_parse_field): copy 'readable' and
986 'writable' attributes
987 * giscanner/transformer.py (_create_member): create fields as
989 * giscanner/glibtransformer.py (_introspect_object,
990 _pair_class_struct): make object instance and class fields
992 * giscanner/girwriter.py (_write_field):
993 * tools/generate.c (write_field_info): write field 'readable'
994 and 'writable' attributes only if non-default (read-only)
995 * girepository/girparser.c (start_field): in the absence of
996 attributes assume fields are read-only
998 * tests/struct.gir: remove redundant readable="1" from fields
999 * tests/scanner/foo-1.0-expected.gir:
1000 * tests/scanner/utility-1.0-expected.gir: add writable="1" to
1001 all record and union fields
1003 2008-10-17 Tommi Komulainen <tommi.komulainen@iki.fi>
1005 Bug 556732 – generate gir files consistently
1007 * giscanner/girwriter.py (_write_property): write properties
1008 'construct' attribute if set
1009 * tools/generate.c (write_property_info): write properties
1010 'readable' and 'writable' attributes only if non-default
1011 * tests/object.gir: add writable="0"
1012 * tests/scanner/foo-1.0-expected.gir: add construct="1"
1014 2008-10-17 Johan Bilien <jobi@via.ecp.fr>
1016 * gir/glib-2.0.c: added annotations
1018 2008-10-16 Johan Bilien <jobi@via.ecp.fr>
1020 * giscanner/ast.py: Also assume direction=out for size_t*, ssize_t*
1023 2008-10-16 Johan Bilien <jobi@via.ecp.fr>
1025 Bug 556610 – giscanner/girparser.py drops parameter options
1027 * tests/scanner/drawable-injected-1.0-expected.gir,
1028 tests/scanner/DrawableAdditions.xml: added simple test for injection.
1029 * giscanner/ast.py: allow Parameter to take options in the constructor
1030 * giscanner/girparser.py: parse parameter options (transfer,
1031 direction, allow-none)
1033 2008-10-16 Colin Walters <walters@verbum.org>
1035 Bug 556185 - segfault on g_callable_info_get_return_type
1037 Initial patch from John Ehresman.
1039 * tests/repository/*: Add a test using
1040 g_callable_info_get_return_type. Instead of casting a
1041 GITypeInfo directly to a GIRegisteredTypeInfo, we need
1042 to call g_type_info_get_interface.
1044 2008-10-16 Colin Walters <walters@verbum.org>
1046 Bug 556579 - union and struct name misresolved
1048 * giscanner/transformer.py: The calls to _resolve_type_name
1049 for struct/union names was a legacy holdover from when type
1050 resolution had multiple phases. Now it's actively harmful
1051 since we might pull in an identical name from another
1055 2008-10-16 Colin Walters <walters@verbum.org>
1057 Bug 556432 - transfer annotations and defaults
1059 * giscanner/transformer.py: Canonicalize type
1060 after removing *, not before. This ensures that
1061 guchar* is transformed to 'uint8'.
1062 Add some comments here.
1063 * giscanner/glibtransformer.py: Add _adjust_transfer
1064 phase for tweaking GObject transfers.
1067 2008-10-16 Tommi Komulainen <tommi.komulainen@iki.fi>
1069 * configure.ac: enable bunch of gcc warning CFLAGS
1071 2008-10-16 Tommi Komulainen <tommi.komulainen@iki.fi>
1073 Bug 556543 – reduce compiler warnings
1075 * girepository/ginfo.c:
1076 * girepository/girepository.c (register_internal,
1077 count_interfaces, find_interface, find_namespace_version,
1078 parse_version, g_irepository_require):
1079 * girepository/girmodule.c (g_ir_module_build_typelib):
1080 * girepository/girnode.c (init_stats, dump_stats,
1081 _g_irnode_init_stats, _g_irnode_dump_stats,
1082 g_ir_node_can_have_member):
1083 * girepository/girparser.c (firstpass_end_element_handler,
1084 locate_gir, parse_basic, parse_type_internal, resolve_aliases,
1085 start_alias, start_type, end_type_top, parse_include, cleanup,
1087 * girepository/gtypelib.c (validate_function_blob, validate_enum_blob):
1088 * giscanner/giscannermodule.c (directive_get_options,
1089 type_get_child_list):
1090 * giscanner/scannerlexer.l (parse_gtkdoc):
1091 * giscanner/scannerparser.y (ctype_free):
1092 * giscanner/sourcescanner.c:
1093 * giscanner/sourcescanner.h (gi_source_scanner_parse_macros):
1094 * tests/types/gitesttypes.c:
1095 * tools/compiler.c (main):
1096 * tools/generate.c (write_repository): Remove unused variables
1097 and code, add missing includes, declarations and case
1100 2008-10-16 Tommi Komulainen <tommi.komulainen@iki.fi>
1102 Bug 556541 – access union members through UnionBlob rather than
1105 * girepository/ginfo.c (g_union_info_find_method): access union
1106 members through UnionBlob rather than StructBlob
1108 2008-10-15 Colin Walters <walters@verbum.org>
1110 Bug 556331 - clean up includes handling
1112 * tools/g-ir-scanner: Rework command line arguments; now we take
1113 --add-include-path and --include separately.
1114 * giscanner/girwriter.py: Separate name= and version= in include
1116 * giscanner/ast.py: Add Include type.
1117 * giscanner/transformer.py: Cleanups to register_include now that
1118 we don't need to handle mixed filenames and relative arguments.
1119 * girepository/girparser.c: Parse name and version separately;
1120 this fixes a bug as a side effect where we weren't resolving
1121 through aliases for basic types.
1122 * girepository/girepository.c: Fix format string args.
1123 * gir/Makefile.am: Update.
1126 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1128 Bug 556434 – unhandled interface/object/... member types
1130 * girepository/girnode.c (g_ir_node_check_unhandled_members,
1131 g_ir_node_build_typelib): Check all
1132 interface/object/boxed/struct/union members are processed and
1133 abort if they are not. (Mostly callbacks in structs, but also
1134 fields in interfaces.)
1136 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1138 * a/girepository/girnode.c (g_ir_node_build_members,
1139 g_ir_node_build_typelib): refactor common code for processing
1140 members to a function
1142 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1144 * gir/Makefile.am (check-local): check that typelib -> gir -> typelib
1145 transformation is lossless (it's not)
1147 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1149 * tests/Makefile.am: fix tests to compare xml to xml instead of
1150 typelib to xml, and stop on error
1152 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1154 * tools/generate.c (write_type_name, write_type_info,
1155 write_type_info, write_object_info, write_object_info,
1156 write_interface_info, write_error_domain_info): reduce code
1159 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1161 Bug 556174 – parse types for lists etc.
1163 * girepository/girparser.c (end_type_recurse):
1165 * tools/generate.c (write_type_info, write_field_info,
1166 write_callable_info, write_callable_info, write_constant_info,
1167 write_property_info): use nested <type>s for lists and hashes
1169 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1172 * tests/object.gir: remove trailing whitespace from inside
1173 elements to match g-ir-generate output
1175 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1177 * tools/generate.c (xml_printf): quote printf arguments so that
1178 we don't generate invalid XML by writing unescaped double quotes
1179 and such in attributes
1181 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1183 * tools/generate.c (write_field_info, write_callable_info,
1184 write_function_info, write_callback_info, write_struct_info,
1185 write_constant_value, write_signal_info, write_vfunc_info,
1186 write_object_info, write_interface_info, write_union_info,
1187 write_repository): remove unused indent parameters, xmlwriter
1188 keeps track of necessary indentation
1190 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1192 * tools/generate.c (xml_element_new, xml_element_free,
1193 xml_start_element, xml_end_element, xml_end_element_unchecked,
1194 xml_open, xml_close): Keep track of generated XML tree and
1195 handle indentation and closing tags properly.
1196 (write_field_info, write_callable_info, write_function_info,
1197 write_callback_info, write_struct_info, write_value_info,
1198 write_constant_info, write_enum_info, write_signal_info,
1199 write_vfunc_info, write_property_info, write_object_info,
1200 write_interface_info, write_error_domain_info, write_union_info,
1201 write_repository): Use xml_start_element and xml_end_element to
1204 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1206 * tools/generate.c (xml_printf, xml_open, xml_close, xml_free):
1207 (write_type_name, write_type_info, write_field_info,
1208 write_callable_info, write_function_info, write_callback_info,
1209 write_struct_info, write_value_info, write_constant_value,
1210 write_constant_info, write_enum_info, write_signal_info,
1211 write_vfunc_info, write_property_info, write_object_info,
1212 write_interface_info, write_error_domain_info, write_union_info,
1213 write_repository): wrap all FILE access to go through simple xmlwriter
1215 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1217 Bug 556400 – Fails to build on OS X 10.4
1219 * configure.ac: check for functions backtrace and backtrace_symbols
1220 * girepository/girparser.c (backtrace_stderr): Comment out
1221 implementation if the functions are not available.
1222 * gcov.mak (clean-gcov, clean-gcno): always call 'find' with a
1223 directory for better portability
1225 2008-10-15 Johan Bilien <jobi@via.ecp.fr>
1227 Bug 556433 – assume direction = out for int * parameters
1229 * giscanner/ast.py: define a list of types for which, if passed as
1230 reference, we assume a default direction of 'out'
1231 * giscanner/transformer.py: if a type has type pointer to one of the
1232 previously defined types, and no direction is set, assume out.
1233 * tests/scanner/drawable.[ch]: added tests for guessed direction=out
1235 2008-10-15 Johan Bilien <jobi@via.ecp.fr>
1237 * tests/scanner/annotation.c: fixed a few copy-paste errors
1239 2008-10-14 Johan Bilien <jobi@via.ecp.fr>
1241 Bug 556323 – transfer-ownership is wrong for functions returning const
1244 * giscanner/transformer.py: check for a const string as return value,
1245 not just const char*. Suggested by Colin Walters
1246 * tests/scanner/annotation-1.0-expected.gir: updated expected output
1248 2008-10-14 Johan Bilien <jobi@via.ecp.fr>
1250 * girepository/ginfo.c, girepository/girepository.h: add
1251 g_union_info_find_method
1253 2008-10-14 Colin Walters <walters@verbum.org>
1255 * tests/repository/Makefile.am: Reenable repo test.
1256 * tests/repository/gitestrepo.c: Prepend search
1257 path for $(top_builddir)/gir dir so that we don't
1258 require installation for "make check" to pass.
1260 2008-10-13 Jürg Billeter <j@bitron.ch>
1262 * giscanner/glibtransformer.py:
1263 * tests/scanner/annotation-1.0-expected.gir:
1264 * tests/scanner/drawable-1.0-expected.gir:
1265 * tests/scanner/foo-1.0-expected.gir:
1266 * tests/scanner/utility-1.0-expected.gir:
1268 Support fields in GObject structs
1270 2008-10-13 Jürg Billeter <j@bitron.ch>
1272 * giscanner/ast.py: add signed integer and off_t to type_names
1274 2008-10-12 Jürg Billeter <j@bitron.ch>
1276 * giscanner/girparser.py: Parse bits attribute of fields
1278 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1280 * tests/repository/Makefile.am: run 'gitestrepo' in 'make check'
1281 * tests/repository/gitestrepo.c (main): instantiate
1282 'GCancellable' to ensure the GType is registered before using
1285 2008-10-12 Johan Bilien <jobi@via.ecp.fr>
1287 * giscanner/girparser.py: actually add the parsed constant nodes
1289 2008-10-12 Colin Walters <walters@verbum.org>
1291 * girepository/girepository.c: Don't cast DirEntry to Blob,
1292 actually look it up by offset.
1294 2008-10-12 Johan Bilien <jobi@via.ecp.fr>
1296 * giscanner/girparser.py: parse constant nodes in gir files
1298 2008-10-12 Johan Bilien <jobi@via.ecp.fr>
1300 * giscanner/transformer.py: prefix for constants have an underscore,
1301 so remove them as if they were functions, not objects.
1303 2008-10-12 Johan Bilien <jobi@via.ecp.fr>
1305 * tests/scanner/foo-1.0-expected.gir: add constants to expected gir
1308 2008-10-12 Colin Walters <walters@verbum.org>
1310 Initial patch from Jani Monoses.
1312 * girepository/gtypelib.c: Fix inverted test for success
1315 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1317 * tools/generate.c (write_callable_info): use "transfer-ownership"
1318 attribute for return values
1320 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1322 * tools/generate.c (write_callable_info): move "transfer" and
1323 "null-ok" attributes from <function> to <return-value> element
1325 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1327 * girepository/girparser.c (start_return_value): handle
1328 "transfer-ownership" attribute
1330 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1332 * girepository/girparser.c (parse_param_transfer):
1333 * tools/generate.c (write_callable_info): use "container" for
1334 container/shallow ownership transfer (not "shallow")
1336 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1338 * girepository/girparser.c (parse_param_transfer,
1339 start_parameter): Refactor handling of transfer=none/shallow/full
1340 to separate function
1342 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1344 Bug 556048 – Crash in g_irepository_find_by_gtype
1346 * girepository/gtypelib.h (BLOB_IS_REGISTERED_TYPE): added
1347 * girepository/girepository.c (find_interface): Fix
1348 find_by_gtype case to get the type name from right offset
1350 2008-10-12 Jürg Billeter <j@bitron.ch>
1352 * giscanner/girparser.py: Fix parsing transfer-ownership attribute
1355 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1357 * girepository/gtypelib.h (RegisteredTypeBlob): make
1358 'unregistered' one bit wide as everywhere else
1360 2008-10-12 Jürg Billeter <j@bitron.ch>
1362 * giscanner/glibtransformer.py:
1363 * tests/scanner/annotation-1.0-expected.gir:
1364 * tests/scanner/drawable-1.0-expected.gir:
1365 * tests/scanner/drawable.h:
1366 * tests/scanner/foo-1.0-expected.gir:
1367 * tests/scanner/utility-1.0-expected.gir:
1369 Readd class records as workaround to not break Gtk typelib
1371 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1373 * tests/types/Makefile.am: fix typo in gitesttypes namespace
1375 2008-10-12 Jürg Billeter <j@bitron.ch>
1377 * giscanner/glibtransformer.py: Don't generate <record> elements
1379 * tests/scanner/*: Update test cases
1381 2008-10-11 Colin Walters <walters@verbum.org>
1383 Bug 552858: versioning
1385 This is a big patch. You should probably remove your installation
1388 * docs/typelib-format.txt: Add nsversion entry which holds
1389 version of namespace.
1390 * girepository/girepository.h: Add 'version' parameter to
1391 g_irepository_require. This may be NULL. Normally
1392 bindings should pass an explicit version though.
1393 * girepository/girepository.c: Lots of infrastructure to
1394 support versioning. Add some more documentation. Disallow
1395 some usage of NULL namespaces.
1396 * girepository/girmodule.c: Add version parameter.
1397 * girepository/gtypelib.c: Update header size.
1398 * giscanner/ast.py: Add version to Namespace.
1399 * giscanner/girparser.py: Parse version attribute from
1400 XML, pass to Namespace.
1401 * giscanner/girwriter.py: Write out version parameter.
1402 * giscanner/transformer.py: Clean up include registration.
1403 * tests/*: Add version attribute.
1404 * tests/invoke/invoke.c: Don't try looking up test before
1405 it's loaded in repository.
1406 * tools/generate.c: Output version parameter.
1407 * gir/Makefile.am: Add 2.0 version to .gir files.
1409 2008-10-11 Colin Walters <walters@verbum.org>
1411 * giscanner/scannerlexer.l (parse_gtkdoc): Don't lose
1412 if we have mismatched parens.
1414 2008-10-11 Lucas Rocha <lucasr@gnome.org>
1416 * giscanner/girparser.py (_parse_enumeration_bitfield): fix typo
1417 on 'members' variable.
1419 2008-10-11 Colin Walters <walters@verbum.org>
1421 Bug 555947 - update annotations syntax
1423 * giscanner/ast.py: Default to None for transfer. Remove
1424 default transfers for container types; we require this to
1426 * giscanner/girwriter.py: Transfer is now 'none', 'container',
1427 'full' to match repository.
1428 * giscanner/scannerlexer.l: Annotations now are parenthesized.
1429 * giscanner/transformer.py: Update for new annotations syntax.
1432 2008-10-11 Johan Bilien <jobi@litl.com>
1434 * giscanner/scannerparser.y: ignore non-UTF-8 string constants
1436 2008-10-11 Johan Bilien <jobi@litl.com>
1438 Bug 552347: Parse #defines constants
1440 * girepository/gtypelib.c: update the list of value_size
1441 with recently defined type tags
1442 * giscanner/scannerparser.y: brought back parsing of #defined, as
1443 present in older version
1444 * giscanner/giscannermodule.c: bind gi_source_scanner_append_filename
1445 * giscanner/girwriter.py: write out constant tags in the gir
1446 * giscanner/sourcescanner.py: add accessor for const_string
1447 * giscanner/transformer.py, giscanner/glibtransformer.py: handle
1450 2008-10-11 Tommi Komulainen <tommi.komulainen@iki.fi>
1452 Bug 555946: Install a test module exercising all types, transfer
1457 * tests/types/*: Add and install a test module that has functions
1458 accepting and returning most of the basic types to enable bindings
1459 implementors to more easily test their type conversion routines.
1461 2008-10-11 Jürg Billeter <j@bitron.ch>
1463 Bug 552374: Const strings should be identified in the gir.
1465 * giscanner/transformer.py: support string memory management
1466 * tests/scanner/foo.h: use char * and const char *
1467 * tests/scanner/foo-expected.gir: test that
1469 2008-10-11 Johan Dahlin <johan@gnome.org>
1471 * giscanner/girparser.py:
1472 Also parse enums which are not glib types.
1474 2008-10-11 Lucas Rocha <lucasr@gnome.org>
1476 Bug 552370: add one more test for unsigned as a type, not as
1479 * giscanner/ast.py: add 'uint' type name for 'unsigned'.
1480 * test/scanner/foo.h: add function which uses unsigned as a type.
1481 * test/scanner/foo-expected.gir: test that.
1483 2008-10-11 Andreas Rottmann <a.rottmann@gmx.at>
1485 Bug 555712: Struct and union issues
1487 * giscanner/scannerparser.y (struct_declarator): Use information
1488 provided about the bit width of a field.
1489 * giscanner/transformer.py (Transformer._create_member): Pass the
1490 symbol's const_int member to the created field (it represents the
1492 * giscanner/girwriter.py (GIRWriter._write_field): Output 'bits'
1493 field attribute, if present.
1494 * giscanner/ast.py (Field): Add 'bits' member, specifying the
1495 width in bits of the field (only relevant for bitfields).
1498 * giscanner/transformer.py (Transformer._create_typedef_struct)
1499 (Transformer._create_typedef_union): Add calls to _create_struct()
1500 and _create_union(), respectively. This causes the scanner to
1501 generate output for fields of struct and union typedefs.
1504 2008-10-11 Jürg Billeter <j@bitron.ch>
1506 Bug 552370: unsigned not scanned properly
1508 * giscanner/scannerparser.y: combine basic types such as unsigned
1509 int and long long when scanning
1510 * tests/scanner/foo-expected.gir:
1511 * tests/scanner/foo.c: (foo_test_unsigned):
1512 * tests/scanner/foo.h: test that
1514 2008-10-11 Lucas Rocha <lucasr@gnome.org>
1516 Bug 554854: The --typelib-xml and --inject options should reuse
1517 giscanner parser/writer.
1519 * giscanner/ast.py: add constructor list to Struct and Union.
1520 Add new param in Return's contructor to define transfer.
1521 * giscanner/girparser.py: several additions to the parser in order
1522 to have parsing all nodes of the gir xml files.
1523 * tools/g-ir-scanner (typelib_xml_strip, inject): use gir parser
1524 and writer in --inject and --typelib-xml options.
1525 * giscanner/xmlwriter.py: ignore empty attributes instead of
1526 raising an error as this basically exposes a bug in GIRParser.
1527 This should be reverted as soon as the parser is fixed.
1529 2008-10-11 Lucas Rocha <lucasr@gnome.org>
1531 Bug 552376: scanner generates wrong names for enum members when
1532 there's no defined gtype.
1534 * giscanner/utils.py (strip_common_prefix): Always strip common
1535 prefix exactly up to the last "_", and not beyond.
1536 * tests/scanner/foo.h (FooEnumNoType): add FOO_ENUM_NEUF. The point
1537 here is that the first character after the last '_' should should be
1538 the same as the character in the same position on the type name.
1539 * tests/scanner/foo-expected.gir: test that
1541 2008-10-10 Lucas Rocha <lucasr@gnome.org>
1543 Bug 555293: append library_paths to LPATH env variable to work
1544 around a bug in find_library when using ldconfig.
1546 * tools/g-ir-scanner (main): ditto.
1548 2008-10-09 Lucas Rocha <lucasr@gnome.org>
1550 * girepository/girepository.c (register_internal): fix regression on
1551 invoke test case by making sure we load the global module in the
1552 typelib when dealing with inline typelibs.
1553 * girepository/gtypelib.c: a couple of coding style fixes.
1555 2008-10-06 Lucas Rocha <lucasr@gnome.org>
1557 Bug 555294: Add support for multiple shared libraries per typelib.
1559 * girepository/ginvoke.c (g_function_info_invoke),
1560 girepository/ginfo.c(g_registered_type_info_get_g_type): use
1561 g_typelib_symbol instead of g_module_symbol.
1562 * girepository/girepository.h: remove g_typelib_set_module and add
1564 * girepository/gtypelib.[ch] (find_some_symbol, _g_typelib_init,
1565 g_typelib_new_from_memory, g_typelib_new_from_const_memory,
1566 g_typelib_free, g_typelib_symbol): chnage GTypeLib to hold a list of
1567 modules instead of just one. The symbol lookup is now abstracted
1568 behind g_typelib_symbol which tries to find the passed symbol name in
1570 * giscanner/girwriter.py, tools/g-ir-scanner: change scanner to read
1571 and write shared_library attribute as a comma-separated list of libs.
1573 2008-10-06 Colin Walters <walters@verbum.org>
1575 * giscanner/transformer.py: Parse length= annotation as
1576 a parameter name, not a raw int.
1579 2008-10-03 Colin Walters <walters@verbum.org>
1581 Bug 551744: Non-GObject types aren't aggregating ctors and methods
1583 * girepository/gtypelib.c: Allow ctors/methods on struct,union,
1585 * giscanner/glibtransformer.py: Ditto, and GLibBoxed is also a
1589 2008-10-03 Colin Walters <walters@verbum.org>
1591 Bug 554576: scan problem with ev_selection_render_selection()
1593 * giscanner/transformer.py: Only do type resolution once we've
1594 scanned all types. What could happen before is that we'd strip
1595 the namespace from local type "EvSelection" => Selection, and
1596 then later pull a "Selection" from some other namespace because
1597 we hadn't yet seen the local EvSelection. This could come
1598 down to hash table ordering and other things so not easy
1599 to write a test for.
1601 2008-10-03 Lucas Rocha <lucasr@gnome.org>
1603 * giscanner/girwriter.py (_parser_member): fix the last parameter of
1604 GLibEnumMember constructor as it should be the enum member nick.
1606 2008-10-02 Colin Walters <walters@verbum.org>
1608 Bug 552961: remove this parameter for methods
1610 * giscanner/glibtransformer.py: Delete this parameter; it is
1612 * girepository/ginvoke.c: Insert this parameter for methods.
1613 * girepository/gtypelib.c: Remove no longer needed verification of
1614 method this parameter.
1617 2008-09-30 Dan Winship <danw@gnome.org>
1619 Bug 554490: g-ir-scanner gets confused by '\\'
1621 * giscanner/scannerlexer.l (chartext, stringtext): fix use of
1622 backslashes so it will correctly parse '\\' and "\\"
1624 * tests/scanner/annotation.c: add a use of '\\' to make sure that
1627 * giscanner/glibtransformer.py (GLibTransformer.count_type): typo
1629 2008-10-02 Colin Walters <walters@verbum.org>
1631 bug 552393: Note variadic functions
1633 * giscanner/scannerparser.y: Parse ellipsis. Refactor grammar
1634 to use parameter_list directly.
1635 * giscanner/sourcescanner.h: Add ellipsis csymbol type.
1636 * giscanner/ast.py: Add Varargs type.
1637 * giscanner/transformer.py: Check for ellipsis symbol, transform
1639 * girepository/girnode.h: Add varargs flag to in-memory nodes.
1640 Parse varargs functions, but filter them out before we start
1641 compiling the typelib.
1643 2008-10-02 Colin Walters <walters@verbum.org>
1645 Bug 554632: type tag for GType
1647 * girepository/girepository.h, girepository/girepository.c:
1648 Add type tag for GType - it's a special type we don't want
1649 to resolve to just "long".
1650 * docs/typelib-format.txt: Update.
1651 * girepository/girparser.c: Parse it.
1652 * giscanner/glibtransformer.py: Ensure we don't put GType in
1654 * tools/generate.c: Remove hardcoded type list.
1657 2008-09-30 Dan Winship <danw@gnome.org>
1659 Bug 554521: scanner generates wrong names for enum members with
1660 full type name prefix
1662 * giscanner/utils.py (strip_common_prefix): Fix this to strip the
1663 right amount when the entire "first" string is a prefix of
1666 * tests/scanner/foo.h (FooEnumFullname):
1667 * tests/scanner/foo-expected.gir: test that
1669 2008-09-29 Colin Walters <walters@verbum.org>
1671 Bug 552380: Array parameters should be marked in the gir
1673 * giscanner/ast.py: Default char** to utf8[], and guchar* to
1674 uint8[]. Add Array, List, and Map subclasses of Type;
1675 these types can be generic. Return transfer defaults
1676 to true if return value is string or container type.
1677 Delete Sequence type.
1678 * giscanner/scannerlexer.l: Syntax change for annotations;
1679 use <> since it's more readable.
1680 * giscanner/girwriter.py: Write out these changes.
1681 * giscanner/girparser.py: Parse them.
1682 * giscanner/transformer.py: Have a defined set of
1683 both list and map types. When creating a type,
1684 check if the ctype we've parsed is one of them,
1685 if so create a container type subclass as appropriate.
1686 * girepository/girparser.c: Parse in generic types.
1689 2008-09-27 Colin Walters <walters@verbum.org>
1691 * tools/g-ir-scanner: Add --inject option.
1693 2008-09-25 Colin Walters <walters@verbum.org>
1695 Remove non-repository types from GIR
1697 * giscanner/ast.py: The canonical name is 'utf8', not
1699 * giscanner/glibast.py: A few more glib type mappings.
1700 * girepository/girparser.c: We only parse repository types.
1701 * tests/*.gir: Update.
1703 2008-09-23 Colin Walters <walters@verbum.org>
1705 Bug 552566: Add time_t type
1707 We need a type for time_t since it's special in C, and just
1708 mapping it to long precluded bindings from handling it
1711 2008-09-19 Colin Walters <walters@verbum.org>
1713 Bug 552390: Handle capitialization like "DBus" more robustly
1715 The to_underscores function was designed for use against prefixed
1716 names; we need a separate function which will convert names like
1717 DBusFoo into dbus_foo, not d_bus_foo.
1719 2008-09-19 Colin Walters <walters@verbum.org>
1721 Add check to make sure we're not hitting out unresolved types
1723 Validate the "this" argument for methods
1725 Remove heuristic matching of methods to classes based on prefix
1727 It was a broken hack that dated from when we handled underscoring
1728 and capitalization conventions less well.
1730 2008-09-18 Colin Walters <walters@verbum.org>
1732 Bug 552384: Use SHLIB_SUFFIX intead of G_MODULE_SUFFIX for Darwin
1734 On Darwin, the suffix for installed shared libraries (.dylib) is
1735 different from loadable modules (.so). We use a bit of magic shell
1736 script from Behdad Esfahbod to figure out the right suffix.
1738 2008-09-15 Johan Dahlin <johan@gnome.org>
1740 * giscanner/sourcescanner.py (SourceType.type_qualifier): Add
1741 a wrapper for type_qualifier as well.
1743 2008-09-15 Colin Walters <walters@verbum.org>
1745 http://bugzilla.gnome.org/show_bug.cgi?id=552065
1747 * giscanner/ast.py: Add deprecation attributes.
1748 * giscanner/girwriter.py: Write out deprecation data.
1749 * girepository/girparser.c: Relax parsing; deprecated
1750 attribute now includes freeform string.
1751 * giscanner/scannerlexer.l: Parse Deprecated.
1752 * giscanner/transformer.py: Look for deprecated attribute
1754 * tests/scanner/*: Add a Deprecated test.
1756 2008-09-14 Tor Lillqvist <tml@novell.com>
1758 * tests/scanner/Makefile.am (%.typelib): Use $(EXEEXT).
1760 2008-09-14 Colin Walters <walters@verbum.org>
1762 * giscanner/glibtransformer.py: Ignore functions with
1765 2008-09-12 Colin Walters <walters@verbum.org>
1767 * giscanner/glibtransformer.py: Accept Gtk.Type as GType.
1769 2008-09-12 Colin Walters <walters@verbum.org>
1771 * giscanner/ast.py: Bind pid_t to INT for vte.
1773 2008-09-12 Colin Walters <walters@verbum.org>
1775 * giscanner/girparser.py: Parse c:type for boxed records/unions.
1776 * giscanner/glibast.py: Avoid overwriting ctype.
1777 * giscsanner/transformer.py: Try resolving types using the GType names.
1779 2008-09-12 Colin Walters <walters@verbum.org>
1781 * giscanner/minixpath.py: Code to run an "XPath"
1782 assertion against an XML tree, taken from
1783 gir-repository/gir/tests.py.
1784 * giscanner/Makefile.am: Ship it.
1785 * tools/g-ir-scanner: Add --xpath-assertions option.
1786 * gir/GLib-assertions.txt: Add a few assertions.
1787 * gir/Makefile.am: Run them.
1789 2008-09-11 Colin Walters <walters@verbum.org>
1791 http://bugzilla.gnome.org/show_bug.cgi?id=551737
1793 * giscanner/transformer.py: Fix strip_namespace_func to only strip
1794 prefix if it ends with _. Tweak callback stripping to determine
1795 based on presence of _ whether we need to use strip_namespace_func
1796 or strip_namespace_object.
1798 2008-09-09 Owen Taylor <otaylor@redhat.com>
1800 * docs/typelib-format.txt: Wether => Whether
1802 2008-09-08 Colin Walters <walters@verbum.org>
1804 * girepository/girparser.c: Default to "readable" for properties.
1805 * giscanner/ast.py: Add readable, writable etc.
1806 * giscanner/girwriter.py: Writ them.
1807 * giscanner/glibtransformer.py: Inspect them.
1810 2008-09-07 Colin Walters <walters@verbum.org>
1812 * giscanner/cgobject.py: Add comment.
1814 2008-09-07 Colin Walters <walters@verbum.org>
1816 * giscanner/cgobject.py: Also call g_thread_init.
1818 2008-09-07 Colin Walters <walters@verbum.org>
1820 * giscanner/transformer.py: Fix regression by not
1821 stripping prefix before stripping namespace for unions
1824 2008-09-06 Colin Walters <walters@verbum.org>
1826 * giscanner/transformer.py: If a namespace contains
1827 multiple caps, try stripping both gnomekeyring_ and
1830 2008-09-07 Johan Dahlin <johan@gnome.org>
1832 Bug 551162 – giscanner does not recognize asm and __asm__
1833 * giscanner/scannerlexer.l:
1834 Patch by Jani Monoses.
1836 2008-09-06 Colin Walters <walters@verbum.org>
1838 * girepository/girnode.c: Allow gtype_name
1839 and gtype_init in struct and union.
1840 * girepository/girparser.c: Parse glib:
1841 boxed bits for both structure and union.
1842 * girepository/gtypelib.c: Don't barf
1843 if structure is boxed.
1844 * giscanner/girparser.py: Parse new XML
1846 * giscanner/girwriter.py: Write out new
1848 * giscanner/glibast.py: Define new classes
1849 which are both Boxed and Struct/Union, as
1850 well as an "Other" for everything else.
1851 * giscanner/glibtransformer.py: Handle
1852 boxed types specially; we try to merge
1853 them with a struct/union if one exists,
1854 otherwise fall back to generic boxed.
1856 * tools/generate.c: Write out new format.
1858 2008-09-06 Johan Dahlin <johan@gnome.org>
1860 * giscanner/grealpath.h: Include stdlib.h
1862 * docs/g-ir-generate.1: Remove leading %
1864 2008-09-01 Colin Walters <walters@verbum.org>
1866 * girepository/girparser.c: Look at c:type to determine
1867 whether or not an item is a pointer.
1869 2008-09-01 Johan Dahlin <johan@gnome.org>
1871 * tests/scanner/Makefile.am:
1872 Set PYTHONPATH so the scanner can run
1873 even if you didn't install anything.
1875 2008-09-01 Johan Dahlin <johan@gnome.org>
1878 Post-release version bump
1881 2008-09-01 Johan Dahlin <johan@gnome.org>
1885 2008-08-31 Colin Walters <walters@verbum.org>
1887 * giscanner/glibtransformer.py: Quiet info
1890 2008-08-31 Johan Dahlin <johan@gnome.org>
1893 Bump version to 0.5.0
1895 2008-08-31 Colin Walters <walters@verbum.org>
1897 * giscanner/glibtransformer.py: Follow aliases to ensure
1898 we don't get a constructor returning a basic type.
1899 * giscanner/transformer.py: Add function to follow aliases.
1902 2008-08-31 Johan Dahlin <johan@gnome.org>
1904 * giscanner/scannerlexer.l:
1905 * giscanner/scannerparser.y:
1906 * giscanner/sourcescanner.h:
1907 * giscanner/sourcescanner.py:
1908 Parse GCC extensions in the parser instead of just undeffing them
1909 in the pre-processor.
1911 2008-08-31 Johan Dahlin <johan@gnome.org>
1913 * giscanner/glibtransformer.py:
1914 Clean up a huge if. Do not add methods or constructors
1916 * giscanner/utils.py:
1917 second might be longer than first, check that.
1919 2008-08-31 Johan Dahlin <johan@gnome.org>
1924 2008-08-31 Colin Walters <walters@verbum.org>
1926 * girepository/girparser.c: Don't lose if we
1929 2008-08-31 Colin Walters <walters@verbum.org>
1931 * giscanner/glibtransformer.py: Look for libtool
1932 library in current directory
1933 * tests/scanner - Update.
1935 2008-08-30 Colin Walters <walters@verbum.org>
1937 * docs/typelib-format.txt: Add a guint32
1939 * gir/Makefile.am: Dep on Makefile
1940 * girepository/ginfo.c:
1941 * girepository/girepository.c: Clean up
1942 default typelib handling; remove global
1943 default_typelib variable. Ensure we handle
1944 NULL repository in more places.
1945 Support dependency resolution.
1946 Support lazy loading.
1947 * girepository/girepository.h: Remove
1948 g_irepository_unregister; we don't support
1949 unloading typelibs since really they're
1950 process-global. Update for lazy loading
1952 * girepository/girmodule.c: Use g_new0.
1953 Add dependencies to GirModule.
1954 * girepository/girparser.c: Parse dependencies.
1955 * girepository/gtypelib.c: Add 4 bytes for
1957 * tests/Makefile.am: Kill off gobject.gir,
1958 it conflicts with the real one.
1959 * tests/object.gir: Dep on GObject.
1960 * tools/generate.c: Take --includedir
1961 argument to say which directories to search
1962 for typelibs. Print out dependencies.
1964 2008-08-30 Colin Walters <walters@verbum.org>
1966 * giscanner/glibtransformer.py: Reduce warning noise.
1968 2008-08-29 Colin Walters <walters@verbum.org>
1970 * girepository/ginfo.c: Add some assertions regarding
1971 refcounts, just to be sure.
1972 * giscanner/glibtransformer.py: Blacklist a few more
1975 2008-08-29 Colin Walters <walters@verbum.org>
1977 * giscanner/glibtransformer.py: Blacklist a few
1978 functions that use GError oddly
1980 2008-08-29 Colin Walters <walters@verbum.org>
1982 * girepository/gtypelib.c: Don't crash if no
1985 2008-08-29 Colin Walters <walters@verbum.org>
1987 * girepository/girparser.c: Handle chains of aliases
1988 across modules by ensuring we fully qualify aliases
1991 2008-08-29 Colin Walters <walters@verbum.org>
1993 * girepository/girparser.c: Don't search aliases
1996 2008-08-29 Colin Walters <walters@verbum.org>
1998 * girepository/girparser.c: Rewrite type parsing
1999 to handle both GLib parsing case as well as correctly
2000 handling GLib.List and friends. Don't try to treat
2001 e.g. ListStore as a List.
2003 2008-08-29 Colin Walters <walters@verbum.org>
2005 * girepository/gtypelib.c: Add more context
2008 2008-08-29 Colin Walters <walters@verbum.org>
2010 * giscanner/glibtransformer.py: Add some informative
2011 logging messages in corner cases. Be sure we use
2012 the most recent node set instead of a cache
2013 when generating result set.
2014 * tests/: Remove duplicated bits in expected girs
2015 * girepository/girparser.c: Accept both List (for
2016 compiling GLib) and GLib.List (what the scanner
2019 * tools/generate.c: Generate canonical form.
2021 2008-08-29 Johan Dahlin <johan@gnome.org>
2023 * giscanner/config.py.in:
2024 Use datarootdir instead of datadir to avoid
2025 an autoconf warning.
2027 2008-08-29 Johan Dahlin <johan@gnome.org>
2031 * examples/gdk-pixbuf.gidl:
2033 Update and remove old cruft.
2035 2008-08-29 Johan Dahlin <johan@gnome.org>
2038 * docs/g-ir-compiler.1:
2039 * docs/g-ir-generate.1:
2040 * docs/g-ir-scanner.1:
2041 Add man pages for the generator and compiler.
2043 2008-08-29 Johan Dahlin <johan@gnome.org>
2045 * docs/g-ir-scanner.1: Document
2047 * giscanner/Makefile.am:
2048 * giscanner/gidlparser.py:
2049 * giscanner/gidlwriter.py:
2050 * tools/g-ir-scanner:
2051 Remove gidl support.
2053 2008-08-28 Colin Walters <walters@verbum.org>
2055 * tests/scanner/Makefile.am: Pass the right
2056 --includedir args. Add a Makefile dep.
2057 * tools/compiler.c: Pass includedirs down.
2058 * girepository/girparser.c: Actually put
2059 includedirs in context, pass down. Fix
2062 2008-08-28 Colin Walters <walters@verbum.org>
2064 * gir/Makefile.am: Use --includedir
2065 * girepository/girparser.c: Recursively parse
2066 includes to pull in aliases and expand them.
2067 We need this to avoid putting unknown names in
2069 * tools/compiler.c: Add --includedir option.
2070 * giscanner/ast.py: Map size/ssize to types
2073 2008-08-28 Tor Lillqvist <tml@novell.com>
2075 Make check now runs successfully on Windows.
2077 * tools/compiler.c (write_out_typelib): Use binary mode for output
2080 * girepository/girnode.c: Don't print NULL strings.
2082 * tests/invoke/Makefile.am
2083 * tests/scanner/Makefile.am: Use -no-undefined on Windows to
2084 convince libtool to build shared libraries.
2086 * tests/invoke/invoke.c: Don't needlessly include <dlfcn.h>. Use
2087 g_assert() instead of printing out expected errors.
2089 2008-08-28 Tor Lillqvist <tml@novell.com>
2091 * girepository/gtypelib.h: Change type of bitfield fields from
2092 guint to the most suitable smaller type. This makes the struct
2093 sizes match the ones on Linux that the sanity check expects when
2094 using gcc -mms-bitfields on Windows.
2096 2008-08-28 Johan Dahlin <johan@gnome.org>
2101 * giscanner/Makefile.am:
2102 * tests/Makefile.am:
2103 * tests/scanner/Makefile.am:
2104 Make distcheck pass.
2106 2008-08-27 Johan Dahlin <johan@gnome.org>
2108 * giscanner/Makefile.am:
2109 Only send in -no-undefined on Win32 as it breaks on MacOS X.
2111 2008-08-27 Tor Lillqvist <tml@novell.com>
2113 Make g-ir-scanner work on Windows. Still problems with the typelib
2114 code. Changes okayed by jdahlin.
2116 * configure.ac: Check for Windows, set Automake conditional
2117 OS_WIN32. Change backslashes to forward slashes in pyexecdir to
2118 avoid shell quoting issues
2120 * girepository/Makefile.am: Use -no-undefined so that libtool
2121 agrees to build a shared library on Windows.
2123 * girepository/girparser.c (backtrace_stderr): No backtrace() on
2124 Windows. Empty implementation on Windows so far.
2126 * girepository/gtypelib.c (g_typelib_check_sanity): Give more
2127 informative error message for the assertion failures. Tell also
2128 what the expected size of the struct is. Check all sizes first and
2129 fail afterwards if at least one size was different from expected.
2131 * tools/Makefile.am: Reorder libraries into proper logical
2134 * tools/generate.c: Don't include <dlfcn.h>, not used.
2136 * giscanner/Makefile.am: On Windows, link with the Python library,
2137 and install the module DLL as _giscanner.pyd. Remove the
2138 unnecessary import library and libtool library that libtool has
2141 * giscanner/scannerlexer.l: Recognize the gcc __attribute__ syntax
2142 and just skip it. Recognize also two "l" suffixes for long long
2143 constants. Recognize also __inline__.
2145 * giscanner/grealpath.h (g_realpath): Implement on Windows, using
2146 GetFullPathName(). As such, GetFullPathName() does more than the
2147 UNIX realpath(). It also changes relative paths into absolute
2148 paths. But for our purposes that shouldn't matter.
2150 * giscanner/giscannermodule.c (pygi_source_scanner_parse_file): On
2151 Windows the file descriptor passed to us is from Python. Python
2152 Python2.5 uses the msvcr71.dll C library, while mingw-built code
2153 uses msvcrt.dll. On Windows, file descriptors are specific to
2154 which C library is used. So we must find out what underlying OS
2155 handle corresponds to the file descriptor Python passes us, and
2156 then make that into a file descriptor valid for the C library this
2159 * giscanner/sourcescanner.py (_parse): Don't need to bypass
2160 __attribute__ as the lexer now handles it. The definition as empty
2161 was ineffective for mingw anyway, as mingw's _mingw.h undefines
2162 __attribute__. Close the temp file before unlinking it.
2164 * giscanner/cgobject.py: Use correct library name for the gobject
2167 * gir/Makefile.am: Must pass the full basename of the DLLs on
2168 Windows to g-ir-scanner. It's a bit ugly that we have to "know"
2169 that the names of the GLib DLLs are like libglib-2.0-0.dll, but in
2170 reality they won't change, until there is a GLib 3, and then also
2171 the Unix code here needs changing.
2173 Must pass CPPFLAGS to g-ir-scanner when building GLib.gir so that
2176 2008-08-26 Colin Walters <walters@verbum.org>
2178 * girepository/girepository.c: Search
2179 $DATADIR/girepository instead of
2180 $DATADIR/gitypelibs; this naming makes
2181 it clearer that e.g. jgir can install
2183 * gir/Makefile.am: Install there.
2185 2008-08-26 Colin Walters <walters@verbum.org>
2187 * girepository/gtypelib.c (_g_typelib_init): Also
2188 use G_MODULE_SUFFIX instead of hardcoding .so.
2190 2008-08-26 Colin Walters <walters@verbum.org>
2192 * girepository/gtypelib.c (_g_typelib_init): Free
2193 string in the right place.
2195 2008-08-26 Colin Walters <walters@verbum.org>
2197 * girepository/gtypelib.c (_g_typelib_init): Handle
2198 both .la and .so names; this works better in the
2199 uninstalled library case.
2201 2008-08-26 Johan Dahlin <johan@gnome.org>
2204 * giscanner/Makefile.am:
2205 * giscanner/cgobject.py:
2206 * giscanner/config.py.in:
2207 * giscanner/sourcescanner.py:
2208 Avoid undeffing __GNUC__, instead define
2209 __attribute__ & friends. Remove glibconfig.h hack.
2210 This makes gobject-introspection work better on
2211 MacOS X, Thanks to Richard Hult for kind help.
2213 2008-08-25 Colin Walters <walters@verbum.org>
2215 * giscanner/glibtransformer.py: Always print
2218 2008-08-25 Colin Walters <walters@verbum.org>
2220 * giscanner/glibtransformer.py: Skip over
2221 interfaces we don't know.
2223 2008-08-25 Colin Walters <walters@verbum.org>
2225 * girepository/girparser.c: Parse new implements
2226 syntax, drop gapi one.
2227 * tests/object.gir: Update.
2228 * tools/generate.c: Generate new syntax.
2230 2008-08-25 Colin Walters <walters@verbum.org>
2232 * giscanner/ast.py: Add interfaces property
2234 * giscanner/girwriter.py: Write out implemented
2236 * giscanner/glibtransformer.py: Introspect
2237 implemented interfaces.
2238 * tests/scanner/*: Make FooObject implement
2241 2008-08-25 Colin Walters <walters@verbum.org>
2243 * giscanner/glibtransformer.py: More correctly pair
2244 methods; if we have a symbol that starts with
2245 e.g. hippo_canvas look for a matching HippoCanvas
2246 class before accepting e.g. HippoCanvasImage.
2248 2008-08-24 Colin Walters <walters@verbum.org>
2250 * tools/g-ir-scanner: Filter out unknown options from
2253 2008-08-24 Colin Walters <walters@verbum.org>
2255 * giscanner/glibtransformer.py: Fail with better
2256 error if we can't find library.
2258 2008-08-24 Colin Walters <walters@verbum.org>
2260 * tools/g-ir-scanner: Use subprocess instead of
2261 commands, works on Windows and avoids the evil
2264 2008-08-24 Colin Walters <walters@verbum.org>
2266 * giscanner/glibtransformer.py: Skip over
2267 g_object_get_type from GLib trunk.
2269 2008-08-24 Colin Walters <walters@verbum.org>
2271 * girepository/girepository.c (g_irepository_require):
2272 Don't open shared library here; we already do it
2275 2008-08-24 Colin Walters <walters@verbum.org>
2277 * girepository/gtypelib.c: Add context stack so
2278 when we get an error we can print out nicely
2281 2008-08-24 Johan Dahlin <johan@gnome.org>
2283 * girepository/girparser.c (start_glib_boxed), (start_function),
2284 (start_field), (start_alias):
2285 Refactor a couple of parsing functions to be simpler to follow.
2288 2008-08-24 Johan Dahlin <johan@gnome.org>
2290 * girepository/girparser.c (start_function):
2291 Remove left-over code, checking type of function.
2293 2008-08-23 Colin Walters <walters@verbum.org>
2295 * giscanner/config.py: Define DATADIR.
2296 * giscanner/transformer.py: Look in DATADIR.
2298 2008-08-23 Colin Walters <walters@verbum.org>
2300 * girepository/gtypelib.c: Check constructor
2302 * girepository/girnode.c: Small tweaks.
2303 * girepository/ginfo.c: Calculate signature offsets
2305 * girepository/girparser.c: Remove duplicate
2307 * giscanner/glibtransformer.py: Avoid marking
2308 functions which return a basic type as
2311 2008-08-23 Colin Walters <walters@verbum.org>
2313 * girepository/girparser.c: Ignore <include>.
2314 * giscanner/girparser.py: Parse them.
2315 * giscanner/girwriter.py: Generate them.
2316 * giscanner/transformer.py: Process <include>
2317 recursively. Don't require full path for
2318 includes, look in {$XDG_DATA_DIRS}/gir.
2319 * tools/g-ir-scanner: Pass through includes.
2320 * Makefile.am: Remove extra --include
2322 * *-expected.gir: Add expected includes.
2324 2008-08-23 Johan Dahlin <johan@gnome.org>
2326 * tests/scanner/Makefile.am:
2327 * tests/scanner/annotation-expected.gir:
2328 * tests/scanner/drawable-expected.gir:
2329 Avoid duplication in the Makefile, regenerate with new
2330 namespaces (same as the filename)
2332 2008-08-22 Colin Walters <walters@verbum.org>
2334 * girepository/girnode.c: Don't hardcode integers,
2337 2008-08-22 Johan Dahlin <johan@gnome.org>
2339 * giscanner/sourcescanner.py:
2340 Check for ../gobject-introspection-1.0.pc.in to determine
2341 if we run installed or uninstalled.
2343 2008-08-22 Johan Dahlin <johan@gnome.org>
2346 * giscanner/sourcescanner.py:
2347 Send in undefs/defines via writing it directly to stdin
2348 of cpp instead of via arguments.
2350 2008-08-22 Colin Walters <walters@verbum.org>
2352 * tools/generate.c, tools/compiler.c: Default
2354 * all Makefile.am: Update.
2356 2008-08-22 Colin Walters <walters@verbum.org>
2358 * girepository/girparser.c: Pass through
2359 recursive types. Avoid overwriting errors.
2360 * giscanner/xmlwriter.py: Always write the
2362 * tests/*.gir: Adjust.
2363 * tests/scanner/Makefile.am: Build typelibs,
2364 and generate XML from those. Once we
2365 have a good diff mechanism...
2366 * tests/scanner/*-expected.gir: Add XML
2368 * tools/g-ir-scanner: Accept --typelib-xml
2370 * tools/generate.c: Better defaults for transfer.
2372 2008-08-22 Johan Dahlin <johan@gnome.org>
2376 * giscanner/Makefile.am:
2377 * giscanner/config.py.in:
2378 * giscanner/sourcescanner.py:
2379 Use the generated glibconfig.h for all scanner invokations.
2380 Rename it to glibconfig-scanner.h and install it.
2381 Add a config.py which so far contains the include dir.
2383 2008-08-22 Johan Dahlin <johan@gnome.org>
2386 Replace glibconfig.h with our own, do some replacement
2387 for CPP/C features we do not support
2389 2008-08-22 Colin Walters <walters@verbum.org>
2391 * tools/generate.c (write_callable_info): Fix unref
2394 2008-08-22 Colin Walters <walters@verbum.org>
2396 * gobject-introspection-1.0.pc.in: Add g-ir-generate.
2397 * tests/Makefile.am: Support $(DEBUG)
2398 * tools/generate.c: Do immediate close tags if no
2401 2008-08-21 Colin Walters <walters@verbum.org>
2403 * tests/scanner/drawable-expected.gir,
2404 * tests/scanner/drawable.c,
2405 * tests/scanner/drawable.h:
2408 2008-08-21 Colin Walters <walters@verbum.org>
2410 * giscanner/glibtransformer.py: Compute prefix
2411 by searching through the symbol for bits
2412 rather than going directly from ctype; this fixes
2415 2008-08-21 Colin Walters <walters@verbum.org>
2417 * giscanner/glibtransformer.py: Also try squashing
2418 underscores from namespace, fixes webkit_web_view_new.
2420 2008-08-21 Colin Walters <walters@verbum.org>
2422 * giscanner/glibtransformer.py: More ctor work,
2423 avoid having gtk_window_group_new end up under
2426 2008-08-21 Colin Walters <walters@verbum.org>
2428 * giscanner/glibtransformer.py: Much simpler approach
2429 of mapping uscored names to classes.
2430 * giscanner/utils.py: Remove unnecessary function.
2432 2008-08-21 Johan Dahlin <johan@gnome.org>
2434 * girepository/girepository.c (g_irepository_require):
2435 Plug memory leak and avoid using freed memory.
2436 Resolve the whole module path, here as well.
2438 2008-08-21 Colin Walters <walters@verbum.org>
2440 * giscanner/glibtransformer.py: Look up all permutations
2441 of class names when scanning methods/ctors based on
2442 the prefix instead of using the return value. This
2443 associates gtk_window_new with the right class.
2445 2008-08-21 Colin Walters <walters@verbum.org>
2447 * girepository/girmodule.c (g_ir_module_build_typelib):
2448 Revert change to increment header_size; we do that in
2451 2008-08-21 Colin Walters <walters@verbum.org>
2453 * girepository/girnode.c (write_string): Tweak to
2454 use UINT instead of INT. Not likely to matter.
2455 * girepository/girmodule.c (g_ir_module_build_typelib):
2456 Add to header_offset as well for header strings
2457 to match what write_string does.
2458 * girepository/gtypelib.c: Replace is_name with
2459 validate_name, which more strongly validates and
2460 handles errors in a better way. Update all callers.
2461 * giscanner/glibtransformer.py: Handle constructors
2464 2008-08-21 Johan Dahlin <johan@gnome.org>
2466 * gir/Makefile.am (typelibs_DATA): Build and
2467 install the Gio.typelib too
2469 * girepository/gtypelib.c (_g_typelib_init):
2470 Use g_module_build_path to resolve the shlib name
2472 2008-08-21 Colin Walters <walters@verbum.org>
2474 * gir/Makefile.am: CLEANFILES typelibs too.
2476 2008-08-21 Johan Dahlin <johan@gnome.org>
2478 * giscanner/glibtransformer.py:
2479 Do not send .la files through find_library.
2481 2008-08-21 Colin Walters <walters@verbum.org>
2483 * girepository/girparser.c (g_irepository_require):
2484 Fix one small leak in error case.
2486 2008-08-21 Johan Dahlin <johan@gnome.org>
2489 Parse glibconfig.h as well and install the compiled
2492 2008-08-21 Johan Dahlin <johan@gnome.org>
2495 * giscanner/glibtransformer.py:
2496 * tools/g-ir-scanner:
2497 Do not hard-core library names in the Makefile, reuse
2498 ctypes find_library instead.
2500 2008-08-21 Johan Dahlin <johan@gnome.org>
2502 * girepository/girparser.c (resolve_aliases):
2503 Remove compilation warnings
2505 2008-08-21 Johan Dahlin <johan@gnome.org>
2507 * girepository/girepository.c (g_irepository_require):
2508 Rewrap and fix double free bug by leaking a bit.
2510 2008-08-20 Colin Walters <walters@verbum.org>
2512 * girepository/girepository.c: Add new function
2513 g_irepository_get_typelib_path which tells
2514 us from where we loaded a namespace.
2516 2008-08-20 Colin Walters <walters@verbum.org>
2518 * tests/scanner/*-expected.gir: Adjust for
2519 added shared-library.
2520 * giscanner/giwriter.py: Make pylint happy.
2522 2008-08-20 Colin Walters <walters@verbum.org>
2524 * girepository/girmodule.c (g_ir_module_build_typelib):
2525 Calculate size correctly, avoid use-after-free.
2527 2008-08-20 Colin Walters <walters@verbum.org>
2529 * girepository/girepository.c: Remove
2530 g_irepository_register_file in favor of
2531 g_irepository_require. There are two
2532 possible deployment scenarios for typelibs:
2533 First, separate in $DATADIR/gitypelibs/. Second,
2534 they may be embedded in shlibs. However since
2535 the first is now the normal case, the API is
2536 optimized around it.
2538 Refactor internals to look up typelibs for
2539 namespaces just-in-time, but we expect
2540 consumers to call g_irepository_require.
2542 Also, add some docs. No one has died from that
2544 * gir/Makefile.am: Need --library for glib.
2545 * giscanner/girwriter.py: Write out shared-library.
2546 * tools/g-ir-writer: Take the first --library
2547 argument as the target of shared-library. In
2548 the future we should make this nicer with pkg-config
2551 2008-08-20 Colin Walters <walters@verbum.org>
2553 * girepository/girparser.py: And parse them.
2555 2008-08-20 Johan Dahlin <johan@gnome.org>
2557 * giscanner/glibast.py: Add gshort/gushort types
2559 2008-08-20 Colin Walters <walters@verbum.org>
2561 * gir/Makefile.am: Rename .gir files using GI namespace.
2562 * girepository/girepository.c: Use XDG_DATA_DIRS for
2563 looking up typelibs. Also typelibs are now suffixed
2565 * tests/invoke/Makefile.am: Only use metadata.
2566 * girepository/Makefile.am: Remove unnecessary include.
2567 * tests/scanner/Makefile.am: Update using GI namespaces
2568 for scanner includes.
2570 2008-08-20 Colin Walters <walters@verbum.org>
2572 * girepository/transformer.py: Suppress aliases whose
2574 * girepository/ast.py: Define some more aliases.
2576 2008-08-20 Colin Walters <walters@verbum.org>
2578 * girepository/girparser.c: Avoid alias infloops.
2580 2008-08-20 Colin Walters <walters@verbum.org>
2582 * tests/scanner/foo-expected.gir: Fix expected list type.
2584 2008-08-20 Johan Dahlin <johan@gnome.org>
2586 * giscanner/glibtransformer.py (GLibTransformer._resolve_type_name):
2587 Add a workaround for #548689.
2588 We can now compile gtk!
2590 2008-08-20 Colin Walters <walters@verbum.org>
2592 * giscanner/glibtransformer.py: Try to look up
2593 aliases using the c:type too.
2595 2008-08-20 Colin Walters <walters@verbum.org>
2597 * girepository/girparser.c: Parse union fields.
2599 2008-08-20 Johan Dahlin <johan@gnome.org>
2601 * giscanner/ast.py: Make time_t an alias for long
2603 * gir/gio-2.0-good.gir:
2604 * gir/glib-2.0-good.gir:
2605 * gir/gobject-2.0-good.gir:
2607 * giscanner/glibtransformer.py:
2608 Do not delete Class structures, we need them in gdk/gtk.
2609 * tests/scanner/drawable-expected.gir:
2610 * tests/scanner/foo-expected.gir:
2611 * tests/scanner/utility-expected.gir:
2614 2008-08-20 Johan Dahlin <johan@gnome.org>
2616 * tests/scanner/Makefile.am:
2617 * tests/scanner/annotation-expected.gir:
2618 * tests/scanner/annotation.c (annotation_object_class_init),
2619 (annotation_object_init), (annotation_object_method),
2620 (annotation_object_in), (annotation_object_out),
2621 (annotation_object_inout), (annotation_object_inout2),
2622 (annotation_object_inout3), (annotation_object_calleeowns),
2623 (annotation_object_calleesowns), (annotation_object_get_strings),
2624 (annotation_object_with_voidp), (annotation_object_get_objects),
2625 (annotation_object_create_object), (annotation_object_allow_none):
2626 * tests/scanner/annotation.h:
2627 * tests/scanner/foo-expected.gir:
2628 * tests/scanner/foo.c:
2629 * tests/scanner/foo.h:
2630 Split out annotation tests out of foo
2632 2008-08-20 Johan Dahlin <johan@gnome.org>
2634 * tests/scanner/Foo-expected.gir:
2635 * tests/scanner/Makefile.am:
2636 * tests/scanner/foo-expected.gir:
2637 * tests/scanner/foo-object.h:
2638 * tests/scanner/foo.c:
2639 Foo->foo, foo-object.h -> foo.h
2641 2008-08-20 Johan Dahlin <johan@gnome.org>
2643 * tests/scanner/Foo-expected.gir:
2644 * tests/scanner/Makefile.am:
2645 * tests/scanner/drawable-expected.gir:
2646 * tests/scanner/drawable.c (test_drawable_class_init),
2647 (test_drawable_init):
2648 * tests/scanner/drawable.h:
2649 * tests/scanner/foo-object.h:
2650 * tests/scanner/foo.c (foo_boxed_method):
2651 Move the drawable parts out of Foo to its own test.
2653 2008-08-20 Johan Dahlin <johan@gnome.org>
2655 * tests/scanner/Foo-expected.gir:
2656 * tests/scanner/foo-object.h:
2657 * tests/scanner/foo.c (foo_drawable_class_init),
2658 (foo_drawable_init):
2659 Add a based on GdkDrawable which generates
2662 2008-08-19 Colin Walters <walters@verbum.org>
2664 * giscanner/transformer.py: Don't try
2665 to strip prefix before namespace.
2667 2008-08-19 Johan Dahlin <johan@gnome.org>
2669 * giscanner/transformer.py:
2670 * tests/scanner/Foo-expected.gir:
2671 * tests/scanner/foo-object.h:
2672 Add support for typedef void foo type of
2675 2008-08-19 Johan Dahlin <johan@gnome.org>
2678 * giscanner/girwriter.py:
2679 * giscanner/glibtransformer.py:
2680 * giscanner/transformer.py:
2681 * tests/scanner/Foo-expected.gir:
2682 Add basic support for union, base the code much
2683 on Struct. Add a testcase.
2685 2008-08-19 Johan Dahlin <johan@gnome.org>
2687 * tests/scanner/Foo-expected.gir:
2688 * tests/scanner/foo-object.h:
2689 Add a union testcase which the compiler currently
2692 2008-08-19 Johan Dahlin <johan@gnome.org>
2694 * gobject-introspection-1.0.pc.in:
2695 Add a g_ir_compiler variable
2697 2008-08-19 Colin Walters <walters@verbum.org>
2699 * giscanner/ast.py: Rework types to be more closely
2701 * giscanner/girparser.py: Parse more bits.
2702 * giscanner/girwriter.py: Write sequences in a new
2703 way that specifies container type.
2704 * giscanner/glibast.py: Adjust for ast.py changes,
2705 add 'ctype' property to GLibObject and GLibInterface
2706 so we can look things up by it later.
2707 * gicanner/transformer.py: Names is new class holding
2708 the various namespaces we manage. Do not confuse
2709 with Namespace which is toplevel XML node effectively.
2710 Rework all type resolution to go through
2711 _resolve_type_name_1.
2712 * giscanner/glibtransformer.py: Raise UnknownTypeError
2713 instead of ValueError for cleanliness. Add Unresolved
2714 class to mark types whose parent we haven't seen yet.
2715 Use new Names object from transformer.py.
2716 Correctly look up parent=.
2717 Fix type validation to handle sequences.
2718 * tests/scanner/Foo-expected.gir: Update for sequence
2719 work, int instead of int32.
2720 * tools/g-ir-scanner: Add --noclosure option
2721 * gir/Makefile.am: Use --noclosure by default for
2724 2008-08-18 Johan Dahlin <johan@gnome.org>
2726 * gir/gio-2.0-good.gir:
2727 * gir/glib-2.0-good.gir:
2728 * gir/gobject-2.0-good.gir:
2731 2008-08-18 Johan Dahlin <johan@gnome.org>
2734 * giscanner/girparser.py:
2735 * giscanner/girwriter.py:
2736 * giscanner/glibast.py:
2737 * giscanner/glibtransformer.py:
2738 * giscanner/transformer.py:
2739 * tests/scanner/Foo-expected.gir:
2740 * tests/scanner/foo-object.h:
2741 * tests/scanner/utility-expected.gir:
2742 * tests/scanner/utility.h:
2743 Redo type resolving and validation.
2744 Add a couple of new tests.
2745 Patch mostly written by Colin.
2747 2008-08-18 Johan Dahlin <johan@gnome.org>
2750 * giscanner/girparser.py:
2752 * giscanner/transformer.py:
2753 Improve enum parsing for enums without a GType.
2754 Make flags/enum references to other girs work
2755 * giscanner/utils.py:
2757 * tests/scanner/Makefile.am:
2758 * tests/scanner/foo-object.h:
2759 * tests/scanner/utility-expected.gir:
2760 * tests/scanner/utility.h:
2761 Add a new test for external enum references
2763 2008-08-18 Johan Dahlin <johan@gnome.org>
2765 * docs/global-module-registry.txt: Update
2767 * tests/array.gir: Update with new type proposal
2769 * girepository/girepository.c (g_type_tag_to_string):
2770 * girepository/girepository.h:
2771 * girepository/girnode.c (g_ir_node_get_full_size_internal),
2773 * girepository/girnode.h:
2774 Make enum serializing functions public. Clean up some whitespace.
2776 2008-08-17 Johan Dahlin <johan@gnome.org>
2778 * docs/global-module-registry.txt:
2779 Add a document for an on disk module registry format
2781 2008-08-17 Johan Dahlin <johan@gnome.org>
2784 * gir/gio-2.0-good.gir:
2787 2008-08-17 Johan Dahlin <johan@gnome.org>
2790 * gir/glib-2.0-good.gir:
2791 * gir/gobject-2.0-good.gir:
2792 * giscanner/cgobject.py:
2793 * giscanner/glibtransformer.py:
2794 Regenerate GObject & GType.
2795 Avoid warnings when generating gobject-2.0.gir.
2796 Introspect a little more, and skip *_get_type functions.
2798 2008-08-17 Colin Walters <walters@verbum.org>
2800 * gir/glib-2.0.gir, gir/gobject-2.0.gir:
2801 Rename to -good, always generate during build.
2802 * gir/Makefile.am: Ensure .gir files dep on
2803 all scanner sources.
2804 * Makefile.am: Switch build order to ensure
2805 the scanner is ready before we do gir/.
2806 * tools/g-ir-scanner: Look for .git too.
2808 2008-08-17 Johan Dahlin <johan@gnome.org>
2810 * girepository/gtypelib.c (validate_enum_blob):
2811 * giscanner/glibtransformer.py:
2812 * giscanner/transformer.py:
2813 Remove resolve_possible_typedefs, it was unused.
2814 Allow multiple enum values of the sample value in an enum,
2815 since it's actually pretty common.
2816 Register enums so they can be resolved too.
2818 2008-08-16 Johan Dahlin <johan@gnome.org>
2820 * giscanner/girparser.py:
2821 Parse enumeration/bitfield.
2823 2008-08-16 Johan Dahlin <johan@gnome.org>
2825 * giscanner/girparser.py:
2828 2008-08-16 Johan Dahlin <johan@gnome.org>
2830 * giscanner/glibtransformer.py:
2831 Resolve type names for alias targets
2832 * giscanner/transformer.py:
2833 Skip FILE* parameters fow now
2835 2008-08-16 Johan Dahlin <johan@gnome.org>
2838 * gir/gobject-2.0.gir:
2841 * tests/scanner/Makefile.am:
2844 2008-08-15 Colin Walters <walters@verbum.org>
2846 * giscanner/glibtransformer.py: Explicitly construct
2847 new list, since we're deleting as we iterate.
2848 Don't delete all structures which end in Class; just
2849 ones which have a paired GObject.
2850 Fix printing of type warning.
2851 * giscanner/transformer.py: Make strip_namespace_object
2852 be the identity function if it doesn't match the
2855 2008-08-15 Colin Walters <walters@verbum.org>
2857 * giscanner/cgobject.py: Define yet more argument
2858 prototypes; fix prototype for g_type_fundamental.
2860 2008-08-14 Johan Dahlin <johan@gnome.org>
2862 * tests/Makefile.am:
2863 * tests/constant.gir:
2864 * tests/gobject.gir:
2866 * tools/generate.c (write_struct_info):
2867 Fix generator for constant/gobject/struct
2869 2008-08-14 Johan Dahlin <johan@gnome.org>
2871 * tests/Makefile.am:
2873 * tools/generate.c (write_enum_info):
2874 Fix generation of enum/bitfields
2876 2008-08-14 Johan Dahlin <johan@gnome.org>
2878 * girepository/girparser.c (start_field), (start_constant),
2879 (start_type), (end_element_handler):
2880 Clear up constant parsing
2885 * tools/generate.c (write_callable_info), (write_function_info),
2886 (write_callback_info), (write_constant_info), (write_signal_info),
2887 (write_vfunc_info), (write_property_info), (write_object_info),
2888 (write_interface_info):
2889 Constants/Signals are handled now.
2891 2008-08-14 Johan Dahlin <johan@gnome.org>
2893 * girepository/girparser.c (start_type):
2894 Don't require c:type.
2895 * tests/Makefile.am:
2898 Update, remove parts we don't support yet
2899 * tests/roundtrips.sh:
2901 * tools/generate.c (write_type_info), (write_field_info),
2902 (write_callable_info), (write_struct_info):
2903 Make it emit proper gir.
2905 2008-08-14 Johan Dahlin <johan@gnome.org>
2907 * giscanner/transformer.py:
2908 New internal function for adding a new node.
2910 2008-08-14 Johan Dahlin <johan@gnome.org>
2913 Define an internal _H_ variable so we skip parsing both
2914 i18n headers, only one is needed.
2916 Add the glib-2.0.gir too.
2917 * giscanner/glibast.py:
2918 Add gconstpointer as an alias for ANY
2919 * giscanner/transformer.py:
2920 Do not lower case enumeration names per se.
2921 Skip functions which has parameters called 'va_list'
2923 2008-08-14 Colin Walters <walters@verbum.org>
2925 * giscanner/transformer.py: Comment data structures.
2926 Also squash pointers in resolve_type_name to correspond
2927 with what we do for params.
2928 * giscanner/glibtransformer.py: Print warnings in more
2929 situations. Rework checks for method/constructor to
2930 look up in our GType database instead of just checking
2931 for *. Avoid generating <record> for GObject which
2932 duplicate the <class>.
2933 * gir/Makefile.am: Generate glib-2.0.gir and gobject-2.0.gir
2936 2008-08-14 Johan Dahlin <johan@gnome.org>
2938 * giscanner/girwriter.py:
2939 * giscanner/glibast.py:
2940 * giscanner/glibtransformer.py:
2941 * giscanner/transformer.py:
2943 * tests/Makefile.am:
2944 Add pyflakes.py and run it in make check.
2945 Update the source code to fix the errors reported by
2948 2008-08-14 Johan Dahlin <johan@gnome.org>
2951 * giscanner/girparser.py:
2952 * giscanner/glibast.py:
2953 * giscanner/glibtransformer.py:
2954 Refactor the parser a bit.
2955 Add parent type to interfaces and update callsites.
2957 2008-08-14 Johan Dahlin <johan@gnome.org>
2959 * giscanner/glibtransformer.py:
2960 * giscanner/utils.py:
2961 Refactor a bit, avoid isinstance and add a method
2962 for each type we parse.
2964 2008-08-14 Johan Dahlin <johan@gnome.org>
2967 * giscanner/girparser.py:
2968 * giscanner/glibtransformer.py:
2969 * tests/Makefile.am:
2970 Run pep8.py in make check, fix old errors.
2972 2008-08-13 Colin Walters <walters@verbum.org>
2974 * giscanner/girparser.py: Parse records.
2976 2008-08-13 Colin Walters <walters@verbum.org>
2978 * gir/Makefile.am: Install again.
2979 * gir/gobject-2.0.gir: Add some more bits.
2981 2008-08-13 Colin Walters <walters@verbum.org>
2983 * gir/gobject-2.0.gir: Use correct namespace, add GType.
2984 * giscanner/girparser.py: Handle aliases.
2985 * giscanner/transformer.py: Record aliases. Make resolver
2986 functions public; we now call into these explicitly from
2987 glibtransformer. Handle resolving aliases.
2988 * giscanner/glibtransformer.py: Separate our internal namespace
2989 from included ones. Call up into transformer's resolver functions.
2991 2008-08-13 Johan Dahlin <johan@gnome.org>
2993 * girepository/girnode.c (g_ir_node_get_full_size_internal):
2994 * girepository/girparser.c (start_class):
2995 * giscanner/glibtransformer.py:
2996 Allow get_type to be None, set a get_type for GInitiallyUnowned too.
2998 2008-08-13 Johan Dahlin <johan@gnome.org>
3000 * giscanner/cgobject.py:
3001 Register GInitiallyUnowned
3002 * giscanner/girwriter.py:
3003 * giscanner/glibtransformer.py:
3004 Special case GObject/GInitially owned as they are a bit special to use.
3006 2008-08-13 Colin Walters <walters@verbum.org>
3008 * tests/scanner/Foo-expected.gir, tests/scanner/utility-expected.gir:
3009 Object is in GObject namespace.
3011 2008-08-13 Colin Walters <walters@verbum.org>
3013 * giscanner/girparser.py: Fix processing of functions
3016 2008-08-13 Colin Walters <walters@verbum.org>
3018 * giscanner/girparser.py: Parse more than just <class.
3019 * giscanner/glibtransformer.py: Put aliases in a separate
3020 data structure since their name is not canonicall.
3021 * giscanner/transformer.py: Handle resolving type names
3024 2008-08-13 Johan Dahlin <johan@gnome.org>
3026 * tools/g-ir-scanner:
3027 Allow multiple libraries
3028 * giscanner/glibtransformer.py:
3029 Rename load_library to add_library, traverse over all libraries
3030 when trying to resolve a function
3032 2008-08-12 Colin Walters <walters@verbum.org>
3034 * giscanner/transformer.py: Record typedefs as <alias> elements.
3035 Also attempt to look up types in external namespaces.
3036 * giscanner/girwriter.py: Write them.
3037 * giscanner/glibtransformer.py: Rework resolver using real instanceof
3038 checks. Resolve interface methods and properties.
3039 * tests/scanner/foo-object.h: Add a method with typedef.
3040 * tests/scanner/Foo-expected.gir: Update.
3041 * girepository/girnode.c: Debug tweaks.
3042 * girepository/girparser.c: Make a first pass through the XML where we
3043 record all the aliases. This lets us resolve them as we go through the
3045 * gir/Makefile.am: Don't install gobject-2.0.gir; we want that to come
3046 from gir-repository.
3048 2008-08-12 Colin Walters <walters@verbum.org>
3050 * giscanner/glibtransformer.py: Resolve typedefs (e.g. AtkAttributeSet -> GSList).
3051 Correctly do subclasseing in 2nd pass resolution. Handle callbacks in structure
3053 * giscanner/transformer.py: Record typedefs and expose public API for resolving
3055 * tests/scanner/Foo-expected.gir: Fix expected callback types.
3057 2008-08-12 Colin Walters <walters@verbum.org>
3059 * giscanner/glibtransformer.py: Also transform object properties.
3061 2008-08-12 Colin Walters <walters@verbum.org>
3063 * giscanner/glibtransformer.py: Also transform callbacks
3064 and structure field types.
3065 * tests/scanner/Fooe-expected.gir: Update to expect correct
3066 names for callbacks and structs.
3068 2008-08-12 Colin Walters <walters@verbum.org>
3070 * girepository/girparser.c: Handle 'any'.
3071 * tests/scanner/Foo-expected.gir, tests/scanner/foo-object.h:
3072 Add test for void *.
3074 2008-08-12 Colin Walters <walters@verbum.org>
3076 * giscanner/glibtransformer.py: We need to do type
3077 resolution in a second pass after we've seen all the
3078 enums, records, etc.
3080 2008-08-12 Colin Walters <walters@verbum.org>
3082 * tests/scanner/Foo-expected.gir, tests/scanner/foo-object.h:
3083 Add enum return value.
3084 * giscanner/glibtransformer.py: Transform function return types
3087 2008-08-12 Colin Walters <walters@verbum.org>
3089 * tests/scanner/Makefile.am: Dep .gir files on scanner
3090 sources too. Also remove @ so we see scanner invocations.
3092 2008-08-12 Colin Walters <walters@verbum.org>
3094 * girepository/girparser.c, girepository/gtypelib.c,
3095 girepository/gtypelib.h, girepository/girnode.c:
3096 Remove usage of (GAPI-oriented) TypeTag in favor of
3097 GITypeTag from girepository.h.
3099 2008-08-10 Colin Walters <walters@verbum.org>
3101 * tests/roundtrips.sh: Use the correct tests.
3103 2008-08-10 Colin Walters <walters@verbum.org>
3105 * giscanner/cgobject.py: Declare/wrap a few more functions.
3106 Fix parameter types for g_object_new and g_type_fundamental.
3108 2008-08-10 Colin Walters <walters@verbum.org>
3110 * giscanner/cgobject.py: Add new decorator @gwrap which forces
3111 us to declare types for both return value and parameters. The
3112 ctypes default of 'int' is bad because it hides 32/64 bit
3113 problems. Convert all existing functions to use it.
3115 2008-08-09 Johan Dahlin <johan@gnome.org>
3117 * giscanner/__init__.py:
3119 * giscanner/cgobject.py:
3120 * giscanner/gidlparser.py:
3121 * giscanner/gidlwriter.py:
3122 * giscanner/girparser.py:
3123 * giscanner/girwriter.py:
3124 * giscanner/glibast.py:
3125 * giscanner/glibtransformer.py:
3126 * giscanner/odict.py:
3127 * giscanner/sourcescanner.py:
3128 * giscanner/transformer.py:
3129 * giscanner/utils.py:
3130 * giscanner/xmlwriter.py:
3131 * tools/g-ir-scanner:
3135 2008-08-09 Johan Dahlin <johan@gnome.org>
3138 * relaxng/c-types.xml:
3139 * relaxng/g-types.xml:
3140 * relaxng/relaxng.rng:
3142 Remove outdated relaxng schemas.
3144 2008-08-09 Johan Dahlin <johan@gnome.org>
3147 Rename metadata to typelib in variable names,
3150 2008-08-09 Johan Dahlin <johan@gnome.org>
3154 Remove old C scanner, which got rewritten in python.
3156 2008-08-09 Johan Dahlin <johan@gnome.org>
3158 * girepository/Makefile.am:
3159 * tools/Makefile.am:
3160 * tools/girmodule.c:
3161 * tools/girmodule.h:
3164 * tools/girparser.c:
3165 * tools/girparser.h:
3166 * tools/girwriter.c:
3167 * tools/girwriter.h:
3168 Move shared *.[ch] files to girepository from tools
3170 2008-08-09 Johan Dahlin <johan@gnome.org>
3172 * tests/Makefile.am:
3175 * tests/constant.test:
3177 * tests/errors.test:
3178 * tests/function.test:
3179 * tests/gobject.test:
3180 * tests/interface.test:
3181 * tests/object.test:
3182 * tests/struct.test:
3187 Rename *.test to *.gir
3189 2008-08-09 Johan Dahlin <johan@gnome.org>
3192 * tests/Makefile.am:
3193 * tests/parser/Foo-expected.gir:
3194 * tests/parser/Makefile.am:
3195 * tests/parser/foo-object.h:
3196 * tests/parser/foo.c:
3197 * tests/parser/utility-expected.gir:
3198 * tests/parser/utility.c:
3199 * tests/parser/utility.h:
3200 * tests/scanner/Makefile.am:
3201 Rename tests/parser to test/scanner
3203 2008-08-08 Colin Walters <walters@verbum.org>
3205 * tests/roundtrips.sh: Use local .gir files again.
3207 2008-08-08 Colin Walters <walters@verbum.org>
3209 * tests/invoke/Makefile.am: .gir file depends on libtool
3212 2008-08-08 Colin Walters <walters@verbum.org>
3214 * tools/girnode.c: Pass through parent node so we can
3215 print the node whose child is NULL, if that occurs.
3217 2008-08-08 Johan Dahlin <johan@gnome.org>
3219 * tests/Makefile.am:
3220 Disable roundtrip tests which are not yet working
3221 * tests/invoke/testfns.gir:
3224 2008-08-08 Johan Dahlin <johan@gnome.org>
3226 * giscanner/girwriter.py:
3228 * giscanner/glibast.py:
3229 * giscanner/glibtransformer.py:
3230 Swap order of members, to keep it consistent with
3233 2008-08-08 Johan Dahlin <johan@gnome.org>
3235 * girepository/gtypelib.c (validate_header):
3236 * girepository/gtypelib.h:
3238 * giscanner/girwriter.py:
3239 * giscanner/sourcescanner.c (gi_source_symbol_ref),
3240 (gi_source_symbol_unref):
3243 * tests/constant.test:
3245 * tests/errors.test:
3246 * tests/function.test:
3247 * tests/gobject.test:
3248 * tests/interface.test:
3249 * tests/invoke/Makefile.am:
3250 * tests/invoke/testfns.xml:
3251 * tests/object.test:
3252 * tests/parser/Makefile.am:
3253 * tests/roundtrips.sh:
3254 * tests/struct.test:
3259 * tools/Makefile.am:
3260 * tools/compiler.c (main):
3261 * tools/generate.c (write_callable_info), (write_function_info),
3263 * tools/gidlmodule.c:
3264 * tools/gidlmodule.h:
3267 * tools/gidlparser.c:
3268 * tools/gidlparser.h:
3269 * tools/gidlwriter.c:
3270 * tools/gidlwriter.h:
3271 * tools/scanner.c (create_node_from_gtype),
3272 (create_node_from_ctype), (g_igenerator_process_properties),
3273 (g_igenerator_process_signals), (g_igenerator_create_object),
3274 (g_igenerator_create_interface), (g_igenerator_create_boxed),
3275 (g_igenerator_create_enum), (g_igenerator_create_flags),
3276 (g_igenerator_process_function_symbol),
3277 (g_igenerator_process_unregistered_struct_typedef),
3278 (g_igenerator_process_struct_typedef),
3279 (g_igenerator_process_union_typedef),
3280 (g_igenerator_process_enum_typedef),
3281 (g_igenerator_process_function_typedef),
3282 (g_igenerator_process_constant), (g_igenerator_process_symbols),
3283 (g_igenerator_add_module), (g_igenerator_add_include_idl):
3284 Merge in the gir-compiler branch.
3285 Thanks to Philip and Colin for their help.
3287 2008-07-26 Colin Walters <walters@verbum.org>
3289 * tools/Makefile.am (bin_PROGRAMS): Install g-idl-compiler
3290 and g-idl-generate to go along with how we're changing this
3291 module to be installed.
3292 * gobject-introspection-1.0.pc.in: Set up Cflags and Libs.
3294 2008-07-24 Colin Walters <walters@verbum.org>
3296 * girepository/girepository.c (g_irepository_register): Add
3297 environment variable G_IREPOSITORY_VERBOSE so we can print
3298 out what we're doing.
3299 * girepository/girepository.c (g_irepository_register_file):
3300 Add GError error message to g_debug call.
3302 2008-07-08 Jürg Billeter <j@bitron.ch>
3304 * giscanner/glibast.py:
3308 2008-06-21 Johan Dahlin <jdahlin@async.com.br>
3310 * giscanner/girparser.py (GIRParser._parse_api): Ignore a few
3313 2008-06-20 Johan Dahlin <jdahlin@async.com.br>
3316 * giscanner/girwriter.py:
3317 * giscanner/transformer.py:
3318 * tests/parser/Foo-expected.gir:
3319 * tests/parser/foo-object.h:
3320 * tests/parser/foo.c (foo_object_allow_none):
3321 Add support for gtk-doc annotations for allow-none.
3324 2008-06-19 Johan Dahlin <jdahlin@async.com.br>
3327 * giscanner/girwriter.py:
3328 * giscanner/glibast.py:
3329 * giscanner/glibtransformer.py:
3330 * giscanner/transformer.py:
3331 * tests/parser/Foo-expected.gir:
3332 Start using abstract type instead of the raw C types.
3333 Register a bunch of glib types we care about.
3335 2008-06-19 Rob Taylor <rob.taylor@codethink.co.uk>
3340 2008-06-08 Philip Van Hoof <pvanhoof@gnome.org>
3342 * girepository/girepository.c:
3343 * girepository/gtypelib.c:
3344 * girepository/ginfo.c:
3345 * girepository/ginvoke.c:
3346 * girepository/girepository.h:
3347 * girepository/gtypelib.h:
3348 * girepository/gmetadata.c:
3349 * girepository/Makefile.am:
3350 * girepository/gmetadata.h:
3352 * tools/gidlmodule.c:
3355 * tools/gidlmodule.h:
3356 * tools/gidlparser.c:
3358 Renamed GMetadata to GTypelib
3360 2008-06-07 Johan Dahlin <jdahlin@async.com.br>
3362 * giscanner/xmlwriter.py:
3363 Improve line wrapping when > 79 charaters
3365 2008-06-05 Jürg Billeter <j@bitron.ch>
3368 * giscanner/girwriter.py:
3369 * giscanner/transformer.py:
3370 Use <type> element for field types
3371 * tests/parser/Foo-expected.gir:
3374 2008-06-04 Johan Dahlin <jdahlin@async.com.br>
3376 * giscanner/glibtransformer.py:
3377 Fix a bug which prevented GdkEvent from being generated
3379 2008-06-03 Johan Dahlin <jdahlin@async.com.br>
3381 * giscanner/Makefile.am:
3383 * giscanner/girwriter.py:
3384 * giscanner/glibast.py:
3385 * giscanner/glibtransformer.py:
3386 * giscanner/transformer.py:
3387 * giscanner/utils.py:
3388 * tests/parser/Foo-expected.gir:
3389 Improve enum member parsing and introspection
3391 2008-05-31 Johan Dahlin <jdahlin@async.com.br>
3393 * giscanner/scannerparser.y:
3394 * giscanner/sourcescanner.h:
3395 * giscanner/sourcescanner.py:
3396 Add a new source type enum for member.
3397 Use __repr__ for improved debugging
3398 * giscanner/girparser.py:
3400 * giscanner/transformer.py:
3401 Improve parsing of struct members.
3402 * tests/parser/foo-object.h:
3405 2008-05-31 Johan Dahlin <jdahlin@async.com.br>
3407 * giscanner/xmlwriter.py:
3408 Improve error reporting when trying to quote None.
3409 * giscanner/girparser.py:
3410 Do not print warnings when including more complete .gir files
3411 * giscanner/girwriter.py:
3412 Do not require a name for parameters, add a todo for singletons
3413 * giscanner/glibtransformer.py:
3414 Refactor the way structs are done, add a couple of hacks to allow
3416 * giscanner/transformer.py:
3417 Add enough hacks so cairo, atk and pango.gir can be parsed properly
3418 * gobject-introspection-1.0.pc.in:
3419 Export girdir, so we can access gobject-2.0.gir from outside
3421 2008-05-31 Johan Dahlin <jdahlin@async.com.br>
3423 * tools/g-ir-scanner:
3424 * tests/parser/Makefile.am:
3425 Update sys.path before running the parser so we don't have
3426 to setup PYTHONPATH ourselves.
3430 * girepository/Makefile.am:
3431 * giscanner/transformer.py:
3432 * gobject-introspection-1.0.pc.in:
3433 * gobject-introspection.pc.in:
3434 * tools/Makefile.am:
3436 Rename pkg-config name to gobject-introspection-1.0,
3437 Do not installed anything which is not using the gir format.
3438 Disable compililation the old C scanner, but still keep the source
3439 until all the remaning functionallity has been ported.
3441 2008-05-31 Johan Dahlin <jdahlin@async.com.br>
3443 * giscanner/giscannermodule.c (symbol_get_ident): Prevent
3444 a crash when symbol->indent is NULL.
3446 * giscanner/sourcescanner.py (ctype_name): Add ctype_name,
3447 a function to convert a CTYPE symbol to a string
3449 2008-05-24 Johan Dahlin <jdahlin@async.com.br>
3452 * giscanner/girwriter.py:
3453 * giscanner/giscannermodule.c
3454 (pygi_source_scanner_append_filename),
3455 (pygi_source_scanner_parse_file):
3456 * giscanner/glibtransformer.py:
3457 * giscanner/sourcescanner.py:
3458 Revert back to using temporary files to send in headers.
3459 Allow Functions to be passed in as callbacks, add a couple
3460 of try/excepts missing features.
3461 We can now scan pango
3463 2008-05-08 Johan Dahlin <johan@gnome.org>
3465 * giscanner/glibtransformer.py:
3466 * giscanner/transformer.py:
3467 Move namespace stripping glibtransformer->transformer
3469 2008-05-08 Johan Dahlin <johan@gnome.org>
3472 * giscanner/girwriter.py:
3473 * giscanner/glibtransformer.py:
3474 * giscanner/transformer.py:
3475 * tools/g-ir-scanner:
3476 Introduce a namespace ast node
3478 2008-05-05 Johan Dahlin <johan@gnome.org>
3480 * giscanner/__init__.py:
3481 * giscanner/sourcescanner.py:
3482 * giscanner/transformer.py:
3483 Move sourcescanner symbols to the sourcescanner module, instead
3484 of in the global __init__ namespace.
3486 2008-05-03 Johan Dahlin <johan@gnome.org>
3488 * giscanner/glibtransformer.py:
3489 * tools/g-ir-scanner:
3490 Handle missing parameters better, allow - and + in .la dlname
3493 2008-05-03 Johan Dahlin <johan@gnome.org>
3495 * giscanner/__init__.py:
3497 * giscanner/girwriter.py:
3498 * giscanner/glibtransformer.py:
3499 * giscanner/transformer.py:
3500 Parse struct fields properly, improve debugging.
3502 2008-04-29 Johan Dahlin <johan@gnome.org>
3505 * giscanner/girwriter.py:
3506 * giscanner/transformer.py:
3507 * tests/parser/Foo-expected.gir:
3509 Use transfer-ownership everywhere, to mark ownership/calle/caller etc.
3511 2008-04-29 Johan Dahlin <jdahlin@async.com.br>
3514 * docs/g-ir-scanner.1:
3515 * metadata-annotations-proposal.txt:
3516 * metadata-format.txt:
3517 Add a basic, unfinshed man page for g-ir-scanner, move documents into .txt
3519 2008-04-29 Johan Dahlin <jdahlin@async.com.br>
3521 * giscanner/girwriter.py:
3522 * giscanner/glibtransformer.py:
3523 * giscanner/transformer.py:
3524 * giscanner/xmlwriter.py:
3525 * tests/parser/Foo-expected.gir:
3526 * tests/parser/foo-object.h:
3527 Write record/structs to gir file too. Add a couple of tests,
3528 fix an off by one error in xmlwriter.py.
3530 2008-04-28 Johan Dahlin <johan@gnome.org>
3532 * giscanner/xmlwriter.py: Calculate the line length properly,
3533 include the provided extra indentation in the calculation, really.
3535 2008-04-28 Johan Dahlin <jdahlin@async.com.br>
3538 * giscanner/glibast.py:
3539 * giscanner/glibtransformer.py:
3540 * giscanner/transformer.py:
3541 * tools/g-ir-scanner:
3542 Add a --strip-prefix and sort out confusion between names and symbols
3543 for functions and struct + derivaties.
3544 Refactor bootstrap of g-ir-scanner, so we can set options on
3545 Transformer() before parsing everything.
3547 2008-04-28 Johan Dahlin <johan@gnome.org>
3549 * giscanner/transformer.py (Transformer._traverse_one): Avoid recursion
3550 when scanning girepository.h
3552 * giscanner/sourcescanner.py (SourceScanner._preprocess): Define
3553 a __GI_SCANNER__ when we run.
3555 2008-04-28 Johan Dahlin <jdahlin@async.com.br>
3558 * giscanner/girwriter.py:
3559 * giscanner/glibast.py:
3560 * giscanner/glibtransformer.py:
3561 * tests/parser/Foo-expected.gir:
3562 * tests/parser/utility-expected.gir:
3563 Rename most c:identifier to c:type. Add new ones to
3564 class/interface/enum/boxed.
3566 2008-04-28 Johan Dahlin <jdahlin@async.com.br>
3569 * giscanner/girwriter.py:
3570 * giscanner/glibtransformer.py:
3571 * tests/parser/Foo-expected.gidl:
3572 * tests/parser/Makefile.am:
3573 Move c:identifier from return-value to subchild type,
3574 as per Jürgs suggestion
3576 2008-04-28 Johan Dahlin <johan@gnome.org>
3578 * giscanner/girwriter.py:
3579 * tests/parser/Foo-expected.gir:
3580 Write property.type as a child node.
3582 2008-04-27 Johan Dahlin <johan@gnome.org>
3587 * gidl/gobject-2.0.gidl:
3589 * gir/gobject-2.0.gir:
3590 * tests/parser/Makefile.am:
3591 Replace the GObject gidl with a GObject gir.
3593 2008-04-27 Johan Dahlin <johan@gnome.org>
3595 * tools/Makefile.am (bin_SCRIPTS): g-ir-scanner is a script,
3598 * giscanner/xmlwriter.py:
3599 * tests/parser/Foo-expected.gir:
3600 Include indentation in line length calculation
3602 2008-04-27 Johan Dahlin <johan@gnome.org>
3604 * giscanner/girparser.py:
3605 Prettify NS parsing using elementtree.
3607 2008-04-27 Johan Dahlin <johan@gnome.org>
3610 * giscanner/Makefile.am:
3611 * giscanner/girparser.py:
3612 * giscanner/glibtransformer.py:
3613 * tests/parser/Foo-expected.gidl:
3614 * tests/parser/Foo-expected.gir:
3615 * tests/parser/Makefile.am:
3616 * tests/parser/utility-expected.gidl:
3617 * tests/parser/utility-expected.gir:
3618 * tools/g-ir-scanner:
3619 Switch over to GIR as the default format. Add a simple GIDL
3621 Update tests and fix simplify makefiles by depending
3622 on GNU make extensions.
3624 2008-04-27 Johan Dahlin <johan@gnome.org>
3626 * giscanner/xmlwriter.py:
3627 Wrap attributes for lines which are wider than 79 characters
3629 * giscanner/scannerlexer.l:
3630 Allow parenthesis in annotations
3633 * giscanner/gidlwriter.py:
3634 * giscanner/girwriter.py:
3635 * giscanner/glibtransformer.py:
3636 * giscanner/transformer.py:
3637 Add initial sequence support, including annotation.
3638 Refactor type handling a bit.
3640 2008-04-27 Johan Dahlin <johan@gnome.org>
3642 * tests/parser/Foo-expected.gidl:
3643 * tests/parser/foo-object.h:
3644 * tests/parser/foo.c (foo_object_class_init),
3645 (foo_object_get_strings), (foo_object_get_objects):
3646 Add two new functions to check sequence return values.
3647 Also fixes a compilation warning.
3649 2008-04-27 Johan Dahlin <johan@gnome.org>
3651 * giscanner/giscannermodule.c (]): Cast the getter, avoids
3652 a compilation warning.
3654 * tools/Makefile.am (g_ir_scanner_SOURCES):
3655 g-ir-scanner has no sources.
3657 2008-04-25 Johan Dahlin <johan@gnome.org>
3659 * giscanner/Makefile.am:
3661 * giscanner/gidlparser.py:
3662 * giscanner/gidlwriter.py:
3663 * giscanner/girwriter.py:
3664 * giscanner/glibast.py:
3665 * giscanner/glibtransformer.py:
3666 * giscanner/transformer.py:
3667 Split out nodes to ast.py and glibast.py
3669 2008-04-25 Johan Dahlin <jdahlin@async.com.br>
3671 * giscanner/Makefile.am:
3672 * giscanner/gidlparser.py:
3673 * giscanner/gidlwriter.py:
3674 * giscanner/girwriter.py:
3675 * giscanner/glibtransformer.py:
3676 * giscanner/gobjecttreebuilder.py:
3677 * giscanner/transformer.py:
3678 * giscanner/treebuilder.py:
3679 * tools/g-ir-scanner:
3680 Rename treebuilder to transformer and
3681 gobjectreebuilder to glibtransformer.
3683 2008-04-25 Johan Dahlin <jdahlin@async.com.br>
3685 * giscanner/Makefile.am:
3686 * giscanner/__init__.py:
3687 * giscanner/cgobject.py:
3688 * giscanner/gidlparser.py:
3689 * giscanner/gidlwriter.py:
3690 * giscanner/girwriter.py:
3691 * giscanner/gobjecttreebuilder.py:
3692 * giscanner/odict.py:
3693 * giscanner/sourcescanner.py:
3694 * giscanner/treebuilder.py:
3695 * giscanner/xmlwriter.py:
3696 * tools/Makefile.am:
3697 * tools/g-ir-scanner:
3698 Add LGPLv2 license header and install all python files
3700 2008-04-25 Johan Dahlin <jdahlin@async.com.br>
3703 * giscanner/gidlwriter.py:
3704 * giscanner/giscannermodule.c (pygi_source_directive_new),
3705 (directive_get_options), (pygi_source_symbol_new),
3706 (symbol_get_base_type), (pygi_source_type_new),
3707 (type_get_base_type), (type_get_child_list),
3708 (pygi_source_scanner_get_symbols),
3709 (pygi_source_scanner_get_directives):
3710 * giscanner/gobjecttreebuilder.py:
3711 * giscanner/sourcescanner.py:
3712 * giscanner/treebuilder.py:
3713 * tests/parser/foo-object.h:
3714 Add support for virtual methods.
3715 Pair struct FooClass with struct Foo.
3716 Clean up the SourceScanner bindings a bit.
3717 Add a testcase for virtual methods.
3719 2008-04-25 Johan Dahlin <jdahlin@async.com.br>
3721 * giscanner/cgobject.py:
3722 * giscanner/gidlwriter.py:
3723 * giscanner/gobjecttreebuilder.py:
3724 Add support for signals
3726 * tests/parser/foo.c (foo_object_class_init):
3727 * Foo-expected.gidl:
3728 Add a signal and update the expected output.
3730 2008-04-24 Johan Dahlin <jdahlin@async.com.br>
3732 * giscanner/gidlwriter.py:
3733 * giscanner/girwriter.py:
3734 * giscanner/giscannermodule.c (directive_get_name),
3735 (directive_get_value), (directive_get_options),
3736 (symbol_get_directives), (symbol_set_directives),
3737 (pygi_source_scanner_parse_file),
3738 (pygi_source_scanner_lex_filename),
3739 (pygi_source_scanner_get_directives), (init_giscanner):
3740 * giscanner/sourcescanner.c (gi_source_scanner_get_directives):
3741 * giscanner/sourcescanner.h:
3742 * giscanner/sourcescanner.py:
3743 * giscanner/treebuilder.py:
3744 * tools/g-ir-scanner:
3745 Add support for source/header annotations.
3747 2008-04-22 Johan Dahlin <jdahlin@async.com.br>
3749 * giscanner/gidlwriter.py:
3750 * giscanner/girwriter.py:
3751 * giscanner/gobjecttreebuilder.py:
3752 * giscanner/treebuilder.py:
3753 Add support for Callbacks
3755 2008-04-22 Havoc Pennington <hp@pobox.com>
3757 * girepository/ginvoke.c (g_function_info_invoke): If a symbol is
3758 not in metadata->module, look for it in the global module, in case
3759 some other object or the app itself provides the symbol.
3761 2008-04-22 Havoc Pennington <hp@pobox.com>
3763 * girepository/gmetadata.c (_g_metadata_init): hack to avoid
3764 dlopening a library that is already in the main app, by checking
3765 whether one of the lib's symbols is already loaded.
3767 2008-04-22 Johan Dahlin <jdahlin@async.com.br>
3769 * tests/parser/Foo-expected.gidl:
3770 * tests/parser/foo-object.h:
3773 2008-04-22 Havoc Pennington <hp@pobox.com>
3775 * girepository/ginfo.c (g_interface_info_find_method):
3776 Use interface_blob_size not object_blob_size to compute offset.
3778 2008-04-22 Havoc Pennington <hp@pobox.com>
3780 * girepository/gmetadata.c (_g_metadata_init): remove
3781 G_MODULE_BIND_LOCAL flag when loading libraries, since some libs
3782 (Glade and Clutter for example) rely on being loaded globally.
3784 2008-04-22 Havoc Pennington <hp@pobox.com>
3786 * girepository/ginfo.c (g_registered_type_info_get_g_type): new
3787 function to get the GType given a RegisteredTypeInfo
3789 2008-04-22 Johan Dahlin <johan@gnome.org>
3791 * COPYING: Add a LGPL license, to prevent automake to
3792 put in a copy of GPL here. Pointed out by Havoc.
3794 * girepository/ginfo.c (g_info_from_entry), (g_type_info_new),
3795 (g_type_info_is_pointer), (g_type_info_get_tag),
3796 (g_type_info_get_param_type), (g_type_info_get_interface),
3797 (g_type_info_get_array_length), (g_type_info_is_zero_terminated),
3798 (g_type_info_get_n_error_domains), (g_type_info_get_error_domain),
3799 (g_error_domain_info_get_codes), (g_enum_info_get_value),
3800 (g_object_info_get_interface), (g_object_info_get_field),
3801 (g_interface_info_get_prerequisite),
3802 (g_signal_info_get_class_closure), (g_constant_info_get_value):
3803 * girepository/ginvoke.c (get_ffi_type):
3804 * girepository/girepository.h:
3805 * girepository/gmetadata.c (g_metadata_get_dir_entry),
3806 (g_metadata_check_sanity), (validate_header),
3807 (validate_array_type_blob), (validate_iface_type_blob),
3808 (validate_param_type_blob), (validate_error_type_blob),
3809 (validate_type_blob), (validate_constant_blob),
3810 (validate_struct_blob), (validate_enum_blob):
3811 * girepository/gmetadata.h:
3812 * tests/Makefile.am:
3813 * tests/invoke/Makefile.am:
3814 * tests/invoke/invoke.c (main):
3815 * tests/roundtrips.sh:
3816 * tools/Makefile.am:
3817 * tools/compiler.c (format_output), (write_out_metadata), (main):
3818 * tools/generate.c (write_type_name), (write_type_info),
3819 (write_constant_value), (write_enum_info), (load_metadata), (main):
3820 * tools/gidlcompilercontext.c:
3821 * tools/gidlcompilercontext.h:
3822 * tools/gidlcompilerentrynode.c:
3823 * tools/gidlcompilerentrynode.h:
3824 * tools/gidlcompilertypenode.c:
3825 * tools/gidlcompilertypenode.h:
3826 * tools/gidlmodule.c (g_idl_module_build_metadata):
3827 * tools/gidlmodule.h:
3828 * tools/gidlnode.c (init_stats), (dump_stats),
3829 (g_idl_node_get_size), (g_idl_node_get_full_size),
3830 (g_idl_node_cmp), (g_idl_node_can_have_member),
3831 (g_idl_node_add_member), (g_idl_node_param_direction_string),
3832 (parse_int_value), (parse_uint_value), (parse_float_value),
3833 (parse_boolean_value), (find_entry_node), (find_entry),
3834 (serialize_type), (g_idl_node_build_metadata), (write_string):
3836 * tools/gidlparser.c (parse_type_internal):
3837 * tools/quote-file.sh:
3838 Revert revisions 157,149-148,136-129 and 120.
3839 Move back to using g-idl-generate to generate the metadata and
3840 avoids dependency on a c compiler.
3842 2008-04-22 Johan Dahlin <jdahlin@async.com.br>
3844 * giscanner/girwriter.py:
3845 * tools/g-ir-scanner:
3846 Add an initial GIR writer and a --format option to g-ir-scanner
3848 2008-04-21 Johan Dahlin <johan@gnome.org>
3850 * giscanner/cgobject.py: Use ctypes.util.find_library to locate
3851 gobject-2.0 and raise ImportError if not found.
3853 * giscanner/gidlparser.py:
3854 * giscanner/gidlwriter.py:
3855 * giscanner/gobjecttreebuilder.py:
3856 * tools/g-ir-scanner:
3857 Add a --include argument to include types from other idls.
3858 Add a minimalistic GIDL parser (just objects for now)
3859 Implement resolving of external type references and use it to
3860 resolve parent types, argument types and return types.
3862 2008-04-21 Johan Dahlin <johan@gnome.org>
3864 * giscanner/gidlwriter.py:
3865 * giscanner/gobjecttreebuilder.py:
3866 * giscanner/treebuilder.py:
3867 Add support for properties.
3868 Refactor Class/Interface support a bit, to share more code and
3869 always initialize their method attribute to an empty list.
3871 2008-04-21 Johan Dahlin <johan@gnome.org>
3873 * giscanner/cgobject.py:
3874 Add a workaround for a glib bug interface introspection bug
3875 (object_interface_list_properties, object_class_list_properties):
3876 Cast the return value to GParamSpec.
3878 * tests/parser/Foo-expected.gidl: Update
3879 * tests/parser/foo.c: Add a string property
3881 * giscanner/gobjecttreebuilder.py:
3882 After stripping namespaces, remove the original
3883 item to avoid duplication (GtkButton struct and Button object)
3885 2008-04-21 Johan Dahlin <johan@gnome.org>
3887 * giscanner/gobjecttreebuilder.py:
3888 * giscanner/treebuilder.py:
3889 Strip namespaces before objects, so we'll export
3890 GtkButton as Button in the gtk namespace
3892 2008-04-21 Johan Dahlin <johan@gnome.org>
3894 * giscanner/gidlwriter.py:
3895 * giscanner/gobjecttreebuilder.py:
3896 * giscanner/treebuilder.py:
3897 Add constructors for object/boxed types.
3899 2008-04-21 Johan Dahlin <johan@gnome.org>
3901 * giscanner/gidlwriter.py:
3902 * giscanner/gobjecttreebuilder.py:
3903 Add support for boxed types
3905 2008-04-21 Johan Dahlin <johan@gnome.org>
3907 * giscanner/giscannermodule.c: Mark structures as const,
3908 wrap SourceType.const_string.
3910 * tests/parser/foo-object.h: Add a couple of constants.
3912 * giscanner/gidlwriter.py:
3913 * giscanner/gobjecttreebuilder.py:
3914 * giscanner/treebuilder.py:
3915 Add basic support for interfaces
3917 * tools/g-ir-scanner:
3918 Add -o/--output for writing to a file
3920 2008-04-21 Havoc Pennington <hp@redhat.com>
3922 * TODO: add some C API wishlist items I could think of quickly
3924 2008-04-21 Johan Dahlin <jdahlin@async.com.br>
3926 * giscanner/gidlwriter.py:
3927 * giscanner/xmlwriter.py:
3928 Add a simple api for writing tags which can be used
3929 with the new 'with statement' in python 2.5
3931 2008-04-21 Johan Dahlin <johan@gnome.org>
3933 * giscanner/gobjecttreebuilder.py:
3934 Strip namespace and object prefix from method names.
3936 2008-04-21 Johan Dahlin <johan@gnome.org>
3938 * tools/g-ir-scanner (main): Add --pkg option to pass in
3939 pkg-config modules to get cflags from.
3941 * giscanner/gidlwriter.py (GIDLWriter._write_method):
3942 Avoid duplication, reuse function writer for methods.
3944 2008-04-21 Johan Dahlin <jdahlin@async.com.br>
3946 * giscanner/gidlwriter.py:
3947 * giscanner/gobjecttreebuilder.py:
3948 * giscanner/treebuilder.py:
3949 * tools/g-ir-scanner:
3950 Resolve libtool .la files.
3951 Strip name spaces for methods.
3952 Add function symbols
3954 2008-04-20 Johan Dahlin <jdahlin@async.com.br>
3956 * giscanner/cgobject.py:
3957 * giscanner/gidlwriter.py:
3958 * giscanner/gobjecttreebuilder.py:
3959 * giscanner/treebuilder.py:
3960 Add support for classes and methods
3962 2008-04-20 Johan Dahlin <johan@gnome.org>
3964 * giscanner/gidlwriter.py:
3965 * giscanner/gobjecttreebuilder.py:
3966 * giscanner/odict.py:
3967 Avoid conflicts, keep the output ordered similar to
3968 the order of the input.
3969 Add a simple ordered dictionary implemenation
3971 2008-04-19 Johan Dahlin <johan@gnome.org>
3973 * giscanner/cgobject.py:
3974 * giscanner/gidlwriter.py:
3975 * giscanner/gobjecttreebuilder.py:
3976 * tools/g-ir-scanner:
3977 Start introspecting get-type functions.
3978 Implement support for GLib/GFlags GTypes.
3979 Add a ctype based GObject binding.
3981 2008-04-18 Johan Dahlin <jdahlin@async.com.br>
3983 * giscanner/gidlwriter.py:
3984 * giscanner/xmlwriter.py:
3985 * tools/g-ir-scanner:
3986 Add a simplistic gidl writer, which can't do too much.
3988 2008-04-18 Johan Dahlin <johan@gnome.org>
3990 * giscanner/sourcescanner.py:
3991 * giscanner/treebuilder.py:
3992 * tools/g-ir-scanner:
3993 split tree building and source scanning interface to separate files.
3995 2008-04-18 Johan Dahlin <johan@gnome.org>
3997 * tools/g-ir-scanner (Parameter.__init__): Start constructing
3999 - Add support for struct/parameter/return, start parsing of ctypes
4001 * giscanner/giscannermodule.c: wrap GISourceType.child_list and
4004 2008-03-31 Johan Dahlin <johan@gnome.org>
4006 * tools/g-ir-scanner:
4007 Start to build abstract syntax node of scanned sources.
4008 Add support for cpp options.
4010 2008-03-27 Johan Dahlin <johan@gnome.org>
4012 * giscanner/giscannermodule.c:
4013 * giscanner/scannerlexer.l:
4014 * giscanner/sourcescanner.c:
4015 * tools/g-ir-scanner:
4017 Add simple pre-processor using subprocess and a PIPE.
4018 Change the parse_file apis to accept a file descriptor.
4020 2008-03-25 Johan Dahlin <johan@gnome.org>
4022 * giscanner/__init__.py:
4023 * tools/g-ir-scanner:
4024 Fix a typo and add an example python test program.
4026 2008-03-25 Johan Dahlin <johan@gnome.org>
4028 * giscanner/__init__.py:
4029 * giscanner/giscannermodule.c:
4030 * giscanner/sourcescanner.c:
4031 * giscanner/sourcescanner.h:
4032 Add constants and wrap a few more SymbolType fields
4034 2008-03-25 Johan Dahlin <johan@gnome.org>
4038 * giscanner/__init__.py:
4039 * giscanner/giscannermodule.c:
4040 * giscanner/Makefile.am:
4042 Add initial python bindings for the scanner and
4043 depend on python 2.5.
4045 2008-03-25 Johan Dahlin <johan@gnome.org>
4049 * giscanner/Makefile.am:
4050 * giscanner/sourcescanner.c:
4051 * giscanner/sourcescanner.h:
4052 * tools/Makefile.am:
4053 * tools/grealpath.h:
4054 * tools/sourcescanner.c:
4055 * tools/sourcescanner.h:
4057 Move the scanner to a separate library.
4059 2008-03-23 Johan Dahlin <johan@gnome.org>
4061 * tools/Makefile.am:
4064 * tools/scannerlexer.l:
4065 * tools/scannerparser.y:
4066 * tools/sourcescanner.c:
4067 * tools/sourcescanner.h:
4068 Split out the source scanner from the generator.
4069 Rename the symbols used in the scanner to use the gi_ prefix.
4070 This should make it possible to use the raw C parser from
4073 2008-03-23 Johan Dahlin <johan@gnome.org>
4075 * tests/parser/Makefile.am (utility.gidl):
4076 * tests/parser/utility-expected.gidl:
4077 Pass in the gobject.gidl since we're defining a GObject.
4079 2008-03-12 Johan Dahlin <johan@gnome.org>
4081 * relaxng/relaxng.rng:
4082 Add a releaxng in relaxng we can use to validate the relaxngs
4085 2008-03-12 Jürg Billeter <j@bitron.ch>
4087 * tools/scanner.c: (g_igenerator_new):
4088 * tools/scannerparser.y:
4089 Fix compiler warnings.
4091 2008-03-12 Jürg Billeter <j@bitron.ch>
4095 * tools/scannerparser.y:
4096 Start fixing memory management in g-idl-scanner.
4098 2008-03-12 Rob Taylor <rob.taylor@codethink.co.uk>
4100 * tools/gidlcompilercontext.c: (write_compiled):
4101 Fix critical warning when no shlib passed to g-idl-compiler.
4103 2008-03-12 Johan Dahlin <johan@gnome.org>
4105 * tests/parser/utility-expected.gidl:
4106 * tests/parser/utility.h:
4107 Add a get_type-function, so the scanner actually
4108 parses it as an object.
4110 2008-03-12 Johan Dahlin <johan@gnome.org>
4112 * tools/gidlwriter.c (function_generate): Add missing trailing quote.
4115 * tests/parser/Foo-expected.gidl:
4116 * tests/parser/Makefile.am:
4117 * tests/parser/foo-object.h:
4118 * tests/parser/foo.c:
4119 * tests/parser/utility-expected.gidl:
4120 * tests/parser/utility.c:
4121 * tests/parser/utility.h:
4123 Add a new gidl test. 'utility.gidl', which is used to be able
4124 to test external type references. Add a reference to UtilityObject*
4127 2008-03-11 Johan Dahlin <johan@gnome.org>
4131 Remove most global variables
4133 2008-03-11 Philip Van Hoof <me@pvanhoof.be>
4135 * tools/scannerlexer.l:
4137 * tests/parser/Foo-expected.gidl:
4138 * tests/parser/foo.c:
4139 * tests/parser/Makefile.am:
4140 * tests/parser/foo-object.h:
4142 Added a few extra tests. Which resulted in finding a few
4143 bugs. Which resulted in me fixing those bugs
4145 2008-03-11 Rob Taylor <rob.taylor@codethink.co.uk>
4147 * tools/gidlcompilercontext.c: (g_idl_compiler_write_dir_entry),
4148 (g_idl_compiler_write_xref_entry), (g_idl_compiler_add_xref):
4149 Add some comments for strings into generated output for
4152 2008-03-11 Rob Taylor <rob.taylor@codethink.co.uk>
4154 * tools/gidlcompilercontext.c: (write_compiled):
4155 Write out the shlibs variable before writing out the strings
4156 length. Fixes compiler warning when using '-l' flag with
4159 2008-03-11 Johan Dahlin <johan@gnome.org>
4161 * tests/parser/Foo-expected.gidl:
4162 * tests/parser/foo-object.h:
4165 * tools/scannerlexer.l:
4166 Add support for parsing return arguments. Add support for
4167 caller-owns return types.
4168 Patch by Philip Van Hoof.
4170 * tools/scannerparser.y:
4171 Remove parsing of the @deprecated syntax used in headers.
4172 We will support gtk-doc deprecation in the future instead.
4174 2008-03-11 Johan Dahlin <johan@gnome.org>
4176 * tools/compiler.c (main): Coding style fixes
4178 2008-03-10 Johan Dahlin <johan@gnome.org>
4181 Add GCOV_LIBS to GILIBS
4183 2008-03-10 Johan Dahlin <johan@gnome.org>
4185 * tests/parser/Foo-expected.gidl:
4186 * tests/parser/foo.c:
4187 Rename null-ok to direction=out
4189 2008-03-10 Philip Van Hoof <me@pvanhoof.be>
4191 reviewed and extensively tested by Johan
4193 * tests/parser/Foo-expected.gidl:
4194 * tests/parser/foo-object.h:
4195 * tests/parser/foo.c:
4198 * tools/gidlwriter.c:
4201 * tools/scannerlexer.l:
4202 * tools/scannerparser.y:
4204 Add support for scanning for gtk-doc comments inside
4205 C source files. Add tests
4207 2008-03-10 Johan Dahlin <johan@gnome.org>
4209 * tests/parser/Makefile.am:
4210 * tests/parser/foo.c:
4213 * tools/scannerparser.y:
4214 Add an api to lex filenames.
4215 Lex all source .c files passed in on the command line.
4216 Scan sources in a test and a couple of private structures
4217 which should not be included in the generated gidl
4219 2008-03-10 Johan Dahlin <johan@gnome.org>
4221 * tests/invoke/Makefile.am: Make the generated metadata
4222 depend on the g-idl-compiler
4224 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4226 * tools/gidlmodule.c
4227 * tools/gidlmodule.h
4230 Remove the old g-idl-compiler code.
4233 2008-02-22 Mark Doffman <mark.doffman@codethink.co.uk>
4235 * tools/quote-file.sh
4238 Move to using the 'C' struct compiler code.
4240 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4242 * girepository/ginfo.c
4244 Change the way that external references with no namespace
4245 are dealt with. External references with no namespace
4246 are placed into the XML as-if they are a local reference.
4247 This is temporary, but helps with roundtrip tests.
4249 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4251 * girepository/ginfo.c
4252 Add the ability to get the value of a constant of
4253 type TYPE_TAG_SYMBOL. In the case of a symbol the value
4254 is provided as a string.
4256 This would deal properly with:
4257 typedef char* random;
4258 const random = "A string";
4260 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4262 * girepository/ginfo.c
4263 * girepository/girepository.h
4265 Add a function to check if an enum is registered or not.
4266 Previously anything testing this relied on the g-type
4267 string offset having a value of 0.
4269 * girepository/gmetadata.c
4270 * girepository/gmetadata.h
4272 Remove unneccesary or erroneous checks. There were two
4273 metadata validation checks which made sure that the blob
4274 sizes were the same as some magic numbers compiled into the code.
4275 This is wrong as it breaks any forwards compatibility that may
4278 Checks were also present that made sure that unregistered type
4279 blobs had a value of 0 in the g-type offset field. This is
4280 unneccessary. If a type blob is unregistered then any value
4281 in its g-type field is simply invalid.
4283 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4285 * girepository/ginfo.c
4286 * girepository/gmetadata.c
4287 * girepository/gmetadata.h
4289 Change the metadata format to have a standard header
4290 for all the type blobs. Merge the SimpleTypeBlob
4291 and InterfaceTypeBlob into a union. A union of these
4292 two blobs existed previously but was not explicit
4293 in the metadata format.
4295 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4297 * tools/gidlcompilercontext.c
4298 * tools/gidlcompilercontext.h
4299 * tools/gidlcompilerentrynode.c
4300 * tools/gidlcompilerentrynode.h
4301 * tools/gidlcompilertypenode.c
4302 * tools/gidlcompilertypenode.h
4304 Add code to compile a tree of GIdlNodes to
4305 a 'C' struct representing the metadata.
4306 This is to aid cross-compiling. Previously
4307 the g-idl-compiler created a binary blob with
4308 data written in the byte order and alignment
4309 of the tool rather than the intended target.
4311 Cleaned up and improved by Johan and Robert :-)
4313 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4315 * girepository/ginvoke.c
4316 * girepository/girepository.h
4317 * girepository/gmetadata.c
4318 * girepository/gmetadata.h
4320 * tools/gidlparser.c
4321 Modify TYPE_TAG_INTERFACE to TYPE_TAG_SYMBOL
4322 to avoid confusion with the interface blob.
4325 * tools/gidlparser.c
4326 Remove magic numbers and replace with type-tag
4327 enumeration symbols.
4329 * girepository/gmetadata.c
4330 Add validate declaration.
4332 2008-03-10 Jürg Billeter <j@bitron.ch>
4334 * tools/gidlparser.c: (parse_type_internal):
4335 * tools/scannerlexer.l:
4336 * tools/scannerparser.y:
4337 Support C99 _Bool type in scanner.
4339 2008-03-10 Jürg Billeter <j@bitron.ch>
4341 * tests/parser/Foo-expected.gidl:
4342 * tests/parser/foo-object.h:
4343 * tests/parser/foo.c: (foo_enum_method):
4344 * tools/scanner.c: (g_igenerator_process_function_symbol):
4345 Don't skip functions that are defined in the namespace of a type
4346 that doesn't support methods, as for example enums.
4348 2008-03-10 Johan Dahlin <johan@gnome.org>
4350 * gidl.dtd: Remove, we're using relaxng for now
4352 * tests/parser/Foo-expected.gidl:
4353 * tests/parser/foo-object.h:
4354 * tests/parser/foo.c:
4355 Rename the enum/flags get_type functions to include the whole type.
4357 2008-03-08 Marc-Andre Lureau <marcandre.lureau@gmail.com>
4359 * tools/gidlwriter.c (enum_generate): added "type-name",
4360 "get-type" and "deprecated" missing arguments.
4361 * tests/parser/Foo-expected.gidl:
4362 * tests/parser/foo-object.h: test enum type, and no type.
4364 2008-03-06 Johan Dahlin <jdahlin@async.com.br>
4367 Consistent checks, add missing 'test'
4369 2008-03-05 Havoc Pennington <hp@redhat.com>
4371 * configure.ac: Take advantage of a libffi.pc if one exists, as it
4372 does on Fedora 8. Make libffi a hard requirement, since it was in
4373 practice anyway (was not really conditional in the code or
4374 makefile, only in configure).
4376 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4378 reviewed by: Rob Taylor <rob.taylor@codethink.co.uk>
4379 reviewed by: Johan Dahlin <johan@gnome.org>
4381 * tests/Makefile.am:
4382 * tests/roundtrips.sh:
4383 Modify the roundtrips test so that they do not use the
4384 --raw option of the gidl compiler but instead compile a
4385 shared library to use with g_module.
4387 * tests/invoke/Makefile.am:
4388 * tests/invoke/invoke.c:
4389 Modify the invoke tests to build a shared library rather
4390 than use the --raw option.
4392 * tests/invoke/invoke-namespace-find.sh: Removed:
4393 Noone knows why this was here, so removed.
4395 2008-02-19 Rob Taylor <rob.taylor@codethink.co.uk>
4397 * tools/scanner.c: (g_igenerator_process_function_symbol):
4398 Move g_idl_node_can_have_member test later, as it broke spotting
4399 get_type's for nodes that can't have members.
4401 2008-02-18 Rob Taylor <rob.taylor@codethink.co.uk>
4404 * tools/gidlnode.c: (g_idl_node_can_have_member):
4405 Add g_idl_node_can_have_member.
4407 * tools/scanner.c: (g_igenerator_process_function_symbol):
4408 Use g_idl_node_can_have_member to test if we should add a function
4409 as a member of the type node.
4411 2008-02-18 Rob Taylor <rob.taylor@codethink.co.uk>
4413 * gidl/GLib.gidl: Renamed to gidl/gobject-2.0.gidl:
4415 * tests/parser/Makefile.am:
4416 Rename GLib.gidl to gobject-2.0.gidl and install in /usr/share/gidl.
4418 2008-02-18 Rob Taylor <rob.taylor@codethink.co.uk>
4420 * tools/scanner.c: (main):
4421 Ignore -pthread when passed to g-idl-scanner.
4423 2008-02-18 Rob Taylor <rob.taylor@codethink.co.uk>
4425 * tools/grealpath.h: Added:
4426 * tools/scanner.c: (main):
4427 * tools/scannerlexer.l:
4428 * tools/Makefile.am:
4429 Always use absolute paths with symbolic links resolved when
4430 comparing filenames.
4432 2008-02-18 Rob Taylor <rob.taylor@codethink.co.uk>
4434 * gobject-introspection.pc.in:
4435 Provide variables for g-idl-parser, scanner and compiler in the
4438 2008-02-13 Rob Taylor <rob.taylor@codethink.co.uk>
4441 * girepository/Makefile.am:
4442 * tools/Makefile.am:
4443 Rename GCOV_SOURCES to GCOVSOURCES to top automake complaining.
4445 2008-02-10 Johan Dahlin <johan@gnome.org>
4447 * tests/parser/Foo-expected.gidl:
4448 * tests/parser/foo-object.h:
4449 * tests/parser/foo.c: (foo_boxed_copy), (foo_boxed_free),
4450 (foo_boxed_get_type), (foo_boxed_new), (foo_boxed_method):
4453 2008-02-10 Johan Dahlin <johan@gnome.org>
4455 * tests/parser/Foo-expected.gidl:
4456 * tests/parser/foo-object.h:
4457 * tests/parser/foo.c: (foo_enum_get_type), (foo_flags_get_type):
4458 Add enum and flags test.
4460 2008-02-10 Johan Dahlin <johan@gnome.org>
4464 * girepository/Makefile.am:
4465 Make 'make distcheck' work again.
4467 2008-02-10 Johan Dahlin <johan@gnome.org>
4469 * m4/Makefile.am (EXTRA_DIST): its called as-compiler-flag.m4,
4472 * tests/parser/Makefile.am: Only create Foo.gidl when running make
4473 check, eg exclude it from BUILT_SOURCES.
4475 2008-02-08 Rob Taylor <rob.taylor@codethink.co.uk>
4480 * girepository/Makefile.am:
4481 * m4/Makefile.am: Added:
4482 * m4/as-compiler-flag.m4: Added:
4483 * m4/gcov.m4: Added:
4484 * tools/Makefile.am:
4485 Add ability to generate a coverage report.
4486 Adds configure option --enable-gcov and make rule 'check-coverage'.
4488 2008-02-08 Rob Taylor <rob.taylor@codethink.co.uk>
4492 * gidl/Makefile.am: Added:
4493 * girepository/Makefile.am: Added:
4494 * src/Makefile.am: Renamed to tools/Makefile.am:
4495 * src/compiler.c: Renamed to tools/compiler.c:
4496 * src/g-idl-offsets.pl: Renamed to tools/g-idl-offsets.pl:
4497 * src/generate.c: Renamed to tools/generate.c:
4498 * src/gidlmodule.c: Renamed to tools/gidlmodule.c:
4499 * src/gidlmodule.h: Renamed to tools/gidlmodule.h:
4500 * src/gidlnode.c: Renamed to tools/gidlnode.c:
4501 * src/gidlnode.h: Renamed to tools/gidlnode.h:
4502 * src/gidlparser.c: Renamed to tools/gidlparser.c:
4503 * src/gidlparser.h: Renamed to tools/gidlparser.h:
4504 * src/gidlwriter.c: Renamed to tools/gidlwriter.c:
4505 * src/gidlwriter.h: Renamed to tools/gidlwriter.h:
4506 * src/ginfo.c: Renamed to girepository/ginfo.c:
4507 * src/ginvoke.c: Renamed to girepository/ginvoke.c:
4508 * src/girepository.c: Renamed to girepository/girepository.c:
4509 * src/girepository.h: Renamed to girepository/girepository.h:
4510 * src/gmetadata.c: Renamed to girepository/gmetadata.c:
4511 * src/gmetadata.h: Renamed to girepository/gmetadata.h:
4512 * src/scanner.c: Renamed to tools/scanner.c:
4513 * src/scanner.h: Renamed to tools/scanner.h:
4514 * src/scannerlexer.l: Renamed to tools/scannerlexer.l:
4515 * src/scannerparser.y: Renamed to tools/scannerparser.y:
4516 * tests/invoke/Makefile.am:
4517 Split src/ into girepository/ and tools/
4521 * girepository/Makefile.am:
4522 * tests/Makefile.am:
4523 * tests/invoke/Makefile.am:
4524 * tests/parser/Makefile.am:
4525 * tests/roundtrips.sh:
4526 * tools/Makefile.am:
4527 Make distcheck work.
4529 2008-02-04 Rob Taylor <rob.taylor@codethink.co.uk>
4531 * tests/invoke/invoke.c: (main):
4532 * tests/invoke/testfns.c: (test6), (test7):
4533 * tests/invoke/testfns.xml:
4534 Add tests for invokation with a GList argument.
4535 Also tests caller-owns return values.
4537 2008-02-04 Rob Taylor <robtaylor@floopily.org>
4540 Add some documentation for GICallableInfo
4542 2008-02-01 Mark Doffman <mark.doffman@codethink.co.uk>
4545 Correct syntax errors in the DTD file.
4547 * relaxng/c-types.xml:
4548 * relaxng/g-types.xml:
4550 Add a RelaxNG specification for the GObject Introspection XML data.
4551 The Specification has validated all of the test files.
4553 2008-01-25 Rob Taylor <robtaylor@floopily.org>
4555 * tests/roundtrips.sh:
4556 * tests/struct.test:
4557 Add roundtrip tests for structs.
4559 2008-01-11 Johan Dahlin <johan@gnome.org>
4561 * src/scanner.c (g_igenerator_process_function_symbol):
4562 Refactor out g_idle_node_add_member.
4563 (create_node_from_gtype, create_node_from_ctype):
4564 Use case instead of if...else
4565 (get_type_from_type_id):
4566 Rename to create_node_from_gtype
4567 (get_type_from_ctype):
4568 Rename to create_node_from_ctype
4570 Rename ginode -> node, gitype -> type, gifunc -> func.
4572 * src/gidlnode.c (g_idl_node_add_member, g_idl_node_cmp):
4573 Two new functions, refactor out of scanner.c
4575 * src/scanner.c: (g_igenerator_process_function_symbol):
4576 * src/scannerlexer.l:
4577 Do not save the content of the deprecated variable, only
4580 2008-01-11 Johan Dahlin <johan@gnome.org>
4582 * tests/parser/foo-object.h: Add a couple of comment parser tests.
4584 2008-01-11 Jürg Billeter <j@bitron.ch>
4586 * src/scannerlexer.l:
4587 Fix GTK-Doc parsing.
4589 2008-01-11 Jürg Billeter <j@bitron.ch>
4591 * src/scannerlexer.l:
4592 Fix GTK-Doc parsing.
4594 2008-01-11 Jürg Billeter <j@bitron.ch>
4596 * src/scanner.c: (lookup_symbol):
4597 Return unresolved name if we find unknown symbol.
4599 2008-01-11 Jürg Billeter <j@bitron.ch>
4601 * src/scanner.c: (g_igenerator_generate):
4602 Initialize GObject to fix scanning interface properties.
4604 * tests/parser/Foo-expected.gidl:
4605 * tests/parser/foo-object.h:
4606 * tests/parser/foo.c: (foo_interface_get_type):
4607 Test interfaces with GObject prerequisite.
4609 * tests/parser/Makefile.am:
4610 Set G_DEBUG=fatal_warnings to abort test on warnings and criticals.
4612 2007-12-27 Johan Dahlin <johan@gnome.org>
4614 * src/scannerlexer.l:
4615 Parse gtk-doc comments.
4617 * src/gidlwriter.c: (function_generate):
4618 Reorganize, avoid duplication and add support for
4619 writing deprecated functions.
4621 * src/scannerparser.y:
4623 Add new structure CDirective and functions to create/free them.
4625 * src/scanner.c: (g_igenerator_process_function_symbol),
4626 (g_igenerator_process_unregistered_struct_typedef),
4627 (g_igenerator_process_struct_typedef),
4628 (g_igenerator_process_union_typedef),
4629 (g_igenerator_process_enum_typedef),
4630 (g_igenerator_process_function_typedef), (g_igenerator_add_symbol),
4631 (g_igenerator_start_preprocessor):
4632 Parse @deprecated directive for functions.
4633 Remove some more C99isms.
4634 Send in -C to cpp to avoid stripping comments.
4636 * tests/parser/foo-object.h:
4637 * tests/parser/Foo-expected.gidl:
4638 Add deprecated directive
4640 2007-12-27 Johan Dahlin <johan@gnome.org>
4642 * src/scannerlexer.l (intsuffix): Add emacs mode line and
4643 escape ' and " so it looks more like C.
4646 Unlink temporary file used.
4648 2007-12-27 Johan Dahlin <johan@gnome.org>
4650 * src/scanner.c: (g_igenerator_new), (g_igenerator_free),
4651 (g_igenerator_start_preprocessor), (main):
4653 * src/scannerparser.y:
4654 Plug a couple of simple memory leaks.
4656 2007-12-27 Johan Dahlin <johan@gnome.org>
4658 * src/scanner.c: (g_igenerator_parse_macros),
4659 (g_igenerator_start_preprocessor), (g_igenerator_set_verbose),
4662 * src/scannerparser.y:
4663 * tests/parser/Makefile.am:
4665 Improve error reporting, return when the preprocessor fails.
4666 Add a verbose parameter, to aid debugging.
4667 Revert to using a temporary file to communicate between the
4668 preprocessor and the parser, because we need to wait for
4669 the exit code from the pre-processor before starting to parse.
4671 2007-12-16 Johan Dahlin <jdahlin@async.com.br>
4673 * src/Makefile.am: Rename clexer.l to scannerlexer.l and
4674 cparser.y to scannerparser.y
4676 2007-12-11 Johan Dahlin <johan@gnome.org>
4680 * src/scanner.c: (g_igenerator_new):
4682 Get rid of the global the_generator variable.
4684 2007-12-10 Johan Dahlin <johan@gnome.org>
4686 * src/scanner.c (main): Add an output option,
4687 add checks for required parameters
4690 set BUILD_SOURCES and CLEANFILES properly
4692 * src/gidlwriter.c: (g_writer_write_inline), (g_writer_write),
4693 (g_writer_write_indent), (g_writer_write_unindent),
4694 (field_generate), (value_generate), (constant_generate),
4695 (property_generate), (function_generate), (vfunc_generate),
4696 (signal_generate), (interface_generate), (struct_generate),
4697 (union_generate), (boxed_generate), (enum_generate),
4698 (node_generate), (g_writer_write_module), (g_idl_writer_save_file):
4700 * src/scanner.c: (g_igenerator_generate):
4702 * src/scannerwriter.c:
4704 Refactor scannerwriter to only be tied to a GIdlModule and move
4705 it (again!) to gidlwriter.c. Change the writer function to take
4708 2007-12-10 Johan Dahlin <johan@gnome.org>
4711 * src/scanner.c: (g_igenerator_generate):
4713 * src/scannerwriter.c: (g_igenerator_write_inline),
4714 (g_igenerator_write), (g_igenerator_write_indent),
4715 (g_igenerator_write_unindent), (field_generate), (value_generate),
4716 (constant_generate), (property_generate), (function_generate),
4717 (vfunc_generate), (signal_generate), (interface_generate),
4718 (struct_generate), (union_generate), (boxed_generate),
4719 (enum_generate), (node_generate), (module_generate),
4720 (g_scanner_write_file):
4722 Move the scanner gidl writing to a separate source file.
4724 2007-12-10 Johan Dahlin <johan@gnome.org>
4729 Move over all CType construction functions.
4731 * tests/parser/Makefile.am:
4732 Be verbose when printing parsing tests results.
4734 2007-12-10 Johan Dahlin <johan@gnome.org>
4736 * src/scanner.c (g_igenerator_start_preprocessor): Refactor
4737 preprocessor handling to here. Start cpp insteado of cc -E,
4738 always include -U__GNUC__, since it's specific to the preprocessor
4741 * tests/parser/Makefile.am (check-local): Silent diff and skip
4742 -U__GNUC__ which is always defined now
4744 2007-12-10 Johan Dahlin,,, <jdahlin@plasttroll>
4746 reviewed by: <delete if not using a buddy>
4748 * src/scanner.c: (g_igenerator_start_preprocessor), (main):
4749 * tests/parser/Makefile.am:
4751 2007-12-09 Johan Dahlin <johan@gnome.org>
4754 Use GOption for command line options.
4755 (g_igenerator_new, main): Simplify constructor and they way
4756 parameters are passed into it.
4762 * src/gen-introspect.c:
4763 * src/gen-introspect.h:
4765 Rename gen-introspect.[ch] to scanner.[ch]
4767 2007-12-09 Johan Dahlin <johan@gnome.org>
4771 * src/Makefile.am: Rename gen-introspect to g-idl-scanner,
4772 don't make the repository library and the other utilites link against
4775 * src/gen-introspect.c: (g_igenerator_create_object),
4776 (g_igenerator_create_interface), (g_igenerator_create_boxed),
4777 (g_igenerator_create_enum), (g_igenerator_create_flags),
4778 (g_igenerator_process_module_symbol),
4779 (g_igenerator_process_module), (g_igenerator_generate), (main):
4780 * src/gen-introspect.h:
4781 Refactor g_igenerator_process_types into smaller pieces.
4783 * tests/parser/Makefile.am:
4784 Depend on the gen-introspect binary
4786 2007-12-09 Johan Dahlin <johan@gnome.org>
4788 * src/gen-introspect.c (g_igenerator_process_types):
4789 Break into smaller pieces, one for each generated node type.
4791 2007-12-08 Johan Dahlin <johan@gnome.org>
4793 * src/gen-introspect.c: (g_igenerator_process_types),
4794 (g_igenerator_add_module):
4795 * tests/parser/Foo-expected.gidl:
4796 * tests/parser/foo-object.h:
4797 * tests/parser/foo.c: (foo_subobject_class_init),
4798 (foo_subobject_init):
4800 Add a subobject test and make sure to register defined classes
4801 in the lookup symbol hash table.
4803 2007-12-08 Johan Dahlin <johan@gnome.org>
4807 * src/gen-introspect.c: (g_igenerator_new), (lookup_symbol),
4808 (g_igenerator_process_types), (g_igenerator_add_module),
4809 (g_igenerator_add_include_idl), (main):
4810 * src/gen-introspect.h:
4811 * tests/parser/Makefile.am:
4812 * tests/parser/Foo-expected.gidl:
4814 Change the gen-introspect to generate namespaced module names,
4815 such as GLib.Object instead of GObject.
4816 Add a GLib.gidl which introduces GLib.Object and GLib.InitiallyUnowned,
4817 add a --include-idl parameter to gen-introspect,
4818 and update the parser test.
4820 2007-12-08 Johan Dahlin <johan@gnome.org>
4822 * src/gen-introspect.c:
4823 Move main to the end of the file and attempt to make it valid
4826 * tests/parser/Makefile.am (BUILT_SOURCES): Remove .repo here,
4827 we're not quite ready to generate metadata yet.
4832 Add a simple gen-introspect parser test
4834 2007-12-06 Gustavo J. A. M. Carneiro <gjc@gnome.org>
4836 reviewed by: Johan Dahlin <johan@gnome.org>
4839 * gobject-introspection.pc.in:
4841 * src/compiler.c: (format_output), (write_out_metadata), (main):
4842 * src/gen-introspect.c: (main):
4843 * src/gen-introspect.h:
4844 * src/generate.c: (write_callable_info), (write_repository),
4845 (load_metadata), (main):
4846 * src/gidlmodule.c: (g_idl_module_new),
4847 (g_idl_module_build_metadata):
4849 * src/gidlparser.c: (start_element_handler):
4850 * src/ginfo.c: (g_info_new), (g_info_from_entry),
4851 (g_base_info_get_name), (g_base_info_get_namespace),
4852 (g_base_info_is_deprecated), (g_base_info_get_annotation),
4853 (g_base_info_get_metadata), (g_function_info_get_symbol),
4854 (g_function_info_get_flags), (g_function_info_get_property),
4855 (g_function_info_get_vfunc), (signature_offset), (g_type_info_new),
4856 (g_callable_info_may_return_null),
4857 (g_callable_info_get_caller_owns), (g_callable_info_get_n_args),
4858 (g_callable_info_get_arg), (g_arg_info_get_direction),
4859 (g_arg_info_is_return_value), (g_arg_info_is_dipper),
4860 (g_arg_info_is_optional), (g_arg_info_may_be_null),
4861 (g_arg_info_get_ownership_transfer), (g_type_info_is_pointer),
4862 (g_type_info_get_tag), (g_type_info_get_param_type),
4863 (g_type_info_get_interface), (g_type_info_get_array_length),
4864 (g_type_info_is_zero_terminated),
4865 (g_type_info_get_n_error_domains), (g_type_info_get_error_domain),
4866 (g_error_domain_info_get_quark), (g_error_domain_info_get_codes),
4867 (g_value_info_get_value), (g_field_info_get_flags),
4868 (g_field_info_get_size), (g_field_info_get_offset),
4869 (g_registered_type_info_get_type_name),
4870 (g_registered_type_info_get_type_init),
4871 (g_struct_info_get_n_fields), (g_struct_info_get_field),
4872 (g_struct_info_get_n_methods), (g_struct_info_get_method),
4873 (find_method), (g_struct_info_find_method),
4874 (g_enum_info_get_n_values), (g_enum_info_get_value),
4875 (g_object_info_get_parent), (g_object_info_get_type_name),
4876 (g_object_info_get_type_init), (g_object_info_get_n_interfaces),
4877 (g_object_info_get_interface), (g_object_info_get_n_fields),
4878 (g_object_info_get_field), (g_object_info_get_n_properties),
4879 (g_object_info_get_property), (g_object_info_get_n_methods),
4880 (g_object_info_get_method), (g_object_info_find_method),
4881 (g_object_info_get_n_signals), (g_object_info_get_signal),
4882 (g_object_info_get_n_vfuncs), (g_object_info_get_vfunc),
4883 (g_object_info_get_n_constants), (g_object_info_get_constant),
4884 (g_interface_info_get_n_prerequisites),
4885 (g_interface_info_get_prerequisite),
4886 (g_interface_info_get_n_properties),
4887 (g_interface_info_get_property), (g_interface_info_get_n_methods),
4888 (g_interface_info_get_method), (g_interface_info_find_method),
4889 (g_interface_info_get_n_signals), (g_interface_info_get_signal),
4890 (g_interface_info_get_n_vfuncs), (g_interface_info_get_vfunc),
4891 (g_interface_info_get_n_constants),
4892 (g_interface_info_get_constant), (g_property_info_get_flags),
4893 (g_signal_info_get_flags), (g_signal_info_get_class_closure),
4894 (g_signal_info_true_stops_emit), (g_vfunc_info_get_flags),
4895 (g_vfunc_info_get_offset), (g_vfunc_info_get_signal),
4896 (g_constant_info_get_value), (g_union_info_get_n_fields),
4897 (g_union_info_get_field), (g_union_info_get_n_methods),
4898 (g_union_info_get_method), (g_union_info_is_discriminated),
4899 (g_union_info_get_discriminator_offset),
4900 (g_union_info_get_discriminator):
4901 * src/ginvoke.c: (g_function_info_invoke):
4902 * src/girepository.c: (g_irepository_register),
4903 (g_irepository_unregister), (g_irepository_get_default),
4904 (count_interfaces), (g_irepository_get_n_infos), (find_interface),
4905 (g_irepository_get_info), (g_irepository_find_by_name),
4906 (g_irepository_get_shared_library),
4907 (g_irepository_build_search_path), (g_irepository_register_file),
4908 (g_irepository_error_quark):
4909 * src/girepository.h:
4910 * src/gmetadata.c: (g_metadata_get_dir_entry),
4911 (g_metadata_check_sanity), (validate_header),
4912 (validate_array_type_blob), (validate_iface_type_blob),
4913 (validate_param_type_blob), (validate_error_type_blob),
4914 (validate_type_blob), (validate_arg_blob),
4915 (validate_signature_blob), (validate_function_blob),
4916 (validate_callback_blob), (validate_constant_blob),
4917 (validate_value_blob), (validate_field_blob),
4918 (validate_property_blob), (validate_signal_blob),
4919 (validate_vfunc_blob), (validate_struct_blob),
4920 (validate_enum_blob), (validate_object_blob),
4921 (validate_interface_blob), (validate_errordomain_blob),
4922 (validate_union_blob), (validate_blob), (validate_directory),
4923 (validate_annotations), (g_metadata_validate), (_g_metadata_init),
4924 (g_metadata_new_from_memory), (g_metadata_new_from_const_memory),
4925 (g_metadata_new_from_mapped_file), (g_metadata_free),
4926 (g_metadata_set_module), (g_metadata_get_namespace):
4928 * tests/Makefile.am:
4929 * tests/invoke/Makefile.am:
4930 * tests/invoke/invoke-namespace-find.sh:
4931 * tests/invoke/invoke.c: (main):
4933 Add a namespace/shared library mapping. fixes #313268.
4935 2007-12-03 Johan Dahlin <johan@gnome.org>
4937 * src/gidlparser.c (parse_type_internal): Disable char/gchar and
4940 2007-11-30 Jürg Billeter <j@bitron.ch>
4946 * src/gen-introspect.c: (g_idl_node_cmp), (g_igenerator_new),
4947 (g_igenerator_write_inline), (g_igenerator_write),
4948 (g_igenerator_write_indent), (g_igenerator_write_unindent),
4949 (field_generate), (value_generate), (constant_generate),
4950 (property_generate), (function_generate), (vfunc_generate),
4951 (signal_generate), (interface_generate), (struct_generate),
4952 (union_generate), (boxed_generate), (enum_generate),
4953 (node_generate), (module_generate), (get_type_from_type_id),
4954 (str_replace), (g_igenerator_process_properties),
4955 (g_igenerator_process_signals), (g_igenerator_process_types),
4956 (get_type_from_ctype), (g_igenerator_process_function_symbol),
4957 (g_igenerator_process_unregistered_struct_typedef),
4958 (g_igenerator_process_struct_typedef),
4959 (g_igenerator_process_union_typedef),
4960 (g_igenerator_process_enum_typedef),
4961 (g_igenerator_process_function_typedef),
4962 (g_igenerator_process_constant), (g_igenerator_process_symbols),
4963 (g_igenerator_add_symbol), (g_igenerator_is_typedef),
4964 (g_igenerator_generate), (main), (csymbol_new),
4965 (csymbol_get_const_boolean), (ctype_new), (ctype_copy),
4966 (cbasic_type_new), (ctypedef_new), (cstruct_new), (cunion_new),
4967 (cenum_new), (cpointer_new), (carray_new), (cfunction_new),
4968 (eat_hspace), (eat_line), (read_identifier),
4969 (g_igenerator_parse_macros):
4970 * src/gen-introspect.h:
4972 Import gen-introspect to generate introspection information by
4975 2007-11-30 Jürg Billeter <j@bitron.ch>
4977 * src/gidlnode.c: (g_idl_node_new): support creating callback nodes
4979 2007-11-30 Jürg Billeter <j@bitron.ch>
4981 * src/gidlparser.c: (end_element_handler): Don't leave requires
4984 2007-11-29 Johan Dahlin <johan@gnome.org>
4986 * src/gidlparser.c (parse_type_internal): Add char,
4987 gchar and guchar to the builtin types.
4989 2007-11-26 Johan Dahlin <johan@gnome.org>
4991 * src/ginfo.c: (g_object_info_get_type_name),
4992 (g_object_info_get_type_init):
4993 * src/girepository.c: (g_irepository_is_registered):
4994 * src/girepository.h:
4996 Add g_object_info_get_type_name, g_object_info_get_type_init and
4997 g_irepository_is_registered.
4999 2006-08-14 Jürg Billeter <j@bitron.ch>
5001 * src/gidlparser.c: (end_element_handler): Don't leave
5002 namespace and implements states too early.
5005 2007-11-26 Johan Dahlin <johan@gnome.org>
5007 * src/gmetadata.c (validate_struct_blob):
5008 pass blob_type to validate_function_blob instead of
5009 hard-coding BLOB_TYPE_STRUCT.
5011 Patch by Torsten Schoenfeld, fixes #314190
5013 2006-10-03 Torsten Schoenfeld <tsch@cvs.gnome.org>
5015 * src/compiler.c, src/generate.c, src/gidlnode.c,
5016 src/gidlparser.c, src/ginfo.c, src/girepository.c,
5017 tests/invoke/invoke.c, test/invoke/testfns.c: Hush compiler
5018 warnings about return values, signedness mismatches, unused
5019 variables, and unhandles enum values in switch statements.
5021 * tests/invoke/Makefile.am: Don't install the invoke test program.
5022 Add -I ../../src to the cflags used for the test functions files.
5024 2005-08-31 Torsten Schoenfeld <tsch@cvs.gnome.org>
5026 * src/girepository.h: Export g_invoke_error_quark.
5028 2005-08-31 Torsten Schoenfeld <tsch@cvs.gnome.org>
5030 * src/ginvoke.c: Remove the fallback implementation of
5031 g_function_info_invoke since we now formally depend on libffi.
5033 2005-07-25 Matthias Clasen <mclasen@redhat.com>
5035 * src/Makefile, tests/Makefile, tests/invoke/Makefile:
5036 Remove these files from cvs, as they are now generated.
5038 * src/gmetadata.c (validate_iface_type_blob): Don't
5039 complain if blob->pointer is not set, since that
5040 happens for enum and flag types. (#308935, Gustavo
5043 * Commit an autoconf-conversion patch by
5044 Gustavo Carneiro (#308708)
5046 2005-05-24 Matthias Clasen <mclasen@redhat.com>
5048 * src/compiler.c (main): Use it here to validate
5049 the generated metadata.
5051 * src/gmetadata.[hc]: Add code to validate a
5054 * metadata-format.txt: Updates
5056 2005-05-22 Matthias Clasen <mclasen@redhat.com>
5058 * tests/*: Add struct offsets to field and vfunc
5061 * src/generate.c (write_vfunc_info): Write offset
5062 information for vfuncs.
5064 * src/gidlnode.c (g_idl_node_build_metadata): Write
5065 the struct offsets into the metadata.
5067 * src/gidlparser.c: Parse the offset attributes of
5068 field and vfunc elements.
5070 * src/gidlnode.h: Add offset members to field and
5073 2005-05-21 Matthias Clasen <mclasen@redhat.com>
5077 * gidl.dtd: Updates.
5079 * src/g-idl-offsets.pl: A perl script which reads a .gidl
5080 file, creates, compiles and runs a C file, and folds the
5081 resulting struct offsets back into the .gidl file.
5083 2005-05-20 Matthias Clasen <mclasen@redhat.com>
5085 * src/gidlparser.c (start_field): Make fields in objects
5088 * src/gidlmodule.c: Include string.h
5093 * metadata-format.txt: Cleanup basic types.
5094 * src/*: Adapt to the changes.
5095 * tests/*: Adapt to the changes.
5096 * examples/gdk-pixbuf.gidl: Adapt to the changes.
5098 * src/gidlnode.c (g_idl_node_get_size): Report the correct
5099 size for enum blobs.
5100 (g_idl_node_get_full_size): Report the correct size for
5103 * src/gidlmodule.c (g_idl_module_build_metadata): Add some
5104 error checking for blob sizes.
5106 2005-05-19 Matthias Clasen <mclasen@redhat.com>
5108 * src/gidlnode.c (g_idl_node_build_metadata): Correctly handle
5109 interface types for which is_pointer is FALSE, e.g. enums.
5111 * src/gidlnode.c (g_idl_node_get_full_size)
5112 * src/gidlparser.c (parse_type_internal):
5113 * src/generate.c (write_type_info): Support unspecialized
5114 lists, hashtables and errors. Also emit a '*' after these.
5118 2005-05-17 Matthias Clasen <mclasen@redhat.com>
5122 * metadata-format.txt: Cleanups by Maciej Katafiasz.
5124 2005-05-15 Matthias Clasen <mclasen@redhat.com>
5126 * src/*.c: Change the directory to be addressed by
5127 1-based indexes, and use an index of zero to mean
5130 2005-05-15 Matthias Clasen <mclasen@redhat.com>
5132 * tests/roundtrips.sh (SIMPLE_TESTS): Add union.test.
5134 * tests/union.test: Add a union test.
5136 * src/generate.c: Handle unions.
5138 * src/girepository.h:
5139 * src/ginfo.c: Add GIUnionInfo and functions to access it.
5141 * src/gidlnode.c: Handle GIdlNodeUnion nodes.
5143 * src/gidlparser.c (start_union): Parse <union> elements.
5145 * src/gidlnode.h: Add a GIdlNodeUnion.
5147 * gidl.dtd: Add a <union> element.
5149 * src/gmetadata.c (g_metadata_check_sanity): Check
5152 * src/gmetadata.h: Add union_blob_size to Header,
5155 * metadata-format.txt: Add a UnionBlob.
5157 2005-05-13 Matthias Clasen <mclasen@redhat.com>
5159 * tests/*: Update testcases.
5161 * src/generate.c (write_callable_info): Don't forget to
5162 write transfer and null-ok attributes for return types
5165 * src/girepository.h:
5166 * src/ginfo.c (g_callable_info_may_return_null):
5167 New function to find out if a function may return NULL.
5169 * src/compiler.c (format_output): Make the generated
5172 * README: Point to a recent libffi snapshot.
5174 * tests/invoke/*: Some invoke tests.
5176 * src/Makefile: Add ginvoke.c and the necessary
5179 * src/girepository.h (g_function_info_invoke): Add
5182 * src/ginvoke.c (g_function_info_invoke): Initial
5183 implementation of invoke functionality based on libffi.
5185 * src/gidlnode.c (g_idl_node_build_metadata): Pass the
5186 strings and types hash tables in the right order when
5188 (find_entry_node): Free the name parts.
5190 2005-05-12 Johan Dahlin <johan@gnome.org>
5192 * src/generate.c: Generate consistent end tags.
5196 2005-05-12 Matthias Clasen <mclasen@redhat.com>
5200 * src/gidlparser.c (start_function): Actually add
5201 methods to objects. (Steven Walter)
5203 * src/girepository.h:
5204 * src/ginfo.c: Rename Transfer and Direction to
5205 GITransfer and GIDirection. (Torsten Schoenfeld)
5207 * tests/*: Make tests work with the changes in name
5210 * src/gidlnode.c (find_entry_node): Parse qualified
5211 names and generate xref nodes for them if needed. Don't
5212 require all modules to be loaded any more.
5214 * src/gidlmodule.c (g_idl_module_build_metadata): Choke
5217 * src/ginfo.c (g_object_info_get_parent): Return NULL
5218 if blob->parent is 0. Still need to make sure index
5221 * src/generate.c: Generate qualified names when
5222 referring to non-local types. Emit transfer attribute
5225 * src/compiler.c (format_output): Put the function
5226 attributes where gcc accepts them.
5228 2005-05-11 Matthias Clasen <mclasen@redhat.com>
5230 * src/compiler.c (main): Add a --verbose cmdline option
5231 and only log messages if it is specified.
5234 * src/gidlnode.c (init_stats, dump_stats): Collect some
5235 statistics on string and type sharing.
5237 * src/gidlmodule.c (g_idl_module_build_metadata): Use
5238 g_message() instead of fprintf().
5240 * src/gidlnode.c (g_idl_node_free): Make this more robust.
5241 (g_idl_node_get_size): Implement for structs.
5242 (g_idl_node_get_full_size): Handle parent being NULL.
5243 (serialize_type): Handle lookup failures more gracefully.
5245 2005-05-10 Matthias Clasen <mclasen@redhat.com>
5247 * src/gidlnode.c (g_idl_node_get_full_size): Correct the
5248 size calculation for 2-parameter types and for objects.
5250 * src/compiler.c: Add a cmdline option for debug output
5251 and install a log handler to implement it.
5252 * src/gidlnode.c: Add some debug spew.
5256 * src/gidlmodule.c (g_idl_module_build_metadata): Don't
5257 forget to count the module name when calculating the
5258 required size for the metadata.
5261 * src/gidlparser.c: Fix compiler warnings.
5263 2005-05-09 Matthias Clasen <mclasen@redhat.com>
5265 * src/compiler.c (main): Free the option context.
5267 * gidl.dtd: Clean up handling of names. All elements
5268 have a "name", only the elements corresponding to
5269 actual callable functions (function, method, constructor),
5270 have an additional "symbol" attribute holding the
5271 dlsym()-able function name.
5273 * src/generate.c: Adapt to generate xml matching the
5277 * src/gidlnode.c: Adapt to parse the new dtd.
5279 * tests/*.test: Adjust to the new dtd.
5281 * metadata-format.txt:
5282 * src/gmetadata.h: Remove the short_name field
5284 * src/gmetadata.c: Shrink size of ValueBlob to 12.
5285 * src/girepository.h:
5286 * src/ginfo.c (g_value_info_get_short_name): Removed
5288 2005-05-09 Matthias Clasen <mclasen@redhat.com>
5290 * gidl.dtd: Allow constructors for boxed types,
5291 patch by Jonathan Blandford.
5294 2005-05-09 Matthias Clasen <mclasen@redhat.com>
5296 * --- Initial import ---