1 2008-11-18 Tommi Komulainen <tommi.komulainen@iki.fi>
3 * tests/scanner/Makefile.am (barapp_SOURCES): fix builddir != srcdir
5 2008-11-18 Andreas Rottmann <a.rottmann@gmx.at>
7 * girepository/girnode.c (g_ir_node_build_typelib): Use sizeof()
8 instead of hard-coding struct sizes.
10 2008-11-18 Owen Taylor <otaylor@redhat.com>
12 Bug 561296 - Add "storage type" to the typelib data for enums
14 In order to set and get enum and flag fields in structures, we need
15 to know the integral type that the enumeration is stored as. We are already
16 computing that at compile time in order to compute struct offsets, so the
17 easiest thing to do is to save that in the typelib.
19 * docs/typelib-format.txt girepository/girnode.[ch] girepository/giroffsets.c
20 girepository/gtypelib.h: Add 'storage_type' to the typelib format for EnumBlob
21 and compute and save it at compile time.
23 * girepository/girepository.h girepository/ginfo.c:
24 Add g_enum_info_get_storage_type().
26 * girepository/gfield.c: Implement reading and writing enum and flags fields
27 based on the storage type.
29 2008-11-18 Owen Taylor <otaylor@redhat.com>
31 Add enums to the Everything test module
33 * tests/everything/everything.[ch]: Add TestEnum and TestFlags to the Everything
34 test module and register them as GTypes.
36 https://bugzilla.gnome.org/show_bug.cgi?id=561296
38 2008-11-18 Johan Dahlin <jdahlin@async.com.br>
40 * giscanner/cachestore.py:
41 Catch BadPickleGet exceptions as well.
43 2008-11-17 Owen Taylor <otaylor@redhat.com>
45 * tests/everything/everything.c: Fix doc comment annotations
46 for test_struct_b_clone() to refer to the right function.
48 2008-11-17 Dan Winship <danw@gnome.org>
50 * giscanner/glibtransformer.py (GLibTransformer.__init__): fix
51 spelling of GHashTable. #561135
53 * tests/scanner/annotation.c (annotation_object_get_hash):
54 * tests/scanner/annotation-1.0-expected.gir:
55 * tests/scanner/annotation-1.0-expected.tgir: add a test of
56 GHashTable annotations
58 2008-11-17 Andreas Rottmann <a.rottmann@gmx.at>
60 * giscanner/ast.py: Change string array match type to be in terms
61 of canonicalized type.
62 * giscanner/transformer.py: Add canonicalize_ctype which gives us
63 a version of a c:type without aliases, so we can deep canonicalize
64 char** to utf8*. Update parse_ctype to use it.
65 * tests/*: Add gtk_init like int*/char*** arg functions for testing.
67 2008-11-16 Colin Walters <walters@verbum.org>
69 * girepository/girepository.c: Ensure we always call init_globals,
70 even if passed a non-default repository.
72 2008-11-16 Colin Walters <walters@verbum.org>
74 Bug 559706 - Interface prerequisites
76 * common.mk: Dep on libgirepository.la for scanner libs so that
77 we rebuild things even if just gdump.c changes.
78 * girepository/gdump.c: Dump prerequisites.
79 * giscanner/ast.py: Add prerequisite list.
80 * giscanner/girparser.py: Parse them from gdump.
81 * giscanner/girwriter.py: Write them.
82 * giscanner/glibtransformer.py: Resolve them.
85 2008-11-16 Owen Taylor <otaylor@redhat.com>
87 Bug 561087 - Respect is_pointer in serialize_type()
89 Add a '*' to the serialization for the cases where we set is_pointer
90 in the type blob we write out depending on node->is_pointer. Don't
91 add the '*' in the cases where is_pointer is set or not set in a
94 http://bugzilla.gnome.org/show_bug.cgi?id=561087
96 2008-11-16 Owen Taylor <otaylor@redhat.com>
98 Bug 560825 – Add size and alignment to typelib
100 Include the size and alignment of structures and unions in the typelib,
101 and add getter methods to retrieve them from GIStructInfo/GIUnionInfo.
103 * docs/typelib-format.txt girepository/gtypelib.h girepository/girnode.c
104 girepository/girmodule.c girepository/gtypelib.c: Add size and alignment
105 to StructBlob and UnionBlob.
107 * girepository/ginfo.c girepository/girepository.h:
108 Add g_[struct|union]_get[size|alignment]().
110 * test/offsets/gen-gitestoffsets: Test overall structure size and alignment.
112 2008-11-16 Owen Taylor <otaylor@redhat.com>
114 Bug 552371 – implement struct field get/set
116 * girepository/gfield.c girepository/girepository.h: Add
117 convenience functions g_field_info_set_field() and
118 g_field_info_get_field() to set and get fields based on the
119 offsets in GIFieldInfo.
121 2008-11-16 Andreas Rottmann <a.rottmann@gmx.at>
123 Bug 560241 - Out-arguments should not be marked as being pointers
126 * girepository/girparser.c: Improved logic for out arguments.
128 2008-11-16 Andreas Rottmann <a.rottmann@gmx.at>
130 Bug 559601 - Pointers in structs/unions unduly treated as arrays
132 * giscanner/transformer.py: Differentiate type creation logic
133 between parameters and struct components.
135 2008-11-15 Colin Walters <walters@verbum.org>
137 * giscanner/dumper.py: Check return code from pkg-config
140 2008-11-14 Johan Dahlin <jdahlin@async.com.br>
142 * tests/everything/everything.c (test_array_int_in),
143 (test_array_gtype_in):
144 * tests/everything/everything.h:
145 Rename the int/gtype array tests. Make the return value
146 useful, an aggregation of the array input values.
148 2008-11-14 Johan Dahlin <jdahlin@async.com.br>
150 * tests/everything/Makefile.am:
151 * tests/everything/everything.c:
152 * tests/everything/everything.h:
153 * tests/everything/gitesttypes.c:
154 * tests/everything/gitesttypes.h:
155 Rename gitesttypes.[ch] to everything.[ch]
157 2008-11-13 Andreas Rottmann <a.rottmann@gmx.at>
159 Bug 560708 – Don't treat arrays that have a length specified as
160 zero-terminated by default
162 * giscanner/transformer.py: Default to non zero terminated for
164 * tests/*: Update, add test for zero vs not.
166 2008-11-13 Andreas Rottmann <a.rottmann@gmx.at>
168 Bug 557788 - Return types for constructors in generated typelib bogus
170 * girepository/girnode.c: Namespace-qualify XREFs; not doing so is
171 obviously broken in the face of duplicate names in different
173 * tests/scanner/*expected.gir: Fix up.
175 2008-11-13 Owen Taylor <otaylor@redhat.com>
177 * girepository/girffi.c: Fix "Unexpected time for time_t"
180 2008-11-13 Colin Walters <walters@verbum.org>
182 Bug 558436 - avoid having scanner load app code
184 * giscanner/cgobject.py: Delete; we no longer load shared
186 * giscanner/dumper.py: Support for linking a library to
187 a stub binary for introspection.
188 * giscanner/glibtransformer.py: Rewrite to use gdump XML
189 from invocation of child binary.
190 * giscanner/transformer.py: Fix up to use fully qualified
191 name in parse tree. Make parse_ctype public so we can use
192 it inside glibtransformer.
193 * tests/scanner/barapp.c: New test, using --program arg
195 * tests/*: Update to use common.mk for invoking scanner.
196 * tools/g-ir-scanner: Add options --program, --program-arg,
198 * docs/g-ir-scanner.1: Update.
200 2008-11-13 Colin Walters <walters@verbum.org>
202 * configure.ac: Depend on Gio, we use it in gdump.c.
203 * girepository/gdump.c: Code to dump GType data to XML.
204 * girepository/girepository.c: Add option group for dumping.
205 * girepository/girepository.h: Define API for the above.
207 2008-11-13 Colin Walters <walters@verbum.org>
209 * common.mk: Add a file to include with Makefile fragments
210 useful for scanner invocation.
212 2008-11-13 Tommi Komulainen <tommi.komulainen@iki.fi>
214 * tests/everything/gitesttypes.c (test_filename_return): Return
215 strings in filename encoding.
217 2008-11-13 Owen Taylor <otaylor@redhat.com>
219 Bug 560253 – Add structure and boxed types to Everything test module
221 * tests/everything/gitesttypes.[ch]: Add examples of:
223 Plain old data structs
224 Plain old data structs with nested fields
226 Plain old data boxed with nested fields
227 More complicated boxed types with internal state
229 2008-11-12 Johan Dahlin <jdahlin@async.com.br>
231 * tests/everything/gitesttypes.c (test_gtype_in):
232 * tests/everything/gitesttypes.h:
233 Add a test of GType arrays, a la gtk_list_store_set_columns.
235 2008-11-12 Owen Taylor <otaylor@redhat.com>
237 Bug 560419 – Cache includes when parsing
239 Keep track of all modules parsed within a GIrParser, and when a
240 module is referenced a second time, use the existing parsed copy
241 instead of reparsing.
243 2008-11-12 Owen Taylor <otaylor@redhat.com>
245 Fix management of ParseContext.includes_modules (#560419)
247 * girepository/girparser.c: Fix some trivial bugs in managing the
248 list of include modules. (Add to module's list twice, not
249 initialized to NULL, not freed.)
251 2008-11-12 Owen Taylor <otaylor@redhat.com>
253 Keep aliases and disguised_structures local to each module (#560419)
255 * girepository/girmodule.[ch]: When parsing, keep keep a separate
256 hash tables of aliases and 'disguised' flags for each module, and
257 store that on the module.
259 After parsing an include merge the aliases/disguised flags to the
262 * girepository/girparser.c: Remove 'prefix_aliases' flag and
263 always prefix aliases/disguised structure types when parsing; this
264 simplifies the code considerably.
266 2008-11-12 Owen Taylor <otaylor@redhat.com>
268 Fix mismatches between .gir name and 'name' attribute (#560419)
270 * tests/boxed.gir tests/constant.gir tests/enum.gir tests/invoke/invoke.c
271 tests/invoke/testfns-1.0.gir tests/object.gir tests/struct.gir: Fix places
272 where the 'name' element of <namespace/> didn't match the filename of the
273 gir, an assumption that the compiler has always expected and now enforces.
275 2008-11-12 Owen Taylor <otaylor@redhat.com>
277 Only allow one <namespace/> element per <repository/> (#560419)
279 * girepository/girparser.c: The logic in girparser.c didn't work
280 very well if there were multiple <namespace/> nodes within a
281 single <repository/> (context->namespace was always the overall
282 filename and not the the name specified in the <namespace/>
283 element for one thing; this would cause aliases to be mis-prefixed
284 in include modules.) Also check that the "name" in the
285 <namespace/> node matches the filename.
287 2008-11-12 Owen Taylor <otaylor@redhat.com>
289 Add a GirParser object to hold the state of a compilation
291 * girepository/girparser.[ch] tools/compiler.c: Add a toplevel
292 GirParser object to hold state that is global across a
293 compilation. Currently just holds the include path, but will
294 eventually also keep a cached list of parsed modules.
296 2008-11-12 Tommi Komulainen <tommi.komulainen@iki.fi>
298 * girepository/girepository.c (find_namespace_latest): Fix
301 2008-11-12 Tommi Komulainen <tommi.komulainen@iki.fi>
303 * configure.ac: use 'introspection' component for bugs
305 2008-11-12 Johan Dahlin <jdahlin@async.com.br>
307 * tests/everything/gitesttypes.c (test_filename_return):
308 * tests/everything/gitesttypes.h:
309 Add a filename return test.
311 2008-11-12 Tommi Komulainen <tommi.komulainen@iki.fi>
313 * tests/offsets/Makefile.am (gitestoffsets.c): fix
314 gen-gitestoffsets invocation with builddir != srcdir
316 2008-11-12 Johan Dahlin <jdahlin@async.com.br>
318 * girepository/girepository.c:
319 Change the element type from utf8 to filename
320 * girepository/girnode.c (g_ir_node_build_typelib):
321 Special case filename equally to utf8 here.
323 2008-11-12 Johan Dahlin <jdahlin@async.com.br>
326 Remove unused variables, add a dependency of girepository.ch, so when
327 they change we rebuild the gir automatically.
329 2008-11-12 Johan Dahlin <jdahlin@async.com.br>
331 * girepository/girepository.c (g_irepository_get_search_path):
332 * girepository/girepository.h:
333 Add a g_irepository_get_search_path, so we can access the search
336 2008-11-12 Johan Bilien <jobi@via.ecp.fr>
338 Bug 560474 – g-ir-compiler crashes when compiling the glib gir
340 * girepository/girparser.c: avoid freeing an uninitialized pointer
342 2008-11-12 Johan Dahlin <jdahlin@async.com.br>
345 * giscanner/glibtransformer.py:
346 * tools/g-ir-scanner:
347 Add a GIRepository-2.0.gir. Change the libtool lookup slightly
348 so we can just pass in --library=foo/bar/baz.la and the scanner
349 does the right thing.
350 Don't warn for _get_type() functions if they don't take any
353 2008-11-11 Owen Taylor <otaylor@redhat.com>
355 Bug 560404 – Prefix types when resolving aliases in included modules
357 * girepository/girparser.c: When resolving aliases in an included
358 module, prefix types before looking them up.
360 2008-11-11 Owen Taylor <otaylor@redhat.com>
362 Compute field offsets and overall size for object structures
364 Bug 560326 – Fails to build Gtk-2.0.typelib with "Unexpected non-pointer
365 field of type object in structure"
367 Do basic computation of field offsets for objects and interfaces;
368 this doesn't attempt to address all of the "mess" for virtual
369 functions described in Bug 560281.
371 2008-11-11 Tommi Komulainen <tommi.komulainen@iki.fi>
373 Bug 560308 – g-ir-compiler goes in infinite loop on Gdk-2.0.gir
375 Based on patch by Johan Bilien.
377 * giscanner/transformer.py (_create_member, _create_parameter):
378 Resolve types here as well.
379 (_resolve_type_name_1): Try resolving using 'ctype' first since
380 it's least ambiguous. Fixes struct member type resolution with
381 similarly named types, e.g. Gdk.PangoRendererClass and
383 * tests/scanner/foo*: Add test.
385 2008-11-11 Owen Taylor <otaylor@redhat.com>
387 * girepository/girparser.c: Search provided include dirs before
388 the default directories.
390 2008-11-11 Owen Taylor <otaylor@redhat.com>
392 * girepository/giroffsets.c: Include fully-qualified names in
395 2008-11-11 Owen Taylor <otaylor@redhat.com>
397 * girepository/giroffsets.c: Fail gracefully with an informative
398 error message when recursion is encountered when computing a
401 2008-11-11 Owen Taylor <otaylor@redhat.com>
403 * girepository/girparser.c: Remove an unused variable.
405 2008-11-10 Owen Taylor <otaylor@redhat.com>
407 Add tests for field offset computations
409 * tests/offsets/offsets.h: Header file with structure definitions to test
411 * tests/offsets/gen-gitestoffsets: Generate a C program that computes
412 field offsets for the structures in offsets.h two ways: using
413 the information from a generated typelib, and as computed by the
416 We diff these two versions to test that everything is OK.
418 2008-11-10 Owen Taylor <otaylor@redhat.com>
420 Remove field offsets from g-ir-generate output and test inputs
422 Field offsets are a) architecture dependent so they shouldn't be part
423 of the architecture-independent gir format which is installed in
424 datadir. b) Are architecture-dependent so they shouldn't be in test
427 * girepository/girparser.c: Don't parse offset for fields
428 * tools/generate.c: Don't parse offset for fields
429 * tests/*.gir test/scanner/*.tgir: Remove offsets
431 (Virtual function and discriminator offsets are not removed, as they
432 aren't fully hooked up to the field-offset computation machinery yet.)
434 2008-11-10 Owen Taylor <otaylor@redhat.com>
436 Bug 560252 - Compute field offsets before writing typelib
438 * girepository/girnode.h: Store the total size and alignment for
439 GIrNodeStruct/Boxed/Union.
441 * girepository/giroffset.c: New file implementing computation of
442 structure field offsets.
444 * girepository/girnode.c: Compute structure field offsets before
445 writing types into the typelib.
447 * docs/typelib-format.txt: Document that a field offset of 0xFFFF
448 means "unknown". Also fix description of the discriminator_offset
451 2008-11-10 Owen Taylor <otaylor@redhat.com>
453 Bug 560250 - Fully parse included modules
455 For some things, like computing structure offsets to put into the typelib
456 we need more than just the aliases from included modules. Do a completel
457 parse of included modules and store in module->included_modules.
459 Also add g_ir_find_node() to find node information from within the
460 active set of modules and their includes.
462 2008-11-10 Owen Taylor <otaylor@redhat.com>
464 Split g_ir_ffi_get_ffi_type() out from ginvoke.c
466 Extract a function to convert GITypeTag to ffi_type from the internals
467 of ginvoke.c. This will be useful in figure out structure alignment.
469 Also fix handling of gsize and time_t to be portable. (Add a check
470 to configure.ac to figure out the width of time_t.)
472 2008-11-10 Owen Taylor <otaylor@redhat.com>
474 Bug 560248 – "disguised structures"
476 Certain types like GIConv and GdkAtom are pointers internally but don't
477 look like pointers when referenced. They have the form.
479 typedef struct _X *X;
481 Parse these as structures/records but mark them in the gir with a 'disguised'
482 attribute so that we know that they need special handling.
484 In the typelib treat them like any other structure.
486 2008-11-09 Jürg Billeter <j@bitron.ch>
489 * giscanner/girwriter.py:
491 Write throws attribute for virtual functions, fixes bug 559703
493 2008-11-07 Johan Dahlin <jdahlin@async.com.br>
495 * giscanner/libtoolimporter.py (LibtoolImporter.find_module): Clear
496 up some confusion about the second argument to find_module, it's
497 actually the packages __path__ attribute which we can safely ignore
499 (LibtoolImporter.load_module): Set module.__loader__ as per PEP 302.
501 2008-11-07 Owen Taylor <otaylor@redhat.com>
503 Bug 559737 – Deal with continuations in macros
505 * giscanner/giscannerlexer.l: Treat continuation lines the same
506 as regular newlines. This makes the scanner not complain about
507 #define foo(x) \ <stuff> inside a C file. There's no attempt
508 however to handle parsing macro definitions split across lines.
510 2008-11-07 Johan Dahlin <jdahlin@async.com.br>
512 * giscanner/cachestore.py:
513 Handle broken cache entries, write only filesystems and
514 running out of diskspace.
516 2008-11-07 Owen Taylor <otaylor@redhat.com>
518 * giscanner/giscannermodule.c (pygi_source_scanner_lex_filename):
519 Set current_filename before lexing the file so error messages
520 are reported in the right file.
522 2008-11-06 Colin Walters <walters@verbum.org>
524 * tests/everything/*: Add some tests for strv.
526 2008-11-05 Colin Walters <walters@verbum.org>
528 * girepository/ginvoke.c (g_function_info_invoke): Don't use
529 nested scope local variable for error which may go away after
530 conditional is complete.
532 2008-11-05 Colin Walters <walters@verbum.org>
534 * giscanner/scannerlexer.l: Avoid static 256 char buf which we
535 manipulate hackily; just use GString. This avoids an
536 uninitialized memory read pointed out by Havoc.
538 2008-11-04 Johan Dahlin <jdahlin@async.com.br>
540 * giscanner/__init__.py:
542 * giscanner/cachestore.py:
543 * giscanner/cgobject.py:
544 * giscanner/girparser.py:
545 * giscanner/girwriter.py:
546 * giscanner/giscannermodule.c:
547 * giscanner/glibast.py:
548 * giscanner/glibtransformer.py:
549 * giscanner/libtoolimporter.py:
550 * giscanner/minixpath.py:
551 * giscanner/odict.py:
552 * giscanner/sourcescanner.c:
553 * giscanner/sourcescanner.h:
554 * giscanner/sourcescanner.py:
555 * giscanner/transformer.py:
556 * giscanner/utils.py:
557 * giscanner/xmlwriter.py:
559 Relicense the giscanner library under LGPLv2+.
560 This has been approved by all contributors.
562 2008-11-01 Owen Taylor <otaylor@redhat.com>
564 Bug 558848 giparser.py: shared library should be optional
566 When parsing a .gir, allow the shared-library attribute
567 of <namespace/> to be missing: this corresponds to the handling
568 in libgirepository and elsewhere.
570 2008-11-01 Tommi Komulainen <tommi.komulainen@iki.fi>
572 Bug 557898 – Fails to build on OSX 10.4
574 * configure.ac: Check for $shrext_cmds that should be implicitly
575 available if you're using libtool >= 2.0. If undefined, call
576 libtool --config explicitly to get its value.
577 * girepository/gtypelib.c: Remove special case for (non-)Darwin
580 2008-10-31 Colin Walters <walters@verbum.org>
582 * COPYING, COPYING.lib, COPYING.tools: Clarify licensing status.
584 2008-10-31 Johan Dahlin <jdahlin@async.com.br>
586 * configure.ac: Post release version bump
589 2008-10-31 Johan Dahlin <jdahlin@async.com.br>
593 * docs/release-checklist.txt:
596 2008-10-31 Johan Dahlin <jdahlin@async.com.br>
598 * Makefile.am: add an upload-release target
599 * docs/release-checklist.txt:
600 Release process documentation
602 2008-10-31 Colin Walters <walters@verbum.org>
604 Bug 558109 – _g_typelib_init fails to find shared libraries
606 * transformer/glibtransformer.py: Use ctypes' find_library
607 on passed libraries and write that for the shared-library
608 entry. We want to avoid depending on -devel packages.
610 2008-10-31 Johan Dahlin <jdahlin@async.com.br>
612 * docs/g-ir-scanner.1:
613 Document the renaming options.
615 2008-10-31 Tommi Komulainen <tommi.komulainen@iki.fi>
617 * giscanner/Makefile.am:
618 * tests/invoke/Makefile.am:
619 * tests/repository/Makefile.am: List in-tree libraries first in
620 LDADD / LIBADD. If installed library is listed first, the
621 resulting binary will prefer installed version to one in .libs,
622 possibly making 'make check' behave strangely.
624 2008-10-30 Tommi Komulainen <tommi.komulainen@iki.fi>
626 * giscanner/ast.py: map 'id' (ObjC) to 'any' type to stop
627 gir-repository from choking with gdk/quartz
629 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
631 * giscanner/giscannermodule.c (calc_attrs_length),
632 (pygi_collect_attributes):
633 * giscanner/xmlwriter.py:
634 Write a C version of the xml namespace formatter.
635 Saves 15% of the time it takes to create a gtk gir.
637 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
639 * giscanner/xmlwriter.py: Abstract attribute formatting
640 to a function external to the XMLWriter class.
642 * giscanner/scannerlexer.l:
643 Parse and discard __typeof and __attribute.
645 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
647 * giscanner/girparser.py:
648 Remove arguments from the constructor, move them to
649 separate accessors. Add a new parse_tree method
650 which takes an element tree instance.
651 * tools/g-ir-scanner:
652 Update callsite for this
654 * giscanner/Makefile.am:
655 * giscanner/cachestore.py:
656 * giscanner/transformer.py:
657 Cache the include parsing. Saves ~25% time when
658 creating vte (which includes everything up to gtk+).
660 2008-10-30 Colin Walters <walters@verbum.org>
662 * giscanner/transformer.py: Don't reparse includes
663 we've already processed.
665 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
667 * giscanner/girparser.py:
668 * giscanner/transformer.py:
669 Avoid parsing parameters, types etc when parsing
670 includes. Should speed up include parsing a bit.
672 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
674 * giscanner/girparser.py:
675 Avoid big if/else and use a dispatch table like
678 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
680 * giscanner/transformer.py:
681 Clean up include parsing and registration.
683 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
685 * giscanner/transformer.py:
688 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
690 Bug 558383 – builddir != srcdir build fails if giscanner python module not already installed
693 construct PYTHONPATH just once
695 * tests/everything/Makefile.am:
696 * tests/scanner/Makefile.am:
697 add $(top_srcdir) to PYTHONPATH to
698 handle builddir != srcdir
700 * giscanner/libtoolimporter.py:
701 * giscanner/sourcescanner.py:
702 Make the libtoolimporter work when distchecking too.
704 Mostly based on patch by Tommi Komulainen
706 2008-10-29 Owen Taylor <otaylor@redhat.com>
708 * giscanner/glibtransformer.py: If a filename of an existing
709 file is passed to --library, hunt for it directly, rather than
710 searching for a corresponding library.
712 2008-10-29 Johan Dahlin <jdahlin@async.com.br>
714 * giscanner/libtoolimporter.py:
715 * giscanner/sourcescanner.py:
716 Clean up the libtool importer a bit. Add a context so we
717 can use it through a with statement.
718 Don't just look in the current directory, look in the whole
721 2008-10-29 Tommi Komulainen <tommi.komulainen@iki.fi>
723 Bug 558065 – gitesttypes should be installed
727 * tests/types/Makefile.am -> tests/everything/Makefile.am
728 * tests/types/gitesttypes.c -> tests/everything/gitesttypes.c
729 * tests/types/gitesttypes.h -> tests/everything/gitesttypes.h
730 move tests/types to tests/everything
732 * tests/everything/Makefile.am: build normal shared library
733 libgirepository-everything.so.1.0.0 and corresponding typelib
734 Everything-1.0.typelib
736 * tests/everything/Makefile.am: explicitly link libtool
737 versioning with typelib versioning with variables
739 2008-10-28 Johan Bilien <jobi@via.ecp.fr>
741 * tools/g-ir-scanner: add LD_LIBRARY_PATH to LPATH before calling ld.
743 2008-10-27 Johan Bilien <jobi@via.ecp.fr>
745 * gio/gio-2.0.c: add allow-none annotations, based on the pygobject
748 2008-10-27 Johan Bilien <jobi@via.ecp.fr>
750 Bug 558068 – when invoking a method, offset the in arguments by one,
753 * tests/invoke/invoke.c, tests/invoke/testfns.c,
754 tests/invoke/testfns-1.0.gir: Add testing of method and constructor.
755 * girepository/ginvoke.c: do not offset the index of given out
756 arguments by one for methods, "this" is provided as in argument only.
758 2008-10-27 Johan Bilien <jobi@via.ecp.fr>
760 * gir/gio-2.0.c: add annotation for g_file_delete
762 2008-10-27 Tommi Komulainen <tommi.komulainen@iki.fi>
764 Bug 558062 – provide and use paths in the .pc file
766 * gobject-introspection-1.0.pc.in: provide typelibdir variable
767 for where .typelibs should be installed (callers shouldn't need
768 to construct paths from bits and pieces)
770 2008-10-25 Andreas Rottmann <a.rottmann@gmx.at>
772 Bug 557791 – g_irepository_require() could return a GTypelib *
774 * girepository/girepository.c: Return GTypelib; this is useful
775 for low level manipulation.
777 2008-10-25 Colin Walters <walters@verbum.org>
779 Bug 557788 – Return types for constructors in generated typelib bogus
781 * giscanner/glibtransformer.py: Don't resolve ctors incrementally,
782 rely on end pass resolution.
784 2008-10-25 Andreas Rottmann <a.rottmann@gmx.at>
786 Bug 557786 - support fixed size arrays
788 * girepository/ginfo.c: Add g_type_info_get_array_fixed_size.
789 * giscanner/scannerparser.y: Retain fixed array size.
790 * giscanner/ast.py: Add to note.
791 * giscanner/girwriter.py: Write to gir.
792 * girepository/girnode.c: Write it to typelib.
793 * tools/generate.c: Generate.
794 * tests/*: Add tests.
796 2008-10-25 Colin Walters <walters@verbum.org>
798 Bug 557076 - move typelibs to $libdir
800 * configure.ac: Steal some configury bits from dbus to expand
802 * gir/Makefile.am: Move to libdir.
803 * girepository/girepository.c: Stop searching XDG_DATA_DIRS;
804 instead just look at one hardcoded path in libdir.
805 * acinclude.m4: Bits from dbus.
807 2008-10-24 Johan Dahlin <johan@gnome.org>
809 * girepository/girnode.c (g_ir_node_check_unhandled_members):
810 Be quiet, do not warn about unhandled members.
812 2008-10-24 Johan Dahlin <johan@gnome.org>
814 * girepository/gtypelib.c:
815 Only use SHLIB_SUFFIX on darwin, otherwise use
816 G_MODULE_SUFFIX, we cannot get shext_cmds from libtool 2.2.
818 2008-10-24 Lucas Rocha <lucasr@gnome.org>
820 Bug 557623 - Constructors shouldn't be flagged as methods.
822 * girepository/ginfo.c (g_function_info_get_flags): ditto.
824 2008-10-24 Johan Dahlin <johan@gnome.org>
826 * giscanner/scannerparser.y:
827 Check against division by zero for the modula operator.
828 This fixes header parsing of OSX system headers included
831 2008-10-24 Johan Dahlin <johan@gnome.org>
835 Add a CONTRIBUTORS file and dist it.
837 2008-10-23 Tommi Komulainen <tommi.komulainen@iki.fi>
839 Bug 556739 – transfer-ownership attribute should be mandatory in .gir
841 * girepository/girparser.c (parse_param_transfer):
842 * giscanner/transformer.py (_create_parameter, _create_return):
843 * giscanner/girwriter.py (_write_return, _write_parameter):
844 * tools/generate.c (write_callable_info): always write and
845 require "transfer-ownership" for return-values and parameters
848 * tests/invoke/testfns-1.0.gir:
850 * tests/scanner/DrawableAdditions.xml:
851 * tests/scanner/GtkFrob-1.0-expected.tgir:
852 * tests/scanner/annotation-1.0-expected.tgir:
853 * tests/scanner/drawable-1.0-expected.tgir:
854 * tests/scanner/drawable-injected-1.0-expected.gir:
855 * tests/scanner/drawable-injected-1.0-expected.tgir:
856 * tests/scanner/foo-1.0-expected.tgir: Updated
858 2008-10-23 Tommi Komulainen <tommi.komulainen@iki.fi>
860 * giscanner/cgobject.py: build fundamental types same way as glib
862 * giscanner/glibtransformer.py (_type_from_gtype): record GType
863 when constructing the Type from it
865 * giscanner/glibtransformer.py (_adjust_transfer): Check whether
866 the parameter is a GObject from its GType, if available.
868 * giscanner/glibtransformer.py (_adjust_transfer):
869 * tests/scanner/foo-1.0-expected.gir:
870 * tests/scanner/foo-1.0-expected.tgir: deduce
871 transfer-ownership from GTypes
873 2008-10-23 Tommi Komulainen <tommi.komulainen@iki.fi>
875 * giscanner/transformer.py (_create_parameter):
876 * tests/scanner/foo-1.0-expected.gir: make varargs
877 transfer-ownership="none"
879 2008-10-23 Colin Walters <walters@verbum.org>
881 Bug 556739 - transfer ownership
883 * giscanner/ast.py: Refactor Parameter/Return to share
884 common attributes. Add transfer_inferred attribute
885 which says whether or not we made a guess.
886 * giscanner/transformer.py: Add much more extensive
887 heuristics around parameter and return transfer.
888 * giscanner/glibtransformer.py: Adjust to inspect
892 2008-10-22 Tommi Komulainen <tommi.komulainen@iki.fi>
894 Bug 557377 – Add test to ensure annotations survive the roundtrip via typelib
896 * tests/scanner/Makefile.am:
897 * tests/scanner/annotation-1.0-expected.tgir:
898 * tests/scanner/drawable-1.0-expected.tgir:
899 * tests/scanner/drawable-injected-1.0-expected.tgir:
900 * tests/scanner/foo-1.0-expected.tgir:
901 * tests/scanner/GtkFrob-1.0-expected.tgir:
902 * tests/scanner/utility-1.0-expected.tgir: Add test to ensure
903 annotations survive the roundtrip via typelib
905 The expectations are as currently produced by g-ir-generate,
906 comparison with the .gir files shows there are differences.
908 2008-10-23 Johan Bilien <jobi@via.ecp.fr>
910 Bug 557468 – Support for GI_TYPELIB_PATH
912 * girepository/girepository.c: if the GI_TYPELIB_PATH is set, add the
913 provided paths to the global search path.
915 2008-10-22 Tommi Komulainen <tommi.komulainen@iki.fi>
917 Bug 557379 – g-ir-generate not writing the 'abstract' attribute
919 * tests/scanner/drawable-1.0-expected.tgir:
920 * tests/scanner/drawable-injected-1.0-expected.tgir:
921 * tests/scanner/foo-1.0-expected.tgir:
922 * tools/generate.c (write_object_info): write 'abstract'
923 attribute for classes
925 2008-10-22 Lucas Rocha <lucasr@gnome.org>
927 * girepository/girmodule.c, girepository/gtypelib.c,
928 girepository/girparser.[ch]: fix some build warnings.
930 2008-10-22 Tommi Komulainen <tommi.komulainen@iki.fi>
932 Bug 557405 – Use 'allow-none' consistently
934 * docs/typelib-format.txt:
935 * girepository/ginfo.c (g_arg_info_may_be_null):
936 * girepository/girnode.c (g_ir_node_build_typelib):
937 * girepository/girnode.h (struct _GIrNodeParam):
938 * girepository/girparser.c (start_parameter):
939 * girepository/girwriter.c (function_generate):
940 * girepository/gtypelib.h (ArgBlob):
942 * tests/function.gir:
943 * tools/generate.c (write_callable_info): Use 'allow-none'
944 consistently throughout
946 2008-10-22 Tommi Komulainen <tommi.komulainen@iki.fi>
948 Bug 557092 – Callback annotations not used
950 * giscanner/transformer.py (_create_callback): use annotations
952 * tests/scanner/annotation.h
953 * tests/scanner/annotation-1.0-expected.gir: add tests
955 2008-10-21 Colin Walters <walters@verbum.org>
957 * giscanner/scannerlexer.l: Don't require trailing whitespace after
958 uncommented parameters.
961 2008-10-21 Colin Walters <walters@verbum.org>
963 * girepository/girepository.c: Ensure that when doing an unversioned
964 require, we prefer items earlier in the search path to later ones.
966 2008-10-21 Owen Taylor <otaylor@redhat.com>
968 * giscanner/transformer.py: For string parameters allow transfer annotation
969 to override the standard automatic guessing based on 'const'.
971 2008-10-21 Johan Bilien <jobi@via.ecp.fr>
973 Bug 557241 – "throws" flag for functions
975 * tests/scanner/drawable-1.0-expected.gir,
976 tests/scanner/drawable-injected-1.0-expected.gir,
977 tests/scanner/drawable.[ch]: add simple test for throwing
978 function (has GError ** as last argument)
980 * giscanner/ast.py: add a 'throws' flag to Function
981 * giscanner/glibtransformer.py: if a function's last paramerter is
982 a GError, set the 'throws' flag and remove that parameter
983 * giscanner/girwriter.py: write out the 'throws' attribute
984 * giscanner/girparser.py: support parsing the 'throws' attribute
986 * tests/repository/gitestthrows.c: add a simple test to check the
987 throws flag in a typelib and invoke the function
989 * girepository/ginfo.c, girepository/girnode.[ch],
990 girepository/girnode.h, girepository/girparser.c,
991 girepository/girepository.h: Add and parse the GI_FUNCTION_THROWS flag
993 * girepository/ginvoke.c: if a function throws, add a GError as last
994 arguments, and propagate the error to the invoker.
996 2008-10-21 Tommi Komulainen <tommi.komulainen@iki.fi>
998 * giscanner/transformer.py (_create_parameters): Warn if we see
999 annotations for unknown parameters. If .h and .c files name
1000 parameters differently, the annotations may be lost.
1002 2008-10-21 Johan Dahlin <johan@gnome.org>
1004 Bug 556358 - don't use libtool internals
1006 * giscanner/Makefile.am:
1007 * giscanner/libtoolimporter.py:
1008 * giscanner/sourcescanner.py:
1009 * giscanner/utils.py:
1010 Add a python meta importer and remove a libtool symlink hack.
1012 2008-10-20 Andreas Rottmann <a.rottmann@gmx.at>
1014 * tests/scanner/Makefile.am (%.typelib): Set PYTHONPATH
1015 and --add-include-path appropriately when invoking the scanner.
1016 * tests/types/Makefile.am (%typelib): Likewise.
1018 2008-10-20 Colin Walters <walters@verbum.org>
1020 Bug 556777 - validate properties
1022 * giscanner/transformer.py: Add option to throw on unknown types.
1023 * giscanner/glibtransformer.py: Use it on properties.
1024 * tests/*: Add a test.
1026 2008-10-20 Colin Walters <walters@verbum.org>
1028 * giscanner/glibast.py: Also register g variants of
1029 default_array_types. This is not beautiful, but
1030 good alternatives aren't easy to come by.
1031 This fixes gchar ** parsing.
1033 2008-10-20 Colin Walters <walters@verbum.org>
1035 * docs/typelib-format.txt, girepository/gtypelib.h:
1036 Take a bit from ObjectInfo to represent abstract flag.
1037 * giscanner/cgobject.py: Expose g_type_get_flags.
1038 * girepository/girepository.h: Add accessor.
1039 * girepository/ginfo.c: Implement it.
1040 * giscanner/ast.py: Add is_abstract flag to generic
1042 * giscanner/glibast.py: Use it.
1043 * giscanner/girwriter.py: Write it.
1044 * girepository/girparser.c: Parse it.
1047 2008-10-20 Tommi Komulainen <tommi.komulainen@iki.fi>
1049 * giscanner/girparser.py (_parse_function): don't lose
1050 'transfer-ownership' attributes when injecting, check for the
1053 2008-10-19 Johan Dahlin <johan@gnome.org>
1055 * giscanner/scannerlexer.l: Parse and ignore __asm.
1057 2008-10-19 Colin Walters <walters@verbum.org>
1059 * giscanner/girparser.py: Parse array length= to ensure
1060 it doesn't get lost from --inject.
1062 2008-10-17 Colin Walters <walters@verbum.org>
1064 Bug 556795 - char ** regression
1066 * giscanner/transformer.py: Fix parsing of ctypes, add some
1067 comments about what's going on.
1068 * tests/*: Add a test for char **.
1070 2008-10-17 Colin Walters <walters@verbum.org>
1072 Bug 556783 - change namespace handling to be more consistent
1074 * giscanner/transformer.py: Eliminate usage of
1075 strip_namespace_object. We now treat --namespace as the default
1076 --strip-prefix; however, if --strip-prefix is specified it
1077 overrides --namespace. This applies to everything except function
1078 names, where we do also strip the namespace.
1079 * giscanner/glibtransformer.py: Remove usage of
1080 strip_namespace_object.
1082 * tests/*: Add skeletal GtkFrob-1.0 test which has different
1083 --namespace and --strip-prefix.
1085 2008-10-17 Tommi Komulainen <tommi.komulainen@iki.fi>
1087 Bug 556732 – generate gir files consistently
1089 * girepository/girparser.c (start_parameter):
1091 * tests/invoke/testfns-1.0.gir:
1092 * tools/generate.c (write_callable_info): write
1093 'transfer-ownership' attribute consistently with both
1094 return-value and parameter elements
1096 2008-10-17 Tommi Komulainen <tommi.komulainen@iki.fi>
1098 Bug 556732 – generate gir files consistently
1100 * tools/generate.c (write_callable_info): write 'direction'
1101 attribute only if other than 'in' to be consistent with
1104 * tests/object.gir: remove direction="in" which is the default
1106 2008-10-17 Tommi Komulainen <tommi.komulainen@iki.fi>
1108 Bug 556732 – generate gir files consistently
1110 * giscanner/ast.py (Field): add readable and writable properties
1111 * giscanner/girparser.py (_parse_field): copy 'readable' and
1112 'writable' attributes
1113 * giscanner/transformer.py (_create_member): create fields as
1115 * giscanner/glibtransformer.py (_introspect_object,
1116 _pair_class_struct): make object instance and class fields
1118 * giscanner/girwriter.py (_write_field):
1119 * tools/generate.c (write_field_info): write field 'readable'
1120 and 'writable' attributes only if non-default (read-only)
1121 * girepository/girparser.c (start_field): in the absence of
1122 attributes assume fields are read-only
1124 * tests/struct.gir: remove redundant readable="1" from fields
1125 * tests/scanner/foo-1.0-expected.gir:
1126 * tests/scanner/utility-1.0-expected.gir: add writable="1" to
1127 all record and union fields
1129 2008-10-17 Tommi Komulainen <tommi.komulainen@iki.fi>
1131 Bug 556732 – generate gir files consistently
1133 * giscanner/girwriter.py (_write_property): write properties
1134 'construct' attribute if set
1135 * tools/generate.c (write_property_info): write properties
1136 'readable' and 'writable' attributes only if non-default
1137 * tests/object.gir: add writable="0"
1138 * tests/scanner/foo-1.0-expected.gir: add construct="1"
1140 2008-10-17 Johan Bilien <jobi@via.ecp.fr>
1142 * gir/glib-2.0.c: added annotations
1144 2008-10-16 Johan Bilien <jobi@via.ecp.fr>
1146 * giscanner/ast.py: Also assume direction=out for size_t*, ssize_t*
1149 2008-10-16 Johan Bilien <jobi@via.ecp.fr>
1151 Bug 556610 – giscanner/girparser.py drops parameter options
1153 * tests/scanner/drawable-injected-1.0-expected.gir,
1154 tests/scanner/DrawableAdditions.xml: added simple test for injection.
1155 * giscanner/ast.py: allow Parameter to take options in the constructor
1156 * giscanner/girparser.py: parse parameter options (transfer,
1157 direction, allow-none)
1159 2008-10-16 Colin Walters <walters@verbum.org>
1161 Bug 556185 - segfault on g_callable_info_get_return_type
1163 Initial patch from John Ehresman.
1165 * tests/repository/*: Add a test using
1166 g_callable_info_get_return_type. Instead of casting a
1167 GITypeInfo directly to a GIRegisteredTypeInfo, we need
1168 to call g_type_info_get_interface.
1170 2008-10-16 Colin Walters <walters@verbum.org>
1172 Bug 556579 - union and struct name misresolved
1174 * giscanner/transformer.py: The calls to _resolve_type_name
1175 for struct/union names was a legacy holdover from when type
1176 resolution had multiple phases. Now it's actively harmful
1177 since we might pull in an identical name from another
1181 2008-10-16 Colin Walters <walters@verbum.org>
1183 Bug 556432 - transfer annotations and defaults
1185 * giscanner/transformer.py: Canonicalize type
1186 after removing *, not before. This ensures that
1187 guchar* is transformed to 'uint8'.
1188 Add some comments here.
1189 * giscanner/glibtransformer.py: Add _adjust_transfer
1190 phase for tweaking GObject transfers.
1193 2008-10-16 Tommi Komulainen <tommi.komulainen@iki.fi>
1195 * configure.ac: enable bunch of gcc warning CFLAGS
1197 2008-10-16 Tommi Komulainen <tommi.komulainen@iki.fi>
1199 Bug 556543 – reduce compiler warnings
1201 * girepository/ginfo.c:
1202 * girepository/girepository.c (register_internal,
1203 count_interfaces, find_interface, find_namespace_version,
1204 parse_version, g_irepository_require):
1205 * girepository/girmodule.c (g_ir_module_build_typelib):
1206 * girepository/girnode.c (init_stats, dump_stats,
1207 _g_irnode_init_stats, _g_irnode_dump_stats,
1208 g_ir_node_can_have_member):
1209 * girepository/girparser.c (firstpass_end_element_handler,
1210 locate_gir, parse_basic, parse_type_internal, resolve_aliases,
1211 start_alias, start_type, end_type_top, parse_include, cleanup,
1213 * girepository/gtypelib.c (validate_function_blob, validate_enum_blob):
1214 * giscanner/giscannermodule.c (directive_get_options,
1215 type_get_child_list):
1216 * giscanner/scannerlexer.l (parse_gtkdoc):
1217 * giscanner/scannerparser.y (ctype_free):
1218 * giscanner/sourcescanner.c:
1219 * giscanner/sourcescanner.h (gi_source_scanner_parse_macros):
1220 * tests/types/gitesttypes.c:
1221 * tools/compiler.c (main):
1222 * tools/generate.c (write_repository): Remove unused variables
1223 and code, add missing includes, declarations and case
1226 2008-10-16 Tommi Komulainen <tommi.komulainen@iki.fi>
1228 Bug 556541 – access union members through UnionBlob rather than
1231 * girepository/ginfo.c (g_union_info_find_method): access union
1232 members through UnionBlob rather than StructBlob
1234 2008-10-15 Colin Walters <walters@verbum.org>
1236 Bug 556331 - clean up includes handling
1238 * tools/g-ir-scanner: Rework command line arguments; now we take
1239 --add-include-path and --include separately.
1240 * giscanner/girwriter.py: Separate name= and version= in include
1242 * giscanner/ast.py: Add Include type.
1243 * giscanner/transformer.py: Cleanups to register_include now that
1244 we don't need to handle mixed filenames and relative arguments.
1245 * girepository/girparser.c: Parse name and version separately;
1246 this fixes a bug as a side effect where we weren't resolving
1247 through aliases for basic types.
1248 * girepository/girepository.c: Fix format string args.
1249 * gir/Makefile.am: Update.
1252 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1254 Bug 556434 – unhandled interface/object/... member types
1256 * girepository/girnode.c (g_ir_node_check_unhandled_members,
1257 g_ir_node_build_typelib): Check all
1258 interface/object/boxed/struct/union members are processed and
1259 abort if they are not. (Mostly callbacks in structs, but also
1260 fields in interfaces.)
1262 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1264 * a/girepository/girnode.c (g_ir_node_build_members,
1265 g_ir_node_build_typelib): refactor common code for processing
1266 members to a function
1268 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1270 * gir/Makefile.am (check-local): check that typelib -> gir -> typelib
1271 transformation is lossless (it's not)
1273 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1275 * tests/Makefile.am: fix tests to compare xml to xml instead of
1276 typelib to xml, and stop on error
1278 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1280 * tools/generate.c (write_type_name, write_type_info,
1281 write_type_info, write_object_info, write_object_info,
1282 write_interface_info, write_error_domain_info): reduce code
1285 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1287 Bug 556174 – parse types for lists etc.
1289 * girepository/girparser.c (end_type_recurse):
1291 * tools/generate.c (write_type_info, write_field_info,
1292 write_callable_info, write_callable_info, write_constant_info,
1293 write_property_info): use nested <type>s for lists and hashes
1295 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1298 * tests/object.gir: remove trailing whitespace from inside
1299 elements to match g-ir-generate output
1301 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1303 * tools/generate.c (xml_printf): quote printf arguments so that
1304 we don't generate invalid XML by writing unescaped double quotes
1305 and such in attributes
1307 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1309 * tools/generate.c (write_field_info, write_callable_info,
1310 write_function_info, write_callback_info, write_struct_info,
1311 write_constant_value, write_signal_info, write_vfunc_info,
1312 write_object_info, write_interface_info, write_union_info,
1313 write_repository): remove unused indent parameters, xmlwriter
1314 keeps track of necessary indentation
1316 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1318 * tools/generate.c (xml_element_new, xml_element_free,
1319 xml_start_element, xml_end_element, xml_end_element_unchecked,
1320 xml_open, xml_close): Keep track of generated XML tree and
1321 handle indentation and closing tags properly.
1322 (write_field_info, write_callable_info, write_function_info,
1323 write_callback_info, write_struct_info, write_value_info,
1324 write_constant_info, write_enum_info, write_signal_info,
1325 write_vfunc_info, write_property_info, write_object_info,
1326 write_interface_info, write_error_domain_info, write_union_info,
1327 write_repository): Use xml_start_element and xml_end_element to
1330 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1332 * tools/generate.c (xml_printf, xml_open, xml_close, xml_free):
1333 (write_type_name, write_type_info, write_field_info,
1334 write_callable_info, write_function_info, write_callback_info,
1335 write_struct_info, write_value_info, write_constant_value,
1336 write_constant_info, write_enum_info, write_signal_info,
1337 write_vfunc_info, write_property_info, write_object_info,
1338 write_interface_info, write_error_domain_info, write_union_info,
1339 write_repository): wrap all FILE access to go through simple xmlwriter
1341 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1343 Bug 556400 – Fails to build on OS X 10.4
1345 * configure.ac: check for functions backtrace and backtrace_symbols
1346 * girepository/girparser.c (backtrace_stderr): Comment out
1347 implementation if the functions are not available.
1348 * gcov.mak (clean-gcov, clean-gcno): always call 'find' with a
1349 directory for better portability
1351 2008-10-15 Johan Bilien <jobi@via.ecp.fr>
1353 Bug 556433 – assume direction = out for int * parameters
1355 * giscanner/ast.py: define a list of types for which, if passed as
1356 reference, we assume a default direction of 'out'
1357 * giscanner/transformer.py: if a type has type pointer to one of the
1358 previously defined types, and no direction is set, assume out.
1359 * tests/scanner/drawable.[ch]: added tests for guessed direction=out
1361 2008-10-15 Johan Bilien <jobi@via.ecp.fr>
1363 * tests/scanner/annotation.c: fixed a few copy-paste errors
1365 2008-10-14 Johan Bilien <jobi@via.ecp.fr>
1367 Bug 556323 – transfer-ownership is wrong for functions returning const
1370 * giscanner/transformer.py: check for a const string as return value,
1371 not just const char*. Suggested by Colin Walters
1372 * tests/scanner/annotation-1.0-expected.gir: updated expected output
1374 2008-10-14 Johan Bilien <jobi@via.ecp.fr>
1376 * girepository/ginfo.c, girepository/girepository.h: add
1377 g_union_info_find_method
1379 2008-10-14 Colin Walters <walters@verbum.org>
1381 * tests/repository/Makefile.am: Reenable repo test.
1382 * tests/repository/gitestrepo.c: Prepend search
1383 path for $(top_builddir)/gir dir so that we don't
1384 require installation for "make check" to pass.
1386 2008-10-13 Jürg Billeter <j@bitron.ch>
1388 * giscanner/glibtransformer.py:
1389 * tests/scanner/annotation-1.0-expected.gir:
1390 * tests/scanner/drawable-1.0-expected.gir:
1391 * tests/scanner/foo-1.0-expected.gir:
1392 * tests/scanner/utility-1.0-expected.gir:
1394 Support fields in GObject structs
1396 2008-10-13 Jürg Billeter <j@bitron.ch>
1398 * giscanner/ast.py: add signed integer and off_t to type_names
1400 2008-10-12 Jürg Billeter <j@bitron.ch>
1402 * giscanner/girparser.py: Parse bits attribute of fields
1404 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1406 * tests/repository/Makefile.am: run 'gitestrepo' in 'make check'
1407 * tests/repository/gitestrepo.c (main): instantiate
1408 'GCancellable' to ensure the GType is registered before using
1411 2008-10-12 Johan Bilien <jobi@via.ecp.fr>
1413 * giscanner/girparser.py: actually add the parsed constant nodes
1415 2008-10-12 Colin Walters <walters@verbum.org>
1417 * girepository/girepository.c: Don't cast DirEntry to Blob,
1418 actually look it up by offset.
1420 2008-10-12 Johan Bilien <jobi@via.ecp.fr>
1422 * giscanner/girparser.py: parse constant nodes in gir files
1424 2008-10-12 Johan Bilien <jobi@via.ecp.fr>
1426 * giscanner/transformer.py: prefix for constants have an underscore,
1427 so remove them as if they were functions, not objects.
1429 2008-10-12 Johan Bilien <jobi@via.ecp.fr>
1431 * tests/scanner/foo-1.0-expected.gir: add constants to expected gir
1434 2008-10-12 Colin Walters <walters@verbum.org>
1436 Initial patch from Jani Monoses.
1438 * girepository/gtypelib.c: Fix inverted test for success
1441 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1443 * tools/generate.c (write_callable_info): use "transfer-ownership"
1444 attribute for return values
1446 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1448 * tools/generate.c (write_callable_info): move "transfer" and
1449 "null-ok" attributes from <function> to <return-value> element
1451 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1453 * girepository/girparser.c (start_return_value): handle
1454 "transfer-ownership" attribute
1456 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1458 * girepository/girparser.c (parse_param_transfer):
1459 * tools/generate.c (write_callable_info): use "container" for
1460 container/shallow ownership transfer (not "shallow")
1462 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1464 * girepository/girparser.c (parse_param_transfer,
1465 start_parameter): Refactor handling of transfer=none/shallow/full
1466 to separate function
1468 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1470 Bug 556048 – Crash in g_irepository_find_by_gtype
1472 * girepository/gtypelib.h (BLOB_IS_REGISTERED_TYPE): added
1473 * girepository/girepository.c (find_interface): Fix
1474 find_by_gtype case to get the type name from right offset
1476 2008-10-12 Jürg Billeter <j@bitron.ch>
1478 * giscanner/girparser.py: Fix parsing transfer-ownership attribute
1481 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1483 * girepository/gtypelib.h (RegisteredTypeBlob): make
1484 'unregistered' one bit wide as everywhere else
1486 2008-10-12 Jürg Billeter <j@bitron.ch>
1488 * giscanner/glibtransformer.py:
1489 * tests/scanner/annotation-1.0-expected.gir:
1490 * tests/scanner/drawable-1.0-expected.gir:
1491 * tests/scanner/drawable.h:
1492 * tests/scanner/foo-1.0-expected.gir:
1493 * tests/scanner/utility-1.0-expected.gir:
1495 Readd class records as workaround to not break Gtk typelib
1497 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1499 * tests/types/Makefile.am: fix typo in gitesttypes namespace
1501 2008-10-12 Jürg Billeter <j@bitron.ch>
1503 * giscanner/glibtransformer.py: Don't generate <record> elements
1505 * tests/scanner/*: Update test cases
1507 2008-10-11 Colin Walters <walters@verbum.org>
1509 Bug 552858: versioning
1511 This is a big patch. You should probably remove your installation
1514 * docs/typelib-format.txt: Add nsversion entry which holds
1515 version of namespace.
1516 * girepository/girepository.h: Add 'version' parameter to
1517 g_irepository_require. This may be NULL. Normally
1518 bindings should pass an explicit version though.
1519 * girepository/girepository.c: Lots of infrastructure to
1520 support versioning. Add some more documentation. Disallow
1521 some usage of NULL namespaces.
1522 * girepository/girmodule.c: Add version parameter.
1523 * girepository/gtypelib.c: Update header size.
1524 * giscanner/ast.py: Add version to Namespace.
1525 * giscanner/girparser.py: Parse version attribute from
1526 XML, pass to Namespace.
1527 * giscanner/girwriter.py: Write out version parameter.
1528 * giscanner/transformer.py: Clean up include registration.
1529 * tests/*: Add version attribute.
1530 * tests/invoke/invoke.c: Don't try looking up test before
1531 it's loaded in repository.
1532 * tools/generate.c: Output version parameter.
1533 * gir/Makefile.am: Add 2.0 version to .gir files.
1535 2008-10-11 Colin Walters <walters@verbum.org>
1537 * giscanner/scannerlexer.l (parse_gtkdoc): Don't lose
1538 if we have mismatched parens.
1540 2008-10-11 Lucas Rocha <lucasr@gnome.org>
1542 * giscanner/girparser.py (_parse_enumeration_bitfield): fix typo
1543 on 'members' variable.
1545 2008-10-11 Colin Walters <walters@verbum.org>
1547 Bug 555947 - update annotations syntax
1549 * giscanner/ast.py: Default to None for transfer. Remove
1550 default transfers for container types; we require this to
1552 * giscanner/girwriter.py: Transfer is now 'none', 'container',
1553 'full' to match repository.
1554 * giscanner/scannerlexer.l: Annotations now are parenthesized.
1555 * giscanner/transformer.py: Update for new annotations syntax.
1558 2008-10-11 Johan Bilien <jobi@litl.com>
1560 * giscanner/scannerparser.y: ignore non-UTF-8 string constants
1562 2008-10-11 Johan Bilien <jobi@litl.com>
1564 Bug 552347: Parse #defines constants
1566 * girepository/gtypelib.c: update the list of value_size
1567 with recently defined type tags
1568 * giscanner/scannerparser.y: brought back parsing of #defined, as
1569 present in older version
1570 * giscanner/giscannermodule.c: bind gi_source_scanner_append_filename
1571 * giscanner/girwriter.py: write out constant tags in the gir
1572 * giscanner/sourcescanner.py: add accessor for const_string
1573 * giscanner/transformer.py, giscanner/glibtransformer.py: handle
1576 2008-10-11 Tommi Komulainen <tommi.komulainen@iki.fi>
1578 Bug 555946: Install a test module exercising all types, transfer
1583 * tests/types/*: Add and install a test module that has functions
1584 accepting and returning most of the basic types to enable bindings
1585 implementors to more easily test their type conversion routines.
1587 2008-10-11 Jürg Billeter <j@bitron.ch>
1589 Bug 552374: Const strings should be identified in the gir.
1591 * giscanner/transformer.py: support string memory management
1592 * tests/scanner/foo.h: use char * and const char *
1593 * tests/scanner/foo-expected.gir: test that
1595 2008-10-11 Johan Dahlin <johan@gnome.org>
1597 * giscanner/girparser.py:
1598 Also parse enums which are not glib types.
1600 2008-10-11 Lucas Rocha <lucasr@gnome.org>
1602 Bug 552370: add one more test for unsigned as a type, not as
1605 * giscanner/ast.py: add 'uint' type name for 'unsigned'.
1606 * test/scanner/foo.h: add function which uses unsigned as a type.
1607 * test/scanner/foo-expected.gir: test that.
1609 2008-10-11 Andreas Rottmann <a.rottmann@gmx.at>
1611 Bug 555712: Struct and union issues
1613 * giscanner/scannerparser.y (struct_declarator): Use information
1614 provided about the bit width of a field.
1615 * giscanner/transformer.py (Transformer._create_member): Pass the
1616 symbol's const_int member to the created field (it represents the
1618 * giscanner/girwriter.py (GIRWriter._write_field): Output 'bits'
1619 field attribute, if present.
1620 * giscanner/ast.py (Field): Add 'bits' member, specifying the
1621 width in bits of the field (only relevant for bitfields).
1624 * giscanner/transformer.py (Transformer._create_typedef_struct)
1625 (Transformer._create_typedef_union): Add calls to _create_struct()
1626 and _create_union(), respectively. This causes the scanner to
1627 generate output for fields of struct and union typedefs.
1630 2008-10-11 Jürg Billeter <j@bitron.ch>
1632 Bug 552370: unsigned not scanned properly
1634 * giscanner/scannerparser.y: combine basic types such as unsigned
1635 int and long long when scanning
1636 * tests/scanner/foo-expected.gir:
1637 * tests/scanner/foo.c: (foo_test_unsigned):
1638 * tests/scanner/foo.h: test that
1640 2008-10-11 Lucas Rocha <lucasr@gnome.org>
1642 Bug 554854: The --typelib-xml and --inject options should reuse
1643 giscanner parser/writer.
1645 * giscanner/ast.py: add constructor list to Struct and Union.
1646 Add new param in Return's contructor to define transfer.
1647 * giscanner/girparser.py: several additions to the parser in order
1648 to have parsing all nodes of the gir xml files.
1649 * tools/g-ir-scanner (typelib_xml_strip, inject): use gir parser
1650 and writer in --inject and --typelib-xml options.
1651 * giscanner/xmlwriter.py: ignore empty attributes instead of
1652 raising an error as this basically exposes a bug in GIRParser.
1653 This should be reverted as soon as the parser is fixed.
1655 2008-10-11 Lucas Rocha <lucasr@gnome.org>
1657 Bug 552376: scanner generates wrong names for enum members when
1658 there's no defined gtype.
1660 * giscanner/utils.py (strip_common_prefix): Always strip common
1661 prefix exactly up to the last "_", and not beyond.
1662 * tests/scanner/foo.h (FooEnumNoType): add FOO_ENUM_NEUF. The point
1663 here is that the first character after the last '_' should should be
1664 the same as the character in the same position on the type name.
1665 * tests/scanner/foo-expected.gir: test that
1667 2008-10-10 Lucas Rocha <lucasr@gnome.org>
1669 Bug 555293: append library_paths to LPATH env variable to work
1670 around a bug in find_library when using ldconfig.
1672 * tools/g-ir-scanner (main): ditto.
1674 2008-10-09 Lucas Rocha <lucasr@gnome.org>
1676 * girepository/girepository.c (register_internal): fix regression on
1677 invoke test case by making sure we load the global module in the
1678 typelib when dealing with inline typelibs.
1679 * girepository/gtypelib.c: a couple of coding style fixes.
1681 2008-10-06 Lucas Rocha <lucasr@gnome.org>
1683 Bug 555294: Add support for multiple shared libraries per typelib.
1685 * girepository/ginvoke.c (g_function_info_invoke),
1686 girepository/ginfo.c(g_registered_type_info_get_g_type): use
1687 g_typelib_symbol instead of g_module_symbol.
1688 * girepository/girepository.h: remove g_typelib_set_module and add
1690 * girepository/gtypelib.[ch] (find_some_symbol, _g_typelib_init,
1691 g_typelib_new_from_memory, g_typelib_new_from_const_memory,
1692 g_typelib_free, g_typelib_symbol): chnage GTypeLib to hold a list of
1693 modules instead of just one. The symbol lookup is now abstracted
1694 behind g_typelib_symbol which tries to find the passed symbol name in
1696 * giscanner/girwriter.py, tools/g-ir-scanner: change scanner to read
1697 and write shared_library attribute as a comma-separated list of libs.
1699 2008-10-06 Colin Walters <walters@verbum.org>
1701 * giscanner/transformer.py: Parse length= annotation as
1702 a parameter name, not a raw int.
1705 2008-10-03 Colin Walters <walters@verbum.org>
1707 Bug 551744: Non-GObject types aren't aggregating ctors and methods
1709 * girepository/gtypelib.c: Allow ctors/methods on struct,union,
1711 * giscanner/glibtransformer.py: Ditto, and GLibBoxed is also a
1715 2008-10-03 Colin Walters <walters@verbum.org>
1717 Bug 554576: scan problem with ev_selection_render_selection()
1719 * giscanner/transformer.py: Only do type resolution once we've
1720 scanned all types. What could happen before is that we'd strip
1721 the namespace from local type "EvSelection" => Selection, and
1722 then later pull a "Selection" from some other namespace because
1723 we hadn't yet seen the local EvSelection. This could come
1724 down to hash table ordering and other things so not easy
1725 to write a test for.
1727 2008-10-03 Lucas Rocha <lucasr@gnome.org>
1729 * giscanner/girwriter.py (_parser_member): fix the last parameter of
1730 GLibEnumMember constructor as it should be the enum member nick.
1732 2008-10-02 Colin Walters <walters@verbum.org>
1734 Bug 552961: remove this parameter for methods
1736 * giscanner/glibtransformer.py: Delete this parameter; it is
1738 * girepository/ginvoke.c: Insert this parameter for methods.
1739 * girepository/gtypelib.c: Remove no longer needed verification of
1740 method this parameter.
1743 2008-09-30 Dan Winship <danw@gnome.org>
1745 Bug 554490: g-ir-scanner gets confused by '\\'
1747 * giscanner/scannerlexer.l (chartext, stringtext): fix use of
1748 backslashes so it will correctly parse '\\' and "\\"
1750 * tests/scanner/annotation.c: add a use of '\\' to make sure that
1753 * giscanner/glibtransformer.py (GLibTransformer.count_type): typo
1755 2008-10-02 Colin Walters <walters@verbum.org>
1757 bug 552393: Note variadic functions
1759 * giscanner/scannerparser.y: Parse ellipsis. Refactor grammar
1760 to use parameter_list directly.
1761 * giscanner/sourcescanner.h: Add ellipsis csymbol type.
1762 * giscanner/ast.py: Add Varargs type.
1763 * giscanner/transformer.py: Check for ellipsis symbol, transform
1765 * girepository/girnode.h: Add varargs flag to in-memory nodes.
1766 Parse varargs functions, but filter them out before we start
1767 compiling the typelib.
1769 2008-10-02 Colin Walters <walters@verbum.org>
1771 Bug 554632: type tag for GType
1773 * girepository/girepository.h, girepository/girepository.c:
1774 Add type tag for GType - it's a special type we don't want
1775 to resolve to just "long".
1776 * docs/typelib-format.txt: Update.
1777 * girepository/girparser.c: Parse it.
1778 * giscanner/glibtransformer.py: Ensure we don't put GType in
1780 * tools/generate.c: Remove hardcoded type list.
1783 2008-09-30 Dan Winship <danw@gnome.org>
1785 Bug 554521: scanner generates wrong names for enum members with
1786 full type name prefix
1788 * giscanner/utils.py (strip_common_prefix): Fix this to strip the
1789 right amount when the entire "first" string is a prefix of
1792 * tests/scanner/foo.h (FooEnumFullname):
1793 * tests/scanner/foo-expected.gir: test that
1795 2008-09-29 Colin Walters <walters@verbum.org>
1797 Bug 552380: Array parameters should be marked in the gir
1799 * giscanner/ast.py: Default char** to utf8[], and guchar* to
1800 uint8[]. Add Array, List, and Map subclasses of Type;
1801 these types can be generic. Return transfer defaults
1802 to true if return value is string or container type.
1803 Delete Sequence type.
1804 * giscanner/scannerlexer.l: Syntax change for annotations;
1805 use <> since it's more readable.
1806 * giscanner/girwriter.py: Write out these changes.
1807 * giscanner/girparser.py: Parse them.
1808 * giscanner/transformer.py: Have a defined set of
1809 both list and map types. When creating a type,
1810 check if the ctype we've parsed is one of them,
1811 if so create a container type subclass as appropriate.
1812 * girepository/girparser.c: Parse in generic types.
1815 2008-09-27 Colin Walters <walters@verbum.org>
1817 * tools/g-ir-scanner: Add --inject option.
1819 2008-09-25 Colin Walters <walters@verbum.org>
1821 Remove non-repository types from GIR
1823 * giscanner/ast.py: The canonical name is 'utf8', not
1825 * giscanner/glibast.py: A few more glib type mappings.
1826 * girepository/girparser.c: We only parse repository types.
1827 * tests/*.gir: Update.
1829 2008-09-23 Colin Walters <walters@verbum.org>
1831 Bug 552566: Add time_t type
1833 We need a type for time_t since it's special in C, and just
1834 mapping it to long precluded bindings from handling it
1837 2008-09-19 Colin Walters <walters@verbum.org>
1839 Bug 552390: Handle capitialization like "DBus" more robustly
1841 The to_underscores function was designed for use against prefixed
1842 names; we need a separate function which will convert names like
1843 DBusFoo into dbus_foo, not d_bus_foo.
1845 2008-09-19 Colin Walters <walters@verbum.org>
1847 Add check to make sure we're not hitting out unresolved types
1849 Validate the "this" argument for methods
1851 Remove heuristic matching of methods to classes based on prefix
1853 It was a broken hack that dated from when we handled underscoring
1854 and capitalization conventions less well.
1856 2008-09-18 Colin Walters <walters@verbum.org>
1858 Bug 552384: Use SHLIB_SUFFIX intead of G_MODULE_SUFFIX for Darwin
1860 On Darwin, the suffix for installed shared libraries (.dylib) is
1861 different from loadable modules (.so). We use a bit of magic shell
1862 script from Behdad Esfahbod to figure out the right suffix.
1864 2008-09-15 Johan Dahlin <johan@gnome.org>
1866 * giscanner/sourcescanner.py (SourceType.type_qualifier): Add
1867 a wrapper for type_qualifier as well.
1869 2008-09-15 Colin Walters <walters@verbum.org>
1871 http://bugzilla.gnome.org/show_bug.cgi?id=552065
1873 * giscanner/ast.py: Add deprecation attributes.
1874 * giscanner/girwriter.py: Write out deprecation data.
1875 * girepository/girparser.c: Relax parsing; deprecated
1876 attribute now includes freeform string.
1877 * giscanner/scannerlexer.l: Parse Deprecated.
1878 * giscanner/transformer.py: Look for deprecated attribute
1880 * tests/scanner/*: Add a Deprecated test.
1882 2008-09-14 Tor Lillqvist <tml@novell.com>
1884 * tests/scanner/Makefile.am (%.typelib): Use $(EXEEXT).
1886 2008-09-14 Colin Walters <walters@verbum.org>
1888 * giscanner/glibtransformer.py: Ignore functions with
1891 2008-09-12 Colin Walters <walters@verbum.org>
1893 * giscanner/glibtransformer.py: Accept Gtk.Type as GType.
1895 2008-09-12 Colin Walters <walters@verbum.org>
1897 * giscanner/ast.py: Bind pid_t to INT for vte.
1899 2008-09-12 Colin Walters <walters@verbum.org>
1901 * giscanner/girparser.py: Parse c:type for boxed records/unions.
1902 * giscanner/glibast.py: Avoid overwriting ctype.
1903 * giscsanner/transformer.py: Try resolving types using the GType names.
1905 2008-09-12 Colin Walters <walters@verbum.org>
1907 * giscanner/minixpath.py: Code to run an "XPath"
1908 assertion against an XML tree, taken from
1909 gir-repository/gir/tests.py.
1910 * giscanner/Makefile.am: Ship it.
1911 * tools/g-ir-scanner: Add --xpath-assertions option.
1912 * gir/GLib-assertions.txt: Add a few assertions.
1913 * gir/Makefile.am: Run them.
1915 2008-09-11 Colin Walters <walters@verbum.org>
1917 http://bugzilla.gnome.org/show_bug.cgi?id=551737
1919 * giscanner/transformer.py: Fix strip_namespace_func to only strip
1920 prefix if it ends with _. Tweak callback stripping to determine
1921 based on presence of _ whether we need to use strip_namespace_func
1922 or strip_namespace_object.
1924 2008-09-09 Owen Taylor <otaylor@redhat.com>
1926 * docs/typelib-format.txt: Wether => Whether
1928 2008-09-08 Colin Walters <walters@verbum.org>
1930 * girepository/girparser.c: Default to "readable" for properties.
1931 * giscanner/ast.py: Add readable, writable etc.
1932 * giscanner/girwriter.py: Writ them.
1933 * giscanner/glibtransformer.py: Inspect them.
1936 2008-09-07 Colin Walters <walters@verbum.org>
1938 * giscanner/cgobject.py: Add comment.
1940 2008-09-07 Colin Walters <walters@verbum.org>
1942 * giscanner/cgobject.py: Also call g_thread_init.
1944 2008-09-07 Colin Walters <walters@verbum.org>
1946 * giscanner/transformer.py: Fix regression by not
1947 stripping prefix before stripping namespace for unions
1950 2008-09-06 Colin Walters <walters@verbum.org>
1952 * giscanner/transformer.py: If a namespace contains
1953 multiple caps, try stripping both gnomekeyring_ and
1956 2008-09-07 Johan Dahlin <johan@gnome.org>
1958 Bug 551162 – giscanner does not recognize asm and __asm__
1959 * giscanner/scannerlexer.l:
1960 Patch by Jani Monoses.
1962 2008-09-06 Colin Walters <walters@verbum.org>
1964 * girepository/girnode.c: Allow gtype_name
1965 and gtype_init in struct and union.
1966 * girepository/girparser.c: Parse glib:
1967 boxed bits for both structure and union.
1968 * girepository/gtypelib.c: Don't barf
1969 if structure is boxed.
1970 * giscanner/girparser.py: Parse new XML
1972 * giscanner/girwriter.py: Write out new
1974 * giscanner/glibast.py: Define new classes
1975 which are both Boxed and Struct/Union, as
1976 well as an "Other" for everything else.
1977 * giscanner/glibtransformer.py: Handle
1978 boxed types specially; we try to merge
1979 them with a struct/union if one exists,
1980 otherwise fall back to generic boxed.
1982 * tools/generate.c: Write out new format.
1984 2008-09-06 Johan Dahlin <johan@gnome.org>
1986 * giscanner/grealpath.h: Include stdlib.h
1988 * docs/g-ir-generate.1: Remove leading %
1990 2008-09-01 Colin Walters <walters@verbum.org>
1992 * girepository/girparser.c: Look at c:type to determine
1993 whether or not an item is a pointer.
1995 2008-09-01 Johan Dahlin <johan@gnome.org>
1997 * tests/scanner/Makefile.am:
1998 Set PYTHONPATH so the scanner can run
1999 even if you didn't install anything.
2001 2008-09-01 Johan Dahlin <johan@gnome.org>
2004 Post-release version bump
2007 2008-09-01 Johan Dahlin <johan@gnome.org>
2011 2008-08-31 Colin Walters <walters@verbum.org>
2013 * giscanner/glibtransformer.py: Quiet info
2016 2008-08-31 Johan Dahlin <johan@gnome.org>
2019 Bump version to 0.5.0
2021 2008-08-31 Colin Walters <walters@verbum.org>
2023 * giscanner/glibtransformer.py: Follow aliases to ensure
2024 we don't get a constructor returning a basic type.
2025 * giscanner/transformer.py: Add function to follow aliases.
2028 2008-08-31 Johan Dahlin <johan@gnome.org>
2030 * giscanner/scannerlexer.l:
2031 * giscanner/scannerparser.y:
2032 * giscanner/sourcescanner.h:
2033 * giscanner/sourcescanner.py:
2034 Parse GCC extensions in the parser instead of just undeffing them
2035 in the pre-processor.
2037 2008-08-31 Johan Dahlin <johan@gnome.org>
2039 * giscanner/glibtransformer.py:
2040 Clean up a huge if. Do not add methods or constructors
2042 * giscanner/utils.py:
2043 second might be longer than first, check that.
2045 2008-08-31 Johan Dahlin <johan@gnome.org>
2050 2008-08-31 Colin Walters <walters@verbum.org>
2052 * girepository/girparser.c: Don't lose if we
2055 2008-08-31 Colin Walters <walters@verbum.org>
2057 * giscanner/glibtransformer.py: Look for libtool
2058 library in current directory
2059 * tests/scanner - Update.
2061 2008-08-30 Colin Walters <walters@verbum.org>
2063 * docs/typelib-format.txt: Add a guint32
2065 * gir/Makefile.am: Dep on Makefile
2066 * girepository/ginfo.c:
2067 * girepository/girepository.c: Clean up
2068 default typelib handling; remove global
2069 default_typelib variable. Ensure we handle
2070 NULL repository in more places.
2071 Support dependency resolution.
2072 Support lazy loading.
2073 * girepository/girepository.h: Remove
2074 g_irepository_unregister; we don't support
2075 unloading typelibs since really they're
2076 process-global. Update for lazy loading
2078 * girepository/girmodule.c: Use g_new0.
2079 Add dependencies to GirModule.
2080 * girepository/girparser.c: Parse dependencies.
2081 * girepository/gtypelib.c: Add 4 bytes for
2083 * tests/Makefile.am: Kill off gobject.gir,
2084 it conflicts with the real one.
2085 * tests/object.gir: Dep on GObject.
2086 * tools/generate.c: Take --includedir
2087 argument to say which directories to search
2088 for typelibs. Print out dependencies.
2090 2008-08-30 Colin Walters <walters@verbum.org>
2092 * giscanner/glibtransformer.py: Reduce warning noise.
2094 2008-08-29 Colin Walters <walters@verbum.org>
2096 * girepository/ginfo.c: Add some assertions regarding
2097 refcounts, just to be sure.
2098 * giscanner/glibtransformer.py: Blacklist a few more
2101 2008-08-29 Colin Walters <walters@verbum.org>
2103 * giscanner/glibtransformer.py: Blacklist a few
2104 functions that use GError oddly
2106 2008-08-29 Colin Walters <walters@verbum.org>
2108 * girepository/gtypelib.c: Don't crash if no
2111 2008-08-29 Colin Walters <walters@verbum.org>
2113 * girepository/girparser.c: Handle chains of aliases
2114 across modules by ensuring we fully qualify aliases
2117 2008-08-29 Colin Walters <walters@verbum.org>
2119 * girepository/girparser.c: Don't search aliases
2122 2008-08-29 Colin Walters <walters@verbum.org>
2124 * girepository/girparser.c: Rewrite type parsing
2125 to handle both GLib parsing case as well as correctly
2126 handling GLib.List and friends. Don't try to treat
2127 e.g. ListStore as a List.
2129 2008-08-29 Colin Walters <walters@verbum.org>
2131 * girepository/gtypelib.c: Add more context
2134 2008-08-29 Colin Walters <walters@verbum.org>
2136 * giscanner/glibtransformer.py: Add some informative
2137 logging messages in corner cases. Be sure we use
2138 the most recent node set instead of a cache
2139 when generating result set.
2140 * tests/: Remove duplicated bits in expected girs
2141 * girepository/girparser.c: Accept both List (for
2142 compiling GLib) and GLib.List (what the scanner
2145 * tools/generate.c: Generate canonical form.
2147 2008-08-29 Johan Dahlin <johan@gnome.org>
2149 * giscanner/config.py.in:
2150 Use datarootdir instead of datadir to avoid
2151 an autoconf warning.
2153 2008-08-29 Johan Dahlin <johan@gnome.org>
2157 * examples/gdk-pixbuf.gidl:
2159 Update and remove old cruft.
2161 2008-08-29 Johan Dahlin <johan@gnome.org>
2164 * docs/g-ir-compiler.1:
2165 * docs/g-ir-generate.1:
2166 * docs/g-ir-scanner.1:
2167 Add man pages for the generator and compiler.
2169 2008-08-29 Johan Dahlin <johan@gnome.org>
2171 * docs/g-ir-scanner.1: Document
2173 * giscanner/Makefile.am:
2174 * giscanner/gidlparser.py:
2175 * giscanner/gidlwriter.py:
2176 * tools/g-ir-scanner:
2177 Remove gidl support.
2179 2008-08-28 Colin Walters <walters@verbum.org>
2181 * tests/scanner/Makefile.am: Pass the right
2182 --includedir args. Add a Makefile dep.
2183 * tools/compiler.c: Pass includedirs down.
2184 * girepository/girparser.c: Actually put
2185 includedirs in context, pass down. Fix
2188 2008-08-28 Colin Walters <walters@verbum.org>
2190 * gir/Makefile.am: Use --includedir
2191 * girepository/girparser.c: Recursively parse
2192 includes to pull in aliases and expand them.
2193 We need this to avoid putting unknown names in
2195 * tools/compiler.c: Add --includedir option.
2196 * giscanner/ast.py: Map size/ssize to types
2199 2008-08-28 Tor Lillqvist <tml@novell.com>
2201 Make check now runs successfully on Windows.
2203 * tools/compiler.c (write_out_typelib): Use binary mode for output
2206 * girepository/girnode.c: Don't print NULL strings.
2208 * tests/invoke/Makefile.am
2209 * tests/scanner/Makefile.am: Use -no-undefined on Windows to
2210 convince libtool to build shared libraries.
2212 * tests/invoke/invoke.c: Don't needlessly include <dlfcn.h>. Use
2213 g_assert() instead of printing out expected errors.
2215 2008-08-28 Tor Lillqvist <tml@novell.com>
2217 * girepository/gtypelib.h: Change type of bitfield fields from
2218 guint to the most suitable smaller type. This makes the struct
2219 sizes match the ones on Linux that the sanity check expects when
2220 using gcc -mms-bitfields on Windows.
2222 2008-08-28 Johan Dahlin <johan@gnome.org>
2227 * giscanner/Makefile.am:
2228 * tests/Makefile.am:
2229 * tests/scanner/Makefile.am:
2230 Make distcheck pass.
2232 2008-08-27 Johan Dahlin <johan@gnome.org>
2234 * giscanner/Makefile.am:
2235 Only send in -no-undefined on Win32 as it breaks on MacOS X.
2237 2008-08-27 Tor Lillqvist <tml@novell.com>
2239 Make g-ir-scanner work on Windows. Still problems with the typelib
2240 code. Changes okayed by jdahlin.
2242 * configure.ac: Check for Windows, set Automake conditional
2243 OS_WIN32. Change backslashes to forward slashes in pyexecdir to
2244 avoid shell quoting issues
2246 * girepository/Makefile.am: Use -no-undefined so that libtool
2247 agrees to build a shared library on Windows.
2249 * girepository/girparser.c (backtrace_stderr): No backtrace() on
2250 Windows. Empty implementation on Windows so far.
2252 * girepository/gtypelib.c (g_typelib_check_sanity): Give more
2253 informative error message for the assertion failures. Tell also
2254 what the expected size of the struct is. Check all sizes first and
2255 fail afterwards if at least one size was different from expected.
2257 * tools/Makefile.am: Reorder libraries into proper logical
2260 * tools/generate.c: Don't include <dlfcn.h>, not used.
2262 * giscanner/Makefile.am: On Windows, link with the Python library,
2263 and install the module DLL as _giscanner.pyd. Remove the
2264 unnecessary import library and libtool library that libtool has
2267 * giscanner/scannerlexer.l: Recognize the gcc __attribute__ syntax
2268 and just skip it. Recognize also two "l" suffixes for long long
2269 constants. Recognize also __inline__.
2271 * giscanner/grealpath.h (g_realpath): Implement on Windows, using
2272 GetFullPathName(). As such, GetFullPathName() does more than the
2273 UNIX realpath(). It also changes relative paths into absolute
2274 paths. But for our purposes that shouldn't matter.
2276 * giscanner/giscannermodule.c (pygi_source_scanner_parse_file): On
2277 Windows the file descriptor passed to us is from Python. Python
2278 Python2.5 uses the msvcr71.dll C library, while mingw-built code
2279 uses msvcrt.dll. On Windows, file descriptors are specific to
2280 which C library is used. So we must find out what underlying OS
2281 handle corresponds to the file descriptor Python passes us, and
2282 then make that into a file descriptor valid for the C library this
2285 * giscanner/sourcescanner.py (_parse): Don't need to bypass
2286 __attribute__ as the lexer now handles it. The definition as empty
2287 was ineffective for mingw anyway, as mingw's _mingw.h undefines
2288 __attribute__. Close the temp file before unlinking it.
2290 * giscanner/cgobject.py: Use correct library name for the gobject
2293 * gir/Makefile.am: Must pass the full basename of the DLLs on
2294 Windows to g-ir-scanner. It's a bit ugly that we have to "know"
2295 that the names of the GLib DLLs are like libglib-2.0-0.dll, but in
2296 reality they won't change, until there is a GLib 3, and then also
2297 the Unix code here needs changing.
2299 Must pass CPPFLAGS to g-ir-scanner when building GLib.gir so that
2302 2008-08-26 Colin Walters <walters@verbum.org>
2304 * girepository/girepository.c: Search
2305 $DATADIR/girepository instead of
2306 $DATADIR/gitypelibs; this naming makes
2307 it clearer that e.g. jgir can install
2309 * gir/Makefile.am: Install there.
2311 2008-08-26 Colin Walters <walters@verbum.org>
2313 * girepository/gtypelib.c (_g_typelib_init): Also
2314 use G_MODULE_SUFFIX instead of hardcoding .so.
2316 2008-08-26 Colin Walters <walters@verbum.org>
2318 * girepository/gtypelib.c (_g_typelib_init): Free
2319 string in the right place.
2321 2008-08-26 Colin Walters <walters@verbum.org>
2323 * girepository/gtypelib.c (_g_typelib_init): Handle
2324 both .la and .so names; this works better in the
2325 uninstalled library case.
2327 2008-08-26 Johan Dahlin <johan@gnome.org>
2330 * giscanner/Makefile.am:
2331 * giscanner/cgobject.py:
2332 * giscanner/config.py.in:
2333 * giscanner/sourcescanner.py:
2334 Avoid undeffing __GNUC__, instead define
2335 __attribute__ & friends. Remove glibconfig.h hack.
2336 This makes gobject-introspection work better on
2337 MacOS X, Thanks to Richard Hult for kind help.
2339 2008-08-25 Colin Walters <walters@verbum.org>
2341 * giscanner/glibtransformer.py: Always print
2344 2008-08-25 Colin Walters <walters@verbum.org>
2346 * giscanner/glibtransformer.py: Skip over
2347 interfaces we don't know.
2349 2008-08-25 Colin Walters <walters@verbum.org>
2351 * girepository/girparser.c: Parse new implements
2352 syntax, drop gapi one.
2353 * tests/object.gir: Update.
2354 * tools/generate.c: Generate new syntax.
2356 2008-08-25 Colin Walters <walters@verbum.org>
2358 * giscanner/ast.py: Add interfaces property
2360 * giscanner/girwriter.py: Write out implemented
2362 * giscanner/glibtransformer.py: Introspect
2363 implemented interfaces.
2364 * tests/scanner/*: Make FooObject implement
2367 2008-08-25 Colin Walters <walters@verbum.org>
2369 * giscanner/glibtransformer.py: More correctly pair
2370 methods; if we have a symbol that starts with
2371 e.g. hippo_canvas look for a matching HippoCanvas
2372 class before accepting e.g. HippoCanvasImage.
2374 2008-08-24 Colin Walters <walters@verbum.org>
2376 * tools/g-ir-scanner: Filter out unknown options from
2379 2008-08-24 Colin Walters <walters@verbum.org>
2381 * giscanner/glibtransformer.py: Fail with better
2382 error if we can't find library.
2384 2008-08-24 Colin Walters <walters@verbum.org>
2386 * tools/g-ir-scanner: Use subprocess instead of
2387 commands, works on Windows and avoids the evil
2390 2008-08-24 Colin Walters <walters@verbum.org>
2392 * giscanner/glibtransformer.py: Skip over
2393 g_object_get_type from GLib trunk.
2395 2008-08-24 Colin Walters <walters@verbum.org>
2397 * girepository/girepository.c (g_irepository_require):
2398 Don't open shared library here; we already do it
2401 2008-08-24 Colin Walters <walters@verbum.org>
2403 * girepository/gtypelib.c: Add context stack so
2404 when we get an error we can print out nicely
2407 2008-08-24 Johan Dahlin <johan@gnome.org>
2409 * girepository/girparser.c (start_glib_boxed), (start_function),
2410 (start_field), (start_alias):
2411 Refactor a couple of parsing functions to be simpler to follow.
2414 2008-08-24 Johan Dahlin <johan@gnome.org>
2416 * girepository/girparser.c (start_function):
2417 Remove left-over code, checking type of function.
2419 2008-08-23 Colin Walters <walters@verbum.org>
2421 * giscanner/config.py: Define DATADIR.
2422 * giscanner/transformer.py: Look in DATADIR.
2424 2008-08-23 Colin Walters <walters@verbum.org>
2426 * girepository/gtypelib.c: Check constructor
2428 * girepository/girnode.c: Small tweaks.
2429 * girepository/ginfo.c: Calculate signature offsets
2431 * girepository/girparser.c: Remove duplicate
2433 * giscanner/glibtransformer.py: Avoid marking
2434 functions which return a basic type as
2437 2008-08-23 Colin Walters <walters@verbum.org>
2439 * girepository/girparser.c: Ignore <include>.
2440 * giscanner/girparser.py: Parse them.
2441 * giscanner/girwriter.py: Generate them.
2442 * giscanner/transformer.py: Process <include>
2443 recursively. Don't require full path for
2444 includes, look in {$XDG_DATA_DIRS}/gir.
2445 * tools/g-ir-scanner: Pass through includes.
2446 * Makefile.am: Remove extra --include
2448 * *-expected.gir: Add expected includes.
2450 2008-08-23 Johan Dahlin <johan@gnome.org>
2452 * tests/scanner/Makefile.am:
2453 * tests/scanner/annotation-expected.gir:
2454 * tests/scanner/drawable-expected.gir:
2455 Avoid duplication in the Makefile, regenerate with new
2456 namespaces (same as the filename)
2458 2008-08-22 Colin Walters <walters@verbum.org>
2460 * girepository/girnode.c: Don't hardcode integers,
2463 2008-08-22 Johan Dahlin <johan@gnome.org>
2465 * giscanner/sourcescanner.py:
2466 Check for ../gobject-introspection-1.0.pc.in to determine
2467 if we run installed or uninstalled.
2469 2008-08-22 Johan Dahlin <johan@gnome.org>
2472 * giscanner/sourcescanner.py:
2473 Send in undefs/defines via writing it directly to stdin
2474 of cpp instead of via arguments.
2476 2008-08-22 Colin Walters <walters@verbum.org>
2478 * tools/generate.c, tools/compiler.c: Default
2480 * all Makefile.am: Update.
2482 2008-08-22 Colin Walters <walters@verbum.org>
2484 * girepository/girparser.c: Pass through
2485 recursive types. Avoid overwriting errors.
2486 * giscanner/xmlwriter.py: Always write the
2488 * tests/*.gir: Adjust.
2489 * tests/scanner/Makefile.am: Build typelibs,
2490 and generate XML from those. Once we
2491 have a good diff mechanism...
2492 * tests/scanner/*-expected.gir: Add XML
2494 * tools/g-ir-scanner: Accept --typelib-xml
2496 * tools/generate.c: Better defaults for transfer.
2498 2008-08-22 Johan Dahlin <johan@gnome.org>
2502 * giscanner/Makefile.am:
2503 * giscanner/config.py.in:
2504 * giscanner/sourcescanner.py:
2505 Use the generated glibconfig.h for all scanner invokations.
2506 Rename it to glibconfig-scanner.h and install it.
2507 Add a config.py which so far contains the include dir.
2509 2008-08-22 Johan Dahlin <johan@gnome.org>
2512 Replace glibconfig.h with our own, do some replacement
2513 for CPP/C features we do not support
2515 2008-08-22 Colin Walters <walters@verbum.org>
2517 * tools/generate.c (write_callable_info): Fix unref
2520 2008-08-22 Colin Walters <walters@verbum.org>
2522 * gobject-introspection-1.0.pc.in: Add g-ir-generate.
2523 * tests/Makefile.am: Support $(DEBUG)
2524 * tools/generate.c: Do immediate close tags if no
2527 2008-08-21 Colin Walters <walters@verbum.org>
2529 * tests/scanner/drawable-expected.gir,
2530 * tests/scanner/drawable.c,
2531 * tests/scanner/drawable.h:
2534 2008-08-21 Colin Walters <walters@verbum.org>
2536 * giscanner/glibtransformer.py: Compute prefix
2537 by searching through the symbol for bits
2538 rather than going directly from ctype; this fixes
2541 2008-08-21 Colin Walters <walters@verbum.org>
2543 * giscanner/glibtransformer.py: Also try squashing
2544 underscores from namespace, fixes webkit_web_view_new.
2546 2008-08-21 Colin Walters <walters@verbum.org>
2548 * giscanner/glibtransformer.py: More ctor work,
2549 avoid having gtk_window_group_new end up under
2552 2008-08-21 Colin Walters <walters@verbum.org>
2554 * giscanner/glibtransformer.py: Much simpler approach
2555 of mapping uscored names to classes.
2556 * giscanner/utils.py: Remove unnecessary function.
2558 2008-08-21 Johan Dahlin <johan@gnome.org>
2560 * girepository/girepository.c (g_irepository_require):
2561 Plug memory leak and avoid using freed memory.
2562 Resolve the whole module path, here as well.
2564 2008-08-21 Colin Walters <walters@verbum.org>
2566 * giscanner/glibtransformer.py: Look up all permutations
2567 of class names when scanning methods/ctors based on
2568 the prefix instead of using the return value. This
2569 associates gtk_window_new with the right class.
2571 2008-08-21 Colin Walters <walters@verbum.org>
2573 * girepository/girmodule.c (g_ir_module_build_typelib):
2574 Revert change to increment header_size; we do that in
2577 2008-08-21 Colin Walters <walters@verbum.org>
2579 * girepository/girnode.c (write_string): Tweak to
2580 use UINT instead of INT. Not likely to matter.
2581 * girepository/girmodule.c (g_ir_module_build_typelib):
2582 Add to header_offset as well for header strings
2583 to match what write_string does.
2584 * girepository/gtypelib.c: Replace is_name with
2585 validate_name, which more strongly validates and
2586 handles errors in a better way. Update all callers.
2587 * giscanner/glibtransformer.py: Handle constructors
2590 2008-08-21 Johan Dahlin <johan@gnome.org>
2592 * gir/Makefile.am (typelibs_DATA): Build and
2593 install the Gio.typelib too
2595 * girepository/gtypelib.c (_g_typelib_init):
2596 Use g_module_build_path to resolve the shlib name
2598 2008-08-21 Colin Walters <walters@verbum.org>
2600 * gir/Makefile.am: CLEANFILES typelibs too.
2602 2008-08-21 Johan Dahlin <johan@gnome.org>
2604 * giscanner/glibtransformer.py:
2605 Do not send .la files through find_library.
2607 2008-08-21 Colin Walters <walters@verbum.org>
2609 * girepository/girparser.c (g_irepository_require):
2610 Fix one small leak in error case.
2612 2008-08-21 Johan Dahlin <johan@gnome.org>
2615 Parse glibconfig.h as well and install the compiled
2618 2008-08-21 Johan Dahlin <johan@gnome.org>
2621 * giscanner/glibtransformer.py:
2622 * tools/g-ir-scanner:
2623 Do not hard-core library names in the Makefile, reuse
2624 ctypes find_library instead.
2626 2008-08-21 Johan Dahlin <johan@gnome.org>
2628 * girepository/girparser.c (resolve_aliases):
2629 Remove compilation warnings
2631 2008-08-21 Johan Dahlin <johan@gnome.org>
2633 * girepository/girepository.c (g_irepository_require):
2634 Rewrap and fix double free bug by leaking a bit.
2636 2008-08-20 Colin Walters <walters@verbum.org>
2638 * girepository/girepository.c: Add new function
2639 g_irepository_get_typelib_path which tells
2640 us from where we loaded a namespace.
2642 2008-08-20 Colin Walters <walters@verbum.org>
2644 * tests/scanner/*-expected.gir: Adjust for
2645 added shared-library.
2646 * giscanner/giwriter.py: Make pylint happy.
2648 2008-08-20 Colin Walters <walters@verbum.org>
2650 * girepository/girmodule.c (g_ir_module_build_typelib):
2651 Calculate size correctly, avoid use-after-free.
2653 2008-08-20 Colin Walters <walters@verbum.org>
2655 * girepository/girepository.c: Remove
2656 g_irepository_register_file in favor of
2657 g_irepository_require. There are two
2658 possible deployment scenarios for typelibs:
2659 First, separate in $DATADIR/gitypelibs/. Second,
2660 they may be embedded in shlibs. However since
2661 the first is now the normal case, the API is
2662 optimized around it.
2664 Refactor internals to look up typelibs for
2665 namespaces just-in-time, but we expect
2666 consumers to call g_irepository_require.
2668 Also, add some docs. No one has died from that
2670 * gir/Makefile.am: Need --library for glib.
2671 * giscanner/girwriter.py: Write out shared-library.
2672 * tools/g-ir-writer: Take the first --library
2673 argument as the target of shared-library. In
2674 the future we should make this nicer with pkg-config
2677 2008-08-20 Colin Walters <walters@verbum.org>
2679 * girepository/girparser.py: And parse them.
2681 2008-08-20 Johan Dahlin <johan@gnome.org>
2683 * giscanner/glibast.py: Add gshort/gushort types
2685 2008-08-20 Colin Walters <walters@verbum.org>
2687 * gir/Makefile.am: Rename .gir files using GI namespace.
2688 * girepository/girepository.c: Use XDG_DATA_DIRS for
2689 looking up typelibs. Also typelibs are now suffixed
2691 * tests/invoke/Makefile.am: Only use metadata.
2692 * girepository/Makefile.am: Remove unnecessary include.
2693 * tests/scanner/Makefile.am: Update using GI namespaces
2694 for scanner includes.
2696 2008-08-20 Colin Walters <walters@verbum.org>
2698 * girepository/transformer.py: Suppress aliases whose
2700 * girepository/ast.py: Define some more aliases.
2702 2008-08-20 Colin Walters <walters@verbum.org>
2704 * girepository/girparser.c: Avoid alias infloops.
2706 2008-08-20 Colin Walters <walters@verbum.org>
2708 * tests/scanner/foo-expected.gir: Fix expected list type.
2710 2008-08-20 Johan Dahlin <johan@gnome.org>
2712 * giscanner/glibtransformer.py (GLibTransformer._resolve_type_name):
2713 Add a workaround for #548689.
2714 We can now compile gtk!
2716 2008-08-20 Colin Walters <walters@verbum.org>
2718 * giscanner/glibtransformer.py: Try to look up
2719 aliases using the c:type too.
2721 2008-08-20 Colin Walters <walters@verbum.org>
2723 * girepository/girparser.c: Parse union fields.
2725 2008-08-20 Johan Dahlin <johan@gnome.org>
2727 * giscanner/ast.py: Make time_t an alias for long
2729 * gir/gio-2.0-good.gir:
2730 * gir/glib-2.0-good.gir:
2731 * gir/gobject-2.0-good.gir:
2733 * giscanner/glibtransformer.py:
2734 Do not delete Class structures, we need them in gdk/gtk.
2735 * tests/scanner/drawable-expected.gir:
2736 * tests/scanner/foo-expected.gir:
2737 * tests/scanner/utility-expected.gir:
2740 2008-08-20 Johan Dahlin <johan@gnome.org>
2742 * tests/scanner/Makefile.am:
2743 * tests/scanner/annotation-expected.gir:
2744 * tests/scanner/annotation.c (annotation_object_class_init),
2745 (annotation_object_init), (annotation_object_method),
2746 (annotation_object_in), (annotation_object_out),
2747 (annotation_object_inout), (annotation_object_inout2),
2748 (annotation_object_inout3), (annotation_object_calleeowns),
2749 (annotation_object_calleesowns), (annotation_object_get_strings),
2750 (annotation_object_with_voidp), (annotation_object_get_objects),
2751 (annotation_object_create_object), (annotation_object_allow_none):
2752 * tests/scanner/annotation.h:
2753 * tests/scanner/foo-expected.gir:
2754 * tests/scanner/foo.c:
2755 * tests/scanner/foo.h:
2756 Split out annotation tests out of foo
2758 2008-08-20 Johan Dahlin <johan@gnome.org>
2760 * tests/scanner/Foo-expected.gir:
2761 * tests/scanner/Makefile.am:
2762 * tests/scanner/foo-expected.gir:
2763 * tests/scanner/foo-object.h:
2764 * tests/scanner/foo.c:
2765 Foo->foo, foo-object.h -> foo.h
2767 2008-08-20 Johan Dahlin <johan@gnome.org>
2769 * tests/scanner/Foo-expected.gir:
2770 * tests/scanner/Makefile.am:
2771 * tests/scanner/drawable-expected.gir:
2772 * tests/scanner/drawable.c (test_drawable_class_init),
2773 (test_drawable_init):
2774 * tests/scanner/drawable.h:
2775 * tests/scanner/foo-object.h:
2776 * tests/scanner/foo.c (foo_boxed_method):
2777 Move the drawable parts out of Foo to its own test.
2779 2008-08-20 Johan Dahlin <johan@gnome.org>
2781 * tests/scanner/Foo-expected.gir:
2782 * tests/scanner/foo-object.h:
2783 * tests/scanner/foo.c (foo_drawable_class_init),
2784 (foo_drawable_init):
2785 Add a based on GdkDrawable which generates
2788 2008-08-19 Colin Walters <walters@verbum.org>
2790 * giscanner/transformer.py: Don't try
2791 to strip prefix before namespace.
2793 2008-08-19 Johan Dahlin <johan@gnome.org>
2795 * giscanner/transformer.py:
2796 * tests/scanner/Foo-expected.gir:
2797 * tests/scanner/foo-object.h:
2798 Add support for typedef void foo type of
2801 2008-08-19 Johan Dahlin <johan@gnome.org>
2804 * giscanner/girwriter.py:
2805 * giscanner/glibtransformer.py:
2806 * giscanner/transformer.py:
2807 * tests/scanner/Foo-expected.gir:
2808 Add basic support for union, base the code much
2809 on Struct. Add a testcase.
2811 2008-08-19 Johan Dahlin <johan@gnome.org>
2813 * tests/scanner/Foo-expected.gir:
2814 * tests/scanner/foo-object.h:
2815 Add a union testcase which the compiler currently
2818 2008-08-19 Johan Dahlin <johan@gnome.org>
2820 * gobject-introspection-1.0.pc.in:
2821 Add a g_ir_compiler variable
2823 2008-08-19 Colin Walters <walters@verbum.org>
2825 * giscanner/ast.py: Rework types to be more closely
2827 * giscanner/girparser.py: Parse more bits.
2828 * giscanner/girwriter.py: Write sequences in a new
2829 way that specifies container type.
2830 * giscanner/glibast.py: Adjust for ast.py changes,
2831 add 'ctype' property to GLibObject and GLibInterface
2832 so we can look things up by it later.
2833 * gicanner/transformer.py: Names is new class holding
2834 the various namespaces we manage. Do not confuse
2835 with Namespace which is toplevel XML node effectively.
2836 Rework all type resolution to go through
2837 _resolve_type_name_1.
2838 * giscanner/glibtransformer.py: Raise UnknownTypeError
2839 instead of ValueError for cleanliness. Add Unresolved
2840 class to mark types whose parent we haven't seen yet.
2841 Use new Names object from transformer.py.
2842 Correctly look up parent=.
2843 Fix type validation to handle sequences.
2844 * tests/scanner/Foo-expected.gir: Update for sequence
2845 work, int instead of int32.
2846 * tools/g-ir-scanner: Add --noclosure option
2847 * gir/Makefile.am: Use --noclosure by default for
2850 2008-08-18 Johan Dahlin <johan@gnome.org>
2852 * gir/gio-2.0-good.gir:
2853 * gir/glib-2.0-good.gir:
2854 * gir/gobject-2.0-good.gir:
2857 2008-08-18 Johan Dahlin <johan@gnome.org>
2860 * giscanner/girparser.py:
2861 * giscanner/girwriter.py:
2862 * giscanner/glibast.py:
2863 * giscanner/glibtransformer.py:
2864 * giscanner/transformer.py:
2865 * tests/scanner/Foo-expected.gir:
2866 * tests/scanner/foo-object.h:
2867 * tests/scanner/utility-expected.gir:
2868 * tests/scanner/utility.h:
2869 Redo type resolving and validation.
2870 Add a couple of new tests.
2871 Patch mostly written by Colin.
2873 2008-08-18 Johan Dahlin <johan@gnome.org>
2876 * giscanner/girparser.py:
2878 * giscanner/transformer.py:
2879 Improve enum parsing for enums without a GType.
2880 Make flags/enum references to other girs work
2881 * giscanner/utils.py:
2883 * tests/scanner/Makefile.am:
2884 * tests/scanner/foo-object.h:
2885 * tests/scanner/utility-expected.gir:
2886 * tests/scanner/utility.h:
2887 Add a new test for external enum references
2889 2008-08-18 Johan Dahlin <johan@gnome.org>
2891 * docs/global-module-registry.txt: Update
2893 * tests/array.gir: Update with new type proposal
2895 * girepository/girepository.c (g_type_tag_to_string):
2896 * girepository/girepository.h:
2897 * girepository/girnode.c (g_ir_node_get_full_size_internal),
2899 * girepository/girnode.h:
2900 Make enum serializing functions public. Clean up some whitespace.
2902 2008-08-17 Johan Dahlin <johan@gnome.org>
2904 * docs/global-module-registry.txt:
2905 Add a document for an on disk module registry format
2907 2008-08-17 Johan Dahlin <johan@gnome.org>
2910 * gir/gio-2.0-good.gir:
2913 2008-08-17 Johan Dahlin <johan@gnome.org>
2916 * gir/glib-2.0-good.gir:
2917 * gir/gobject-2.0-good.gir:
2918 * giscanner/cgobject.py:
2919 * giscanner/glibtransformer.py:
2920 Regenerate GObject & GType.
2921 Avoid warnings when generating gobject-2.0.gir.
2922 Introspect a little more, and skip *_get_type functions.
2924 2008-08-17 Colin Walters <walters@verbum.org>
2926 * gir/glib-2.0.gir, gir/gobject-2.0.gir:
2927 Rename to -good, always generate during build.
2928 * gir/Makefile.am: Ensure .gir files dep on
2929 all scanner sources.
2930 * Makefile.am: Switch build order to ensure
2931 the scanner is ready before we do gir/.
2932 * tools/g-ir-scanner: Look for .git too.
2934 2008-08-17 Johan Dahlin <johan@gnome.org>
2936 * girepository/gtypelib.c (validate_enum_blob):
2937 * giscanner/glibtransformer.py:
2938 * giscanner/transformer.py:
2939 Remove resolve_possible_typedefs, it was unused.
2940 Allow multiple enum values of the sample value in an enum,
2941 since it's actually pretty common.
2942 Register enums so they can be resolved too.
2944 2008-08-16 Johan Dahlin <johan@gnome.org>
2946 * giscanner/girparser.py:
2947 Parse enumeration/bitfield.
2949 2008-08-16 Johan Dahlin <johan@gnome.org>
2951 * giscanner/girparser.py:
2954 2008-08-16 Johan Dahlin <johan@gnome.org>
2956 * giscanner/glibtransformer.py:
2957 Resolve type names for alias targets
2958 * giscanner/transformer.py:
2959 Skip FILE* parameters fow now
2961 2008-08-16 Johan Dahlin <johan@gnome.org>
2964 * gir/gobject-2.0.gir:
2967 * tests/scanner/Makefile.am:
2970 2008-08-15 Colin Walters <walters@verbum.org>
2972 * giscanner/glibtransformer.py: Explicitly construct
2973 new list, since we're deleting as we iterate.
2974 Don't delete all structures which end in Class; just
2975 ones which have a paired GObject.
2976 Fix printing of type warning.
2977 * giscanner/transformer.py: Make strip_namespace_object
2978 be the identity function if it doesn't match the
2981 2008-08-15 Colin Walters <walters@verbum.org>
2983 * giscanner/cgobject.py: Define yet more argument
2984 prototypes; fix prototype for g_type_fundamental.
2986 2008-08-14 Johan Dahlin <johan@gnome.org>
2988 * tests/Makefile.am:
2989 * tests/constant.gir:
2990 * tests/gobject.gir:
2992 * tools/generate.c (write_struct_info):
2993 Fix generator for constant/gobject/struct
2995 2008-08-14 Johan Dahlin <johan@gnome.org>
2997 * tests/Makefile.am:
2999 * tools/generate.c (write_enum_info):
3000 Fix generation of enum/bitfields
3002 2008-08-14 Johan Dahlin <johan@gnome.org>
3004 * girepository/girparser.c (start_field), (start_constant),
3005 (start_type), (end_element_handler):
3006 Clear up constant parsing
3011 * tools/generate.c (write_callable_info), (write_function_info),
3012 (write_callback_info), (write_constant_info), (write_signal_info),
3013 (write_vfunc_info), (write_property_info), (write_object_info),
3014 (write_interface_info):
3015 Constants/Signals are handled now.
3017 2008-08-14 Johan Dahlin <johan@gnome.org>
3019 * girepository/girparser.c (start_type):
3020 Don't require c:type.
3021 * tests/Makefile.am:
3024 Update, remove parts we don't support yet
3025 * tests/roundtrips.sh:
3027 * tools/generate.c (write_type_info), (write_field_info),
3028 (write_callable_info), (write_struct_info):
3029 Make it emit proper gir.
3031 2008-08-14 Johan Dahlin <johan@gnome.org>
3033 * giscanner/transformer.py:
3034 New internal function for adding a new node.
3036 2008-08-14 Johan Dahlin <johan@gnome.org>
3039 Define an internal _H_ variable so we skip parsing both
3040 i18n headers, only one is needed.
3042 Add the glib-2.0.gir too.
3043 * giscanner/glibast.py:
3044 Add gconstpointer as an alias for ANY
3045 * giscanner/transformer.py:
3046 Do not lower case enumeration names per se.
3047 Skip functions which has parameters called 'va_list'
3049 2008-08-14 Colin Walters <walters@verbum.org>
3051 * giscanner/transformer.py: Comment data structures.
3052 Also squash pointers in resolve_type_name to correspond
3053 with what we do for params.
3054 * giscanner/glibtransformer.py: Print warnings in more
3055 situations. Rework checks for method/constructor to
3056 look up in our GType database instead of just checking
3057 for *. Avoid generating <record> for GObject which
3058 duplicate the <class>.
3059 * gir/Makefile.am: Generate glib-2.0.gir and gobject-2.0.gir
3062 2008-08-14 Johan Dahlin <johan@gnome.org>
3064 * giscanner/girwriter.py:
3065 * giscanner/glibast.py:
3066 * giscanner/glibtransformer.py:
3067 * giscanner/transformer.py:
3069 * tests/Makefile.am:
3070 Add pyflakes.py and run it in make check.
3071 Update the source code to fix the errors reported by
3074 2008-08-14 Johan Dahlin <johan@gnome.org>
3077 * giscanner/girparser.py:
3078 * giscanner/glibast.py:
3079 * giscanner/glibtransformer.py:
3080 Refactor the parser a bit.
3081 Add parent type to interfaces and update callsites.
3083 2008-08-14 Johan Dahlin <johan@gnome.org>
3085 * giscanner/glibtransformer.py:
3086 * giscanner/utils.py:
3087 Refactor a bit, avoid isinstance and add a method
3088 for each type we parse.
3090 2008-08-14 Johan Dahlin <johan@gnome.org>
3093 * giscanner/girparser.py:
3094 * giscanner/glibtransformer.py:
3095 * tests/Makefile.am:
3096 Run pep8.py in make check, fix old errors.
3098 2008-08-13 Colin Walters <walters@verbum.org>
3100 * giscanner/girparser.py: Parse records.
3102 2008-08-13 Colin Walters <walters@verbum.org>
3104 * gir/Makefile.am: Install again.
3105 * gir/gobject-2.0.gir: Add some more bits.
3107 2008-08-13 Colin Walters <walters@verbum.org>
3109 * gir/gobject-2.0.gir: Use correct namespace, add GType.
3110 * giscanner/girparser.py: Handle aliases.
3111 * giscanner/transformer.py: Record aliases. Make resolver
3112 functions public; we now call into these explicitly from
3113 glibtransformer. Handle resolving aliases.
3114 * giscanner/glibtransformer.py: Separate our internal namespace
3115 from included ones. Call up into transformer's resolver functions.
3117 2008-08-13 Johan Dahlin <johan@gnome.org>
3119 * girepository/girnode.c (g_ir_node_get_full_size_internal):
3120 * girepository/girparser.c (start_class):
3121 * giscanner/glibtransformer.py:
3122 Allow get_type to be None, set a get_type for GInitiallyUnowned too.
3124 2008-08-13 Johan Dahlin <johan@gnome.org>
3126 * giscanner/cgobject.py:
3127 Register GInitiallyUnowned
3128 * giscanner/girwriter.py:
3129 * giscanner/glibtransformer.py:
3130 Special case GObject/GInitially owned as they are a bit special to use.
3132 2008-08-13 Colin Walters <walters@verbum.org>
3134 * tests/scanner/Foo-expected.gir, tests/scanner/utility-expected.gir:
3135 Object is in GObject namespace.
3137 2008-08-13 Colin Walters <walters@verbum.org>
3139 * giscanner/girparser.py: Fix processing of functions
3142 2008-08-13 Colin Walters <walters@verbum.org>
3144 * giscanner/girparser.py: Parse more than just <class.
3145 * giscanner/glibtransformer.py: Put aliases in a separate
3146 data structure since their name is not canonicall.
3147 * giscanner/transformer.py: Handle resolving type names
3150 2008-08-13 Johan Dahlin <johan@gnome.org>
3152 * tools/g-ir-scanner:
3153 Allow multiple libraries
3154 * giscanner/glibtransformer.py:
3155 Rename load_library to add_library, traverse over all libraries
3156 when trying to resolve a function
3158 2008-08-12 Colin Walters <walters@verbum.org>
3160 * giscanner/transformer.py: Record typedefs as <alias> elements.
3161 Also attempt to look up types in external namespaces.
3162 * giscanner/girwriter.py: Write them.
3163 * giscanner/glibtransformer.py: Rework resolver using real instanceof
3164 checks. Resolve interface methods and properties.
3165 * tests/scanner/foo-object.h: Add a method with typedef.
3166 * tests/scanner/Foo-expected.gir: Update.
3167 * girepository/girnode.c: Debug tweaks.
3168 * girepository/girparser.c: Make a first pass through the XML where we
3169 record all the aliases. This lets us resolve them as we go through the
3171 * gir/Makefile.am: Don't install gobject-2.0.gir; we want that to come
3172 from gir-repository.
3174 2008-08-12 Colin Walters <walters@verbum.org>
3176 * giscanner/glibtransformer.py: Resolve typedefs (e.g. AtkAttributeSet -> GSList).
3177 Correctly do subclasseing in 2nd pass resolution. Handle callbacks in structure
3179 * giscanner/transformer.py: Record typedefs and expose public API for resolving
3181 * tests/scanner/Foo-expected.gir: Fix expected callback types.
3183 2008-08-12 Colin Walters <walters@verbum.org>
3185 * giscanner/glibtransformer.py: Also transform object properties.
3187 2008-08-12 Colin Walters <walters@verbum.org>
3189 * giscanner/glibtransformer.py: Also transform callbacks
3190 and structure field types.
3191 * tests/scanner/Fooe-expected.gir: Update to expect correct
3192 names for callbacks and structs.
3194 2008-08-12 Colin Walters <walters@verbum.org>
3196 * girepository/girparser.c: Handle 'any'.
3197 * tests/scanner/Foo-expected.gir, tests/scanner/foo-object.h:
3198 Add test for void *.
3200 2008-08-12 Colin Walters <walters@verbum.org>
3202 * giscanner/glibtransformer.py: We need to do type
3203 resolution in a second pass after we've seen all the
3204 enums, records, etc.
3206 2008-08-12 Colin Walters <walters@verbum.org>
3208 * tests/scanner/Foo-expected.gir, tests/scanner/foo-object.h:
3209 Add enum return value.
3210 * giscanner/glibtransformer.py: Transform function return types
3213 2008-08-12 Colin Walters <walters@verbum.org>
3215 * tests/scanner/Makefile.am: Dep .gir files on scanner
3216 sources too. Also remove @ so we see scanner invocations.
3218 2008-08-12 Colin Walters <walters@verbum.org>
3220 * girepository/girparser.c, girepository/gtypelib.c,
3221 girepository/gtypelib.h, girepository/girnode.c:
3222 Remove usage of (GAPI-oriented) TypeTag in favor of
3223 GITypeTag from girepository.h.
3225 2008-08-10 Colin Walters <walters@verbum.org>
3227 * tests/roundtrips.sh: Use the correct tests.
3229 2008-08-10 Colin Walters <walters@verbum.org>
3231 * giscanner/cgobject.py: Declare/wrap a few more functions.
3232 Fix parameter types for g_object_new and g_type_fundamental.
3234 2008-08-10 Colin Walters <walters@verbum.org>
3236 * giscanner/cgobject.py: Add new decorator @gwrap which forces
3237 us to declare types for both return value and parameters. The
3238 ctypes default of 'int' is bad because it hides 32/64 bit
3239 problems. Convert all existing functions to use it.
3241 2008-08-09 Johan Dahlin <johan@gnome.org>
3243 * giscanner/__init__.py:
3245 * giscanner/cgobject.py:
3246 * giscanner/gidlparser.py:
3247 * giscanner/gidlwriter.py:
3248 * giscanner/girparser.py:
3249 * giscanner/girwriter.py:
3250 * giscanner/glibast.py:
3251 * giscanner/glibtransformer.py:
3252 * giscanner/odict.py:
3253 * giscanner/sourcescanner.py:
3254 * giscanner/transformer.py:
3255 * giscanner/utils.py:
3256 * giscanner/xmlwriter.py:
3257 * tools/g-ir-scanner:
3261 2008-08-09 Johan Dahlin <johan@gnome.org>
3264 * relaxng/c-types.xml:
3265 * relaxng/g-types.xml:
3266 * relaxng/relaxng.rng:
3268 Remove outdated relaxng schemas.
3270 2008-08-09 Johan Dahlin <johan@gnome.org>
3273 Rename metadata to typelib in variable names,
3276 2008-08-09 Johan Dahlin <johan@gnome.org>
3280 Remove old C scanner, which got rewritten in python.
3282 2008-08-09 Johan Dahlin <johan@gnome.org>
3284 * girepository/Makefile.am:
3285 * tools/Makefile.am:
3286 * tools/girmodule.c:
3287 * tools/girmodule.h:
3290 * tools/girparser.c:
3291 * tools/girparser.h:
3292 * tools/girwriter.c:
3293 * tools/girwriter.h:
3294 Move shared *.[ch] files to girepository from tools
3296 2008-08-09 Johan Dahlin <johan@gnome.org>
3298 * tests/Makefile.am:
3301 * tests/constant.test:
3303 * tests/errors.test:
3304 * tests/function.test:
3305 * tests/gobject.test:
3306 * tests/interface.test:
3307 * tests/object.test:
3308 * tests/struct.test:
3313 Rename *.test to *.gir
3315 2008-08-09 Johan Dahlin <johan@gnome.org>
3318 * tests/Makefile.am:
3319 * tests/parser/Foo-expected.gir:
3320 * tests/parser/Makefile.am:
3321 * tests/parser/foo-object.h:
3322 * tests/parser/foo.c:
3323 * tests/parser/utility-expected.gir:
3324 * tests/parser/utility.c:
3325 * tests/parser/utility.h:
3326 * tests/scanner/Makefile.am:
3327 Rename tests/parser to test/scanner
3329 2008-08-08 Colin Walters <walters@verbum.org>
3331 * tests/roundtrips.sh: Use local .gir files again.
3333 2008-08-08 Colin Walters <walters@verbum.org>
3335 * tests/invoke/Makefile.am: .gir file depends on libtool
3338 2008-08-08 Colin Walters <walters@verbum.org>
3340 * tools/girnode.c: Pass through parent node so we can
3341 print the node whose child is NULL, if that occurs.
3343 2008-08-08 Johan Dahlin <johan@gnome.org>
3345 * tests/Makefile.am:
3346 Disable roundtrip tests which are not yet working
3347 * tests/invoke/testfns.gir:
3350 2008-08-08 Johan Dahlin <johan@gnome.org>
3352 * giscanner/girwriter.py:
3354 * giscanner/glibast.py:
3355 * giscanner/glibtransformer.py:
3356 Swap order of members, to keep it consistent with
3359 2008-08-08 Johan Dahlin <johan@gnome.org>
3361 * girepository/gtypelib.c (validate_header):
3362 * girepository/gtypelib.h:
3364 * giscanner/girwriter.py:
3365 * giscanner/sourcescanner.c (gi_source_symbol_ref),
3366 (gi_source_symbol_unref):
3369 * tests/constant.test:
3371 * tests/errors.test:
3372 * tests/function.test:
3373 * tests/gobject.test:
3374 * tests/interface.test:
3375 * tests/invoke/Makefile.am:
3376 * tests/invoke/testfns.xml:
3377 * tests/object.test:
3378 * tests/parser/Makefile.am:
3379 * tests/roundtrips.sh:
3380 * tests/struct.test:
3385 * tools/Makefile.am:
3386 * tools/compiler.c (main):
3387 * tools/generate.c (write_callable_info), (write_function_info),
3389 * tools/gidlmodule.c:
3390 * tools/gidlmodule.h:
3393 * tools/gidlparser.c:
3394 * tools/gidlparser.h:
3395 * tools/gidlwriter.c:
3396 * tools/gidlwriter.h:
3397 * tools/scanner.c (create_node_from_gtype),
3398 (create_node_from_ctype), (g_igenerator_process_properties),
3399 (g_igenerator_process_signals), (g_igenerator_create_object),
3400 (g_igenerator_create_interface), (g_igenerator_create_boxed),
3401 (g_igenerator_create_enum), (g_igenerator_create_flags),
3402 (g_igenerator_process_function_symbol),
3403 (g_igenerator_process_unregistered_struct_typedef),
3404 (g_igenerator_process_struct_typedef),
3405 (g_igenerator_process_union_typedef),
3406 (g_igenerator_process_enum_typedef),
3407 (g_igenerator_process_function_typedef),
3408 (g_igenerator_process_constant), (g_igenerator_process_symbols),
3409 (g_igenerator_add_module), (g_igenerator_add_include_idl):
3410 Merge in the gir-compiler branch.
3411 Thanks to Philip and Colin for their help.
3413 2008-07-26 Colin Walters <walters@verbum.org>
3415 * tools/Makefile.am (bin_PROGRAMS): Install g-idl-compiler
3416 and g-idl-generate to go along with how we're changing this
3417 module to be installed.
3418 * gobject-introspection-1.0.pc.in: Set up Cflags and Libs.
3420 2008-07-24 Colin Walters <walters@verbum.org>
3422 * girepository/girepository.c (g_irepository_register): Add
3423 environment variable G_IREPOSITORY_VERBOSE so we can print
3424 out what we're doing.
3425 * girepository/girepository.c (g_irepository_register_file):
3426 Add GError error message to g_debug call.
3428 2008-07-08 Jürg Billeter <j@bitron.ch>
3430 * giscanner/glibast.py:
3434 2008-06-21 Johan Dahlin <jdahlin@async.com.br>
3436 * giscanner/girparser.py (GIRParser._parse_api): Ignore a few
3439 2008-06-20 Johan Dahlin <jdahlin@async.com.br>
3442 * giscanner/girwriter.py:
3443 * giscanner/transformer.py:
3444 * tests/parser/Foo-expected.gir:
3445 * tests/parser/foo-object.h:
3446 * tests/parser/foo.c (foo_object_allow_none):
3447 Add support for gtk-doc annotations for allow-none.
3450 2008-06-19 Johan Dahlin <jdahlin@async.com.br>
3453 * giscanner/girwriter.py:
3454 * giscanner/glibast.py:
3455 * giscanner/glibtransformer.py:
3456 * giscanner/transformer.py:
3457 * tests/parser/Foo-expected.gir:
3458 Start using abstract type instead of the raw C types.
3459 Register a bunch of glib types we care about.
3461 2008-06-19 Rob Taylor <rob.taylor@codethink.co.uk>
3466 2008-06-08 Philip Van Hoof <pvanhoof@gnome.org>
3468 * girepository/girepository.c:
3469 * girepository/gtypelib.c:
3470 * girepository/ginfo.c:
3471 * girepository/ginvoke.c:
3472 * girepository/girepository.h:
3473 * girepository/gtypelib.h:
3474 * girepository/gmetadata.c:
3475 * girepository/Makefile.am:
3476 * girepository/gmetadata.h:
3478 * tools/gidlmodule.c:
3481 * tools/gidlmodule.h:
3482 * tools/gidlparser.c:
3484 Renamed GMetadata to GTypelib
3486 2008-06-07 Johan Dahlin <jdahlin@async.com.br>
3488 * giscanner/xmlwriter.py:
3489 Improve line wrapping when > 79 charaters
3491 2008-06-05 Jürg Billeter <j@bitron.ch>
3494 * giscanner/girwriter.py:
3495 * giscanner/transformer.py:
3496 Use <type> element for field types
3497 * tests/parser/Foo-expected.gir:
3500 2008-06-04 Johan Dahlin <jdahlin@async.com.br>
3502 * giscanner/glibtransformer.py:
3503 Fix a bug which prevented GdkEvent from being generated
3505 2008-06-03 Johan Dahlin <jdahlin@async.com.br>
3507 * giscanner/Makefile.am:
3509 * giscanner/girwriter.py:
3510 * giscanner/glibast.py:
3511 * giscanner/glibtransformer.py:
3512 * giscanner/transformer.py:
3513 * giscanner/utils.py:
3514 * tests/parser/Foo-expected.gir:
3515 Improve enum member parsing and introspection
3517 2008-05-31 Johan Dahlin <jdahlin@async.com.br>
3519 * giscanner/scannerparser.y:
3520 * giscanner/sourcescanner.h:
3521 * giscanner/sourcescanner.py:
3522 Add a new source type enum for member.
3523 Use __repr__ for improved debugging
3524 * giscanner/girparser.py:
3526 * giscanner/transformer.py:
3527 Improve parsing of struct members.
3528 * tests/parser/foo-object.h:
3531 2008-05-31 Johan Dahlin <jdahlin@async.com.br>
3533 * giscanner/xmlwriter.py:
3534 Improve error reporting when trying to quote None.
3535 * giscanner/girparser.py:
3536 Do not print warnings when including more complete .gir files
3537 * giscanner/girwriter.py:
3538 Do not require a name for parameters, add a todo for singletons
3539 * giscanner/glibtransformer.py:
3540 Refactor the way structs are done, add a couple of hacks to allow
3542 * giscanner/transformer.py:
3543 Add enough hacks so cairo, atk and pango.gir can be parsed properly
3544 * gobject-introspection-1.0.pc.in:
3545 Export girdir, so we can access gobject-2.0.gir from outside
3547 2008-05-31 Johan Dahlin <jdahlin@async.com.br>
3549 * tools/g-ir-scanner:
3550 * tests/parser/Makefile.am:
3551 Update sys.path before running the parser so we don't have
3552 to setup PYTHONPATH ourselves.
3556 * girepository/Makefile.am:
3557 * giscanner/transformer.py:
3558 * gobject-introspection-1.0.pc.in:
3559 * gobject-introspection.pc.in:
3560 * tools/Makefile.am:
3562 Rename pkg-config name to gobject-introspection-1.0,
3563 Do not installed anything which is not using the gir format.
3564 Disable compililation the old C scanner, but still keep the source
3565 until all the remaning functionallity has been ported.
3567 2008-05-31 Johan Dahlin <jdahlin@async.com.br>
3569 * giscanner/giscannermodule.c (symbol_get_ident): Prevent
3570 a crash when symbol->indent is NULL.
3572 * giscanner/sourcescanner.py (ctype_name): Add ctype_name,
3573 a function to convert a CTYPE symbol to a string
3575 2008-05-24 Johan Dahlin <jdahlin@async.com.br>
3578 * giscanner/girwriter.py:
3579 * giscanner/giscannermodule.c
3580 (pygi_source_scanner_append_filename),
3581 (pygi_source_scanner_parse_file):
3582 * giscanner/glibtransformer.py:
3583 * giscanner/sourcescanner.py:
3584 Revert back to using temporary files to send in headers.
3585 Allow Functions to be passed in as callbacks, add a couple
3586 of try/excepts missing features.
3587 We can now scan pango
3589 2008-05-08 Johan Dahlin <johan@gnome.org>
3591 * giscanner/glibtransformer.py:
3592 * giscanner/transformer.py:
3593 Move namespace stripping glibtransformer->transformer
3595 2008-05-08 Johan Dahlin <johan@gnome.org>
3598 * giscanner/girwriter.py:
3599 * giscanner/glibtransformer.py:
3600 * giscanner/transformer.py:
3601 * tools/g-ir-scanner:
3602 Introduce a namespace ast node
3604 2008-05-05 Johan Dahlin <johan@gnome.org>
3606 * giscanner/__init__.py:
3607 * giscanner/sourcescanner.py:
3608 * giscanner/transformer.py:
3609 Move sourcescanner symbols to the sourcescanner module, instead
3610 of in the global __init__ namespace.
3612 2008-05-03 Johan Dahlin <johan@gnome.org>
3614 * giscanner/glibtransformer.py:
3615 * tools/g-ir-scanner:
3616 Handle missing parameters better, allow - and + in .la dlname
3619 2008-05-03 Johan Dahlin <johan@gnome.org>
3621 * giscanner/__init__.py:
3623 * giscanner/girwriter.py:
3624 * giscanner/glibtransformer.py:
3625 * giscanner/transformer.py:
3626 Parse struct fields properly, improve debugging.
3628 2008-04-29 Johan Dahlin <johan@gnome.org>
3631 * giscanner/girwriter.py:
3632 * giscanner/transformer.py:
3633 * tests/parser/Foo-expected.gir:
3635 Use transfer-ownership everywhere, to mark ownership/calle/caller etc.
3637 2008-04-29 Johan Dahlin <jdahlin@async.com.br>
3640 * docs/g-ir-scanner.1:
3641 * metadata-annotations-proposal.txt:
3642 * metadata-format.txt:
3643 Add a basic, unfinshed man page for g-ir-scanner, move documents into .txt
3645 2008-04-29 Johan Dahlin <jdahlin@async.com.br>
3647 * giscanner/girwriter.py:
3648 * giscanner/glibtransformer.py:
3649 * giscanner/transformer.py:
3650 * giscanner/xmlwriter.py:
3651 * tests/parser/Foo-expected.gir:
3652 * tests/parser/foo-object.h:
3653 Write record/structs to gir file too. Add a couple of tests,
3654 fix an off by one error in xmlwriter.py.
3656 2008-04-28 Johan Dahlin <johan@gnome.org>
3658 * giscanner/xmlwriter.py: Calculate the line length properly,
3659 include the provided extra indentation in the calculation, really.
3661 2008-04-28 Johan Dahlin <jdahlin@async.com.br>
3664 * giscanner/glibast.py:
3665 * giscanner/glibtransformer.py:
3666 * giscanner/transformer.py:
3667 * tools/g-ir-scanner:
3668 Add a --strip-prefix and sort out confusion between names and symbols
3669 for functions and struct + derivaties.
3670 Refactor bootstrap of g-ir-scanner, so we can set options on
3671 Transformer() before parsing everything.
3673 2008-04-28 Johan Dahlin <johan@gnome.org>
3675 * giscanner/transformer.py (Transformer._traverse_one): Avoid recursion
3676 when scanning girepository.h
3678 * giscanner/sourcescanner.py (SourceScanner._preprocess): Define
3679 a __GI_SCANNER__ when we run.
3681 2008-04-28 Johan Dahlin <jdahlin@async.com.br>
3684 * giscanner/girwriter.py:
3685 * giscanner/glibast.py:
3686 * giscanner/glibtransformer.py:
3687 * tests/parser/Foo-expected.gir:
3688 * tests/parser/utility-expected.gir:
3689 Rename most c:identifier to c:type. Add new ones to
3690 class/interface/enum/boxed.
3692 2008-04-28 Johan Dahlin <jdahlin@async.com.br>
3695 * giscanner/girwriter.py:
3696 * giscanner/glibtransformer.py:
3697 * tests/parser/Foo-expected.gidl:
3698 * tests/parser/Makefile.am:
3699 Move c:identifier from return-value to subchild type,
3700 as per Jürgs suggestion
3702 2008-04-28 Johan Dahlin <johan@gnome.org>
3704 * giscanner/girwriter.py:
3705 * tests/parser/Foo-expected.gir:
3706 Write property.type as a child node.
3708 2008-04-27 Johan Dahlin <johan@gnome.org>
3713 * gidl/gobject-2.0.gidl:
3715 * gir/gobject-2.0.gir:
3716 * tests/parser/Makefile.am:
3717 Replace the GObject gidl with a GObject gir.
3719 2008-04-27 Johan Dahlin <johan@gnome.org>
3721 * tools/Makefile.am (bin_SCRIPTS): g-ir-scanner is a script,
3724 * giscanner/xmlwriter.py:
3725 * tests/parser/Foo-expected.gir:
3726 Include indentation in line length calculation
3728 2008-04-27 Johan Dahlin <johan@gnome.org>
3730 * giscanner/girparser.py:
3731 Prettify NS parsing using elementtree.
3733 2008-04-27 Johan Dahlin <johan@gnome.org>
3736 * giscanner/Makefile.am:
3737 * giscanner/girparser.py:
3738 * giscanner/glibtransformer.py:
3739 * tests/parser/Foo-expected.gidl:
3740 * tests/parser/Foo-expected.gir:
3741 * tests/parser/Makefile.am:
3742 * tests/parser/utility-expected.gidl:
3743 * tests/parser/utility-expected.gir:
3744 * tools/g-ir-scanner:
3745 Switch over to GIR as the default format. Add a simple GIDL
3747 Update tests and fix simplify makefiles by depending
3748 on GNU make extensions.
3750 2008-04-27 Johan Dahlin <johan@gnome.org>
3752 * giscanner/xmlwriter.py:
3753 Wrap attributes for lines which are wider than 79 characters
3755 * giscanner/scannerlexer.l:
3756 Allow parenthesis in annotations
3759 * giscanner/gidlwriter.py:
3760 * giscanner/girwriter.py:
3761 * giscanner/glibtransformer.py:
3762 * giscanner/transformer.py:
3763 Add initial sequence support, including annotation.
3764 Refactor type handling a bit.
3766 2008-04-27 Johan Dahlin <johan@gnome.org>
3768 * tests/parser/Foo-expected.gidl:
3769 * tests/parser/foo-object.h:
3770 * tests/parser/foo.c (foo_object_class_init),
3771 (foo_object_get_strings), (foo_object_get_objects):
3772 Add two new functions to check sequence return values.
3773 Also fixes a compilation warning.
3775 2008-04-27 Johan Dahlin <johan@gnome.org>
3777 * giscanner/giscannermodule.c (]): Cast the getter, avoids
3778 a compilation warning.
3780 * tools/Makefile.am (g_ir_scanner_SOURCES):
3781 g-ir-scanner has no sources.
3783 2008-04-25 Johan Dahlin <johan@gnome.org>
3785 * giscanner/Makefile.am:
3787 * giscanner/gidlparser.py:
3788 * giscanner/gidlwriter.py:
3789 * giscanner/girwriter.py:
3790 * giscanner/glibast.py:
3791 * giscanner/glibtransformer.py:
3792 * giscanner/transformer.py:
3793 Split out nodes to ast.py and glibast.py
3795 2008-04-25 Johan Dahlin <jdahlin@async.com.br>
3797 * giscanner/Makefile.am:
3798 * giscanner/gidlparser.py:
3799 * giscanner/gidlwriter.py:
3800 * giscanner/girwriter.py:
3801 * giscanner/glibtransformer.py:
3802 * giscanner/gobjecttreebuilder.py:
3803 * giscanner/transformer.py:
3804 * giscanner/treebuilder.py:
3805 * tools/g-ir-scanner:
3806 Rename treebuilder to transformer and
3807 gobjectreebuilder to glibtransformer.
3809 2008-04-25 Johan Dahlin <jdahlin@async.com.br>
3811 * giscanner/Makefile.am:
3812 * giscanner/__init__.py:
3813 * giscanner/cgobject.py:
3814 * giscanner/gidlparser.py:
3815 * giscanner/gidlwriter.py:
3816 * giscanner/girwriter.py:
3817 * giscanner/gobjecttreebuilder.py:
3818 * giscanner/odict.py:
3819 * giscanner/sourcescanner.py:
3820 * giscanner/treebuilder.py:
3821 * giscanner/xmlwriter.py:
3822 * tools/Makefile.am:
3823 * tools/g-ir-scanner:
3824 Add LGPLv2 license header and install all python files
3826 2008-04-25 Johan Dahlin <jdahlin@async.com.br>
3829 * giscanner/gidlwriter.py:
3830 * giscanner/giscannermodule.c (pygi_source_directive_new),
3831 (directive_get_options), (pygi_source_symbol_new),
3832 (symbol_get_base_type), (pygi_source_type_new),
3833 (type_get_base_type), (type_get_child_list),
3834 (pygi_source_scanner_get_symbols),
3835 (pygi_source_scanner_get_directives):
3836 * giscanner/gobjecttreebuilder.py:
3837 * giscanner/sourcescanner.py:
3838 * giscanner/treebuilder.py:
3839 * tests/parser/foo-object.h:
3840 Add support for virtual methods.
3841 Pair struct FooClass with struct Foo.
3842 Clean up the SourceScanner bindings a bit.
3843 Add a testcase for virtual methods.
3845 2008-04-25 Johan Dahlin <jdahlin@async.com.br>
3847 * giscanner/cgobject.py:
3848 * giscanner/gidlwriter.py:
3849 * giscanner/gobjecttreebuilder.py:
3850 Add support for signals
3852 * tests/parser/foo.c (foo_object_class_init):
3853 * Foo-expected.gidl:
3854 Add a signal and update the expected output.
3856 2008-04-24 Johan Dahlin <jdahlin@async.com.br>
3858 * giscanner/gidlwriter.py:
3859 * giscanner/girwriter.py:
3860 * giscanner/giscannermodule.c (directive_get_name),
3861 (directive_get_value), (directive_get_options),
3862 (symbol_get_directives), (symbol_set_directives),
3863 (pygi_source_scanner_parse_file),
3864 (pygi_source_scanner_lex_filename),
3865 (pygi_source_scanner_get_directives), (init_giscanner):
3866 * giscanner/sourcescanner.c (gi_source_scanner_get_directives):
3867 * giscanner/sourcescanner.h:
3868 * giscanner/sourcescanner.py:
3869 * giscanner/treebuilder.py:
3870 * tools/g-ir-scanner:
3871 Add support for source/header annotations.
3873 2008-04-22 Johan Dahlin <jdahlin@async.com.br>
3875 * giscanner/gidlwriter.py:
3876 * giscanner/girwriter.py:
3877 * giscanner/gobjecttreebuilder.py:
3878 * giscanner/treebuilder.py:
3879 Add support for Callbacks
3881 2008-04-22 Havoc Pennington <hp@pobox.com>
3883 * girepository/ginvoke.c (g_function_info_invoke): If a symbol is
3884 not in metadata->module, look for it in the global module, in case
3885 some other object or the app itself provides the symbol.
3887 2008-04-22 Havoc Pennington <hp@pobox.com>
3889 * girepository/gmetadata.c (_g_metadata_init): hack to avoid
3890 dlopening a library that is already in the main app, by checking
3891 whether one of the lib's symbols is already loaded.
3893 2008-04-22 Johan Dahlin <jdahlin@async.com.br>
3895 * tests/parser/Foo-expected.gidl:
3896 * tests/parser/foo-object.h:
3899 2008-04-22 Havoc Pennington <hp@pobox.com>
3901 * girepository/ginfo.c (g_interface_info_find_method):
3902 Use interface_blob_size not object_blob_size to compute offset.
3904 2008-04-22 Havoc Pennington <hp@pobox.com>
3906 * girepository/gmetadata.c (_g_metadata_init): remove
3907 G_MODULE_BIND_LOCAL flag when loading libraries, since some libs
3908 (Glade and Clutter for example) rely on being loaded globally.
3910 2008-04-22 Havoc Pennington <hp@pobox.com>
3912 * girepository/ginfo.c (g_registered_type_info_get_g_type): new
3913 function to get the GType given a RegisteredTypeInfo
3915 2008-04-22 Johan Dahlin <johan@gnome.org>
3917 * COPYING: Add a LGPL license, to prevent automake to
3918 put in a copy of GPL here. Pointed out by Havoc.
3920 * girepository/ginfo.c (g_info_from_entry), (g_type_info_new),
3921 (g_type_info_is_pointer), (g_type_info_get_tag),
3922 (g_type_info_get_param_type), (g_type_info_get_interface),
3923 (g_type_info_get_array_length), (g_type_info_is_zero_terminated),
3924 (g_type_info_get_n_error_domains), (g_type_info_get_error_domain),
3925 (g_error_domain_info_get_codes), (g_enum_info_get_value),
3926 (g_object_info_get_interface), (g_object_info_get_field),
3927 (g_interface_info_get_prerequisite),
3928 (g_signal_info_get_class_closure), (g_constant_info_get_value):
3929 * girepository/ginvoke.c (get_ffi_type):
3930 * girepository/girepository.h:
3931 * girepository/gmetadata.c (g_metadata_get_dir_entry),
3932 (g_metadata_check_sanity), (validate_header),
3933 (validate_array_type_blob), (validate_iface_type_blob),
3934 (validate_param_type_blob), (validate_error_type_blob),
3935 (validate_type_blob), (validate_constant_blob),
3936 (validate_struct_blob), (validate_enum_blob):
3937 * girepository/gmetadata.h:
3938 * tests/Makefile.am:
3939 * tests/invoke/Makefile.am:
3940 * tests/invoke/invoke.c (main):
3941 * tests/roundtrips.sh:
3942 * tools/Makefile.am:
3943 * tools/compiler.c (format_output), (write_out_metadata), (main):
3944 * tools/generate.c (write_type_name), (write_type_info),
3945 (write_constant_value), (write_enum_info), (load_metadata), (main):
3946 * tools/gidlcompilercontext.c:
3947 * tools/gidlcompilercontext.h:
3948 * tools/gidlcompilerentrynode.c:
3949 * tools/gidlcompilerentrynode.h:
3950 * tools/gidlcompilertypenode.c:
3951 * tools/gidlcompilertypenode.h:
3952 * tools/gidlmodule.c (g_idl_module_build_metadata):
3953 * tools/gidlmodule.h:
3954 * tools/gidlnode.c (init_stats), (dump_stats),
3955 (g_idl_node_get_size), (g_idl_node_get_full_size),
3956 (g_idl_node_cmp), (g_idl_node_can_have_member),
3957 (g_idl_node_add_member), (g_idl_node_param_direction_string),
3958 (parse_int_value), (parse_uint_value), (parse_float_value),
3959 (parse_boolean_value), (find_entry_node), (find_entry),
3960 (serialize_type), (g_idl_node_build_metadata), (write_string):
3962 * tools/gidlparser.c (parse_type_internal):
3963 * tools/quote-file.sh:
3964 Revert revisions 157,149-148,136-129 and 120.
3965 Move back to using g-idl-generate to generate the metadata and
3966 avoids dependency on a c compiler.
3968 2008-04-22 Johan Dahlin <jdahlin@async.com.br>
3970 * giscanner/girwriter.py:
3971 * tools/g-ir-scanner:
3972 Add an initial GIR writer and a --format option to g-ir-scanner
3974 2008-04-21 Johan Dahlin <johan@gnome.org>
3976 * giscanner/cgobject.py: Use ctypes.util.find_library to locate
3977 gobject-2.0 and raise ImportError if not found.
3979 * giscanner/gidlparser.py:
3980 * giscanner/gidlwriter.py:
3981 * giscanner/gobjecttreebuilder.py:
3982 * tools/g-ir-scanner:
3983 Add a --include argument to include types from other idls.
3984 Add a minimalistic GIDL parser (just objects for now)
3985 Implement resolving of external type references and use it to
3986 resolve parent types, argument types and return types.
3988 2008-04-21 Johan Dahlin <johan@gnome.org>
3990 * giscanner/gidlwriter.py:
3991 * giscanner/gobjecttreebuilder.py:
3992 * giscanner/treebuilder.py:
3993 Add support for properties.
3994 Refactor Class/Interface support a bit, to share more code and
3995 always initialize their method attribute to an empty list.
3997 2008-04-21 Johan Dahlin <johan@gnome.org>
3999 * giscanner/cgobject.py:
4000 Add a workaround for a glib bug interface introspection bug
4001 (object_interface_list_properties, object_class_list_properties):
4002 Cast the return value to GParamSpec.
4004 * tests/parser/Foo-expected.gidl: Update
4005 * tests/parser/foo.c: Add a string property
4007 * giscanner/gobjecttreebuilder.py:
4008 After stripping namespaces, remove the original
4009 item to avoid duplication (GtkButton struct and Button object)
4011 2008-04-21 Johan Dahlin <johan@gnome.org>
4013 * giscanner/gobjecttreebuilder.py:
4014 * giscanner/treebuilder.py:
4015 Strip namespaces before objects, so we'll export
4016 GtkButton as Button in the gtk namespace
4018 2008-04-21 Johan Dahlin <johan@gnome.org>
4020 * giscanner/gidlwriter.py:
4021 * giscanner/gobjecttreebuilder.py:
4022 * giscanner/treebuilder.py:
4023 Add constructors for object/boxed types.
4025 2008-04-21 Johan Dahlin <johan@gnome.org>
4027 * giscanner/gidlwriter.py:
4028 * giscanner/gobjecttreebuilder.py:
4029 Add support for boxed types
4031 2008-04-21 Johan Dahlin <johan@gnome.org>
4033 * giscanner/giscannermodule.c: Mark structures as const,
4034 wrap SourceType.const_string.
4036 * tests/parser/foo-object.h: Add a couple of constants.
4038 * giscanner/gidlwriter.py:
4039 * giscanner/gobjecttreebuilder.py:
4040 * giscanner/treebuilder.py:
4041 Add basic support for interfaces
4043 * tools/g-ir-scanner:
4044 Add -o/--output for writing to a file
4046 2008-04-21 Havoc Pennington <hp@redhat.com>
4048 * TODO: add some C API wishlist items I could think of quickly
4050 2008-04-21 Johan Dahlin <jdahlin@async.com.br>
4052 * giscanner/gidlwriter.py:
4053 * giscanner/xmlwriter.py:
4054 Add a simple api for writing tags which can be used
4055 with the new 'with statement' in python 2.5
4057 2008-04-21 Johan Dahlin <johan@gnome.org>
4059 * giscanner/gobjecttreebuilder.py:
4060 Strip namespace and object prefix from method names.
4062 2008-04-21 Johan Dahlin <johan@gnome.org>
4064 * tools/g-ir-scanner (main): Add --pkg option to pass in
4065 pkg-config modules to get cflags from.
4067 * giscanner/gidlwriter.py (GIDLWriter._write_method):
4068 Avoid duplication, reuse function writer for methods.
4070 2008-04-21 Johan Dahlin <jdahlin@async.com.br>
4072 * giscanner/gidlwriter.py:
4073 * giscanner/gobjecttreebuilder.py:
4074 * giscanner/treebuilder.py:
4075 * tools/g-ir-scanner:
4076 Resolve libtool .la files.
4077 Strip name spaces for methods.
4078 Add function symbols
4080 2008-04-20 Johan Dahlin <jdahlin@async.com.br>
4082 * giscanner/cgobject.py:
4083 * giscanner/gidlwriter.py:
4084 * giscanner/gobjecttreebuilder.py:
4085 * giscanner/treebuilder.py:
4086 Add support for classes and methods
4088 2008-04-20 Johan Dahlin <johan@gnome.org>
4090 * giscanner/gidlwriter.py:
4091 * giscanner/gobjecttreebuilder.py:
4092 * giscanner/odict.py:
4093 Avoid conflicts, keep the output ordered similar to
4094 the order of the input.
4095 Add a simple ordered dictionary implemenation
4097 2008-04-19 Johan Dahlin <johan@gnome.org>
4099 * giscanner/cgobject.py:
4100 * giscanner/gidlwriter.py:
4101 * giscanner/gobjecttreebuilder.py:
4102 * tools/g-ir-scanner:
4103 Start introspecting get-type functions.
4104 Implement support for GLib/GFlags GTypes.
4105 Add a ctype based GObject binding.
4107 2008-04-18 Johan Dahlin <jdahlin@async.com.br>
4109 * giscanner/gidlwriter.py:
4110 * giscanner/xmlwriter.py:
4111 * tools/g-ir-scanner:
4112 Add a simplistic gidl writer, which can't do too much.
4114 2008-04-18 Johan Dahlin <johan@gnome.org>
4116 * giscanner/sourcescanner.py:
4117 * giscanner/treebuilder.py:
4118 * tools/g-ir-scanner:
4119 split tree building and source scanning interface to separate files.
4121 2008-04-18 Johan Dahlin <johan@gnome.org>
4123 * tools/g-ir-scanner (Parameter.__init__): Start constructing
4125 - Add support for struct/parameter/return, start parsing of ctypes
4127 * giscanner/giscannermodule.c: wrap GISourceType.child_list and
4130 2008-03-31 Johan Dahlin <johan@gnome.org>
4132 * tools/g-ir-scanner:
4133 Start to build abstract syntax node of scanned sources.
4134 Add support for cpp options.
4136 2008-03-27 Johan Dahlin <johan@gnome.org>
4138 * giscanner/giscannermodule.c:
4139 * giscanner/scannerlexer.l:
4140 * giscanner/sourcescanner.c:
4141 * tools/g-ir-scanner:
4143 Add simple pre-processor using subprocess and a PIPE.
4144 Change the parse_file apis to accept a file descriptor.
4146 2008-03-25 Johan Dahlin <johan@gnome.org>
4148 * giscanner/__init__.py:
4149 * tools/g-ir-scanner:
4150 Fix a typo and add an example python test program.
4152 2008-03-25 Johan Dahlin <johan@gnome.org>
4154 * giscanner/__init__.py:
4155 * giscanner/giscannermodule.c:
4156 * giscanner/sourcescanner.c:
4157 * giscanner/sourcescanner.h:
4158 Add constants and wrap a few more SymbolType fields
4160 2008-03-25 Johan Dahlin <johan@gnome.org>
4164 * giscanner/__init__.py:
4165 * giscanner/giscannermodule.c:
4166 * giscanner/Makefile.am:
4168 Add initial python bindings for the scanner and
4169 depend on python 2.5.
4171 2008-03-25 Johan Dahlin <johan@gnome.org>
4175 * giscanner/Makefile.am:
4176 * giscanner/sourcescanner.c:
4177 * giscanner/sourcescanner.h:
4178 * tools/Makefile.am:
4179 * tools/grealpath.h:
4180 * tools/sourcescanner.c:
4181 * tools/sourcescanner.h:
4183 Move the scanner to a separate library.
4185 2008-03-23 Johan Dahlin <johan@gnome.org>
4187 * tools/Makefile.am:
4190 * tools/scannerlexer.l:
4191 * tools/scannerparser.y:
4192 * tools/sourcescanner.c:
4193 * tools/sourcescanner.h:
4194 Split out the source scanner from the generator.
4195 Rename the symbols used in the scanner to use the gi_ prefix.
4196 This should make it possible to use the raw C parser from
4199 2008-03-23 Johan Dahlin <johan@gnome.org>
4201 * tests/parser/Makefile.am (utility.gidl):
4202 * tests/parser/utility-expected.gidl:
4203 Pass in the gobject.gidl since we're defining a GObject.
4205 2008-03-12 Johan Dahlin <johan@gnome.org>
4207 * relaxng/relaxng.rng:
4208 Add a releaxng in relaxng we can use to validate the relaxngs
4211 2008-03-12 Jürg Billeter <j@bitron.ch>
4213 * tools/scanner.c: (g_igenerator_new):
4214 * tools/scannerparser.y:
4215 Fix compiler warnings.
4217 2008-03-12 Jürg Billeter <j@bitron.ch>
4221 * tools/scannerparser.y:
4222 Start fixing memory management in g-idl-scanner.
4224 2008-03-12 Rob Taylor <rob.taylor@codethink.co.uk>
4226 * tools/gidlcompilercontext.c: (write_compiled):
4227 Fix critical warning when no shlib passed to g-idl-compiler.
4229 2008-03-12 Johan Dahlin <johan@gnome.org>
4231 * tests/parser/utility-expected.gidl:
4232 * tests/parser/utility.h:
4233 Add a get_type-function, so the scanner actually
4234 parses it as an object.
4236 2008-03-12 Johan Dahlin <johan@gnome.org>
4238 * tools/gidlwriter.c (function_generate): Add missing trailing quote.
4241 * tests/parser/Foo-expected.gidl:
4242 * tests/parser/Makefile.am:
4243 * tests/parser/foo-object.h:
4244 * tests/parser/foo.c:
4245 * tests/parser/utility-expected.gidl:
4246 * tests/parser/utility.c:
4247 * tests/parser/utility.h:
4249 Add a new gidl test. 'utility.gidl', which is used to be able
4250 to test external type references. Add a reference to UtilityObject*
4253 2008-03-11 Johan Dahlin <johan@gnome.org>
4257 Remove most global variables
4259 2008-03-11 Philip Van Hoof <me@pvanhoof.be>
4261 * tools/scannerlexer.l:
4263 * tests/parser/Foo-expected.gidl:
4264 * tests/parser/foo.c:
4265 * tests/parser/Makefile.am:
4266 * tests/parser/foo-object.h:
4268 Added a few extra tests. Which resulted in finding a few
4269 bugs. Which resulted in me fixing those bugs
4271 2008-03-11 Rob Taylor <rob.taylor@codethink.co.uk>
4273 * tools/gidlcompilercontext.c: (g_idl_compiler_write_dir_entry),
4274 (g_idl_compiler_write_xref_entry), (g_idl_compiler_add_xref):
4275 Add some comments for strings into generated output for
4278 2008-03-11 Rob Taylor <rob.taylor@codethink.co.uk>
4280 * tools/gidlcompilercontext.c: (write_compiled):
4281 Write out the shlibs variable before writing out the strings
4282 length. Fixes compiler warning when using '-l' flag with
4285 2008-03-11 Johan Dahlin <johan@gnome.org>
4287 * tests/parser/Foo-expected.gidl:
4288 * tests/parser/foo-object.h:
4291 * tools/scannerlexer.l:
4292 Add support for parsing return arguments. Add support for
4293 caller-owns return types.
4294 Patch by Philip Van Hoof.
4296 * tools/scannerparser.y:
4297 Remove parsing of the @deprecated syntax used in headers.
4298 We will support gtk-doc deprecation in the future instead.
4300 2008-03-11 Johan Dahlin <johan@gnome.org>
4302 * tools/compiler.c (main): Coding style fixes
4304 2008-03-10 Johan Dahlin <johan@gnome.org>
4307 Add GCOV_LIBS to GILIBS
4309 2008-03-10 Johan Dahlin <johan@gnome.org>
4311 * tests/parser/Foo-expected.gidl:
4312 * tests/parser/foo.c:
4313 Rename null-ok to direction=out
4315 2008-03-10 Philip Van Hoof <me@pvanhoof.be>
4317 reviewed and extensively tested by Johan
4319 * tests/parser/Foo-expected.gidl:
4320 * tests/parser/foo-object.h:
4321 * tests/parser/foo.c:
4324 * tools/gidlwriter.c:
4327 * tools/scannerlexer.l:
4328 * tools/scannerparser.y:
4330 Add support for scanning for gtk-doc comments inside
4331 C source files. Add tests
4333 2008-03-10 Johan Dahlin <johan@gnome.org>
4335 * tests/parser/Makefile.am:
4336 * tests/parser/foo.c:
4339 * tools/scannerparser.y:
4340 Add an api to lex filenames.
4341 Lex all source .c files passed in on the command line.
4342 Scan sources in a test and a couple of private structures
4343 which should not be included in the generated gidl
4345 2008-03-10 Johan Dahlin <johan@gnome.org>
4347 * tests/invoke/Makefile.am: Make the generated metadata
4348 depend on the g-idl-compiler
4350 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4352 * tools/gidlmodule.c
4353 * tools/gidlmodule.h
4356 Remove the old g-idl-compiler code.
4359 2008-02-22 Mark Doffman <mark.doffman@codethink.co.uk>
4361 * tools/quote-file.sh
4364 Move to using the 'C' struct compiler code.
4366 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4368 * girepository/ginfo.c
4370 Change the way that external references with no namespace
4371 are dealt with. External references with no namespace
4372 are placed into the XML as-if they are a local reference.
4373 This is temporary, but helps with roundtrip tests.
4375 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4377 * girepository/ginfo.c
4378 Add the ability to get the value of a constant of
4379 type TYPE_TAG_SYMBOL. In the case of a symbol the value
4380 is provided as a string.
4382 This would deal properly with:
4383 typedef char* random;
4384 const random = "A string";
4386 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4388 * girepository/ginfo.c
4389 * girepository/girepository.h
4391 Add a function to check if an enum is registered or not.
4392 Previously anything testing this relied on the g-type
4393 string offset having a value of 0.
4395 * girepository/gmetadata.c
4396 * girepository/gmetadata.h
4398 Remove unneccesary or erroneous checks. There were two
4399 metadata validation checks which made sure that the blob
4400 sizes were the same as some magic numbers compiled into the code.
4401 This is wrong as it breaks any forwards compatibility that may
4404 Checks were also present that made sure that unregistered type
4405 blobs had a value of 0 in the g-type offset field. This is
4406 unneccessary. If a type blob is unregistered then any value
4407 in its g-type field is simply invalid.
4409 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4411 * girepository/ginfo.c
4412 * girepository/gmetadata.c
4413 * girepository/gmetadata.h
4415 Change the metadata format to have a standard header
4416 for all the type blobs. Merge the SimpleTypeBlob
4417 and InterfaceTypeBlob into a union. A union of these
4418 two blobs existed previously but was not explicit
4419 in the metadata format.
4421 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4423 * tools/gidlcompilercontext.c
4424 * tools/gidlcompilercontext.h
4425 * tools/gidlcompilerentrynode.c
4426 * tools/gidlcompilerentrynode.h
4427 * tools/gidlcompilertypenode.c
4428 * tools/gidlcompilertypenode.h
4430 Add code to compile a tree of GIdlNodes to
4431 a 'C' struct representing the metadata.
4432 This is to aid cross-compiling. Previously
4433 the g-idl-compiler created a binary blob with
4434 data written in the byte order and alignment
4435 of the tool rather than the intended target.
4437 Cleaned up and improved by Johan and Robert :-)
4439 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4441 * girepository/ginvoke.c
4442 * girepository/girepository.h
4443 * girepository/gmetadata.c
4444 * girepository/gmetadata.h
4446 * tools/gidlparser.c
4447 Modify TYPE_TAG_INTERFACE to TYPE_TAG_SYMBOL
4448 to avoid confusion with the interface blob.
4451 * tools/gidlparser.c
4452 Remove magic numbers and replace with type-tag
4453 enumeration symbols.
4455 * girepository/gmetadata.c
4456 Add validate declaration.
4458 2008-03-10 Jürg Billeter <j@bitron.ch>
4460 * tools/gidlparser.c: (parse_type_internal):
4461 * tools/scannerlexer.l:
4462 * tools/scannerparser.y:
4463 Support C99 _Bool type in scanner.
4465 2008-03-10 Jürg Billeter <j@bitron.ch>
4467 * tests/parser/Foo-expected.gidl:
4468 * tests/parser/foo-object.h:
4469 * tests/parser/foo.c: (foo_enum_method):
4470 * tools/scanner.c: (g_igenerator_process_function_symbol):
4471 Don't skip functions that are defined in the namespace of a type
4472 that doesn't support methods, as for example enums.
4474 2008-03-10 Johan Dahlin <johan@gnome.org>
4476 * gidl.dtd: Remove, we're using relaxng for now
4478 * tests/parser/Foo-expected.gidl:
4479 * tests/parser/foo-object.h:
4480 * tests/parser/foo.c:
4481 Rename the enum/flags get_type functions to include the whole type.
4483 2008-03-08 Marc-Andre Lureau <marcandre.lureau@gmail.com>
4485 * tools/gidlwriter.c (enum_generate): added "type-name",
4486 "get-type" and "deprecated" missing arguments.
4487 * tests/parser/Foo-expected.gidl:
4488 * tests/parser/foo-object.h: test enum type, and no type.
4490 2008-03-06 Johan Dahlin <jdahlin@async.com.br>
4493 Consistent checks, add missing 'test'
4495 2008-03-05 Havoc Pennington <hp@redhat.com>
4497 * configure.ac: Take advantage of a libffi.pc if one exists, as it
4498 does on Fedora 8. Make libffi a hard requirement, since it was in
4499 practice anyway (was not really conditional in the code or
4500 makefile, only in configure).
4502 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4504 reviewed by: Rob Taylor <rob.taylor@codethink.co.uk>
4505 reviewed by: Johan Dahlin <johan@gnome.org>
4507 * tests/Makefile.am:
4508 * tests/roundtrips.sh:
4509 Modify the roundtrips test so that they do not use the
4510 --raw option of the gidl compiler but instead compile a
4511 shared library to use with g_module.
4513 * tests/invoke/Makefile.am:
4514 * tests/invoke/invoke.c:
4515 Modify the invoke tests to build a shared library rather
4516 than use the --raw option.
4518 * tests/invoke/invoke-namespace-find.sh: Removed:
4519 Noone knows why this was here, so removed.
4521 2008-02-19 Rob Taylor <rob.taylor@codethink.co.uk>
4523 * tools/scanner.c: (g_igenerator_process_function_symbol):
4524 Move g_idl_node_can_have_member test later, as it broke spotting
4525 get_type's for nodes that can't have members.
4527 2008-02-18 Rob Taylor <rob.taylor@codethink.co.uk>
4530 * tools/gidlnode.c: (g_idl_node_can_have_member):
4531 Add g_idl_node_can_have_member.
4533 * tools/scanner.c: (g_igenerator_process_function_symbol):
4534 Use g_idl_node_can_have_member to test if we should add a function
4535 as a member of the type node.
4537 2008-02-18 Rob Taylor <rob.taylor@codethink.co.uk>
4539 * gidl/GLib.gidl: Renamed to gidl/gobject-2.0.gidl:
4541 * tests/parser/Makefile.am:
4542 Rename GLib.gidl to gobject-2.0.gidl and install in /usr/share/gidl.
4544 2008-02-18 Rob Taylor <rob.taylor@codethink.co.uk>
4546 * tools/scanner.c: (main):
4547 Ignore -pthread when passed to g-idl-scanner.
4549 2008-02-18 Rob Taylor <rob.taylor@codethink.co.uk>
4551 * tools/grealpath.h: Added:
4552 * tools/scanner.c: (main):
4553 * tools/scannerlexer.l:
4554 * tools/Makefile.am:
4555 Always use absolute paths with symbolic links resolved when
4556 comparing filenames.
4558 2008-02-18 Rob Taylor <rob.taylor@codethink.co.uk>
4560 * gobject-introspection.pc.in:
4561 Provide variables for g-idl-parser, scanner and compiler in the
4564 2008-02-13 Rob Taylor <rob.taylor@codethink.co.uk>
4567 * girepository/Makefile.am:
4568 * tools/Makefile.am:
4569 Rename GCOV_SOURCES to GCOVSOURCES to top automake complaining.
4571 2008-02-10 Johan Dahlin <johan@gnome.org>
4573 * tests/parser/Foo-expected.gidl:
4574 * tests/parser/foo-object.h:
4575 * tests/parser/foo.c: (foo_boxed_copy), (foo_boxed_free),
4576 (foo_boxed_get_type), (foo_boxed_new), (foo_boxed_method):
4579 2008-02-10 Johan Dahlin <johan@gnome.org>
4581 * tests/parser/Foo-expected.gidl:
4582 * tests/parser/foo-object.h:
4583 * tests/parser/foo.c: (foo_enum_get_type), (foo_flags_get_type):
4584 Add enum and flags test.
4586 2008-02-10 Johan Dahlin <johan@gnome.org>
4590 * girepository/Makefile.am:
4591 Make 'make distcheck' work again.
4593 2008-02-10 Johan Dahlin <johan@gnome.org>
4595 * m4/Makefile.am (EXTRA_DIST): its called as-compiler-flag.m4,
4598 * tests/parser/Makefile.am: Only create Foo.gidl when running make
4599 check, eg exclude it from BUILT_SOURCES.
4601 2008-02-08 Rob Taylor <rob.taylor@codethink.co.uk>
4606 * girepository/Makefile.am:
4607 * m4/Makefile.am: Added:
4608 * m4/as-compiler-flag.m4: Added:
4609 * m4/gcov.m4: Added:
4610 * tools/Makefile.am:
4611 Add ability to generate a coverage report.
4612 Adds configure option --enable-gcov and make rule 'check-coverage'.
4614 2008-02-08 Rob Taylor <rob.taylor@codethink.co.uk>
4618 * gidl/Makefile.am: Added:
4619 * girepository/Makefile.am: Added:
4620 * src/Makefile.am: Renamed to tools/Makefile.am:
4621 * src/compiler.c: Renamed to tools/compiler.c:
4622 * src/g-idl-offsets.pl: Renamed to tools/g-idl-offsets.pl:
4623 * src/generate.c: Renamed to tools/generate.c:
4624 * src/gidlmodule.c: Renamed to tools/gidlmodule.c:
4625 * src/gidlmodule.h: Renamed to tools/gidlmodule.h:
4626 * src/gidlnode.c: Renamed to tools/gidlnode.c:
4627 * src/gidlnode.h: Renamed to tools/gidlnode.h:
4628 * src/gidlparser.c: Renamed to tools/gidlparser.c:
4629 * src/gidlparser.h: Renamed to tools/gidlparser.h:
4630 * src/gidlwriter.c: Renamed to tools/gidlwriter.c:
4631 * src/gidlwriter.h: Renamed to tools/gidlwriter.h:
4632 * src/ginfo.c: Renamed to girepository/ginfo.c:
4633 * src/ginvoke.c: Renamed to girepository/ginvoke.c:
4634 * src/girepository.c: Renamed to girepository/girepository.c:
4635 * src/girepository.h: Renamed to girepository/girepository.h:
4636 * src/gmetadata.c: Renamed to girepository/gmetadata.c:
4637 * src/gmetadata.h: Renamed to girepository/gmetadata.h:
4638 * src/scanner.c: Renamed to tools/scanner.c:
4639 * src/scanner.h: Renamed to tools/scanner.h:
4640 * src/scannerlexer.l: Renamed to tools/scannerlexer.l:
4641 * src/scannerparser.y: Renamed to tools/scannerparser.y:
4642 * tests/invoke/Makefile.am:
4643 Split src/ into girepository/ and tools/
4647 * girepository/Makefile.am:
4648 * tests/Makefile.am:
4649 * tests/invoke/Makefile.am:
4650 * tests/parser/Makefile.am:
4651 * tests/roundtrips.sh:
4652 * tools/Makefile.am:
4653 Make distcheck work.
4655 2008-02-04 Rob Taylor <rob.taylor@codethink.co.uk>
4657 * tests/invoke/invoke.c: (main):
4658 * tests/invoke/testfns.c: (test6), (test7):
4659 * tests/invoke/testfns.xml:
4660 Add tests for invokation with a GList argument.
4661 Also tests caller-owns return values.
4663 2008-02-04 Rob Taylor <robtaylor@floopily.org>
4666 Add some documentation for GICallableInfo
4668 2008-02-01 Mark Doffman <mark.doffman@codethink.co.uk>
4671 Correct syntax errors in the DTD file.
4673 * relaxng/c-types.xml:
4674 * relaxng/g-types.xml:
4676 Add a RelaxNG specification for the GObject Introspection XML data.
4677 The Specification has validated all of the test files.
4679 2008-01-25 Rob Taylor <robtaylor@floopily.org>
4681 * tests/roundtrips.sh:
4682 * tests/struct.test:
4683 Add roundtrip tests for structs.
4685 2008-01-11 Johan Dahlin <johan@gnome.org>
4687 * src/scanner.c (g_igenerator_process_function_symbol):
4688 Refactor out g_idle_node_add_member.
4689 (create_node_from_gtype, create_node_from_ctype):
4690 Use case instead of if...else
4691 (get_type_from_type_id):
4692 Rename to create_node_from_gtype
4693 (get_type_from_ctype):
4694 Rename to create_node_from_ctype
4696 Rename ginode -> node, gitype -> type, gifunc -> func.
4698 * src/gidlnode.c (g_idl_node_add_member, g_idl_node_cmp):
4699 Two new functions, refactor out of scanner.c
4701 * src/scanner.c: (g_igenerator_process_function_symbol):
4702 * src/scannerlexer.l:
4703 Do not save the content of the deprecated variable, only
4706 2008-01-11 Johan Dahlin <johan@gnome.org>
4708 * tests/parser/foo-object.h: Add a couple of comment parser tests.
4710 2008-01-11 Jürg Billeter <j@bitron.ch>
4712 * src/scannerlexer.l:
4713 Fix GTK-Doc parsing.
4715 2008-01-11 Jürg Billeter <j@bitron.ch>
4717 * src/scannerlexer.l:
4718 Fix GTK-Doc parsing.
4720 2008-01-11 Jürg Billeter <j@bitron.ch>
4722 * src/scanner.c: (lookup_symbol):
4723 Return unresolved name if we find unknown symbol.
4725 2008-01-11 Jürg Billeter <j@bitron.ch>
4727 * src/scanner.c: (g_igenerator_generate):
4728 Initialize GObject to fix scanning interface properties.
4730 * tests/parser/Foo-expected.gidl:
4731 * tests/parser/foo-object.h:
4732 * tests/parser/foo.c: (foo_interface_get_type):
4733 Test interfaces with GObject prerequisite.
4735 * tests/parser/Makefile.am:
4736 Set G_DEBUG=fatal_warnings to abort test on warnings and criticals.
4738 2007-12-27 Johan Dahlin <johan@gnome.org>
4740 * src/scannerlexer.l:
4741 Parse gtk-doc comments.
4743 * src/gidlwriter.c: (function_generate):
4744 Reorganize, avoid duplication and add support for
4745 writing deprecated functions.
4747 * src/scannerparser.y:
4749 Add new structure CDirective and functions to create/free them.
4751 * src/scanner.c: (g_igenerator_process_function_symbol),
4752 (g_igenerator_process_unregistered_struct_typedef),
4753 (g_igenerator_process_struct_typedef),
4754 (g_igenerator_process_union_typedef),
4755 (g_igenerator_process_enum_typedef),
4756 (g_igenerator_process_function_typedef), (g_igenerator_add_symbol),
4757 (g_igenerator_start_preprocessor):
4758 Parse @deprecated directive for functions.
4759 Remove some more C99isms.
4760 Send in -C to cpp to avoid stripping comments.
4762 * tests/parser/foo-object.h:
4763 * tests/parser/Foo-expected.gidl:
4764 Add deprecated directive
4766 2007-12-27 Johan Dahlin <johan@gnome.org>
4768 * src/scannerlexer.l (intsuffix): Add emacs mode line and
4769 escape ' and " so it looks more like C.
4772 Unlink temporary file used.
4774 2007-12-27 Johan Dahlin <johan@gnome.org>
4776 * src/scanner.c: (g_igenerator_new), (g_igenerator_free),
4777 (g_igenerator_start_preprocessor), (main):
4779 * src/scannerparser.y:
4780 Plug a couple of simple memory leaks.
4782 2007-12-27 Johan Dahlin <johan@gnome.org>
4784 * src/scanner.c: (g_igenerator_parse_macros),
4785 (g_igenerator_start_preprocessor), (g_igenerator_set_verbose),
4788 * src/scannerparser.y:
4789 * tests/parser/Makefile.am:
4791 Improve error reporting, return when the preprocessor fails.
4792 Add a verbose parameter, to aid debugging.
4793 Revert to using a temporary file to communicate between the
4794 preprocessor and the parser, because we need to wait for
4795 the exit code from the pre-processor before starting to parse.
4797 2007-12-16 Johan Dahlin <jdahlin@async.com.br>
4799 * src/Makefile.am: Rename clexer.l to scannerlexer.l and
4800 cparser.y to scannerparser.y
4802 2007-12-11 Johan Dahlin <johan@gnome.org>
4806 * src/scanner.c: (g_igenerator_new):
4808 Get rid of the global the_generator variable.
4810 2007-12-10 Johan Dahlin <johan@gnome.org>
4812 * src/scanner.c (main): Add an output option,
4813 add checks for required parameters
4816 set BUILD_SOURCES and CLEANFILES properly
4818 * src/gidlwriter.c: (g_writer_write_inline), (g_writer_write),
4819 (g_writer_write_indent), (g_writer_write_unindent),
4820 (field_generate), (value_generate), (constant_generate),
4821 (property_generate), (function_generate), (vfunc_generate),
4822 (signal_generate), (interface_generate), (struct_generate),
4823 (union_generate), (boxed_generate), (enum_generate),
4824 (node_generate), (g_writer_write_module), (g_idl_writer_save_file):
4826 * src/scanner.c: (g_igenerator_generate):
4828 * src/scannerwriter.c:
4830 Refactor scannerwriter to only be tied to a GIdlModule and move
4831 it (again!) to gidlwriter.c. Change the writer function to take
4834 2007-12-10 Johan Dahlin <johan@gnome.org>
4837 * src/scanner.c: (g_igenerator_generate):
4839 * src/scannerwriter.c: (g_igenerator_write_inline),
4840 (g_igenerator_write), (g_igenerator_write_indent),
4841 (g_igenerator_write_unindent), (field_generate), (value_generate),
4842 (constant_generate), (property_generate), (function_generate),
4843 (vfunc_generate), (signal_generate), (interface_generate),
4844 (struct_generate), (union_generate), (boxed_generate),
4845 (enum_generate), (node_generate), (module_generate),
4846 (g_scanner_write_file):
4848 Move the scanner gidl writing to a separate source file.
4850 2007-12-10 Johan Dahlin <johan@gnome.org>
4855 Move over all CType construction functions.
4857 * tests/parser/Makefile.am:
4858 Be verbose when printing parsing tests results.
4860 2007-12-10 Johan Dahlin <johan@gnome.org>
4862 * src/scanner.c (g_igenerator_start_preprocessor): Refactor
4863 preprocessor handling to here. Start cpp insteado of cc -E,
4864 always include -U__GNUC__, since it's specific to the preprocessor
4867 * tests/parser/Makefile.am (check-local): Silent diff and skip
4868 -U__GNUC__ which is always defined now
4870 2007-12-10 Johan Dahlin,,, <jdahlin@plasttroll>
4872 reviewed by: <delete if not using a buddy>
4874 * src/scanner.c: (g_igenerator_start_preprocessor), (main):
4875 * tests/parser/Makefile.am:
4877 2007-12-09 Johan Dahlin <johan@gnome.org>
4880 Use GOption for command line options.
4881 (g_igenerator_new, main): Simplify constructor and they way
4882 parameters are passed into it.
4888 * src/gen-introspect.c:
4889 * src/gen-introspect.h:
4891 Rename gen-introspect.[ch] to scanner.[ch]
4893 2007-12-09 Johan Dahlin <johan@gnome.org>
4897 * src/Makefile.am: Rename gen-introspect to g-idl-scanner,
4898 don't make the repository library and the other utilites link against
4901 * src/gen-introspect.c: (g_igenerator_create_object),
4902 (g_igenerator_create_interface), (g_igenerator_create_boxed),
4903 (g_igenerator_create_enum), (g_igenerator_create_flags),
4904 (g_igenerator_process_module_symbol),
4905 (g_igenerator_process_module), (g_igenerator_generate), (main):
4906 * src/gen-introspect.h:
4907 Refactor g_igenerator_process_types into smaller pieces.
4909 * tests/parser/Makefile.am:
4910 Depend on the gen-introspect binary
4912 2007-12-09 Johan Dahlin <johan@gnome.org>
4914 * src/gen-introspect.c (g_igenerator_process_types):
4915 Break into smaller pieces, one for each generated node type.
4917 2007-12-08 Johan Dahlin <johan@gnome.org>
4919 * src/gen-introspect.c: (g_igenerator_process_types),
4920 (g_igenerator_add_module):
4921 * tests/parser/Foo-expected.gidl:
4922 * tests/parser/foo-object.h:
4923 * tests/parser/foo.c: (foo_subobject_class_init),
4924 (foo_subobject_init):
4926 Add a subobject test and make sure to register defined classes
4927 in the lookup symbol hash table.
4929 2007-12-08 Johan Dahlin <johan@gnome.org>
4933 * src/gen-introspect.c: (g_igenerator_new), (lookup_symbol),
4934 (g_igenerator_process_types), (g_igenerator_add_module),
4935 (g_igenerator_add_include_idl), (main):
4936 * src/gen-introspect.h:
4937 * tests/parser/Makefile.am:
4938 * tests/parser/Foo-expected.gidl:
4940 Change the gen-introspect to generate namespaced module names,
4941 such as GLib.Object instead of GObject.
4942 Add a GLib.gidl which introduces GLib.Object and GLib.InitiallyUnowned,
4943 add a --include-idl parameter to gen-introspect,
4944 and update the parser test.
4946 2007-12-08 Johan Dahlin <johan@gnome.org>
4948 * src/gen-introspect.c:
4949 Move main to the end of the file and attempt to make it valid
4952 * tests/parser/Makefile.am (BUILT_SOURCES): Remove .repo here,
4953 we're not quite ready to generate metadata yet.
4958 Add a simple gen-introspect parser test
4960 2007-12-06 Gustavo J. A. M. Carneiro <gjc@gnome.org>
4962 reviewed by: Johan Dahlin <johan@gnome.org>
4965 * gobject-introspection.pc.in:
4967 * src/compiler.c: (format_output), (write_out_metadata), (main):
4968 * src/gen-introspect.c: (main):
4969 * src/gen-introspect.h:
4970 * src/generate.c: (write_callable_info), (write_repository),
4971 (load_metadata), (main):
4972 * src/gidlmodule.c: (g_idl_module_new),
4973 (g_idl_module_build_metadata):
4975 * src/gidlparser.c: (start_element_handler):
4976 * src/ginfo.c: (g_info_new), (g_info_from_entry),
4977 (g_base_info_get_name), (g_base_info_get_namespace),
4978 (g_base_info_is_deprecated), (g_base_info_get_annotation),
4979 (g_base_info_get_metadata), (g_function_info_get_symbol),
4980 (g_function_info_get_flags), (g_function_info_get_property),
4981 (g_function_info_get_vfunc), (signature_offset), (g_type_info_new),
4982 (g_callable_info_may_return_null),
4983 (g_callable_info_get_caller_owns), (g_callable_info_get_n_args),
4984 (g_callable_info_get_arg), (g_arg_info_get_direction),
4985 (g_arg_info_is_return_value), (g_arg_info_is_dipper),
4986 (g_arg_info_is_optional), (g_arg_info_may_be_null),
4987 (g_arg_info_get_ownership_transfer), (g_type_info_is_pointer),
4988 (g_type_info_get_tag), (g_type_info_get_param_type),
4989 (g_type_info_get_interface), (g_type_info_get_array_length),
4990 (g_type_info_is_zero_terminated),
4991 (g_type_info_get_n_error_domains), (g_type_info_get_error_domain),
4992 (g_error_domain_info_get_quark), (g_error_domain_info_get_codes),
4993 (g_value_info_get_value), (g_field_info_get_flags),
4994 (g_field_info_get_size), (g_field_info_get_offset),
4995 (g_registered_type_info_get_type_name),
4996 (g_registered_type_info_get_type_init),
4997 (g_struct_info_get_n_fields), (g_struct_info_get_field),
4998 (g_struct_info_get_n_methods), (g_struct_info_get_method),
4999 (find_method), (g_struct_info_find_method),
5000 (g_enum_info_get_n_values), (g_enum_info_get_value),
5001 (g_object_info_get_parent), (g_object_info_get_type_name),
5002 (g_object_info_get_type_init), (g_object_info_get_n_interfaces),
5003 (g_object_info_get_interface), (g_object_info_get_n_fields),
5004 (g_object_info_get_field), (g_object_info_get_n_properties),
5005 (g_object_info_get_property), (g_object_info_get_n_methods),
5006 (g_object_info_get_method), (g_object_info_find_method),
5007 (g_object_info_get_n_signals), (g_object_info_get_signal),
5008 (g_object_info_get_n_vfuncs), (g_object_info_get_vfunc),
5009 (g_object_info_get_n_constants), (g_object_info_get_constant),
5010 (g_interface_info_get_n_prerequisites),
5011 (g_interface_info_get_prerequisite),
5012 (g_interface_info_get_n_properties),
5013 (g_interface_info_get_property), (g_interface_info_get_n_methods),
5014 (g_interface_info_get_method), (g_interface_info_find_method),
5015 (g_interface_info_get_n_signals), (g_interface_info_get_signal),
5016 (g_interface_info_get_n_vfuncs), (g_interface_info_get_vfunc),
5017 (g_interface_info_get_n_constants),
5018 (g_interface_info_get_constant), (g_property_info_get_flags),
5019 (g_signal_info_get_flags), (g_signal_info_get_class_closure),
5020 (g_signal_info_true_stops_emit), (g_vfunc_info_get_flags),
5021 (g_vfunc_info_get_offset), (g_vfunc_info_get_signal),
5022 (g_constant_info_get_value), (g_union_info_get_n_fields),
5023 (g_union_info_get_field), (g_union_info_get_n_methods),
5024 (g_union_info_get_method), (g_union_info_is_discriminated),
5025 (g_union_info_get_discriminator_offset),
5026 (g_union_info_get_discriminator):
5027 * src/ginvoke.c: (g_function_info_invoke):
5028 * src/girepository.c: (g_irepository_register),
5029 (g_irepository_unregister), (g_irepository_get_default),
5030 (count_interfaces), (g_irepository_get_n_infos), (find_interface),
5031 (g_irepository_get_info), (g_irepository_find_by_name),
5032 (g_irepository_get_shared_library),
5033 (g_irepository_build_search_path), (g_irepository_register_file),
5034 (g_irepository_error_quark):
5035 * src/girepository.h:
5036 * src/gmetadata.c: (g_metadata_get_dir_entry),
5037 (g_metadata_check_sanity), (validate_header),
5038 (validate_array_type_blob), (validate_iface_type_blob),
5039 (validate_param_type_blob), (validate_error_type_blob),
5040 (validate_type_blob), (validate_arg_blob),
5041 (validate_signature_blob), (validate_function_blob),
5042 (validate_callback_blob), (validate_constant_blob),
5043 (validate_value_blob), (validate_field_blob),
5044 (validate_property_blob), (validate_signal_blob),
5045 (validate_vfunc_blob), (validate_struct_blob),
5046 (validate_enum_blob), (validate_object_blob),
5047 (validate_interface_blob), (validate_errordomain_blob),
5048 (validate_union_blob), (validate_blob), (validate_directory),
5049 (validate_annotations), (g_metadata_validate), (_g_metadata_init),
5050 (g_metadata_new_from_memory), (g_metadata_new_from_const_memory),
5051 (g_metadata_new_from_mapped_file), (g_metadata_free),
5052 (g_metadata_set_module), (g_metadata_get_namespace):
5054 * tests/Makefile.am:
5055 * tests/invoke/Makefile.am:
5056 * tests/invoke/invoke-namespace-find.sh:
5057 * tests/invoke/invoke.c: (main):
5059 Add a namespace/shared library mapping. fixes #313268.
5061 2007-12-03 Johan Dahlin <johan@gnome.org>
5063 * src/gidlparser.c (parse_type_internal): Disable char/gchar and
5066 2007-11-30 Jürg Billeter <j@bitron.ch>
5072 * src/gen-introspect.c: (g_idl_node_cmp), (g_igenerator_new),
5073 (g_igenerator_write_inline), (g_igenerator_write),
5074 (g_igenerator_write_indent), (g_igenerator_write_unindent),
5075 (field_generate), (value_generate), (constant_generate),
5076 (property_generate), (function_generate), (vfunc_generate),
5077 (signal_generate), (interface_generate), (struct_generate),
5078 (union_generate), (boxed_generate), (enum_generate),
5079 (node_generate), (module_generate), (get_type_from_type_id),
5080 (str_replace), (g_igenerator_process_properties),
5081 (g_igenerator_process_signals), (g_igenerator_process_types),
5082 (get_type_from_ctype), (g_igenerator_process_function_symbol),
5083 (g_igenerator_process_unregistered_struct_typedef),
5084 (g_igenerator_process_struct_typedef),
5085 (g_igenerator_process_union_typedef),
5086 (g_igenerator_process_enum_typedef),
5087 (g_igenerator_process_function_typedef),
5088 (g_igenerator_process_constant), (g_igenerator_process_symbols),
5089 (g_igenerator_add_symbol), (g_igenerator_is_typedef),
5090 (g_igenerator_generate), (main), (csymbol_new),
5091 (csymbol_get_const_boolean), (ctype_new), (ctype_copy),
5092 (cbasic_type_new), (ctypedef_new), (cstruct_new), (cunion_new),
5093 (cenum_new), (cpointer_new), (carray_new), (cfunction_new),
5094 (eat_hspace), (eat_line), (read_identifier),
5095 (g_igenerator_parse_macros):
5096 * src/gen-introspect.h:
5098 Import gen-introspect to generate introspection information by
5101 2007-11-30 Jürg Billeter <j@bitron.ch>
5103 * src/gidlnode.c: (g_idl_node_new): support creating callback nodes
5105 2007-11-30 Jürg Billeter <j@bitron.ch>
5107 * src/gidlparser.c: (end_element_handler): Don't leave requires
5110 2007-11-29 Johan Dahlin <johan@gnome.org>
5112 * src/gidlparser.c (parse_type_internal): Add char,
5113 gchar and guchar to the builtin types.
5115 2007-11-26 Johan Dahlin <johan@gnome.org>
5117 * src/ginfo.c: (g_object_info_get_type_name),
5118 (g_object_info_get_type_init):
5119 * src/girepository.c: (g_irepository_is_registered):
5120 * src/girepository.h:
5122 Add g_object_info_get_type_name, g_object_info_get_type_init and
5123 g_irepository_is_registered.
5125 2006-08-14 Jürg Billeter <j@bitron.ch>
5127 * src/gidlparser.c: (end_element_handler): Don't leave
5128 namespace and implements states too early.
5131 2007-11-26 Johan Dahlin <johan@gnome.org>
5133 * src/gmetadata.c (validate_struct_blob):
5134 pass blob_type to validate_function_blob instead of
5135 hard-coding BLOB_TYPE_STRUCT.
5137 Patch by Torsten Schoenfeld, fixes #314190
5139 2006-10-03 Torsten Schoenfeld <tsch@cvs.gnome.org>
5141 * src/compiler.c, src/generate.c, src/gidlnode.c,
5142 src/gidlparser.c, src/ginfo.c, src/girepository.c,
5143 tests/invoke/invoke.c, test/invoke/testfns.c: Hush compiler
5144 warnings about return values, signedness mismatches, unused
5145 variables, and unhandles enum values in switch statements.
5147 * tests/invoke/Makefile.am: Don't install the invoke test program.
5148 Add -I ../../src to the cflags used for the test functions files.
5150 2005-08-31 Torsten Schoenfeld <tsch@cvs.gnome.org>
5152 * src/girepository.h: Export g_invoke_error_quark.
5154 2005-08-31 Torsten Schoenfeld <tsch@cvs.gnome.org>
5156 * src/ginvoke.c: Remove the fallback implementation of
5157 g_function_info_invoke since we now formally depend on libffi.
5159 2005-07-25 Matthias Clasen <mclasen@redhat.com>
5161 * src/Makefile, tests/Makefile, tests/invoke/Makefile:
5162 Remove these files from cvs, as they are now generated.
5164 * src/gmetadata.c (validate_iface_type_blob): Don't
5165 complain if blob->pointer is not set, since that
5166 happens for enum and flag types. (#308935, Gustavo
5169 * Commit an autoconf-conversion patch by
5170 Gustavo Carneiro (#308708)
5172 2005-05-24 Matthias Clasen <mclasen@redhat.com>
5174 * src/compiler.c (main): Use it here to validate
5175 the generated metadata.
5177 * src/gmetadata.[hc]: Add code to validate a
5180 * metadata-format.txt: Updates
5182 2005-05-22 Matthias Clasen <mclasen@redhat.com>
5184 * tests/*: Add struct offsets to field and vfunc
5187 * src/generate.c (write_vfunc_info): Write offset
5188 information for vfuncs.
5190 * src/gidlnode.c (g_idl_node_build_metadata): Write
5191 the struct offsets into the metadata.
5193 * src/gidlparser.c: Parse the offset attributes of
5194 field and vfunc elements.
5196 * src/gidlnode.h: Add offset members to field and
5199 2005-05-21 Matthias Clasen <mclasen@redhat.com>
5203 * gidl.dtd: Updates.
5205 * src/g-idl-offsets.pl: A perl script which reads a .gidl
5206 file, creates, compiles and runs a C file, and folds the
5207 resulting struct offsets back into the .gidl file.
5209 2005-05-20 Matthias Clasen <mclasen@redhat.com>
5211 * src/gidlparser.c (start_field): Make fields in objects
5214 * src/gidlmodule.c: Include string.h
5219 * metadata-format.txt: Cleanup basic types.
5220 * src/*: Adapt to the changes.
5221 * tests/*: Adapt to the changes.
5222 * examples/gdk-pixbuf.gidl: Adapt to the changes.
5224 * src/gidlnode.c (g_idl_node_get_size): Report the correct
5225 size for enum blobs.
5226 (g_idl_node_get_full_size): Report the correct size for
5229 * src/gidlmodule.c (g_idl_module_build_metadata): Add some
5230 error checking for blob sizes.
5232 2005-05-19 Matthias Clasen <mclasen@redhat.com>
5234 * src/gidlnode.c (g_idl_node_build_metadata): Correctly handle
5235 interface types for which is_pointer is FALSE, e.g. enums.
5237 * src/gidlnode.c (g_idl_node_get_full_size)
5238 * src/gidlparser.c (parse_type_internal):
5239 * src/generate.c (write_type_info): Support unspecialized
5240 lists, hashtables and errors. Also emit a '*' after these.
5244 2005-05-17 Matthias Clasen <mclasen@redhat.com>
5248 * metadata-format.txt: Cleanups by Maciej Katafiasz.
5250 2005-05-15 Matthias Clasen <mclasen@redhat.com>
5252 * src/*.c: Change the directory to be addressed by
5253 1-based indexes, and use an index of zero to mean
5256 2005-05-15 Matthias Clasen <mclasen@redhat.com>
5258 * tests/roundtrips.sh (SIMPLE_TESTS): Add union.test.
5260 * tests/union.test: Add a union test.
5262 * src/generate.c: Handle unions.
5264 * src/girepository.h:
5265 * src/ginfo.c: Add GIUnionInfo and functions to access it.
5267 * src/gidlnode.c: Handle GIdlNodeUnion nodes.
5269 * src/gidlparser.c (start_union): Parse <union> elements.
5271 * src/gidlnode.h: Add a GIdlNodeUnion.
5273 * gidl.dtd: Add a <union> element.
5275 * src/gmetadata.c (g_metadata_check_sanity): Check
5278 * src/gmetadata.h: Add union_blob_size to Header,
5281 * metadata-format.txt: Add a UnionBlob.
5283 2005-05-13 Matthias Clasen <mclasen@redhat.com>
5285 * tests/*: Update testcases.
5287 * src/generate.c (write_callable_info): Don't forget to
5288 write transfer and null-ok attributes for return types
5291 * src/girepository.h:
5292 * src/ginfo.c (g_callable_info_may_return_null):
5293 New function to find out if a function may return NULL.
5295 * src/compiler.c (format_output): Make the generated
5298 * README: Point to a recent libffi snapshot.
5300 * tests/invoke/*: Some invoke tests.
5302 * src/Makefile: Add ginvoke.c and the necessary
5305 * src/girepository.h (g_function_info_invoke): Add
5308 * src/ginvoke.c (g_function_info_invoke): Initial
5309 implementation of invoke functionality based on libffi.
5311 * src/gidlnode.c (g_idl_node_build_metadata): Pass the
5312 strings and types hash tables in the right order when
5314 (find_entry_node): Free the name parts.
5316 2005-05-12 Johan Dahlin <johan@gnome.org>
5318 * src/generate.c: Generate consistent end tags.
5322 2005-05-12 Matthias Clasen <mclasen@redhat.com>
5326 * src/gidlparser.c (start_function): Actually add
5327 methods to objects. (Steven Walter)
5329 * src/girepository.h:
5330 * src/ginfo.c: Rename Transfer and Direction to
5331 GITransfer and GIDirection. (Torsten Schoenfeld)
5333 * tests/*: Make tests work with the changes in name
5336 * src/gidlnode.c (find_entry_node): Parse qualified
5337 names and generate xref nodes for them if needed. Don't
5338 require all modules to be loaded any more.
5340 * src/gidlmodule.c (g_idl_module_build_metadata): Choke
5343 * src/ginfo.c (g_object_info_get_parent): Return NULL
5344 if blob->parent is 0. Still need to make sure index
5347 * src/generate.c: Generate qualified names when
5348 referring to non-local types. Emit transfer attribute
5351 * src/compiler.c (format_output): Put the function
5352 attributes where gcc accepts them.
5354 2005-05-11 Matthias Clasen <mclasen@redhat.com>
5356 * src/compiler.c (main): Add a --verbose cmdline option
5357 and only log messages if it is specified.
5360 * src/gidlnode.c (init_stats, dump_stats): Collect some
5361 statistics on string and type sharing.
5363 * src/gidlmodule.c (g_idl_module_build_metadata): Use
5364 g_message() instead of fprintf().
5366 * src/gidlnode.c (g_idl_node_free): Make this more robust.
5367 (g_idl_node_get_size): Implement for structs.
5368 (g_idl_node_get_full_size): Handle parent being NULL.
5369 (serialize_type): Handle lookup failures more gracefully.
5371 2005-05-10 Matthias Clasen <mclasen@redhat.com>
5373 * src/gidlnode.c (g_idl_node_get_full_size): Correct the
5374 size calculation for 2-parameter types and for objects.
5376 * src/compiler.c: Add a cmdline option for debug output
5377 and install a log handler to implement it.
5378 * src/gidlnode.c: Add some debug spew.
5382 * src/gidlmodule.c (g_idl_module_build_metadata): Don't
5383 forget to count the module name when calculating the
5384 required size for the metadata.
5387 * src/gidlparser.c: Fix compiler warnings.
5389 2005-05-09 Matthias Clasen <mclasen@redhat.com>
5391 * src/compiler.c (main): Free the option context.
5393 * gidl.dtd: Clean up handling of names. All elements
5394 have a "name", only the elements corresponding to
5395 actual callable functions (function, method, constructor),
5396 have an additional "symbol" attribute holding the
5397 dlsym()-able function name.
5399 * src/generate.c: Adapt to generate xml matching the
5403 * src/gidlnode.c: Adapt to parse the new dtd.
5405 * tests/*.test: Adjust to the new dtd.
5407 * metadata-format.txt:
5408 * src/gmetadata.h: Remove the short_name field
5410 * src/gmetadata.c: Shrink size of ValueBlob to 12.
5411 * src/girepository.h:
5412 * src/ginfo.c (g_value_info_get_short_name): Removed
5414 2005-05-09 Matthias Clasen <mclasen@redhat.com>
5416 * gidl.dtd: Allow constructors for boxed types,
5417 patch by Jonathan Blandford.
5420 2005-05-09 Matthias Clasen <mclasen@redhat.com>
5422 * --- Initial import ---