1 2008-11-16 Colin Walters <walters@verbum.org>
3 * girepository/girepository.c: Ensure we always call init_globals,
4 even if passed a non-default repository.
6 2008-11-16 Colin Walters <walters@verbum.org>
8 Bug 559706 - Interface prerequisites
10 * common.mk: Dep on libgirepository.la for scanner libs so that
11 we rebuild things even if just gdump.c changes.
12 * girepository/gdump.c: Dump prerequisites.
13 * giscanner/ast.py: Add prerequisite list.
14 * giscanner/girparser.py: Parse them from gdump.
15 * giscanner/girwriter.py: Write them.
16 * giscanner/glibtransformer.py: Resolve them.
19 2008-11-16 Owen Taylor <otaylor@redhat.com>
21 Bug 561087 - Respect is_pointer in serialize_type()
23 Add a '*' to the serialization for the cases where we set is_pointer
24 in the type blob we write out depending on node->is_pointer. Don't
25 add the '*' in the cases where is_pointer is set or not set in a
28 http://bugzilla.gnome.org/show_bug.cgi?id=561087
30 2008-11-16 Owen Taylor <otaylor@redhat.com>
32 Bug 560825 – Add size and alignment to typelib
34 Include the size and alignment of structures and unions in the typelib,
35 and add getter methods to retrieve them from GIStructInfo/GIUnionInfo.
37 * docs/typelib-format.txt girepository/gtypelib.h girepository/girnode.c
38 girepository/girmodule.c girepository/gtypelib.c: Add size and alignment
39 to StructBlob and UnionBlob.
41 * girepository/ginfo.c girepository/girepository.h:
42 Add g_[struct|union]_get[size|alignment]().
44 * test/offsets/gen-gitestoffsets: Test overall structure size and alignment.
46 2008-11-16 Owen Taylor <otaylor@redhat.com>
48 Bug 552371 – implement struct field get/set
50 * girepository/gfield.c girepository/girepository.h: Add
51 convenience functions g_field_info_set_field() and
52 g_field_info_get_field() to set and get fields based on the
53 offsets in GIFieldInfo.
55 2008-11-16 Andreas Rottmann <a.rottmann@gmx.at>
57 Bug 560241 - Out-arguments should not be marked as being pointers
60 * girepository/girparser.c: Improved logic for out arguments.
62 2008-11-16 Andreas Rottmann <a.rottmann@gmx.at>
64 Bug 559601 - Pointers in structs/unions unduly treated as arrays
66 * giscanner/transformer.py: Differentiate type creation logic
67 between parameters and struct components.
69 2008-11-15 Colin Walters <walters@verbum.org>
71 * giscanner/dumper.py: Check return code from pkg-config
74 2008-11-14 Johan Dahlin <jdahlin@async.com.br>
76 * tests/everything/everything.c (test_array_int_in),
77 (test_array_gtype_in):
78 * tests/everything/everything.h:
79 Rename the int/gtype array tests. Make the return value
80 useful, an aggregation of the array input values.
82 2008-11-14 Johan Dahlin <jdahlin@async.com.br>
84 * tests/everything/Makefile.am:
85 * tests/everything/everything.c:
86 * tests/everything/everything.h:
87 * tests/everything/gitesttypes.c:
88 * tests/everything/gitesttypes.h:
89 Rename gitesttypes.[ch] to everything.[ch]
91 2008-11-13 Andreas Rottmann <a.rottmann@gmx.at>
93 Bug 560708 – Don't treat arrays that have a length specified as
94 zero-terminated by default
96 * giscanner/transformer.py: Default to non zero terminated for
98 * tests/*: Update, add test for zero vs not.
100 2008-11-13 Andreas Rottmann <a.rottmann@gmx.at>
102 Bug 557788 - Return types for constructors in generated typelib bogus
104 * girepository/girnode.c: Namespace-qualify XREFs; not doing so is
105 obviously broken in the face of duplicate names in different
107 * tests/scanner/*expected.gir: Fix up.
109 2008-11-13 Owen Taylor <otaylor@redhat.com>
111 * girepository/girffi.c: Fix "Unexpected time for time_t"
114 2008-11-13 Colin Walters <walters@verbum.org>
116 Bug 558436 - avoid having scanner load app code
118 * giscanner/cgobject.py: Delete; we no longer load shared
120 * giscanner/dumper.py: Support for linking a library to
121 a stub binary for introspection.
122 * giscanner/glibtransformer.py: Rewrite to use gdump XML
123 from invocation of child binary.
124 * giscanner/transformer.py: Fix up to use fully qualified
125 name in parse tree. Make parse_ctype public so we can use
126 it inside glibtransformer.
127 * tests/scanner/barapp.c: New test, using --program arg
129 * tests/*: Update to use common.mk for invoking scanner.
130 * tools/g-ir-scanner: Add options --program, --program-arg,
132 * docs/g-ir-scanner.1: Update.
134 2008-11-13 Colin Walters <walters@verbum.org>
136 * configure.ac: Depend on Gio, we use it in gdump.c.
137 * girepository/gdump.c: Code to dump GType data to XML.
138 * girepository/girepository.c: Add option group for dumping.
139 * girepository/girepository.h: Define API for the above.
141 2008-11-13 Colin Walters <walters@verbum.org>
143 * common.mk: Add a file to include with Makefile fragments
144 useful for scanner invocation.
146 2008-11-13 Tommi Komulainen <tommi.komulainen@iki.fi>
148 * tests/everything/gitesttypes.c (test_filename_return): Return
149 strings in filename encoding.
151 2008-11-13 Owen Taylor <otaylor@redhat.com>
153 Bug 560253 – Add structure and boxed types to Everything test module
155 * tests/everything/gitesttypes.[ch]: Add examples of:
157 Plain old data structs
158 Plain old data structs with nested fields
160 Plain old data boxed with nested fields
161 More complicated boxed types with internal state
163 2008-11-12 Johan Dahlin <jdahlin@async.com.br>
165 * tests/everything/gitesttypes.c (test_gtype_in):
166 * tests/everything/gitesttypes.h:
167 Add a test of GType arrays, a la gtk_list_store_set_columns.
169 2008-11-12 Owen Taylor <otaylor@redhat.com>
171 Bug 560419 – Cache includes when parsing
173 Keep track of all modules parsed within a GIrParser, and when a
174 module is referenced a second time, use the existing parsed copy
175 instead of reparsing.
177 2008-11-12 Owen Taylor <otaylor@redhat.com>
179 Fix management of ParseContext.includes_modules (#560419)
181 * girepository/girparser.c: Fix some trivial bugs in managing the
182 list of include modules. (Add to module's list twice, not
183 initialized to NULL, not freed.)
185 2008-11-12 Owen Taylor <otaylor@redhat.com>
187 Keep aliases and disguised_structures local to each module (#560419)
189 * girepository/girmodule.[ch]: When parsing, keep keep a separate
190 hash tables of aliases and 'disguised' flags for each module, and
191 store that on the module.
193 After parsing an include merge the aliases/disguised flags to the
196 * girepository/girparser.c: Remove 'prefix_aliases' flag and
197 always prefix aliases/disguised structure types when parsing; this
198 simplifies the code considerably.
200 2008-11-12 Owen Taylor <otaylor@redhat.com>
202 Fix mismatches between .gir name and 'name' attribute (#560419)
204 * tests/boxed.gir tests/constant.gir tests/enum.gir tests/invoke/invoke.c
205 tests/invoke/testfns-1.0.gir tests/object.gir tests/struct.gir: Fix places
206 where the 'name' element of <namespace/> didn't match the filename of the
207 gir, an assumption that the compiler has always expected and now enforces.
209 2008-11-12 Owen Taylor <otaylor@redhat.com>
211 Only allow one <namespace/> element per <repository/> (#560419)
213 * girepository/girparser.c: The logic in girparser.c didn't work
214 very well if there were multiple <namespace/> nodes within a
215 single <repository/> (context->namespace was always the overall
216 filename and not the the name specified in the <namespace/>
217 element for one thing; this would cause aliases to be mis-prefixed
218 in include modules.) Also check that the "name" in the
219 <namespace/> node matches the filename.
221 2008-11-12 Owen Taylor <otaylor@redhat.com>
223 Add a GirParser object to hold the state of a compilation
225 * girepository/girparser.[ch] tools/compiler.c: Add a toplevel
226 GirParser object to hold state that is global across a
227 compilation. Currently just holds the include path, but will
228 eventually also keep a cached list of parsed modules.
230 2008-11-12 Tommi Komulainen <tommi.komulainen@iki.fi>
232 * girepository/girepository.c (find_namespace_latest): Fix
235 2008-11-12 Tommi Komulainen <tommi.komulainen@iki.fi>
237 * configure.ac: use 'introspection' component for bugs
239 2008-11-12 Johan Dahlin <jdahlin@async.com.br>
241 * tests/everything/gitesttypes.c (test_filename_return):
242 * tests/everything/gitesttypes.h:
243 Add a filename return test.
245 2008-11-12 Tommi Komulainen <tommi.komulainen@iki.fi>
247 * tests/offsets/Makefile.am (gitestoffsets.c): fix
248 gen-gitestoffsets invocation with builddir != srcdir
250 2008-11-12 Johan Dahlin <jdahlin@async.com.br>
252 * girepository/girepository.c:
253 Change the element type from utf8 to filename
254 * girepository/girnode.c (g_ir_node_build_typelib):
255 Special case filename equally to utf8 here.
257 2008-11-12 Johan Dahlin <jdahlin@async.com.br>
260 Remove unused variables, add a dependency of girepository.ch, so when
261 they change we rebuild the gir automatically.
263 2008-11-12 Johan Dahlin <jdahlin@async.com.br>
265 * girepository/girepository.c (g_irepository_get_search_path):
266 * girepository/girepository.h:
267 Add a g_irepository_get_search_path, so we can access the search
270 2008-11-12 Johan Bilien <jobi@via.ecp.fr>
272 Bug 560474 – g-ir-compiler crashes when compiling the glib gir
274 * girepository/girparser.c: avoid freeing an uninitialized pointer
276 2008-11-12 Johan Dahlin <jdahlin@async.com.br>
279 * giscanner/glibtransformer.py:
280 * tools/g-ir-scanner:
281 Add a GIRepository-2.0.gir. Change the libtool lookup slightly
282 so we can just pass in --library=foo/bar/baz.la and the scanner
283 does the right thing.
284 Don't warn for _get_type() functions if they don't take any
287 2008-11-11 Owen Taylor <otaylor@redhat.com>
289 Bug 560404 – Prefix types when resolving aliases in included modules
291 * girepository/girparser.c: When resolving aliases in an included
292 module, prefix types before looking them up.
294 2008-11-11 Owen Taylor <otaylor@redhat.com>
296 Compute field offsets and overall size for object structures
298 Bug 560326 – Fails to build Gtk-2.0.typelib with "Unexpected non-pointer
299 field of type object in structure"
301 Do basic computation of field offsets for objects and interfaces;
302 this doesn't attempt to address all of the "mess" for virtual
303 functions described in Bug 560281.
305 2008-11-11 Tommi Komulainen <tommi.komulainen@iki.fi>
307 Bug 560308 – g-ir-compiler goes in infinite loop on Gdk-2.0.gir
309 Based on patch by Johan Bilien.
311 * giscanner/transformer.py (_create_member, _create_parameter):
312 Resolve types here as well.
313 (_resolve_type_name_1): Try resolving using 'ctype' first since
314 it's least ambiguous. Fixes struct member type resolution with
315 similarly named types, e.g. Gdk.PangoRendererClass and
317 * tests/scanner/foo*: Add test.
319 2008-11-11 Owen Taylor <otaylor@redhat.com>
321 * girepository/girparser.c: Search provided include dirs before
322 the default directories.
324 2008-11-11 Owen Taylor <otaylor@redhat.com>
326 * girepository/giroffsets.c: Include fully-qualified names in
329 2008-11-11 Owen Taylor <otaylor@redhat.com>
331 * girepository/giroffsets.c: Fail gracefully with an informative
332 error message when recursion is encountered when computing a
335 2008-11-11 Owen Taylor <otaylor@redhat.com>
337 * girepository/girparser.c: Remove an unused variable.
339 2008-11-10 Owen Taylor <otaylor@redhat.com>
341 Add tests for field offset computations
343 * tests/offsets/offsets.h: Header file with structure definitions to test
345 * tests/offsets/gen-gitestoffsets: Generate a C program that computes
346 field offsets for the structures in offsets.h two ways: using
347 the information from a generated typelib, and as computed by the
350 We diff these two versions to test that everything is OK.
352 2008-11-10 Owen Taylor <otaylor@redhat.com>
354 Remove field offsets from g-ir-generate output and test inputs
356 Field offsets are a) architecture dependent so they shouldn't be part
357 of the architecture-independent gir format which is installed in
358 datadir. b) Are architecture-dependent so they shouldn't be in test
361 * girepository/girparser.c: Don't parse offset for fields
362 * tools/generate.c: Don't parse offset for fields
363 * tests/*.gir test/scanner/*.tgir: Remove offsets
365 (Virtual function and discriminator offsets are not removed, as they
366 aren't fully hooked up to the field-offset computation machinery yet.)
368 2008-11-10 Owen Taylor <otaylor@redhat.com>
370 Bug 560252 - Compute field offsets before writing typelib
372 * girepository/girnode.h: Store the total size and alignment for
373 GIrNodeStruct/Boxed/Union.
375 * girepository/giroffset.c: New file implementing computation of
376 structure field offsets.
378 * girepository/girnode.c: Compute structure field offsets before
379 writing types into the typelib.
381 * docs/typelib-format.txt: Document that a field offset of 0xFFFF
382 means "unknown". Also fix description of the discriminator_offset
385 2008-11-10 Owen Taylor <otaylor@redhat.com>
387 Bug 560250 - Fully parse included modules
389 For some things, like computing structure offsets to put into the typelib
390 we need more than just the aliases from included modules. Do a completel
391 parse of included modules and store in module->included_modules.
393 Also add g_ir_find_node() to find node information from within the
394 active set of modules and their includes.
396 2008-11-10 Owen Taylor <otaylor@redhat.com>
398 Split g_ir_ffi_get_ffi_type() out from ginvoke.c
400 Extract a function to convert GITypeTag to ffi_type from the internals
401 of ginvoke.c. This will be useful in figure out structure alignment.
403 Also fix handling of gsize and time_t to be portable. (Add a check
404 to configure.ac to figure out the width of time_t.)
406 2008-11-10 Owen Taylor <otaylor@redhat.com>
408 Bug 560248 – "disguised structures"
410 Certain types like GIConv and GdkAtom are pointers internally but don't
411 look like pointers when referenced. They have the form.
413 typedef struct _X *X;
415 Parse these as structures/records but mark them in the gir with a 'disguised'
416 attribute so that we know that they need special handling.
418 In the typelib treat them like any other structure.
420 2008-11-09 Jürg Billeter <j@bitron.ch>
423 * giscanner/girwriter.py:
425 Write throws attribute for virtual functions, fixes bug 559703
427 2008-11-07 Johan Dahlin <jdahlin@async.com.br>
429 * giscanner/libtoolimporter.py (LibtoolImporter.find_module): Clear
430 up some confusion about the second argument to find_module, it's
431 actually the packages __path__ attribute which we can safely ignore
433 (LibtoolImporter.load_module): Set module.__loader__ as per PEP 302.
435 2008-11-07 Owen Taylor <otaylor@redhat.com>
437 Bug 559737 – Deal with continuations in macros
439 * giscanner/giscannerlexer.l: Treat continuation lines the same
440 as regular newlines. This makes the scanner not complain about
441 #define foo(x) \ <stuff> inside a C file. There's no attempt
442 however to handle parsing macro definitions split across lines.
444 2008-11-07 Johan Dahlin <jdahlin@async.com.br>
446 * giscanner/cachestore.py:
447 Handle broken cache entries, write only filesystems and
448 running out of diskspace.
450 2008-11-07 Owen Taylor <otaylor@redhat.com>
452 * giscanner/giscannermodule.c (pygi_source_scanner_lex_filename):
453 Set current_filename before lexing the file so error messages
454 are reported in the right file.
456 2008-11-06 Colin Walters <walters@verbum.org>
458 * tests/everything/*: Add some tests for strv.
460 2008-11-05 Colin Walters <walters@verbum.org>
462 * girepository/ginvoke.c (g_function_info_invoke): Don't use
463 nested scope local variable for error which may go away after
464 conditional is complete.
466 2008-11-05 Colin Walters <walters@verbum.org>
468 * giscanner/scannerlexer.l: Avoid static 256 char buf which we
469 manipulate hackily; just use GString. This avoids an
470 uninitialized memory read pointed out by Havoc.
472 2008-11-04 Johan Dahlin <jdahlin@async.com.br>
474 * giscanner/__init__.py:
476 * giscanner/cachestore.py:
477 * giscanner/cgobject.py:
478 * giscanner/girparser.py:
479 * giscanner/girwriter.py:
480 * giscanner/giscannermodule.c:
481 * giscanner/glibast.py:
482 * giscanner/glibtransformer.py:
483 * giscanner/libtoolimporter.py:
484 * giscanner/minixpath.py:
485 * giscanner/odict.py:
486 * giscanner/sourcescanner.c:
487 * giscanner/sourcescanner.h:
488 * giscanner/sourcescanner.py:
489 * giscanner/transformer.py:
490 * giscanner/utils.py:
491 * giscanner/xmlwriter.py:
493 Relicense the giscanner library under LGPLv2+.
494 This has been approved by all contributors.
496 2008-11-01 Owen Taylor <otaylor@redhat.com>
498 Bug 558848 giparser.py: shared library should be optional
500 When parsing a .gir, allow the shared-library attribute
501 of <namespace/> to be missing: this corresponds to the handling
502 in libgirepository and elsewhere.
504 2008-11-01 Tommi Komulainen <tommi.komulainen@iki.fi>
506 Bug 557898 – Fails to build on OSX 10.4
508 * configure.ac: Check for $shrext_cmds that should be implicitly
509 available if you're using libtool >= 2.0. If undefined, call
510 libtool --config explicitly to get its value.
511 * girepository/gtypelib.c: Remove special case for (non-)Darwin
514 2008-10-31 Colin Walters <walters@verbum.org>
516 * COPYING, COPYING.lib, COPYING.tools: Clarify licensing status.
518 2008-10-31 Johan Dahlin <jdahlin@async.com.br>
520 * configure.ac: Post release version bump
523 2008-10-31 Johan Dahlin <jdahlin@async.com.br>
527 * docs/release-checklist.txt:
530 2008-10-31 Johan Dahlin <jdahlin@async.com.br>
532 * Makefile.am: add an upload-release target
533 * docs/release-checklist.txt:
534 Release process documentation
536 2008-10-31 Colin Walters <walters@verbum.org>
538 Bug 558109 – _g_typelib_init fails to find shared libraries
540 * transformer/glibtransformer.py: Use ctypes' find_library
541 on passed libraries and write that for the shared-library
542 entry. We want to avoid depending on -devel packages.
544 2008-10-31 Johan Dahlin <jdahlin@async.com.br>
546 * docs/g-ir-scanner.1:
547 Document the renaming options.
549 2008-10-31 Tommi Komulainen <tommi.komulainen@iki.fi>
551 * giscanner/Makefile.am:
552 * tests/invoke/Makefile.am:
553 * tests/repository/Makefile.am: List in-tree libraries first in
554 LDADD / LIBADD. If installed library is listed first, the
555 resulting binary will prefer installed version to one in .libs,
556 possibly making 'make check' behave strangely.
558 2008-10-30 Tommi Komulainen <tommi.komulainen@iki.fi>
560 * giscanner/ast.py: map 'id' (ObjC) to 'any' type to stop
561 gir-repository from choking with gdk/quartz
563 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
565 * giscanner/giscannermodule.c (calc_attrs_length),
566 (pygi_collect_attributes):
567 * giscanner/xmlwriter.py:
568 Write a C version of the xml namespace formatter.
569 Saves 15% of the time it takes to create a gtk gir.
571 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
573 * giscanner/xmlwriter.py: Abstract attribute formatting
574 to a function external to the XMLWriter class.
576 * giscanner/scannerlexer.l:
577 Parse and discard __typeof and __attribute.
579 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
581 * giscanner/girparser.py:
582 Remove arguments from the constructor, move them to
583 separate accessors. Add a new parse_tree method
584 which takes an element tree instance.
585 * tools/g-ir-scanner:
586 Update callsite for this
588 * giscanner/Makefile.am:
589 * giscanner/cachestore.py:
590 * giscanner/transformer.py:
591 Cache the include parsing. Saves ~25% time when
592 creating vte (which includes everything up to gtk+).
594 2008-10-30 Colin Walters <walters@verbum.org>
596 * giscanner/transformer.py: Don't reparse includes
597 we've already processed.
599 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
601 * giscanner/girparser.py:
602 * giscanner/transformer.py:
603 Avoid parsing parameters, types etc when parsing
604 includes. Should speed up include parsing a bit.
606 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
608 * giscanner/girparser.py:
609 Avoid big if/else and use a dispatch table like
612 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
614 * giscanner/transformer.py:
615 Clean up include parsing and registration.
617 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
619 * giscanner/transformer.py:
622 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
624 Bug 558383 – builddir != srcdir build fails if giscanner python module not already installed
627 construct PYTHONPATH just once
629 * tests/everything/Makefile.am:
630 * tests/scanner/Makefile.am:
631 add $(top_srcdir) to PYTHONPATH to
632 handle builddir != srcdir
634 * giscanner/libtoolimporter.py:
635 * giscanner/sourcescanner.py:
636 Make the libtoolimporter work when distchecking too.
638 Mostly based on patch by Tommi Komulainen
640 2008-10-29 Owen Taylor <otaylor@redhat.com>
642 * giscanner/glibtransformer.py: If a filename of an existing
643 file is passed to --library, hunt for it directly, rather than
644 searching for a corresponding library.
646 2008-10-29 Johan Dahlin <jdahlin@async.com.br>
648 * giscanner/libtoolimporter.py:
649 * giscanner/sourcescanner.py:
650 Clean up the libtool importer a bit. Add a context so we
651 can use it through a with statement.
652 Don't just look in the current directory, look in the whole
655 2008-10-29 Tommi Komulainen <tommi.komulainen@iki.fi>
657 Bug 558065 – gitesttypes should be installed
661 * tests/types/Makefile.am -> tests/everything/Makefile.am
662 * tests/types/gitesttypes.c -> tests/everything/gitesttypes.c
663 * tests/types/gitesttypes.h -> tests/everything/gitesttypes.h
664 move tests/types to tests/everything
666 * tests/everything/Makefile.am: build normal shared library
667 libgirepository-everything.so.1.0.0 and corresponding typelib
668 Everything-1.0.typelib
670 * tests/everything/Makefile.am: explicitly link libtool
671 versioning with typelib versioning with variables
673 2008-10-28 Johan Bilien <jobi@via.ecp.fr>
675 * tools/g-ir-scanner: add LD_LIBRARY_PATH to LPATH before calling ld.
677 2008-10-27 Johan Bilien <jobi@via.ecp.fr>
679 * gio/gio-2.0.c: add allow-none annotations, based on the pygobject
682 2008-10-27 Johan Bilien <jobi@via.ecp.fr>
684 Bug 558068 – when invoking a method, offset the in arguments by one,
687 * tests/invoke/invoke.c, tests/invoke/testfns.c,
688 tests/invoke/testfns-1.0.gir: Add testing of method and constructor.
689 * girepository/ginvoke.c: do not offset the index of given out
690 arguments by one for methods, "this" is provided as in argument only.
692 2008-10-27 Johan Bilien <jobi@via.ecp.fr>
694 * gir/gio-2.0.c: add annotation for g_file_delete
696 2008-10-27 Tommi Komulainen <tommi.komulainen@iki.fi>
698 Bug 558062 – provide and use paths in the .pc file
700 * gobject-introspection-1.0.pc.in: provide typelibdir variable
701 for where .typelibs should be installed (callers shouldn't need
702 to construct paths from bits and pieces)
704 2008-10-25 Andreas Rottmann <a.rottmann@gmx.at>
706 Bug 557791 – g_irepository_require() could return a GTypelib *
708 * girepository/girepository.c: Return GTypelib; this is useful
709 for low level manipulation.
711 2008-10-25 Colin Walters <walters@verbum.org>
713 Bug 557788 – Return types for constructors in generated typelib bogus
715 * giscanner/glibtransformer.py: Don't resolve ctors incrementally,
716 rely on end pass resolution.
718 2008-10-25 Andreas Rottmann <a.rottmann@gmx.at>
720 Bug 557786 - support fixed size arrays
722 * girepository/ginfo.c: Add g_type_info_get_array_fixed_size.
723 * giscanner/scannerparser.y: Retain fixed array size.
724 * giscanner/ast.py: Add to note.
725 * giscanner/girwriter.py: Write to gir.
726 * girepository/girnode.c: Write it to typelib.
727 * tools/generate.c: Generate.
728 * tests/*: Add tests.
730 2008-10-25 Colin Walters <walters@verbum.org>
732 Bug 557076 - move typelibs to $libdir
734 * configure.ac: Steal some configury bits from dbus to expand
736 * gir/Makefile.am: Move to libdir.
737 * girepository/girepository.c: Stop searching XDG_DATA_DIRS;
738 instead just look at one hardcoded path in libdir.
739 * acinclude.m4: Bits from dbus.
741 2008-10-24 Johan Dahlin <johan@gnome.org>
743 * girepository/girnode.c (g_ir_node_check_unhandled_members):
744 Be quiet, do not warn about unhandled members.
746 2008-10-24 Johan Dahlin <johan@gnome.org>
748 * girepository/gtypelib.c:
749 Only use SHLIB_SUFFIX on darwin, otherwise use
750 G_MODULE_SUFFIX, we cannot get shext_cmds from libtool 2.2.
752 2008-10-24 Lucas Rocha <lucasr@gnome.org>
754 Bug 557623 - Constructors shouldn't be flagged as methods.
756 * girepository/ginfo.c (g_function_info_get_flags): ditto.
758 2008-10-24 Johan Dahlin <johan@gnome.org>
760 * giscanner/scannerparser.y:
761 Check against division by zero for the modula operator.
762 This fixes header parsing of OSX system headers included
765 2008-10-24 Johan Dahlin <johan@gnome.org>
769 Add a CONTRIBUTORS file and dist it.
771 2008-10-23 Tommi Komulainen <tommi.komulainen@iki.fi>
773 Bug 556739 – transfer-ownership attribute should be mandatory in .gir
775 * girepository/girparser.c (parse_param_transfer):
776 * giscanner/transformer.py (_create_parameter, _create_return):
777 * giscanner/girwriter.py (_write_return, _write_parameter):
778 * tools/generate.c (write_callable_info): always write and
779 require "transfer-ownership" for return-values and parameters
782 * tests/invoke/testfns-1.0.gir:
784 * tests/scanner/DrawableAdditions.xml:
785 * tests/scanner/GtkFrob-1.0-expected.tgir:
786 * tests/scanner/annotation-1.0-expected.tgir:
787 * tests/scanner/drawable-1.0-expected.tgir:
788 * tests/scanner/drawable-injected-1.0-expected.gir:
789 * tests/scanner/drawable-injected-1.0-expected.tgir:
790 * tests/scanner/foo-1.0-expected.tgir: Updated
792 2008-10-23 Tommi Komulainen <tommi.komulainen@iki.fi>
794 * giscanner/cgobject.py: build fundamental types same way as glib
796 * giscanner/glibtransformer.py (_type_from_gtype): record GType
797 when constructing the Type from it
799 * giscanner/glibtransformer.py (_adjust_transfer): Check whether
800 the parameter is a GObject from its GType, if available.
802 * giscanner/glibtransformer.py (_adjust_transfer):
803 * tests/scanner/foo-1.0-expected.gir:
804 * tests/scanner/foo-1.0-expected.tgir: deduce
805 transfer-ownership from GTypes
807 2008-10-23 Tommi Komulainen <tommi.komulainen@iki.fi>
809 * giscanner/transformer.py (_create_parameter):
810 * tests/scanner/foo-1.0-expected.gir: make varargs
811 transfer-ownership="none"
813 2008-10-23 Colin Walters <walters@verbum.org>
815 Bug 556739 - transfer ownership
817 * giscanner/ast.py: Refactor Parameter/Return to share
818 common attributes. Add transfer_inferred attribute
819 which says whether or not we made a guess.
820 * giscanner/transformer.py: Add much more extensive
821 heuristics around parameter and return transfer.
822 * giscanner/glibtransformer.py: Adjust to inspect
826 2008-10-22 Tommi Komulainen <tommi.komulainen@iki.fi>
828 Bug 557377 – Add test to ensure annotations survive the roundtrip via typelib
830 * tests/scanner/Makefile.am:
831 * tests/scanner/annotation-1.0-expected.tgir:
832 * tests/scanner/drawable-1.0-expected.tgir:
833 * tests/scanner/drawable-injected-1.0-expected.tgir:
834 * tests/scanner/foo-1.0-expected.tgir:
835 * tests/scanner/GtkFrob-1.0-expected.tgir:
836 * tests/scanner/utility-1.0-expected.tgir: Add test to ensure
837 annotations survive the roundtrip via typelib
839 The expectations are as currently produced by g-ir-generate,
840 comparison with the .gir files shows there are differences.
842 2008-10-23 Johan Bilien <jobi@via.ecp.fr>
844 Bug 557468 – Support for GI_TYPELIB_PATH
846 * girepository/girepository.c: if the GI_TYPELIB_PATH is set, add the
847 provided paths to the global search path.
849 2008-10-22 Tommi Komulainen <tommi.komulainen@iki.fi>
851 Bug 557379 – g-ir-generate not writing the 'abstract' attribute
853 * tests/scanner/drawable-1.0-expected.tgir:
854 * tests/scanner/drawable-injected-1.0-expected.tgir:
855 * tests/scanner/foo-1.0-expected.tgir:
856 * tools/generate.c (write_object_info): write 'abstract'
857 attribute for classes
859 2008-10-22 Lucas Rocha <lucasr@gnome.org>
861 * girepository/girmodule.c, girepository/gtypelib.c,
862 girepository/girparser.[ch]: fix some build warnings.
864 2008-10-22 Tommi Komulainen <tommi.komulainen@iki.fi>
866 Bug 557405 – Use 'allow-none' consistently
868 * docs/typelib-format.txt:
869 * girepository/ginfo.c (g_arg_info_may_be_null):
870 * girepository/girnode.c (g_ir_node_build_typelib):
871 * girepository/girnode.h (struct _GIrNodeParam):
872 * girepository/girparser.c (start_parameter):
873 * girepository/girwriter.c (function_generate):
874 * girepository/gtypelib.h (ArgBlob):
876 * tests/function.gir:
877 * tools/generate.c (write_callable_info): Use 'allow-none'
878 consistently throughout
880 2008-10-22 Tommi Komulainen <tommi.komulainen@iki.fi>
882 Bug 557092 – Callback annotations not used
884 * giscanner/transformer.py (_create_callback): use annotations
886 * tests/scanner/annotation.h
887 * tests/scanner/annotation-1.0-expected.gir: add tests
889 2008-10-21 Colin Walters <walters@verbum.org>
891 * giscanner/scannerlexer.l: Don't require trailing whitespace after
892 uncommented parameters.
895 2008-10-21 Colin Walters <walters@verbum.org>
897 * girepository/girepository.c: Ensure that when doing an unversioned
898 require, we prefer items earlier in the search path to later ones.
900 2008-10-21 Owen Taylor <otaylor@redhat.com>
902 * giscanner/transformer.py: For string parameters allow transfer annotation
903 to override the standard automatic guessing based on 'const'.
905 2008-10-21 Johan Bilien <jobi@via.ecp.fr>
907 Bug 557241 – "throws" flag for functions
909 * tests/scanner/drawable-1.0-expected.gir,
910 tests/scanner/drawable-injected-1.0-expected.gir,
911 tests/scanner/drawable.[ch]: add simple test for throwing
912 function (has GError ** as last argument)
914 * giscanner/ast.py: add a 'throws' flag to Function
915 * giscanner/glibtransformer.py: if a function's last paramerter is
916 a GError, set the 'throws' flag and remove that parameter
917 * giscanner/girwriter.py: write out the 'throws' attribute
918 * giscanner/girparser.py: support parsing the 'throws' attribute
920 * tests/repository/gitestthrows.c: add a simple test to check the
921 throws flag in a typelib and invoke the function
923 * girepository/ginfo.c, girepository/girnode.[ch],
924 girepository/girnode.h, girepository/girparser.c,
925 girepository/girepository.h: Add and parse the GI_FUNCTION_THROWS flag
927 * girepository/ginvoke.c: if a function throws, add a GError as last
928 arguments, and propagate the error to the invoker.
930 2008-10-21 Tommi Komulainen <tommi.komulainen@iki.fi>
932 * giscanner/transformer.py (_create_parameters): Warn if we see
933 annotations for unknown parameters. If .h and .c files name
934 parameters differently, the annotations may be lost.
936 2008-10-21 Johan Dahlin <johan@gnome.org>
938 Bug 556358 - don't use libtool internals
940 * giscanner/Makefile.am:
941 * giscanner/libtoolimporter.py:
942 * giscanner/sourcescanner.py:
943 * giscanner/utils.py:
944 Add a python meta importer and remove a libtool symlink hack.
946 2008-10-20 Andreas Rottmann <a.rottmann@gmx.at>
948 * tests/scanner/Makefile.am (%.typelib): Set PYTHONPATH
949 and --add-include-path appropriately when invoking the scanner.
950 * tests/types/Makefile.am (%typelib): Likewise.
952 2008-10-20 Colin Walters <walters@verbum.org>
954 Bug 556777 - validate properties
956 * giscanner/transformer.py: Add option to throw on unknown types.
957 * giscanner/glibtransformer.py: Use it on properties.
958 * tests/*: Add a test.
960 2008-10-20 Colin Walters <walters@verbum.org>
962 * giscanner/glibast.py: Also register g variants of
963 default_array_types. This is not beautiful, but
964 good alternatives aren't easy to come by.
965 This fixes gchar ** parsing.
967 2008-10-20 Colin Walters <walters@verbum.org>
969 * docs/typelib-format.txt, girepository/gtypelib.h:
970 Take a bit from ObjectInfo to represent abstract flag.
971 * giscanner/cgobject.py: Expose g_type_get_flags.
972 * girepository/girepository.h: Add accessor.
973 * girepository/ginfo.c: Implement it.
974 * giscanner/ast.py: Add is_abstract flag to generic
976 * giscanner/glibast.py: Use it.
977 * giscanner/girwriter.py: Write it.
978 * girepository/girparser.c: Parse it.
981 2008-10-20 Tommi Komulainen <tommi.komulainen@iki.fi>
983 * giscanner/girparser.py (_parse_function): don't lose
984 'transfer-ownership' attributes when injecting, check for the
987 2008-10-19 Johan Dahlin <johan@gnome.org>
989 * giscanner/scannerlexer.l: Parse and ignore __asm.
991 2008-10-19 Colin Walters <walters@verbum.org>
993 * giscanner/girparser.py: Parse array length= to ensure
994 it doesn't get lost from --inject.
996 2008-10-17 Colin Walters <walters@verbum.org>
998 Bug 556795 - char ** regression
1000 * giscanner/transformer.py: Fix parsing of ctypes, add some
1001 comments about what's going on.
1002 * tests/*: Add a test for char **.
1004 2008-10-17 Colin Walters <walters@verbum.org>
1006 Bug 556783 - change namespace handling to be more consistent
1008 * giscanner/transformer.py: Eliminate usage of
1009 strip_namespace_object. We now treat --namespace as the default
1010 --strip-prefix; however, if --strip-prefix is specified it
1011 overrides --namespace. This applies to everything except function
1012 names, where we do also strip the namespace.
1013 * giscanner/glibtransformer.py: Remove usage of
1014 strip_namespace_object.
1016 * tests/*: Add skeletal GtkFrob-1.0 test which has different
1017 --namespace and --strip-prefix.
1019 2008-10-17 Tommi Komulainen <tommi.komulainen@iki.fi>
1021 Bug 556732 – generate gir files consistently
1023 * girepository/girparser.c (start_parameter):
1025 * tests/invoke/testfns-1.0.gir:
1026 * tools/generate.c (write_callable_info): write
1027 'transfer-ownership' attribute consistently with both
1028 return-value and parameter elements
1030 2008-10-17 Tommi Komulainen <tommi.komulainen@iki.fi>
1032 Bug 556732 – generate gir files consistently
1034 * tools/generate.c (write_callable_info): write 'direction'
1035 attribute only if other than 'in' to be consistent with
1038 * tests/object.gir: remove direction="in" which is the default
1040 2008-10-17 Tommi Komulainen <tommi.komulainen@iki.fi>
1042 Bug 556732 – generate gir files consistently
1044 * giscanner/ast.py (Field): add readable and writable properties
1045 * giscanner/girparser.py (_parse_field): copy 'readable' and
1046 'writable' attributes
1047 * giscanner/transformer.py (_create_member): create fields as
1049 * giscanner/glibtransformer.py (_introspect_object,
1050 _pair_class_struct): make object instance and class fields
1052 * giscanner/girwriter.py (_write_field):
1053 * tools/generate.c (write_field_info): write field 'readable'
1054 and 'writable' attributes only if non-default (read-only)
1055 * girepository/girparser.c (start_field): in the absence of
1056 attributes assume fields are read-only
1058 * tests/struct.gir: remove redundant readable="1" from fields
1059 * tests/scanner/foo-1.0-expected.gir:
1060 * tests/scanner/utility-1.0-expected.gir: add writable="1" to
1061 all record and union fields
1063 2008-10-17 Tommi Komulainen <tommi.komulainen@iki.fi>
1065 Bug 556732 – generate gir files consistently
1067 * giscanner/girwriter.py (_write_property): write properties
1068 'construct' attribute if set
1069 * tools/generate.c (write_property_info): write properties
1070 'readable' and 'writable' attributes only if non-default
1071 * tests/object.gir: add writable="0"
1072 * tests/scanner/foo-1.0-expected.gir: add construct="1"
1074 2008-10-17 Johan Bilien <jobi@via.ecp.fr>
1076 * gir/glib-2.0.c: added annotations
1078 2008-10-16 Johan Bilien <jobi@via.ecp.fr>
1080 * giscanner/ast.py: Also assume direction=out for size_t*, ssize_t*
1083 2008-10-16 Johan Bilien <jobi@via.ecp.fr>
1085 Bug 556610 – giscanner/girparser.py drops parameter options
1087 * tests/scanner/drawable-injected-1.0-expected.gir,
1088 tests/scanner/DrawableAdditions.xml: added simple test for injection.
1089 * giscanner/ast.py: allow Parameter to take options in the constructor
1090 * giscanner/girparser.py: parse parameter options (transfer,
1091 direction, allow-none)
1093 2008-10-16 Colin Walters <walters@verbum.org>
1095 Bug 556185 - segfault on g_callable_info_get_return_type
1097 Initial patch from John Ehresman.
1099 * tests/repository/*: Add a test using
1100 g_callable_info_get_return_type. Instead of casting a
1101 GITypeInfo directly to a GIRegisteredTypeInfo, we need
1102 to call g_type_info_get_interface.
1104 2008-10-16 Colin Walters <walters@verbum.org>
1106 Bug 556579 - union and struct name misresolved
1108 * giscanner/transformer.py: The calls to _resolve_type_name
1109 for struct/union names was a legacy holdover from when type
1110 resolution had multiple phases. Now it's actively harmful
1111 since we might pull in an identical name from another
1115 2008-10-16 Colin Walters <walters@verbum.org>
1117 Bug 556432 - transfer annotations and defaults
1119 * giscanner/transformer.py: Canonicalize type
1120 after removing *, not before. This ensures that
1121 guchar* is transformed to 'uint8'.
1122 Add some comments here.
1123 * giscanner/glibtransformer.py: Add _adjust_transfer
1124 phase for tweaking GObject transfers.
1127 2008-10-16 Tommi Komulainen <tommi.komulainen@iki.fi>
1129 * configure.ac: enable bunch of gcc warning CFLAGS
1131 2008-10-16 Tommi Komulainen <tommi.komulainen@iki.fi>
1133 Bug 556543 – reduce compiler warnings
1135 * girepository/ginfo.c:
1136 * girepository/girepository.c (register_internal,
1137 count_interfaces, find_interface, find_namespace_version,
1138 parse_version, g_irepository_require):
1139 * girepository/girmodule.c (g_ir_module_build_typelib):
1140 * girepository/girnode.c (init_stats, dump_stats,
1141 _g_irnode_init_stats, _g_irnode_dump_stats,
1142 g_ir_node_can_have_member):
1143 * girepository/girparser.c (firstpass_end_element_handler,
1144 locate_gir, parse_basic, parse_type_internal, resolve_aliases,
1145 start_alias, start_type, end_type_top, parse_include, cleanup,
1147 * girepository/gtypelib.c (validate_function_blob, validate_enum_blob):
1148 * giscanner/giscannermodule.c (directive_get_options,
1149 type_get_child_list):
1150 * giscanner/scannerlexer.l (parse_gtkdoc):
1151 * giscanner/scannerparser.y (ctype_free):
1152 * giscanner/sourcescanner.c:
1153 * giscanner/sourcescanner.h (gi_source_scanner_parse_macros):
1154 * tests/types/gitesttypes.c:
1155 * tools/compiler.c (main):
1156 * tools/generate.c (write_repository): Remove unused variables
1157 and code, add missing includes, declarations and case
1160 2008-10-16 Tommi Komulainen <tommi.komulainen@iki.fi>
1162 Bug 556541 – access union members through UnionBlob rather than
1165 * girepository/ginfo.c (g_union_info_find_method): access union
1166 members through UnionBlob rather than StructBlob
1168 2008-10-15 Colin Walters <walters@verbum.org>
1170 Bug 556331 - clean up includes handling
1172 * tools/g-ir-scanner: Rework command line arguments; now we take
1173 --add-include-path and --include separately.
1174 * giscanner/girwriter.py: Separate name= and version= in include
1176 * giscanner/ast.py: Add Include type.
1177 * giscanner/transformer.py: Cleanups to register_include now that
1178 we don't need to handle mixed filenames and relative arguments.
1179 * girepository/girparser.c: Parse name and version separately;
1180 this fixes a bug as a side effect where we weren't resolving
1181 through aliases for basic types.
1182 * girepository/girepository.c: Fix format string args.
1183 * gir/Makefile.am: Update.
1186 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1188 Bug 556434 – unhandled interface/object/... member types
1190 * girepository/girnode.c (g_ir_node_check_unhandled_members,
1191 g_ir_node_build_typelib): Check all
1192 interface/object/boxed/struct/union members are processed and
1193 abort if they are not. (Mostly callbacks in structs, but also
1194 fields in interfaces.)
1196 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1198 * a/girepository/girnode.c (g_ir_node_build_members,
1199 g_ir_node_build_typelib): refactor common code for processing
1200 members to a function
1202 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1204 * gir/Makefile.am (check-local): check that typelib -> gir -> typelib
1205 transformation is lossless (it's not)
1207 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1209 * tests/Makefile.am: fix tests to compare xml to xml instead of
1210 typelib to xml, and stop on error
1212 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1214 * tools/generate.c (write_type_name, write_type_info,
1215 write_type_info, write_object_info, write_object_info,
1216 write_interface_info, write_error_domain_info): reduce code
1219 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1221 Bug 556174 – parse types for lists etc.
1223 * girepository/girparser.c (end_type_recurse):
1225 * tools/generate.c (write_type_info, write_field_info,
1226 write_callable_info, write_callable_info, write_constant_info,
1227 write_property_info): use nested <type>s for lists and hashes
1229 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1232 * tests/object.gir: remove trailing whitespace from inside
1233 elements to match g-ir-generate output
1235 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1237 * tools/generate.c (xml_printf): quote printf arguments so that
1238 we don't generate invalid XML by writing unescaped double quotes
1239 and such in attributes
1241 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1243 * tools/generate.c (write_field_info, write_callable_info,
1244 write_function_info, write_callback_info, write_struct_info,
1245 write_constant_value, write_signal_info, write_vfunc_info,
1246 write_object_info, write_interface_info, write_union_info,
1247 write_repository): remove unused indent parameters, xmlwriter
1248 keeps track of necessary indentation
1250 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1252 * tools/generate.c (xml_element_new, xml_element_free,
1253 xml_start_element, xml_end_element, xml_end_element_unchecked,
1254 xml_open, xml_close): Keep track of generated XML tree and
1255 handle indentation and closing tags properly.
1256 (write_field_info, write_callable_info, write_function_info,
1257 write_callback_info, write_struct_info, write_value_info,
1258 write_constant_info, write_enum_info, write_signal_info,
1259 write_vfunc_info, write_property_info, write_object_info,
1260 write_interface_info, write_error_domain_info, write_union_info,
1261 write_repository): Use xml_start_element and xml_end_element to
1264 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1266 * tools/generate.c (xml_printf, xml_open, xml_close, xml_free):
1267 (write_type_name, write_type_info, write_field_info,
1268 write_callable_info, write_function_info, write_callback_info,
1269 write_struct_info, write_value_info, write_constant_value,
1270 write_constant_info, write_enum_info, write_signal_info,
1271 write_vfunc_info, write_property_info, write_object_info,
1272 write_interface_info, write_error_domain_info, write_union_info,
1273 write_repository): wrap all FILE access to go through simple xmlwriter
1275 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1277 Bug 556400 – Fails to build on OS X 10.4
1279 * configure.ac: check for functions backtrace and backtrace_symbols
1280 * girepository/girparser.c (backtrace_stderr): Comment out
1281 implementation if the functions are not available.
1282 * gcov.mak (clean-gcov, clean-gcno): always call 'find' with a
1283 directory for better portability
1285 2008-10-15 Johan Bilien <jobi@via.ecp.fr>
1287 Bug 556433 – assume direction = out for int * parameters
1289 * giscanner/ast.py: define a list of types for which, if passed as
1290 reference, we assume a default direction of 'out'
1291 * giscanner/transformer.py: if a type has type pointer to one of the
1292 previously defined types, and no direction is set, assume out.
1293 * tests/scanner/drawable.[ch]: added tests for guessed direction=out
1295 2008-10-15 Johan Bilien <jobi@via.ecp.fr>
1297 * tests/scanner/annotation.c: fixed a few copy-paste errors
1299 2008-10-14 Johan Bilien <jobi@via.ecp.fr>
1301 Bug 556323 – transfer-ownership is wrong for functions returning const
1304 * giscanner/transformer.py: check for a const string as return value,
1305 not just const char*. Suggested by Colin Walters
1306 * tests/scanner/annotation-1.0-expected.gir: updated expected output
1308 2008-10-14 Johan Bilien <jobi@via.ecp.fr>
1310 * girepository/ginfo.c, girepository/girepository.h: add
1311 g_union_info_find_method
1313 2008-10-14 Colin Walters <walters@verbum.org>
1315 * tests/repository/Makefile.am: Reenable repo test.
1316 * tests/repository/gitestrepo.c: Prepend search
1317 path for $(top_builddir)/gir dir so that we don't
1318 require installation for "make check" to pass.
1320 2008-10-13 Jürg Billeter <j@bitron.ch>
1322 * giscanner/glibtransformer.py:
1323 * tests/scanner/annotation-1.0-expected.gir:
1324 * tests/scanner/drawable-1.0-expected.gir:
1325 * tests/scanner/foo-1.0-expected.gir:
1326 * tests/scanner/utility-1.0-expected.gir:
1328 Support fields in GObject structs
1330 2008-10-13 Jürg Billeter <j@bitron.ch>
1332 * giscanner/ast.py: add signed integer and off_t to type_names
1334 2008-10-12 Jürg Billeter <j@bitron.ch>
1336 * giscanner/girparser.py: Parse bits attribute of fields
1338 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1340 * tests/repository/Makefile.am: run 'gitestrepo' in 'make check'
1341 * tests/repository/gitestrepo.c (main): instantiate
1342 'GCancellable' to ensure the GType is registered before using
1345 2008-10-12 Johan Bilien <jobi@via.ecp.fr>
1347 * giscanner/girparser.py: actually add the parsed constant nodes
1349 2008-10-12 Colin Walters <walters@verbum.org>
1351 * girepository/girepository.c: Don't cast DirEntry to Blob,
1352 actually look it up by offset.
1354 2008-10-12 Johan Bilien <jobi@via.ecp.fr>
1356 * giscanner/girparser.py: parse constant nodes in gir files
1358 2008-10-12 Johan Bilien <jobi@via.ecp.fr>
1360 * giscanner/transformer.py: prefix for constants have an underscore,
1361 so remove them as if they were functions, not objects.
1363 2008-10-12 Johan Bilien <jobi@via.ecp.fr>
1365 * tests/scanner/foo-1.0-expected.gir: add constants to expected gir
1368 2008-10-12 Colin Walters <walters@verbum.org>
1370 Initial patch from Jani Monoses.
1372 * girepository/gtypelib.c: Fix inverted test for success
1375 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1377 * tools/generate.c (write_callable_info): use "transfer-ownership"
1378 attribute for return values
1380 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1382 * tools/generate.c (write_callable_info): move "transfer" and
1383 "null-ok" attributes from <function> to <return-value> element
1385 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1387 * girepository/girparser.c (start_return_value): handle
1388 "transfer-ownership" attribute
1390 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1392 * girepository/girparser.c (parse_param_transfer):
1393 * tools/generate.c (write_callable_info): use "container" for
1394 container/shallow ownership transfer (not "shallow")
1396 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1398 * girepository/girparser.c (parse_param_transfer,
1399 start_parameter): Refactor handling of transfer=none/shallow/full
1400 to separate function
1402 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1404 Bug 556048 – Crash in g_irepository_find_by_gtype
1406 * girepository/gtypelib.h (BLOB_IS_REGISTERED_TYPE): added
1407 * girepository/girepository.c (find_interface): Fix
1408 find_by_gtype case to get the type name from right offset
1410 2008-10-12 Jürg Billeter <j@bitron.ch>
1412 * giscanner/girparser.py: Fix parsing transfer-ownership attribute
1415 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1417 * girepository/gtypelib.h (RegisteredTypeBlob): make
1418 'unregistered' one bit wide as everywhere else
1420 2008-10-12 Jürg Billeter <j@bitron.ch>
1422 * giscanner/glibtransformer.py:
1423 * tests/scanner/annotation-1.0-expected.gir:
1424 * tests/scanner/drawable-1.0-expected.gir:
1425 * tests/scanner/drawable.h:
1426 * tests/scanner/foo-1.0-expected.gir:
1427 * tests/scanner/utility-1.0-expected.gir:
1429 Readd class records as workaround to not break Gtk typelib
1431 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1433 * tests/types/Makefile.am: fix typo in gitesttypes namespace
1435 2008-10-12 Jürg Billeter <j@bitron.ch>
1437 * giscanner/glibtransformer.py: Don't generate <record> elements
1439 * tests/scanner/*: Update test cases
1441 2008-10-11 Colin Walters <walters@verbum.org>
1443 Bug 552858: versioning
1445 This is a big patch. You should probably remove your installation
1448 * docs/typelib-format.txt: Add nsversion entry which holds
1449 version of namespace.
1450 * girepository/girepository.h: Add 'version' parameter to
1451 g_irepository_require. This may be NULL. Normally
1452 bindings should pass an explicit version though.
1453 * girepository/girepository.c: Lots of infrastructure to
1454 support versioning. Add some more documentation. Disallow
1455 some usage of NULL namespaces.
1456 * girepository/girmodule.c: Add version parameter.
1457 * girepository/gtypelib.c: Update header size.
1458 * giscanner/ast.py: Add version to Namespace.
1459 * giscanner/girparser.py: Parse version attribute from
1460 XML, pass to Namespace.
1461 * giscanner/girwriter.py: Write out version parameter.
1462 * giscanner/transformer.py: Clean up include registration.
1463 * tests/*: Add version attribute.
1464 * tests/invoke/invoke.c: Don't try looking up test before
1465 it's loaded in repository.
1466 * tools/generate.c: Output version parameter.
1467 * gir/Makefile.am: Add 2.0 version to .gir files.
1469 2008-10-11 Colin Walters <walters@verbum.org>
1471 * giscanner/scannerlexer.l (parse_gtkdoc): Don't lose
1472 if we have mismatched parens.
1474 2008-10-11 Lucas Rocha <lucasr@gnome.org>
1476 * giscanner/girparser.py (_parse_enumeration_bitfield): fix typo
1477 on 'members' variable.
1479 2008-10-11 Colin Walters <walters@verbum.org>
1481 Bug 555947 - update annotations syntax
1483 * giscanner/ast.py: Default to None for transfer. Remove
1484 default transfers for container types; we require this to
1486 * giscanner/girwriter.py: Transfer is now 'none', 'container',
1487 'full' to match repository.
1488 * giscanner/scannerlexer.l: Annotations now are parenthesized.
1489 * giscanner/transformer.py: Update for new annotations syntax.
1492 2008-10-11 Johan Bilien <jobi@litl.com>
1494 * giscanner/scannerparser.y: ignore non-UTF-8 string constants
1496 2008-10-11 Johan Bilien <jobi@litl.com>
1498 Bug 552347: Parse #defines constants
1500 * girepository/gtypelib.c: update the list of value_size
1501 with recently defined type tags
1502 * giscanner/scannerparser.y: brought back parsing of #defined, as
1503 present in older version
1504 * giscanner/giscannermodule.c: bind gi_source_scanner_append_filename
1505 * giscanner/girwriter.py: write out constant tags in the gir
1506 * giscanner/sourcescanner.py: add accessor for const_string
1507 * giscanner/transformer.py, giscanner/glibtransformer.py: handle
1510 2008-10-11 Tommi Komulainen <tommi.komulainen@iki.fi>
1512 Bug 555946: Install a test module exercising all types, transfer
1517 * tests/types/*: Add and install a test module that has functions
1518 accepting and returning most of the basic types to enable bindings
1519 implementors to more easily test their type conversion routines.
1521 2008-10-11 Jürg Billeter <j@bitron.ch>
1523 Bug 552374: Const strings should be identified in the gir.
1525 * giscanner/transformer.py: support string memory management
1526 * tests/scanner/foo.h: use char * and const char *
1527 * tests/scanner/foo-expected.gir: test that
1529 2008-10-11 Johan Dahlin <johan@gnome.org>
1531 * giscanner/girparser.py:
1532 Also parse enums which are not glib types.
1534 2008-10-11 Lucas Rocha <lucasr@gnome.org>
1536 Bug 552370: add one more test for unsigned as a type, not as
1539 * giscanner/ast.py: add 'uint' type name for 'unsigned'.
1540 * test/scanner/foo.h: add function which uses unsigned as a type.
1541 * test/scanner/foo-expected.gir: test that.
1543 2008-10-11 Andreas Rottmann <a.rottmann@gmx.at>
1545 Bug 555712: Struct and union issues
1547 * giscanner/scannerparser.y (struct_declarator): Use information
1548 provided about the bit width of a field.
1549 * giscanner/transformer.py (Transformer._create_member): Pass the
1550 symbol's const_int member to the created field (it represents the
1552 * giscanner/girwriter.py (GIRWriter._write_field): Output 'bits'
1553 field attribute, if present.
1554 * giscanner/ast.py (Field): Add 'bits' member, specifying the
1555 width in bits of the field (only relevant for bitfields).
1558 * giscanner/transformer.py (Transformer._create_typedef_struct)
1559 (Transformer._create_typedef_union): Add calls to _create_struct()
1560 and _create_union(), respectively. This causes the scanner to
1561 generate output for fields of struct and union typedefs.
1564 2008-10-11 Jürg Billeter <j@bitron.ch>
1566 Bug 552370: unsigned not scanned properly
1568 * giscanner/scannerparser.y: combine basic types such as unsigned
1569 int and long long when scanning
1570 * tests/scanner/foo-expected.gir:
1571 * tests/scanner/foo.c: (foo_test_unsigned):
1572 * tests/scanner/foo.h: test that
1574 2008-10-11 Lucas Rocha <lucasr@gnome.org>
1576 Bug 554854: The --typelib-xml and --inject options should reuse
1577 giscanner parser/writer.
1579 * giscanner/ast.py: add constructor list to Struct and Union.
1580 Add new param in Return's contructor to define transfer.
1581 * giscanner/girparser.py: several additions to the parser in order
1582 to have parsing all nodes of the gir xml files.
1583 * tools/g-ir-scanner (typelib_xml_strip, inject): use gir parser
1584 and writer in --inject and --typelib-xml options.
1585 * giscanner/xmlwriter.py: ignore empty attributes instead of
1586 raising an error as this basically exposes a bug in GIRParser.
1587 This should be reverted as soon as the parser is fixed.
1589 2008-10-11 Lucas Rocha <lucasr@gnome.org>
1591 Bug 552376: scanner generates wrong names for enum members when
1592 there's no defined gtype.
1594 * giscanner/utils.py (strip_common_prefix): Always strip common
1595 prefix exactly up to the last "_", and not beyond.
1596 * tests/scanner/foo.h (FooEnumNoType): add FOO_ENUM_NEUF. The point
1597 here is that the first character after the last '_' should should be
1598 the same as the character in the same position on the type name.
1599 * tests/scanner/foo-expected.gir: test that
1601 2008-10-10 Lucas Rocha <lucasr@gnome.org>
1603 Bug 555293: append library_paths to LPATH env variable to work
1604 around a bug in find_library when using ldconfig.
1606 * tools/g-ir-scanner (main): ditto.
1608 2008-10-09 Lucas Rocha <lucasr@gnome.org>
1610 * girepository/girepository.c (register_internal): fix regression on
1611 invoke test case by making sure we load the global module in the
1612 typelib when dealing with inline typelibs.
1613 * girepository/gtypelib.c: a couple of coding style fixes.
1615 2008-10-06 Lucas Rocha <lucasr@gnome.org>
1617 Bug 555294: Add support for multiple shared libraries per typelib.
1619 * girepository/ginvoke.c (g_function_info_invoke),
1620 girepository/ginfo.c(g_registered_type_info_get_g_type): use
1621 g_typelib_symbol instead of g_module_symbol.
1622 * girepository/girepository.h: remove g_typelib_set_module and add
1624 * girepository/gtypelib.[ch] (find_some_symbol, _g_typelib_init,
1625 g_typelib_new_from_memory, g_typelib_new_from_const_memory,
1626 g_typelib_free, g_typelib_symbol): chnage GTypeLib to hold a list of
1627 modules instead of just one. The symbol lookup is now abstracted
1628 behind g_typelib_symbol which tries to find the passed symbol name in
1630 * giscanner/girwriter.py, tools/g-ir-scanner: change scanner to read
1631 and write shared_library attribute as a comma-separated list of libs.
1633 2008-10-06 Colin Walters <walters@verbum.org>
1635 * giscanner/transformer.py: Parse length= annotation as
1636 a parameter name, not a raw int.
1639 2008-10-03 Colin Walters <walters@verbum.org>
1641 Bug 551744: Non-GObject types aren't aggregating ctors and methods
1643 * girepository/gtypelib.c: Allow ctors/methods on struct,union,
1645 * giscanner/glibtransformer.py: Ditto, and GLibBoxed is also a
1649 2008-10-03 Colin Walters <walters@verbum.org>
1651 Bug 554576: scan problem with ev_selection_render_selection()
1653 * giscanner/transformer.py: Only do type resolution once we've
1654 scanned all types. What could happen before is that we'd strip
1655 the namespace from local type "EvSelection" => Selection, and
1656 then later pull a "Selection" from some other namespace because
1657 we hadn't yet seen the local EvSelection. This could come
1658 down to hash table ordering and other things so not easy
1659 to write a test for.
1661 2008-10-03 Lucas Rocha <lucasr@gnome.org>
1663 * giscanner/girwriter.py (_parser_member): fix the last parameter of
1664 GLibEnumMember constructor as it should be the enum member nick.
1666 2008-10-02 Colin Walters <walters@verbum.org>
1668 Bug 552961: remove this parameter for methods
1670 * giscanner/glibtransformer.py: Delete this parameter; it is
1672 * girepository/ginvoke.c: Insert this parameter for methods.
1673 * girepository/gtypelib.c: Remove no longer needed verification of
1674 method this parameter.
1677 2008-09-30 Dan Winship <danw@gnome.org>
1679 Bug 554490: g-ir-scanner gets confused by '\\'
1681 * giscanner/scannerlexer.l (chartext, stringtext): fix use of
1682 backslashes so it will correctly parse '\\' and "\\"
1684 * tests/scanner/annotation.c: add a use of '\\' to make sure that
1687 * giscanner/glibtransformer.py (GLibTransformer.count_type): typo
1689 2008-10-02 Colin Walters <walters@verbum.org>
1691 bug 552393: Note variadic functions
1693 * giscanner/scannerparser.y: Parse ellipsis. Refactor grammar
1694 to use parameter_list directly.
1695 * giscanner/sourcescanner.h: Add ellipsis csymbol type.
1696 * giscanner/ast.py: Add Varargs type.
1697 * giscanner/transformer.py: Check for ellipsis symbol, transform
1699 * girepository/girnode.h: Add varargs flag to in-memory nodes.
1700 Parse varargs functions, but filter them out before we start
1701 compiling the typelib.
1703 2008-10-02 Colin Walters <walters@verbum.org>
1705 Bug 554632: type tag for GType
1707 * girepository/girepository.h, girepository/girepository.c:
1708 Add type tag for GType - it's a special type we don't want
1709 to resolve to just "long".
1710 * docs/typelib-format.txt: Update.
1711 * girepository/girparser.c: Parse it.
1712 * giscanner/glibtransformer.py: Ensure we don't put GType in
1714 * tools/generate.c: Remove hardcoded type list.
1717 2008-09-30 Dan Winship <danw@gnome.org>
1719 Bug 554521: scanner generates wrong names for enum members with
1720 full type name prefix
1722 * giscanner/utils.py (strip_common_prefix): Fix this to strip the
1723 right amount when the entire "first" string is a prefix of
1726 * tests/scanner/foo.h (FooEnumFullname):
1727 * tests/scanner/foo-expected.gir: test that
1729 2008-09-29 Colin Walters <walters@verbum.org>
1731 Bug 552380: Array parameters should be marked in the gir
1733 * giscanner/ast.py: Default char** to utf8[], and guchar* to
1734 uint8[]. Add Array, List, and Map subclasses of Type;
1735 these types can be generic. Return transfer defaults
1736 to true if return value is string or container type.
1737 Delete Sequence type.
1738 * giscanner/scannerlexer.l: Syntax change for annotations;
1739 use <> since it's more readable.
1740 * giscanner/girwriter.py: Write out these changes.
1741 * giscanner/girparser.py: Parse them.
1742 * giscanner/transformer.py: Have a defined set of
1743 both list and map types. When creating a type,
1744 check if the ctype we've parsed is one of them,
1745 if so create a container type subclass as appropriate.
1746 * girepository/girparser.c: Parse in generic types.
1749 2008-09-27 Colin Walters <walters@verbum.org>
1751 * tools/g-ir-scanner: Add --inject option.
1753 2008-09-25 Colin Walters <walters@verbum.org>
1755 Remove non-repository types from GIR
1757 * giscanner/ast.py: The canonical name is 'utf8', not
1759 * giscanner/glibast.py: A few more glib type mappings.
1760 * girepository/girparser.c: We only parse repository types.
1761 * tests/*.gir: Update.
1763 2008-09-23 Colin Walters <walters@verbum.org>
1765 Bug 552566: Add time_t type
1767 We need a type for time_t since it's special in C, and just
1768 mapping it to long precluded bindings from handling it
1771 2008-09-19 Colin Walters <walters@verbum.org>
1773 Bug 552390: Handle capitialization like "DBus" more robustly
1775 The to_underscores function was designed for use against prefixed
1776 names; we need a separate function which will convert names like
1777 DBusFoo into dbus_foo, not d_bus_foo.
1779 2008-09-19 Colin Walters <walters@verbum.org>
1781 Add check to make sure we're not hitting out unresolved types
1783 Validate the "this" argument for methods
1785 Remove heuristic matching of methods to classes based on prefix
1787 It was a broken hack that dated from when we handled underscoring
1788 and capitalization conventions less well.
1790 2008-09-18 Colin Walters <walters@verbum.org>
1792 Bug 552384: Use SHLIB_SUFFIX intead of G_MODULE_SUFFIX for Darwin
1794 On Darwin, the suffix for installed shared libraries (.dylib) is
1795 different from loadable modules (.so). We use a bit of magic shell
1796 script from Behdad Esfahbod to figure out the right suffix.
1798 2008-09-15 Johan Dahlin <johan@gnome.org>
1800 * giscanner/sourcescanner.py (SourceType.type_qualifier): Add
1801 a wrapper for type_qualifier as well.
1803 2008-09-15 Colin Walters <walters@verbum.org>
1805 http://bugzilla.gnome.org/show_bug.cgi?id=552065
1807 * giscanner/ast.py: Add deprecation attributes.
1808 * giscanner/girwriter.py: Write out deprecation data.
1809 * girepository/girparser.c: Relax parsing; deprecated
1810 attribute now includes freeform string.
1811 * giscanner/scannerlexer.l: Parse Deprecated.
1812 * giscanner/transformer.py: Look for deprecated attribute
1814 * tests/scanner/*: Add a Deprecated test.
1816 2008-09-14 Tor Lillqvist <tml@novell.com>
1818 * tests/scanner/Makefile.am (%.typelib): Use $(EXEEXT).
1820 2008-09-14 Colin Walters <walters@verbum.org>
1822 * giscanner/glibtransformer.py: Ignore functions with
1825 2008-09-12 Colin Walters <walters@verbum.org>
1827 * giscanner/glibtransformer.py: Accept Gtk.Type as GType.
1829 2008-09-12 Colin Walters <walters@verbum.org>
1831 * giscanner/ast.py: Bind pid_t to INT for vte.
1833 2008-09-12 Colin Walters <walters@verbum.org>
1835 * giscanner/girparser.py: Parse c:type for boxed records/unions.
1836 * giscanner/glibast.py: Avoid overwriting ctype.
1837 * giscsanner/transformer.py: Try resolving types using the GType names.
1839 2008-09-12 Colin Walters <walters@verbum.org>
1841 * giscanner/minixpath.py: Code to run an "XPath"
1842 assertion against an XML tree, taken from
1843 gir-repository/gir/tests.py.
1844 * giscanner/Makefile.am: Ship it.
1845 * tools/g-ir-scanner: Add --xpath-assertions option.
1846 * gir/GLib-assertions.txt: Add a few assertions.
1847 * gir/Makefile.am: Run them.
1849 2008-09-11 Colin Walters <walters@verbum.org>
1851 http://bugzilla.gnome.org/show_bug.cgi?id=551737
1853 * giscanner/transformer.py: Fix strip_namespace_func to only strip
1854 prefix if it ends with _. Tweak callback stripping to determine
1855 based on presence of _ whether we need to use strip_namespace_func
1856 or strip_namespace_object.
1858 2008-09-09 Owen Taylor <otaylor@redhat.com>
1860 * docs/typelib-format.txt: Wether => Whether
1862 2008-09-08 Colin Walters <walters@verbum.org>
1864 * girepository/girparser.c: Default to "readable" for properties.
1865 * giscanner/ast.py: Add readable, writable etc.
1866 * giscanner/girwriter.py: Writ them.
1867 * giscanner/glibtransformer.py: Inspect them.
1870 2008-09-07 Colin Walters <walters@verbum.org>
1872 * giscanner/cgobject.py: Add comment.
1874 2008-09-07 Colin Walters <walters@verbum.org>
1876 * giscanner/cgobject.py: Also call g_thread_init.
1878 2008-09-07 Colin Walters <walters@verbum.org>
1880 * giscanner/transformer.py: Fix regression by not
1881 stripping prefix before stripping namespace for unions
1884 2008-09-06 Colin Walters <walters@verbum.org>
1886 * giscanner/transformer.py: If a namespace contains
1887 multiple caps, try stripping both gnomekeyring_ and
1890 2008-09-07 Johan Dahlin <johan@gnome.org>
1892 Bug 551162 – giscanner does not recognize asm and __asm__
1893 * giscanner/scannerlexer.l:
1894 Patch by Jani Monoses.
1896 2008-09-06 Colin Walters <walters@verbum.org>
1898 * girepository/girnode.c: Allow gtype_name
1899 and gtype_init in struct and union.
1900 * girepository/girparser.c: Parse glib:
1901 boxed bits for both structure and union.
1902 * girepository/gtypelib.c: Don't barf
1903 if structure is boxed.
1904 * giscanner/girparser.py: Parse new XML
1906 * giscanner/girwriter.py: Write out new
1908 * giscanner/glibast.py: Define new classes
1909 which are both Boxed and Struct/Union, as
1910 well as an "Other" for everything else.
1911 * giscanner/glibtransformer.py: Handle
1912 boxed types specially; we try to merge
1913 them with a struct/union if one exists,
1914 otherwise fall back to generic boxed.
1916 * tools/generate.c: Write out new format.
1918 2008-09-06 Johan Dahlin <johan@gnome.org>
1920 * giscanner/grealpath.h: Include stdlib.h
1922 * docs/g-ir-generate.1: Remove leading %
1924 2008-09-01 Colin Walters <walters@verbum.org>
1926 * girepository/girparser.c: Look at c:type to determine
1927 whether or not an item is a pointer.
1929 2008-09-01 Johan Dahlin <johan@gnome.org>
1931 * tests/scanner/Makefile.am:
1932 Set PYTHONPATH so the scanner can run
1933 even if you didn't install anything.
1935 2008-09-01 Johan Dahlin <johan@gnome.org>
1938 Post-release version bump
1941 2008-09-01 Johan Dahlin <johan@gnome.org>
1945 2008-08-31 Colin Walters <walters@verbum.org>
1947 * giscanner/glibtransformer.py: Quiet info
1950 2008-08-31 Johan Dahlin <johan@gnome.org>
1953 Bump version to 0.5.0
1955 2008-08-31 Colin Walters <walters@verbum.org>
1957 * giscanner/glibtransformer.py: Follow aliases to ensure
1958 we don't get a constructor returning a basic type.
1959 * giscanner/transformer.py: Add function to follow aliases.
1962 2008-08-31 Johan Dahlin <johan@gnome.org>
1964 * giscanner/scannerlexer.l:
1965 * giscanner/scannerparser.y:
1966 * giscanner/sourcescanner.h:
1967 * giscanner/sourcescanner.py:
1968 Parse GCC extensions in the parser instead of just undeffing them
1969 in the pre-processor.
1971 2008-08-31 Johan Dahlin <johan@gnome.org>
1973 * giscanner/glibtransformer.py:
1974 Clean up a huge if. Do not add methods or constructors
1976 * giscanner/utils.py:
1977 second might be longer than first, check that.
1979 2008-08-31 Johan Dahlin <johan@gnome.org>
1984 2008-08-31 Colin Walters <walters@verbum.org>
1986 * girepository/girparser.c: Don't lose if we
1989 2008-08-31 Colin Walters <walters@verbum.org>
1991 * giscanner/glibtransformer.py: Look for libtool
1992 library in current directory
1993 * tests/scanner - Update.
1995 2008-08-30 Colin Walters <walters@verbum.org>
1997 * docs/typelib-format.txt: Add a guint32
1999 * gir/Makefile.am: Dep on Makefile
2000 * girepository/ginfo.c:
2001 * girepository/girepository.c: Clean up
2002 default typelib handling; remove global
2003 default_typelib variable. Ensure we handle
2004 NULL repository in more places.
2005 Support dependency resolution.
2006 Support lazy loading.
2007 * girepository/girepository.h: Remove
2008 g_irepository_unregister; we don't support
2009 unloading typelibs since really they're
2010 process-global. Update for lazy loading
2012 * girepository/girmodule.c: Use g_new0.
2013 Add dependencies to GirModule.
2014 * girepository/girparser.c: Parse dependencies.
2015 * girepository/gtypelib.c: Add 4 bytes for
2017 * tests/Makefile.am: Kill off gobject.gir,
2018 it conflicts with the real one.
2019 * tests/object.gir: Dep on GObject.
2020 * tools/generate.c: Take --includedir
2021 argument to say which directories to search
2022 for typelibs. Print out dependencies.
2024 2008-08-30 Colin Walters <walters@verbum.org>
2026 * giscanner/glibtransformer.py: Reduce warning noise.
2028 2008-08-29 Colin Walters <walters@verbum.org>
2030 * girepository/ginfo.c: Add some assertions regarding
2031 refcounts, just to be sure.
2032 * giscanner/glibtransformer.py: Blacklist a few more
2035 2008-08-29 Colin Walters <walters@verbum.org>
2037 * giscanner/glibtransformer.py: Blacklist a few
2038 functions that use GError oddly
2040 2008-08-29 Colin Walters <walters@verbum.org>
2042 * girepository/gtypelib.c: Don't crash if no
2045 2008-08-29 Colin Walters <walters@verbum.org>
2047 * girepository/girparser.c: Handle chains of aliases
2048 across modules by ensuring we fully qualify aliases
2051 2008-08-29 Colin Walters <walters@verbum.org>
2053 * girepository/girparser.c: Don't search aliases
2056 2008-08-29 Colin Walters <walters@verbum.org>
2058 * girepository/girparser.c: Rewrite type parsing
2059 to handle both GLib parsing case as well as correctly
2060 handling GLib.List and friends. Don't try to treat
2061 e.g. ListStore as a List.
2063 2008-08-29 Colin Walters <walters@verbum.org>
2065 * girepository/gtypelib.c: Add more context
2068 2008-08-29 Colin Walters <walters@verbum.org>
2070 * giscanner/glibtransformer.py: Add some informative
2071 logging messages in corner cases. Be sure we use
2072 the most recent node set instead of a cache
2073 when generating result set.
2074 * tests/: Remove duplicated bits in expected girs
2075 * girepository/girparser.c: Accept both List (for
2076 compiling GLib) and GLib.List (what the scanner
2079 * tools/generate.c: Generate canonical form.
2081 2008-08-29 Johan Dahlin <johan@gnome.org>
2083 * giscanner/config.py.in:
2084 Use datarootdir instead of datadir to avoid
2085 an autoconf warning.
2087 2008-08-29 Johan Dahlin <johan@gnome.org>
2091 * examples/gdk-pixbuf.gidl:
2093 Update and remove old cruft.
2095 2008-08-29 Johan Dahlin <johan@gnome.org>
2098 * docs/g-ir-compiler.1:
2099 * docs/g-ir-generate.1:
2100 * docs/g-ir-scanner.1:
2101 Add man pages for the generator and compiler.
2103 2008-08-29 Johan Dahlin <johan@gnome.org>
2105 * docs/g-ir-scanner.1: Document
2107 * giscanner/Makefile.am:
2108 * giscanner/gidlparser.py:
2109 * giscanner/gidlwriter.py:
2110 * tools/g-ir-scanner:
2111 Remove gidl support.
2113 2008-08-28 Colin Walters <walters@verbum.org>
2115 * tests/scanner/Makefile.am: Pass the right
2116 --includedir args. Add a Makefile dep.
2117 * tools/compiler.c: Pass includedirs down.
2118 * girepository/girparser.c: Actually put
2119 includedirs in context, pass down. Fix
2122 2008-08-28 Colin Walters <walters@verbum.org>
2124 * gir/Makefile.am: Use --includedir
2125 * girepository/girparser.c: Recursively parse
2126 includes to pull in aliases and expand them.
2127 We need this to avoid putting unknown names in
2129 * tools/compiler.c: Add --includedir option.
2130 * giscanner/ast.py: Map size/ssize to types
2133 2008-08-28 Tor Lillqvist <tml@novell.com>
2135 Make check now runs successfully on Windows.
2137 * tools/compiler.c (write_out_typelib): Use binary mode for output
2140 * girepository/girnode.c: Don't print NULL strings.
2142 * tests/invoke/Makefile.am
2143 * tests/scanner/Makefile.am: Use -no-undefined on Windows to
2144 convince libtool to build shared libraries.
2146 * tests/invoke/invoke.c: Don't needlessly include <dlfcn.h>. Use
2147 g_assert() instead of printing out expected errors.
2149 2008-08-28 Tor Lillqvist <tml@novell.com>
2151 * girepository/gtypelib.h: Change type of bitfield fields from
2152 guint to the most suitable smaller type. This makes the struct
2153 sizes match the ones on Linux that the sanity check expects when
2154 using gcc -mms-bitfields on Windows.
2156 2008-08-28 Johan Dahlin <johan@gnome.org>
2161 * giscanner/Makefile.am:
2162 * tests/Makefile.am:
2163 * tests/scanner/Makefile.am:
2164 Make distcheck pass.
2166 2008-08-27 Johan Dahlin <johan@gnome.org>
2168 * giscanner/Makefile.am:
2169 Only send in -no-undefined on Win32 as it breaks on MacOS X.
2171 2008-08-27 Tor Lillqvist <tml@novell.com>
2173 Make g-ir-scanner work on Windows. Still problems with the typelib
2174 code. Changes okayed by jdahlin.
2176 * configure.ac: Check for Windows, set Automake conditional
2177 OS_WIN32. Change backslashes to forward slashes in pyexecdir to
2178 avoid shell quoting issues
2180 * girepository/Makefile.am: Use -no-undefined so that libtool
2181 agrees to build a shared library on Windows.
2183 * girepository/girparser.c (backtrace_stderr): No backtrace() on
2184 Windows. Empty implementation on Windows so far.
2186 * girepository/gtypelib.c (g_typelib_check_sanity): Give more
2187 informative error message for the assertion failures. Tell also
2188 what the expected size of the struct is. Check all sizes first and
2189 fail afterwards if at least one size was different from expected.
2191 * tools/Makefile.am: Reorder libraries into proper logical
2194 * tools/generate.c: Don't include <dlfcn.h>, not used.
2196 * giscanner/Makefile.am: On Windows, link with the Python library,
2197 and install the module DLL as _giscanner.pyd. Remove the
2198 unnecessary import library and libtool library that libtool has
2201 * giscanner/scannerlexer.l: Recognize the gcc __attribute__ syntax
2202 and just skip it. Recognize also two "l" suffixes for long long
2203 constants. Recognize also __inline__.
2205 * giscanner/grealpath.h (g_realpath): Implement on Windows, using
2206 GetFullPathName(). As such, GetFullPathName() does more than the
2207 UNIX realpath(). It also changes relative paths into absolute
2208 paths. But for our purposes that shouldn't matter.
2210 * giscanner/giscannermodule.c (pygi_source_scanner_parse_file): On
2211 Windows the file descriptor passed to us is from Python. Python
2212 Python2.5 uses the msvcr71.dll C library, while mingw-built code
2213 uses msvcrt.dll. On Windows, file descriptors are specific to
2214 which C library is used. So we must find out what underlying OS
2215 handle corresponds to the file descriptor Python passes us, and
2216 then make that into a file descriptor valid for the C library this
2219 * giscanner/sourcescanner.py (_parse): Don't need to bypass
2220 __attribute__ as the lexer now handles it. The definition as empty
2221 was ineffective for mingw anyway, as mingw's _mingw.h undefines
2222 __attribute__. Close the temp file before unlinking it.
2224 * giscanner/cgobject.py: Use correct library name for the gobject
2227 * gir/Makefile.am: Must pass the full basename of the DLLs on
2228 Windows to g-ir-scanner. It's a bit ugly that we have to "know"
2229 that the names of the GLib DLLs are like libglib-2.0-0.dll, but in
2230 reality they won't change, until there is a GLib 3, and then also
2231 the Unix code here needs changing.
2233 Must pass CPPFLAGS to g-ir-scanner when building GLib.gir so that
2236 2008-08-26 Colin Walters <walters@verbum.org>
2238 * girepository/girepository.c: Search
2239 $DATADIR/girepository instead of
2240 $DATADIR/gitypelibs; this naming makes
2241 it clearer that e.g. jgir can install
2243 * gir/Makefile.am: Install there.
2245 2008-08-26 Colin Walters <walters@verbum.org>
2247 * girepository/gtypelib.c (_g_typelib_init): Also
2248 use G_MODULE_SUFFIX instead of hardcoding .so.
2250 2008-08-26 Colin Walters <walters@verbum.org>
2252 * girepository/gtypelib.c (_g_typelib_init): Free
2253 string in the right place.
2255 2008-08-26 Colin Walters <walters@verbum.org>
2257 * girepository/gtypelib.c (_g_typelib_init): Handle
2258 both .la and .so names; this works better in the
2259 uninstalled library case.
2261 2008-08-26 Johan Dahlin <johan@gnome.org>
2264 * giscanner/Makefile.am:
2265 * giscanner/cgobject.py:
2266 * giscanner/config.py.in:
2267 * giscanner/sourcescanner.py:
2268 Avoid undeffing __GNUC__, instead define
2269 __attribute__ & friends. Remove glibconfig.h hack.
2270 This makes gobject-introspection work better on
2271 MacOS X, Thanks to Richard Hult for kind help.
2273 2008-08-25 Colin Walters <walters@verbum.org>
2275 * giscanner/glibtransformer.py: Always print
2278 2008-08-25 Colin Walters <walters@verbum.org>
2280 * giscanner/glibtransformer.py: Skip over
2281 interfaces we don't know.
2283 2008-08-25 Colin Walters <walters@verbum.org>
2285 * girepository/girparser.c: Parse new implements
2286 syntax, drop gapi one.
2287 * tests/object.gir: Update.
2288 * tools/generate.c: Generate new syntax.
2290 2008-08-25 Colin Walters <walters@verbum.org>
2292 * giscanner/ast.py: Add interfaces property
2294 * giscanner/girwriter.py: Write out implemented
2296 * giscanner/glibtransformer.py: Introspect
2297 implemented interfaces.
2298 * tests/scanner/*: Make FooObject implement
2301 2008-08-25 Colin Walters <walters@verbum.org>
2303 * giscanner/glibtransformer.py: More correctly pair
2304 methods; if we have a symbol that starts with
2305 e.g. hippo_canvas look for a matching HippoCanvas
2306 class before accepting e.g. HippoCanvasImage.
2308 2008-08-24 Colin Walters <walters@verbum.org>
2310 * tools/g-ir-scanner: Filter out unknown options from
2313 2008-08-24 Colin Walters <walters@verbum.org>
2315 * giscanner/glibtransformer.py: Fail with better
2316 error if we can't find library.
2318 2008-08-24 Colin Walters <walters@verbum.org>
2320 * tools/g-ir-scanner: Use subprocess instead of
2321 commands, works on Windows and avoids the evil
2324 2008-08-24 Colin Walters <walters@verbum.org>
2326 * giscanner/glibtransformer.py: Skip over
2327 g_object_get_type from GLib trunk.
2329 2008-08-24 Colin Walters <walters@verbum.org>
2331 * girepository/girepository.c (g_irepository_require):
2332 Don't open shared library here; we already do it
2335 2008-08-24 Colin Walters <walters@verbum.org>
2337 * girepository/gtypelib.c: Add context stack so
2338 when we get an error we can print out nicely
2341 2008-08-24 Johan Dahlin <johan@gnome.org>
2343 * girepository/girparser.c (start_glib_boxed), (start_function),
2344 (start_field), (start_alias):
2345 Refactor a couple of parsing functions to be simpler to follow.
2348 2008-08-24 Johan Dahlin <johan@gnome.org>
2350 * girepository/girparser.c (start_function):
2351 Remove left-over code, checking type of function.
2353 2008-08-23 Colin Walters <walters@verbum.org>
2355 * giscanner/config.py: Define DATADIR.
2356 * giscanner/transformer.py: Look in DATADIR.
2358 2008-08-23 Colin Walters <walters@verbum.org>
2360 * girepository/gtypelib.c: Check constructor
2362 * girepository/girnode.c: Small tweaks.
2363 * girepository/ginfo.c: Calculate signature offsets
2365 * girepository/girparser.c: Remove duplicate
2367 * giscanner/glibtransformer.py: Avoid marking
2368 functions which return a basic type as
2371 2008-08-23 Colin Walters <walters@verbum.org>
2373 * girepository/girparser.c: Ignore <include>.
2374 * giscanner/girparser.py: Parse them.
2375 * giscanner/girwriter.py: Generate them.
2376 * giscanner/transformer.py: Process <include>
2377 recursively. Don't require full path for
2378 includes, look in {$XDG_DATA_DIRS}/gir.
2379 * tools/g-ir-scanner: Pass through includes.
2380 * Makefile.am: Remove extra --include
2382 * *-expected.gir: Add expected includes.
2384 2008-08-23 Johan Dahlin <johan@gnome.org>
2386 * tests/scanner/Makefile.am:
2387 * tests/scanner/annotation-expected.gir:
2388 * tests/scanner/drawable-expected.gir:
2389 Avoid duplication in the Makefile, regenerate with new
2390 namespaces (same as the filename)
2392 2008-08-22 Colin Walters <walters@verbum.org>
2394 * girepository/girnode.c: Don't hardcode integers,
2397 2008-08-22 Johan Dahlin <johan@gnome.org>
2399 * giscanner/sourcescanner.py:
2400 Check for ../gobject-introspection-1.0.pc.in to determine
2401 if we run installed or uninstalled.
2403 2008-08-22 Johan Dahlin <johan@gnome.org>
2406 * giscanner/sourcescanner.py:
2407 Send in undefs/defines via writing it directly to stdin
2408 of cpp instead of via arguments.
2410 2008-08-22 Colin Walters <walters@verbum.org>
2412 * tools/generate.c, tools/compiler.c: Default
2414 * all Makefile.am: Update.
2416 2008-08-22 Colin Walters <walters@verbum.org>
2418 * girepository/girparser.c: Pass through
2419 recursive types. Avoid overwriting errors.
2420 * giscanner/xmlwriter.py: Always write the
2422 * tests/*.gir: Adjust.
2423 * tests/scanner/Makefile.am: Build typelibs,
2424 and generate XML from those. Once we
2425 have a good diff mechanism...
2426 * tests/scanner/*-expected.gir: Add XML
2428 * tools/g-ir-scanner: Accept --typelib-xml
2430 * tools/generate.c: Better defaults for transfer.
2432 2008-08-22 Johan Dahlin <johan@gnome.org>
2436 * giscanner/Makefile.am:
2437 * giscanner/config.py.in:
2438 * giscanner/sourcescanner.py:
2439 Use the generated glibconfig.h for all scanner invokations.
2440 Rename it to glibconfig-scanner.h and install it.
2441 Add a config.py which so far contains the include dir.
2443 2008-08-22 Johan Dahlin <johan@gnome.org>
2446 Replace glibconfig.h with our own, do some replacement
2447 for CPP/C features we do not support
2449 2008-08-22 Colin Walters <walters@verbum.org>
2451 * tools/generate.c (write_callable_info): Fix unref
2454 2008-08-22 Colin Walters <walters@verbum.org>
2456 * gobject-introspection-1.0.pc.in: Add g-ir-generate.
2457 * tests/Makefile.am: Support $(DEBUG)
2458 * tools/generate.c: Do immediate close tags if no
2461 2008-08-21 Colin Walters <walters@verbum.org>
2463 * tests/scanner/drawable-expected.gir,
2464 * tests/scanner/drawable.c,
2465 * tests/scanner/drawable.h:
2468 2008-08-21 Colin Walters <walters@verbum.org>
2470 * giscanner/glibtransformer.py: Compute prefix
2471 by searching through the symbol for bits
2472 rather than going directly from ctype; this fixes
2475 2008-08-21 Colin Walters <walters@verbum.org>
2477 * giscanner/glibtransformer.py: Also try squashing
2478 underscores from namespace, fixes webkit_web_view_new.
2480 2008-08-21 Colin Walters <walters@verbum.org>
2482 * giscanner/glibtransformer.py: More ctor work,
2483 avoid having gtk_window_group_new end up under
2486 2008-08-21 Colin Walters <walters@verbum.org>
2488 * giscanner/glibtransformer.py: Much simpler approach
2489 of mapping uscored names to classes.
2490 * giscanner/utils.py: Remove unnecessary function.
2492 2008-08-21 Johan Dahlin <johan@gnome.org>
2494 * girepository/girepository.c (g_irepository_require):
2495 Plug memory leak and avoid using freed memory.
2496 Resolve the whole module path, here as well.
2498 2008-08-21 Colin Walters <walters@verbum.org>
2500 * giscanner/glibtransformer.py: Look up all permutations
2501 of class names when scanning methods/ctors based on
2502 the prefix instead of using the return value. This
2503 associates gtk_window_new with the right class.
2505 2008-08-21 Colin Walters <walters@verbum.org>
2507 * girepository/girmodule.c (g_ir_module_build_typelib):
2508 Revert change to increment header_size; we do that in
2511 2008-08-21 Colin Walters <walters@verbum.org>
2513 * girepository/girnode.c (write_string): Tweak to
2514 use UINT instead of INT. Not likely to matter.
2515 * girepository/girmodule.c (g_ir_module_build_typelib):
2516 Add to header_offset as well for header strings
2517 to match what write_string does.
2518 * girepository/gtypelib.c: Replace is_name with
2519 validate_name, which more strongly validates and
2520 handles errors in a better way. Update all callers.
2521 * giscanner/glibtransformer.py: Handle constructors
2524 2008-08-21 Johan Dahlin <johan@gnome.org>
2526 * gir/Makefile.am (typelibs_DATA): Build and
2527 install the Gio.typelib too
2529 * girepository/gtypelib.c (_g_typelib_init):
2530 Use g_module_build_path to resolve the shlib name
2532 2008-08-21 Colin Walters <walters@verbum.org>
2534 * gir/Makefile.am: CLEANFILES typelibs too.
2536 2008-08-21 Johan Dahlin <johan@gnome.org>
2538 * giscanner/glibtransformer.py:
2539 Do not send .la files through find_library.
2541 2008-08-21 Colin Walters <walters@verbum.org>
2543 * girepository/girparser.c (g_irepository_require):
2544 Fix one small leak in error case.
2546 2008-08-21 Johan Dahlin <johan@gnome.org>
2549 Parse glibconfig.h as well and install the compiled
2552 2008-08-21 Johan Dahlin <johan@gnome.org>
2555 * giscanner/glibtransformer.py:
2556 * tools/g-ir-scanner:
2557 Do not hard-core library names in the Makefile, reuse
2558 ctypes find_library instead.
2560 2008-08-21 Johan Dahlin <johan@gnome.org>
2562 * girepository/girparser.c (resolve_aliases):
2563 Remove compilation warnings
2565 2008-08-21 Johan Dahlin <johan@gnome.org>
2567 * girepository/girepository.c (g_irepository_require):
2568 Rewrap and fix double free bug by leaking a bit.
2570 2008-08-20 Colin Walters <walters@verbum.org>
2572 * girepository/girepository.c: Add new function
2573 g_irepository_get_typelib_path which tells
2574 us from where we loaded a namespace.
2576 2008-08-20 Colin Walters <walters@verbum.org>
2578 * tests/scanner/*-expected.gir: Adjust for
2579 added shared-library.
2580 * giscanner/giwriter.py: Make pylint happy.
2582 2008-08-20 Colin Walters <walters@verbum.org>
2584 * girepository/girmodule.c (g_ir_module_build_typelib):
2585 Calculate size correctly, avoid use-after-free.
2587 2008-08-20 Colin Walters <walters@verbum.org>
2589 * girepository/girepository.c: Remove
2590 g_irepository_register_file in favor of
2591 g_irepository_require. There are two
2592 possible deployment scenarios for typelibs:
2593 First, separate in $DATADIR/gitypelibs/. Second,
2594 they may be embedded in shlibs. However since
2595 the first is now the normal case, the API is
2596 optimized around it.
2598 Refactor internals to look up typelibs for
2599 namespaces just-in-time, but we expect
2600 consumers to call g_irepository_require.
2602 Also, add some docs. No one has died from that
2604 * gir/Makefile.am: Need --library for glib.
2605 * giscanner/girwriter.py: Write out shared-library.
2606 * tools/g-ir-writer: Take the first --library
2607 argument as the target of shared-library. In
2608 the future we should make this nicer with pkg-config
2611 2008-08-20 Colin Walters <walters@verbum.org>
2613 * girepository/girparser.py: And parse them.
2615 2008-08-20 Johan Dahlin <johan@gnome.org>
2617 * giscanner/glibast.py: Add gshort/gushort types
2619 2008-08-20 Colin Walters <walters@verbum.org>
2621 * gir/Makefile.am: Rename .gir files using GI namespace.
2622 * girepository/girepository.c: Use XDG_DATA_DIRS for
2623 looking up typelibs. Also typelibs are now suffixed
2625 * tests/invoke/Makefile.am: Only use metadata.
2626 * girepository/Makefile.am: Remove unnecessary include.
2627 * tests/scanner/Makefile.am: Update using GI namespaces
2628 for scanner includes.
2630 2008-08-20 Colin Walters <walters@verbum.org>
2632 * girepository/transformer.py: Suppress aliases whose
2634 * girepository/ast.py: Define some more aliases.
2636 2008-08-20 Colin Walters <walters@verbum.org>
2638 * girepository/girparser.c: Avoid alias infloops.
2640 2008-08-20 Colin Walters <walters@verbum.org>
2642 * tests/scanner/foo-expected.gir: Fix expected list type.
2644 2008-08-20 Johan Dahlin <johan@gnome.org>
2646 * giscanner/glibtransformer.py (GLibTransformer._resolve_type_name):
2647 Add a workaround for #548689.
2648 We can now compile gtk!
2650 2008-08-20 Colin Walters <walters@verbum.org>
2652 * giscanner/glibtransformer.py: Try to look up
2653 aliases using the c:type too.
2655 2008-08-20 Colin Walters <walters@verbum.org>
2657 * girepository/girparser.c: Parse union fields.
2659 2008-08-20 Johan Dahlin <johan@gnome.org>
2661 * giscanner/ast.py: Make time_t an alias for long
2663 * gir/gio-2.0-good.gir:
2664 * gir/glib-2.0-good.gir:
2665 * gir/gobject-2.0-good.gir:
2667 * giscanner/glibtransformer.py:
2668 Do not delete Class structures, we need them in gdk/gtk.
2669 * tests/scanner/drawable-expected.gir:
2670 * tests/scanner/foo-expected.gir:
2671 * tests/scanner/utility-expected.gir:
2674 2008-08-20 Johan Dahlin <johan@gnome.org>
2676 * tests/scanner/Makefile.am:
2677 * tests/scanner/annotation-expected.gir:
2678 * tests/scanner/annotation.c (annotation_object_class_init),
2679 (annotation_object_init), (annotation_object_method),
2680 (annotation_object_in), (annotation_object_out),
2681 (annotation_object_inout), (annotation_object_inout2),
2682 (annotation_object_inout3), (annotation_object_calleeowns),
2683 (annotation_object_calleesowns), (annotation_object_get_strings),
2684 (annotation_object_with_voidp), (annotation_object_get_objects),
2685 (annotation_object_create_object), (annotation_object_allow_none):
2686 * tests/scanner/annotation.h:
2687 * tests/scanner/foo-expected.gir:
2688 * tests/scanner/foo.c:
2689 * tests/scanner/foo.h:
2690 Split out annotation tests out of foo
2692 2008-08-20 Johan Dahlin <johan@gnome.org>
2694 * tests/scanner/Foo-expected.gir:
2695 * tests/scanner/Makefile.am:
2696 * tests/scanner/foo-expected.gir:
2697 * tests/scanner/foo-object.h:
2698 * tests/scanner/foo.c:
2699 Foo->foo, foo-object.h -> foo.h
2701 2008-08-20 Johan Dahlin <johan@gnome.org>
2703 * tests/scanner/Foo-expected.gir:
2704 * tests/scanner/Makefile.am:
2705 * tests/scanner/drawable-expected.gir:
2706 * tests/scanner/drawable.c (test_drawable_class_init),
2707 (test_drawable_init):
2708 * tests/scanner/drawable.h:
2709 * tests/scanner/foo-object.h:
2710 * tests/scanner/foo.c (foo_boxed_method):
2711 Move the drawable parts out of Foo to its own test.
2713 2008-08-20 Johan Dahlin <johan@gnome.org>
2715 * tests/scanner/Foo-expected.gir:
2716 * tests/scanner/foo-object.h:
2717 * tests/scanner/foo.c (foo_drawable_class_init),
2718 (foo_drawable_init):
2719 Add a based on GdkDrawable which generates
2722 2008-08-19 Colin Walters <walters@verbum.org>
2724 * giscanner/transformer.py: Don't try
2725 to strip prefix before namespace.
2727 2008-08-19 Johan Dahlin <johan@gnome.org>
2729 * giscanner/transformer.py:
2730 * tests/scanner/Foo-expected.gir:
2731 * tests/scanner/foo-object.h:
2732 Add support for typedef void foo type of
2735 2008-08-19 Johan Dahlin <johan@gnome.org>
2738 * giscanner/girwriter.py:
2739 * giscanner/glibtransformer.py:
2740 * giscanner/transformer.py:
2741 * tests/scanner/Foo-expected.gir:
2742 Add basic support for union, base the code much
2743 on Struct. Add a testcase.
2745 2008-08-19 Johan Dahlin <johan@gnome.org>
2747 * tests/scanner/Foo-expected.gir:
2748 * tests/scanner/foo-object.h:
2749 Add a union testcase which the compiler currently
2752 2008-08-19 Johan Dahlin <johan@gnome.org>
2754 * gobject-introspection-1.0.pc.in:
2755 Add a g_ir_compiler variable
2757 2008-08-19 Colin Walters <walters@verbum.org>
2759 * giscanner/ast.py: Rework types to be more closely
2761 * giscanner/girparser.py: Parse more bits.
2762 * giscanner/girwriter.py: Write sequences in a new
2763 way that specifies container type.
2764 * giscanner/glibast.py: Adjust for ast.py changes,
2765 add 'ctype' property to GLibObject and GLibInterface
2766 so we can look things up by it later.
2767 * gicanner/transformer.py: Names is new class holding
2768 the various namespaces we manage. Do not confuse
2769 with Namespace which is toplevel XML node effectively.
2770 Rework all type resolution to go through
2771 _resolve_type_name_1.
2772 * giscanner/glibtransformer.py: Raise UnknownTypeError
2773 instead of ValueError for cleanliness. Add Unresolved
2774 class to mark types whose parent we haven't seen yet.
2775 Use new Names object from transformer.py.
2776 Correctly look up parent=.
2777 Fix type validation to handle sequences.
2778 * tests/scanner/Foo-expected.gir: Update for sequence
2779 work, int instead of int32.
2780 * tools/g-ir-scanner: Add --noclosure option
2781 * gir/Makefile.am: Use --noclosure by default for
2784 2008-08-18 Johan Dahlin <johan@gnome.org>
2786 * gir/gio-2.0-good.gir:
2787 * gir/glib-2.0-good.gir:
2788 * gir/gobject-2.0-good.gir:
2791 2008-08-18 Johan Dahlin <johan@gnome.org>
2794 * giscanner/girparser.py:
2795 * giscanner/girwriter.py:
2796 * giscanner/glibast.py:
2797 * giscanner/glibtransformer.py:
2798 * giscanner/transformer.py:
2799 * tests/scanner/Foo-expected.gir:
2800 * tests/scanner/foo-object.h:
2801 * tests/scanner/utility-expected.gir:
2802 * tests/scanner/utility.h:
2803 Redo type resolving and validation.
2804 Add a couple of new tests.
2805 Patch mostly written by Colin.
2807 2008-08-18 Johan Dahlin <johan@gnome.org>
2810 * giscanner/girparser.py:
2812 * giscanner/transformer.py:
2813 Improve enum parsing for enums without a GType.
2814 Make flags/enum references to other girs work
2815 * giscanner/utils.py:
2817 * tests/scanner/Makefile.am:
2818 * tests/scanner/foo-object.h:
2819 * tests/scanner/utility-expected.gir:
2820 * tests/scanner/utility.h:
2821 Add a new test for external enum references
2823 2008-08-18 Johan Dahlin <johan@gnome.org>
2825 * docs/global-module-registry.txt: Update
2827 * tests/array.gir: Update with new type proposal
2829 * girepository/girepository.c (g_type_tag_to_string):
2830 * girepository/girepository.h:
2831 * girepository/girnode.c (g_ir_node_get_full_size_internal),
2833 * girepository/girnode.h:
2834 Make enum serializing functions public. Clean up some whitespace.
2836 2008-08-17 Johan Dahlin <johan@gnome.org>
2838 * docs/global-module-registry.txt:
2839 Add a document for an on disk module registry format
2841 2008-08-17 Johan Dahlin <johan@gnome.org>
2844 * gir/gio-2.0-good.gir:
2847 2008-08-17 Johan Dahlin <johan@gnome.org>
2850 * gir/glib-2.0-good.gir:
2851 * gir/gobject-2.0-good.gir:
2852 * giscanner/cgobject.py:
2853 * giscanner/glibtransformer.py:
2854 Regenerate GObject & GType.
2855 Avoid warnings when generating gobject-2.0.gir.
2856 Introspect a little more, and skip *_get_type functions.
2858 2008-08-17 Colin Walters <walters@verbum.org>
2860 * gir/glib-2.0.gir, gir/gobject-2.0.gir:
2861 Rename to -good, always generate during build.
2862 * gir/Makefile.am: Ensure .gir files dep on
2863 all scanner sources.
2864 * Makefile.am: Switch build order to ensure
2865 the scanner is ready before we do gir/.
2866 * tools/g-ir-scanner: Look for .git too.
2868 2008-08-17 Johan Dahlin <johan@gnome.org>
2870 * girepository/gtypelib.c (validate_enum_blob):
2871 * giscanner/glibtransformer.py:
2872 * giscanner/transformer.py:
2873 Remove resolve_possible_typedefs, it was unused.
2874 Allow multiple enum values of the sample value in an enum,
2875 since it's actually pretty common.
2876 Register enums so they can be resolved too.
2878 2008-08-16 Johan Dahlin <johan@gnome.org>
2880 * giscanner/girparser.py:
2881 Parse enumeration/bitfield.
2883 2008-08-16 Johan Dahlin <johan@gnome.org>
2885 * giscanner/girparser.py:
2888 2008-08-16 Johan Dahlin <johan@gnome.org>
2890 * giscanner/glibtransformer.py:
2891 Resolve type names for alias targets
2892 * giscanner/transformer.py:
2893 Skip FILE* parameters fow now
2895 2008-08-16 Johan Dahlin <johan@gnome.org>
2898 * gir/gobject-2.0.gir:
2901 * tests/scanner/Makefile.am:
2904 2008-08-15 Colin Walters <walters@verbum.org>
2906 * giscanner/glibtransformer.py: Explicitly construct
2907 new list, since we're deleting as we iterate.
2908 Don't delete all structures which end in Class; just
2909 ones which have a paired GObject.
2910 Fix printing of type warning.
2911 * giscanner/transformer.py: Make strip_namespace_object
2912 be the identity function if it doesn't match the
2915 2008-08-15 Colin Walters <walters@verbum.org>
2917 * giscanner/cgobject.py: Define yet more argument
2918 prototypes; fix prototype for g_type_fundamental.
2920 2008-08-14 Johan Dahlin <johan@gnome.org>
2922 * tests/Makefile.am:
2923 * tests/constant.gir:
2924 * tests/gobject.gir:
2926 * tools/generate.c (write_struct_info):
2927 Fix generator for constant/gobject/struct
2929 2008-08-14 Johan Dahlin <johan@gnome.org>
2931 * tests/Makefile.am:
2933 * tools/generate.c (write_enum_info):
2934 Fix generation of enum/bitfields
2936 2008-08-14 Johan Dahlin <johan@gnome.org>
2938 * girepository/girparser.c (start_field), (start_constant),
2939 (start_type), (end_element_handler):
2940 Clear up constant parsing
2945 * tools/generate.c (write_callable_info), (write_function_info),
2946 (write_callback_info), (write_constant_info), (write_signal_info),
2947 (write_vfunc_info), (write_property_info), (write_object_info),
2948 (write_interface_info):
2949 Constants/Signals are handled now.
2951 2008-08-14 Johan Dahlin <johan@gnome.org>
2953 * girepository/girparser.c (start_type):
2954 Don't require c:type.
2955 * tests/Makefile.am:
2958 Update, remove parts we don't support yet
2959 * tests/roundtrips.sh:
2961 * tools/generate.c (write_type_info), (write_field_info),
2962 (write_callable_info), (write_struct_info):
2963 Make it emit proper gir.
2965 2008-08-14 Johan Dahlin <johan@gnome.org>
2967 * giscanner/transformer.py:
2968 New internal function for adding a new node.
2970 2008-08-14 Johan Dahlin <johan@gnome.org>
2973 Define an internal _H_ variable so we skip parsing both
2974 i18n headers, only one is needed.
2976 Add the glib-2.0.gir too.
2977 * giscanner/glibast.py:
2978 Add gconstpointer as an alias for ANY
2979 * giscanner/transformer.py:
2980 Do not lower case enumeration names per se.
2981 Skip functions which has parameters called 'va_list'
2983 2008-08-14 Colin Walters <walters@verbum.org>
2985 * giscanner/transformer.py: Comment data structures.
2986 Also squash pointers in resolve_type_name to correspond
2987 with what we do for params.
2988 * giscanner/glibtransformer.py: Print warnings in more
2989 situations. Rework checks for method/constructor to
2990 look up in our GType database instead of just checking
2991 for *. Avoid generating <record> for GObject which
2992 duplicate the <class>.
2993 * gir/Makefile.am: Generate glib-2.0.gir and gobject-2.0.gir
2996 2008-08-14 Johan Dahlin <johan@gnome.org>
2998 * giscanner/girwriter.py:
2999 * giscanner/glibast.py:
3000 * giscanner/glibtransformer.py:
3001 * giscanner/transformer.py:
3003 * tests/Makefile.am:
3004 Add pyflakes.py and run it in make check.
3005 Update the source code to fix the errors reported by
3008 2008-08-14 Johan Dahlin <johan@gnome.org>
3011 * giscanner/girparser.py:
3012 * giscanner/glibast.py:
3013 * giscanner/glibtransformer.py:
3014 Refactor the parser a bit.
3015 Add parent type to interfaces and update callsites.
3017 2008-08-14 Johan Dahlin <johan@gnome.org>
3019 * giscanner/glibtransformer.py:
3020 * giscanner/utils.py:
3021 Refactor a bit, avoid isinstance and add a method
3022 for each type we parse.
3024 2008-08-14 Johan Dahlin <johan@gnome.org>
3027 * giscanner/girparser.py:
3028 * giscanner/glibtransformer.py:
3029 * tests/Makefile.am:
3030 Run pep8.py in make check, fix old errors.
3032 2008-08-13 Colin Walters <walters@verbum.org>
3034 * giscanner/girparser.py: Parse records.
3036 2008-08-13 Colin Walters <walters@verbum.org>
3038 * gir/Makefile.am: Install again.
3039 * gir/gobject-2.0.gir: Add some more bits.
3041 2008-08-13 Colin Walters <walters@verbum.org>
3043 * gir/gobject-2.0.gir: Use correct namespace, add GType.
3044 * giscanner/girparser.py: Handle aliases.
3045 * giscanner/transformer.py: Record aliases. Make resolver
3046 functions public; we now call into these explicitly from
3047 glibtransformer. Handle resolving aliases.
3048 * giscanner/glibtransformer.py: Separate our internal namespace
3049 from included ones. Call up into transformer's resolver functions.
3051 2008-08-13 Johan Dahlin <johan@gnome.org>
3053 * girepository/girnode.c (g_ir_node_get_full_size_internal):
3054 * girepository/girparser.c (start_class):
3055 * giscanner/glibtransformer.py:
3056 Allow get_type to be None, set a get_type for GInitiallyUnowned too.
3058 2008-08-13 Johan Dahlin <johan@gnome.org>
3060 * giscanner/cgobject.py:
3061 Register GInitiallyUnowned
3062 * giscanner/girwriter.py:
3063 * giscanner/glibtransformer.py:
3064 Special case GObject/GInitially owned as they are a bit special to use.
3066 2008-08-13 Colin Walters <walters@verbum.org>
3068 * tests/scanner/Foo-expected.gir, tests/scanner/utility-expected.gir:
3069 Object is in GObject namespace.
3071 2008-08-13 Colin Walters <walters@verbum.org>
3073 * giscanner/girparser.py: Fix processing of functions
3076 2008-08-13 Colin Walters <walters@verbum.org>
3078 * giscanner/girparser.py: Parse more than just <class.
3079 * giscanner/glibtransformer.py: Put aliases in a separate
3080 data structure since their name is not canonicall.
3081 * giscanner/transformer.py: Handle resolving type names
3084 2008-08-13 Johan Dahlin <johan@gnome.org>
3086 * tools/g-ir-scanner:
3087 Allow multiple libraries
3088 * giscanner/glibtransformer.py:
3089 Rename load_library to add_library, traverse over all libraries
3090 when trying to resolve a function
3092 2008-08-12 Colin Walters <walters@verbum.org>
3094 * giscanner/transformer.py: Record typedefs as <alias> elements.
3095 Also attempt to look up types in external namespaces.
3096 * giscanner/girwriter.py: Write them.
3097 * giscanner/glibtransformer.py: Rework resolver using real instanceof
3098 checks. Resolve interface methods and properties.
3099 * tests/scanner/foo-object.h: Add a method with typedef.
3100 * tests/scanner/Foo-expected.gir: Update.
3101 * girepository/girnode.c: Debug tweaks.
3102 * girepository/girparser.c: Make a first pass through the XML where we
3103 record all the aliases. This lets us resolve them as we go through the
3105 * gir/Makefile.am: Don't install gobject-2.0.gir; we want that to come
3106 from gir-repository.
3108 2008-08-12 Colin Walters <walters@verbum.org>
3110 * giscanner/glibtransformer.py: Resolve typedefs (e.g. AtkAttributeSet -> GSList).
3111 Correctly do subclasseing in 2nd pass resolution. Handle callbacks in structure
3113 * giscanner/transformer.py: Record typedefs and expose public API for resolving
3115 * tests/scanner/Foo-expected.gir: Fix expected callback types.
3117 2008-08-12 Colin Walters <walters@verbum.org>
3119 * giscanner/glibtransformer.py: Also transform object properties.
3121 2008-08-12 Colin Walters <walters@verbum.org>
3123 * giscanner/glibtransformer.py: Also transform callbacks
3124 and structure field types.
3125 * tests/scanner/Fooe-expected.gir: Update to expect correct
3126 names for callbacks and structs.
3128 2008-08-12 Colin Walters <walters@verbum.org>
3130 * girepository/girparser.c: Handle 'any'.
3131 * tests/scanner/Foo-expected.gir, tests/scanner/foo-object.h:
3132 Add test for void *.
3134 2008-08-12 Colin Walters <walters@verbum.org>
3136 * giscanner/glibtransformer.py: We need to do type
3137 resolution in a second pass after we've seen all the
3138 enums, records, etc.
3140 2008-08-12 Colin Walters <walters@verbum.org>
3142 * tests/scanner/Foo-expected.gir, tests/scanner/foo-object.h:
3143 Add enum return value.
3144 * giscanner/glibtransformer.py: Transform function return types
3147 2008-08-12 Colin Walters <walters@verbum.org>
3149 * tests/scanner/Makefile.am: Dep .gir files on scanner
3150 sources too. Also remove @ so we see scanner invocations.
3152 2008-08-12 Colin Walters <walters@verbum.org>
3154 * girepository/girparser.c, girepository/gtypelib.c,
3155 girepository/gtypelib.h, girepository/girnode.c:
3156 Remove usage of (GAPI-oriented) TypeTag in favor of
3157 GITypeTag from girepository.h.
3159 2008-08-10 Colin Walters <walters@verbum.org>
3161 * tests/roundtrips.sh: Use the correct tests.
3163 2008-08-10 Colin Walters <walters@verbum.org>
3165 * giscanner/cgobject.py: Declare/wrap a few more functions.
3166 Fix parameter types for g_object_new and g_type_fundamental.
3168 2008-08-10 Colin Walters <walters@verbum.org>
3170 * giscanner/cgobject.py: Add new decorator @gwrap which forces
3171 us to declare types for both return value and parameters. The
3172 ctypes default of 'int' is bad because it hides 32/64 bit
3173 problems. Convert all existing functions to use it.
3175 2008-08-09 Johan Dahlin <johan@gnome.org>
3177 * giscanner/__init__.py:
3179 * giscanner/cgobject.py:
3180 * giscanner/gidlparser.py:
3181 * giscanner/gidlwriter.py:
3182 * giscanner/girparser.py:
3183 * giscanner/girwriter.py:
3184 * giscanner/glibast.py:
3185 * giscanner/glibtransformer.py:
3186 * giscanner/odict.py:
3187 * giscanner/sourcescanner.py:
3188 * giscanner/transformer.py:
3189 * giscanner/utils.py:
3190 * giscanner/xmlwriter.py:
3191 * tools/g-ir-scanner:
3195 2008-08-09 Johan Dahlin <johan@gnome.org>
3198 * relaxng/c-types.xml:
3199 * relaxng/g-types.xml:
3200 * relaxng/relaxng.rng:
3202 Remove outdated relaxng schemas.
3204 2008-08-09 Johan Dahlin <johan@gnome.org>
3207 Rename metadata to typelib in variable names,
3210 2008-08-09 Johan Dahlin <johan@gnome.org>
3214 Remove old C scanner, which got rewritten in python.
3216 2008-08-09 Johan Dahlin <johan@gnome.org>
3218 * girepository/Makefile.am:
3219 * tools/Makefile.am:
3220 * tools/girmodule.c:
3221 * tools/girmodule.h:
3224 * tools/girparser.c:
3225 * tools/girparser.h:
3226 * tools/girwriter.c:
3227 * tools/girwriter.h:
3228 Move shared *.[ch] files to girepository from tools
3230 2008-08-09 Johan Dahlin <johan@gnome.org>
3232 * tests/Makefile.am:
3235 * tests/constant.test:
3237 * tests/errors.test:
3238 * tests/function.test:
3239 * tests/gobject.test:
3240 * tests/interface.test:
3241 * tests/object.test:
3242 * tests/struct.test:
3247 Rename *.test to *.gir
3249 2008-08-09 Johan Dahlin <johan@gnome.org>
3252 * tests/Makefile.am:
3253 * tests/parser/Foo-expected.gir:
3254 * tests/parser/Makefile.am:
3255 * tests/parser/foo-object.h:
3256 * tests/parser/foo.c:
3257 * tests/parser/utility-expected.gir:
3258 * tests/parser/utility.c:
3259 * tests/parser/utility.h:
3260 * tests/scanner/Makefile.am:
3261 Rename tests/parser to test/scanner
3263 2008-08-08 Colin Walters <walters@verbum.org>
3265 * tests/roundtrips.sh: Use local .gir files again.
3267 2008-08-08 Colin Walters <walters@verbum.org>
3269 * tests/invoke/Makefile.am: .gir file depends on libtool
3272 2008-08-08 Colin Walters <walters@verbum.org>
3274 * tools/girnode.c: Pass through parent node so we can
3275 print the node whose child is NULL, if that occurs.
3277 2008-08-08 Johan Dahlin <johan@gnome.org>
3279 * tests/Makefile.am:
3280 Disable roundtrip tests which are not yet working
3281 * tests/invoke/testfns.gir:
3284 2008-08-08 Johan Dahlin <johan@gnome.org>
3286 * giscanner/girwriter.py:
3288 * giscanner/glibast.py:
3289 * giscanner/glibtransformer.py:
3290 Swap order of members, to keep it consistent with
3293 2008-08-08 Johan Dahlin <johan@gnome.org>
3295 * girepository/gtypelib.c (validate_header):
3296 * girepository/gtypelib.h:
3298 * giscanner/girwriter.py:
3299 * giscanner/sourcescanner.c (gi_source_symbol_ref),
3300 (gi_source_symbol_unref):
3303 * tests/constant.test:
3305 * tests/errors.test:
3306 * tests/function.test:
3307 * tests/gobject.test:
3308 * tests/interface.test:
3309 * tests/invoke/Makefile.am:
3310 * tests/invoke/testfns.xml:
3311 * tests/object.test:
3312 * tests/parser/Makefile.am:
3313 * tests/roundtrips.sh:
3314 * tests/struct.test:
3319 * tools/Makefile.am:
3320 * tools/compiler.c (main):
3321 * tools/generate.c (write_callable_info), (write_function_info),
3323 * tools/gidlmodule.c:
3324 * tools/gidlmodule.h:
3327 * tools/gidlparser.c:
3328 * tools/gidlparser.h:
3329 * tools/gidlwriter.c:
3330 * tools/gidlwriter.h:
3331 * tools/scanner.c (create_node_from_gtype),
3332 (create_node_from_ctype), (g_igenerator_process_properties),
3333 (g_igenerator_process_signals), (g_igenerator_create_object),
3334 (g_igenerator_create_interface), (g_igenerator_create_boxed),
3335 (g_igenerator_create_enum), (g_igenerator_create_flags),
3336 (g_igenerator_process_function_symbol),
3337 (g_igenerator_process_unregistered_struct_typedef),
3338 (g_igenerator_process_struct_typedef),
3339 (g_igenerator_process_union_typedef),
3340 (g_igenerator_process_enum_typedef),
3341 (g_igenerator_process_function_typedef),
3342 (g_igenerator_process_constant), (g_igenerator_process_symbols),
3343 (g_igenerator_add_module), (g_igenerator_add_include_idl):
3344 Merge in the gir-compiler branch.
3345 Thanks to Philip and Colin for their help.
3347 2008-07-26 Colin Walters <walters@verbum.org>
3349 * tools/Makefile.am (bin_PROGRAMS): Install g-idl-compiler
3350 and g-idl-generate to go along with how we're changing this
3351 module to be installed.
3352 * gobject-introspection-1.0.pc.in: Set up Cflags and Libs.
3354 2008-07-24 Colin Walters <walters@verbum.org>
3356 * girepository/girepository.c (g_irepository_register): Add
3357 environment variable G_IREPOSITORY_VERBOSE so we can print
3358 out what we're doing.
3359 * girepository/girepository.c (g_irepository_register_file):
3360 Add GError error message to g_debug call.
3362 2008-07-08 Jürg Billeter <j@bitron.ch>
3364 * giscanner/glibast.py:
3368 2008-06-21 Johan Dahlin <jdahlin@async.com.br>
3370 * giscanner/girparser.py (GIRParser._parse_api): Ignore a few
3373 2008-06-20 Johan Dahlin <jdahlin@async.com.br>
3376 * giscanner/girwriter.py:
3377 * giscanner/transformer.py:
3378 * tests/parser/Foo-expected.gir:
3379 * tests/parser/foo-object.h:
3380 * tests/parser/foo.c (foo_object_allow_none):
3381 Add support for gtk-doc annotations for allow-none.
3384 2008-06-19 Johan Dahlin <jdahlin@async.com.br>
3387 * giscanner/girwriter.py:
3388 * giscanner/glibast.py:
3389 * giscanner/glibtransformer.py:
3390 * giscanner/transformer.py:
3391 * tests/parser/Foo-expected.gir:
3392 Start using abstract type instead of the raw C types.
3393 Register a bunch of glib types we care about.
3395 2008-06-19 Rob Taylor <rob.taylor@codethink.co.uk>
3400 2008-06-08 Philip Van Hoof <pvanhoof@gnome.org>
3402 * girepository/girepository.c:
3403 * girepository/gtypelib.c:
3404 * girepository/ginfo.c:
3405 * girepository/ginvoke.c:
3406 * girepository/girepository.h:
3407 * girepository/gtypelib.h:
3408 * girepository/gmetadata.c:
3409 * girepository/Makefile.am:
3410 * girepository/gmetadata.h:
3412 * tools/gidlmodule.c:
3415 * tools/gidlmodule.h:
3416 * tools/gidlparser.c:
3418 Renamed GMetadata to GTypelib
3420 2008-06-07 Johan Dahlin <jdahlin@async.com.br>
3422 * giscanner/xmlwriter.py:
3423 Improve line wrapping when > 79 charaters
3425 2008-06-05 Jürg Billeter <j@bitron.ch>
3428 * giscanner/girwriter.py:
3429 * giscanner/transformer.py:
3430 Use <type> element for field types
3431 * tests/parser/Foo-expected.gir:
3434 2008-06-04 Johan Dahlin <jdahlin@async.com.br>
3436 * giscanner/glibtransformer.py:
3437 Fix a bug which prevented GdkEvent from being generated
3439 2008-06-03 Johan Dahlin <jdahlin@async.com.br>
3441 * giscanner/Makefile.am:
3443 * giscanner/girwriter.py:
3444 * giscanner/glibast.py:
3445 * giscanner/glibtransformer.py:
3446 * giscanner/transformer.py:
3447 * giscanner/utils.py:
3448 * tests/parser/Foo-expected.gir:
3449 Improve enum member parsing and introspection
3451 2008-05-31 Johan Dahlin <jdahlin@async.com.br>
3453 * giscanner/scannerparser.y:
3454 * giscanner/sourcescanner.h:
3455 * giscanner/sourcescanner.py:
3456 Add a new source type enum for member.
3457 Use __repr__ for improved debugging
3458 * giscanner/girparser.py:
3460 * giscanner/transformer.py:
3461 Improve parsing of struct members.
3462 * tests/parser/foo-object.h:
3465 2008-05-31 Johan Dahlin <jdahlin@async.com.br>
3467 * giscanner/xmlwriter.py:
3468 Improve error reporting when trying to quote None.
3469 * giscanner/girparser.py:
3470 Do not print warnings when including more complete .gir files
3471 * giscanner/girwriter.py:
3472 Do not require a name for parameters, add a todo for singletons
3473 * giscanner/glibtransformer.py:
3474 Refactor the way structs are done, add a couple of hacks to allow
3476 * giscanner/transformer.py:
3477 Add enough hacks so cairo, atk and pango.gir can be parsed properly
3478 * gobject-introspection-1.0.pc.in:
3479 Export girdir, so we can access gobject-2.0.gir from outside
3481 2008-05-31 Johan Dahlin <jdahlin@async.com.br>
3483 * tools/g-ir-scanner:
3484 * tests/parser/Makefile.am:
3485 Update sys.path before running the parser so we don't have
3486 to setup PYTHONPATH ourselves.
3490 * girepository/Makefile.am:
3491 * giscanner/transformer.py:
3492 * gobject-introspection-1.0.pc.in:
3493 * gobject-introspection.pc.in:
3494 * tools/Makefile.am:
3496 Rename pkg-config name to gobject-introspection-1.0,
3497 Do not installed anything which is not using the gir format.
3498 Disable compililation the old C scanner, but still keep the source
3499 until all the remaning functionallity has been ported.
3501 2008-05-31 Johan Dahlin <jdahlin@async.com.br>
3503 * giscanner/giscannermodule.c (symbol_get_ident): Prevent
3504 a crash when symbol->indent is NULL.
3506 * giscanner/sourcescanner.py (ctype_name): Add ctype_name,
3507 a function to convert a CTYPE symbol to a string
3509 2008-05-24 Johan Dahlin <jdahlin@async.com.br>
3512 * giscanner/girwriter.py:
3513 * giscanner/giscannermodule.c
3514 (pygi_source_scanner_append_filename),
3515 (pygi_source_scanner_parse_file):
3516 * giscanner/glibtransformer.py:
3517 * giscanner/sourcescanner.py:
3518 Revert back to using temporary files to send in headers.
3519 Allow Functions to be passed in as callbacks, add a couple
3520 of try/excepts missing features.
3521 We can now scan pango
3523 2008-05-08 Johan Dahlin <johan@gnome.org>
3525 * giscanner/glibtransformer.py:
3526 * giscanner/transformer.py:
3527 Move namespace stripping glibtransformer->transformer
3529 2008-05-08 Johan Dahlin <johan@gnome.org>
3532 * giscanner/girwriter.py:
3533 * giscanner/glibtransformer.py:
3534 * giscanner/transformer.py:
3535 * tools/g-ir-scanner:
3536 Introduce a namespace ast node
3538 2008-05-05 Johan Dahlin <johan@gnome.org>
3540 * giscanner/__init__.py:
3541 * giscanner/sourcescanner.py:
3542 * giscanner/transformer.py:
3543 Move sourcescanner symbols to the sourcescanner module, instead
3544 of in the global __init__ namespace.
3546 2008-05-03 Johan Dahlin <johan@gnome.org>
3548 * giscanner/glibtransformer.py:
3549 * tools/g-ir-scanner:
3550 Handle missing parameters better, allow - and + in .la dlname
3553 2008-05-03 Johan Dahlin <johan@gnome.org>
3555 * giscanner/__init__.py:
3557 * giscanner/girwriter.py:
3558 * giscanner/glibtransformer.py:
3559 * giscanner/transformer.py:
3560 Parse struct fields properly, improve debugging.
3562 2008-04-29 Johan Dahlin <johan@gnome.org>
3565 * giscanner/girwriter.py:
3566 * giscanner/transformer.py:
3567 * tests/parser/Foo-expected.gir:
3569 Use transfer-ownership everywhere, to mark ownership/calle/caller etc.
3571 2008-04-29 Johan Dahlin <jdahlin@async.com.br>
3574 * docs/g-ir-scanner.1:
3575 * metadata-annotations-proposal.txt:
3576 * metadata-format.txt:
3577 Add a basic, unfinshed man page for g-ir-scanner, move documents into .txt
3579 2008-04-29 Johan Dahlin <jdahlin@async.com.br>
3581 * giscanner/girwriter.py:
3582 * giscanner/glibtransformer.py:
3583 * giscanner/transformer.py:
3584 * giscanner/xmlwriter.py:
3585 * tests/parser/Foo-expected.gir:
3586 * tests/parser/foo-object.h:
3587 Write record/structs to gir file too. Add a couple of tests,
3588 fix an off by one error in xmlwriter.py.
3590 2008-04-28 Johan Dahlin <johan@gnome.org>
3592 * giscanner/xmlwriter.py: Calculate the line length properly,
3593 include the provided extra indentation in the calculation, really.
3595 2008-04-28 Johan Dahlin <jdahlin@async.com.br>
3598 * giscanner/glibast.py:
3599 * giscanner/glibtransformer.py:
3600 * giscanner/transformer.py:
3601 * tools/g-ir-scanner:
3602 Add a --strip-prefix and sort out confusion between names and symbols
3603 for functions and struct + derivaties.
3604 Refactor bootstrap of g-ir-scanner, so we can set options on
3605 Transformer() before parsing everything.
3607 2008-04-28 Johan Dahlin <johan@gnome.org>
3609 * giscanner/transformer.py (Transformer._traverse_one): Avoid recursion
3610 when scanning girepository.h
3612 * giscanner/sourcescanner.py (SourceScanner._preprocess): Define
3613 a __GI_SCANNER__ when we run.
3615 2008-04-28 Johan Dahlin <jdahlin@async.com.br>
3618 * giscanner/girwriter.py:
3619 * giscanner/glibast.py:
3620 * giscanner/glibtransformer.py:
3621 * tests/parser/Foo-expected.gir:
3622 * tests/parser/utility-expected.gir:
3623 Rename most c:identifier to c:type. Add new ones to
3624 class/interface/enum/boxed.
3626 2008-04-28 Johan Dahlin <jdahlin@async.com.br>
3629 * giscanner/girwriter.py:
3630 * giscanner/glibtransformer.py:
3631 * tests/parser/Foo-expected.gidl:
3632 * tests/parser/Makefile.am:
3633 Move c:identifier from return-value to subchild type,
3634 as per Jürgs suggestion
3636 2008-04-28 Johan Dahlin <johan@gnome.org>
3638 * giscanner/girwriter.py:
3639 * tests/parser/Foo-expected.gir:
3640 Write property.type as a child node.
3642 2008-04-27 Johan Dahlin <johan@gnome.org>
3647 * gidl/gobject-2.0.gidl:
3649 * gir/gobject-2.0.gir:
3650 * tests/parser/Makefile.am:
3651 Replace the GObject gidl with a GObject gir.
3653 2008-04-27 Johan Dahlin <johan@gnome.org>
3655 * tools/Makefile.am (bin_SCRIPTS): g-ir-scanner is a script,
3658 * giscanner/xmlwriter.py:
3659 * tests/parser/Foo-expected.gir:
3660 Include indentation in line length calculation
3662 2008-04-27 Johan Dahlin <johan@gnome.org>
3664 * giscanner/girparser.py:
3665 Prettify NS parsing using elementtree.
3667 2008-04-27 Johan Dahlin <johan@gnome.org>
3670 * giscanner/Makefile.am:
3671 * giscanner/girparser.py:
3672 * giscanner/glibtransformer.py:
3673 * tests/parser/Foo-expected.gidl:
3674 * tests/parser/Foo-expected.gir:
3675 * tests/parser/Makefile.am:
3676 * tests/parser/utility-expected.gidl:
3677 * tests/parser/utility-expected.gir:
3678 * tools/g-ir-scanner:
3679 Switch over to GIR as the default format. Add a simple GIDL
3681 Update tests and fix simplify makefiles by depending
3682 on GNU make extensions.
3684 2008-04-27 Johan Dahlin <johan@gnome.org>
3686 * giscanner/xmlwriter.py:
3687 Wrap attributes for lines which are wider than 79 characters
3689 * giscanner/scannerlexer.l:
3690 Allow parenthesis in annotations
3693 * giscanner/gidlwriter.py:
3694 * giscanner/girwriter.py:
3695 * giscanner/glibtransformer.py:
3696 * giscanner/transformer.py:
3697 Add initial sequence support, including annotation.
3698 Refactor type handling a bit.
3700 2008-04-27 Johan Dahlin <johan@gnome.org>
3702 * tests/parser/Foo-expected.gidl:
3703 * tests/parser/foo-object.h:
3704 * tests/parser/foo.c (foo_object_class_init),
3705 (foo_object_get_strings), (foo_object_get_objects):
3706 Add two new functions to check sequence return values.
3707 Also fixes a compilation warning.
3709 2008-04-27 Johan Dahlin <johan@gnome.org>
3711 * giscanner/giscannermodule.c (]): Cast the getter, avoids
3712 a compilation warning.
3714 * tools/Makefile.am (g_ir_scanner_SOURCES):
3715 g-ir-scanner has no sources.
3717 2008-04-25 Johan Dahlin <johan@gnome.org>
3719 * giscanner/Makefile.am:
3721 * giscanner/gidlparser.py:
3722 * giscanner/gidlwriter.py:
3723 * giscanner/girwriter.py:
3724 * giscanner/glibast.py:
3725 * giscanner/glibtransformer.py:
3726 * giscanner/transformer.py:
3727 Split out nodes to ast.py and glibast.py
3729 2008-04-25 Johan Dahlin <jdahlin@async.com.br>
3731 * giscanner/Makefile.am:
3732 * giscanner/gidlparser.py:
3733 * giscanner/gidlwriter.py:
3734 * giscanner/girwriter.py:
3735 * giscanner/glibtransformer.py:
3736 * giscanner/gobjecttreebuilder.py:
3737 * giscanner/transformer.py:
3738 * giscanner/treebuilder.py:
3739 * tools/g-ir-scanner:
3740 Rename treebuilder to transformer and
3741 gobjectreebuilder to glibtransformer.
3743 2008-04-25 Johan Dahlin <jdahlin@async.com.br>
3745 * giscanner/Makefile.am:
3746 * giscanner/__init__.py:
3747 * giscanner/cgobject.py:
3748 * giscanner/gidlparser.py:
3749 * giscanner/gidlwriter.py:
3750 * giscanner/girwriter.py:
3751 * giscanner/gobjecttreebuilder.py:
3752 * giscanner/odict.py:
3753 * giscanner/sourcescanner.py:
3754 * giscanner/treebuilder.py:
3755 * giscanner/xmlwriter.py:
3756 * tools/Makefile.am:
3757 * tools/g-ir-scanner:
3758 Add LGPLv2 license header and install all python files
3760 2008-04-25 Johan Dahlin <jdahlin@async.com.br>
3763 * giscanner/gidlwriter.py:
3764 * giscanner/giscannermodule.c (pygi_source_directive_new),
3765 (directive_get_options), (pygi_source_symbol_new),
3766 (symbol_get_base_type), (pygi_source_type_new),
3767 (type_get_base_type), (type_get_child_list),
3768 (pygi_source_scanner_get_symbols),
3769 (pygi_source_scanner_get_directives):
3770 * giscanner/gobjecttreebuilder.py:
3771 * giscanner/sourcescanner.py:
3772 * giscanner/treebuilder.py:
3773 * tests/parser/foo-object.h:
3774 Add support for virtual methods.
3775 Pair struct FooClass with struct Foo.
3776 Clean up the SourceScanner bindings a bit.
3777 Add a testcase for virtual methods.
3779 2008-04-25 Johan Dahlin <jdahlin@async.com.br>
3781 * giscanner/cgobject.py:
3782 * giscanner/gidlwriter.py:
3783 * giscanner/gobjecttreebuilder.py:
3784 Add support for signals
3786 * tests/parser/foo.c (foo_object_class_init):
3787 * Foo-expected.gidl:
3788 Add a signal and update the expected output.
3790 2008-04-24 Johan Dahlin <jdahlin@async.com.br>
3792 * giscanner/gidlwriter.py:
3793 * giscanner/girwriter.py:
3794 * giscanner/giscannermodule.c (directive_get_name),
3795 (directive_get_value), (directive_get_options),
3796 (symbol_get_directives), (symbol_set_directives),
3797 (pygi_source_scanner_parse_file),
3798 (pygi_source_scanner_lex_filename),
3799 (pygi_source_scanner_get_directives), (init_giscanner):
3800 * giscanner/sourcescanner.c (gi_source_scanner_get_directives):
3801 * giscanner/sourcescanner.h:
3802 * giscanner/sourcescanner.py:
3803 * giscanner/treebuilder.py:
3804 * tools/g-ir-scanner:
3805 Add support for source/header annotations.
3807 2008-04-22 Johan Dahlin <jdahlin@async.com.br>
3809 * giscanner/gidlwriter.py:
3810 * giscanner/girwriter.py:
3811 * giscanner/gobjecttreebuilder.py:
3812 * giscanner/treebuilder.py:
3813 Add support for Callbacks
3815 2008-04-22 Havoc Pennington <hp@pobox.com>
3817 * girepository/ginvoke.c (g_function_info_invoke): If a symbol is
3818 not in metadata->module, look for it in the global module, in case
3819 some other object or the app itself provides the symbol.
3821 2008-04-22 Havoc Pennington <hp@pobox.com>
3823 * girepository/gmetadata.c (_g_metadata_init): hack to avoid
3824 dlopening a library that is already in the main app, by checking
3825 whether one of the lib's symbols is already loaded.
3827 2008-04-22 Johan Dahlin <jdahlin@async.com.br>
3829 * tests/parser/Foo-expected.gidl:
3830 * tests/parser/foo-object.h:
3833 2008-04-22 Havoc Pennington <hp@pobox.com>
3835 * girepository/ginfo.c (g_interface_info_find_method):
3836 Use interface_blob_size not object_blob_size to compute offset.
3838 2008-04-22 Havoc Pennington <hp@pobox.com>
3840 * girepository/gmetadata.c (_g_metadata_init): remove
3841 G_MODULE_BIND_LOCAL flag when loading libraries, since some libs
3842 (Glade and Clutter for example) rely on being loaded globally.
3844 2008-04-22 Havoc Pennington <hp@pobox.com>
3846 * girepository/ginfo.c (g_registered_type_info_get_g_type): new
3847 function to get the GType given a RegisteredTypeInfo
3849 2008-04-22 Johan Dahlin <johan@gnome.org>
3851 * COPYING: Add a LGPL license, to prevent automake to
3852 put in a copy of GPL here. Pointed out by Havoc.
3854 * girepository/ginfo.c (g_info_from_entry), (g_type_info_new),
3855 (g_type_info_is_pointer), (g_type_info_get_tag),
3856 (g_type_info_get_param_type), (g_type_info_get_interface),
3857 (g_type_info_get_array_length), (g_type_info_is_zero_terminated),
3858 (g_type_info_get_n_error_domains), (g_type_info_get_error_domain),
3859 (g_error_domain_info_get_codes), (g_enum_info_get_value),
3860 (g_object_info_get_interface), (g_object_info_get_field),
3861 (g_interface_info_get_prerequisite),
3862 (g_signal_info_get_class_closure), (g_constant_info_get_value):
3863 * girepository/ginvoke.c (get_ffi_type):
3864 * girepository/girepository.h:
3865 * girepository/gmetadata.c (g_metadata_get_dir_entry),
3866 (g_metadata_check_sanity), (validate_header),
3867 (validate_array_type_blob), (validate_iface_type_blob),
3868 (validate_param_type_blob), (validate_error_type_blob),
3869 (validate_type_blob), (validate_constant_blob),
3870 (validate_struct_blob), (validate_enum_blob):
3871 * girepository/gmetadata.h:
3872 * tests/Makefile.am:
3873 * tests/invoke/Makefile.am:
3874 * tests/invoke/invoke.c (main):
3875 * tests/roundtrips.sh:
3876 * tools/Makefile.am:
3877 * tools/compiler.c (format_output), (write_out_metadata), (main):
3878 * tools/generate.c (write_type_name), (write_type_info),
3879 (write_constant_value), (write_enum_info), (load_metadata), (main):
3880 * tools/gidlcompilercontext.c:
3881 * tools/gidlcompilercontext.h:
3882 * tools/gidlcompilerentrynode.c:
3883 * tools/gidlcompilerentrynode.h:
3884 * tools/gidlcompilertypenode.c:
3885 * tools/gidlcompilertypenode.h:
3886 * tools/gidlmodule.c (g_idl_module_build_metadata):
3887 * tools/gidlmodule.h:
3888 * tools/gidlnode.c (init_stats), (dump_stats),
3889 (g_idl_node_get_size), (g_idl_node_get_full_size),
3890 (g_idl_node_cmp), (g_idl_node_can_have_member),
3891 (g_idl_node_add_member), (g_idl_node_param_direction_string),
3892 (parse_int_value), (parse_uint_value), (parse_float_value),
3893 (parse_boolean_value), (find_entry_node), (find_entry),
3894 (serialize_type), (g_idl_node_build_metadata), (write_string):
3896 * tools/gidlparser.c (parse_type_internal):
3897 * tools/quote-file.sh:
3898 Revert revisions 157,149-148,136-129 and 120.
3899 Move back to using g-idl-generate to generate the metadata and
3900 avoids dependency on a c compiler.
3902 2008-04-22 Johan Dahlin <jdahlin@async.com.br>
3904 * giscanner/girwriter.py:
3905 * tools/g-ir-scanner:
3906 Add an initial GIR writer and a --format option to g-ir-scanner
3908 2008-04-21 Johan Dahlin <johan@gnome.org>
3910 * giscanner/cgobject.py: Use ctypes.util.find_library to locate
3911 gobject-2.0 and raise ImportError if not found.
3913 * giscanner/gidlparser.py:
3914 * giscanner/gidlwriter.py:
3915 * giscanner/gobjecttreebuilder.py:
3916 * tools/g-ir-scanner:
3917 Add a --include argument to include types from other idls.
3918 Add a minimalistic GIDL parser (just objects for now)
3919 Implement resolving of external type references and use it to
3920 resolve parent types, argument types and return types.
3922 2008-04-21 Johan Dahlin <johan@gnome.org>
3924 * giscanner/gidlwriter.py:
3925 * giscanner/gobjecttreebuilder.py:
3926 * giscanner/treebuilder.py:
3927 Add support for properties.
3928 Refactor Class/Interface support a bit, to share more code and
3929 always initialize their method attribute to an empty list.
3931 2008-04-21 Johan Dahlin <johan@gnome.org>
3933 * giscanner/cgobject.py:
3934 Add a workaround for a glib bug interface introspection bug
3935 (object_interface_list_properties, object_class_list_properties):
3936 Cast the return value to GParamSpec.
3938 * tests/parser/Foo-expected.gidl: Update
3939 * tests/parser/foo.c: Add a string property
3941 * giscanner/gobjecttreebuilder.py:
3942 After stripping namespaces, remove the original
3943 item to avoid duplication (GtkButton struct and Button object)
3945 2008-04-21 Johan Dahlin <johan@gnome.org>
3947 * giscanner/gobjecttreebuilder.py:
3948 * giscanner/treebuilder.py:
3949 Strip namespaces before objects, so we'll export
3950 GtkButton as Button in the gtk namespace
3952 2008-04-21 Johan Dahlin <johan@gnome.org>
3954 * giscanner/gidlwriter.py:
3955 * giscanner/gobjecttreebuilder.py:
3956 * giscanner/treebuilder.py:
3957 Add constructors for object/boxed types.
3959 2008-04-21 Johan Dahlin <johan@gnome.org>
3961 * giscanner/gidlwriter.py:
3962 * giscanner/gobjecttreebuilder.py:
3963 Add support for boxed types
3965 2008-04-21 Johan Dahlin <johan@gnome.org>
3967 * giscanner/giscannermodule.c: Mark structures as const,
3968 wrap SourceType.const_string.
3970 * tests/parser/foo-object.h: Add a couple of constants.
3972 * giscanner/gidlwriter.py:
3973 * giscanner/gobjecttreebuilder.py:
3974 * giscanner/treebuilder.py:
3975 Add basic support for interfaces
3977 * tools/g-ir-scanner:
3978 Add -o/--output for writing to a file
3980 2008-04-21 Havoc Pennington <hp@redhat.com>
3982 * TODO: add some C API wishlist items I could think of quickly
3984 2008-04-21 Johan Dahlin <jdahlin@async.com.br>
3986 * giscanner/gidlwriter.py:
3987 * giscanner/xmlwriter.py:
3988 Add a simple api for writing tags which can be used
3989 with the new 'with statement' in python 2.5
3991 2008-04-21 Johan Dahlin <johan@gnome.org>
3993 * giscanner/gobjecttreebuilder.py:
3994 Strip namespace and object prefix from method names.
3996 2008-04-21 Johan Dahlin <johan@gnome.org>
3998 * tools/g-ir-scanner (main): Add --pkg option to pass in
3999 pkg-config modules to get cflags from.
4001 * giscanner/gidlwriter.py (GIDLWriter._write_method):
4002 Avoid duplication, reuse function writer for methods.
4004 2008-04-21 Johan Dahlin <jdahlin@async.com.br>
4006 * giscanner/gidlwriter.py:
4007 * giscanner/gobjecttreebuilder.py:
4008 * giscanner/treebuilder.py:
4009 * tools/g-ir-scanner:
4010 Resolve libtool .la files.
4011 Strip name spaces for methods.
4012 Add function symbols
4014 2008-04-20 Johan Dahlin <jdahlin@async.com.br>
4016 * giscanner/cgobject.py:
4017 * giscanner/gidlwriter.py:
4018 * giscanner/gobjecttreebuilder.py:
4019 * giscanner/treebuilder.py:
4020 Add support for classes and methods
4022 2008-04-20 Johan Dahlin <johan@gnome.org>
4024 * giscanner/gidlwriter.py:
4025 * giscanner/gobjecttreebuilder.py:
4026 * giscanner/odict.py:
4027 Avoid conflicts, keep the output ordered similar to
4028 the order of the input.
4029 Add a simple ordered dictionary implemenation
4031 2008-04-19 Johan Dahlin <johan@gnome.org>
4033 * giscanner/cgobject.py:
4034 * giscanner/gidlwriter.py:
4035 * giscanner/gobjecttreebuilder.py:
4036 * tools/g-ir-scanner:
4037 Start introspecting get-type functions.
4038 Implement support for GLib/GFlags GTypes.
4039 Add a ctype based GObject binding.
4041 2008-04-18 Johan Dahlin <jdahlin@async.com.br>
4043 * giscanner/gidlwriter.py:
4044 * giscanner/xmlwriter.py:
4045 * tools/g-ir-scanner:
4046 Add a simplistic gidl writer, which can't do too much.
4048 2008-04-18 Johan Dahlin <johan@gnome.org>
4050 * giscanner/sourcescanner.py:
4051 * giscanner/treebuilder.py:
4052 * tools/g-ir-scanner:
4053 split tree building and source scanning interface to separate files.
4055 2008-04-18 Johan Dahlin <johan@gnome.org>
4057 * tools/g-ir-scanner (Parameter.__init__): Start constructing
4059 - Add support for struct/parameter/return, start parsing of ctypes
4061 * giscanner/giscannermodule.c: wrap GISourceType.child_list and
4064 2008-03-31 Johan Dahlin <johan@gnome.org>
4066 * tools/g-ir-scanner:
4067 Start to build abstract syntax node of scanned sources.
4068 Add support for cpp options.
4070 2008-03-27 Johan Dahlin <johan@gnome.org>
4072 * giscanner/giscannermodule.c:
4073 * giscanner/scannerlexer.l:
4074 * giscanner/sourcescanner.c:
4075 * tools/g-ir-scanner:
4077 Add simple pre-processor using subprocess and a PIPE.
4078 Change the parse_file apis to accept a file descriptor.
4080 2008-03-25 Johan Dahlin <johan@gnome.org>
4082 * giscanner/__init__.py:
4083 * tools/g-ir-scanner:
4084 Fix a typo and add an example python test program.
4086 2008-03-25 Johan Dahlin <johan@gnome.org>
4088 * giscanner/__init__.py:
4089 * giscanner/giscannermodule.c:
4090 * giscanner/sourcescanner.c:
4091 * giscanner/sourcescanner.h:
4092 Add constants and wrap a few more SymbolType fields
4094 2008-03-25 Johan Dahlin <johan@gnome.org>
4098 * giscanner/__init__.py:
4099 * giscanner/giscannermodule.c:
4100 * giscanner/Makefile.am:
4102 Add initial python bindings for the scanner and
4103 depend on python 2.5.
4105 2008-03-25 Johan Dahlin <johan@gnome.org>
4109 * giscanner/Makefile.am:
4110 * giscanner/sourcescanner.c:
4111 * giscanner/sourcescanner.h:
4112 * tools/Makefile.am:
4113 * tools/grealpath.h:
4114 * tools/sourcescanner.c:
4115 * tools/sourcescanner.h:
4117 Move the scanner to a separate library.
4119 2008-03-23 Johan Dahlin <johan@gnome.org>
4121 * tools/Makefile.am:
4124 * tools/scannerlexer.l:
4125 * tools/scannerparser.y:
4126 * tools/sourcescanner.c:
4127 * tools/sourcescanner.h:
4128 Split out the source scanner from the generator.
4129 Rename the symbols used in the scanner to use the gi_ prefix.
4130 This should make it possible to use the raw C parser from
4133 2008-03-23 Johan Dahlin <johan@gnome.org>
4135 * tests/parser/Makefile.am (utility.gidl):
4136 * tests/parser/utility-expected.gidl:
4137 Pass in the gobject.gidl since we're defining a GObject.
4139 2008-03-12 Johan Dahlin <johan@gnome.org>
4141 * relaxng/relaxng.rng:
4142 Add a releaxng in relaxng we can use to validate the relaxngs
4145 2008-03-12 Jürg Billeter <j@bitron.ch>
4147 * tools/scanner.c: (g_igenerator_new):
4148 * tools/scannerparser.y:
4149 Fix compiler warnings.
4151 2008-03-12 Jürg Billeter <j@bitron.ch>
4155 * tools/scannerparser.y:
4156 Start fixing memory management in g-idl-scanner.
4158 2008-03-12 Rob Taylor <rob.taylor@codethink.co.uk>
4160 * tools/gidlcompilercontext.c: (write_compiled):
4161 Fix critical warning when no shlib passed to g-idl-compiler.
4163 2008-03-12 Johan Dahlin <johan@gnome.org>
4165 * tests/parser/utility-expected.gidl:
4166 * tests/parser/utility.h:
4167 Add a get_type-function, so the scanner actually
4168 parses it as an object.
4170 2008-03-12 Johan Dahlin <johan@gnome.org>
4172 * tools/gidlwriter.c (function_generate): Add missing trailing quote.
4175 * tests/parser/Foo-expected.gidl:
4176 * tests/parser/Makefile.am:
4177 * tests/parser/foo-object.h:
4178 * tests/parser/foo.c:
4179 * tests/parser/utility-expected.gidl:
4180 * tests/parser/utility.c:
4181 * tests/parser/utility.h:
4183 Add a new gidl test. 'utility.gidl', which is used to be able
4184 to test external type references. Add a reference to UtilityObject*
4187 2008-03-11 Johan Dahlin <johan@gnome.org>
4191 Remove most global variables
4193 2008-03-11 Philip Van Hoof <me@pvanhoof.be>
4195 * tools/scannerlexer.l:
4197 * tests/parser/Foo-expected.gidl:
4198 * tests/parser/foo.c:
4199 * tests/parser/Makefile.am:
4200 * tests/parser/foo-object.h:
4202 Added a few extra tests. Which resulted in finding a few
4203 bugs. Which resulted in me fixing those bugs
4205 2008-03-11 Rob Taylor <rob.taylor@codethink.co.uk>
4207 * tools/gidlcompilercontext.c: (g_idl_compiler_write_dir_entry),
4208 (g_idl_compiler_write_xref_entry), (g_idl_compiler_add_xref):
4209 Add some comments for strings into generated output for
4212 2008-03-11 Rob Taylor <rob.taylor@codethink.co.uk>
4214 * tools/gidlcompilercontext.c: (write_compiled):
4215 Write out the shlibs variable before writing out the strings
4216 length. Fixes compiler warning when using '-l' flag with
4219 2008-03-11 Johan Dahlin <johan@gnome.org>
4221 * tests/parser/Foo-expected.gidl:
4222 * tests/parser/foo-object.h:
4225 * tools/scannerlexer.l:
4226 Add support for parsing return arguments. Add support for
4227 caller-owns return types.
4228 Patch by Philip Van Hoof.
4230 * tools/scannerparser.y:
4231 Remove parsing of the @deprecated syntax used in headers.
4232 We will support gtk-doc deprecation in the future instead.
4234 2008-03-11 Johan Dahlin <johan@gnome.org>
4236 * tools/compiler.c (main): Coding style fixes
4238 2008-03-10 Johan Dahlin <johan@gnome.org>
4241 Add GCOV_LIBS to GILIBS
4243 2008-03-10 Johan Dahlin <johan@gnome.org>
4245 * tests/parser/Foo-expected.gidl:
4246 * tests/parser/foo.c:
4247 Rename null-ok to direction=out
4249 2008-03-10 Philip Van Hoof <me@pvanhoof.be>
4251 reviewed and extensively tested by Johan
4253 * tests/parser/Foo-expected.gidl:
4254 * tests/parser/foo-object.h:
4255 * tests/parser/foo.c:
4258 * tools/gidlwriter.c:
4261 * tools/scannerlexer.l:
4262 * tools/scannerparser.y:
4264 Add support for scanning for gtk-doc comments inside
4265 C source files. Add tests
4267 2008-03-10 Johan Dahlin <johan@gnome.org>
4269 * tests/parser/Makefile.am:
4270 * tests/parser/foo.c:
4273 * tools/scannerparser.y:
4274 Add an api to lex filenames.
4275 Lex all source .c files passed in on the command line.
4276 Scan sources in a test and a couple of private structures
4277 which should not be included in the generated gidl
4279 2008-03-10 Johan Dahlin <johan@gnome.org>
4281 * tests/invoke/Makefile.am: Make the generated metadata
4282 depend on the g-idl-compiler
4284 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4286 * tools/gidlmodule.c
4287 * tools/gidlmodule.h
4290 Remove the old g-idl-compiler code.
4293 2008-02-22 Mark Doffman <mark.doffman@codethink.co.uk>
4295 * tools/quote-file.sh
4298 Move to using the 'C' struct compiler code.
4300 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4302 * girepository/ginfo.c
4304 Change the way that external references with no namespace
4305 are dealt with. External references with no namespace
4306 are placed into the XML as-if they are a local reference.
4307 This is temporary, but helps with roundtrip tests.
4309 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4311 * girepository/ginfo.c
4312 Add the ability to get the value of a constant of
4313 type TYPE_TAG_SYMBOL. In the case of a symbol the value
4314 is provided as a string.
4316 This would deal properly with:
4317 typedef char* random;
4318 const random = "A string";
4320 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4322 * girepository/ginfo.c
4323 * girepository/girepository.h
4325 Add a function to check if an enum is registered or not.
4326 Previously anything testing this relied on the g-type
4327 string offset having a value of 0.
4329 * girepository/gmetadata.c
4330 * girepository/gmetadata.h
4332 Remove unneccesary or erroneous checks. There were two
4333 metadata validation checks which made sure that the blob
4334 sizes were the same as some magic numbers compiled into the code.
4335 This is wrong as it breaks any forwards compatibility that may
4338 Checks were also present that made sure that unregistered type
4339 blobs had a value of 0 in the g-type offset field. This is
4340 unneccessary. If a type blob is unregistered then any value
4341 in its g-type field is simply invalid.
4343 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4345 * girepository/ginfo.c
4346 * girepository/gmetadata.c
4347 * girepository/gmetadata.h
4349 Change the metadata format to have a standard header
4350 for all the type blobs. Merge the SimpleTypeBlob
4351 and InterfaceTypeBlob into a union. A union of these
4352 two blobs existed previously but was not explicit
4353 in the metadata format.
4355 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4357 * tools/gidlcompilercontext.c
4358 * tools/gidlcompilercontext.h
4359 * tools/gidlcompilerentrynode.c
4360 * tools/gidlcompilerentrynode.h
4361 * tools/gidlcompilertypenode.c
4362 * tools/gidlcompilertypenode.h
4364 Add code to compile a tree of GIdlNodes to
4365 a 'C' struct representing the metadata.
4366 This is to aid cross-compiling. Previously
4367 the g-idl-compiler created a binary blob with
4368 data written in the byte order and alignment
4369 of the tool rather than the intended target.
4371 Cleaned up and improved by Johan and Robert :-)
4373 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4375 * girepository/ginvoke.c
4376 * girepository/girepository.h
4377 * girepository/gmetadata.c
4378 * girepository/gmetadata.h
4380 * tools/gidlparser.c
4381 Modify TYPE_TAG_INTERFACE to TYPE_TAG_SYMBOL
4382 to avoid confusion with the interface blob.
4385 * tools/gidlparser.c
4386 Remove magic numbers and replace with type-tag
4387 enumeration symbols.
4389 * girepository/gmetadata.c
4390 Add validate declaration.
4392 2008-03-10 Jürg Billeter <j@bitron.ch>
4394 * tools/gidlparser.c: (parse_type_internal):
4395 * tools/scannerlexer.l:
4396 * tools/scannerparser.y:
4397 Support C99 _Bool type in scanner.
4399 2008-03-10 Jürg Billeter <j@bitron.ch>
4401 * tests/parser/Foo-expected.gidl:
4402 * tests/parser/foo-object.h:
4403 * tests/parser/foo.c: (foo_enum_method):
4404 * tools/scanner.c: (g_igenerator_process_function_symbol):
4405 Don't skip functions that are defined in the namespace of a type
4406 that doesn't support methods, as for example enums.
4408 2008-03-10 Johan Dahlin <johan@gnome.org>
4410 * gidl.dtd: Remove, we're using relaxng for now
4412 * tests/parser/Foo-expected.gidl:
4413 * tests/parser/foo-object.h:
4414 * tests/parser/foo.c:
4415 Rename the enum/flags get_type functions to include the whole type.
4417 2008-03-08 Marc-Andre Lureau <marcandre.lureau@gmail.com>
4419 * tools/gidlwriter.c (enum_generate): added "type-name",
4420 "get-type" and "deprecated" missing arguments.
4421 * tests/parser/Foo-expected.gidl:
4422 * tests/parser/foo-object.h: test enum type, and no type.
4424 2008-03-06 Johan Dahlin <jdahlin@async.com.br>
4427 Consistent checks, add missing 'test'
4429 2008-03-05 Havoc Pennington <hp@redhat.com>
4431 * configure.ac: Take advantage of a libffi.pc if one exists, as it
4432 does on Fedora 8. Make libffi a hard requirement, since it was in
4433 practice anyway (was not really conditional in the code or
4434 makefile, only in configure).
4436 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4438 reviewed by: Rob Taylor <rob.taylor@codethink.co.uk>
4439 reviewed by: Johan Dahlin <johan@gnome.org>
4441 * tests/Makefile.am:
4442 * tests/roundtrips.sh:
4443 Modify the roundtrips test so that they do not use the
4444 --raw option of the gidl compiler but instead compile a
4445 shared library to use with g_module.
4447 * tests/invoke/Makefile.am:
4448 * tests/invoke/invoke.c:
4449 Modify the invoke tests to build a shared library rather
4450 than use the --raw option.
4452 * tests/invoke/invoke-namespace-find.sh: Removed:
4453 Noone knows why this was here, so removed.
4455 2008-02-19 Rob Taylor <rob.taylor@codethink.co.uk>
4457 * tools/scanner.c: (g_igenerator_process_function_symbol):
4458 Move g_idl_node_can_have_member test later, as it broke spotting
4459 get_type's for nodes that can't have members.
4461 2008-02-18 Rob Taylor <rob.taylor@codethink.co.uk>
4464 * tools/gidlnode.c: (g_idl_node_can_have_member):
4465 Add g_idl_node_can_have_member.
4467 * tools/scanner.c: (g_igenerator_process_function_symbol):
4468 Use g_idl_node_can_have_member to test if we should add a function
4469 as a member of the type node.
4471 2008-02-18 Rob Taylor <rob.taylor@codethink.co.uk>
4473 * gidl/GLib.gidl: Renamed to gidl/gobject-2.0.gidl:
4475 * tests/parser/Makefile.am:
4476 Rename GLib.gidl to gobject-2.0.gidl and install in /usr/share/gidl.
4478 2008-02-18 Rob Taylor <rob.taylor@codethink.co.uk>
4480 * tools/scanner.c: (main):
4481 Ignore -pthread when passed to g-idl-scanner.
4483 2008-02-18 Rob Taylor <rob.taylor@codethink.co.uk>
4485 * tools/grealpath.h: Added:
4486 * tools/scanner.c: (main):
4487 * tools/scannerlexer.l:
4488 * tools/Makefile.am:
4489 Always use absolute paths with symbolic links resolved when
4490 comparing filenames.
4492 2008-02-18 Rob Taylor <rob.taylor@codethink.co.uk>
4494 * gobject-introspection.pc.in:
4495 Provide variables for g-idl-parser, scanner and compiler in the
4498 2008-02-13 Rob Taylor <rob.taylor@codethink.co.uk>
4501 * girepository/Makefile.am:
4502 * tools/Makefile.am:
4503 Rename GCOV_SOURCES to GCOVSOURCES to top automake complaining.
4505 2008-02-10 Johan Dahlin <johan@gnome.org>
4507 * tests/parser/Foo-expected.gidl:
4508 * tests/parser/foo-object.h:
4509 * tests/parser/foo.c: (foo_boxed_copy), (foo_boxed_free),
4510 (foo_boxed_get_type), (foo_boxed_new), (foo_boxed_method):
4513 2008-02-10 Johan Dahlin <johan@gnome.org>
4515 * tests/parser/Foo-expected.gidl:
4516 * tests/parser/foo-object.h:
4517 * tests/parser/foo.c: (foo_enum_get_type), (foo_flags_get_type):
4518 Add enum and flags test.
4520 2008-02-10 Johan Dahlin <johan@gnome.org>
4524 * girepository/Makefile.am:
4525 Make 'make distcheck' work again.
4527 2008-02-10 Johan Dahlin <johan@gnome.org>
4529 * m4/Makefile.am (EXTRA_DIST): its called as-compiler-flag.m4,
4532 * tests/parser/Makefile.am: Only create Foo.gidl when running make
4533 check, eg exclude it from BUILT_SOURCES.
4535 2008-02-08 Rob Taylor <rob.taylor@codethink.co.uk>
4540 * girepository/Makefile.am:
4541 * m4/Makefile.am: Added:
4542 * m4/as-compiler-flag.m4: Added:
4543 * m4/gcov.m4: Added:
4544 * tools/Makefile.am:
4545 Add ability to generate a coverage report.
4546 Adds configure option --enable-gcov and make rule 'check-coverage'.
4548 2008-02-08 Rob Taylor <rob.taylor@codethink.co.uk>
4552 * gidl/Makefile.am: Added:
4553 * girepository/Makefile.am: Added:
4554 * src/Makefile.am: Renamed to tools/Makefile.am:
4555 * src/compiler.c: Renamed to tools/compiler.c:
4556 * src/g-idl-offsets.pl: Renamed to tools/g-idl-offsets.pl:
4557 * src/generate.c: Renamed to tools/generate.c:
4558 * src/gidlmodule.c: Renamed to tools/gidlmodule.c:
4559 * src/gidlmodule.h: Renamed to tools/gidlmodule.h:
4560 * src/gidlnode.c: Renamed to tools/gidlnode.c:
4561 * src/gidlnode.h: Renamed to tools/gidlnode.h:
4562 * src/gidlparser.c: Renamed to tools/gidlparser.c:
4563 * src/gidlparser.h: Renamed to tools/gidlparser.h:
4564 * src/gidlwriter.c: Renamed to tools/gidlwriter.c:
4565 * src/gidlwriter.h: Renamed to tools/gidlwriter.h:
4566 * src/ginfo.c: Renamed to girepository/ginfo.c:
4567 * src/ginvoke.c: Renamed to girepository/ginvoke.c:
4568 * src/girepository.c: Renamed to girepository/girepository.c:
4569 * src/girepository.h: Renamed to girepository/girepository.h:
4570 * src/gmetadata.c: Renamed to girepository/gmetadata.c:
4571 * src/gmetadata.h: Renamed to girepository/gmetadata.h:
4572 * src/scanner.c: Renamed to tools/scanner.c:
4573 * src/scanner.h: Renamed to tools/scanner.h:
4574 * src/scannerlexer.l: Renamed to tools/scannerlexer.l:
4575 * src/scannerparser.y: Renamed to tools/scannerparser.y:
4576 * tests/invoke/Makefile.am:
4577 Split src/ into girepository/ and tools/
4581 * girepository/Makefile.am:
4582 * tests/Makefile.am:
4583 * tests/invoke/Makefile.am:
4584 * tests/parser/Makefile.am:
4585 * tests/roundtrips.sh:
4586 * tools/Makefile.am:
4587 Make distcheck work.
4589 2008-02-04 Rob Taylor <rob.taylor@codethink.co.uk>
4591 * tests/invoke/invoke.c: (main):
4592 * tests/invoke/testfns.c: (test6), (test7):
4593 * tests/invoke/testfns.xml:
4594 Add tests for invokation with a GList argument.
4595 Also tests caller-owns return values.
4597 2008-02-04 Rob Taylor <robtaylor@floopily.org>
4600 Add some documentation for GICallableInfo
4602 2008-02-01 Mark Doffman <mark.doffman@codethink.co.uk>
4605 Correct syntax errors in the DTD file.
4607 * relaxng/c-types.xml:
4608 * relaxng/g-types.xml:
4610 Add a RelaxNG specification for the GObject Introspection XML data.
4611 The Specification has validated all of the test files.
4613 2008-01-25 Rob Taylor <robtaylor@floopily.org>
4615 * tests/roundtrips.sh:
4616 * tests/struct.test:
4617 Add roundtrip tests for structs.
4619 2008-01-11 Johan Dahlin <johan@gnome.org>
4621 * src/scanner.c (g_igenerator_process_function_symbol):
4622 Refactor out g_idle_node_add_member.
4623 (create_node_from_gtype, create_node_from_ctype):
4624 Use case instead of if...else
4625 (get_type_from_type_id):
4626 Rename to create_node_from_gtype
4627 (get_type_from_ctype):
4628 Rename to create_node_from_ctype
4630 Rename ginode -> node, gitype -> type, gifunc -> func.
4632 * src/gidlnode.c (g_idl_node_add_member, g_idl_node_cmp):
4633 Two new functions, refactor out of scanner.c
4635 * src/scanner.c: (g_igenerator_process_function_symbol):
4636 * src/scannerlexer.l:
4637 Do not save the content of the deprecated variable, only
4640 2008-01-11 Johan Dahlin <johan@gnome.org>
4642 * tests/parser/foo-object.h: Add a couple of comment parser tests.
4644 2008-01-11 Jürg Billeter <j@bitron.ch>
4646 * src/scannerlexer.l:
4647 Fix GTK-Doc parsing.
4649 2008-01-11 Jürg Billeter <j@bitron.ch>
4651 * src/scannerlexer.l:
4652 Fix GTK-Doc parsing.
4654 2008-01-11 Jürg Billeter <j@bitron.ch>
4656 * src/scanner.c: (lookup_symbol):
4657 Return unresolved name if we find unknown symbol.
4659 2008-01-11 Jürg Billeter <j@bitron.ch>
4661 * src/scanner.c: (g_igenerator_generate):
4662 Initialize GObject to fix scanning interface properties.
4664 * tests/parser/Foo-expected.gidl:
4665 * tests/parser/foo-object.h:
4666 * tests/parser/foo.c: (foo_interface_get_type):
4667 Test interfaces with GObject prerequisite.
4669 * tests/parser/Makefile.am:
4670 Set G_DEBUG=fatal_warnings to abort test on warnings and criticals.
4672 2007-12-27 Johan Dahlin <johan@gnome.org>
4674 * src/scannerlexer.l:
4675 Parse gtk-doc comments.
4677 * src/gidlwriter.c: (function_generate):
4678 Reorganize, avoid duplication and add support for
4679 writing deprecated functions.
4681 * src/scannerparser.y:
4683 Add new structure CDirective and functions to create/free them.
4685 * src/scanner.c: (g_igenerator_process_function_symbol),
4686 (g_igenerator_process_unregistered_struct_typedef),
4687 (g_igenerator_process_struct_typedef),
4688 (g_igenerator_process_union_typedef),
4689 (g_igenerator_process_enum_typedef),
4690 (g_igenerator_process_function_typedef), (g_igenerator_add_symbol),
4691 (g_igenerator_start_preprocessor):
4692 Parse @deprecated directive for functions.
4693 Remove some more C99isms.
4694 Send in -C to cpp to avoid stripping comments.
4696 * tests/parser/foo-object.h:
4697 * tests/parser/Foo-expected.gidl:
4698 Add deprecated directive
4700 2007-12-27 Johan Dahlin <johan@gnome.org>
4702 * src/scannerlexer.l (intsuffix): Add emacs mode line and
4703 escape ' and " so it looks more like C.
4706 Unlink temporary file used.
4708 2007-12-27 Johan Dahlin <johan@gnome.org>
4710 * src/scanner.c: (g_igenerator_new), (g_igenerator_free),
4711 (g_igenerator_start_preprocessor), (main):
4713 * src/scannerparser.y:
4714 Plug a couple of simple memory leaks.
4716 2007-12-27 Johan Dahlin <johan@gnome.org>
4718 * src/scanner.c: (g_igenerator_parse_macros),
4719 (g_igenerator_start_preprocessor), (g_igenerator_set_verbose),
4722 * src/scannerparser.y:
4723 * tests/parser/Makefile.am:
4725 Improve error reporting, return when the preprocessor fails.
4726 Add a verbose parameter, to aid debugging.
4727 Revert to using a temporary file to communicate between the
4728 preprocessor and the parser, because we need to wait for
4729 the exit code from the pre-processor before starting to parse.
4731 2007-12-16 Johan Dahlin <jdahlin@async.com.br>
4733 * src/Makefile.am: Rename clexer.l to scannerlexer.l and
4734 cparser.y to scannerparser.y
4736 2007-12-11 Johan Dahlin <johan@gnome.org>
4740 * src/scanner.c: (g_igenerator_new):
4742 Get rid of the global the_generator variable.
4744 2007-12-10 Johan Dahlin <johan@gnome.org>
4746 * src/scanner.c (main): Add an output option,
4747 add checks for required parameters
4750 set BUILD_SOURCES and CLEANFILES properly
4752 * src/gidlwriter.c: (g_writer_write_inline), (g_writer_write),
4753 (g_writer_write_indent), (g_writer_write_unindent),
4754 (field_generate), (value_generate), (constant_generate),
4755 (property_generate), (function_generate), (vfunc_generate),
4756 (signal_generate), (interface_generate), (struct_generate),
4757 (union_generate), (boxed_generate), (enum_generate),
4758 (node_generate), (g_writer_write_module), (g_idl_writer_save_file):
4760 * src/scanner.c: (g_igenerator_generate):
4762 * src/scannerwriter.c:
4764 Refactor scannerwriter to only be tied to a GIdlModule and move
4765 it (again!) to gidlwriter.c. Change the writer function to take
4768 2007-12-10 Johan Dahlin <johan@gnome.org>
4771 * src/scanner.c: (g_igenerator_generate):
4773 * src/scannerwriter.c: (g_igenerator_write_inline),
4774 (g_igenerator_write), (g_igenerator_write_indent),
4775 (g_igenerator_write_unindent), (field_generate), (value_generate),
4776 (constant_generate), (property_generate), (function_generate),
4777 (vfunc_generate), (signal_generate), (interface_generate),
4778 (struct_generate), (union_generate), (boxed_generate),
4779 (enum_generate), (node_generate), (module_generate),
4780 (g_scanner_write_file):
4782 Move the scanner gidl writing to a separate source file.
4784 2007-12-10 Johan Dahlin <johan@gnome.org>
4789 Move over all CType construction functions.
4791 * tests/parser/Makefile.am:
4792 Be verbose when printing parsing tests results.
4794 2007-12-10 Johan Dahlin <johan@gnome.org>
4796 * src/scanner.c (g_igenerator_start_preprocessor): Refactor
4797 preprocessor handling to here. Start cpp insteado of cc -E,
4798 always include -U__GNUC__, since it's specific to the preprocessor
4801 * tests/parser/Makefile.am (check-local): Silent diff and skip
4802 -U__GNUC__ which is always defined now
4804 2007-12-10 Johan Dahlin,,, <jdahlin@plasttroll>
4806 reviewed by: <delete if not using a buddy>
4808 * src/scanner.c: (g_igenerator_start_preprocessor), (main):
4809 * tests/parser/Makefile.am:
4811 2007-12-09 Johan Dahlin <johan@gnome.org>
4814 Use GOption for command line options.
4815 (g_igenerator_new, main): Simplify constructor and they way
4816 parameters are passed into it.
4822 * src/gen-introspect.c:
4823 * src/gen-introspect.h:
4825 Rename gen-introspect.[ch] to scanner.[ch]
4827 2007-12-09 Johan Dahlin <johan@gnome.org>
4831 * src/Makefile.am: Rename gen-introspect to g-idl-scanner,
4832 don't make the repository library and the other utilites link against
4835 * src/gen-introspect.c: (g_igenerator_create_object),
4836 (g_igenerator_create_interface), (g_igenerator_create_boxed),
4837 (g_igenerator_create_enum), (g_igenerator_create_flags),
4838 (g_igenerator_process_module_symbol),
4839 (g_igenerator_process_module), (g_igenerator_generate), (main):
4840 * src/gen-introspect.h:
4841 Refactor g_igenerator_process_types into smaller pieces.
4843 * tests/parser/Makefile.am:
4844 Depend on the gen-introspect binary
4846 2007-12-09 Johan Dahlin <johan@gnome.org>
4848 * src/gen-introspect.c (g_igenerator_process_types):
4849 Break into smaller pieces, one for each generated node type.
4851 2007-12-08 Johan Dahlin <johan@gnome.org>
4853 * src/gen-introspect.c: (g_igenerator_process_types),
4854 (g_igenerator_add_module):
4855 * tests/parser/Foo-expected.gidl:
4856 * tests/parser/foo-object.h:
4857 * tests/parser/foo.c: (foo_subobject_class_init),
4858 (foo_subobject_init):
4860 Add a subobject test and make sure to register defined classes
4861 in the lookup symbol hash table.
4863 2007-12-08 Johan Dahlin <johan@gnome.org>
4867 * src/gen-introspect.c: (g_igenerator_new), (lookup_symbol),
4868 (g_igenerator_process_types), (g_igenerator_add_module),
4869 (g_igenerator_add_include_idl), (main):
4870 * src/gen-introspect.h:
4871 * tests/parser/Makefile.am:
4872 * tests/parser/Foo-expected.gidl:
4874 Change the gen-introspect to generate namespaced module names,
4875 such as GLib.Object instead of GObject.
4876 Add a GLib.gidl which introduces GLib.Object and GLib.InitiallyUnowned,
4877 add a --include-idl parameter to gen-introspect,
4878 and update the parser test.
4880 2007-12-08 Johan Dahlin <johan@gnome.org>
4882 * src/gen-introspect.c:
4883 Move main to the end of the file and attempt to make it valid
4886 * tests/parser/Makefile.am (BUILT_SOURCES): Remove .repo here,
4887 we're not quite ready to generate metadata yet.
4892 Add a simple gen-introspect parser test
4894 2007-12-06 Gustavo J. A. M. Carneiro <gjc@gnome.org>
4896 reviewed by: Johan Dahlin <johan@gnome.org>
4899 * gobject-introspection.pc.in:
4901 * src/compiler.c: (format_output), (write_out_metadata), (main):
4902 * src/gen-introspect.c: (main):
4903 * src/gen-introspect.h:
4904 * src/generate.c: (write_callable_info), (write_repository),
4905 (load_metadata), (main):
4906 * src/gidlmodule.c: (g_idl_module_new),
4907 (g_idl_module_build_metadata):
4909 * src/gidlparser.c: (start_element_handler):
4910 * src/ginfo.c: (g_info_new), (g_info_from_entry),
4911 (g_base_info_get_name), (g_base_info_get_namespace),
4912 (g_base_info_is_deprecated), (g_base_info_get_annotation),
4913 (g_base_info_get_metadata), (g_function_info_get_symbol),
4914 (g_function_info_get_flags), (g_function_info_get_property),
4915 (g_function_info_get_vfunc), (signature_offset), (g_type_info_new),
4916 (g_callable_info_may_return_null),
4917 (g_callable_info_get_caller_owns), (g_callable_info_get_n_args),
4918 (g_callable_info_get_arg), (g_arg_info_get_direction),
4919 (g_arg_info_is_return_value), (g_arg_info_is_dipper),
4920 (g_arg_info_is_optional), (g_arg_info_may_be_null),
4921 (g_arg_info_get_ownership_transfer), (g_type_info_is_pointer),
4922 (g_type_info_get_tag), (g_type_info_get_param_type),
4923 (g_type_info_get_interface), (g_type_info_get_array_length),
4924 (g_type_info_is_zero_terminated),
4925 (g_type_info_get_n_error_domains), (g_type_info_get_error_domain),
4926 (g_error_domain_info_get_quark), (g_error_domain_info_get_codes),
4927 (g_value_info_get_value), (g_field_info_get_flags),
4928 (g_field_info_get_size), (g_field_info_get_offset),
4929 (g_registered_type_info_get_type_name),
4930 (g_registered_type_info_get_type_init),
4931 (g_struct_info_get_n_fields), (g_struct_info_get_field),
4932 (g_struct_info_get_n_methods), (g_struct_info_get_method),
4933 (find_method), (g_struct_info_find_method),
4934 (g_enum_info_get_n_values), (g_enum_info_get_value),
4935 (g_object_info_get_parent), (g_object_info_get_type_name),
4936 (g_object_info_get_type_init), (g_object_info_get_n_interfaces),
4937 (g_object_info_get_interface), (g_object_info_get_n_fields),
4938 (g_object_info_get_field), (g_object_info_get_n_properties),
4939 (g_object_info_get_property), (g_object_info_get_n_methods),
4940 (g_object_info_get_method), (g_object_info_find_method),
4941 (g_object_info_get_n_signals), (g_object_info_get_signal),
4942 (g_object_info_get_n_vfuncs), (g_object_info_get_vfunc),
4943 (g_object_info_get_n_constants), (g_object_info_get_constant),
4944 (g_interface_info_get_n_prerequisites),
4945 (g_interface_info_get_prerequisite),
4946 (g_interface_info_get_n_properties),
4947 (g_interface_info_get_property), (g_interface_info_get_n_methods),
4948 (g_interface_info_get_method), (g_interface_info_find_method),
4949 (g_interface_info_get_n_signals), (g_interface_info_get_signal),
4950 (g_interface_info_get_n_vfuncs), (g_interface_info_get_vfunc),
4951 (g_interface_info_get_n_constants),
4952 (g_interface_info_get_constant), (g_property_info_get_flags),
4953 (g_signal_info_get_flags), (g_signal_info_get_class_closure),
4954 (g_signal_info_true_stops_emit), (g_vfunc_info_get_flags),
4955 (g_vfunc_info_get_offset), (g_vfunc_info_get_signal),
4956 (g_constant_info_get_value), (g_union_info_get_n_fields),
4957 (g_union_info_get_field), (g_union_info_get_n_methods),
4958 (g_union_info_get_method), (g_union_info_is_discriminated),
4959 (g_union_info_get_discriminator_offset),
4960 (g_union_info_get_discriminator):
4961 * src/ginvoke.c: (g_function_info_invoke):
4962 * src/girepository.c: (g_irepository_register),
4963 (g_irepository_unregister), (g_irepository_get_default),
4964 (count_interfaces), (g_irepository_get_n_infos), (find_interface),
4965 (g_irepository_get_info), (g_irepository_find_by_name),
4966 (g_irepository_get_shared_library),
4967 (g_irepository_build_search_path), (g_irepository_register_file),
4968 (g_irepository_error_quark):
4969 * src/girepository.h:
4970 * src/gmetadata.c: (g_metadata_get_dir_entry),
4971 (g_metadata_check_sanity), (validate_header),
4972 (validate_array_type_blob), (validate_iface_type_blob),
4973 (validate_param_type_blob), (validate_error_type_blob),
4974 (validate_type_blob), (validate_arg_blob),
4975 (validate_signature_blob), (validate_function_blob),
4976 (validate_callback_blob), (validate_constant_blob),
4977 (validate_value_blob), (validate_field_blob),
4978 (validate_property_blob), (validate_signal_blob),
4979 (validate_vfunc_blob), (validate_struct_blob),
4980 (validate_enum_blob), (validate_object_blob),
4981 (validate_interface_blob), (validate_errordomain_blob),
4982 (validate_union_blob), (validate_blob), (validate_directory),
4983 (validate_annotations), (g_metadata_validate), (_g_metadata_init),
4984 (g_metadata_new_from_memory), (g_metadata_new_from_const_memory),
4985 (g_metadata_new_from_mapped_file), (g_metadata_free),
4986 (g_metadata_set_module), (g_metadata_get_namespace):
4988 * tests/Makefile.am:
4989 * tests/invoke/Makefile.am:
4990 * tests/invoke/invoke-namespace-find.sh:
4991 * tests/invoke/invoke.c: (main):
4993 Add a namespace/shared library mapping. fixes #313268.
4995 2007-12-03 Johan Dahlin <johan@gnome.org>
4997 * src/gidlparser.c (parse_type_internal): Disable char/gchar and
5000 2007-11-30 Jürg Billeter <j@bitron.ch>
5006 * src/gen-introspect.c: (g_idl_node_cmp), (g_igenerator_new),
5007 (g_igenerator_write_inline), (g_igenerator_write),
5008 (g_igenerator_write_indent), (g_igenerator_write_unindent),
5009 (field_generate), (value_generate), (constant_generate),
5010 (property_generate), (function_generate), (vfunc_generate),
5011 (signal_generate), (interface_generate), (struct_generate),
5012 (union_generate), (boxed_generate), (enum_generate),
5013 (node_generate), (module_generate), (get_type_from_type_id),
5014 (str_replace), (g_igenerator_process_properties),
5015 (g_igenerator_process_signals), (g_igenerator_process_types),
5016 (get_type_from_ctype), (g_igenerator_process_function_symbol),
5017 (g_igenerator_process_unregistered_struct_typedef),
5018 (g_igenerator_process_struct_typedef),
5019 (g_igenerator_process_union_typedef),
5020 (g_igenerator_process_enum_typedef),
5021 (g_igenerator_process_function_typedef),
5022 (g_igenerator_process_constant), (g_igenerator_process_symbols),
5023 (g_igenerator_add_symbol), (g_igenerator_is_typedef),
5024 (g_igenerator_generate), (main), (csymbol_new),
5025 (csymbol_get_const_boolean), (ctype_new), (ctype_copy),
5026 (cbasic_type_new), (ctypedef_new), (cstruct_new), (cunion_new),
5027 (cenum_new), (cpointer_new), (carray_new), (cfunction_new),
5028 (eat_hspace), (eat_line), (read_identifier),
5029 (g_igenerator_parse_macros):
5030 * src/gen-introspect.h:
5032 Import gen-introspect to generate introspection information by
5035 2007-11-30 Jürg Billeter <j@bitron.ch>
5037 * src/gidlnode.c: (g_idl_node_new): support creating callback nodes
5039 2007-11-30 Jürg Billeter <j@bitron.ch>
5041 * src/gidlparser.c: (end_element_handler): Don't leave requires
5044 2007-11-29 Johan Dahlin <johan@gnome.org>
5046 * src/gidlparser.c (parse_type_internal): Add char,
5047 gchar and guchar to the builtin types.
5049 2007-11-26 Johan Dahlin <johan@gnome.org>
5051 * src/ginfo.c: (g_object_info_get_type_name),
5052 (g_object_info_get_type_init):
5053 * src/girepository.c: (g_irepository_is_registered):
5054 * src/girepository.h:
5056 Add g_object_info_get_type_name, g_object_info_get_type_init and
5057 g_irepository_is_registered.
5059 2006-08-14 Jürg Billeter <j@bitron.ch>
5061 * src/gidlparser.c: (end_element_handler): Don't leave
5062 namespace and implements states too early.
5065 2007-11-26 Johan Dahlin <johan@gnome.org>
5067 * src/gmetadata.c (validate_struct_blob):
5068 pass blob_type to validate_function_blob instead of
5069 hard-coding BLOB_TYPE_STRUCT.
5071 Patch by Torsten Schoenfeld, fixes #314190
5073 2006-10-03 Torsten Schoenfeld <tsch@cvs.gnome.org>
5075 * src/compiler.c, src/generate.c, src/gidlnode.c,
5076 src/gidlparser.c, src/ginfo.c, src/girepository.c,
5077 tests/invoke/invoke.c, test/invoke/testfns.c: Hush compiler
5078 warnings about return values, signedness mismatches, unused
5079 variables, and unhandles enum values in switch statements.
5081 * tests/invoke/Makefile.am: Don't install the invoke test program.
5082 Add -I ../../src to the cflags used for the test functions files.
5084 2005-08-31 Torsten Schoenfeld <tsch@cvs.gnome.org>
5086 * src/girepository.h: Export g_invoke_error_quark.
5088 2005-08-31 Torsten Schoenfeld <tsch@cvs.gnome.org>
5090 * src/ginvoke.c: Remove the fallback implementation of
5091 g_function_info_invoke since we now formally depend on libffi.
5093 2005-07-25 Matthias Clasen <mclasen@redhat.com>
5095 * src/Makefile, tests/Makefile, tests/invoke/Makefile:
5096 Remove these files from cvs, as they are now generated.
5098 * src/gmetadata.c (validate_iface_type_blob): Don't
5099 complain if blob->pointer is not set, since that
5100 happens for enum and flag types. (#308935, Gustavo
5103 * Commit an autoconf-conversion patch by
5104 Gustavo Carneiro (#308708)
5106 2005-05-24 Matthias Clasen <mclasen@redhat.com>
5108 * src/compiler.c (main): Use it here to validate
5109 the generated metadata.
5111 * src/gmetadata.[hc]: Add code to validate a
5114 * metadata-format.txt: Updates
5116 2005-05-22 Matthias Clasen <mclasen@redhat.com>
5118 * tests/*: Add struct offsets to field and vfunc
5121 * src/generate.c (write_vfunc_info): Write offset
5122 information for vfuncs.
5124 * src/gidlnode.c (g_idl_node_build_metadata): Write
5125 the struct offsets into the metadata.
5127 * src/gidlparser.c: Parse the offset attributes of
5128 field and vfunc elements.
5130 * src/gidlnode.h: Add offset members to field and
5133 2005-05-21 Matthias Clasen <mclasen@redhat.com>
5137 * gidl.dtd: Updates.
5139 * src/g-idl-offsets.pl: A perl script which reads a .gidl
5140 file, creates, compiles and runs a C file, and folds the
5141 resulting struct offsets back into the .gidl file.
5143 2005-05-20 Matthias Clasen <mclasen@redhat.com>
5145 * src/gidlparser.c (start_field): Make fields in objects
5148 * src/gidlmodule.c: Include string.h
5153 * metadata-format.txt: Cleanup basic types.
5154 * src/*: Adapt to the changes.
5155 * tests/*: Adapt to the changes.
5156 * examples/gdk-pixbuf.gidl: Adapt to the changes.
5158 * src/gidlnode.c (g_idl_node_get_size): Report the correct
5159 size for enum blobs.
5160 (g_idl_node_get_full_size): Report the correct size for
5163 * src/gidlmodule.c (g_idl_module_build_metadata): Add some
5164 error checking for blob sizes.
5166 2005-05-19 Matthias Clasen <mclasen@redhat.com>
5168 * src/gidlnode.c (g_idl_node_build_metadata): Correctly handle
5169 interface types for which is_pointer is FALSE, e.g. enums.
5171 * src/gidlnode.c (g_idl_node_get_full_size)
5172 * src/gidlparser.c (parse_type_internal):
5173 * src/generate.c (write_type_info): Support unspecialized
5174 lists, hashtables and errors. Also emit a '*' after these.
5178 2005-05-17 Matthias Clasen <mclasen@redhat.com>
5182 * metadata-format.txt: Cleanups by Maciej Katafiasz.
5184 2005-05-15 Matthias Clasen <mclasen@redhat.com>
5186 * src/*.c: Change the directory to be addressed by
5187 1-based indexes, and use an index of zero to mean
5190 2005-05-15 Matthias Clasen <mclasen@redhat.com>
5192 * tests/roundtrips.sh (SIMPLE_TESTS): Add union.test.
5194 * tests/union.test: Add a union test.
5196 * src/generate.c: Handle unions.
5198 * src/girepository.h:
5199 * src/ginfo.c: Add GIUnionInfo and functions to access it.
5201 * src/gidlnode.c: Handle GIdlNodeUnion nodes.
5203 * src/gidlparser.c (start_union): Parse <union> elements.
5205 * src/gidlnode.h: Add a GIdlNodeUnion.
5207 * gidl.dtd: Add a <union> element.
5209 * src/gmetadata.c (g_metadata_check_sanity): Check
5212 * src/gmetadata.h: Add union_blob_size to Header,
5215 * metadata-format.txt: Add a UnionBlob.
5217 2005-05-13 Matthias Clasen <mclasen@redhat.com>
5219 * tests/*: Update testcases.
5221 * src/generate.c (write_callable_info): Don't forget to
5222 write transfer and null-ok attributes for return types
5225 * src/girepository.h:
5226 * src/ginfo.c (g_callable_info_may_return_null):
5227 New function to find out if a function may return NULL.
5229 * src/compiler.c (format_output): Make the generated
5232 * README: Point to a recent libffi snapshot.
5234 * tests/invoke/*: Some invoke tests.
5236 * src/Makefile: Add ginvoke.c and the necessary
5239 * src/girepository.h (g_function_info_invoke): Add
5242 * src/ginvoke.c (g_function_info_invoke): Initial
5243 implementation of invoke functionality based on libffi.
5245 * src/gidlnode.c (g_idl_node_build_metadata): Pass the
5246 strings and types hash tables in the right order when
5248 (find_entry_node): Free the name parts.
5250 2005-05-12 Johan Dahlin <johan@gnome.org>
5252 * src/generate.c: Generate consistent end tags.
5256 2005-05-12 Matthias Clasen <mclasen@redhat.com>
5260 * src/gidlparser.c (start_function): Actually add
5261 methods to objects. (Steven Walter)
5263 * src/girepository.h:
5264 * src/ginfo.c: Rename Transfer and Direction to
5265 GITransfer and GIDirection. (Torsten Schoenfeld)
5267 * tests/*: Make tests work with the changes in name
5270 * src/gidlnode.c (find_entry_node): Parse qualified
5271 names and generate xref nodes for them if needed. Don't
5272 require all modules to be loaded any more.
5274 * src/gidlmodule.c (g_idl_module_build_metadata): Choke
5277 * src/ginfo.c (g_object_info_get_parent): Return NULL
5278 if blob->parent is 0. Still need to make sure index
5281 * src/generate.c: Generate qualified names when
5282 referring to non-local types. Emit transfer attribute
5285 * src/compiler.c (format_output): Put the function
5286 attributes where gcc accepts them.
5288 2005-05-11 Matthias Clasen <mclasen@redhat.com>
5290 * src/compiler.c (main): Add a --verbose cmdline option
5291 and only log messages if it is specified.
5294 * src/gidlnode.c (init_stats, dump_stats): Collect some
5295 statistics on string and type sharing.
5297 * src/gidlmodule.c (g_idl_module_build_metadata): Use
5298 g_message() instead of fprintf().
5300 * src/gidlnode.c (g_idl_node_free): Make this more robust.
5301 (g_idl_node_get_size): Implement for structs.
5302 (g_idl_node_get_full_size): Handle parent being NULL.
5303 (serialize_type): Handle lookup failures more gracefully.
5305 2005-05-10 Matthias Clasen <mclasen@redhat.com>
5307 * src/gidlnode.c (g_idl_node_get_full_size): Correct the
5308 size calculation for 2-parameter types and for objects.
5310 * src/compiler.c: Add a cmdline option for debug output
5311 and install a log handler to implement it.
5312 * src/gidlnode.c: Add some debug spew.
5316 * src/gidlmodule.c (g_idl_module_build_metadata): Don't
5317 forget to count the module name when calculating the
5318 required size for the metadata.
5321 * src/gidlparser.c: Fix compiler warnings.
5323 2005-05-09 Matthias Clasen <mclasen@redhat.com>
5325 * src/compiler.c (main): Free the option context.
5327 * gidl.dtd: Clean up handling of names. All elements
5328 have a "name", only the elements corresponding to
5329 actual callable functions (function, method, constructor),
5330 have an additional "symbol" attribute holding the
5331 dlsym()-able function name.
5333 * src/generate.c: Adapt to generate xml matching the
5337 * src/gidlnode.c: Adapt to parse the new dtd.
5339 * tests/*.test: Adjust to the new dtd.
5341 * metadata-format.txt:
5342 * src/gmetadata.h: Remove the short_name field
5344 * src/gmetadata.c: Shrink size of ValueBlob to 12.
5345 * src/girepository.h:
5346 * src/ginfo.c (g_value_info_get_short_name): Removed
5348 2005-05-09 Matthias Clasen <mclasen@redhat.com>
5350 * gidl.dtd: Allow constructors for boxed types,
5351 patch by Jonathan Blandford.
5354 2005-05-09 Matthias Clasen <mclasen@redhat.com>
5356 * --- Initial import ---