1 2008-11-17 Andreas Rottmann <a.rottmann@gmx.at>
3 * giscanner/ast.py: Change string array match type to be in terms
5 * giscanner/transformer.py: Add canonicalize_ctype which gives us
6 a version of a c:type without aliases, so we can deep canonicalize
7 char** to utf8*. Update parse_ctype to use it.
8 * tests/*: Add gtk_init like int*/char*** arg functions for testing.
10 2008-11-16 Colin Walters <walters@verbum.org>
12 * girepository/girepository.c: Ensure we always call init_globals,
13 even if passed a non-default repository.
15 2008-11-16 Colin Walters <walters@verbum.org>
17 Bug 559706 - Interface prerequisites
19 * common.mk: Dep on libgirepository.la for scanner libs so that
20 we rebuild things even if just gdump.c changes.
21 * girepository/gdump.c: Dump prerequisites.
22 * giscanner/ast.py: Add prerequisite list.
23 * giscanner/girparser.py: Parse them from gdump.
24 * giscanner/girwriter.py: Write them.
25 * giscanner/glibtransformer.py: Resolve them.
28 2008-11-16 Owen Taylor <otaylor@redhat.com>
30 Bug 561087 - Respect is_pointer in serialize_type()
32 Add a '*' to the serialization for the cases where we set is_pointer
33 in the type blob we write out depending on node->is_pointer. Don't
34 add the '*' in the cases where is_pointer is set or not set in a
37 http://bugzilla.gnome.org/show_bug.cgi?id=561087
39 2008-11-16 Owen Taylor <otaylor@redhat.com>
41 Bug 560825 – Add size and alignment to typelib
43 Include the size and alignment of structures and unions in the typelib,
44 and add getter methods to retrieve them from GIStructInfo/GIUnionInfo.
46 * docs/typelib-format.txt girepository/gtypelib.h girepository/girnode.c
47 girepository/girmodule.c girepository/gtypelib.c: Add size and alignment
48 to StructBlob and UnionBlob.
50 * girepository/ginfo.c girepository/girepository.h:
51 Add g_[struct|union]_get[size|alignment]().
53 * test/offsets/gen-gitestoffsets: Test overall structure size and alignment.
55 2008-11-16 Owen Taylor <otaylor@redhat.com>
57 Bug 552371 – implement struct field get/set
59 * girepository/gfield.c girepository/girepository.h: Add
60 convenience functions g_field_info_set_field() and
61 g_field_info_get_field() to set and get fields based on the
62 offsets in GIFieldInfo.
64 2008-11-16 Andreas Rottmann <a.rottmann@gmx.at>
66 Bug 560241 - Out-arguments should not be marked as being pointers
69 * girepository/girparser.c: Improved logic for out arguments.
71 2008-11-16 Andreas Rottmann <a.rottmann@gmx.at>
73 Bug 559601 - Pointers in structs/unions unduly treated as arrays
75 * giscanner/transformer.py: Differentiate type creation logic
76 between parameters and struct components.
78 2008-11-15 Colin Walters <walters@verbum.org>
80 * giscanner/dumper.py: Check return code from pkg-config
83 2008-11-14 Johan Dahlin <jdahlin@async.com.br>
85 * tests/everything/everything.c (test_array_int_in),
86 (test_array_gtype_in):
87 * tests/everything/everything.h:
88 Rename the int/gtype array tests. Make the return value
89 useful, an aggregation of the array input values.
91 2008-11-14 Johan Dahlin <jdahlin@async.com.br>
93 * tests/everything/Makefile.am:
94 * tests/everything/everything.c:
95 * tests/everything/everything.h:
96 * tests/everything/gitesttypes.c:
97 * tests/everything/gitesttypes.h:
98 Rename gitesttypes.[ch] to everything.[ch]
100 2008-11-13 Andreas Rottmann <a.rottmann@gmx.at>
102 Bug 560708 – Don't treat arrays that have a length specified as
103 zero-terminated by default
105 * giscanner/transformer.py: Default to non zero terminated for
107 * tests/*: Update, add test for zero vs not.
109 2008-11-13 Andreas Rottmann <a.rottmann@gmx.at>
111 Bug 557788 - Return types for constructors in generated typelib bogus
113 * girepository/girnode.c: Namespace-qualify XREFs; not doing so is
114 obviously broken in the face of duplicate names in different
116 * tests/scanner/*expected.gir: Fix up.
118 2008-11-13 Owen Taylor <otaylor@redhat.com>
120 * girepository/girffi.c: Fix "Unexpected time for time_t"
123 2008-11-13 Colin Walters <walters@verbum.org>
125 Bug 558436 - avoid having scanner load app code
127 * giscanner/cgobject.py: Delete; we no longer load shared
129 * giscanner/dumper.py: Support for linking a library to
130 a stub binary for introspection.
131 * giscanner/glibtransformer.py: Rewrite to use gdump XML
132 from invocation of child binary.
133 * giscanner/transformer.py: Fix up to use fully qualified
134 name in parse tree. Make parse_ctype public so we can use
135 it inside glibtransformer.
136 * tests/scanner/barapp.c: New test, using --program arg
138 * tests/*: Update to use common.mk for invoking scanner.
139 * tools/g-ir-scanner: Add options --program, --program-arg,
141 * docs/g-ir-scanner.1: Update.
143 2008-11-13 Colin Walters <walters@verbum.org>
145 * configure.ac: Depend on Gio, we use it in gdump.c.
146 * girepository/gdump.c: Code to dump GType data to XML.
147 * girepository/girepository.c: Add option group for dumping.
148 * girepository/girepository.h: Define API for the above.
150 2008-11-13 Colin Walters <walters@verbum.org>
152 * common.mk: Add a file to include with Makefile fragments
153 useful for scanner invocation.
155 2008-11-13 Tommi Komulainen <tommi.komulainen@iki.fi>
157 * tests/everything/gitesttypes.c (test_filename_return): Return
158 strings in filename encoding.
160 2008-11-13 Owen Taylor <otaylor@redhat.com>
162 Bug 560253 – Add structure and boxed types to Everything test module
164 * tests/everything/gitesttypes.[ch]: Add examples of:
166 Plain old data structs
167 Plain old data structs with nested fields
169 Plain old data boxed with nested fields
170 More complicated boxed types with internal state
172 2008-11-12 Johan Dahlin <jdahlin@async.com.br>
174 * tests/everything/gitesttypes.c (test_gtype_in):
175 * tests/everything/gitesttypes.h:
176 Add a test of GType arrays, a la gtk_list_store_set_columns.
178 2008-11-12 Owen Taylor <otaylor@redhat.com>
180 Bug 560419 – Cache includes when parsing
182 Keep track of all modules parsed within a GIrParser, and when a
183 module is referenced a second time, use the existing parsed copy
184 instead of reparsing.
186 2008-11-12 Owen Taylor <otaylor@redhat.com>
188 Fix management of ParseContext.includes_modules (#560419)
190 * girepository/girparser.c: Fix some trivial bugs in managing the
191 list of include modules. (Add to module's list twice, not
192 initialized to NULL, not freed.)
194 2008-11-12 Owen Taylor <otaylor@redhat.com>
196 Keep aliases and disguised_structures local to each module (#560419)
198 * girepository/girmodule.[ch]: When parsing, keep keep a separate
199 hash tables of aliases and 'disguised' flags for each module, and
200 store that on the module.
202 After parsing an include merge the aliases/disguised flags to the
205 * girepository/girparser.c: Remove 'prefix_aliases' flag and
206 always prefix aliases/disguised structure types when parsing; this
207 simplifies the code considerably.
209 2008-11-12 Owen Taylor <otaylor@redhat.com>
211 Fix mismatches between .gir name and 'name' attribute (#560419)
213 * tests/boxed.gir tests/constant.gir tests/enum.gir tests/invoke/invoke.c
214 tests/invoke/testfns-1.0.gir tests/object.gir tests/struct.gir: Fix places
215 where the 'name' element of <namespace/> didn't match the filename of the
216 gir, an assumption that the compiler has always expected and now enforces.
218 2008-11-12 Owen Taylor <otaylor@redhat.com>
220 Only allow one <namespace/> element per <repository/> (#560419)
222 * girepository/girparser.c: The logic in girparser.c didn't work
223 very well if there were multiple <namespace/> nodes within a
224 single <repository/> (context->namespace was always the overall
225 filename and not the the name specified in the <namespace/>
226 element for one thing; this would cause aliases to be mis-prefixed
227 in include modules.) Also check that the "name" in the
228 <namespace/> node matches the filename.
230 2008-11-12 Owen Taylor <otaylor@redhat.com>
232 Add a GirParser object to hold the state of a compilation
234 * girepository/girparser.[ch] tools/compiler.c: Add a toplevel
235 GirParser object to hold state that is global across a
236 compilation. Currently just holds the include path, but will
237 eventually also keep a cached list of parsed modules.
239 2008-11-12 Tommi Komulainen <tommi.komulainen@iki.fi>
241 * girepository/girepository.c (find_namespace_latest): Fix
244 2008-11-12 Tommi Komulainen <tommi.komulainen@iki.fi>
246 * configure.ac: use 'introspection' component for bugs
248 2008-11-12 Johan Dahlin <jdahlin@async.com.br>
250 * tests/everything/gitesttypes.c (test_filename_return):
251 * tests/everything/gitesttypes.h:
252 Add a filename return test.
254 2008-11-12 Tommi Komulainen <tommi.komulainen@iki.fi>
256 * tests/offsets/Makefile.am (gitestoffsets.c): fix
257 gen-gitestoffsets invocation with builddir != srcdir
259 2008-11-12 Johan Dahlin <jdahlin@async.com.br>
261 * girepository/girepository.c:
262 Change the element type from utf8 to filename
263 * girepository/girnode.c (g_ir_node_build_typelib):
264 Special case filename equally to utf8 here.
266 2008-11-12 Johan Dahlin <jdahlin@async.com.br>
269 Remove unused variables, add a dependency of girepository.ch, so when
270 they change we rebuild the gir automatically.
272 2008-11-12 Johan Dahlin <jdahlin@async.com.br>
274 * girepository/girepository.c (g_irepository_get_search_path):
275 * girepository/girepository.h:
276 Add a g_irepository_get_search_path, so we can access the search
279 2008-11-12 Johan Bilien <jobi@via.ecp.fr>
281 Bug 560474 – g-ir-compiler crashes when compiling the glib gir
283 * girepository/girparser.c: avoid freeing an uninitialized pointer
285 2008-11-12 Johan Dahlin <jdahlin@async.com.br>
288 * giscanner/glibtransformer.py:
289 * tools/g-ir-scanner:
290 Add a GIRepository-2.0.gir. Change the libtool lookup slightly
291 so we can just pass in --library=foo/bar/baz.la and the scanner
292 does the right thing.
293 Don't warn for _get_type() functions if they don't take any
296 2008-11-11 Owen Taylor <otaylor@redhat.com>
298 Bug 560404 – Prefix types when resolving aliases in included modules
300 * girepository/girparser.c: When resolving aliases in an included
301 module, prefix types before looking them up.
303 2008-11-11 Owen Taylor <otaylor@redhat.com>
305 Compute field offsets and overall size for object structures
307 Bug 560326 – Fails to build Gtk-2.0.typelib with "Unexpected non-pointer
308 field of type object in structure"
310 Do basic computation of field offsets for objects and interfaces;
311 this doesn't attempt to address all of the "mess" for virtual
312 functions described in Bug 560281.
314 2008-11-11 Tommi Komulainen <tommi.komulainen@iki.fi>
316 Bug 560308 – g-ir-compiler goes in infinite loop on Gdk-2.0.gir
318 Based on patch by Johan Bilien.
320 * giscanner/transformer.py (_create_member, _create_parameter):
321 Resolve types here as well.
322 (_resolve_type_name_1): Try resolving using 'ctype' first since
323 it's least ambiguous. Fixes struct member type resolution with
324 similarly named types, e.g. Gdk.PangoRendererClass and
326 * tests/scanner/foo*: Add test.
328 2008-11-11 Owen Taylor <otaylor@redhat.com>
330 * girepository/girparser.c: Search provided include dirs before
331 the default directories.
333 2008-11-11 Owen Taylor <otaylor@redhat.com>
335 * girepository/giroffsets.c: Include fully-qualified names in
338 2008-11-11 Owen Taylor <otaylor@redhat.com>
340 * girepository/giroffsets.c: Fail gracefully with an informative
341 error message when recursion is encountered when computing a
344 2008-11-11 Owen Taylor <otaylor@redhat.com>
346 * girepository/girparser.c: Remove an unused variable.
348 2008-11-10 Owen Taylor <otaylor@redhat.com>
350 Add tests for field offset computations
352 * tests/offsets/offsets.h: Header file with structure definitions to test
354 * tests/offsets/gen-gitestoffsets: Generate a C program that computes
355 field offsets for the structures in offsets.h two ways: using
356 the information from a generated typelib, and as computed by the
359 We diff these two versions to test that everything is OK.
361 2008-11-10 Owen Taylor <otaylor@redhat.com>
363 Remove field offsets from g-ir-generate output and test inputs
365 Field offsets are a) architecture dependent so they shouldn't be part
366 of the architecture-independent gir format which is installed in
367 datadir. b) Are architecture-dependent so they shouldn't be in test
370 * girepository/girparser.c: Don't parse offset for fields
371 * tools/generate.c: Don't parse offset for fields
372 * tests/*.gir test/scanner/*.tgir: Remove offsets
374 (Virtual function and discriminator offsets are not removed, as they
375 aren't fully hooked up to the field-offset computation machinery yet.)
377 2008-11-10 Owen Taylor <otaylor@redhat.com>
379 Bug 560252 - Compute field offsets before writing typelib
381 * girepository/girnode.h: Store the total size and alignment for
382 GIrNodeStruct/Boxed/Union.
384 * girepository/giroffset.c: New file implementing computation of
385 structure field offsets.
387 * girepository/girnode.c: Compute structure field offsets before
388 writing types into the typelib.
390 * docs/typelib-format.txt: Document that a field offset of 0xFFFF
391 means "unknown". Also fix description of the discriminator_offset
394 2008-11-10 Owen Taylor <otaylor@redhat.com>
396 Bug 560250 - Fully parse included modules
398 For some things, like computing structure offsets to put into the typelib
399 we need more than just the aliases from included modules. Do a completel
400 parse of included modules and store in module->included_modules.
402 Also add g_ir_find_node() to find node information from within the
403 active set of modules and their includes.
405 2008-11-10 Owen Taylor <otaylor@redhat.com>
407 Split g_ir_ffi_get_ffi_type() out from ginvoke.c
409 Extract a function to convert GITypeTag to ffi_type from the internals
410 of ginvoke.c. This will be useful in figure out structure alignment.
412 Also fix handling of gsize and time_t to be portable. (Add a check
413 to configure.ac to figure out the width of time_t.)
415 2008-11-10 Owen Taylor <otaylor@redhat.com>
417 Bug 560248 – "disguised structures"
419 Certain types like GIConv and GdkAtom are pointers internally but don't
420 look like pointers when referenced. They have the form.
422 typedef struct _X *X;
424 Parse these as structures/records but mark them in the gir with a 'disguised'
425 attribute so that we know that they need special handling.
427 In the typelib treat them like any other structure.
429 2008-11-09 Jürg Billeter <j@bitron.ch>
432 * giscanner/girwriter.py:
434 Write throws attribute for virtual functions, fixes bug 559703
436 2008-11-07 Johan Dahlin <jdahlin@async.com.br>
438 * giscanner/libtoolimporter.py (LibtoolImporter.find_module): Clear
439 up some confusion about the second argument to find_module, it's
440 actually the packages __path__ attribute which we can safely ignore
442 (LibtoolImporter.load_module): Set module.__loader__ as per PEP 302.
444 2008-11-07 Owen Taylor <otaylor@redhat.com>
446 Bug 559737 – Deal with continuations in macros
448 * giscanner/giscannerlexer.l: Treat continuation lines the same
449 as regular newlines. This makes the scanner not complain about
450 #define foo(x) \ <stuff> inside a C file. There's no attempt
451 however to handle parsing macro definitions split across lines.
453 2008-11-07 Johan Dahlin <jdahlin@async.com.br>
455 * giscanner/cachestore.py:
456 Handle broken cache entries, write only filesystems and
457 running out of diskspace.
459 2008-11-07 Owen Taylor <otaylor@redhat.com>
461 * giscanner/giscannermodule.c (pygi_source_scanner_lex_filename):
462 Set current_filename before lexing the file so error messages
463 are reported in the right file.
465 2008-11-06 Colin Walters <walters@verbum.org>
467 * tests/everything/*: Add some tests for strv.
469 2008-11-05 Colin Walters <walters@verbum.org>
471 * girepository/ginvoke.c (g_function_info_invoke): Don't use
472 nested scope local variable for error which may go away after
473 conditional is complete.
475 2008-11-05 Colin Walters <walters@verbum.org>
477 * giscanner/scannerlexer.l: Avoid static 256 char buf which we
478 manipulate hackily; just use GString. This avoids an
479 uninitialized memory read pointed out by Havoc.
481 2008-11-04 Johan Dahlin <jdahlin@async.com.br>
483 * giscanner/__init__.py:
485 * giscanner/cachestore.py:
486 * giscanner/cgobject.py:
487 * giscanner/girparser.py:
488 * giscanner/girwriter.py:
489 * giscanner/giscannermodule.c:
490 * giscanner/glibast.py:
491 * giscanner/glibtransformer.py:
492 * giscanner/libtoolimporter.py:
493 * giscanner/minixpath.py:
494 * giscanner/odict.py:
495 * giscanner/sourcescanner.c:
496 * giscanner/sourcescanner.h:
497 * giscanner/sourcescanner.py:
498 * giscanner/transformer.py:
499 * giscanner/utils.py:
500 * giscanner/xmlwriter.py:
502 Relicense the giscanner library under LGPLv2+.
503 This has been approved by all contributors.
505 2008-11-01 Owen Taylor <otaylor@redhat.com>
507 Bug 558848 giparser.py: shared library should be optional
509 When parsing a .gir, allow the shared-library attribute
510 of <namespace/> to be missing: this corresponds to the handling
511 in libgirepository and elsewhere.
513 2008-11-01 Tommi Komulainen <tommi.komulainen@iki.fi>
515 Bug 557898 – Fails to build on OSX 10.4
517 * configure.ac: Check for $shrext_cmds that should be implicitly
518 available if you're using libtool >= 2.0. If undefined, call
519 libtool --config explicitly to get its value.
520 * girepository/gtypelib.c: Remove special case for (non-)Darwin
523 2008-10-31 Colin Walters <walters@verbum.org>
525 * COPYING, COPYING.lib, COPYING.tools: Clarify licensing status.
527 2008-10-31 Johan Dahlin <jdahlin@async.com.br>
529 * configure.ac: Post release version bump
532 2008-10-31 Johan Dahlin <jdahlin@async.com.br>
536 * docs/release-checklist.txt:
539 2008-10-31 Johan Dahlin <jdahlin@async.com.br>
541 * Makefile.am: add an upload-release target
542 * docs/release-checklist.txt:
543 Release process documentation
545 2008-10-31 Colin Walters <walters@verbum.org>
547 Bug 558109 – _g_typelib_init fails to find shared libraries
549 * transformer/glibtransformer.py: Use ctypes' find_library
550 on passed libraries and write that for the shared-library
551 entry. We want to avoid depending on -devel packages.
553 2008-10-31 Johan Dahlin <jdahlin@async.com.br>
555 * docs/g-ir-scanner.1:
556 Document the renaming options.
558 2008-10-31 Tommi Komulainen <tommi.komulainen@iki.fi>
560 * giscanner/Makefile.am:
561 * tests/invoke/Makefile.am:
562 * tests/repository/Makefile.am: List in-tree libraries first in
563 LDADD / LIBADD. If installed library is listed first, the
564 resulting binary will prefer installed version to one in .libs,
565 possibly making 'make check' behave strangely.
567 2008-10-30 Tommi Komulainen <tommi.komulainen@iki.fi>
569 * giscanner/ast.py: map 'id' (ObjC) to 'any' type to stop
570 gir-repository from choking with gdk/quartz
572 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
574 * giscanner/giscannermodule.c (calc_attrs_length),
575 (pygi_collect_attributes):
576 * giscanner/xmlwriter.py:
577 Write a C version of the xml namespace formatter.
578 Saves 15% of the time it takes to create a gtk gir.
580 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
582 * giscanner/xmlwriter.py: Abstract attribute formatting
583 to a function external to the XMLWriter class.
585 * giscanner/scannerlexer.l:
586 Parse and discard __typeof and __attribute.
588 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
590 * giscanner/girparser.py:
591 Remove arguments from the constructor, move them to
592 separate accessors. Add a new parse_tree method
593 which takes an element tree instance.
594 * tools/g-ir-scanner:
595 Update callsite for this
597 * giscanner/Makefile.am:
598 * giscanner/cachestore.py:
599 * giscanner/transformer.py:
600 Cache the include parsing. Saves ~25% time when
601 creating vte (which includes everything up to gtk+).
603 2008-10-30 Colin Walters <walters@verbum.org>
605 * giscanner/transformer.py: Don't reparse includes
606 we've already processed.
608 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
610 * giscanner/girparser.py:
611 * giscanner/transformer.py:
612 Avoid parsing parameters, types etc when parsing
613 includes. Should speed up include parsing a bit.
615 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
617 * giscanner/girparser.py:
618 Avoid big if/else and use a dispatch table like
621 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
623 * giscanner/transformer.py:
624 Clean up include parsing and registration.
626 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
628 * giscanner/transformer.py:
631 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
633 Bug 558383 – builddir != srcdir build fails if giscanner python module not already installed
636 construct PYTHONPATH just once
638 * tests/everything/Makefile.am:
639 * tests/scanner/Makefile.am:
640 add $(top_srcdir) to PYTHONPATH to
641 handle builddir != srcdir
643 * giscanner/libtoolimporter.py:
644 * giscanner/sourcescanner.py:
645 Make the libtoolimporter work when distchecking too.
647 Mostly based on patch by Tommi Komulainen
649 2008-10-29 Owen Taylor <otaylor@redhat.com>
651 * giscanner/glibtransformer.py: If a filename of an existing
652 file is passed to --library, hunt for it directly, rather than
653 searching for a corresponding library.
655 2008-10-29 Johan Dahlin <jdahlin@async.com.br>
657 * giscanner/libtoolimporter.py:
658 * giscanner/sourcescanner.py:
659 Clean up the libtool importer a bit. Add a context so we
660 can use it through a with statement.
661 Don't just look in the current directory, look in the whole
664 2008-10-29 Tommi Komulainen <tommi.komulainen@iki.fi>
666 Bug 558065 – gitesttypes should be installed
670 * tests/types/Makefile.am -> tests/everything/Makefile.am
671 * tests/types/gitesttypes.c -> tests/everything/gitesttypes.c
672 * tests/types/gitesttypes.h -> tests/everything/gitesttypes.h
673 move tests/types to tests/everything
675 * tests/everything/Makefile.am: build normal shared library
676 libgirepository-everything.so.1.0.0 and corresponding typelib
677 Everything-1.0.typelib
679 * tests/everything/Makefile.am: explicitly link libtool
680 versioning with typelib versioning with variables
682 2008-10-28 Johan Bilien <jobi@via.ecp.fr>
684 * tools/g-ir-scanner: add LD_LIBRARY_PATH to LPATH before calling ld.
686 2008-10-27 Johan Bilien <jobi@via.ecp.fr>
688 * gio/gio-2.0.c: add allow-none annotations, based on the pygobject
691 2008-10-27 Johan Bilien <jobi@via.ecp.fr>
693 Bug 558068 – when invoking a method, offset the in arguments by one,
696 * tests/invoke/invoke.c, tests/invoke/testfns.c,
697 tests/invoke/testfns-1.0.gir: Add testing of method and constructor.
698 * girepository/ginvoke.c: do not offset the index of given out
699 arguments by one for methods, "this" is provided as in argument only.
701 2008-10-27 Johan Bilien <jobi@via.ecp.fr>
703 * gir/gio-2.0.c: add annotation for g_file_delete
705 2008-10-27 Tommi Komulainen <tommi.komulainen@iki.fi>
707 Bug 558062 – provide and use paths in the .pc file
709 * gobject-introspection-1.0.pc.in: provide typelibdir variable
710 for where .typelibs should be installed (callers shouldn't need
711 to construct paths from bits and pieces)
713 2008-10-25 Andreas Rottmann <a.rottmann@gmx.at>
715 Bug 557791 – g_irepository_require() could return a GTypelib *
717 * girepository/girepository.c: Return GTypelib; this is useful
718 for low level manipulation.
720 2008-10-25 Colin Walters <walters@verbum.org>
722 Bug 557788 – Return types for constructors in generated typelib bogus
724 * giscanner/glibtransformer.py: Don't resolve ctors incrementally,
725 rely on end pass resolution.
727 2008-10-25 Andreas Rottmann <a.rottmann@gmx.at>
729 Bug 557786 - support fixed size arrays
731 * girepository/ginfo.c: Add g_type_info_get_array_fixed_size.
732 * giscanner/scannerparser.y: Retain fixed array size.
733 * giscanner/ast.py: Add to note.
734 * giscanner/girwriter.py: Write to gir.
735 * girepository/girnode.c: Write it to typelib.
736 * tools/generate.c: Generate.
737 * tests/*: Add tests.
739 2008-10-25 Colin Walters <walters@verbum.org>
741 Bug 557076 - move typelibs to $libdir
743 * configure.ac: Steal some configury bits from dbus to expand
745 * gir/Makefile.am: Move to libdir.
746 * girepository/girepository.c: Stop searching XDG_DATA_DIRS;
747 instead just look at one hardcoded path in libdir.
748 * acinclude.m4: Bits from dbus.
750 2008-10-24 Johan Dahlin <johan@gnome.org>
752 * girepository/girnode.c (g_ir_node_check_unhandled_members):
753 Be quiet, do not warn about unhandled members.
755 2008-10-24 Johan Dahlin <johan@gnome.org>
757 * girepository/gtypelib.c:
758 Only use SHLIB_SUFFIX on darwin, otherwise use
759 G_MODULE_SUFFIX, we cannot get shext_cmds from libtool 2.2.
761 2008-10-24 Lucas Rocha <lucasr@gnome.org>
763 Bug 557623 - Constructors shouldn't be flagged as methods.
765 * girepository/ginfo.c (g_function_info_get_flags): ditto.
767 2008-10-24 Johan Dahlin <johan@gnome.org>
769 * giscanner/scannerparser.y:
770 Check against division by zero for the modula operator.
771 This fixes header parsing of OSX system headers included
774 2008-10-24 Johan Dahlin <johan@gnome.org>
778 Add a CONTRIBUTORS file and dist it.
780 2008-10-23 Tommi Komulainen <tommi.komulainen@iki.fi>
782 Bug 556739 – transfer-ownership attribute should be mandatory in .gir
784 * girepository/girparser.c (parse_param_transfer):
785 * giscanner/transformer.py (_create_parameter, _create_return):
786 * giscanner/girwriter.py (_write_return, _write_parameter):
787 * tools/generate.c (write_callable_info): always write and
788 require "transfer-ownership" for return-values and parameters
791 * tests/invoke/testfns-1.0.gir:
793 * tests/scanner/DrawableAdditions.xml:
794 * tests/scanner/GtkFrob-1.0-expected.tgir:
795 * tests/scanner/annotation-1.0-expected.tgir:
796 * tests/scanner/drawable-1.0-expected.tgir:
797 * tests/scanner/drawable-injected-1.0-expected.gir:
798 * tests/scanner/drawable-injected-1.0-expected.tgir:
799 * tests/scanner/foo-1.0-expected.tgir: Updated
801 2008-10-23 Tommi Komulainen <tommi.komulainen@iki.fi>
803 * giscanner/cgobject.py: build fundamental types same way as glib
805 * giscanner/glibtransformer.py (_type_from_gtype): record GType
806 when constructing the Type from it
808 * giscanner/glibtransformer.py (_adjust_transfer): Check whether
809 the parameter is a GObject from its GType, if available.
811 * giscanner/glibtransformer.py (_adjust_transfer):
812 * tests/scanner/foo-1.0-expected.gir:
813 * tests/scanner/foo-1.0-expected.tgir: deduce
814 transfer-ownership from GTypes
816 2008-10-23 Tommi Komulainen <tommi.komulainen@iki.fi>
818 * giscanner/transformer.py (_create_parameter):
819 * tests/scanner/foo-1.0-expected.gir: make varargs
820 transfer-ownership="none"
822 2008-10-23 Colin Walters <walters@verbum.org>
824 Bug 556739 - transfer ownership
826 * giscanner/ast.py: Refactor Parameter/Return to share
827 common attributes. Add transfer_inferred attribute
828 which says whether or not we made a guess.
829 * giscanner/transformer.py: Add much more extensive
830 heuristics around parameter and return transfer.
831 * giscanner/glibtransformer.py: Adjust to inspect
835 2008-10-22 Tommi Komulainen <tommi.komulainen@iki.fi>
837 Bug 557377 – Add test to ensure annotations survive the roundtrip via typelib
839 * tests/scanner/Makefile.am:
840 * tests/scanner/annotation-1.0-expected.tgir:
841 * tests/scanner/drawable-1.0-expected.tgir:
842 * tests/scanner/drawable-injected-1.0-expected.tgir:
843 * tests/scanner/foo-1.0-expected.tgir:
844 * tests/scanner/GtkFrob-1.0-expected.tgir:
845 * tests/scanner/utility-1.0-expected.tgir: Add test to ensure
846 annotations survive the roundtrip via typelib
848 The expectations are as currently produced by g-ir-generate,
849 comparison with the .gir files shows there are differences.
851 2008-10-23 Johan Bilien <jobi@via.ecp.fr>
853 Bug 557468 – Support for GI_TYPELIB_PATH
855 * girepository/girepository.c: if the GI_TYPELIB_PATH is set, add the
856 provided paths to the global search path.
858 2008-10-22 Tommi Komulainen <tommi.komulainen@iki.fi>
860 Bug 557379 – g-ir-generate not writing the 'abstract' attribute
862 * tests/scanner/drawable-1.0-expected.tgir:
863 * tests/scanner/drawable-injected-1.0-expected.tgir:
864 * tests/scanner/foo-1.0-expected.tgir:
865 * tools/generate.c (write_object_info): write 'abstract'
866 attribute for classes
868 2008-10-22 Lucas Rocha <lucasr@gnome.org>
870 * girepository/girmodule.c, girepository/gtypelib.c,
871 girepository/girparser.[ch]: fix some build warnings.
873 2008-10-22 Tommi Komulainen <tommi.komulainen@iki.fi>
875 Bug 557405 – Use 'allow-none' consistently
877 * docs/typelib-format.txt:
878 * girepository/ginfo.c (g_arg_info_may_be_null):
879 * girepository/girnode.c (g_ir_node_build_typelib):
880 * girepository/girnode.h (struct _GIrNodeParam):
881 * girepository/girparser.c (start_parameter):
882 * girepository/girwriter.c (function_generate):
883 * girepository/gtypelib.h (ArgBlob):
885 * tests/function.gir:
886 * tools/generate.c (write_callable_info): Use 'allow-none'
887 consistently throughout
889 2008-10-22 Tommi Komulainen <tommi.komulainen@iki.fi>
891 Bug 557092 – Callback annotations not used
893 * giscanner/transformer.py (_create_callback): use annotations
895 * tests/scanner/annotation.h
896 * tests/scanner/annotation-1.0-expected.gir: add tests
898 2008-10-21 Colin Walters <walters@verbum.org>
900 * giscanner/scannerlexer.l: Don't require trailing whitespace after
901 uncommented parameters.
904 2008-10-21 Colin Walters <walters@verbum.org>
906 * girepository/girepository.c: Ensure that when doing an unversioned
907 require, we prefer items earlier in the search path to later ones.
909 2008-10-21 Owen Taylor <otaylor@redhat.com>
911 * giscanner/transformer.py: For string parameters allow transfer annotation
912 to override the standard automatic guessing based on 'const'.
914 2008-10-21 Johan Bilien <jobi@via.ecp.fr>
916 Bug 557241 – "throws" flag for functions
918 * tests/scanner/drawable-1.0-expected.gir,
919 tests/scanner/drawable-injected-1.0-expected.gir,
920 tests/scanner/drawable.[ch]: add simple test for throwing
921 function (has GError ** as last argument)
923 * giscanner/ast.py: add a 'throws' flag to Function
924 * giscanner/glibtransformer.py: if a function's last paramerter is
925 a GError, set the 'throws' flag and remove that parameter
926 * giscanner/girwriter.py: write out the 'throws' attribute
927 * giscanner/girparser.py: support parsing the 'throws' attribute
929 * tests/repository/gitestthrows.c: add a simple test to check the
930 throws flag in a typelib and invoke the function
932 * girepository/ginfo.c, girepository/girnode.[ch],
933 girepository/girnode.h, girepository/girparser.c,
934 girepository/girepository.h: Add and parse the GI_FUNCTION_THROWS flag
936 * girepository/ginvoke.c: if a function throws, add a GError as last
937 arguments, and propagate the error to the invoker.
939 2008-10-21 Tommi Komulainen <tommi.komulainen@iki.fi>
941 * giscanner/transformer.py (_create_parameters): Warn if we see
942 annotations for unknown parameters. If .h and .c files name
943 parameters differently, the annotations may be lost.
945 2008-10-21 Johan Dahlin <johan@gnome.org>
947 Bug 556358 - don't use libtool internals
949 * giscanner/Makefile.am:
950 * giscanner/libtoolimporter.py:
951 * giscanner/sourcescanner.py:
952 * giscanner/utils.py:
953 Add a python meta importer and remove a libtool symlink hack.
955 2008-10-20 Andreas Rottmann <a.rottmann@gmx.at>
957 * tests/scanner/Makefile.am (%.typelib): Set PYTHONPATH
958 and --add-include-path appropriately when invoking the scanner.
959 * tests/types/Makefile.am (%typelib): Likewise.
961 2008-10-20 Colin Walters <walters@verbum.org>
963 Bug 556777 - validate properties
965 * giscanner/transformer.py: Add option to throw on unknown types.
966 * giscanner/glibtransformer.py: Use it on properties.
967 * tests/*: Add a test.
969 2008-10-20 Colin Walters <walters@verbum.org>
971 * giscanner/glibast.py: Also register g variants of
972 default_array_types. This is not beautiful, but
973 good alternatives aren't easy to come by.
974 This fixes gchar ** parsing.
976 2008-10-20 Colin Walters <walters@verbum.org>
978 * docs/typelib-format.txt, girepository/gtypelib.h:
979 Take a bit from ObjectInfo to represent abstract flag.
980 * giscanner/cgobject.py: Expose g_type_get_flags.
981 * girepository/girepository.h: Add accessor.
982 * girepository/ginfo.c: Implement it.
983 * giscanner/ast.py: Add is_abstract flag to generic
985 * giscanner/glibast.py: Use it.
986 * giscanner/girwriter.py: Write it.
987 * girepository/girparser.c: Parse it.
990 2008-10-20 Tommi Komulainen <tommi.komulainen@iki.fi>
992 * giscanner/girparser.py (_parse_function): don't lose
993 'transfer-ownership' attributes when injecting, check for the
996 2008-10-19 Johan Dahlin <johan@gnome.org>
998 * giscanner/scannerlexer.l: Parse and ignore __asm.
1000 2008-10-19 Colin Walters <walters@verbum.org>
1002 * giscanner/girparser.py: Parse array length= to ensure
1003 it doesn't get lost from --inject.
1005 2008-10-17 Colin Walters <walters@verbum.org>
1007 Bug 556795 - char ** regression
1009 * giscanner/transformer.py: Fix parsing of ctypes, add some
1010 comments about what's going on.
1011 * tests/*: Add a test for char **.
1013 2008-10-17 Colin Walters <walters@verbum.org>
1015 Bug 556783 - change namespace handling to be more consistent
1017 * giscanner/transformer.py: Eliminate usage of
1018 strip_namespace_object. We now treat --namespace as the default
1019 --strip-prefix; however, if --strip-prefix is specified it
1020 overrides --namespace. This applies to everything except function
1021 names, where we do also strip the namespace.
1022 * giscanner/glibtransformer.py: Remove usage of
1023 strip_namespace_object.
1025 * tests/*: Add skeletal GtkFrob-1.0 test which has different
1026 --namespace and --strip-prefix.
1028 2008-10-17 Tommi Komulainen <tommi.komulainen@iki.fi>
1030 Bug 556732 – generate gir files consistently
1032 * girepository/girparser.c (start_parameter):
1034 * tests/invoke/testfns-1.0.gir:
1035 * tools/generate.c (write_callable_info): write
1036 'transfer-ownership' attribute consistently with both
1037 return-value and parameter elements
1039 2008-10-17 Tommi Komulainen <tommi.komulainen@iki.fi>
1041 Bug 556732 – generate gir files consistently
1043 * tools/generate.c (write_callable_info): write 'direction'
1044 attribute only if other than 'in' to be consistent with
1047 * tests/object.gir: remove direction="in" which is the default
1049 2008-10-17 Tommi Komulainen <tommi.komulainen@iki.fi>
1051 Bug 556732 – generate gir files consistently
1053 * giscanner/ast.py (Field): add readable and writable properties
1054 * giscanner/girparser.py (_parse_field): copy 'readable' and
1055 'writable' attributes
1056 * giscanner/transformer.py (_create_member): create fields as
1058 * giscanner/glibtransformer.py (_introspect_object,
1059 _pair_class_struct): make object instance and class fields
1061 * giscanner/girwriter.py (_write_field):
1062 * tools/generate.c (write_field_info): write field 'readable'
1063 and 'writable' attributes only if non-default (read-only)
1064 * girepository/girparser.c (start_field): in the absence of
1065 attributes assume fields are read-only
1067 * tests/struct.gir: remove redundant readable="1" from fields
1068 * tests/scanner/foo-1.0-expected.gir:
1069 * tests/scanner/utility-1.0-expected.gir: add writable="1" to
1070 all record and union fields
1072 2008-10-17 Tommi Komulainen <tommi.komulainen@iki.fi>
1074 Bug 556732 – generate gir files consistently
1076 * giscanner/girwriter.py (_write_property): write properties
1077 'construct' attribute if set
1078 * tools/generate.c (write_property_info): write properties
1079 'readable' and 'writable' attributes only if non-default
1080 * tests/object.gir: add writable="0"
1081 * tests/scanner/foo-1.0-expected.gir: add construct="1"
1083 2008-10-17 Johan Bilien <jobi@via.ecp.fr>
1085 * gir/glib-2.0.c: added annotations
1087 2008-10-16 Johan Bilien <jobi@via.ecp.fr>
1089 * giscanner/ast.py: Also assume direction=out for size_t*, ssize_t*
1092 2008-10-16 Johan Bilien <jobi@via.ecp.fr>
1094 Bug 556610 – giscanner/girparser.py drops parameter options
1096 * tests/scanner/drawable-injected-1.0-expected.gir,
1097 tests/scanner/DrawableAdditions.xml: added simple test for injection.
1098 * giscanner/ast.py: allow Parameter to take options in the constructor
1099 * giscanner/girparser.py: parse parameter options (transfer,
1100 direction, allow-none)
1102 2008-10-16 Colin Walters <walters@verbum.org>
1104 Bug 556185 - segfault on g_callable_info_get_return_type
1106 Initial patch from John Ehresman.
1108 * tests/repository/*: Add a test using
1109 g_callable_info_get_return_type. Instead of casting a
1110 GITypeInfo directly to a GIRegisteredTypeInfo, we need
1111 to call g_type_info_get_interface.
1113 2008-10-16 Colin Walters <walters@verbum.org>
1115 Bug 556579 - union and struct name misresolved
1117 * giscanner/transformer.py: The calls to _resolve_type_name
1118 for struct/union names was a legacy holdover from when type
1119 resolution had multiple phases. Now it's actively harmful
1120 since we might pull in an identical name from another
1124 2008-10-16 Colin Walters <walters@verbum.org>
1126 Bug 556432 - transfer annotations and defaults
1128 * giscanner/transformer.py: Canonicalize type
1129 after removing *, not before. This ensures that
1130 guchar* is transformed to 'uint8'.
1131 Add some comments here.
1132 * giscanner/glibtransformer.py: Add _adjust_transfer
1133 phase for tweaking GObject transfers.
1136 2008-10-16 Tommi Komulainen <tommi.komulainen@iki.fi>
1138 * configure.ac: enable bunch of gcc warning CFLAGS
1140 2008-10-16 Tommi Komulainen <tommi.komulainen@iki.fi>
1142 Bug 556543 – reduce compiler warnings
1144 * girepository/ginfo.c:
1145 * girepository/girepository.c (register_internal,
1146 count_interfaces, find_interface, find_namespace_version,
1147 parse_version, g_irepository_require):
1148 * girepository/girmodule.c (g_ir_module_build_typelib):
1149 * girepository/girnode.c (init_stats, dump_stats,
1150 _g_irnode_init_stats, _g_irnode_dump_stats,
1151 g_ir_node_can_have_member):
1152 * girepository/girparser.c (firstpass_end_element_handler,
1153 locate_gir, parse_basic, parse_type_internal, resolve_aliases,
1154 start_alias, start_type, end_type_top, parse_include, cleanup,
1156 * girepository/gtypelib.c (validate_function_blob, validate_enum_blob):
1157 * giscanner/giscannermodule.c (directive_get_options,
1158 type_get_child_list):
1159 * giscanner/scannerlexer.l (parse_gtkdoc):
1160 * giscanner/scannerparser.y (ctype_free):
1161 * giscanner/sourcescanner.c:
1162 * giscanner/sourcescanner.h (gi_source_scanner_parse_macros):
1163 * tests/types/gitesttypes.c:
1164 * tools/compiler.c (main):
1165 * tools/generate.c (write_repository): Remove unused variables
1166 and code, add missing includes, declarations and case
1169 2008-10-16 Tommi Komulainen <tommi.komulainen@iki.fi>
1171 Bug 556541 – access union members through UnionBlob rather than
1174 * girepository/ginfo.c (g_union_info_find_method): access union
1175 members through UnionBlob rather than StructBlob
1177 2008-10-15 Colin Walters <walters@verbum.org>
1179 Bug 556331 - clean up includes handling
1181 * tools/g-ir-scanner: Rework command line arguments; now we take
1182 --add-include-path and --include separately.
1183 * giscanner/girwriter.py: Separate name= and version= in include
1185 * giscanner/ast.py: Add Include type.
1186 * giscanner/transformer.py: Cleanups to register_include now that
1187 we don't need to handle mixed filenames and relative arguments.
1188 * girepository/girparser.c: Parse name and version separately;
1189 this fixes a bug as a side effect where we weren't resolving
1190 through aliases for basic types.
1191 * girepository/girepository.c: Fix format string args.
1192 * gir/Makefile.am: Update.
1195 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1197 Bug 556434 – unhandled interface/object/... member types
1199 * girepository/girnode.c (g_ir_node_check_unhandled_members,
1200 g_ir_node_build_typelib): Check all
1201 interface/object/boxed/struct/union members are processed and
1202 abort if they are not. (Mostly callbacks in structs, but also
1203 fields in interfaces.)
1205 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1207 * a/girepository/girnode.c (g_ir_node_build_members,
1208 g_ir_node_build_typelib): refactor common code for processing
1209 members to a function
1211 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1213 * gir/Makefile.am (check-local): check that typelib -> gir -> typelib
1214 transformation is lossless (it's not)
1216 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1218 * tests/Makefile.am: fix tests to compare xml to xml instead of
1219 typelib to xml, and stop on error
1221 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1223 * tools/generate.c (write_type_name, write_type_info,
1224 write_type_info, write_object_info, write_object_info,
1225 write_interface_info, write_error_domain_info): reduce code
1228 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1230 Bug 556174 – parse types for lists etc.
1232 * girepository/girparser.c (end_type_recurse):
1234 * tools/generate.c (write_type_info, write_field_info,
1235 write_callable_info, write_callable_info, write_constant_info,
1236 write_property_info): use nested <type>s for lists and hashes
1238 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1241 * tests/object.gir: remove trailing whitespace from inside
1242 elements to match g-ir-generate output
1244 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1246 * tools/generate.c (xml_printf): quote printf arguments so that
1247 we don't generate invalid XML by writing unescaped double quotes
1248 and such in attributes
1250 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1252 * tools/generate.c (write_field_info, write_callable_info,
1253 write_function_info, write_callback_info, write_struct_info,
1254 write_constant_value, write_signal_info, write_vfunc_info,
1255 write_object_info, write_interface_info, write_union_info,
1256 write_repository): remove unused indent parameters, xmlwriter
1257 keeps track of necessary indentation
1259 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1261 * tools/generate.c (xml_element_new, xml_element_free,
1262 xml_start_element, xml_end_element, xml_end_element_unchecked,
1263 xml_open, xml_close): Keep track of generated XML tree and
1264 handle indentation and closing tags properly.
1265 (write_field_info, write_callable_info, write_function_info,
1266 write_callback_info, write_struct_info, write_value_info,
1267 write_constant_info, write_enum_info, write_signal_info,
1268 write_vfunc_info, write_property_info, write_object_info,
1269 write_interface_info, write_error_domain_info, write_union_info,
1270 write_repository): Use xml_start_element and xml_end_element to
1273 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1275 * tools/generate.c (xml_printf, xml_open, xml_close, xml_free):
1276 (write_type_name, write_type_info, write_field_info,
1277 write_callable_info, write_function_info, write_callback_info,
1278 write_struct_info, write_value_info, write_constant_value,
1279 write_constant_info, write_enum_info, write_signal_info,
1280 write_vfunc_info, write_property_info, write_object_info,
1281 write_interface_info, write_error_domain_info, write_union_info,
1282 write_repository): wrap all FILE access to go through simple xmlwriter
1284 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1286 Bug 556400 – Fails to build on OS X 10.4
1288 * configure.ac: check for functions backtrace and backtrace_symbols
1289 * girepository/girparser.c (backtrace_stderr): Comment out
1290 implementation if the functions are not available.
1291 * gcov.mak (clean-gcov, clean-gcno): always call 'find' with a
1292 directory for better portability
1294 2008-10-15 Johan Bilien <jobi@via.ecp.fr>
1296 Bug 556433 – assume direction = out for int * parameters
1298 * giscanner/ast.py: define a list of types for which, if passed as
1299 reference, we assume a default direction of 'out'
1300 * giscanner/transformer.py: if a type has type pointer to one of the
1301 previously defined types, and no direction is set, assume out.
1302 * tests/scanner/drawable.[ch]: added tests for guessed direction=out
1304 2008-10-15 Johan Bilien <jobi@via.ecp.fr>
1306 * tests/scanner/annotation.c: fixed a few copy-paste errors
1308 2008-10-14 Johan Bilien <jobi@via.ecp.fr>
1310 Bug 556323 – transfer-ownership is wrong for functions returning const
1313 * giscanner/transformer.py: check for a const string as return value,
1314 not just const char*. Suggested by Colin Walters
1315 * tests/scanner/annotation-1.0-expected.gir: updated expected output
1317 2008-10-14 Johan Bilien <jobi@via.ecp.fr>
1319 * girepository/ginfo.c, girepository/girepository.h: add
1320 g_union_info_find_method
1322 2008-10-14 Colin Walters <walters@verbum.org>
1324 * tests/repository/Makefile.am: Reenable repo test.
1325 * tests/repository/gitestrepo.c: Prepend search
1326 path for $(top_builddir)/gir dir so that we don't
1327 require installation for "make check" to pass.
1329 2008-10-13 Jürg Billeter <j@bitron.ch>
1331 * giscanner/glibtransformer.py:
1332 * tests/scanner/annotation-1.0-expected.gir:
1333 * tests/scanner/drawable-1.0-expected.gir:
1334 * tests/scanner/foo-1.0-expected.gir:
1335 * tests/scanner/utility-1.0-expected.gir:
1337 Support fields in GObject structs
1339 2008-10-13 Jürg Billeter <j@bitron.ch>
1341 * giscanner/ast.py: add signed integer and off_t to type_names
1343 2008-10-12 Jürg Billeter <j@bitron.ch>
1345 * giscanner/girparser.py: Parse bits attribute of fields
1347 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1349 * tests/repository/Makefile.am: run 'gitestrepo' in 'make check'
1350 * tests/repository/gitestrepo.c (main): instantiate
1351 'GCancellable' to ensure the GType is registered before using
1354 2008-10-12 Johan Bilien <jobi@via.ecp.fr>
1356 * giscanner/girparser.py: actually add the parsed constant nodes
1358 2008-10-12 Colin Walters <walters@verbum.org>
1360 * girepository/girepository.c: Don't cast DirEntry to Blob,
1361 actually look it up by offset.
1363 2008-10-12 Johan Bilien <jobi@via.ecp.fr>
1365 * giscanner/girparser.py: parse constant nodes in gir files
1367 2008-10-12 Johan Bilien <jobi@via.ecp.fr>
1369 * giscanner/transformer.py: prefix for constants have an underscore,
1370 so remove them as if they were functions, not objects.
1372 2008-10-12 Johan Bilien <jobi@via.ecp.fr>
1374 * tests/scanner/foo-1.0-expected.gir: add constants to expected gir
1377 2008-10-12 Colin Walters <walters@verbum.org>
1379 Initial patch from Jani Monoses.
1381 * girepository/gtypelib.c: Fix inverted test for success
1384 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1386 * tools/generate.c (write_callable_info): use "transfer-ownership"
1387 attribute for return values
1389 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1391 * tools/generate.c (write_callable_info): move "transfer" and
1392 "null-ok" attributes from <function> to <return-value> element
1394 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1396 * girepository/girparser.c (start_return_value): handle
1397 "transfer-ownership" attribute
1399 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1401 * girepository/girparser.c (parse_param_transfer):
1402 * tools/generate.c (write_callable_info): use "container" for
1403 container/shallow ownership transfer (not "shallow")
1405 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1407 * girepository/girparser.c (parse_param_transfer,
1408 start_parameter): Refactor handling of transfer=none/shallow/full
1409 to separate function
1411 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1413 Bug 556048 – Crash in g_irepository_find_by_gtype
1415 * girepository/gtypelib.h (BLOB_IS_REGISTERED_TYPE): added
1416 * girepository/girepository.c (find_interface): Fix
1417 find_by_gtype case to get the type name from right offset
1419 2008-10-12 Jürg Billeter <j@bitron.ch>
1421 * giscanner/girparser.py: Fix parsing transfer-ownership attribute
1424 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1426 * girepository/gtypelib.h (RegisteredTypeBlob): make
1427 'unregistered' one bit wide as everywhere else
1429 2008-10-12 Jürg Billeter <j@bitron.ch>
1431 * giscanner/glibtransformer.py:
1432 * tests/scanner/annotation-1.0-expected.gir:
1433 * tests/scanner/drawable-1.0-expected.gir:
1434 * tests/scanner/drawable.h:
1435 * tests/scanner/foo-1.0-expected.gir:
1436 * tests/scanner/utility-1.0-expected.gir:
1438 Readd class records as workaround to not break Gtk typelib
1440 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1442 * tests/types/Makefile.am: fix typo in gitesttypes namespace
1444 2008-10-12 Jürg Billeter <j@bitron.ch>
1446 * giscanner/glibtransformer.py: Don't generate <record> elements
1448 * tests/scanner/*: Update test cases
1450 2008-10-11 Colin Walters <walters@verbum.org>
1452 Bug 552858: versioning
1454 This is a big patch. You should probably remove your installation
1457 * docs/typelib-format.txt: Add nsversion entry which holds
1458 version of namespace.
1459 * girepository/girepository.h: Add 'version' parameter to
1460 g_irepository_require. This may be NULL. Normally
1461 bindings should pass an explicit version though.
1462 * girepository/girepository.c: Lots of infrastructure to
1463 support versioning. Add some more documentation. Disallow
1464 some usage of NULL namespaces.
1465 * girepository/girmodule.c: Add version parameter.
1466 * girepository/gtypelib.c: Update header size.
1467 * giscanner/ast.py: Add version to Namespace.
1468 * giscanner/girparser.py: Parse version attribute from
1469 XML, pass to Namespace.
1470 * giscanner/girwriter.py: Write out version parameter.
1471 * giscanner/transformer.py: Clean up include registration.
1472 * tests/*: Add version attribute.
1473 * tests/invoke/invoke.c: Don't try looking up test before
1474 it's loaded in repository.
1475 * tools/generate.c: Output version parameter.
1476 * gir/Makefile.am: Add 2.0 version to .gir files.
1478 2008-10-11 Colin Walters <walters@verbum.org>
1480 * giscanner/scannerlexer.l (parse_gtkdoc): Don't lose
1481 if we have mismatched parens.
1483 2008-10-11 Lucas Rocha <lucasr@gnome.org>
1485 * giscanner/girparser.py (_parse_enumeration_bitfield): fix typo
1486 on 'members' variable.
1488 2008-10-11 Colin Walters <walters@verbum.org>
1490 Bug 555947 - update annotations syntax
1492 * giscanner/ast.py: Default to None for transfer. Remove
1493 default transfers for container types; we require this to
1495 * giscanner/girwriter.py: Transfer is now 'none', 'container',
1496 'full' to match repository.
1497 * giscanner/scannerlexer.l: Annotations now are parenthesized.
1498 * giscanner/transformer.py: Update for new annotations syntax.
1501 2008-10-11 Johan Bilien <jobi@litl.com>
1503 * giscanner/scannerparser.y: ignore non-UTF-8 string constants
1505 2008-10-11 Johan Bilien <jobi@litl.com>
1507 Bug 552347: Parse #defines constants
1509 * girepository/gtypelib.c: update the list of value_size
1510 with recently defined type tags
1511 * giscanner/scannerparser.y: brought back parsing of #defined, as
1512 present in older version
1513 * giscanner/giscannermodule.c: bind gi_source_scanner_append_filename
1514 * giscanner/girwriter.py: write out constant tags in the gir
1515 * giscanner/sourcescanner.py: add accessor for const_string
1516 * giscanner/transformer.py, giscanner/glibtransformer.py: handle
1519 2008-10-11 Tommi Komulainen <tommi.komulainen@iki.fi>
1521 Bug 555946: Install a test module exercising all types, transfer
1526 * tests/types/*: Add and install a test module that has functions
1527 accepting and returning most of the basic types to enable bindings
1528 implementors to more easily test their type conversion routines.
1530 2008-10-11 Jürg Billeter <j@bitron.ch>
1532 Bug 552374: Const strings should be identified in the gir.
1534 * giscanner/transformer.py: support string memory management
1535 * tests/scanner/foo.h: use char * and const char *
1536 * tests/scanner/foo-expected.gir: test that
1538 2008-10-11 Johan Dahlin <johan@gnome.org>
1540 * giscanner/girparser.py:
1541 Also parse enums which are not glib types.
1543 2008-10-11 Lucas Rocha <lucasr@gnome.org>
1545 Bug 552370: add one more test for unsigned as a type, not as
1548 * giscanner/ast.py: add 'uint' type name for 'unsigned'.
1549 * test/scanner/foo.h: add function which uses unsigned as a type.
1550 * test/scanner/foo-expected.gir: test that.
1552 2008-10-11 Andreas Rottmann <a.rottmann@gmx.at>
1554 Bug 555712: Struct and union issues
1556 * giscanner/scannerparser.y (struct_declarator): Use information
1557 provided about the bit width of a field.
1558 * giscanner/transformer.py (Transformer._create_member): Pass the
1559 symbol's const_int member to the created field (it represents the
1561 * giscanner/girwriter.py (GIRWriter._write_field): Output 'bits'
1562 field attribute, if present.
1563 * giscanner/ast.py (Field): Add 'bits' member, specifying the
1564 width in bits of the field (only relevant for bitfields).
1567 * giscanner/transformer.py (Transformer._create_typedef_struct)
1568 (Transformer._create_typedef_union): Add calls to _create_struct()
1569 and _create_union(), respectively. This causes the scanner to
1570 generate output for fields of struct and union typedefs.
1573 2008-10-11 Jürg Billeter <j@bitron.ch>
1575 Bug 552370: unsigned not scanned properly
1577 * giscanner/scannerparser.y: combine basic types such as unsigned
1578 int and long long when scanning
1579 * tests/scanner/foo-expected.gir:
1580 * tests/scanner/foo.c: (foo_test_unsigned):
1581 * tests/scanner/foo.h: test that
1583 2008-10-11 Lucas Rocha <lucasr@gnome.org>
1585 Bug 554854: The --typelib-xml and --inject options should reuse
1586 giscanner parser/writer.
1588 * giscanner/ast.py: add constructor list to Struct and Union.
1589 Add new param in Return's contructor to define transfer.
1590 * giscanner/girparser.py: several additions to the parser in order
1591 to have parsing all nodes of the gir xml files.
1592 * tools/g-ir-scanner (typelib_xml_strip, inject): use gir parser
1593 and writer in --inject and --typelib-xml options.
1594 * giscanner/xmlwriter.py: ignore empty attributes instead of
1595 raising an error as this basically exposes a bug in GIRParser.
1596 This should be reverted as soon as the parser is fixed.
1598 2008-10-11 Lucas Rocha <lucasr@gnome.org>
1600 Bug 552376: scanner generates wrong names for enum members when
1601 there's no defined gtype.
1603 * giscanner/utils.py (strip_common_prefix): Always strip common
1604 prefix exactly up to the last "_", and not beyond.
1605 * tests/scanner/foo.h (FooEnumNoType): add FOO_ENUM_NEUF. The point
1606 here is that the first character after the last '_' should should be
1607 the same as the character in the same position on the type name.
1608 * tests/scanner/foo-expected.gir: test that
1610 2008-10-10 Lucas Rocha <lucasr@gnome.org>
1612 Bug 555293: append library_paths to LPATH env variable to work
1613 around a bug in find_library when using ldconfig.
1615 * tools/g-ir-scanner (main): ditto.
1617 2008-10-09 Lucas Rocha <lucasr@gnome.org>
1619 * girepository/girepository.c (register_internal): fix regression on
1620 invoke test case by making sure we load the global module in the
1621 typelib when dealing with inline typelibs.
1622 * girepository/gtypelib.c: a couple of coding style fixes.
1624 2008-10-06 Lucas Rocha <lucasr@gnome.org>
1626 Bug 555294: Add support for multiple shared libraries per typelib.
1628 * girepository/ginvoke.c (g_function_info_invoke),
1629 girepository/ginfo.c(g_registered_type_info_get_g_type): use
1630 g_typelib_symbol instead of g_module_symbol.
1631 * girepository/girepository.h: remove g_typelib_set_module and add
1633 * girepository/gtypelib.[ch] (find_some_symbol, _g_typelib_init,
1634 g_typelib_new_from_memory, g_typelib_new_from_const_memory,
1635 g_typelib_free, g_typelib_symbol): chnage GTypeLib to hold a list of
1636 modules instead of just one. The symbol lookup is now abstracted
1637 behind g_typelib_symbol which tries to find the passed symbol name in
1639 * giscanner/girwriter.py, tools/g-ir-scanner: change scanner to read
1640 and write shared_library attribute as a comma-separated list of libs.
1642 2008-10-06 Colin Walters <walters@verbum.org>
1644 * giscanner/transformer.py: Parse length= annotation as
1645 a parameter name, not a raw int.
1648 2008-10-03 Colin Walters <walters@verbum.org>
1650 Bug 551744: Non-GObject types aren't aggregating ctors and methods
1652 * girepository/gtypelib.c: Allow ctors/methods on struct,union,
1654 * giscanner/glibtransformer.py: Ditto, and GLibBoxed is also a
1658 2008-10-03 Colin Walters <walters@verbum.org>
1660 Bug 554576: scan problem with ev_selection_render_selection()
1662 * giscanner/transformer.py: Only do type resolution once we've
1663 scanned all types. What could happen before is that we'd strip
1664 the namespace from local type "EvSelection" => Selection, and
1665 then later pull a "Selection" from some other namespace because
1666 we hadn't yet seen the local EvSelection. This could come
1667 down to hash table ordering and other things so not easy
1668 to write a test for.
1670 2008-10-03 Lucas Rocha <lucasr@gnome.org>
1672 * giscanner/girwriter.py (_parser_member): fix the last parameter of
1673 GLibEnumMember constructor as it should be the enum member nick.
1675 2008-10-02 Colin Walters <walters@verbum.org>
1677 Bug 552961: remove this parameter for methods
1679 * giscanner/glibtransformer.py: Delete this parameter; it is
1681 * girepository/ginvoke.c: Insert this parameter for methods.
1682 * girepository/gtypelib.c: Remove no longer needed verification of
1683 method this parameter.
1686 2008-09-30 Dan Winship <danw@gnome.org>
1688 Bug 554490: g-ir-scanner gets confused by '\\'
1690 * giscanner/scannerlexer.l (chartext, stringtext): fix use of
1691 backslashes so it will correctly parse '\\' and "\\"
1693 * tests/scanner/annotation.c: add a use of '\\' to make sure that
1696 * giscanner/glibtransformer.py (GLibTransformer.count_type): typo
1698 2008-10-02 Colin Walters <walters@verbum.org>
1700 bug 552393: Note variadic functions
1702 * giscanner/scannerparser.y: Parse ellipsis. Refactor grammar
1703 to use parameter_list directly.
1704 * giscanner/sourcescanner.h: Add ellipsis csymbol type.
1705 * giscanner/ast.py: Add Varargs type.
1706 * giscanner/transformer.py: Check for ellipsis symbol, transform
1708 * girepository/girnode.h: Add varargs flag to in-memory nodes.
1709 Parse varargs functions, but filter them out before we start
1710 compiling the typelib.
1712 2008-10-02 Colin Walters <walters@verbum.org>
1714 Bug 554632: type tag for GType
1716 * girepository/girepository.h, girepository/girepository.c:
1717 Add type tag for GType - it's a special type we don't want
1718 to resolve to just "long".
1719 * docs/typelib-format.txt: Update.
1720 * girepository/girparser.c: Parse it.
1721 * giscanner/glibtransformer.py: Ensure we don't put GType in
1723 * tools/generate.c: Remove hardcoded type list.
1726 2008-09-30 Dan Winship <danw@gnome.org>
1728 Bug 554521: scanner generates wrong names for enum members with
1729 full type name prefix
1731 * giscanner/utils.py (strip_common_prefix): Fix this to strip the
1732 right amount when the entire "first" string is a prefix of
1735 * tests/scanner/foo.h (FooEnumFullname):
1736 * tests/scanner/foo-expected.gir: test that
1738 2008-09-29 Colin Walters <walters@verbum.org>
1740 Bug 552380: Array parameters should be marked in the gir
1742 * giscanner/ast.py: Default char** to utf8[], and guchar* to
1743 uint8[]. Add Array, List, and Map subclasses of Type;
1744 these types can be generic. Return transfer defaults
1745 to true if return value is string or container type.
1746 Delete Sequence type.
1747 * giscanner/scannerlexer.l: Syntax change for annotations;
1748 use <> since it's more readable.
1749 * giscanner/girwriter.py: Write out these changes.
1750 * giscanner/girparser.py: Parse them.
1751 * giscanner/transformer.py: Have a defined set of
1752 both list and map types. When creating a type,
1753 check if the ctype we've parsed is one of them,
1754 if so create a container type subclass as appropriate.
1755 * girepository/girparser.c: Parse in generic types.
1758 2008-09-27 Colin Walters <walters@verbum.org>
1760 * tools/g-ir-scanner: Add --inject option.
1762 2008-09-25 Colin Walters <walters@verbum.org>
1764 Remove non-repository types from GIR
1766 * giscanner/ast.py: The canonical name is 'utf8', not
1768 * giscanner/glibast.py: A few more glib type mappings.
1769 * girepository/girparser.c: We only parse repository types.
1770 * tests/*.gir: Update.
1772 2008-09-23 Colin Walters <walters@verbum.org>
1774 Bug 552566: Add time_t type
1776 We need a type for time_t since it's special in C, and just
1777 mapping it to long precluded bindings from handling it
1780 2008-09-19 Colin Walters <walters@verbum.org>
1782 Bug 552390: Handle capitialization like "DBus" more robustly
1784 The to_underscores function was designed for use against prefixed
1785 names; we need a separate function which will convert names like
1786 DBusFoo into dbus_foo, not d_bus_foo.
1788 2008-09-19 Colin Walters <walters@verbum.org>
1790 Add check to make sure we're not hitting out unresolved types
1792 Validate the "this" argument for methods
1794 Remove heuristic matching of methods to classes based on prefix
1796 It was a broken hack that dated from when we handled underscoring
1797 and capitalization conventions less well.
1799 2008-09-18 Colin Walters <walters@verbum.org>
1801 Bug 552384: Use SHLIB_SUFFIX intead of G_MODULE_SUFFIX for Darwin
1803 On Darwin, the suffix for installed shared libraries (.dylib) is
1804 different from loadable modules (.so). We use a bit of magic shell
1805 script from Behdad Esfahbod to figure out the right suffix.
1807 2008-09-15 Johan Dahlin <johan@gnome.org>
1809 * giscanner/sourcescanner.py (SourceType.type_qualifier): Add
1810 a wrapper for type_qualifier as well.
1812 2008-09-15 Colin Walters <walters@verbum.org>
1814 http://bugzilla.gnome.org/show_bug.cgi?id=552065
1816 * giscanner/ast.py: Add deprecation attributes.
1817 * giscanner/girwriter.py: Write out deprecation data.
1818 * girepository/girparser.c: Relax parsing; deprecated
1819 attribute now includes freeform string.
1820 * giscanner/scannerlexer.l: Parse Deprecated.
1821 * giscanner/transformer.py: Look for deprecated attribute
1823 * tests/scanner/*: Add a Deprecated test.
1825 2008-09-14 Tor Lillqvist <tml@novell.com>
1827 * tests/scanner/Makefile.am (%.typelib): Use $(EXEEXT).
1829 2008-09-14 Colin Walters <walters@verbum.org>
1831 * giscanner/glibtransformer.py: Ignore functions with
1834 2008-09-12 Colin Walters <walters@verbum.org>
1836 * giscanner/glibtransformer.py: Accept Gtk.Type as GType.
1838 2008-09-12 Colin Walters <walters@verbum.org>
1840 * giscanner/ast.py: Bind pid_t to INT for vte.
1842 2008-09-12 Colin Walters <walters@verbum.org>
1844 * giscanner/girparser.py: Parse c:type for boxed records/unions.
1845 * giscanner/glibast.py: Avoid overwriting ctype.
1846 * giscsanner/transformer.py: Try resolving types using the GType names.
1848 2008-09-12 Colin Walters <walters@verbum.org>
1850 * giscanner/minixpath.py: Code to run an "XPath"
1851 assertion against an XML tree, taken from
1852 gir-repository/gir/tests.py.
1853 * giscanner/Makefile.am: Ship it.
1854 * tools/g-ir-scanner: Add --xpath-assertions option.
1855 * gir/GLib-assertions.txt: Add a few assertions.
1856 * gir/Makefile.am: Run them.
1858 2008-09-11 Colin Walters <walters@verbum.org>
1860 http://bugzilla.gnome.org/show_bug.cgi?id=551737
1862 * giscanner/transformer.py: Fix strip_namespace_func to only strip
1863 prefix if it ends with _. Tweak callback stripping to determine
1864 based on presence of _ whether we need to use strip_namespace_func
1865 or strip_namespace_object.
1867 2008-09-09 Owen Taylor <otaylor@redhat.com>
1869 * docs/typelib-format.txt: Wether => Whether
1871 2008-09-08 Colin Walters <walters@verbum.org>
1873 * girepository/girparser.c: Default to "readable" for properties.
1874 * giscanner/ast.py: Add readable, writable etc.
1875 * giscanner/girwriter.py: Writ them.
1876 * giscanner/glibtransformer.py: Inspect them.
1879 2008-09-07 Colin Walters <walters@verbum.org>
1881 * giscanner/cgobject.py: Add comment.
1883 2008-09-07 Colin Walters <walters@verbum.org>
1885 * giscanner/cgobject.py: Also call g_thread_init.
1887 2008-09-07 Colin Walters <walters@verbum.org>
1889 * giscanner/transformer.py: Fix regression by not
1890 stripping prefix before stripping namespace for unions
1893 2008-09-06 Colin Walters <walters@verbum.org>
1895 * giscanner/transformer.py: If a namespace contains
1896 multiple caps, try stripping both gnomekeyring_ and
1899 2008-09-07 Johan Dahlin <johan@gnome.org>
1901 Bug 551162 – giscanner does not recognize asm and __asm__
1902 * giscanner/scannerlexer.l:
1903 Patch by Jani Monoses.
1905 2008-09-06 Colin Walters <walters@verbum.org>
1907 * girepository/girnode.c: Allow gtype_name
1908 and gtype_init in struct and union.
1909 * girepository/girparser.c: Parse glib:
1910 boxed bits for both structure and union.
1911 * girepository/gtypelib.c: Don't barf
1912 if structure is boxed.
1913 * giscanner/girparser.py: Parse new XML
1915 * giscanner/girwriter.py: Write out new
1917 * giscanner/glibast.py: Define new classes
1918 which are both Boxed and Struct/Union, as
1919 well as an "Other" for everything else.
1920 * giscanner/glibtransformer.py: Handle
1921 boxed types specially; we try to merge
1922 them with a struct/union if one exists,
1923 otherwise fall back to generic boxed.
1925 * tools/generate.c: Write out new format.
1927 2008-09-06 Johan Dahlin <johan@gnome.org>
1929 * giscanner/grealpath.h: Include stdlib.h
1931 * docs/g-ir-generate.1: Remove leading %
1933 2008-09-01 Colin Walters <walters@verbum.org>
1935 * girepository/girparser.c: Look at c:type to determine
1936 whether or not an item is a pointer.
1938 2008-09-01 Johan Dahlin <johan@gnome.org>
1940 * tests/scanner/Makefile.am:
1941 Set PYTHONPATH so the scanner can run
1942 even if you didn't install anything.
1944 2008-09-01 Johan Dahlin <johan@gnome.org>
1947 Post-release version bump
1950 2008-09-01 Johan Dahlin <johan@gnome.org>
1954 2008-08-31 Colin Walters <walters@verbum.org>
1956 * giscanner/glibtransformer.py: Quiet info
1959 2008-08-31 Johan Dahlin <johan@gnome.org>
1962 Bump version to 0.5.0
1964 2008-08-31 Colin Walters <walters@verbum.org>
1966 * giscanner/glibtransformer.py: Follow aliases to ensure
1967 we don't get a constructor returning a basic type.
1968 * giscanner/transformer.py: Add function to follow aliases.
1971 2008-08-31 Johan Dahlin <johan@gnome.org>
1973 * giscanner/scannerlexer.l:
1974 * giscanner/scannerparser.y:
1975 * giscanner/sourcescanner.h:
1976 * giscanner/sourcescanner.py:
1977 Parse GCC extensions in the parser instead of just undeffing them
1978 in the pre-processor.
1980 2008-08-31 Johan Dahlin <johan@gnome.org>
1982 * giscanner/glibtransformer.py:
1983 Clean up a huge if. Do not add methods or constructors
1985 * giscanner/utils.py:
1986 second might be longer than first, check that.
1988 2008-08-31 Johan Dahlin <johan@gnome.org>
1993 2008-08-31 Colin Walters <walters@verbum.org>
1995 * girepository/girparser.c: Don't lose if we
1998 2008-08-31 Colin Walters <walters@verbum.org>
2000 * giscanner/glibtransformer.py: Look for libtool
2001 library in current directory
2002 * tests/scanner - Update.
2004 2008-08-30 Colin Walters <walters@verbum.org>
2006 * docs/typelib-format.txt: Add a guint32
2008 * gir/Makefile.am: Dep on Makefile
2009 * girepository/ginfo.c:
2010 * girepository/girepository.c: Clean up
2011 default typelib handling; remove global
2012 default_typelib variable. Ensure we handle
2013 NULL repository in more places.
2014 Support dependency resolution.
2015 Support lazy loading.
2016 * girepository/girepository.h: Remove
2017 g_irepository_unregister; we don't support
2018 unloading typelibs since really they're
2019 process-global. Update for lazy loading
2021 * girepository/girmodule.c: Use g_new0.
2022 Add dependencies to GirModule.
2023 * girepository/girparser.c: Parse dependencies.
2024 * girepository/gtypelib.c: Add 4 bytes for
2026 * tests/Makefile.am: Kill off gobject.gir,
2027 it conflicts with the real one.
2028 * tests/object.gir: Dep on GObject.
2029 * tools/generate.c: Take --includedir
2030 argument to say which directories to search
2031 for typelibs. Print out dependencies.
2033 2008-08-30 Colin Walters <walters@verbum.org>
2035 * giscanner/glibtransformer.py: Reduce warning noise.
2037 2008-08-29 Colin Walters <walters@verbum.org>
2039 * girepository/ginfo.c: Add some assertions regarding
2040 refcounts, just to be sure.
2041 * giscanner/glibtransformer.py: Blacklist a few more
2044 2008-08-29 Colin Walters <walters@verbum.org>
2046 * giscanner/glibtransformer.py: Blacklist a few
2047 functions that use GError oddly
2049 2008-08-29 Colin Walters <walters@verbum.org>
2051 * girepository/gtypelib.c: Don't crash if no
2054 2008-08-29 Colin Walters <walters@verbum.org>
2056 * girepository/girparser.c: Handle chains of aliases
2057 across modules by ensuring we fully qualify aliases
2060 2008-08-29 Colin Walters <walters@verbum.org>
2062 * girepository/girparser.c: Don't search aliases
2065 2008-08-29 Colin Walters <walters@verbum.org>
2067 * girepository/girparser.c: Rewrite type parsing
2068 to handle both GLib parsing case as well as correctly
2069 handling GLib.List and friends. Don't try to treat
2070 e.g. ListStore as a List.
2072 2008-08-29 Colin Walters <walters@verbum.org>
2074 * girepository/gtypelib.c: Add more context
2077 2008-08-29 Colin Walters <walters@verbum.org>
2079 * giscanner/glibtransformer.py: Add some informative
2080 logging messages in corner cases. Be sure we use
2081 the most recent node set instead of a cache
2082 when generating result set.
2083 * tests/: Remove duplicated bits in expected girs
2084 * girepository/girparser.c: Accept both List (for
2085 compiling GLib) and GLib.List (what the scanner
2088 * tools/generate.c: Generate canonical form.
2090 2008-08-29 Johan Dahlin <johan@gnome.org>
2092 * giscanner/config.py.in:
2093 Use datarootdir instead of datadir to avoid
2094 an autoconf warning.
2096 2008-08-29 Johan Dahlin <johan@gnome.org>
2100 * examples/gdk-pixbuf.gidl:
2102 Update and remove old cruft.
2104 2008-08-29 Johan Dahlin <johan@gnome.org>
2107 * docs/g-ir-compiler.1:
2108 * docs/g-ir-generate.1:
2109 * docs/g-ir-scanner.1:
2110 Add man pages for the generator and compiler.
2112 2008-08-29 Johan Dahlin <johan@gnome.org>
2114 * docs/g-ir-scanner.1: Document
2116 * giscanner/Makefile.am:
2117 * giscanner/gidlparser.py:
2118 * giscanner/gidlwriter.py:
2119 * tools/g-ir-scanner:
2120 Remove gidl support.
2122 2008-08-28 Colin Walters <walters@verbum.org>
2124 * tests/scanner/Makefile.am: Pass the right
2125 --includedir args. Add a Makefile dep.
2126 * tools/compiler.c: Pass includedirs down.
2127 * girepository/girparser.c: Actually put
2128 includedirs in context, pass down. Fix
2131 2008-08-28 Colin Walters <walters@verbum.org>
2133 * gir/Makefile.am: Use --includedir
2134 * girepository/girparser.c: Recursively parse
2135 includes to pull in aliases and expand them.
2136 We need this to avoid putting unknown names in
2138 * tools/compiler.c: Add --includedir option.
2139 * giscanner/ast.py: Map size/ssize to types
2142 2008-08-28 Tor Lillqvist <tml@novell.com>
2144 Make check now runs successfully on Windows.
2146 * tools/compiler.c (write_out_typelib): Use binary mode for output
2149 * girepository/girnode.c: Don't print NULL strings.
2151 * tests/invoke/Makefile.am
2152 * tests/scanner/Makefile.am: Use -no-undefined on Windows to
2153 convince libtool to build shared libraries.
2155 * tests/invoke/invoke.c: Don't needlessly include <dlfcn.h>. Use
2156 g_assert() instead of printing out expected errors.
2158 2008-08-28 Tor Lillqvist <tml@novell.com>
2160 * girepository/gtypelib.h: Change type of bitfield fields from
2161 guint to the most suitable smaller type. This makes the struct
2162 sizes match the ones on Linux that the sanity check expects when
2163 using gcc -mms-bitfields on Windows.
2165 2008-08-28 Johan Dahlin <johan@gnome.org>
2170 * giscanner/Makefile.am:
2171 * tests/Makefile.am:
2172 * tests/scanner/Makefile.am:
2173 Make distcheck pass.
2175 2008-08-27 Johan Dahlin <johan@gnome.org>
2177 * giscanner/Makefile.am:
2178 Only send in -no-undefined on Win32 as it breaks on MacOS X.
2180 2008-08-27 Tor Lillqvist <tml@novell.com>
2182 Make g-ir-scanner work on Windows. Still problems with the typelib
2183 code. Changes okayed by jdahlin.
2185 * configure.ac: Check for Windows, set Automake conditional
2186 OS_WIN32. Change backslashes to forward slashes in pyexecdir to
2187 avoid shell quoting issues
2189 * girepository/Makefile.am: Use -no-undefined so that libtool
2190 agrees to build a shared library on Windows.
2192 * girepository/girparser.c (backtrace_stderr): No backtrace() on
2193 Windows. Empty implementation on Windows so far.
2195 * girepository/gtypelib.c (g_typelib_check_sanity): Give more
2196 informative error message for the assertion failures. Tell also
2197 what the expected size of the struct is. Check all sizes first and
2198 fail afterwards if at least one size was different from expected.
2200 * tools/Makefile.am: Reorder libraries into proper logical
2203 * tools/generate.c: Don't include <dlfcn.h>, not used.
2205 * giscanner/Makefile.am: On Windows, link with the Python library,
2206 and install the module DLL as _giscanner.pyd. Remove the
2207 unnecessary import library and libtool library that libtool has
2210 * giscanner/scannerlexer.l: Recognize the gcc __attribute__ syntax
2211 and just skip it. Recognize also two "l" suffixes for long long
2212 constants. Recognize also __inline__.
2214 * giscanner/grealpath.h (g_realpath): Implement on Windows, using
2215 GetFullPathName(). As such, GetFullPathName() does more than the
2216 UNIX realpath(). It also changes relative paths into absolute
2217 paths. But for our purposes that shouldn't matter.
2219 * giscanner/giscannermodule.c (pygi_source_scanner_parse_file): On
2220 Windows the file descriptor passed to us is from Python. Python
2221 Python2.5 uses the msvcr71.dll C library, while mingw-built code
2222 uses msvcrt.dll. On Windows, file descriptors are specific to
2223 which C library is used. So we must find out what underlying OS
2224 handle corresponds to the file descriptor Python passes us, and
2225 then make that into a file descriptor valid for the C library this
2228 * giscanner/sourcescanner.py (_parse): Don't need to bypass
2229 __attribute__ as the lexer now handles it. The definition as empty
2230 was ineffective for mingw anyway, as mingw's _mingw.h undefines
2231 __attribute__. Close the temp file before unlinking it.
2233 * giscanner/cgobject.py: Use correct library name for the gobject
2236 * gir/Makefile.am: Must pass the full basename of the DLLs on
2237 Windows to g-ir-scanner. It's a bit ugly that we have to "know"
2238 that the names of the GLib DLLs are like libglib-2.0-0.dll, but in
2239 reality they won't change, until there is a GLib 3, and then also
2240 the Unix code here needs changing.
2242 Must pass CPPFLAGS to g-ir-scanner when building GLib.gir so that
2245 2008-08-26 Colin Walters <walters@verbum.org>
2247 * girepository/girepository.c: Search
2248 $DATADIR/girepository instead of
2249 $DATADIR/gitypelibs; this naming makes
2250 it clearer that e.g. jgir can install
2252 * gir/Makefile.am: Install there.
2254 2008-08-26 Colin Walters <walters@verbum.org>
2256 * girepository/gtypelib.c (_g_typelib_init): Also
2257 use G_MODULE_SUFFIX instead of hardcoding .so.
2259 2008-08-26 Colin Walters <walters@verbum.org>
2261 * girepository/gtypelib.c (_g_typelib_init): Free
2262 string in the right place.
2264 2008-08-26 Colin Walters <walters@verbum.org>
2266 * girepository/gtypelib.c (_g_typelib_init): Handle
2267 both .la and .so names; this works better in the
2268 uninstalled library case.
2270 2008-08-26 Johan Dahlin <johan@gnome.org>
2273 * giscanner/Makefile.am:
2274 * giscanner/cgobject.py:
2275 * giscanner/config.py.in:
2276 * giscanner/sourcescanner.py:
2277 Avoid undeffing __GNUC__, instead define
2278 __attribute__ & friends. Remove glibconfig.h hack.
2279 This makes gobject-introspection work better on
2280 MacOS X, Thanks to Richard Hult for kind help.
2282 2008-08-25 Colin Walters <walters@verbum.org>
2284 * giscanner/glibtransformer.py: Always print
2287 2008-08-25 Colin Walters <walters@verbum.org>
2289 * giscanner/glibtransformer.py: Skip over
2290 interfaces we don't know.
2292 2008-08-25 Colin Walters <walters@verbum.org>
2294 * girepository/girparser.c: Parse new implements
2295 syntax, drop gapi one.
2296 * tests/object.gir: Update.
2297 * tools/generate.c: Generate new syntax.
2299 2008-08-25 Colin Walters <walters@verbum.org>
2301 * giscanner/ast.py: Add interfaces property
2303 * giscanner/girwriter.py: Write out implemented
2305 * giscanner/glibtransformer.py: Introspect
2306 implemented interfaces.
2307 * tests/scanner/*: Make FooObject implement
2310 2008-08-25 Colin Walters <walters@verbum.org>
2312 * giscanner/glibtransformer.py: More correctly pair
2313 methods; if we have a symbol that starts with
2314 e.g. hippo_canvas look for a matching HippoCanvas
2315 class before accepting e.g. HippoCanvasImage.
2317 2008-08-24 Colin Walters <walters@verbum.org>
2319 * tools/g-ir-scanner: Filter out unknown options from
2322 2008-08-24 Colin Walters <walters@verbum.org>
2324 * giscanner/glibtransformer.py: Fail with better
2325 error if we can't find library.
2327 2008-08-24 Colin Walters <walters@verbum.org>
2329 * tools/g-ir-scanner: Use subprocess instead of
2330 commands, works on Windows and avoids the evil
2333 2008-08-24 Colin Walters <walters@verbum.org>
2335 * giscanner/glibtransformer.py: Skip over
2336 g_object_get_type from GLib trunk.
2338 2008-08-24 Colin Walters <walters@verbum.org>
2340 * girepository/girepository.c (g_irepository_require):
2341 Don't open shared library here; we already do it
2344 2008-08-24 Colin Walters <walters@verbum.org>
2346 * girepository/gtypelib.c: Add context stack so
2347 when we get an error we can print out nicely
2350 2008-08-24 Johan Dahlin <johan@gnome.org>
2352 * girepository/girparser.c (start_glib_boxed), (start_function),
2353 (start_field), (start_alias):
2354 Refactor a couple of parsing functions to be simpler to follow.
2357 2008-08-24 Johan Dahlin <johan@gnome.org>
2359 * girepository/girparser.c (start_function):
2360 Remove left-over code, checking type of function.
2362 2008-08-23 Colin Walters <walters@verbum.org>
2364 * giscanner/config.py: Define DATADIR.
2365 * giscanner/transformer.py: Look in DATADIR.
2367 2008-08-23 Colin Walters <walters@verbum.org>
2369 * girepository/gtypelib.c: Check constructor
2371 * girepository/girnode.c: Small tweaks.
2372 * girepository/ginfo.c: Calculate signature offsets
2374 * girepository/girparser.c: Remove duplicate
2376 * giscanner/glibtransformer.py: Avoid marking
2377 functions which return a basic type as
2380 2008-08-23 Colin Walters <walters@verbum.org>
2382 * girepository/girparser.c: Ignore <include>.
2383 * giscanner/girparser.py: Parse them.
2384 * giscanner/girwriter.py: Generate them.
2385 * giscanner/transformer.py: Process <include>
2386 recursively. Don't require full path for
2387 includes, look in {$XDG_DATA_DIRS}/gir.
2388 * tools/g-ir-scanner: Pass through includes.
2389 * Makefile.am: Remove extra --include
2391 * *-expected.gir: Add expected includes.
2393 2008-08-23 Johan Dahlin <johan@gnome.org>
2395 * tests/scanner/Makefile.am:
2396 * tests/scanner/annotation-expected.gir:
2397 * tests/scanner/drawable-expected.gir:
2398 Avoid duplication in the Makefile, regenerate with new
2399 namespaces (same as the filename)
2401 2008-08-22 Colin Walters <walters@verbum.org>
2403 * girepository/girnode.c: Don't hardcode integers,
2406 2008-08-22 Johan Dahlin <johan@gnome.org>
2408 * giscanner/sourcescanner.py:
2409 Check for ../gobject-introspection-1.0.pc.in to determine
2410 if we run installed or uninstalled.
2412 2008-08-22 Johan Dahlin <johan@gnome.org>
2415 * giscanner/sourcescanner.py:
2416 Send in undefs/defines via writing it directly to stdin
2417 of cpp instead of via arguments.
2419 2008-08-22 Colin Walters <walters@verbum.org>
2421 * tools/generate.c, tools/compiler.c: Default
2423 * all Makefile.am: Update.
2425 2008-08-22 Colin Walters <walters@verbum.org>
2427 * girepository/girparser.c: Pass through
2428 recursive types. Avoid overwriting errors.
2429 * giscanner/xmlwriter.py: Always write the
2431 * tests/*.gir: Adjust.
2432 * tests/scanner/Makefile.am: Build typelibs,
2433 and generate XML from those. Once we
2434 have a good diff mechanism...
2435 * tests/scanner/*-expected.gir: Add XML
2437 * tools/g-ir-scanner: Accept --typelib-xml
2439 * tools/generate.c: Better defaults for transfer.
2441 2008-08-22 Johan Dahlin <johan@gnome.org>
2445 * giscanner/Makefile.am:
2446 * giscanner/config.py.in:
2447 * giscanner/sourcescanner.py:
2448 Use the generated glibconfig.h for all scanner invokations.
2449 Rename it to glibconfig-scanner.h and install it.
2450 Add a config.py which so far contains the include dir.
2452 2008-08-22 Johan Dahlin <johan@gnome.org>
2455 Replace glibconfig.h with our own, do some replacement
2456 for CPP/C features we do not support
2458 2008-08-22 Colin Walters <walters@verbum.org>
2460 * tools/generate.c (write_callable_info): Fix unref
2463 2008-08-22 Colin Walters <walters@verbum.org>
2465 * gobject-introspection-1.0.pc.in: Add g-ir-generate.
2466 * tests/Makefile.am: Support $(DEBUG)
2467 * tools/generate.c: Do immediate close tags if no
2470 2008-08-21 Colin Walters <walters@verbum.org>
2472 * tests/scanner/drawable-expected.gir,
2473 * tests/scanner/drawable.c,
2474 * tests/scanner/drawable.h:
2477 2008-08-21 Colin Walters <walters@verbum.org>
2479 * giscanner/glibtransformer.py: Compute prefix
2480 by searching through the symbol for bits
2481 rather than going directly from ctype; this fixes
2484 2008-08-21 Colin Walters <walters@verbum.org>
2486 * giscanner/glibtransformer.py: Also try squashing
2487 underscores from namespace, fixes webkit_web_view_new.
2489 2008-08-21 Colin Walters <walters@verbum.org>
2491 * giscanner/glibtransformer.py: More ctor work,
2492 avoid having gtk_window_group_new end up under
2495 2008-08-21 Colin Walters <walters@verbum.org>
2497 * giscanner/glibtransformer.py: Much simpler approach
2498 of mapping uscored names to classes.
2499 * giscanner/utils.py: Remove unnecessary function.
2501 2008-08-21 Johan Dahlin <johan@gnome.org>
2503 * girepository/girepository.c (g_irepository_require):
2504 Plug memory leak and avoid using freed memory.
2505 Resolve the whole module path, here as well.
2507 2008-08-21 Colin Walters <walters@verbum.org>
2509 * giscanner/glibtransformer.py: Look up all permutations
2510 of class names when scanning methods/ctors based on
2511 the prefix instead of using the return value. This
2512 associates gtk_window_new with the right class.
2514 2008-08-21 Colin Walters <walters@verbum.org>
2516 * girepository/girmodule.c (g_ir_module_build_typelib):
2517 Revert change to increment header_size; we do that in
2520 2008-08-21 Colin Walters <walters@verbum.org>
2522 * girepository/girnode.c (write_string): Tweak to
2523 use UINT instead of INT. Not likely to matter.
2524 * girepository/girmodule.c (g_ir_module_build_typelib):
2525 Add to header_offset as well for header strings
2526 to match what write_string does.
2527 * girepository/gtypelib.c: Replace is_name with
2528 validate_name, which more strongly validates and
2529 handles errors in a better way. Update all callers.
2530 * giscanner/glibtransformer.py: Handle constructors
2533 2008-08-21 Johan Dahlin <johan@gnome.org>
2535 * gir/Makefile.am (typelibs_DATA): Build and
2536 install the Gio.typelib too
2538 * girepository/gtypelib.c (_g_typelib_init):
2539 Use g_module_build_path to resolve the shlib name
2541 2008-08-21 Colin Walters <walters@verbum.org>
2543 * gir/Makefile.am: CLEANFILES typelibs too.
2545 2008-08-21 Johan Dahlin <johan@gnome.org>
2547 * giscanner/glibtransformer.py:
2548 Do not send .la files through find_library.
2550 2008-08-21 Colin Walters <walters@verbum.org>
2552 * girepository/girparser.c (g_irepository_require):
2553 Fix one small leak in error case.
2555 2008-08-21 Johan Dahlin <johan@gnome.org>
2558 Parse glibconfig.h as well and install the compiled
2561 2008-08-21 Johan Dahlin <johan@gnome.org>
2564 * giscanner/glibtransformer.py:
2565 * tools/g-ir-scanner:
2566 Do not hard-core library names in the Makefile, reuse
2567 ctypes find_library instead.
2569 2008-08-21 Johan Dahlin <johan@gnome.org>
2571 * girepository/girparser.c (resolve_aliases):
2572 Remove compilation warnings
2574 2008-08-21 Johan Dahlin <johan@gnome.org>
2576 * girepository/girepository.c (g_irepository_require):
2577 Rewrap and fix double free bug by leaking a bit.
2579 2008-08-20 Colin Walters <walters@verbum.org>
2581 * girepository/girepository.c: Add new function
2582 g_irepository_get_typelib_path which tells
2583 us from where we loaded a namespace.
2585 2008-08-20 Colin Walters <walters@verbum.org>
2587 * tests/scanner/*-expected.gir: Adjust for
2588 added shared-library.
2589 * giscanner/giwriter.py: Make pylint happy.
2591 2008-08-20 Colin Walters <walters@verbum.org>
2593 * girepository/girmodule.c (g_ir_module_build_typelib):
2594 Calculate size correctly, avoid use-after-free.
2596 2008-08-20 Colin Walters <walters@verbum.org>
2598 * girepository/girepository.c: Remove
2599 g_irepository_register_file in favor of
2600 g_irepository_require. There are two
2601 possible deployment scenarios for typelibs:
2602 First, separate in $DATADIR/gitypelibs/. Second,
2603 they may be embedded in shlibs. However since
2604 the first is now the normal case, the API is
2605 optimized around it.
2607 Refactor internals to look up typelibs for
2608 namespaces just-in-time, but we expect
2609 consumers to call g_irepository_require.
2611 Also, add some docs. No one has died from that
2613 * gir/Makefile.am: Need --library for glib.
2614 * giscanner/girwriter.py: Write out shared-library.
2615 * tools/g-ir-writer: Take the first --library
2616 argument as the target of shared-library. In
2617 the future we should make this nicer with pkg-config
2620 2008-08-20 Colin Walters <walters@verbum.org>
2622 * girepository/girparser.py: And parse them.
2624 2008-08-20 Johan Dahlin <johan@gnome.org>
2626 * giscanner/glibast.py: Add gshort/gushort types
2628 2008-08-20 Colin Walters <walters@verbum.org>
2630 * gir/Makefile.am: Rename .gir files using GI namespace.
2631 * girepository/girepository.c: Use XDG_DATA_DIRS for
2632 looking up typelibs. Also typelibs are now suffixed
2634 * tests/invoke/Makefile.am: Only use metadata.
2635 * girepository/Makefile.am: Remove unnecessary include.
2636 * tests/scanner/Makefile.am: Update using GI namespaces
2637 for scanner includes.
2639 2008-08-20 Colin Walters <walters@verbum.org>
2641 * girepository/transformer.py: Suppress aliases whose
2643 * girepository/ast.py: Define some more aliases.
2645 2008-08-20 Colin Walters <walters@verbum.org>
2647 * girepository/girparser.c: Avoid alias infloops.
2649 2008-08-20 Colin Walters <walters@verbum.org>
2651 * tests/scanner/foo-expected.gir: Fix expected list type.
2653 2008-08-20 Johan Dahlin <johan@gnome.org>
2655 * giscanner/glibtransformer.py (GLibTransformer._resolve_type_name):
2656 Add a workaround for #548689.
2657 We can now compile gtk!
2659 2008-08-20 Colin Walters <walters@verbum.org>
2661 * giscanner/glibtransformer.py: Try to look up
2662 aliases using the c:type too.
2664 2008-08-20 Colin Walters <walters@verbum.org>
2666 * girepository/girparser.c: Parse union fields.
2668 2008-08-20 Johan Dahlin <johan@gnome.org>
2670 * giscanner/ast.py: Make time_t an alias for long
2672 * gir/gio-2.0-good.gir:
2673 * gir/glib-2.0-good.gir:
2674 * gir/gobject-2.0-good.gir:
2676 * giscanner/glibtransformer.py:
2677 Do not delete Class structures, we need them in gdk/gtk.
2678 * tests/scanner/drawable-expected.gir:
2679 * tests/scanner/foo-expected.gir:
2680 * tests/scanner/utility-expected.gir:
2683 2008-08-20 Johan Dahlin <johan@gnome.org>
2685 * tests/scanner/Makefile.am:
2686 * tests/scanner/annotation-expected.gir:
2687 * tests/scanner/annotation.c (annotation_object_class_init),
2688 (annotation_object_init), (annotation_object_method),
2689 (annotation_object_in), (annotation_object_out),
2690 (annotation_object_inout), (annotation_object_inout2),
2691 (annotation_object_inout3), (annotation_object_calleeowns),
2692 (annotation_object_calleesowns), (annotation_object_get_strings),
2693 (annotation_object_with_voidp), (annotation_object_get_objects),
2694 (annotation_object_create_object), (annotation_object_allow_none):
2695 * tests/scanner/annotation.h:
2696 * tests/scanner/foo-expected.gir:
2697 * tests/scanner/foo.c:
2698 * tests/scanner/foo.h:
2699 Split out annotation tests out of foo
2701 2008-08-20 Johan Dahlin <johan@gnome.org>
2703 * tests/scanner/Foo-expected.gir:
2704 * tests/scanner/Makefile.am:
2705 * tests/scanner/foo-expected.gir:
2706 * tests/scanner/foo-object.h:
2707 * tests/scanner/foo.c:
2708 Foo->foo, foo-object.h -> foo.h
2710 2008-08-20 Johan Dahlin <johan@gnome.org>
2712 * tests/scanner/Foo-expected.gir:
2713 * tests/scanner/Makefile.am:
2714 * tests/scanner/drawable-expected.gir:
2715 * tests/scanner/drawable.c (test_drawable_class_init),
2716 (test_drawable_init):
2717 * tests/scanner/drawable.h:
2718 * tests/scanner/foo-object.h:
2719 * tests/scanner/foo.c (foo_boxed_method):
2720 Move the drawable parts out of Foo to its own test.
2722 2008-08-20 Johan Dahlin <johan@gnome.org>
2724 * tests/scanner/Foo-expected.gir:
2725 * tests/scanner/foo-object.h:
2726 * tests/scanner/foo.c (foo_drawable_class_init),
2727 (foo_drawable_init):
2728 Add a based on GdkDrawable which generates
2731 2008-08-19 Colin Walters <walters@verbum.org>
2733 * giscanner/transformer.py: Don't try
2734 to strip prefix before namespace.
2736 2008-08-19 Johan Dahlin <johan@gnome.org>
2738 * giscanner/transformer.py:
2739 * tests/scanner/Foo-expected.gir:
2740 * tests/scanner/foo-object.h:
2741 Add support for typedef void foo type of
2744 2008-08-19 Johan Dahlin <johan@gnome.org>
2747 * giscanner/girwriter.py:
2748 * giscanner/glibtransformer.py:
2749 * giscanner/transformer.py:
2750 * tests/scanner/Foo-expected.gir:
2751 Add basic support for union, base the code much
2752 on Struct. Add a testcase.
2754 2008-08-19 Johan Dahlin <johan@gnome.org>
2756 * tests/scanner/Foo-expected.gir:
2757 * tests/scanner/foo-object.h:
2758 Add a union testcase which the compiler currently
2761 2008-08-19 Johan Dahlin <johan@gnome.org>
2763 * gobject-introspection-1.0.pc.in:
2764 Add a g_ir_compiler variable
2766 2008-08-19 Colin Walters <walters@verbum.org>
2768 * giscanner/ast.py: Rework types to be more closely
2770 * giscanner/girparser.py: Parse more bits.
2771 * giscanner/girwriter.py: Write sequences in a new
2772 way that specifies container type.
2773 * giscanner/glibast.py: Adjust for ast.py changes,
2774 add 'ctype' property to GLibObject and GLibInterface
2775 so we can look things up by it later.
2776 * gicanner/transformer.py: Names is new class holding
2777 the various namespaces we manage. Do not confuse
2778 with Namespace which is toplevel XML node effectively.
2779 Rework all type resolution to go through
2780 _resolve_type_name_1.
2781 * giscanner/glibtransformer.py: Raise UnknownTypeError
2782 instead of ValueError for cleanliness. Add Unresolved
2783 class to mark types whose parent we haven't seen yet.
2784 Use new Names object from transformer.py.
2785 Correctly look up parent=.
2786 Fix type validation to handle sequences.
2787 * tests/scanner/Foo-expected.gir: Update for sequence
2788 work, int instead of int32.
2789 * tools/g-ir-scanner: Add --noclosure option
2790 * gir/Makefile.am: Use --noclosure by default for
2793 2008-08-18 Johan Dahlin <johan@gnome.org>
2795 * gir/gio-2.0-good.gir:
2796 * gir/glib-2.0-good.gir:
2797 * gir/gobject-2.0-good.gir:
2800 2008-08-18 Johan Dahlin <johan@gnome.org>
2803 * giscanner/girparser.py:
2804 * giscanner/girwriter.py:
2805 * giscanner/glibast.py:
2806 * giscanner/glibtransformer.py:
2807 * giscanner/transformer.py:
2808 * tests/scanner/Foo-expected.gir:
2809 * tests/scanner/foo-object.h:
2810 * tests/scanner/utility-expected.gir:
2811 * tests/scanner/utility.h:
2812 Redo type resolving and validation.
2813 Add a couple of new tests.
2814 Patch mostly written by Colin.
2816 2008-08-18 Johan Dahlin <johan@gnome.org>
2819 * giscanner/girparser.py:
2821 * giscanner/transformer.py:
2822 Improve enum parsing for enums without a GType.
2823 Make flags/enum references to other girs work
2824 * giscanner/utils.py:
2826 * tests/scanner/Makefile.am:
2827 * tests/scanner/foo-object.h:
2828 * tests/scanner/utility-expected.gir:
2829 * tests/scanner/utility.h:
2830 Add a new test for external enum references
2832 2008-08-18 Johan Dahlin <johan@gnome.org>
2834 * docs/global-module-registry.txt: Update
2836 * tests/array.gir: Update with new type proposal
2838 * girepository/girepository.c (g_type_tag_to_string):
2839 * girepository/girepository.h:
2840 * girepository/girnode.c (g_ir_node_get_full_size_internal),
2842 * girepository/girnode.h:
2843 Make enum serializing functions public. Clean up some whitespace.
2845 2008-08-17 Johan Dahlin <johan@gnome.org>
2847 * docs/global-module-registry.txt:
2848 Add a document for an on disk module registry format
2850 2008-08-17 Johan Dahlin <johan@gnome.org>
2853 * gir/gio-2.0-good.gir:
2856 2008-08-17 Johan Dahlin <johan@gnome.org>
2859 * gir/glib-2.0-good.gir:
2860 * gir/gobject-2.0-good.gir:
2861 * giscanner/cgobject.py:
2862 * giscanner/glibtransformer.py:
2863 Regenerate GObject & GType.
2864 Avoid warnings when generating gobject-2.0.gir.
2865 Introspect a little more, and skip *_get_type functions.
2867 2008-08-17 Colin Walters <walters@verbum.org>
2869 * gir/glib-2.0.gir, gir/gobject-2.0.gir:
2870 Rename to -good, always generate during build.
2871 * gir/Makefile.am: Ensure .gir files dep on
2872 all scanner sources.
2873 * Makefile.am: Switch build order to ensure
2874 the scanner is ready before we do gir/.
2875 * tools/g-ir-scanner: Look for .git too.
2877 2008-08-17 Johan Dahlin <johan@gnome.org>
2879 * girepository/gtypelib.c (validate_enum_blob):
2880 * giscanner/glibtransformer.py:
2881 * giscanner/transformer.py:
2882 Remove resolve_possible_typedefs, it was unused.
2883 Allow multiple enum values of the sample value in an enum,
2884 since it's actually pretty common.
2885 Register enums so they can be resolved too.
2887 2008-08-16 Johan Dahlin <johan@gnome.org>
2889 * giscanner/girparser.py:
2890 Parse enumeration/bitfield.
2892 2008-08-16 Johan Dahlin <johan@gnome.org>
2894 * giscanner/girparser.py:
2897 2008-08-16 Johan Dahlin <johan@gnome.org>
2899 * giscanner/glibtransformer.py:
2900 Resolve type names for alias targets
2901 * giscanner/transformer.py:
2902 Skip FILE* parameters fow now
2904 2008-08-16 Johan Dahlin <johan@gnome.org>
2907 * gir/gobject-2.0.gir:
2910 * tests/scanner/Makefile.am:
2913 2008-08-15 Colin Walters <walters@verbum.org>
2915 * giscanner/glibtransformer.py: Explicitly construct
2916 new list, since we're deleting as we iterate.
2917 Don't delete all structures which end in Class; just
2918 ones which have a paired GObject.
2919 Fix printing of type warning.
2920 * giscanner/transformer.py: Make strip_namespace_object
2921 be the identity function if it doesn't match the
2924 2008-08-15 Colin Walters <walters@verbum.org>
2926 * giscanner/cgobject.py: Define yet more argument
2927 prototypes; fix prototype for g_type_fundamental.
2929 2008-08-14 Johan Dahlin <johan@gnome.org>
2931 * tests/Makefile.am:
2932 * tests/constant.gir:
2933 * tests/gobject.gir:
2935 * tools/generate.c (write_struct_info):
2936 Fix generator for constant/gobject/struct
2938 2008-08-14 Johan Dahlin <johan@gnome.org>
2940 * tests/Makefile.am:
2942 * tools/generate.c (write_enum_info):
2943 Fix generation of enum/bitfields
2945 2008-08-14 Johan Dahlin <johan@gnome.org>
2947 * girepository/girparser.c (start_field), (start_constant),
2948 (start_type), (end_element_handler):
2949 Clear up constant parsing
2954 * tools/generate.c (write_callable_info), (write_function_info),
2955 (write_callback_info), (write_constant_info), (write_signal_info),
2956 (write_vfunc_info), (write_property_info), (write_object_info),
2957 (write_interface_info):
2958 Constants/Signals are handled now.
2960 2008-08-14 Johan Dahlin <johan@gnome.org>
2962 * girepository/girparser.c (start_type):
2963 Don't require c:type.
2964 * tests/Makefile.am:
2967 Update, remove parts we don't support yet
2968 * tests/roundtrips.sh:
2970 * tools/generate.c (write_type_info), (write_field_info),
2971 (write_callable_info), (write_struct_info):
2972 Make it emit proper gir.
2974 2008-08-14 Johan Dahlin <johan@gnome.org>
2976 * giscanner/transformer.py:
2977 New internal function for adding a new node.
2979 2008-08-14 Johan Dahlin <johan@gnome.org>
2982 Define an internal _H_ variable so we skip parsing both
2983 i18n headers, only one is needed.
2985 Add the glib-2.0.gir too.
2986 * giscanner/glibast.py:
2987 Add gconstpointer as an alias for ANY
2988 * giscanner/transformer.py:
2989 Do not lower case enumeration names per se.
2990 Skip functions which has parameters called 'va_list'
2992 2008-08-14 Colin Walters <walters@verbum.org>
2994 * giscanner/transformer.py: Comment data structures.
2995 Also squash pointers in resolve_type_name to correspond
2996 with what we do for params.
2997 * giscanner/glibtransformer.py: Print warnings in more
2998 situations. Rework checks for method/constructor to
2999 look up in our GType database instead of just checking
3000 for *. Avoid generating <record> for GObject which
3001 duplicate the <class>.
3002 * gir/Makefile.am: Generate glib-2.0.gir and gobject-2.0.gir
3005 2008-08-14 Johan Dahlin <johan@gnome.org>
3007 * giscanner/girwriter.py:
3008 * giscanner/glibast.py:
3009 * giscanner/glibtransformer.py:
3010 * giscanner/transformer.py:
3012 * tests/Makefile.am:
3013 Add pyflakes.py and run it in make check.
3014 Update the source code to fix the errors reported by
3017 2008-08-14 Johan Dahlin <johan@gnome.org>
3020 * giscanner/girparser.py:
3021 * giscanner/glibast.py:
3022 * giscanner/glibtransformer.py:
3023 Refactor the parser a bit.
3024 Add parent type to interfaces and update callsites.
3026 2008-08-14 Johan Dahlin <johan@gnome.org>
3028 * giscanner/glibtransformer.py:
3029 * giscanner/utils.py:
3030 Refactor a bit, avoid isinstance and add a method
3031 for each type we parse.
3033 2008-08-14 Johan Dahlin <johan@gnome.org>
3036 * giscanner/girparser.py:
3037 * giscanner/glibtransformer.py:
3038 * tests/Makefile.am:
3039 Run pep8.py in make check, fix old errors.
3041 2008-08-13 Colin Walters <walters@verbum.org>
3043 * giscanner/girparser.py: Parse records.
3045 2008-08-13 Colin Walters <walters@verbum.org>
3047 * gir/Makefile.am: Install again.
3048 * gir/gobject-2.0.gir: Add some more bits.
3050 2008-08-13 Colin Walters <walters@verbum.org>
3052 * gir/gobject-2.0.gir: Use correct namespace, add GType.
3053 * giscanner/girparser.py: Handle aliases.
3054 * giscanner/transformer.py: Record aliases. Make resolver
3055 functions public; we now call into these explicitly from
3056 glibtransformer. Handle resolving aliases.
3057 * giscanner/glibtransformer.py: Separate our internal namespace
3058 from included ones. Call up into transformer's resolver functions.
3060 2008-08-13 Johan Dahlin <johan@gnome.org>
3062 * girepository/girnode.c (g_ir_node_get_full_size_internal):
3063 * girepository/girparser.c (start_class):
3064 * giscanner/glibtransformer.py:
3065 Allow get_type to be None, set a get_type for GInitiallyUnowned too.
3067 2008-08-13 Johan Dahlin <johan@gnome.org>
3069 * giscanner/cgobject.py:
3070 Register GInitiallyUnowned
3071 * giscanner/girwriter.py:
3072 * giscanner/glibtransformer.py:
3073 Special case GObject/GInitially owned as they are a bit special to use.
3075 2008-08-13 Colin Walters <walters@verbum.org>
3077 * tests/scanner/Foo-expected.gir, tests/scanner/utility-expected.gir:
3078 Object is in GObject namespace.
3080 2008-08-13 Colin Walters <walters@verbum.org>
3082 * giscanner/girparser.py: Fix processing of functions
3085 2008-08-13 Colin Walters <walters@verbum.org>
3087 * giscanner/girparser.py: Parse more than just <class.
3088 * giscanner/glibtransformer.py: Put aliases in a separate
3089 data structure since their name is not canonicall.
3090 * giscanner/transformer.py: Handle resolving type names
3093 2008-08-13 Johan Dahlin <johan@gnome.org>
3095 * tools/g-ir-scanner:
3096 Allow multiple libraries
3097 * giscanner/glibtransformer.py:
3098 Rename load_library to add_library, traverse over all libraries
3099 when trying to resolve a function
3101 2008-08-12 Colin Walters <walters@verbum.org>
3103 * giscanner/transformer.py: Record typedefs as <alias> elements.
3104 Also attempt to look up types in external namespaces.
3105 * giscanner/girwriter.py: Write them.
3106 * giscanner/glibtransformer.py: Rework resolver using real instanceof
3107 checks. Resolve interface methods and properties.
3108 * tests/scanner/foo-object.h: Add a method with typedef.
3109 * tests/scanner/Foo-expected.gir: Update.
3110 * girepository/girnode.c: Debug tweaks.
3111 * girepository/girparser.c: Make a first pass through the XML where we
3112 record all the aliases. This lets us resolve them as we go through the
3114 * gir/Makefile.am: Don't install gobject-2.0.gir; we want that to come
3115 from gir-repository.
3117 2008-08-12 Colin Walters <walters@verbum.org>
3119 * giscanner/glibtransformer.py: Resolve typedefs (e.g. AtkAttributeSet -> GSList).
3120 Correctly do subclasseing in 2nd pass resolution. Handle callbacks in structure
3122 * giscanner/transformer.py: Record typedefs and expose public API for resolving
3124 * tests/scanner/Foo-expected.gir: Fix expected callback types.
3126 2008-08-12 Colin Walters <walters@verbum.org>
3128 * giscanner/glibtransformer.py: Also transform object properties.
3130 2008-08-12 Colin Walters <walters@verbum.org>
3132 * giscanner/glibtransformer.py: Also transform callbacks
3133 and structure field types.
3134 * tests/scanner/Fooe-expected.gir: Update to expect correct
3135 names for callbacks and structs.
3137 2008-08-12 Colin Walters <walters@verbum.org>
3139 * girepository/girparser.c: Handle 'any'.
3140 * tests/scanner/Foo-expected.gir, tests/scanner/foo-object.h:
3141 Add test for void *.
3143 2008-08-12 Colin Walters <walters@verbum.org>
3145 * giscanner/glibtransformer.py: We need to do type
3146 resolution in a second pass after we've seen all the
3147 enums, records, etc.
3149 2008-08-12 Colin Walters <walters@verbum.org>
3151 * tests/scanner/Foo-expected.gir, tests/scanner/foo-object.h:
3152 Add enum return value.
3153 * giscanner/glibtransformer.py: Transform function return types
3156 2008-08-12 Colin Walters <walters@verbum.org>
3158 * tests/scanner/Makefile.am: Dep .gir files on scanner
3159 sources too. Also remove @ so we see scanner invocations.
3161 2008-08-12 Colin Walters <walters@verbum.org>
3163 * girepository/girparser.c, girepository/gtypelib.c,
3164 girepository/gtypelib.h, girepository/girnode.c:
3165 Remove usage of (GAPI-oriented) TypeTag in favor of
3166 GITypeTag from girepository.h.
3168 2008-08-10 Colin Walters <walters@verbum.org>
3170 * tests/roundtrips.sh: Use the correct tests.
3172 2008-08-10 Colin Walters <walters@verbum.org>
3174 * giscanner/cgobject.py: Declare/wrap a few more functions.
3175 Fix parameter types for g_object_new and g_type_fundamental.
3177 2008-08-10 Colin Walters <walters@verbum.org>
3179 * giscanner/cgobject.py: Add new decorator @gwrap which forces
3180 us to declare types for both return value and parameters. The
3181 ctypes default of 'int' is bad because it hides 32/64 bit
3182 problems. Convert all existing functions to use it.
3184 2008-08-09 Johan Dahlin <johan@gnome.org>
3186 * giscanner/__init__.py:
3188 * giscanner/cgobject.py:
3189 * giscanner/gidlparser.py:
3190 * giscanner/gidlwriter.py:
3191 * giscanner/girparser.py:
3192 * giscanner/girwriter.py:
3193 * giscanner/glibast.py:
3194 * giscanner/glibtransformer.py:
3195 * giscanner/odict.py:
3196 * giscanner/sourcescanner.py:
3197 * giscanner/transformer.py:
3198 * giscanner/utils.py:
3199 * giscanner/xmlwriter.py:
3200 * tools/g-ir-scanner:
3204 2008-08-09 Johan Dahlin <johan@gnome.org>
3207 * relaxng/c-types.xml:
3208 * relaxng/g-types.xml:
3209 * relaxng/relaxng.rng:
3211 Remove outdated relaxng schemas.
3213 2008-08-09 Johan Dahlin <johan@gnome.org>
3216 Rename metadata to typelib in variable names,
3219 2008-08-09 Johan Dahlin <johan@gnome.org>
3223 Remove old C scanner, which got rewritten in python.
3225 2008-08-09 Johan Dahlin <johan@gnome.org>
3227 * girepository/Makefile.am:
3228 * tools/Makefile.am:
3229 * tools/girmodule.c:
3230 * tools/girmodule.h:
3233 * tools/girparser.c:
3234 * tools/girparser.h:
3235 * tools/girwriter.c:
3236 * tools/girwriter.h:
3237 Move shared *.[ch] files to girepository from tools
3239 2008-08-09 Johan Dahlin <johan@gnome.org>
3241 * tests/Makefile.am:
3244 * tests/constant.test:
3246 * tests/errors.test:
3247 * tests/function.test:
3248 * tests/gobject.test:
3249 * tests/interface.test:
3250 * tests/object.test:
3251 * tests/struct.test:
3256 Rename *.test to *.gir
3258 2008-08-09 Johan Dahlin <johan@gnome.org>
3261 * tests/Makefile.am:
3262 * tests/parser/Foo-expected.gir:
3263 * tests/parser/Makefile.am:
3264 * tests/parser/foo-object.h:
3265 * tests/parser/foo.c:
3266 * tests/parser/utility-expected.gir:
3267 * tests/parser/utility.c:
3268 * tests/parser/utility.h:
3269 * tests/scanner/Makefile.am:
3270 Rename tests/parser to test/scanner
3272 2008-08-08 Colin Walters <walters@verbum.org>
3274 * tests/roundtrips.sh: Use local .gir files again.
3276 2008-08-08 Colin Walters <walters@verbum.org>
3278 * tests/invoke/Makefile.am: .gir file depends on libtool
3281 2008-08-08 Colin Walters <walters@verbum.org>
3283 * tools/girnode.c: Pass through parent node so we can
3284 print the node whose child is NULL, if that occurs.
3286 2008-08-08 Johan Dahlin <johan@gnome.org>
3288 * tests/Makefile.am:
3289 Disable roundtrip tests which are not yet working
3290 * tests/invoke/testfns.gir:
3293 2008-08-08 Johan Dahlin <johan@gnome.org>
3295 * giscanner/girwriter.py:
3297 * giscanner/glibast.py:
3298 * giscanner/glibtransformer.py:
3299 Swap order of members, to keep it consistent with
3302 2008-08-08 Johan Dahlin <johan@gnome.org>
3304 * girepository/gtypelib.c (validate_header):
3305 * girepository/gtypelib.h:
3307 * giscanner/girwriter.py:
3308 * giscanner/sourcescanner.c (gi_source_symbol_ref),
3309 (gi_source_symbol_unref):
3312 * tests/constant.test:
3314 * tests/errors.test:
3315 * tests/function.test:
3316 * tests/gobject.test:
3317 * tests/interface.test:
3318 * tests/invoke/Makefile.am:
3319 * tests/invoke/testfns.xml:
3320 * tests/object.test:
3321 * tests/parser/Makefile.am:
3322 * tests/roundtrips.sh:
3323 * tests/struct.test:
3328 * tools/Makefile.am:
3329 * tools/compiler.c (main):
3330 * tools/generate.c (write_callable_info), (write_function_info),
3332 * tools/gidlmodule.c:
3333 * tools/gidlmodule.h:
3336 * tools/gidlparser.c:
3337 * tools/gidlparser.h:
3338 * tools/gidlwriter.c:
3339 * tools/gidlwriter.h:
3340 * tools/scanner.c (create_node_from_gtype),
3341 (create_node_from_ctype), (g_igenerator_process_properties),
3342 (g_igenerator_process_signals), (g_igenerator_create_object),
3343 (g_igenerator_create_interface), (g_igenerator_create_boxed),
3344 (g_igenerator_create_enum), (g_igenerator_create_flags),
3345 (g_igenerator_process_function_symbol),
3346 (g_igenerator_process_unregistered_struct_typedef),
3347 (g_igenerator_process_struct_typedef),
3348 (g_igenerator_process_union_typedef),
3349 (g_igenerator_process_enum_typedef),
3350 (g_igenerator_process_function_typedef),
3351 (g_igenerator_process_constant), (g_igenerator_process_symbols),
3352 (g_igenerator_add_module), (g_igenerator_add_include_idl):
3353 Merge in the gir-compiler branch.
3354 Thanks to Philip and Colin for their help.
3356 2008-07-26 Colin Walters <walters@verbum.org>
3358 * tools/Makefile.am (bin_PROGRAMS): Install g-idl-compiler
3359 and g-idl-generate to go along with how we're changing this
3360 module to be installed.
3361 * gobject-introspection-1.0.pc.in: Set up Cflags and Libs.
3363 2008-07-24 Colin Walters <walters@verbum.org>
3365 * girepository/girepository.c (g_irepository_register): Add
3366 environment variable G_IREPOSITORY_VERBOSE so we can print
3367 out what we're doing.
3368 * girepository/girepository.c (g_irepository_register_file):
3369 Add GError error message to g_debug call.
3371 2008-07-08 Jürg Billeter <j@bitron.ch>
3373 * giscanner/glibast.py:
3377 2008-06-21 Johan Dahlin <jdahlin@async.com.br>
3379 * giscanner/girparser.py (GIRParser._parse_api): Ignore a few
3382 2008-06-20 Johan Dahlin <jdahlin@async.com.br>
3385 * giscanner/girwriter.py:
3386 * giscanner/transformer.py:
3387 * tests/parser/Foo-expected.gir:
3388 * tests/parser/foo-object.h:
3389 * tests/parser/foo.c (foo_object_allow_none):
3390 Add support for gtk-doc annotations for allow-none.
3393 2008-06-19 Johan Dahlin <jdahlin@async.com.br>
3396 * giscanner/girwriter.py:
3397 * giscanner/glibast.py:
3398 * giscanner/glibtransformer.py:
3399 * giscanner/transformer.py:
3400 * tests/parser/Foo-expected.gir:
3401 Start using abstract type instead of the raw C types.
3402 Register a bunch of glib types we care about.
3404 2008-06-19 Rob Taylor <rob.taylor@codethink.co.uk>
3409 2008-06-08 Philip Van Hoof <pvanhoof@gnome.org>
3411 * girepository/girepository.c:
3412 * girepository/gtypelib.c:
3413 * girepository/ginfo.c:
3414 * girepository/ginvoke.c:
3415 * girepository/girepository.h:
3416 * girepository/gtypelib.h:
3417 * girepository/gmetadata.c:
3418 * girepository/Makefile.am:
3419 * girepository/gmetadata.h:
3421 * tools/gidlmodule.c:
3424 * tools/gidlmodule.h:
3425 * tools/gidlparser.c:
3427 Renamed GMetadata to GTypelib
3429 2008-06-07 Johan Dahlin <jdahlin@async.com.br>
3431 * giscanner/xmlwriter.py:
3432 Improve line wrapping when > 79 charaters
3434 2008-06-05 Jürg Billeter <j@bitron.ch>
3437 * giscanner/girwriter.py:
3438 * giscanner/transformer.py:
3439 Use <type> element for field types
3440 * tests/parser/Foo-expected.gir:
3443 2008-06-04 Johan Dahlin <jdahlin@async.com.br>
3445 * giscanner/glibtransformer.py:
3446 Fix a bug which prevented GdkEvent from being generated
3448 2008-06-03 Johan Dahlin <jdahlin@async.com.br>
3450 * giscanner/Makefile.am:
3452 * giscanner/girwriter.py:
3453 * giscanner/glibast.py:
3454 * giscanner/glibtransformer.py:
3455 * giscanner/transformer.py:
3456 * giscanner/utils.py:
3457 * tests/parser/Foo-expected.gir:
3458 Improve enum member parsing and introspection
3460 2008-05-31 Johan Dahlin <jdahlin@async.com.br>
3462 * giscanner/scannerparser.y:
3463 * giscanner/sourcescanner.h:
3464 * giscanner/sourcescanner.py:
3465 Add a new source type enum for member.
3466 Use __repr__ for improved debugging
3467 * giscanner/girparser.py:
3469 * giscanner/transformer.py:
3470 Improve parsing of struct members.
3471 * tests/parser/foo-object.h:
3474 2008-05-31 Johan Dahlin <jdahlin@async.com.br>
3476 * giscanner/xmlwriter.py:
3477 Improve error reporting when trying to quote None.
3478 * giscanner/girparser.py:
3479 Do not print warnings when including more complete .gir files
3480 * giscanner/girwriter.py:
3481 Do not require a name for parameters, add a todo for singletons
3482 * giscanner/glibtransformer.py:
3483 Refactor the way structs are done, add a couple of hacks to allow
3485 * giscanner/transformer.py:
3486 Add enough hacks so cairo, atk and pango.gir can be parsed properly
3487 * gobject-introspection-1.0.pc.in:
3488 Export girdir, so we can access gobject-2.0.gir from outside
3490 2008-05-31 Johan Dahlin <jdahlin@async.com.br>
3492 * tools/g-ir-scanner:
3493 * tests/parser/Makefile.am:
3494 Update sys.path before running the parser so we don't have
3495 to setup PYTHONPATH ourselves.
3499 * girepository/Makefile.am:
3500 * giscanner/transformer.py:
3501 * gobject-introspection-1.0.pc.in:
3502 * gobject-introspection.pc.in:
3503 * tools/Makefile.am:
3505 Rename pkg-config name to gobject-introspection-1.0,
3506 Do not installed anything which is not using the gir format.
3507 Disable compililation the old C scanner, but still keep the source
3508 until all the remaning functionallity has been ported.
3510 2008-05-31 Johan Dahlin <jdahlin@async.com.br>
3512 * giscanner/giscannermodule.c (symbol_get_ident): Prevent
3513 a crash when symbol->indent is NULL.
3515 * giscanner/sourcescanner.py (ctype_name): Add ctype_name,
3516 a function to convert a CTYPE symbol to a string
3518 2008-05-24 Johan Dahlin <jdahlin@async.com.br>
3521 * giscanner/girwriter.py:
3522 * giscanner/giscannermodule.c
3523 (pygi_source_scanner_append_filename),
3524 (pygi_source_scanner_parse_file):
3525 * giscanner/glibtransformer.py:
3526 * giscanner/sourcescanner.py:
3527 Revert back to using temporary files to send in headers.
3528 Allow Functions to be passed in as callbacks, add a couple
3529 of try/excepts missing features.
3530 We can now scan pango
3532 2008-05-08 Johan Dahlin <johan@gnome.org>
3534 * giscanner/glibtransformer.py:
3535 * giscanner/transformer.py:
3536 Move namespace stripping glibtransformer->transformer
3538 2008-05-08 Johan Dahlin <johan@gnome.org>
3541 * giscanner/girwriter.py:
3542 * giscanner/glibtransformer.py:
3543 * giscanner/transformer.py:
3544 * tools/g-ir-scanner:
3545 Introduce a namespace ast node
3547 2008-05-05 Johan Dahlin <johan@gnome.org>
3549 * giscanner/__init__.py:
3550 * giscanner/sourcescanner.py:
3551 * giscanner/transformer.py:
3552 Move sourcescanner symbols to the sourcescanner module, instead
3553 of in the global __init__ namespace.
3555 2008-05-03 Johan Dahlin <johan@gnome.org>
3557 * giscanner/glibtransformer.py:
3558 * tools/g-ir-scanner:
3559 Handle missing parameters better, allow - and + in .la dlname
3562 2008-05-03 Johan Dahlin <johan@gnome.org>
3564 * giscanner/__init__.py:
3566 * giscanner/girwriter.py:
3567 * giscanner/glibtransformer.py:
3568 * giscanner/transformer.py:
3569 Parse struct fields properly, improve debugging.
3571 2008-04-29 Johan Dahlin <johan@gnome.org>
3574 * giscanner/girwriter.py:
3575 * giscanner/transformer.py:
3576 * tests/parser/Foo-expected.gir:
3578 Use transfer-ownership everywhere, to mark ownership/calle/caller etc.
3580 2008-04-29 Johan Dahlin <jdahlin@async.com.br>
3583 * docs/g-ir-scanner.1:
3584 * metadata-annotations-proposal.txt:
3585 * metadata-format.txt:
3586 Add a basic, unfinshed man page for g-ir-scanner, move documents into .txt
3588 2008-04-29 Johan Dahlin <jdahlin@async.com.br>
3590 * giscanner/girwriter.py:
3591 * giscanner/glibtransformer.py:
3592 * giscanner/transformer.py:
3593 * giscanner/xmlwriter.py:
3594 * tests/parser/Foo-expected.gir:
3595 * tests/parser/foo-object.h:
3596 Write record/structs to gir file too. Add a couple of tests,
3597 fix an off by one error in xmlwriter.py.
3599 2008-04-28 Johan Dahlin <johan@gnome.org>
3601 * giscanner/xmlwriter.py: Calculate the line length properly,
3602 include the provided extra indentation in the calculation, really.
3604 2008-04-28 Johan Dahlin <jdahlin@async.com.br>
3607 * giscanner/glibast.py:
3608 * giscanner/glibtransformer.py:
3609 * giscanner/transformer.py:
3610 * tools/g-ir-scanner:
3611 Add a --strip-prefix and sort out confusion between names and symbols
3612 for functions and struct + derivaties.
3613 Refactor bootstrap of g-ir-scanner, so we can set options on
3614 Transformer() before parsing everything.
3616 2008-04-28 Johan Dahlin <johan@gnome.org>
3618 * giscanner/transformer.py (Transformer._traverse_one): Avoid recursion
3619 when scanning girepository.h
3621 * giscanner/sourcescanner.py (SourceScanner._preprocess): Define
3622 a __GI_SCANNER__ when we run.
3624 2008-04-28 Johan Dahlin <jdahlin@async.com.br>
3627 * giscanner/girwriter.py:
3628 * giscanner/glibast.py:
3629 * giscanner/glibtransformer.py:
3630 * tests/parser/Foo-expected.gir:
3631 * tests/parser/utility-expected.gir:
3632 Rename most c:identifier to c:type. Add new ones to
3633 class/interface/enum/boxed.
3635 2008-04-28 Johan Dahlin <jdahlin@async.com.br>
3638 * giscanner/girwriter.py:
3639 * giscanner/glibtransformer.py:
3640 * tests/parser/Foo-expected.gidl:
3641 * tests/parser/Makefile.am:
3642 Move c:identifier from return-value to subchild type,
3643 as per Jürgs suggestion
3645 2008-04-28 Johan Dahlin <johan@gnome.org>
3647 * giscanner/girwriter.py:
3648 * tests/parser/Foo-expected.gir:
3649 Write property.type as a child node.
3651 2008-04-27 Johan Dahlin <johan@gnome.org>
3656 * gidl/gobject-2.0.gidl:
3658 * gir/gobject-2.0.gir:
3659 * tests/parser/Makefile.am:
3660 Replace the GObject gidl with a GObject gir.
3662 2008-04-27 Johan Dahlin <johan@gnome.org>
3664 * tools/Makefile.am (bin_SCRIPTS): g-ir-scanner is a script,
3667 * giscanner/xmlwriter.py:
3668 * tests/parser/Foo-expected.gir:
3669 Include indentation in line length calculation
3671 2008-04-27 Johan Dahlin <johan@gnome.org>
3673 * giscanner/girparser.py:
3674 Prettify NS parsing using elementtree.
3676 2008-04-27 Johan Dahlin <johan@gnome.org>
3679 * giscanner/Makefile.am:
3680 * giscanner/girparser.py:
3681 * giscanner/glibtransformer.py:
3682 * tests/parser/Foo-expected.gidl:
3683 * tests/parser/Foo-expected.gir:
3684 * tests/parser/Makefile.am:
3685 * tests/parser/utility-expected.gidl:
3686 * tests/parser/utility-expected.gir:
3687 * tools/g-ir-scanner:
3688 Switch over to GIR as the default format. Add a simple GIDL
3690 Update tests and fix simplify makefiles by depending
3691 on GNU make extensions.
3693 2008-04-27 Johan Dahlin <johan@gnome.org>
3695 * giscanner/xmlwriter.py:
3696 Wrap attributes for lines which are wider than 79 characters
3698 * giscanner/scannerlexer.l:
3699 Allow parenthesis in annotations
3702 * giscanner/gidlwriter.py:
3703 * giscanner/girwriter.py:
3704 * giscanner/glibtransformer.py:
3705 * giscanner/transformer.py:
3706 Add initial sequence support, including annotation.
3707 Refactor type handling a bit.
3709 2008-04-27 Johan Dahlin <johan@gnome.org>
3711 * tests/parser/Foo-expected.gidl:
3712 * tests/parser/foo-object.h:
3713 * tests/parser/foo.c (foo_object_class_init),
3714 (foo_object_get_strings), (foo_object_get_objects):
3715 Add two new functions to check sequence return values.
3716 Also fixes a compilation warning.
3718 2008-04-27 Johan Dahlin <johan@gnome.org>
3720 * giscanner/giscannermodule.c (]): Cast the getter, avoids
3721 a compilation warning.
3723 * tools/Makefile.am (g_ir_scanner_SOURCES):
3724 g-ir-scanner has no sources.
3726 2008-04-25 Johan Dahlin <johan@gnome.org>
3728 * giscanner/Makefile.am:
3730 * giscanner/gidlparser.py:
3731 * giscanner/gidlwriter.py:
3732 * giscanner/girwriter.py:
3733 * giscanner/glibast.py:
3734 * giscanner/glibtransformer.py:
3735 * giscanner/transformer.py:
3736 Split out nodes to ast.py and glibast.py
3738 2008-04-25 Johan Dahlin <jdahlin@async.com.br>
3740 * giscanner/Makefile.am:
3741 * giscanner/gidlparser.py:
3742 * giscanner/gidlwriter.py:
3743 * giscanner/girwriter.py:
3744 * giscanner/glibtransformer.py:
3745 * giscanner/gobjecttreebuilder.py:
3746 * giscanner/transformer.py:
3747 * giscanner/treebuilder.py:
3748 * tools/g-ir-scanner:
3749 Rename treebuilder to transformer and
3750 gobjectreebuilder to glibtransformer.
3752 2008-04-25 Johan Dahlin <jdahlin@async.com.br>
3754 * giscanner/Makefile.am:
3755 * giscanner/__init__.py:
3756 * giscanner/cgobject.py:
3757 * giscanner/gidlparser.py:
3758 * giscanner/gidlwriter.py:
3759 * giscanner/girwriter.py:
3760 * giscanner/gobjecttreebuilder.py:
3761 * giscanner/odict.py:
3762 * giscanner/sourcescanner.py:
3763 * giscanner/treebuilder.py:
3764 * giscanner/xmlwriter.py:
3765 * tools/Makefile.am:
3766 * tools/g-ir-scanner:
3767 Add LGPLv2 license header and install all python files
3769 2008-04-25 Johan Dahlin <jdahlin@async.com.br>
3772 * giscanner/gidlwriter.py:
3773 * giscanner/giscannermodule.c (pygi_source_directive_new),
3774 (directive_get_options), (pygi_source_symbol_new),
3775 (symbol_get_base_type), (pygi_source_type_new),
3776 (type_get_base_type), (type_get_child_list),
3777 (pygi_source_scanner_get_symbols),
3778 (pygi_source_scanner_get_directives):
3779 * giscanner/gobjecttreebuilder.py:
3780 * giscanner/sourcescanner.py:
3781 * giscanner/treebuilder.py:
3782 * tests/parser/foo-object.h:
3783 Add support for virtual methods.
3784 Pair struct FooClass with struct Foo.
3785 Clean up the SourceScanner bindings a bit.
3786 Add a testcase for virtual methods.
3788 2008-04-25 Johan Dahlin <jdahlin@async.com.br>
3790 * giscanner/cgobject.py:
3791 * giscanner/gidlwriter.py:
3792 * giscanner/gobjecttreebuilder.py:
3793 Add support for signals
3795 * tests/parser/foo.c (foo_object_class_init):
3796 * Foo-expected.gidl:
3797 Add a signal and update the expected output.
3799 2008-04-24 Johan Dahlin <jdahlin@async.com.br>
3801 * giscanner/gidlwriter.py:
3802 * giscanner/girwriter.py:
3803 * giscanner/giscannermodule.c (directive_get_name),
3804 (directive_get_value), (directive_get_options),
3805 (symbol_get_directives), (symbol_set_directives),
3806 (pygi_source_scanner_parse_file),
3807 (pygi_source_scanner_lex_filename),
3808 (pygi_source_scanner_get_directives), (init_giscanner):
3809 * giscanner/sourcescanner.c (gi_source_scanner_get_directives):
3810 * giscanner/sourcescanner.h:
3811 * giscanner/sourcescanner.py:
3812 * giscanner/treebuilder.py:
3813 * tools/g-ir-scanner:
3814 Add support for source/header annotations.
3816 2008-04-22 Johan Dahlin <jdahlin@async.com.br>
3818 * giscanner/gidlwriter.py:
3819 * giscanner/girwriter.py:
3820 * giscanner/gobjecttreebuilder.py:
3821 * giscanner/treebuilder.py:
3822 Add support for Callbacks
3824 2008-04-22 Havoc Pennington <hp@pobox.com>
3826 * girepository/ginvoke.c (g_function_info_invoke): If a symbol is
3827 not in metadata->module, look for it in the global module, in case
3828 some other object or the app itself provides the symbol.
3830 2008-04-22 Havoc Pennington <hp@pobox.com>
3832 * girepository/gmetadata.c (_g_metadata_init): hack to avoid
3833 dlopening a library that is already in the main app, by checking
3834 whether one of the lib's symbols is already loaded.
3836 2008-04-22 Johan Dahlin <jdahlin@async.com.br>
3838 * tests/parser/Foo-expected.gidl:
3839 * tests/parser/foo-object.h:
3842 2008-04-22 Havoc Pennington <hp@pobox.com>
3844 * girepository/ginfo.c (g_interface_info_find_method):
3845 Use interface_blob_size not object_blob_size to compute offset.
3847 2008-04-22 Havoc Pennington <hp@pobox.com>
3849 * girepository/gmetadata.c (_g_metadata_init): remove
3850 G_MODULE_BIND_LOCAL flag when loading libraries, since some libs
3851 (Glade and Clutter for example) rely on being loaded globally.
3853 2008-04-22 Havoc Pennington <hp@pobox.com>
3855 * girepository/ginfo.c (g_registered_type_info_get_g_type): new
3856 function to get the GType given a RegisteredTypeInfo
3858 2008-04-22 Johan Dahlin <johan@gnome.org>
3860 * COPYING: Add a LGPL license, to prevent automake to
3861 put in a copy of GPL here. Pointed out by Havoc.
3863 * girepository/ginfo.c (g_info_from_entry), (g_type_info_new),
3864 (g_type_info_is_pointer), (g_type_info_get_tag),
3865 (g_type_info_get_param_type), (g_type_info_get_interface),
3866 (g_type_info_get_array_length), (g_type_info_is_zero_terminated),
3867 (g_type_info_get_n_error_domains), (g_type_info_get_error_domain),
3868 (g_error_domain_info_get_codes), (g_enum_info_get_value),
3869 (g_object_info_get_interface), (g_object_info_get_field),
3870 (g_interface_info_get_prerequisite),
3871 (g_signal_info_get_class_closure), (g_constant_info_get_value):
3872 * girepository/ginvoke.c (get_ffi_type):
3873 * girepository/girepository.h:
3874 * girepository/gmetadata.c (g_metadata_get_dir_entry),
3875 (g_metadata_check_sanity), (validate_header),
3876 (validate_array_type_blob), (validate_iface_type_blob),
3877 (validate_param_type_blob), (validate_error_type_blob),
3878 (validate_type_blob), (validate_constant_blob),
3879 (validate_struct_blob), (validate_enum_blob):
3880 * girepository/gmetadata.h:
3881 * tests/Makefile.am:
3882 * tests/invoke/Makefile.am:
3883 * tests/invoke/invoke.c (main):
3884 * tests/roundtrips.sh:
3885 * tools/Makefile.am:
3886 * tools/compiler.c (format_output), (write_out_metadata), (main):
3887 * tools/generate.c (write_type_name), (write_type_info),
3888 (write_constant_value), (write_enum_info), (load_metadata), (main):
3889 * tools/gidlcompilercontext.c:
3890 * tools/gidlcompilercontext.h:
3891 * tools/gidlcompilerentrynode.c:
3892 * tools/gidlcompilerentrynode.h:
3893 * tools/gidlcompilertypenode.c:
3894 * tools/gidlcompilertypenode.h:
3895 * tools/gidlmodule.c (g_idl_module_build_metadata):
3896 * tools/gidlmodule.h:
3897 * tools/gidlnode.c (init_stats), (dump_stats),
3898 (g_idl_node_get_size), (g_idl_node_get_full_size),
3899 (g_idl_node_cmp), (g_idl_node_can_have_member),
3900 (g_idl_node_add_member), (g_idl_node_param_direction_string),
3901 (parse_int_value), (parse_uint_value), (parse_float_value),
3902 (parse_boolean_value), (find_entry_node), (find_entry),
3903 (serialize_type), (g_idl_node_build_metadata), (write_string):
3905 * tools/gidlparser.c (parse_type_internal):
3906 * tools/quote-file.sh:
3907 Revert revisions 157,149-148,136-129 and 120.
3908 Move back to using g-idl-generate to generate the metadata and
3909 avoids dependency on a c compiler.
3911 2008-04-22 Johan Dahlin <jdahlin@async.com.br>
3913 * giscanner/girwriter.py:
3914 * tools/g-ir-scanner:
3915 Add an initial GIR writer and a --format option to g-ir-scanner
3917 2008-04-21 Johan Dahlin <johan@gnome.org>
3919 * giscanner/cgobject.py: Use ctypes.util.find_library to locate
3920 gobject-2.0 and raise ImportError if not found.
3922 * giscanner/gidlparser.py:
3923 * giscanner/gidlwriter.py:
3924 * giscanner/gobjecttreebuilder.py:
3925 * tools/g-ir-scanner:
3926 Add a --include argument to include types from other idls.
3927 Add a minimalistic GIDL parser (just objects for now)
3928 Implement resolving of external type references and use it to
3929 resolve parent types, argument types and return types.
3931 2008-04-21 Johan Dahlin <johan@gnome.org>
3933 * giscanner/gidlwriter.py:
3934 * giscanner/gobjecttreebuilder.py:
3935 * giscanner/treebuilder.py:
3936 Add support for properties.
3937 Refactor Class/Interface support a bit, to share more code and
3938 always initialize their method attribute to an empty list.
3940 2008-04-21 Johan Dahlin <johan@gnome.org>
3942 * giscanner/cgobject.py:
3943 Add a workaround for a glib bug interface introspection bug
3944 (object_interface_list_properties, object_class_list_properties):
3945 Cast the return value to GParamSpec.
3947 * tests/parser/Foo-expected.gidl: Update
3948 * tests/parser/foo.c: Add a string property
3950 * giscanner/gobjecttreebuilder.py:
3951 After stripping namespaces, remove the original
3952 item to avoid duplication (GtkButton struct and Button object)
3954 2008-04-21 Johan Dahlin <johan@gnome.org>
3956 * giscanner/gobjecttreebuilder.py:
3957 * giscanner/treebuilder.py:
3958 Strip namespaces before objects, so we'll export
3959 GtkButton as Button in the gtk namespace
3961 2008-04-21 Johan Dahlin <johan@gnome.org>
3963 * giscanner/gidlwriter.py:
3964 * giscanner/gobjecttreebuilder.py:
3965 * giscanner/treebuilder.py:
3966 Add constructors for object/boxed types.
3968 2008-04-21 Johan Dahlin <johan@gnome.org>
3970 * giscanner/gidlwriter.py:
3971 * giscanner/gobjecttreebuilder.py:
3972 Add support for boxed types
3974 2008-04-21 Johan Dahlin <johan@gnome.org>
3976 * giscanner/giscannermodule.c: Mark structures as const,
3977 wrap SourceType.const_string.
3979 * tests/parser/foo-object.h: Add a couple of constants.
3981 * giscanner/gidlwriter.py:
3982 * giscanner/gobjecttreebuilder.py:
3983 * giscanner/treebuilder.py:
3984 Add basic support for interfaces
3986 * tools/g-ir-scanner:
3987 Add -o/--output for writing to a file
3989 2008-04-21 Havoc Pennington <hp@redhat.com>
3991 * TODO: add some C API wishlist items I could think of quickly
3993 2008-04-21 Johan Dahlin <jdahlin@async.com.br>
3995 * giscanner/gidlwriter.py:
3996 * giscanner/xmlwriter.py:
3997 Add a simple api for writing tags which can be used
3998 with the new 'with statement' in python 2.5
4000 2008-04-21 Johan Dahlin <johan@gnome.org>
4002 * giscanner/gobjecttreebuilder.py:
4003 Strip namespace and object prefix from method names.
4005 2008-04-21 Johan Dahlin <johan@gnome.org>
4007 * tools/g-ir-scanner (main): Add --pkg option to pass in
4008 pkg-config modules to get cflags from.
4010 * giscanner/gidlwriter.py (GIDLWriter._write_method):
4011 Avoid duplication, reuse function writer for methods.
4013 2008-04-21 Johan Dahlin <jdahlin@async.com.br>
4015 * giscanner/gidlwriter.py:
4016 * giscanner/gobjecttreebuilder.py:
4017 * giscanner/treebuilder.py:
4018 * tools/g-ir-scanner:
4019 Resolve libtool .la files.
4020 Strip name spaces for methods.
4021 Add function symbols
4023 2008-04-20 Johan Dahlin <jdahlin@async.com.br>
4025 * giscanner/cgobject.py:
4026 * giscanner/gidlwriter.py:
4027 * giscanner/gobjecttreebuilder.py:
4028 * giscanner/treebuilder.py:
4029 Add support for classes and methods
4031 2008-04-20 Johan Dahlin <johan@gnome.org>
4033 * giscanner/gidlwriter.py:
4034 * giscanner/gobjecttreebuilder.py:
4035 * giscanner/odict.py:
4036 Avoid conflicts, keep the output ordered similar to
4037 the order of the input.
4038 Add a simple ordered dictionary implemenation
4040 2008-04-19 Johan Dahlin <johan@gnome.org>
4042 * giscanner/cgobject.py:
4043 * giscanner/gidlwriter.py:
4044 * giscanner/gobjecttreebuilder.py:
4045 * tools/g-ir-scanner:
4046 Start introspecting get-type functions.
4047 Implement support for GLib/GFlags GTypes.
4048 Add a ctype based GObject binding.
4050 2008-04-18 Johan Dahlin <jdahlin@async.com.br>
4052 * giscanner/gidlwriter.py:
4053 * giscanner/xmlwriter.py:
4054 * tools/g-ir-scanner:
4055 Add a simplistic gidl writer, which can't do too much.
4057 2008-04-18 Johan Dahlin <johan@gnome.org>
4059 * giscanner/sourcescanner.py:
4060 * giscanner/treebuilder.py:
4061 * tools/g-ir-scanner:
4062 split tree building and source scanning interface to separate files.
4064 2008-04-18 Johan Dahlin <johan@gnome.org>
4066 * tools/g-ir-scanner (Parameter.__init__): Start constructing
4068 - Add support for struct/parameter/return, start parsing of ctypes
4070 * giscanner/giscannermodule.c: wrap GISourceType.child_list and
4073 2008-03-31 Johan Dahlin <johan@gnome.org>
4075 * tools/g-ir-scanner:
4076 Start to build abstract syntax node of scanned sources.
4077 Add support for cpp options.
4079 2008-03-27 Johan Dahlin <johan@gnome.org>
4081 * giscanner/giscannermodule.c:
4082 * giscanner/scannerlexer.l:
4083 * giscanner/sourcescanner.c:
4084 * tools/g-ir-scanner:
4086 Add simple pre-processor using subprocess and a PIPE.
4087 Change the parse_file apis to accept a file descriptor.
4089 2008-03-25 Johan Dahlin <johan@gnome.org>
4091 * giscanner/__init__.py:
4092 * tools/g-ir-scanner:
4093 Fix a typo and add an example python test program.
4095 2008-03-25 Johan Dahlin <johan@gnome.org>
4097 * giscanner/__init__.py:
4098 * giscanner/giscannermodule.c:
4099 * giscanner/sourcescanner.c:
4100 * giscanner/sourcescanner.h:
4101 Add constants and wrap a few more SymbolType fields
4103 2008-03-25 Johan Dahlin <johan@gnome.org>
4107 * giscanner/__init__.py:
4108 * giscanner/giscannermodule.c:
4109 * giscanner/Makefile.am:
4111 Add initial python bindings for the scanner and
4112 depend on python 2.5.
4114 2008-03-25 Johan Dahlin <johan@gnome.org>
4118 * giscanner/Makefile.am:
4119 * giscanner/sourcescanner.c:
4120 * giscanner/sourcescanner.h:
4121 * tools/Makefile.am:
4122 * tools/grealpath.h:
4123 * tools/sourcescanner.c:
4124 * tools/sourcescanner.h:
4126 Move the scanner to a separate library.
4128 2008-03-23 Johan Dahlin <johan@gnome.org>
4130 * tools/Makefile.am:
4133 * tools/scannerlexer.l:
4134 * tools/scannerparser.y:
4135 * tools/sourcescanner.c:
4136 * tools/sourcescanner.h:
4137 Split out the source scanner from the generator.
4138 Rename the symbols used in the scanner to use the gi_ prefix.
4139 This should make it possible to use the raw C parser from
4142 2008-03-23 Johan Dahlin <johan@gnome.org>
4144 * tests/parser/Makefile.am (utility.gidl):
4145 * tests/parser/utility-expected.gidl:
4146 Pass in the gobject.gidl since we're defining a GObject.
4148 2008-03-12 Johan Dahlin <johan@gnome.org>
4150 * relaxng/relaxng.rng:
4151 Add a releaxng in relaxng we can use to validate the relaxngs
4154 2008-03-12 Jürg Billeter <j@bitron.ch>
4156 * tools/scanner.c: (g_igenerator_new):
4157 * tools/scannerparser.y:
4158 Fix compiler warnings.
4160 2008-03-12 Jürg Billeter <j@bitron.ch>
4164 * tools/scannerparser.y:
4165 Start fixing memory management in g-idl-scanner.
4167 2008-03-12 Rob Taylor <rob.taylor@codethink.co.uk>
4169 * tools/gidlcompilercontext.c: (write_compiled):
4170 Fix critical warning when no shlib passed to g-idl-compiler.
4172 2008-03-12 Johan Dahlin <johan@gnome.org>
4174 * tests/parser/utility-expected.gidl:
4175 * tests/parser/utility.h:
4176 Add a get_type-function, so the scanner actually
4177 parses it as an object.
4179 2008-03-12 Johan Dahlin <johan@gnome.org>
4181 * tools/gidlwriter.c (function_generate): Add missing trailing quote.
4184 * tests/parser/Foo-expected.gidl:
4185 * tests/parser/Makefile.am:
4186 * tests/parser/foo-object.h:
4187 * tests/parser/foo.c:
4188 * tests/parser/utility-expected.gidl:
4189 * tests/parser/utility.c:
4190 * tests/parser/utility.h:
4192 Add a new gidl test. 'utility.gidl', which is used to be able
4193 to test external type references. Add a reference to UtilityObject*
4196 2008-03-11 Johan Dahlin <johan@gnome.org>
4200 Remove most global variables
4202 2008-03-11 Philip Van Hoof <me@pvanhoof.be>
4204 * tools/scannerlexer.l:
4206 * tests/parser/Foo-expected.gidl:
4207 * tests/parser/foo.c:
4208 * tests/parser/Makefile.am:
4209 * tests/parser/foo-object.h:
4211 Added a few extra tests. Which resulted in finding a few
4212 bugs. Which resulted in me fixing those bugs
4214 2008-03-11 Rob Taylor <rob.taylor@codethink.co.uk>
4216 * tools/gidlcompilercontext.c: (g_idl_compiler_write_dir_entry),
4217 (g_idl_compiler_write_xref_entry), (g_idl_compiler_add_xref):
4218 Add some comments for strings into generated output for
4221 2008-03-11 Rob Taylor <rob.taylor@codethink.co.uk>
4223 * tools/gidlcompilercontext.c: (write_compiled):
4224 Write out the shlibs variable before writing out the strings
4225 length. Fixes compiler warning when using '-l' flag with
4228 2008-03-11 Johan Dahlin <johan@gnome.org>
4230 * tests/parser/Foo-expected.gidl:
4231 * tests/parser/foo-object.h:
4234 * tools/scannerlexer.l:
4235 Add support for parsing return arguments. Add support for
4236 caller-owns return types.
4237 Patch by Philip Van Hoof.
4239 * tools/scannerparser.y:
4240 Remove parsing of the @deprecated syntax used in headers.
4241 We will support gtk-doc deprecation in the future instead.
4243 2008-03-11 Johan Dahlin <johan@gnome.org>
4245 * tools/compiler.c (main): Coding style fixes
4247 2008-03-10 Johan Dahlin <johan@gnome.org>
4250 Add GCOV_LIBS to GILIBS
4252 2008-03-10 Johan Dahlin <johan@gnome.org>
4254 * tests/parser/Foo-expected.gidl:
4255 * tests/parser/foo.c:
4256 Rename null-ok to direction=out
4258 2008-03-10 Philip Van Hoof <me@pvanhoof.be>
4260 reviewed and extensively tested by Johan
4262 * tests/parser/Foo-expected.gidl:
4263 * tests/parser/foo-object.h:
4264 * tests/parser/foo.c:
4267 * tools/gidlwriter.c:
4270 * tools/scannerlexer.l:
4271 * tools/scannerparser.y:
4273 Add support for scanning for gtk-doc comments inside
4274 C source files. Add tests
4276 2008-03-10 Johan Dahlin <johan@gnome.org>
4278 * tests/parser/Makefile.am:
4279 * tests/parser/foo.c:
4282 * tools/scannerparser.y:
4283 Add an api to lex filenames.
4284 Lex all source .c files passed in on the command line.
4285 Scan sources in a test and a couple of private structures
4286 which should not be included in the generated gidl
4288 2008-03-10 Johan Dahlin <johan@gnome.org>
4290 * tests/invoke/Makefile.am: Make the generated metadata
4291 depend on the g-idl-compiler
4293 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4295 * tools/gidlmodule.c
4296 * tools/gidlmodule.h
4299 Remove the old g-idl-compiler code.
4302 2008-02-22 Mark Doffman <mark.doffman@codethink.co.uk>
4304 * tools/quote-file.sh
4307 Move to using the 'C' struct compiler code.
4309 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4311 * girepository/ginfo.c
4313 Change the way that external references with no namespace
4314 are dealt with. External references with no namespace
4315 are placed into the XML as-if they are a local reference.
4316 This is temporary, but helps with roundtrip tests.
4318 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4320 * girepository/ginfo.c
4321 Add the ability to get the value of a constant of
4322 type TYPE_TAG_SYMBOL. In the case of a symbol the value
4323 is provided as a string.
4325 This would deal properly with:
4326 typedef char* random;
4327 const random = "A string";
4329 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4331 * girepository/ginfo.c
4332 * girepository/girepository.h
4334 Add a function to check if an enum is registered or not.
4335 Previously anything testing this relied on the g-type
4336 string offset having a value of 0.
4338 * girepository/gmetadata.c
4339 * girepository/gmetadata.h
4341 Remove unneccesary or erroneous checks. There were two
4342 metadata validation checks which made sure that the blob
4343 sizes were the same as some magic numbers compiled into the code.
4344 This is wrong as it breaks any forwards compatibility that may
4347 Checks were also present that made sure that unregistered type
4348 blobs had a value of 0 in the g-type offset field. This is
4349 unneccessary. If a type blob is unregistered then any value
4350 in its g-type field is simply invalid.
4352 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4354 * girepository/ginfo.c
4355 * girepository/gmetadata.c
4356 * girepository/gmetadata.h
4358 Change the metadata format to have a standard header
4359 for all the type blobs. Merge the SimpleTypeBlob
4360 and InterfaceTypeBlob into a union. A union of these
4361 two blobs existed previously but was not explicit
4362 in the metadata format.
4364 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4366 * tools/gidlcompilercontext.c
4367 * tools/gidlcompilercontext.h
4368 * tools/gidlcompilerentrynode.c
4369 * tools/gidlcompilerentrynode.h
4370 * tools/gidlcompilertypenode.c
4371 * tools/gidlcompilertypenode.h
4373 Add code to compile a tree of GIdlNodes to
4374 a 'C' struct representing the metadata.
4375 This is to aid cross-compiling. Previously
4376 the g-idl-compiler created a binary blob with
4377 data written in the byte order and alignment
4378 of the tool rather than the intended target.
4380 Cleaned up and improved by Johan and Robert :-)
4382 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4384 * girepository/ginvoke.c
4385 * girepository/girepository.h
4386 * girepository/gmetadata.c
4387 * girepository/gmetadata.h
4389 * tools/gidlparser.c
4390 Modify TYPE_TAG_INTERFACE to TYPE_TAG_SYMBOL
4391 to avoid confusion with the interface blob.
4394 * tools/gidlparser.c
4395 Remove magic numbers and replace with type-tag
4396 enumeration symbols.
4398 * girepository/gmetadata.c
4399 Add validate declaration.
4401 2008-03-10 Jürg Billeter <j@bitron.ch>
4403 * tools/gidlparser.c: (parse_type_internal):
4404 * tools/scannerlexer.l:
4405 * tools/scannerparser.y:
4406 Support C99 _Bool type in scanner.
4408 2008-03-10 Jürg Billeter <j@bitron.ch>
4410 * tests/parser/Foo-expected.gidl:
4411 * tests/parser/foo-object.h:
4412 * tests/parser/foo.c: (foo_enum_method):
4413 * tools/scanner.c: (g_igenerator_process_function_symbol):
4414 Don't skip functions that are defined in the namespace of a type
4415 that doesn't support methods, as for example enums.
4417 2008-03-10 Johan Dahlin <johan@gnome.org>
4419 * gidl.dtd: Remove, we're using relaxng for now
4421 * tests/parser/Foo-expected.gidl:
4422 * tests/parser/foo-object.h:
4423 * tests/parser/foo.c:
4424 Rename the enum/flags get_type functions to include the whole type.
4426 2008-03-08 Marc-Andre Lureau <marcandre.lureau@gmail.com>
4428 * tools/gidlwriter.c (enum_generate): added "type-name",
4429 "get-type" and "deprecated" missing arguments.
4430 * tests/parser/Foo-expected.gidl:
4431 * tests/parser/foo-object.h: test enum type, and no type.
4433 2008-03-06 Johan Dahlin <jdahlin@async.com.br>
4436 Consistent checks, add missing 'test'
4438 2008-03-05 Havoc Pennington <hp@redhat.com>
4440 * configure.ac: Take advantage of a libffi.pc if one exists, as it
4441 does on Fedora 8. Make libffi a hard requirement, since it was in
4442 practice anyway (was not really conditional in the code or
4443 makefile, only in configure).
4445 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4447 reviewed by: Rob Taylor <rob.taylor@codethink.co.uk>
4448 reviewed by: Johan Dahlin <johan@gnome.org>
4450 * tests/Makefile.am:
4451 * tests/roundtrips.sh:
4452 Modify the roundtrips test so that they do not use the
4453 --raw option of the gidl compiler but instead compile a
4454 shared library to use with g_module.
4456 * tests/invoke/Makefile.am:
4457 * tests/invoke/invoke.c:
4458 Modify the invoke tests to build a shared library rather
4459 than use the --raw option.
4461 * tests/invoke/invoke-namespace-find.sh: Removed:
4462 Noone knows why this was here, so removed.
4464 2008-02-19 Rob Taylor <rob.taylor@codethink.co.uk>
4466 * tools/scanner.c: (g_igenerator_process_function_symbol):
4467 Move g_idl_node_can_have_member test later, as it broke spotting
4468 get_type's for nodes that can't have members.
4470 2008-02-18 Rob Taylor <rob.taylor@codethink.co.uk>
4473 * tools/gidlnode.c: (g_idl_node_can_have_member):
4474 Add g_idl_node_can_have_member.
4476 * tools/scanner.c: (g_igenerator_process_function_symbol):
4477 Use g_idl_node_can_have_member to test if we should add a function
4478 as a member of the type node.
4480 2008-02-18 Rob Taylor <rob.taylor@codethink.co.uk>
4482 * gidl/GLib.gidl: Renamed to gidl/gobject-2.0.gidl:
4484 * tests/parser/Makefile.am:
4485 Rename GLib.gidl to gobject-2.0.gidl and install in /usr/share/gidl.
4487 2008-02-18 Rob Taylor <rob.taylor@codethink.co.uk>
4489 * tools/scanner.c: (main):
4490 Ignore -pthread when passed to g-idl-scanner.
4492 2008-02-18 Rob Taylor <rob.taylor@codethink.co.uk>
4494 * tools/grealpath.h: Added:
4495 * tools/scanner.c: (main):
4496 * tools/scannerlexer.l:
4497 * tools/Makefile.am:
4498 Always use absolute paths with symbolic links resolved when
4499 comparing filenames.
4501 2008-02-18 Rob Taylor <rob.taylor@codethink.co.uk>
4503 * gobject-introspection.pc.in:
4504 Provide variables for g-idl-parser, scanner and compiler in the
4507 2008-02-13 Rob Taylor <rob.taylor@codethink.co.uk>
4510 * girepository/Makefile.am:
4511 * tools/Makefile.am:
4512 Rename GCOV_SOURCES to GCOVSOURCES to top automake complaining.
4514 2008-02-10 Johan Dahlin <johan@gnome.org>
4516 * tests/parser/Foo-expected.gidl:
4517 * tests/parser/foo-object.h:
4518 * tests/parser/foo.c: (foo_boxed_copy), (foo_boxed_free),
4519 (foo_boxed_get_type), (foo_boxed_new), (foo_boxed_method):
4522 2008-02-10 Johan Dahlin <johan@gnome.org>
4524 * tests/parser/Foo-expected.gidl:
4525 * tests/parser/foo-object.h:
4526 * tests/parser/foo.c: (foo_enum_get_type), (foo_flags_get_type):
4527 Add enum and flags test.
4529 2008-02-10 Johan Dahlin <johan@gnome.org>
4533 * girepository/Makefile.am:
4534 Make 'make distcheck' work again.
4536 2008-02-10 Johan Dahlin <johan@gnome.org>
4538 * m4/Makefile.am (EXTRA_DIST): its called as-compiler-flag.m4,
4541 * tests/parser/Makefile.am: Only create Foo.gidl when running make
4542 check, eg exclude it from BUILT_SOURCES.
4544 2008-02-08 Rob Taylor <rob.taylor@codethink.co.uk>
4549 * girepository/Makefile.am:
4550 * m4/Makefile.am: Added:
4551 * m4/as-compiler-flag.m4: Added:
4552 * m4/gcov.m4: Added:
4553 * tools/Makefile.am:
4554 Add ability to generate a coverage report.
4555 Adds configure option --enable-gcov and make rule 'check-coverage'.
4557 2008-02-08 Rob Taylor <rob.taylor@codethink.co.uk>
4561 * gidl/Makefile.am: Added:
4562 * girepository/Makefile.am: Added:
4563 * src/Makefile.am: Renamed to tools/Makefile.am:
4564 * src/compiler.c: Renamed to tools/compiler.c:
4565 * src/g-idl-offsets.pl: Renamed to tools/g-idl-offsets.pl:
4566 * src/generate.c: Renamed to tools/generate.c:
4567 * src/gidlmodule.c: Renamed to tools/gidlmodule.c:
4568 * src/gidlmodule.h: Renamed to tools/gidlmodule.h:
4569 * src/gidlnode.c: Renamed to tools/gidlnode.c:
4570 * src/gidlnode.h: Renamed to tools/gidlnode.h:
4571 * src/gidlparser.c: Renamed to tools/gidlparser.c:
4572 * src/gidlparser.h: Renamed to tools/gidlparser.h:
4573 * src/gidlwriter.c: Renamed to tools/gidlwriter.c:
4574 * src/gidlwriter.h: Renamed to tools/gidlwriter.h:
4575 * src/ginfo.c: Renamed to girepository/ginfo.c:
4576 * src/ginvoke.c: Renamed to girepository/ginvoke.c:
4577 * src/girepository.c: Renamed to girepository/girepository.c:
4578 * src/girepository.h: Renamed to girepository/girepository.h:
4579 * src/gmetadata.c: Renamed to girepository/gmetadata.c:
4580 * src/gmetadata.h: Renamed to girepository/gmetadata.h:
4581 * src/scanner.c: Renamed to tools/scanner.c:
4582 * src/scanner.h: Renamed to tools/scanner.h:
4583 * src/scannerlexer.l: Renamed to tools/scannerlexer.l:
4584 * src/scannerparser.y: Renamed to tools/scannerparser.y:
4585 * tests/invoke/Makefile.am:
4586 Split src/ into girepository/ and tools/
4590 * girepository/Makefile.am:
4591 * tests/Makefile.am:
4592 * tests/invoke/Makefile.am:
4593 * tests/parser/Makefile.am:
4594 * tests/roundtrips.sh:
4595 * tools/Makefile.am:
4596 Make distcheck work.
4598 2008-02-04 Rob Taylor <rob.taylor@codethink.co.uk>
4600 * tests/invoke/invoke.c: (main):
4601 * tests/invoke/testfns.c: (test6), (test7):
4602 * tests/invoke/testfns.xml:
4603 Add tests for invokation with a GList argument.
4604 Also tests caller-owns return values.
4606 2008-02-04 Rob Taylor <robtaylor@floopily.org>
4609 Add some documentation for GICallableInfo
4611 2008-02-01 Mark Doffman <mark.doffman@codethink.co.uk>
4614 Correct syntax errors in the DTD file.
4616 * relaxng/c-types.xml:
4617 * relaxng/g-types.xml:
4619 Add a RelaxNG specification for the GObject Introspection XML data.
4620 The Specification has validated all of the test files.
4622 2008-01-25 Rob Taylor <robtaylor@floopily.org>
4624 * tests/roundtrips.sh:
4625 * tests/struct.test:
4626 Add roundtrip tests for structs.
4628 2008-01-11 Johan Dahlin <johan@gnome.org>
4630 * src/scanner.c (g_igenerator_process_function_symbol):
4631 Refactor out g_idle_node_add_member.
4632 (create_node_from_gtype, create_node_from_ctype):
4633 Use case instead of if...else
4634 (get_type_from_type_id):
4635 Rename to create_node_from_gtype
4636 (get_type_from_ctype):
4637 Rename to create_node_from_ctype
4639 Rename ginode -> node, gitype -> type, gifunc -> func.
4641 * src/gidlnode.c (g_idl_node_add_member, g_idl_node_cmp):
4642 Two new functions, refactor out of scanner.c
4644 * src/scanner.c: (g_igenerator_process_function_symbol):
4645 * src/scannerlexer.l:
4646 Do not save the content of the deprecated variable, only
4649 2008-01-11 Johan Dahlin <johan@gnome.org>
4651 * tests/parser/foo-object.h: Add a couple of comment parser tests.
4653 2008-01-11 Jürg Billeter <j@bitron.ch>
4655 * src/scannerlexer.l:
4656 Fix GTK-Doc parsing.
4658 2008-01-11 Jürg Billeter <j@bitron.ch>
4660 * src/scannerlexer.l:
4661 Fix GTK-Doc parsing.
4663 2008-01-11 Jürg Billeter <j@bitron.ch>
4665 * src/scanner.c: (lookup_symbol):
4666 Return unresolved name if we find unknown symbol.
4668 2008-01-11 Jürg Billeter <j@bitron.ch>
4670 * src/scanner.c: (g_igenerator_generate):
4671 Initialize GObject to fix scanning interface properties.
4673 * tests/parser/Foo-expected.gidl:
4674 * tests/parser/foo-object.h:
4675 * tests/parser/foo.c: (foo_interface_get_type):
4676 Test interfaces with GObject prerequisite.
4678 * tests/parser/Makefile.am:
4679 Set G_DEBUG=fatal_warnings to abort test on warnings and criticals.
4681 2007-12-27 Johan Dahlin <johan@gnome.org>
4683 * src/scannerlexer.l:
4684 Parse gtk-doc comments.
4686 * src/gidlwriter.c: (function_generate):
4687 Reorganize, avoid duplication and add support for
4688 writing deprecated functions.
4690 * src/scannerparser.y:
4692 Add new structure CDirective and functions to create/free them.
4694 * src/scanner.c: (g_igenerator_process_function_symbol),
4695 (g_igenerator_process_unregistered_struct_typedef),
4696 (g_igenerator_process_struct_typedef),
4697 (g_igenerator_process_union_typedef),
4698 (g_igenerator_process_enum_typedef),
4699 (g_igenerator_process_function_typedef), (g_igenerator_add_symbol),
4700 (g_igenerator_start_preprocessor):
4701 Parse @deprecated directive for functions.
4702 Remove some more C99isms.
4703 Send in -C to cpp to avoid stripping comments.
4705 * tests/parser/foo-object.h:
4706 * tests/parser/Foo-expected.gidl:
4707 Add deprecated directive
4709 2007-12-27 Johan Dahlin <johan@gnome.org>
4711 * src/scannerlexer.l (intsuffix): Add emacs mode line and
4712 escape ' and " so it looks more like C.
4715 Unlink temporary file used.
4717 2007-12-27 Johan Dahlin <johan@gnome.org>
4719 * src/scanner.c: (g_igenerator_new), (g_igenerator_free),
4720 (g_igenerator_start_preprocessor), (main):
4722 * src/scannerparser.y:
4723 Plug a couple of simple memory leaks.
4725 2007-12-27 Johan Dahlin <johan@gnome.org>
4727 * src/scanner.c: (g_igenerator_parse_macros),
4728 (g_igenerator_start_preprocessor), (g_igenerator_set_verbose),
4731 * src/scannerparser.y:
4732 * tests/parser/Makefile.am:
4734 Improve error reporting, return when the preprocessor fails.
4735 Add a verbose parameter, to aid debugging.
4736 Revert to using a temporary file to communicate between the
4737 preprocessor and the parser, because we need to wait for
4738 the exit code from the pre-processor before starting to parse.
4740 2007-12-16 Johan Dahlin <jdahlin@async.com.br>
4742 * src/Makefile.am: Rename clexer.l to scannerlexer.l and
4743 cparser.y to scannerparser.y
4745 2007-12-11 Johan Dahlin <johan@gnome.org>
4749 * src/scanner.c: (g_igenerator_new):
4751 Get rid of the global the_generator variable.
4753 2007-12-10 Johan Dahlin <johan@gnome.org>
4755 * src/scanner.c (main): Add an output option,
4756 add checks for required parameters
4759 set BUILD_SOURCES and CLEANFILES properly
4761 * src/gidlwriter.c: (g_writer_write_inline), (g_writer_write),
4762 (g_writer_write_indent), (g_writer_write_unindent),
4763 (field_generate), (value_generate), (constant_generate),
4764 (property_generate), (function_generate), (vfunc_generate),
4765 (signal_generate), (interface_generate), (struct_generate),
4766 (union_generate), (boxed_generate), (enum_generate),
4767 (node_generate), (g_writer_write_module), (g_idl_writer_save_file):
4769 * src/scanner.c: (g_igenerator_generate):
4771 * src/scannerwriter.c:
4773 Refactor scannerwriter to only be tied to a GIdlModule and move
4774 it (again!) to gidlwriter.c. Change the writer function to take
4777 2007-12-10 Johan Dahlin <johan@gnome.org>
4780 * src/scanner.c: (g_igenerator_generate):
4782 * src/scannerwriter.c: (g_igenerator_write_inline),
4783 (g_igenerator_write), (g_igenerator_write_indent),
4784 (g_igenerator_write_unindent), (field_generate), (value_generate),
4785 (constant_generate), (property_generate), (function_generate),
4786 (vfunc_generate), (signal_generate), (interface_generate),
4787 (struct_generate), (union_generate), (boxed_generate),
4788 (enum_generate), (node_generate), (module_generate),
4789 (g_scanner_write_file):
4791 Move the scanner gidl writing to a separate source file.
4793 2007-12-10 Johan Dahlin <johan@gnome.org>
4798 Move over all CType construction functions.
4800 * tests/parser/Makefile.am:
4801 Be verbose when printing parsing tests results.
4803 2007-12-10 Johan Dahlin <johan@gnome.org>
4805 * src/scanner.c (g_igenerator_start_preprocessor): Refactor
4806 preprocessor handling to here. Start cpp insteado of cc -E,
4807 always include -U__GNUC__, since it's specific to the preprocessor
4810 * tests/parser/Makefile.am (check-local): Silent diff and skip
4811 -U__GNUC__ which is always defined now
4813 2007-12-10 Johan Dahlin,,, <jdahlin@plasttroll>
4815 reviewed by: <delete if not using a buddy>
4817 * src/scanner.c: (g_igenerator_start_preprocessor), (main):
4818 * tests/parser/Makefile.am:
4820 2007-12-09 Johan Dahlin <johan@gnome.org>
4823 Use GOption for command line options.
4824 (g_igenerator_new, main): Simplify constructor and they way
4825 parameters are passed into it.
4831 * src/gen-introspect.c:
4832 * src/gen-introspect.h:
4834 Rename gen-introspect.[ch] to scanner.[ch]
4836 2007-12-09 Johan Dahlin <johan@gnome.org>
4840 * src/Makefile.am: Rename gen-introspect to g-idl-scanner,
4841 don't make the repository library and the other utilites link against
4844 * src/gen-introspect.c: (g_igenerator_create_object),
4845 (g_igenerator_create_interface), (g_igenerator_create_boxed),
4846 (g_igenerator_create_enum), (g_igenerator_create_flags),
4847 (g_igenerator_process_module_symbol),
4848 (g_igenerator_process_module), (g_igenerator_generate), (main):
4849 * src/gen-introspect.h:
4850 Refactor g_igenerator_process_types into smaller pieces.
4852 * tests/parser/Makefile.am:
4853 Depend on the gen-introspect binary
4855 2007-12-09 Johan Dahlin <johan@gnome.org>
4857 * src/gen-introspect.c (g_igenerator_process_types):
4858 Break into smaller pieces, one for each generated node type.
4860 2007-12-08 Johan Dahlin <johan@gnome.org>
4862 * src/gen-introspect.c: (g_igenerator_process_types),
4863 (g_igenerator_add_module):
4864 * tests/parser/Foo-expected.gidl:
4865 * tests/parser/foo-object.h:
4866 * tests/parser/foo.c: (foo_subobject_class_init),
4867 (foo_subobject_init):
4869 Add a subobject test and make sure to register defined classes
4870 in the lookup symbol hash table.
4872 2007-12-08 Johan Dahlin <johan@gnome.org>
4876 * src/gen-introspect.c: (g_igenerator_new), (lookup_symbol),
4877 (g_igenerator_process_types), (g_igenerator_add_module),
4878 (g_igenerator_add_include_idl), (main):
4879 * src/gen-introspect.h:
4880 * tests/parser/Makefile.am:
4881 * tests/parser/Foo-expected.gidl:
4883 Change the gen-introspect to generate namespaced module names,
4884 such as GLib.Object instead of GObject.
4885 Add a GLib.gidl which introduces GLib.Object and GLib.InitiallyUnowned,
4886 add a --include-idl parameter to gen-introspect,
4887 and update the parser test.
4889 2007-12-08 Johan Dahlin <johan@gnome.org>
4891 * src/gen-introspect.c:
4892 Move main to the end of the file and attempt to make it valid
4895 * tests/parser/Makefile.am (BUILT_SOURCES): Remove .repo here,
4896 we're not quite ready to generate metadata yet.
4901 Add a simple gen-introspect parser test
4903 2007-12-06 Gustavo J. A. M. Carneiro <gjc@gnome.org>
4905 reviewed by: Johan Dahlin <johan@gnome.org>
4908 * gobject-introspection.pc.in:
4910 * src/compiler.c: (format_output), (write_out_metadata), (main):
4911 * src/gen-introspect.c: (main):
4912 * src/gen-introspect.h:
4913 * src/generate.c: (write_callable_info), (write_repository),
4914 (load_metadata), (main):
4915 * src/gidlmodule.c: (g_idl_module_new),
4916 (g_idl_module_build_metadata):
4918 * src/gidlparser.c: (start_element_handler):
4919 * src/ginfo.c: (g_info_new), (g_info_from_entry),
4920 (g_base_info_get_name), (g_base_info_get_namespace),
4921 (g_base_info_is_deprecated), (g_base_info_get_annotation),
4922 (g_base_info_get_metadata), (g_function_info_get_symbol),
4923 (g_function_info_get_flags), (g_function_info_get_property),
4924 (g_function_info_get_vfunc), (signature_offset), (g_type_info_new),
4925 (g_callable_info_may_return_null),
4926 (g_callable_info_get_caller_owns), (g_callable_info_get_n_args),
4927 (g_callable_info_get_arg), (g_arg_info_get_direction),
4928 (g_arg_info_is_return_value), (g_arg_info_is_dipper),
4929 (g_arg_info_is_optional), (g_arg_info_may_be_null),
4930 (g_arg_info_get_ownership_transfer), (g_type_info_is_pointer),
4931 (g_type_info_get_tag), (g_type_info_get_param_type),
4932 (g_type_info_get_interface), (g_type_info_get_array_length),
4933 (g_type_info_is_zero_terminated),
4934 (g_type_info_get_n_error_domains), (g_type_info_get_error_domain),
4935 (g_error_domain_info_get_quark), (g_error_domain_info_get_codes),
4936 (g_value_info_get_value), (g_field_info_get_flags),
4937 (g_field_info_get_size), (g_field_info_get_offset),
4938 (g_registered_type_info_get_type_name),
4939 (g_registered_type_info_get_type_init),
4940 (g_struct_info_get_n_fields), (g_struct_info_get_field),
4941 (g_struct_info_get_n_methods), (g_struct_info_get_method),
4942 (find_method), (g_struct_info_find_method),
4943 (g_enum_info_get_n_values), (g_enum_info_get_value),
4944 (g_object_info_get_parent), (g_object_info_get_type_name),
4945 (g_object_info_get_type_init), (g_object_info_get_n_interfaces),
4946 (g_object_info_get_interface), (g_object_info_get_n_fields),
4947 (g_object_info_get_field), (g_object_info_get_n_properties),
4948 (g_object_info_get_property), (g_object_info_get_n_methods),
4949 (g_object_info_get_method), (g_object_info_find_method),
4950 (g_object_info_get_n_signals), (g_object_info_get_signal),
4951 (g_object_info_get_n_vfuncs), (g_object_info_get_vfunc),
4952 (g_object_info_get_n_constants), (g_object_info_get_constant),
4953 (g_interface_info_get_n_prerequisites),
4954 (g_interface_info_get_prerequisite),
4955 (g_interface_info_get_n_properties),
4956 (g_interface_info_get_property), (g_interface_info_get_n_methods),
4957 (g_interface_info_get_method), (g_interface_info_find_method),
4958 (g_interface_info_get_n_signals), (g_interface_info_get_signal),
4959 (g_interface_info_get_n_vfuncs), (g_interface_info_get_vfunc),
4960 (g_interface_info_get_n_constants),
4961 (g_interface_info_get_constant), (g_property_info_get_flags),
4962 (g_signal_info_get_flags), (g_signal_info_get_class_closure),
4963 (g_signal_info_true_stops_emit), (g_vfunc_info_get_flags),
4964 (g_vfunc_info_get_offset), (g_vfunc_info_get_signal),
4965 (g_constant_info_get_value), (g_union_info_get_n_fields),
4966 (g_union_info_get_field), (g_union_info_get_n_methods),
4967 (g_union_info_get_method), (g_union_info_is_discriminated),
4968 (g_union_info_get_discriminator_offset),
4969 (g_union_info_get_discriminator):
4970 * src/ginvoke.c: (g_function_info_invoke):
4971 * src/girepository.c: (g_irepository_register),
4972 (g_irepository_unregister), (g_irepository_get_default),
4973 (count_interfaces), (g_irepository_get_n_infos), (find_interface),
4974 (g_irepository_get_info), (g_irepository_find_by_name),
4975 (g_irepository_get_shared_library),
4976 (g_irepository_build_search_path), (g_irepository_register_file),
4977 (g_irepository_error_quark):
4978 * src/girepository.h:
4979 * src/gmetadata.c: (g_metadata_get_dir_entry),
4980 (g_metadata_check_sanity), (validate_header),
4981 (validate_array_type_blob), (validate_iface_type_blob),
4982 (validate_param_type_blob), (validate_error_type_blob),
4983 (validate_type_blob), (validate_arg_blob),
4984 (validate_signature_blob), (validate_function_blob),
4985 (validate_callback_blob), (validate_constant_blob),
4986 (validate_value_blob), (validate_field_blob),
4987 (validate_property_blob), (validate_signal_blob),
4988 (validate_vfunc_blob), (validate_struct_blob),
4989 (validate_enum_blob), (validate_object_blob),
4990 (validate_interface_blob), (validate_errordomain_blob),
4991 (validate_union_blob), (validate_blob), (validate_directory),
4992 (validate_annotations), (g_metadata_validate), (_g_metadata_init),
4993 (g_metadata_new_from_memory), (g_metadata_new_from_const_memory),
4994 (g_metadata_new_from_mapped_file), (g_metadata_free),
4995 (g_metadata_set_module), (g_metadata_get_namespace):
4997 * tests/Makefile.am:
4998 * tests/invoke/Makefile.am:
4999 * tests/invoke/invoke-namespace-find.sh:
5000 * tests/invoke/invoke.c: (main):
5002 Add a namespace/shared library mapping. fixes #313268.
5004 2007-12-03 Johan Dahlin <johan@gnome.org>
5006 * src/gidlparser.c (parse_type_internal): Disable char/gchar and
5009 2007-11-30 Jürg Billeter <j@bitron.ch>
5015 * src/gen-introspect.c: (g_idl_node_cmp), (g_igenerator_new),
5016 (g_igenerator_write_inline), (g_igenerator_write),
5017 (g_igenerator_write_indent), (g_igenerator_write_unindent),
5018 (field_generate), (value_generate), (constant_generate),
5019 (property_generate), (function_generate), (vfunc_generate),
5020 (signal_generate), (interface_generate), (struct_generate),
5021 (union_generate), (boxed_generate), (enum_generate),
5022 (node_generate), (module_generate), (get_type_from_type_id),
5023 (str_replace), (g_igenerator_process_properties),
5024 (g_igenerator_process_signals), (g_igenerator_process_types),
5025 (get_type_from_ctype), (g_igenerator_process_function_symbol),
5026 (g_igenerator_process_unregistered_struct_typedef),
5027 (g_igenerator_process_struct_typedef),
5028 (g_igenerator_process_union_typedef),
5029 (g_igenerator_process_enum_typedef),
5030 (g_igenerator_process_function_typedef),
5031 (g_igenerator_process_constant), (g_igenerator_process_symbols),
5032 (g_igenerator_add_symbol), (g_igenerator_is_typedef),
5033 (g_igenerator_generate), (main), (csymbol_new),
5034 (csymbol_get_const_boolean), (ctype_new), (ctype_copy),
5035 (cbasic_type_new), (ctypedef_new), (cstruct_new), (cunion_new),
5036 (cenum_new), (cpointer_new), (carray_new), (cfunction_new),
5037 (eat_hspace), (eat_line), (read_identifier),
5038 (g_igenerator_parse_macros):
5039 * src/gen-introspect.h:
5041 Import gen-introspect to generate introspection information by
5044 2007-11-30 Jürg Billeter <j@bitron.ch>
5046 * src/gidlnode.c: (g_idl_node_new): support creating callback nodes
5048 2007-11-30 Jürg Billeter <j@bitron.ch>
5050 * src/gidlparser.c: (end_element_handler): Don't leave requires
5053 2007-11-29 Johan Dahlin <johan@gnome.org>
5055 * src/gidlparser.c (parse_type_internal): Add char,
5056 gchar and guchar to the builtin types.
5058 2007-11-26 Johan Dahlin <johan@gnome.org>
5060 * src/ginfo.c: (g_object_info_get_type_name),
5061 (g_object_info_get_type_init):
5062 * src/girepository.c: (g_irepository_is_registered):
5063 * src/girepository.h:
5065 Add g_object_info_get_type_name, g_object_info_get_type_init and
5066 g_irepository_is_registered.
5068 2006-08-14 Jürg Billeter <j@bitron.ch>
5070 * src/gidlparser.c: (end_element_handler): Don't leave
5071 namespace and implements states too early.
5074 2007-11-26 Johan Dahlin <johan@gnome.org>
5076 * src/gmetadata.c (validate_struct_blob):
5077 pass blob_type to validate_function_blob instead of
5078 hard-coding BLOB_TYPE_STRUCT.
5080 Patch by Torsten Schoenfeld, fixes #314190
5082 2006-10-03 Torsten Schoenfeld <tsch@cvs.gnome.org>
5084 * src/compiler.c, src/generate.c, src/gidlnode.c,
5085 src/gidlparser.c, src/ginfo.c, src/girepository.c,
5086 tests/invoke/invoke.c, test/invoke/testfns.c: Hush compiler
5087 warnings about return values, signedness mismatches, unused
5088 variables, and unhandles enum values in switch statements.
5090 * tests/invoke/Makefile.am: Don't install the invoke test program.
5091 Add -I ../../src to the cflags used for the test functions files.
5093 2005-08-31 Torsten Schoenfeld <tsch@cvs.gnome.org>
5095 * src/girepository.h: Export g_invoke_error_quark.
5097 2005-08-31 Torsten Schoenfeld <tsch@cvs.gnome.org>
5099 * src/ginvoke.c: Remove the fallback implementation of
5100 g_function_info_invoke since we now formally depend on libffi.
5102 2005-07-25 Matthias Clasen <mclasen@redhat.com>
5104 * src/Makefile, tests/Makefile, tests/invoke/Makefile:
5105 Remove these files from cvs, as they are now generated.
5107 * src/gmetadata.c (validate_iface_type_blob): Don't
5108 complain if blob->pointer is not set, since that
5109 happens for enum and flag types. (#308935, Gustavo
5112 * Commit an autoconf-conversion patch by
5113 Gustavo Carneiro (#308708)
5115 2005-05-24 Matthias Clasen <mclasen@redhat.com>
5117 * src/compiler.c (main): Use it here to validate
5118 the generated metadata.
5120 * src/gmetadata.[hc]: Add code to validate a
5123 * metadata-format.txt: Updates
5125 2005-05-22 Matthias Clasen <mclasen@redhat.com>
5127 * tests/*: Add struct offsets to field and vfunc
5130 * src/generate.c (write_vfunc_info): Write offset
5131 information for vfuncs.
5133 * src/gidlnode.c (g_idl_node_build_metadata): Write
5134 the struct offsets into the metadata.
5136 * src/gidlparser.c: Parse the offset attributes of
5137 field and vfunc elements.
5139 * src/gidlnode.h: Add offset members to field and
5142 2005-05-21 Matthias Clasen <mclasen@redhat.com>
5146 * gidl.dtd: Updates.
5148 * src/g-idl-offsets.pl: A perl script which reads a .gidl
5149 file, creates, compiles and runs a C file, and folds the
5150 resulting struct offsets back into the .gidl file.
5152 2005-05-20 Matthias Clasen <mclasen@redhat.com>
5154 * src/gidlparser.c (start_field): Make fields in objects
5157 * src/gidlmodule.c: Include string.h
5162 * metadata-format.txt: Cleanup basic types.
5163 * src/*: Adapt to the changes.
5164 * tests/*: Adapt to the changes.
5165 * examples/gdk-pixbuf.gidl: Adapt to the changes.
5167 * src/gidlnode.c (g_idl_node_get_size): Report the correct
5168 size for enum blobs.
5169 (g_idl_node_get_full_size): Report the correct size for
5172 * src/gidlmodule.c (g_idl_module_build_metadata): Add some
5173 error checking for blob sizes.
5175 2005-05-19 Matthias Clasen <mclasen@redhat.com>
5177 * src/gidlnode.c (g_idl_node_build_metadata): Correctly handle
5178 interface types for which is_pointer is FALSE, e.g. enums.
5180 * src/gidlnode.c (g_idl_node_get_full_size)
5181 * src/gidlparser.c (parse_type_internal):
5182 * src/generate.c (write_type_info): Support unspecialized
5183 lists, hashtables and errors. Also emit a '*' after these.
5187 2005-05-17 Matthias Clasen <mclasen@redhat.com>
5191 * metadata-format.txt: Cleanups by Maciej Katafiasz.
5193 2005-05-15 Matthias Clasen <mclasen@redhat.com>
5195 * src/*.c: Change the directory to be addressed by
5196 1-based indexes, and use an index of zero to mean
5199 2005-05-15 Matthias Clasen <mclasen@redhat.com>
5201 * tests/roundtrips.sh (SIMPLE_TESTS): Add union.test.
5203 * tests/union.test: Add a union test.
5205 * src/generate.c: Handle unions.
5207 * src/girepository.h:
5208 * src/ginfo.c: Add GIUnionInfo and functions to access it.
5210 * src/gidlnode.c: Handle GIdlNodeUnion nodes.
5212 * src/gidlparser.c (start_union): Parse <union> elements.
5214 * src/gidlnode.h: Add a GIdlNodeUnion.
5216 * gidl.dtd: Add a <union> element.
5218 * src/gmetadata.c (g_metadata_check_sanity): Check
5221 * src/gmetadata.h: Add union_blob_size to Header,
5224 * metadata-format.txt: Add a UnionBlob.
5226 2005-05-13 Matthias Clasen <mclasen@redhat.com>
5228 * tests/*: Update testcases.
5230 * src/generate.c (write_callable_info): Don't forget to
5231 write transfer and null-ok attributes for return types
5234 * src/girepository.h:
5235 * src/ginfo.c (g_callable_info_may_return_null):
5236 New function to find out if a function may return NULL.
5238 * src/compiler.c (format_output): Make the generated
5241 * README: Point to a recent libffi snapshot.
5243 * tests/invoke/*: Some invoke tests.
5245 * src/Makefile: Add ginvoke.c and the necessary
5248 * src/girepository.h (g_function_info_invoke): Add
5251 * src/ginvoke.c (g_function_info_invoke): Initial
5252 implementation of invoke functionality based on libffi.
5254 * src/gidlnode.c (g_idl_node_build_metadata): Pass the
5255 strings and types hash tables in the right order when
5257 (find_entry_node): Free the name parts.
5259 2005-05-12 Johan Dahlin <johan@gnome.org>
5261 * src/generate.c: Generate consistent end tags.
5265 2005-05-12 Matthias Clasen <mclasen@redhat.com>
5269 * src/gidlparser.c (start_function): Actually add
5270 methods to objects. (Steven Walter)
5272 * src/girepository.h:
5273 * src/ginfo.c: Rename Transfer and Direction to
5274 GITransfer and GIDirection. (Torsten Schoenfeld)
5276 * tests/*: Make tests work with the changes in name
5279 * src/gidlnode.c (find_entry_node): Parse qualified
5280 names and generate xref nodes for them if needed. Don't
5281 require all modules to be loaded any more.
5283 * src/gidlmodule.c (g_idl_module_build_metadata): Choke
5286 * src/ginfo.c (g_object_info_get_parent): Return NULL
5287 if blob->parent is 0. Still need to make sure index
5290 * src/generate.c: Generate qualified names when
5291 referring to non-local types. Emit transfer attribute
5294 * src/compiler.c (format_output): Put the function
5295 attributes where gcc accepts them.
5297 2005-05-11 Matthias Clasen <mclasen@redhat.com>
5299 * src/compiler.c (main): Add a --verbose cmdline option
5300 and only log messages if it is specified.
5303 * src/gidlnode.c (init_stats, dump_stats): Collect some
5304 statistics on string and type sharing.
5306 * src/gidlmodule.c (g_idl_module_build_metadata): Use
5307 g_message() instead of fprintf().
5309 * src/gidlnode.c (g_idl_node_free): Make this more robust.
5310 (g_idl_node_get_size): Implement for structs.
5311 (g_idl_node_get_full_size): Handle parent being NULL.
5312 (serialize_type): Handle lookup failures more gracefully.
5314 2005-05-10 Matthias Clasen <mclasen@redhat.com>
5316 * src/gidlnode.c (g_idl_node_get_full_size): Correct the
5317 size calculation for 2-parameter types and for objects.
5319 * src/compiler.c: Add a cmdline option for debug output
5320 and install a log handler to implement it.
5321 * src/gidlnode.c: Add some debug spew.
5325 * src/gidlmodule.c (g_idl_module_build_metadata): Don't
5326 forget to count the module name when calculating the
5327 required size for the metadata.
5330 * src/gidlparser.c: Fix compiler warnings.
5332 2005-05-09 Matthias Clasen <mclasen@redhat.com>
5334 * src/compiler.c (main): Free the option context.
5336 * gidl.dtd: Clean up handling of names. All elements
5337 have a "name", only the elements corresponding to
5338 actual callable functions (function, method, constructor),
5339 have an additional "symbol" attribute holding the
5340 dlsym()-able function name.
5342 * src/generate.c: Adapt to generate xml matching the
5346 * src/gidlnode.c: Adapt to parse the new dtd.
5348 * tests/*.test: Adjust to the new dtd.
5350 * metadata-format.txt:
5351 * src/gmetadata.h: Remove the short_name field
5353 * src/gmetadata.c: Shrink size of ValueBlob to 12.
5354 * src/girepository.h:
5355 * src/ginfo.c (g_value_info_get_short_name): Removed
5357 2005-05-09 Matthias Clasen <mclasen@redhat.com>
5359 * gidl.dtd: Allow constructors for boxed types,
5360 patch by Jonathan Blandford.
5363 2005-05-09 Matthias Clasen <mclasen@redhat.com>
5365 * --- Initial import ---