1 2008-11-18 Owen Taylor <otaylor@redhat.com>
3 Bug 561296 - Add "storage type" to the typelib data for enums
5 In order to set and get enum and flag fields in structures, we need
6 to know the integral type that the enumeration is stored as. We are already
7 computing that at compile time in order to compute struct offsets, so the
8 easiest thing to do is to save that in the typelib.
10 * docs/typelib-format.txt girepository/girnode.[ch] girepository/giroffsets.c
11 girepository/gtypelib.h: Add 'storage_type' to the typelib format for EnumBlob
12 and compute and save it at compile time.
14 * girepository/girepository.h girepository/ginfo.c:
15 Add g_enum_info_get_storage_type().
17 * girepository/gfield.c: Implement reading and writing enum and flags fields
18 based on the storage type.
20 2008-11-18 Owen Taylor <otaylor@redhat.com>
22 Add enums to the Everything test module
24 * tests/everything/everything.[ch]: Add TestEnum and TestFlags to the Everything
25 test module and register them as GTypes.
27 https://bugzilla.gnome.org/show_bug.cgi?id=561296
29 2008-11-18 Johan Dahlin <jdahlin@async.com.br>
31 * giscanner/cachestore.py:
32 Catch BadPickleGet exceptions as well.
34 2008-11-17 Owen Taylor <otaylor@redhat.com>
36 * tests/everything/everything.c: Fix doc comment annotations
37 for test_struct_b_clone() to refer to the right function.
39 2008-11-17 Dan Winship <danw@gnome.org>
41 * giscanner/glibtransformer.py (GLibTransformer.__init__): fix
42 spelling of GHashTable. #561135
44 * tests/scanner/annotation.c (annotation_object_get_hash):
45 * tests/scanner/annotation-1.0-expected.gir:
46 * tests/scanner/annotation-1.0-expected.tgir: add a test of
47 GHashTable annotations
49 2008-11-17 Andreas Rottmann <a.rottmann@gmx.at>
51 * giscanner/ast.py: Change string array match type to be in terms
52 of canonicalized type.
53 * giscanner/transformer.py: Add canonicalize_ctype which gives us
54 a version of a c:type without aliases, so we can deep canonicalize
55 char** to utf8*. Update parse_ctype to use it.
56 * tests/*: Add gtk_init like int*/char*** arg functions for testing.
58 2008-11-16 Colin Walters <walters@verbum.org>
60 * girepository/girepository.c: Ensure we always call init_globals,
61 even if passed a non-default repository.
63 2008-11-16 Colin Walters <walters@verbum.org>
65 Bug 559706 - Interface prerequisites
67 * common.mk: Dep on libgirepository.la for scanner libs so that
68 we rebuild things even if just gdump.c changes.
69 * girepository/gdump.c: Dump prerequisites.
70 * giscanner/ast.py: Add prerequisite list.
71 * giscanner/girparser.py: Parse them from gdump.
72 * giscanner/girwriter.py: Write them.
73 * giscanner/glibtransformer.py: Resolve them.
76 2008-11-16 Owen Taylor <otaylor@redhat.com>
78 Bug 561087 - Respect is_pointer in serialize_type()
80 Add a '*' to the serialization for the cases where we set is_pointer
81 in the type blob we write out depending on node->is_pointer. Don't
82 add the '*' in the cases where is_pointer is set or not set in a
85 http://bugzilla.gnome.org/show_bug.cgi?id=561087
87 2008-11-16 Owen Taylor <otaylor@redhat.com>
89 Bug 560825 – Add size and alignment to typelib
91 Include the size and alignment of structures and unions in the typelib,
92 and add getter methods to retrieve them from GIStructInfo/GIUnionInfo.
94 * docs/typelib-format.txt girepository/gtypelib.h girepository/girnode.c
95 girepository/girmodule.c girepository/gtypelib.c: Add size and alignment
96 to StructBlob and UnionBlob.
98 * girepository/ginfo.c girepository/girepository.h:
99 Add g_[struct|union]_get[size|alignment]().
101 * test/offsets/gen-gitestoffsets: Test overall structure size and alignment.
103 2008-11-16 Owen Taylor <otaylor@redhat.com>
105 Bug 552371 – implement struct field get/set
107 * girepository/gfield.c girepository/girepository.h: Add
108 convenience functions g_field_info_set_field() and
109 g_field_info_get_field() to set and get fields based on the
110 offsets in GIFieldInfo.
112 2008-11-16 Andreas Rottmann <a.rottmann@gmx.at>
114 Bug 560241 - Out-arguments should not be marked as being pointers
117 * girepository/girparser.c: Improved logic for out arguments.
119 2008-11-16 Andreas Rottmann <a.rottmann@gmx.at>
121 Bug 559601 - Pointers in structs/unions unduly treated as arrays
123 * giscanner/transformer.py: Differentiate type creation logic
124 between parameters and struct components.
126 2008-11-15 Colin Walters <walters@verbum.org>
128 * giscanner/dumper.py: Check return code from pkg-config
131 2008-11-14 Johan Dahlin <jdahlin@async.com.br>
133 * tests/everything/everything.c (test_array_int_in),
134 (test_array_gtype_in):
135 * tests/everything/everything.h:
136 Rename the int/gtype array tests. Make the return value
137 useful, an aggregation of the array input values.
139 2008-11-14 Johan Dahlin <jdahlin@async.com.br>
141 * tests/everything/Makefile.am:
142 * tests/everything/everything.c:
143 * tests/everything/everything.h:
144 * tests/everything/gitesttypes.c:
145 * tests/everything/gitesttypes.h:
146 Rename gitesttypes.[ch] to everything.[ch]
148 2008-11-13 Andreas Rottmann <a.rottmann@gmx.at>
150 Bug 560708 – Don't treat arrays that have a length specified as
151 zero-terminated by default
153 * giscanner/transformer.py: Default to non zero terminated for
155 * tests/*: Update, add test for zero vs not.
157 2008-11-13 Andreas Rottmann <a.rottmann@gmx.at>
159 Bug 557788 - Return types for constructors in generated typelib bogus
161 * girepository/girnode.c: Namespace-qualify XREFs; not doing so is
162 obviously broken in the face of duplicate names in different
164 * tests/scanner/*expected.gir: Fix up.
166 2008-11-13 Owen Taylor <otaylor@redhat.com>
168 * girepository/girffi.c: Fix "Unexpected time for time_t"
171 2008-11-13 Colin Walters <walters@verbum.org>
173 Bug 558436 - avoid having scanner load app code
175 * giscanner/cgobject.py: Delete; we no longer load shared
177 * giscanner/dumper.py: Support for linking a library to
178 a stub binary for introspection.
179 * giscanner/glibtransformer.py: Rewrite to use gdump XML
180 from invocation of child binary.
181 * giscanner/transformer.py: Fix up to use fully qualified
182 name in parse tree. Make parse_ctype public so we can use
183 it inside glibtransformer.
184 * tests/scanner/barapp.c: New test, using --program arg
186 * tests/*: Update to use common.mk for invoking scanner.
187 * tools/g-ir-scanner: Add options --program, --program-arg,
189 * docs/g-ir-scanner.1: Update.
191 2008-11-13 Colin Walters <walters@verbum.org>
193 * configure.ac: Depend on Gio, we use it in gdump.c.
194 * girepository/gdump.c: Code to dump GType data to XML.
195 * girepository/girepository.c: Add option group for dumping.
196 * girepository/girepository.h: Define API for the above.
198 2008-11-13 Colin Walters <walters@verbum.org>
200 * common.mk: Add a file to include with Makefile fragments
201 useful for scanner invocation.
203 2008-11-13 Tommi Komulainen <tommi.komulainen@iki.fi>
205 * tests/everything/gitesttypes.c (test_filename_return): Return
206 strings in filename encoding.
208 2008-11-13 Owen Taylor <otaylor@redhat.com>
210 Bug 560253 – Add structure and boxed types to Everything test module
212 * tests/everything/gitesttypes.[ch]: Add examples of:
214 Plain old data structs
215 Plain old data structs with nested fields
217 Plain old data boxed with nested fields
218 More complicated boxed types with internal state
220 2008-11-12 Johan Dahlin <jdahlin@async.com.br>
222 * tests/everything/gitesttypes.c (test_gtype_in):
223 * tests/everything/gitesttypes.h:
224 Add a test of GType arrays, a la gtk_list_store_set_columns.
226 2008-11-12 Owen Taylor <otaylor@redhat.com>
228 Bug 560419 – Cache includes when parsing
230 Keep track of all modules parsed within a GIrParser, and when a
231 module is referenced a second time, use the existing parsed copy
232 instead of reparsing.
234 2008-11-12 Owen Taylor <otaylor@redhat.com>
236 Fix management of ParseContext.includes_modules (#560419)
238 * girepository/girparser.c: Fix some trivial bugs in managing the
239 list of include modules. (Add to module's list twice, not
240 initialized to NULL, not freed.)
242 2008-11-12 Owen Taylor <otaylor@redhat.com>
244 Keep aliases and disguised_structures local to each module (#560419)
246 * girepository/girmodule.[ch]: When parsing, keep keep a separate
247 hash tables of aliases and 'disguised' flags for each module, and
248 store that on the module.
250 After parsing an include merge the aliases/disguised flags to the
253 * girepository/girparser.c: Remove 'prefix_aliases' flag and
254 always prefix aliases/disguised structure types when parsing; this
255 simplifies the code considerably.
257 2008-11-12 Owen Taylor <otaylor@redhat.com>
259 Fix mismatches between .gir name and 'name' attribute (#560419)
261 * tests/boxed.gir tests/constant.gir tests/enum.gir tests/invoke/invoke.c
262 tests/invoke/testfns-1.0.gir tests/object.gir tests/struct.gir: Fix places
263 where the 'name' element of <namespace/> didn't match the filename of the
264 gir, an assumption that the compiler has always expected and now enforces.
266 2008-11-12 Owen Taylor <otaylor@redhat.com>
268 Only allow one <namespace/> element per <repository/> (#560419)
270 * girepository/girparser.c: The logic in girparser.c didn't work
271 very well if there were multiple <namespace/> nodes within a
272 single <repository/> (context->namespace was always the overall
273 filename and not the the name specified in the <namespace/>
274 element for one thing; this would cause aliases to be mis-prefixed
275 in include modules.) Also check that the "name" in the
276 <namespace/> node matches the filename.
278 2008-11-12 Owen Taylor <otaylor@redhat.com>
280 Add a GirParser object to hold the state of a compilation
282 * girepository/girparser.[ch] tools/compiler.c: Add a toplevel
283 GirParser object to hold state that is global across a
284 compilation. Currently just holds the include path, but will
285 eventually also keep a cached list of parsed modules.
287 2008-11-12 Tommi Komulainen <tommi.komulainen@iki.fi>
289 * girepository/girepository.c (find_namespace_latest): Fix
292 2008-11-12 Tommi Komulainen <tommi.komulainen@iki.fi>
294 * configure.ac: use 'introspection' component for bugs
296 2008-11-12 Johan Dahlin <jdahlin@async.com.br>
298 * tests/everything/gitesttypes.c (test_filename_return):
299 * tests/everything/gitesttypes.h:
300 Add a filename return test.
302 2008-11-12 Tommi Komulainen <tommi.komulainen@iki.fi>
304 * tests/offsets/Makefile.am (gitestoffsets.c): fix
305 gen-gitestoffsets invocation with builddir != srcdir
307 2008-11-12 Johan Dahlin <jdahlin@async.com.br>
309 * girepository/girepository.c:
310 Change the element type from utf8 to filename
311 * girepository/girnode.c (g_ir_node_build_typelib):
312 Special case filename equally to utf8 here.
314 2008-11-12 Johan Dahlin <jdahlin@async.com.br>
317 Remove unused variables, add a dependency of girepository.ch, so when
318 they change we rebuild the gir automatically.
320 2008-11-12 Johan Dahlin <jdahlin@async.com.br>
322 * girepository/girepository.c (g_irepository_get_search_path):
323 * girepository/girepository.h:
324 Add a g_irepository_get_search_path, so we can access the search
327 2008-11-12 Johan Bilien <jobi@via.ecp.fr>
329 Bug 560474 – g-ir-compiler crashes when compiling the glib gir
331 * girepository/girparser.c: avoid freeing an uninitialized pointer
333 2008-11-12 Johan Dahlin <jdahlin@async.com.br>
336 * giscanner/glibtransformer.py:
337 * tools/g-ir-scanner:
338 Add a GIRepository-2.0.gir. Change the libtool lookup slightly
339 so we can just pass in --library=foo/bar/baz.la and the scanner
340 does the right thing.
341 Don't warn for _get_type() functions if they don't take any
344 2008-11-11 Owen Taylor <otaylor@redhat.com>
346 Bug 560404 – Prefix types when resolving aliases in included modules
348 * girepository/girparser.c: When resolving aliases in an included
349 module, prefix types before looking them up.
351 2008-11-11 Owen Taylor <otaylor@redhat.com>
353 Compute field offsets and overall size for object structures
355 Bug 560326 – Fails to build Gtk-2.0.typelib with "Unexpected non-pointer
356 field of type object in structure"
358 Do basic computation of field offsets for objects and interfaces;
359 this doesn't attempt to address all of the "mess" for virtual
360 functions described in Bug 560281.
362 2008-11-11 Tommi Komulainen <tommi.komulainen@iki.fi>
364 Bug 560308 – g-ir-compiler goes in infinite loop on Gdk-2.0.gir
366 Based on patch by Johan Bilien.
368 * giscanner/transformer.py (_create_member, _create_parameter):
369 Resolve types here as well.
370 (_resolve_type_name_1): Try resolving using 'ctype' first since
371 it's least ambiguous. Fixes struct member type resolution with
372 similarly named types, e.g. Gdk.PangoRendererClass and
374 * tests/scanner/foo*: Add test.
376 2008-11-11 Owen Taylor <otaylor@redhat.com>
378 * girepository/girparser.c: Search provided include dirs before
379 the default directories.
381 2008-11-11 Owen Taylor <otaylor@redhat.com>
383 * girepository/giroffsets.c: Include fully-qualified names in
386 2008-11-11 Owen Taylor <otaylor@redhat.com>
388 * girepository/giroffsets.c: Fail gracefully with an informative
389 error message when recursion is encountered when computing a
392 2008-11-11 Owen Taylor <otaylor@redhat.com>
394 * girepository/girparser.c: Remove an unused variable.
396 2008-11-10 Owen Taylor <otaylor@redhat.com>
398 Add tests for field offset computations
400 * tests/offsets/offsets.h: Header file with structure definitions to test
402 * tests/offsets/gen-gitestoffsets: Generate a C program that computes
403 field offsets for the structures in offsets.h two ways: using
404 the information from a generated typelib, and as computed by the
407 We diff these two versions to test that everything is OK.
409 2008-11-10 Owen Taylor <otaylor@redhat.com>
411 Remove field offsets from g-ir-generate output and test inputs
413 Field offsets are a) architecture dependent so they shouldn't be part
414 of the architecture-independent gir format which is installed in
415 datadir. b) Are architecture-dependent so they shouldn't be in test
418 * girepository/girparser.c: Don't parse offset for fields
419 * tools/generate.c: Don't parse offset for fields
420 * tests/*.gir test/scanner/*.tgir: Remove offsets
422 (Virtual function and discriminator offsets are not removed, as they
423 aren't fully hooked up to the field-offset computation machinery yet.)
425 2008-11-10 Owen Taylor <otaylor@redhat.com>
427 Bug 560252 - Compute field offsets before writing typelib
429 * girepository/girnode.h: Store the total size and alignment for
430 GIrNodeStruct/Boxed/Union.
432 * girepository/giroffset.c: New file implementing computation of
433 structure field offsets.
435 * girepository/girnode.c: Compute structure field offsets before
436 writing types into the typelib.
438 * docs/typelib-format.txt: Document that a field offset of 0xFFFF
439 means "unknown". Also fix description of the discriminator_offset
442 2008-11-10 Owen Taylor <otaylor@redhat.com>
444 Bug 560250 - Fully parse included modules
446 For some things, like computing structure offsets to put into the typelib
447 we need more than just the aliases from included modules. Do a completel
448 parse of included modules and store in module->included_modules.
450 Also add g_ir_find_node() to find node information from within the
451 active set of modules and their includes.
453 2008-11-10 Owen Taylor <otaylor@redhat.com>
455 Split g_ir_ffi_get_ffi_type() out from ginvoke.c
457 Extract a function to convert GITypeTag to ffi_type from the internals
458 of ginvoke.c. This will be useful in figure out structure alignment.
460 Also fix handling of gsize and time_t to be portable. (Add a check
461 to configure.ac to figure out the width of time_t.)
463 2008-11-10 Owen Taylor <otaylor@redhat.com>
465 Bug 560248 – "disguised structures"
467 Certain types like GIConv and GdkAtom are pointers internally but don't
468 look like pointers when referenced. They have the form.
470 typedef struct _X *X;
472 Parse these as structures/records but mark them in the gir with a 'disguised'
473 attribute so that we know that they need special handling.
475 In the typelib treat them like any other structure.
477 2008-11-09 Jürg Billeter <j@bitron.ch>
480 * giscanner/girwriter.py:
482 Write throws attribute for virtual functions, fixes bug 559703
484 2008-11-07 Johan Dahlin <jdahlin@async.com.br>
486 * giscanner/libtoolimporter.py (LibtoolImporter.find_module): Clear
487 up some confusion about the second argument to find_module, it's
488 actually the packages __path__ attribute which we can safely ignore
490 (LibtoolImporter.load_module): Set module.__loader__ as per PEP 302.
492 2008-11-07 Owen Taylor <otaylor@redhat.com>
494 Bug 559737 – Deal with continuations in macros
496 * giscanner/giscannerlexer.l: Treat continuation lines the same
497 as regular newlines. This makes the scanner not complain about
498 #define foo(x) \ <stuff> inside a C file. There's no attempt
499 however to handle parsing macro definitions split across lines.
501 2008-11-07 Johan Dahlin <jdahlin@async.com.br>
503 * giscanner/cachestore.py:
504 Handle broken cache entries, write only filesystems and
505 running out of diskspace.
507 2008-11-07 Owen Taylor <otaylor@redhat.com>
509 * giscanner/giscannermodule.c (pygi_source_scanner_lex_filename):
510 Set current_filename before lexing the file so error messages
511 are reported in the right file.
513 2008-11-06 Colin Walters <walters@verbum.org>
515 * tests/everything/*: Add some tests for strv.
517 2008-11-05 Colin Walters <walters@verbum.org>
519 * girepository/ginvoke.c (g_function_info_invoke): Don't use
520 nested scope local variable for error which may go away after
521 conditional is complete.
523 2008-11-05 Colin Walters <walters@verbum.org>
525 * giscanner/scannerlexer.l: Avoid static 256 char buf which we
526 manipulate hackily; just use GString. This avoids an
527 uninitialized memory read pointed out by Havoc.
529 2008-11-04 Johan Dahlin <jdahlin@async.com.br>
531 * giscanner/__init__.py:
533 * giscanner/cachestore.py:
534 * giscanner/cgobject.py:
535 * giscanner/girparser.py:
536 * giscanner/girwriter.py:
537 * giscanner/giscannermodule.c:
538 * giscanner/glibast.py:
539 * giscanner/glibtransformer.py:
540 * giscanner/libtoolimporter.py:
541 * giscanner/minixpath.py:
542 * giscanner/odict.py:
543 * giscanner/sourcescanner.c:
544 * giscanner/sourcescanner.h:
545 * giscanner/sourcescanner.py:
546 * giscanner/transformer.py:
547 * giscanner/utils.py:
548 * giscanner/xmlwriter.py:
550 Relicense the giscanner library under LGPLv2+.
551 This has been approved by all contributors.
553 2008-11-01 Owen Taylor <otaylor@redhat.com>
555 Bug 558848 giparser.py: shared library should be optional
557 When parsing a .gir, allow the shared-library attribute
558 of <namespace/> to be missing: this corresponds to the handling
559 in libgirepository and elsewhere.
561 2008-11-01 Tommi Komulainen <tommi.komulainen@iki.fi>
563 Bug 557898 – Fails to build on OSX 10.4
565 * configure.ac: Check for $shrext_cmds that should be implicitly
566 available if you're using libtool >= 2.0. If undefined, call
567 libtool --config explicitly to get its value.
568 * girepository/gtypelib.c: Remove special case for (non-)Darwin
571 2008-10-31 Colin Walters <walters@verbum.org>
573 * COPYING, COPYING.lib, COPYING.tools: Clarify licensing status.
575 2008-10-31 Johan Dahlin <jdahlin@async.com.br>
577 * configure.ac: Post release version bump
580 2008-10-31 Johan Dahlin <jdahlin@async.com.br>
584 * docs/release-checklist.txt:
587 2008-10-31 Johan Dahlin <jdahlin@async.com.br>
589 * Makefile.am: add an upload-release target
590 * docs/release-checklist.txt:
591 Release process documentation
593 2008-10-31 Colin Walters <walters@verbum.org>
595 Bug 558109 – _g_typelib_init fails to find shared libraries
597 * transformer/glibtransformer.py: Use ctypes' find_library
598 on passed libraries and write that for the shared-library
599 entry. We want to avoid depending on -devel packages.
601 2008-10-31 Johan Dahlin <jdahlin@async.com.br>
603 * docs/g-ir-scanner.1:
604 Document the renaming options.
606 2008-10-31 Tommi Komulainen <tommi.komulainen@iki.fi>
608 * giscanner/Makefile.am:
609 * tests/invoke/Makefile.am:
610 * tests/repository/Makefile.am: List in-tree libraries first in
611 LDADD / LIBADD. If installed library is listed first, the
612 resulting binary will prefer installed version to one in .libs,
613 possibly making 'make check' behave strangely.
615 2008-10-30 Tommi Komulainen <tommi.komulainen@iki.fi>
617 * giscanner/ast.py: map 'id' (ObjC) to 'any' type to stop
618 gir-repository from choking with gdk/quartz
620 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
622 * giscanner/giscannermodule.c (calc_attrs_length),
623 (pygi_collect_attributes):
624 * giscanner/xmlwriter.py:
625 Write a C version of the xml namespace formatter.
626 Saves 15% of the time it takes to create a gtk gir.
628 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
630 * giscanner/xmlwriter.py: Abstract attribute formatting
631 to a function external to the XMLWriter class.
633 * giscanner/scannerlexer.l:
634 Parse and discard __typeof and __attribute.
636 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
638 * giscanner/girparser.py:
639 Remove arguments from the constructor, move them to
640 separate accessors. Add a new parse_tree method
641 which takes an element tree instance.
642 * tools/g-ir-scanner:
643 Update callsite for this
645 * giscanner/Makefile.am:
646 * giscanner/cachestore.py:
647 * giscanner/transformer.py:
648 Cache the include parsing. Saves ~25% time when
649 creating vte (which includes everything up to gtk+).
651 2008-10-30 Colin Walters <walters@verbum.org>
653 * giscanner/transformer.py: Don't reparse includes
654 we've already processed.
656 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
658 * giscanner/girparser.py:
659 * giscanner/transformer.py:
660 Avoid parsing parameters, types etc when parsing
661 includes. Should speed up include parsing a bit.
663 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
665 * giscanner/girparser.py:
666 Avoid big if/else and use a dispatch table like
669 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
671 * giscanner/transformer.py:
672 Clean up include parsing and registration.
674 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
676 * giscanner/transformer.py:
679 2008-10-30 Johan Dahlin <jdahlin@async.com.br>
681 Bug 558383 – builddir != srcdir build fails if giscanner python module not already installed
684 construct PYTHONPATH just once
686 * tests/everything/Makefile.am:
687 * tests/scanner/Makefile.am:
688 add $(top_srcdir) to PYTHONPATH to
689 handle builddir != srcdir
691 * giscanner/libtoolimporter.py:
692 * giscanner/sourcescanner.py:
693 Make the libtoolimporter work when distchecking too.
695 Mostly based on patch by Tommi Komulainen
697 2008-10-29 Owen Taylor <otaylor@redhat.com>
699 * giscanner/glibtransformer.py: If a filename of an existing
700 file is passed to --library, hunt for it directly, rather than
701 searching for a corresponding library.
703 2008-10-29 Johan Dahlin <jdahlin@async.com.br>
705 * giscanner/libtoolimporter.py:
706 * giscanner/sourcescanner.py:
707 Clean up the libtool importer a bit. Add a context so we
708 can use it through a with statement.
709 Don't just look in the current directory, look in the whole
712 2008-10-29 Tommi Komulainen <tommi.komulainen@iki.fi>
714 Bug 558065 – gitesttypes should be installed
718 * tests/types/Makefile.am -> tests/everything/Makefile.am
719 * tests/types/gitesttypes.c -> tests/everything/gitesttypes.c
720 * tests/types/gitesttypes.h -> tests/everything/gitesttypes.h
721 move tests/types to tests/everything
723 * tests/everything/Makefile.am: build normal shared library
724 libgirepository-everything.so.1.0.0 and corresponding typelib
725 Everything-1.0.typelib
727 * tests/everything/Makefile.am: explicitly link libtool
728 versioning with typelib versioning with variables
730 2008-10-28 Johan Bilien <jobi@via.ecp.fr>
732 * tools/g-ir-scanner: add LD_LIBRARY_PATH to LPATH before calling ld.
734 2008-10-27 Johan Bilien <jobi@via.ecp.fr>
736 * gio/gio-2.0.c: add allow-none annotations, based on the pygobject
739 2008-10-27 Johan Bilien <jobi@via.ecp.fr>
741 Bug 558068 – when invoking a method, offset the in arguments by one,
744 * tests/invoke/invoke.c, tests/invoke/testfns.c,
745 tests/invoke/testfns-1.0.gir: Add testing of method and constructor.
746 * girepository/ginvoke.c: do not offset the index of given out
747 arguments by one for methods, "this" is provided as in argument only.
749 2008-10-27 Johan Bilien <jobi@via.ecp.fr>
751 * gir/gio-2.0.c: add annotation for g_file_delete
753 2008-10-27 Tommi Komulainen <tommi.komulainen@iki.fi>
755 Bug 558062 – provide and use paths in the .pc file
757 * gobject-introspection-1.0.pc.in: provide typelibdir variable
758 for where .typelibs should be installed (callers shouldn't need
759 to construct paths from bits and pieces)
761 2008-10-25 Andreas Rottmann <a.rottmann@gmx.at>
763 Bug 557791 – g_irepository_require() could return a GTypelib *
765 * girepository/girepository.c: Return GTypelib; this is useful
766 for low level manipulation.
768 2008-10-25 Colin Walters <walters@verbum.org>
770 Bug 557788 – Return types for constructors in generated typelib bogus
772 * giscanner/glibtransformer.py: Don't resolve ctors incrementally,
773 rely on end pass resolution.
775 2008-10-25 Andreas Rottmann <a.rottmann@gmx.at>
777 Bug 557786 - support fixed size arrays
779 * girepository/ginfo.c: Add g_type_info_get_array_fixed_size.
780 * giscanner/scannerparser.y: Retain fixed array size.
781 * giscanner/ast.py: Add to note.
782 * giscanner/girwriter.py: Write to gir.
783 * girepository/girnode.c: Write it to typelib.
784 * tools/generate.c: Generate.
785 * tests/*: Add tests.
787 2008-10-25 Colin Walters <walters@verbum.org>
789 Bug 557076 - move typelibs to $libdir
791 * configure.ac: Steal some configury bits from dbus to expand
793 * gir/Makefile.am: Move to libdir.
794 * girepository/girepository.c: Stop searching XDG_DATA_DIRS;
795 instead just look at one hardcoded path in libdir.
796 * acinclude.m4: Bits from dbus.
798 2008-10-24 Johan Dahlin <johan@gnome.org>
800 * girepository/girnode.c (g_ir_node_check_unhandled_members):
801 Be quiet, do not warn about unhandled members.
803 2008-10-24 Johan Dahlin <johan@gnome.org>
805 * girepository/gtypelib.c:
806 Only use SHLIB_SUFFIX on darwin, otherwise use
807 G_MODULE_SUFFIX, we cannot get shext_cmds from libtool 2.2.
809 2008-10-24 Lucas Rocha <lucasr@gnome.org>
811 Bug 557623 - Constructors shouldn't be flagged as methods.
813 * girepository/ginfo.c (g_function_info_get_flags): ditto.
815 2008-10-24 Johan Dahlin <johan@gnome.org>
817 * giscanner/scannerparser.y:
818 Check against division by zero for the modula operator.
819 This fixes header parsing of OSX system headers included
822 2008-10-24 Johan Dahlin <johan@gnome.org>
826 Add a CONTRIBUTORS file and dist it.
828 2008-10-23 Tommi Komulainen <tommi.komulainen@iki.fi>
830 Bug 556739 – transfer-ownership attribute should be mandatory in .gir
832 * girepository/girparser.c (parse_param_transfer):
833 * giscanner/transformer.py (_create_parameter, _create_return):
834 * giscanner/girwriter.py (_write_return, _write_parameter):
835 * tools/generate.c (write_callable_info): always write and
836 require "transfer-ownership" for return-values and parameters
839 * tests/invoke/testfns-1.0.gir:
841 * tests/scanner/DrawableAdditions.xml:
842 * tests/scanner/GtkFrob-1.0-expected.tgir:
843 * tests/scanner/annotation-1.0-expected.tgir:
844 * tests/scanner/drawable-1.0-expected.tgir:
845 * tests/scanner/drawable-injected-1.0-expected.gir:
846 * tests/scanner/drawable-injected-1.0-expected.tgir:
847 * tests/scanner/foo-1.0-expected.tgir: Updated
849 2008-10-23 Tommi Komulainen <tommi.komulainen@iki.fi>
851 * giscanner/cgobject.py: build fundamental types same way as glib
853 * giscanner/glibtransformer.py (_type_from_gtype): record GType
854 when constructing the Type from it
856 * giscanner/glibtransformer.py (_adjust_transfer): Check whether
857 the parameter is a GObject from its GType, if available.
859 * giscanner/glibtransformer.py (_adjust_transfer):
860 * tests/scanner/foo-1.0-expected.gir:
861 * tests/scanner/foo-1.0-expected.tgir: deduce
862 transfer-ownership from GTypes
864 2008-10-23 Tommi Komulainen <tommi.komulainen@iki.fi>
866 * giscanner/transformer.py (_create_parameter):
867 * tests/scanner/foo-1.0-expected.gir: make varargs
868 transfer-ownership="none"
870 2008-10-23 Colin Walters <walters@verbum.org>
872 Bug 556739 - transfer ownership
874 * giscanner/ast.py: Refactor Parameter/Return to share
875 common attributes. Add transfer_inferred attribute
876 which says whether or not we made a guess.
877 * giscanner/transformer.py: Add much more extensive
878 heuristics around parameter and return transfer.
879 * giscanner/glibtransformer.py: Adjust to inspect
883 2008-10-22 Tommi Komulainen <tommi.komulainen@iki.fi>
885 Bug 557377 – Add test to ensure annotations survive the roundtrip via typelib
887 * tests/scanner/Makefile.am:
888 * tests/scanner/annotation-1.0-expected.tgir:
889 * tests/scanner/drawable-1.0-expected.tgir:
890 * tests/scanner/drawable-injected-1.0-expected.tgir:
891 * tests/scanner/foo-1.0-expected.tgir:
892 * tests/scanner/GtkFrob-1.0-expected.tgir:
893 * tests/scanner/utility-1.0-expected.tgir: Add test to ensure
894 annotations survive the roundtrip via typelib
896 The expectations are as currently produced by g-ir-generate,
897 comparison with the .gir files shows there are differences.
899 2008-10-23 Johan Bilien <jobi@via.ecp.fr>
901 Bug 557468 – Support for GI_TYPELIB_PATH
903 * girepository/girepository.c: if the GI_TYPELIB_PATH is set, add the
904 provided paths to the global search path.
906 2008-10-22 Tommi Komulainen <tommi.komulainen@iki.fi>
908 Bug 557379 – g-ir-generate not writing the 'abstract' attribute
910 * tests/scanner/drawable-1.0-expected.tgir:
911 * tests/scanner/drawable-injected-1.0-expected.tgir:
912 * tests/scanner/foo-1.0-expected.tgir:
913 * tools/generate.c (write_object_info): write 'abstract'
914 attribute for classes
916 2008-10-22 Lucas Rocha <lucasr@gnome.org>
918 * girepository/girmodule.c, girepository/gtypelib.c,
919 girepository/girparser.[ch]: fix some build warnings.
921 2008-10-22 Tommi Komulainen <tommi.komulainen@iki.fi>
923 Bug 557405 – Use 'allow-none' consistently
925 * docs/typelib-format.txt:
926 * girepository/ginfo.c (g_arg_info_may_be_null):
927 * girepository/girnode.c (g_ir_node_build_typelib):
928 * girepository/girnode.h (struct _GIrNodeParam):
929 * girepository/girparser.c (start_parameter):
930 * girepository/girwriter.c (function_generate):
931 * girepository/gtypelib.h (ArgBlob):
933 * tests/function.gir:
934 * tools/generate.c (write_callable_info): Use 'allow-none'
935 consistently throughout
937 2008-10-22 Tommi Komulainen <tommi.komulainen@iki.fi>
939 Bug 557092 – Callback annotations not used
941 * giscanner/transformer.py (_create_callback): use annotations
943 * tests/scanner/annotation.h
944 * tests/scanner/annotation-1.0-expected.gir: add tests
946 2008-10-21 Colin Walters <walters@verbum.org>
948 * giscanner/scannerlexer.l: Don't require trailing whitespace after
949 uncommented parameters.
952 2008-10-21 Colin Walters <walters@verbum.org>
954 * girepository/girepository.c: Ensure that when doing an unversioned
955 require, we prefer items earlier in the search path to later ones.
957 2008-10-21 Owen Taylor <otaylor@redhat.com>
959 * giscanner/transformer.py: For string parameters allow transfer annotation
960 to override the standard automatic guessing based on 'const'.
962 2008-10-21 Johan Bilien <jobi@via.ecp.fr>
964 Bug 557241 – "throws" flag for functions
966 * tests/scanner/drawable-1.0-expected.gir,
967 tests/scanner/drawable-injected-1.0-expected.gir,
968 tests/scanner/drawable.[ch]: add simple test for throwing
969 function (has GError ** as last argument)
971 * giscanner/ast.py: add a 'throws' flag to Function
972 * giscanner/glibtransformer.py: if a function's last paramerter is
973 a GError, set the 'throws' flag and remove that parameter
974 * giscanner/girwriter.py: write out the 'throws' attribute
975 * giscanner/girparser.py: support parsing the 'throws' attribute
977 * tests/repository/gitestthrows.c: add a simple test to check the
978 throws flag in a typelib and invoke the function
980 * girepository/ginfo.c, girepository/girnode.[ch],
981 girepository/girnode.h, girepository/girparser.c,
982 girepository/girepository.h: Add and parse the GI_FUNCTION_THROWS flag
984 * girepository/ginvoke.c: if a function throws, add a GError as last
985 arguments, and propagate the error to the invoker.
987 2008-10-21 Tommi Komulainen <tommi.komulainen@iki.fi>
989 * giscanner/transformer.py (_create_parameters): Warn if we see
990 annotations for unknown parameters. If .h and .c files name
991 parameters differently, the annotations may be lost.
993 2008-10-21 Johan Dahlin <johan@gnome.org>
995 Bug 556358 - don't use libtool internals
997 * giscanner/Makefile.am:
998 * giscanner/libtoolimporter.py:
999 * giscanner/sourcescanner.py:
1000 * giscanner/utils.py:
1001 Add a python meta importer and remove a libtool symlink hack.
1003 2008-10-20 Andreas Rottmann <a.rottmann@gmx.at>
1005 * tests/scanner/Makefile.am (%.typelib): Set PYTHONPATH
1006 and --add-include-path appropriately when invoking the scanner.
1007 * tests/types/Makefile.am (%typelib): Likewise.
1009 2008-10-20 Colin Walters <walters@verbum.org>
1011 Bug 556777 - validate properties
1013 * giscanner/transformer.py: Add option to throw on unknown types.
1014 * giscanner/glibtransformer.py: Use it on properties.
1015 * tests/*: Add a test.
1017 2008-10-20 Colin Walters <walters@verbum.org>
1019 * giscanner/glibast.py: Also register g variants of
1020 default_array_types. This is not beautiful, but
1021 good alternatives aren't easy to come by.
1022 This fixes gchar ** parsing.
1024 2008-10-20 Colin Walters <walters@verbum.org>
1026 * docs/typelib-format.txt, girepository/gtypelib.h:
1027 Take a bit from ObjectInfo to represent abstract flag.
1028 * giscanner/cgobject.py: Expose g_type_get_flags.
1029 * girepository/girepository.h: Add accessor.
1030 * girepository/ginfo.c: Implement it.
1031 * giscanner/ast.py: Add is_abstract flag to generic
1033 * giscanner/glibast.py: Use it.
1034 * giscanner/girwriter.py: Write it.
1035 * girepository/girparser.c: Parse it.
1038 2008-10-20 Tommi Komulainen <tommi.komulainen@iki.fi>
1040 * giscanner/girparser.py (_parse_function): don't lose
1041 'transfer-ownership' attributes when injecting, check for the
1044 2008-10-19 Johan Dahlin <johan@gnome.org>
1046 * giscanner/scannerlexer.l: Parse and ignore __asm.
1048 2008-10-19 Colin Walters <walters@verbum.org>
1050 * giscanner/girparser.py: Parse array length= to ensure
1051 it doesn't get lost from --inject.
1053 2008-10-17 Colin Walters <walters@verbum.org>
1055 Bug 556795 - char ** regression
1057 * giscanner/transformer.py: Fix parsing of ctypes, add some
1058 comments about what's going on.
1059 * tests/*: Add a test for char **.
1061 2008-10-17 Colin Walters <walters@verbum.org>
1063 Bug 556783 - change namespace handling to be more consistent
1065 * giscanner/transformer.py: Eliminate usage of
1066 strip_namespace_object. We now treat --namespace as the default
1067 --strip-prefix; however, if --strip-prefix is specified it
1068 overrides --namespace. This applies to everything except function
1069 names, where we do also strip the namespace.
1070 * giscanner/glibtransformer.py: Remove usage of
1071 strip_namespace_object.
1073 * tests/*: Add skeletal GtkFrob-1.0 test which has different
1074 --namespace and --strip-prefix.
1076 2008-10-17 Tommi Komulainen <tommi.komulainen@iki.fi>
1078 Bug 556732 – generate gir files consistently
1080 * girepository/girparser.c (start_parameter):
1082 * tests/invoke/testfns-1.0.gir:
1083 * tools/generate.c (write_callable_info): write
1084 'transfer-ownership' attribute consistently with both
1085 return-value and parameter elements
1087 2008-10-17 Tommi Komulainen <tommi.komulainen@iki.fi>
1089 Bug 556732 – generate gir files consistently
1091 * tools/generate.c (write_callable_info): write 'direction'
1092 attribute only if other than 'in' to be consistent with
1095 * tests/object.gir: remove direction="in" which is the default
1097 2008-10-17 Tommi Komulainen <tommi.komulainen@iki.fi>
1099 Bug 556732 – generate gir files consistently
1101 * giscanner/ast.py (Field): add readable and writable properties
1102 * giscanner/girparser.py (_parse_field): copy 'readable' and
1103 'writable' attributes
1104 * giscanner/transformer.py (_create_member): create fields as
1106 * giscanner/glibtransformer.py (_introspect_object,
1107 _pair_class_struct): make object instance and class fields
1109 * giscanner/girwriter.py (_write_field):
1110 * tools/generate.c (write_field_info): write field 'readable'
1111 and 'writable' attributes only if non-default (read-only)
1112 * girepository/girparser.c (start_field): in the absence of
1113 attributes assume fields are read-only
1115 * tests/struct.gir: remove redundant readable="1" from fields
1116 * tests/scanner/foo-1.0-expected.gir:
1117 * tests/scanner/utility-1.0-expected.gir: add writable="1" to
1118 all record and union fields
1120 2008-10-17 Tommi Komulainen <tommi.komulainen@iki.fi>
1122 Bug 556732 – generate gir files consistently
1124 * giscanner/girwriter.py (_write_property): write properties
1125 'construct' attribute if set
1126 * tools/generate.c (write_property_info): write properties
1127 'readable' and 'writable' attributes only if non-default
1128 * tests/object.gir: add writable="0"
1129 * tests/scanner/foo-1.0-expected.gir: add construct="1"
1131 2008-10-17 Johan Bilien <jobi@via.ecp.fr>
1133 * gir/glib-2.0.c: added annotations
1135 2008-10-16 Johan Bilien <jobi@via.ecp.fr>
1137 * giscanner/ast.py: Also assume direction=out for size_t*, ssize_t*
1140 2008-10-16 Johan Bilien <jobi@via.ecp.fr>
1142 Bug 556610 – giscanner/girparser.py drops parameter options
1144 * tests/scanner/drawable-injected-1.0-expected.gir,
1145 tests/scanner/DrawableAdditions.xml: added simple test for injection.
1146 * giscanner/ast.py: allow Parameter to take options in the constructor
1147 * giscanner/girparser.py: parse parameter options (transfer,
1148 direction, allow-none)
1150 2008-10-16 Colin Walters <walters@verbum.org>
1152 Bug 556185 - segfault on g_callable_info_get_return_type
1154 Initial patch from John Ehresman.
1156 * tests/repository/*: Add a test using
1157 g_callable_info_get_return_type. Instead of casting a
1158 GITypeInfo directly to a GIRegisteredTypeInfo, we need
1159 to call g_type_info_get_interface.
1161 2008-10-16 Colin Walters <walters@verbum.org>
1163 Bug 556579 - union and struct name misresolved
1165 * giscanner/transformer.py: The calls to _resolve_type_name
1166 for struct/union names was a legacy holdover from when type
1167 resolution had multiple phases. Now it's actively harmful
1168 since we might pull in an identical name from another
1172 2008-10-16 Colin Walters <walters@verbum.org>
1174 Bug 556432 - transfer annotations and defaults
1176 * giscanner/transformer.py: Canonicalize type
1177 after removing *, not before. This ensures that
1178 guchar* is transformed to 'uint8'.
1179 Add some comments here.
1180 * giscanner/glibtransformer.py: Add _adjust_transfer
1181 phase for tweaking GObject transfers.
1184 2008-10-16 Tommi Komulainen <tommi.komulainen@iki.fi>
1186 * configure.ac: enable bunch of gcc warning CFLAGS
1188 2008-10-16 Tommi Komulainen <tommi.komulainen@iki.fi>
1190 Bug 556543 – reduce compiler warnings
1192 * girepository/ginfo.c:
1193 * girepository/girepository.c (register_internal,
1194 count_interfaces, find_interface, find_namespace_version,
1195 parse_version, g_irepository_require):
1196 * girepository/girmodule.c (g_ir_module_build_typelib):
1197 * girepository/girnode.c (init_stats, dump_stats,
1198 _g_irnode_init_stats, _g_irnode_dump_stats,
1199 g_ir_node_can_have_member):
1200 * girepository/girparser.c (firstpass_end_element_handler,
1201 locate_gir, parse_basic, parse_type_internal, resolve_aliases,
1202 start_alias, start_type, end_type_top, parse_include, cleanup,
1204 * girepository/gtypelib.c (validate_function_blob, validate_enum_blob):
1205 * giscanner/giscannermodule.c (directive_get_options,
1206 type_get_child_list):
1207 * giscanner/scannerlexer.l (parse_gtkdoc):
1208 * giscanner/scannerparser.y (ctype_free):
1209 * giscanner/sourcescanner.c:
1210 * giscanner/sourcescanner.h (gi_source_scanner_parse_macros):
1211 * tests/types/gitesttypes.c:
1212 * tools/compiler.c (main):
1213 * tools/generate.c (write_repository): Remove unused variables
1214 and code, add missing includes, declarations and case
1217 2008-10-16 Tommi Komulainen <tommi.komulainen@iki.fi>
1219 Bug 556541 – access union members through UnionBlob rather than
1222 * girepository/ginfo.c (g_union_info_find_method): access union
1223 members through UnionBlob rather than StructBlob
1225 2008-10-15 Colin Walters <walters@verbum.org>
1227 Bug 556331 - clean up includes handling
1229 * tools/g-ir-scanner: Rework command line arguments; now we take
1230 --add-include-path and --include separately.
1231 * giscanner/girwriter.py: Separate name= and version= in include
1233 * giscanner/ast.py: Add Include type.
1234 * giscanner/transformer.py: Cleanups to register_include now that
1235 we don't need to handle mixed filenames and relative arguments.
1236 * girepository/girparser.c: Parse name and version separately;
1237 this fixes a bug as a side effect where we weren't resolving
1238 through aliases for basic types.
1239 * girepository/girepository.c: Fix format string args.
1240 * gir/Makefile.am: Update.
1243 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1245 Bug 556434 – unhandled interface/object/... member types
1247 * girepository/girnode.c (g_ir_node_check_unhandled_members,
1248 g_ir_node_build_typelib): Check all
1249 interface/object/boxed/struct/union members are processed and
1250 abort if they are not. (Mostly callbacks in structs, but also
1251 fields in interfaces.)
1253 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1255 * a/girepository/girnode.c (g_ir_node_build_members,
1256 g_ir_node_build_typelib): refactor common code for processing
1257 members to a function
1259 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1261 * gir/Makefile.am (check-local): check that typelib -> gir -> typelib
1262 transformation is lossless (it's not)
1264 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1266 * tests/Makefile.am: fix tests to compare xml to xml instead of
1267 typelib to xml, and stop on error
1269 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1271 * tools/generate.c (write_type_name, write_type_info,
1272 write_type_info, write_object_info, write_object_info,
1273 write_interface_info, write_error_domain_info): reduce code
1276 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1278 Bug 556174 – parse types for lists etc.
1280 * girepository/girparser.c (end_type_recurse):
1282 * tools/generate.c (write_type_info, write_field_info,
1283 write_callable_info, write_callable_info, write_constant_info,
1284 write_property_info): use nested <type>s for lists and hashes
1286 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1289 * tests/object.gir: remove trailing whitespace from inside
1290 elements to match g-ir-generate output
1292 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1294 * tools/generate.c (xml_printf): quote printf arguments so that
1295 we don't generate invalid XML by writing unescaped double quotes
1296 and such in attributes
1298 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1300 * tools/generate.c (write_field_info, write_callable_info,
1301 write_function_info, write_callback_info, write_struct_info,
1302 write_constant_value, write_signal_info, write_vfunc_info,
1303 write_object_info, write_interface_info, write_union_info,
1304 write_repository): remove unused indent parameters, xmlwriter
1305 keeps track of necessary indentation
1307 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1309 * tools/generate.c (xml_element_new, xml_element_free,
1310 xml_start_element, xml_end_element, xml_end_element_unchecked,
1311 xml_open, xml_close): Keep track of generated XML tree and
1312 handle indentation and closing tags properly.
1313 (write_field_info, write_callable_info, write_function_info,
1314 write_callback_info, write_struct_info, write_value_info,
1315 write_constant_info, write_enum_info, write_signal_info,
1316 write_vfunc_info, write_property_info, write_object_info,
1317 write_interface_info, write_error_domain_info, write_union_info,
1318 write_repository): Use xml_start_element and xml_end_element to
1321 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1323 * tools/generate.c (xml_printf, xml_open, xml_close, xml_free):
1324 (write_type_name, write_type_info, write_field_info,
1325 write_callable_info, write_function_info, write_callback_info,
1326 write_struct_info, write_value_info, write_constant_value,
1327 write_constant_info, write_enum_info, write_signal_info,
1328 write_vfunc_info, write_property_info, write_object_info,
1329 write_interface_info, write_error_domain_info, write_union_info,
1330 write_repository): wrap all FILE access to go through simple xmlwriter
1332 2008-10-15 Tommi Komulainen <tommi.komulainen@iki.fi>
1334 Bug 556400 – Fails to build on OS X 10.4
1336 * configure.ac: check for functions backtrace and backtrace_symbols
1337 * girepository/girparser.c (backtrace_stderr): Comment out
1338 implementation if the functions are not available.
1339 * gcov.mak (clean-gcov, clean-gcno): always call 'find' with a
1340 directory for better portability
1342 2008-10-15 Johan Bilien <jobi@via.ecp.fr>
1344 Bug 556433 – assume direction = out for int * parameters
1346 * giscanner/ast.py: define a list of types for which, if passed as
1347 reference, we assume a default direction of 'out'
1348 * giscanner/transformer.py: if a type has type pointer to one of the
1349 previously defined types, and no direction is set, assume out.
1350 * tests/scanner/drawable.[ch]: added tests for guessed direction=out
1352 2008-10-15 Johan Bilien <jobi@via.ecp.fr>
1354 * tests/scanner/annotation.c: fixed a few copy-paste errors
1356 2008-10-14 Johan Bilien <jobi@via.ecp.fr>
1358 Bug 556323 – transfer-ownership is wrong for functions returning const
1361 * giscanner/transformer.py: check for a const string as return value,
1362 not just const char*. Suggested by Colin Walters
1363 * tests/scanner/annotation-1.0-expected.gir: updated expected output
1365 2008-10-14 Johan Bilien <jobi@via.ecp.fr>
1367 * girepository/ginfo.c, girepository/girepository.h: add
1368 g_union_info_find_method
1370 2008-10-14 Colin Walters <walters@verbum.org>
1372 * tests/repository/Makefile.am: Reenable repo test.
1373 * tests/repository/gitestrepo.c: Prepend search
1374 path for $(top_builddir)/gir dir so that we don't
1375 require installation for "make check" to pass.
1377 2008-10-13 Jürg Billeter <j@bitron.ch>
1379 * giscanner/glibtransformer.py:
1380 * tests/scanner/annotation-1.0-expected.gir:
1381 * tests/scanner/drawable-1.0-expected.gir:
1382 * tests/scanner/foo-1.0-expected.gir:
1383 * tests/scanner/utility-1.0-expected.gir:
1385 Support fields in GObject structs
1387 2008-10-13 Jürg Billeter <j@bitron.ch>
1389 * giscanner/ast.py: add signed integer and off_t to type_names
1391 2008-10-12 Jürg Billeter <j@bitron.ch>
1393 * giscanner/girparser.py: Parse bits attribute of fields
1395 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1397 * tests/repository/Makefile.am: run 'gitestrepo' in 'make check'
1398 * tests/repository/gitestrepo.c (main): instantiate
1399 'GCancellable' to ensure the GType is registered before using
1402 2008-10-12 Johan Bilien <jobi@via.ecp.fr>
1404 * giscanner/girparser.py: actually add the parsed constant nodes
1406 2008-10-12 Colin Walters <walters@verbum.org>
1408 * girepository/girepository.c: Don't cast DirEntry to Blob,
1409 actually look it up by offset.
1411 2008-10-12 Johan Bilien <jobi@via.ecp.fr>
1413 * giscanner/girparser.py: parse constant nodes in gir files
1415 2008-10-12 Johan Bilien <jobi@via.ecp.fr>
1417 * giscanner/transformer.py: prefix for constants have an underscore,
1418 so remove them as if they were functions, not objects.
1420 2008-10-12 Johan Bilien <jobi@via.ecp.fr>
1422 * tests/scanner/foo-1.0-expected.gir: add constants to expected gir
1425 2008-10-12 Colin Walters <walters@verbum.org>
1427 Initial patch from Jani Monoses.
1429 * girepository/gtypelib.c: Fix inverted test for success
1432 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1434 * tools/generate.c (write_callable_info): use "transfer-ownership"
1435 attribute for return values
1437 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1439 * tools/generate.c (write_callable_info): move "transfer" and
1440 "null-ok" attributes from <function> to <return-value> element
1442 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1444 * girepository/girparser.c (start_return_value): handle
1445 "transfer-ownership" attribute
1447 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1449 * girepository/girparser.c (parse_param_transfer):
1450 * tools/generate.c (write_callable_info): use "container" for
1451 container/shallow ownership transfer (not "shallow")
1453 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1455 * girepository/girparser.c (parse_param_transfer,
1456 start_parameter): Refactor handling of transfer=none/shallow/full
1457 to separate function
1459 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1461 Bug 556048 – Crash in g_irepository_find_by_gtype
1463 * girepository/gtypelib.h (BLOB_IS_REGISTERED_TYPE): added
1464 * girepository/girepository.c (find_interface): Fix
1465 find_by_gtype case to get the type name from right offset
1467 2008-10-12 Jürg Billeter <j@bitron.ch>
1469 * giscanner/girparser.py: Fix parsing transfer-ownership attribute
1472 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1474 * girepository/gtypelib.h (RegisteredTypeBlob): make
1475 'unregistered' one bit wide as everywhere else
1477 2008-10-12 Jürg Billeter <j@bitron.ch>
1479 * giscanner/glibtransformer.py:
1480 * tests/scanner/annotation-1.0-expected.gir:
1481 * tests/scanner/drawable-1.0-expected.gir:
1482 * tests/scanner/drawable.h:
1483 * tests/scanner/foo-1.0-expected.gir:
1484 * tests/scanner/utility-1.0-expected.gir:
1486 Readd class records as workaround to not break Gtk typelib
1488 2008-10-12 Tommi Komulainen <tommi.komulainen@iki.fi>
1490 * tests/types/Makefile.am: fix typo in gitesttypes namespace
1492 2008-10-12 Jürg Billeter <j@bitron.ch>
1494 * giscanner/glibtransformer.py: Don't generate <record> elements
1496 * tests/scanner/*: Update test cases
1498 2008-10-11 Colin Walters <walters@verbum.org>
1500 Bug 552858: versioning
1502 This is a big patch. You should probably remove your installation
1505 * docs/typelib-format.txt: Add nsversion entry which holds
1506 version of namespace.
1507 * girepository/girepository.h: Add 'version' parameter to
1508 g_irepository_require. This may be NULL. Normally
1509 bindings should pass an explicit version though.
1510 * girepository/girepository.c: Lots of infrastructure to
1511 support versioning. Add some more documentation. Disallow
1512 some usage of NULL namespaces.
1513 * girepository/girmodule.c: Add version parameter.
1514 * girepository/gtypelib.c: Update header size.
1515 * giscanner/ast.py: Add version to Namespace.
1516 * giscanner/girparser.py: Parse version attribute from
1517 XML, pass to Namespace.
1518 * giscanner/girwriter.py: Write out version parameter.
1519 * giscanner/transformer.py: Clean up include registration.
1520 * tests/*: Add version attribute.
1521 * tests/invoke/invoke.c: Don't try looking up test before
1522 it's loaded in repository.
1523 * tools/generate.c: Output version parameter.
1524 * gir/Makefile.am: Add 2.0 version to .gir files.
1526 2008-10-11 Colin Walters <walters@verbum.org>
1528 * giscanner/scannerlexer.l (parse_gtkdoc): Don't lose
1529 if we have mismatched parens.
1531 2008-10-11 Lucas Rocha <lucasr@gnome.org>
1533 * giscanner/girparser.py (_parse_enumeration_bitfield): fix typo
1534 on 'members' variable.
1536 2008-10-11 Colin Walters <walters@verbum.org>
1538 Bug 555947 - update annotations syntax
1540 * giscanner/ast.py: Default to None for transfer. Remove
1541 default transfers for container types; we require this to
1543 * giscanner/girwriter.py: Transfer is now 'none', 'container',
1544 'full' to match repository.
1545 * giscanner/scannerlexer.l: Annotations now are parenthesized.
1546 * giscanner/transformer.py: Update for new annotations syntax.
1549 2008-10-11 Johan Bilien <jobi@litl.com>
1551 * giscanner/scannerparser.y: ignore non-UTF-8 string constants
1553 2008-10-11 Johan Bilien <jobi@litl.com>
1555 Bug 552347: Parse #defines constants
1557 * girepository/gtypelib.c: update the list of value_size
1558 with recently defined type tags
1559 * giscanner/scannerparser.y: brought back parsing of #defined, as
1560 present in older version
1561 * giscanner/giscannermodule.c: bind gi_source_scanner_append_filename
1562 * giscanner/girwriter.py: write out constant tags in the gir
1563 * giscanner/sourcescanner.py: add accessor for const_string
1564 * giscanner/transformer.py, giscanner/glibtransformer.py: handle
1567 2008-10-11 Tommi Komulainen <tommi.komulainen@iki.fi>
1569 Bug 555946: Install a test module exercising all types, transfer
1574 * tests/types/*: Add and install a test module that has functions
1575 accepting and returning most of the basic types to enable bindings
1576 implementors to more easily test their type conversion routines.
1578 2008-10-11 Jürg Billeter <j@bitron.ch>
1580 Bug 552374: Const strings should be identified in the gir.
1582 * giscanner/transformer.py: support string memory management
1583 * tests/scanner/foo.h: use char * and const char *
1584 * tests/scanner/foo-expected.gir: test that
1586 2008-10-11 Johan Dahlin <johan@gnome.org>
1588 * giscanner/girparser.py:
1589 Also parse enums which are not glib types.
1591 2008-10-11 Lucas Rocha <lucasr@gnome.org>
1593 Bug 552370: add one more test for unsigned as a type, not as
1596 * giscanner/ast.py: add 'uint' type name for 'unsigned'.
1597 * test/scanner/foo.h: add function which uses unsigned as a type.
1598 * test/scanner/foo-expected.gir: test that.
1600 2008-10-11 Andreas Rottmann <a.rottmann@gmx.at>
1602 Bug 555712: Struct and union issues
1604 * giscanner/scannerparser.y (struct_declarator): Use information
1605 provided about the bit width of a field.
1606 * giscanner/transformer.py (Transformer._create_member): Pass the
1607 symbol's const_int member to the created field (it represents the
1609 * giscanner/girwriter.py (GIRWriter._write_field): Output 'bits'
1610 field attribute, if present.
1611 * giscanner/ast.py (Field): Add 'bits' member, specifying the
1612 width in bits of the field (only relevant for bitfields).
1615 * giscanner/transformer.py (Transformer._create_typedef_struct)
1616 (Transformer._create_typedef_union): Add calls to _create_struct()
1617 and _create_union(), respectively. This causes the scanner to
1618 generate output for fields of struct and union typedefs.
1621 2008-10-11 Jürg Billeter <j@bitron.ch>
1623 Bug 552370: unsigned not scanned properly
1625 * giscanner/scannerparser.y: combine basic types such as unsigned
1626 int and long long when scanning
1627 * tests/scanner/foo-expected.gir:
1628 * tests/scanner/foo.c: (foo_test_unsigned):
1629 * tests/scanner/foo.h: test that
1631 2008-10-11 Lucas Rocha <lucasr@gnome.org>
1633 Bug 554854: The --typelib-xml and --inject options should reuse
1634 giscanner parser/writer.
1636 * giscanner/ast.py: add constructor list to Struct and Union.
1637 Add new param in Return's contructor to define transfer.
1638 * giscanner/girparser.py: several additions to the parser in order
1639 to have parsing all nodes of the gir xml files.
1640 * tools/g-ir-scanner (typelib_xml_strip, inject): use gir parser
1641 and writer in --inject and --typelib-xml options.
1642 * giscanner/xmlwriter.py: ignore empty attributes instead of
1643 raising an error as this basically exposes a bug in GIRParser.
1644 This should be reverted as soon as the parser is fixed.
1646 2008-10-11 Lucas Rocha <lucasr@gnome.org>
1648 Bug 552376: scanner generates wrong names for enum members when
1649 there's no defined gtype.
1651 * giscanner/utils.py (strip_common_prefix): Always strip common
1652 prefix exactly up to the last "_", and not beyond.
1653 * tests/scanner/foo.h (FooEnumNoType): add FOO_ENUM_NEUF. The point
1654 here is that the first character after the last '_' should should be
1655 the same as the character in the same position on the type name.
1656 * tests/scanner/foo-expected.gir: test that
1658 2008-10-10 Lucas Rocha <lucasr@gnome.org>
1660 Bug 555293: append library_paths to LPATH env variable to work
1661 around a bug in find_library when using ldconfig.
1663 * tools/g-ir-scanner (main): ditto.
1665 2008-10-09 Lucas Rocha <lucasr@gnome.org>
1667 * girepository/girepository.c (register_internal): fix regression on
1668 invoke test case by making sure we load the global module in the
1669 typelib when dealing with inline typelibs.
1670 * girepository/gtypelib.c: a couple of coding style fixes.
1672 2008-10-06 Lucas Rocha <lucasr@gnome.org>
1674 Bug 555294: Add support for multiple shared libraries per typelib.
1676 * girepository/ginvoke.c (g_function_info_invoke),
1677 girepository/ginfo.c(g_registered_type_info_get_g_type): use
1678 g_typelib_symbol instead of g_module_symbol.
1679 * girepository/girepository.h: remove g_typelib_set_module and add
1681 * girepository/gtypelib.[ch] (find_some_symbol, _g_typelib_init,
1682 g_typelib_new_from_memory, g_typelib_new_from_const_memory,
1683 g_typelib_free, g_typelib_symbol): chnage GTypeLib to hold a list of
1684 modules instead of just one. The symbol lookup is now abstracted
1685 behind g_typelib_symbol which tries to find the passed symbol name in
1687 * giscanner/girwriter.py, tools/g-ir-scanner: change scanner to read
1688 and write shared_library attribute as a comma-separated list of libs.
1690 2008-10-06 Colin Walters <walters@verbum.org>
1692 * giscanner/transformer.py: Parse length= annotation as
1693 a parameter name, not a raw int.
1696 2008-10-03 Colin Walters <walters@verbum.org>
1698 Bug 551744: Non-GObject types aren't aggregating ctors and methods
1700 * girepository/gtypelib.c: Allow ctors/methods on struct,union,
1702 * giscanner/glibtransformer.py: Ditto, and GLibBoxed is also a
1706 2008-10-03 Colin Walters <walters@verbum.org>
1708 Bug 554576: scan problem with ev_selection_render_selection()
1710 * giscanner/transformer.py: Only do type resolution once we've
1711 scanned all types. What could happen before is that we'd strip
1712 the namespace from local type "EvSelection" => Selection, and
1713 then later pull a "Selection" from some other namespace because
1714 we hadn't yet seen the local EvSelection. This could come
1715 down to hash table ordering and other things so not easy
1716 to write a test for.
1718 2008-10-03 Lucas Rocha <lucasr@gnome.org>
1720 * giscanner/girwriter.py (_parser_member): fix the last parameter of
1721 GLibEnumMember constructor as it should be the enum member nick.
1723 2008-10-02 Colin Walters <walters@verbum.org>
1725 Bug 552961: remove this parameter for methods
1727 * giscanner/glibtransformer.py: Delete this parameter; it is
1729 * girepository/ginvoke.c: Insert this parameter for methods.
1730 * girepository/gtypelib.c: Remove no longer needed verification of
1731 method this parameter.
1734 2008-09-30 Dan Winship <danw@gnome.org>
1736 Bug 554490: g-ir-scanner gets confused by '\\'
1738 * giscanner/scannerlexer.l (chartext, stringtext): fix use of
1739 backslashes so it will correctly parse '\\' and "\\"
1741 * tests/scanner/annotation.c: add a use of '\\' to make sure that
1744 * giscanner/glibtransformer.py (GLibTransformer.count_type): typo
1746 2008-10-02 Colin Walters <walters@verbum.org>
1748 bug 552393: Note variadic functions
1750 * giscanner/scannerparser.y: Parse ellipsis. Refactor grammar
1751 to use parameter_list directly.
1752 * giscanner/sourcescanner.h: Add ellipsis csymbol type.
1753 * giscanner/ast.py: Add Varargs type.
1754 * giscanner/transformer.py: Check for ellipsis symbol, transform
1756 * girepository/girnode.h: Add varargs flag to in-memory nodes.
1757 Parse varargs functions, but filter them out before we start
1758 compiling the typelib.
1760 2008-10-02 Colin Walters <walters@verbum.org>
1762 Bug 554632: type tag for GType
1764 * girepository/girepository.h, girepository/girepository.c:
1765 Add type tag for GType - it's a special type we don't want
1766 to resolve to just "long".
1767 * docs/typelib-format.txt: Update.
1768 * girepository/girparser.c: Parse it.
1769 * giscanner/glibtransformer.py: Ensure we don't put GType in
1771 * tools/generate.c: Remove hardcoded type list.
1774 2008-09-30 Dan Winship <danw@gnome.org>
1776 Bug 554521: scanner generates wrong names for enum members with
1777 full type name prefix
1779 * giscanner/utils.py (strip_common_prefix): Fix this to strip the
1780 right amount when the entire "first" string is a prefix of
1783 * tests/scanner/foo.h (FooEnumFullname):
1784 * tests/scanner/foo-expected.gir: test that
1786 2008-09-29 Colin Walters <walters@verbum.org>
1788 Bug 552380: Array parameters should be marked in the gir
1790 * giscanner/ast.py: Default char** to utf8[], and guchar* to
1791 uint8[]. Add Array, List, and Map subclasses of Type;
1792 these types can be generic. Return transfer defaults
1793 to true if return value is string or container type.
1794 Delete Sequence type.
1795 * giscanner/scannerlexer.l: Syntax change for annotations;
1796 use <> since it's more readable.
1797 * giscanner/girwriter.py: Write out these changes.
1798 * giscanner/girparser.py: Parse them.
1799 * giscanner/transformer.py: Have a defined set of
1800 both list and map types. When creating a type,
1801 check if the ctype we've parsed is one of them,
1802 if so create a container type subclass as appropriate.
1803 * girepository/girparser.c: Parse in generic types.
1806 2008-09-27 Colin Walters <walters@verbum.org>
1808 * tools/g-ir-scanner: Add --inject option.
1810 2008-09-25 Colin Walters <walters@verbum.org>
1812 Remove non-repository types from GIR
1814 * giscanner/ast.py: The canonical name is 'utf8', not
1816 * giscanner/glibast.py: A few more glib type mappings.
1817 * girepository/girparser.c: We only parse repository types.
1818 * tests/*.gir: Update.
1820 2008-09-23 Colin Walters <walters@verbum.org>
1822 Bug 552566: Add time_t type
1824 We need a type for time_t since it's special in C, and just
1825 mapping it to long precluded bindings from handling it
1828 2008-09-19 Colin Walters <walters@verbum.org>
1830 Bug 552390: Handle capitialization like "DBus" more robustly
1832 The to_underscores function was designed for use against prefixed
1833 names; we need a separate function which will convert names like
1834 DBusFoo into dbus_foo, not d_bus_foo.
1836 2008-09-19 Colin Walters <walters@verbum.org>
1838 Add check to make sure we're not hitting out unresolved types
1840 Validate the "this" argument for methods
1842 Remove heuristic matching of methods to classes based on prefix
1844 It was a broken hack that dated from when we handled underscoring
1845 and capitalization conventions less well.
1847 2008-09-18 Colin Walters <walters@verbum.org>
1849 Bug 552384: Use SHLIB_SUFFIX intead of G_MODULE_SUFFIX for Darwin
1851 On Darwin, the suffix for installed shared libraries (.dylib) is
1852 different from loadable modules (.so). We use a bit of magic shell
1853 script from Behdad Esfahbod to figure out the right suffix.
1855 2008-09-15 Johan Dahlin <johan@gnome.org>
1857 * giscanner/sourcescanner.py (SourceType.type_qualifier): Add
1858 a wrapper for type_qualifier as well.
1860 2008-09-15 Colin Walters <walters@verbum.org>
1862 http://bugzilla.gnome.org/show_bug.cgi?id=552065
1864 * giscanner/ast.py: Add deprecation attributes.
1865 * giscanner/girwriter.py: Write out deprecation data.
1866 * girepository/girparser.c: Relax parsing; deprecated
1867 attribute now includes freeform string.
1868 * giscanner/scannerlexer.l: Parse Deprecated.
1869 * giscanner/transformer.py: Look for deprecated attribute
1871 * tests/scanner/*: Add a Deprecated test.
1873 2008-09-14 Tor Lillqvist <tml@novell.com>
1875 * tests/scanner/Makefile.am (%.typelib): Use $(EXEEXT).
1877 2008-09-14 Colin Walters <walters@verbum.org>
1879 * giscanner/glibtransformer.py: Ignore functions with
1882 2008-09-12 Colin Walters <walters@verbum.org>
1884 * giscanner/glibtransformer.py: Accept Gtk.Type as GType.
1886 2008-09-12 Colin Walters <walters@verbum.org>
1888 * giscanner/ast.py: Bind pid_t to INT for vte.
1890 2008-09-12 Colin Walters <walters@verbum.org>
1892 * giscanner/girparser.py: Parse c:type for boxed records/unions.
1893 * giscanner/glibast.py: Avoid overwriting ctype.
1894 * giscsanner/transformer.py: Try resolving types using the GType names.
1896 2008-09-12 Colin Walters <walters@verbum.org>
1898 * giscanner/minixpath.py: Code to run an "XPath"
1899 assertion against an XML tree, taken from
1900 gir-repository/gir/tests.py.
1901 * giscanner/Makefile.am: Ship it.
1902 * tools/g-ir-scanner: Add --xpath-assertions option.
1903 * gir/GLib-assertions.txt: Add a few assertions.
1904 * gir/Makefile.am: Run them.
1906 2008-09-11 Colin Walters <walters@verbum.org>
1908 http://bugzilla.gnome.org/show_bug.cgi?id=551737
1910 * giscanner/transformer.py: Fix strip_namespace_func to only strip
1911 prefix if it ends with _. Tweak callback stripping to determine
1912 based on presence of _ whether we need to use strip_namespace_func
1913 or strip_namespace_object.
1915 2008-09-09 Owen Taylor <otaylor@redhat.com>
1917 * docs/typelib-format.txt: Wether => Whether
1919 2008-09-08 Colin Walters <walters@verbum.org>
1921 * girepository/girparser.c: Default to "readable" for properties.
1922 * giscanner/ast.py: Add readable, writable etc.
1923 * giscanner/girwriter.py: Writ them.
1924 * giscanner/glibtransformer.py: Inspect them.
1927 2008-09-07 Colin Walters <walters@verbum.org>
1929 * giscanner/cgobject.py: Add comment.
1931 2008-09-07 Colin Walters <walters@verbum.org>
1933 * giscanner/cgobject.py: Also call g_thread_init.
1935 2008-09-07 Colin Walters <walters@verbum.org>
1937 * giscanner/transformer.py: Fix regression by not
1938 stripping prefix before stripping namespace for unions
1941 2008-09-06 Colin Walters <walters@verbum.org>
1943 * giscanner/transformer.py: If a namespace contains
1944 multiple caps, try stripping both gnomekeyring_ and
1947 2008-09-07 Johan Dahlin <johan@gnome.org>
1949 Bug 551162 – giscanner does not recognize asm and __asm__
1950 * giscanner/scannerlexer.l:
1951 Patch by Jani Monoses.
1953 2008-09-06 Colin Walters <walters@verbum.org>
1955 * girepository/girnode.c: Allow gtype_name
1956 and gtype_init in struct and union.
1957 * girepository/girparser.c: Parse glib:
1958 boxed bits for both structure and union.
1959 * girepository/gtypelib.c: Don't barf
1960 if structure is boxed.
1961 * giscanner/girparser.py: Parse new XML
1963 * giscanner/girwriter.py: Write out new
1965 * giscanner/glibast.py: Define new classes
1966 which are both Boxed and Struct/Union, as
1967 well as an "Other" for everything else.
1968 * giscanner/glibtransformer.py: Handle
1969 boxed types specially; we try to merge
1970 them with a struct/union if one exists,
1971 otherwise fall back to generic boxed.
1973 * tools/generate.c: Write out new format.
1975 2008-09-06 Johan Dahlin <johan@gnome.org>
1977 * giscanner/grealpath.h: Include stdlib.h
1979 * docs/g-ir-generate.1: Remove leading %
1981 2008-09-01 Colin Walters <walters@verbum.org>
1983 * girepository/girparser.c: Look at c:type to determine
1984 whether or not an item is a pointer.
1986 2008-09-01 Johan Dahlin <johan@gnome.org>
1988 * tests/scanner/Makefile.am:
1989 Set PYTHONPATH so the scanner can run
1990 even if you didn't install anything.
1992 2008-09-01 Johan Dahlin <johan@gnome.org>
1995 Post-release version bump
1998 2008-09-01 Johan Dahlin <johan@gnome.org>
2002 2008-08-31 Colin Walters <walters@verbum.org>
2004 * giscanner/glibtransformer.py: Quiet info
2007 2008-08-31 Johan Dahlin <johan@gnome.org>
2010 Bump version to 0.5.0
2012 2008-08-31 Colin Walters <walters@verbum.org>
2014 * giscanner/glibtransformer.py: Follow aliases to ensure
2015 we don't get a constructor returning a basic type.
2016 * giscanner/transformer.py: Add function to follow aliases.
2019 2008-08-31 Johan Dahlin <johan@gnome.org>
2021 * giscanner/scannerlexer.l:
2022 * giscanner/scannerparser.y:
2023 * giscanner/sourcescanner.h:
2024 * giscanner/sourcescanner.py:
2025 Parse GCC extensions in the parser instead of just undeffing them
2026 in the pre-processor.
2028 2008-08-31 Johan Dahlin <johan@gnome.org>
2030 * giscanner/glibtransformer.py:
2031 Clean up a huge if. Do not add methods or constructors
2033 * giscanner/utils.py:
2034 second might be longer than first, check that.
2036 2008-08-31 Johan Dahlin <johan@gnome.org>
2041 2008-08-31 Colin Walters <walters@verbum.org>
2043 * girepository/girparser.c: Don't lose if we
2046 2008-08-31 Colin Walters <walters@verbum.org>
2048 * giscanner/glibtransformer.py: Look for libtool
2049 library in current directory
2050 * tests/scanner - Update.
2052 2008-08-30 Colin Walters <walters@verbum.org>
2054 * docs/typelib-format.txt: Add a guint32
2056 * gir/Makefile.am: Dep on Makefile
2057 * girepository/ginfo.c:
2058 * girepository/girepository.c: Clean up
2059 default typelib handling; remove global
2060 default_typelib variable. Ensure we handle
2061 NULL repository in more places.
2062 Support dependency resolution.
2063 Support lazy loading.
2064 * girepository/girepository.h: Remove
2065 g_irepository_unregister; we don't support
2066 unloading typelibs since really they're
2067 process-global. Update for lazy loading
2069 * girepository/girmodule.c: Use g_new0.
2070 Add dependencies to GirModule.
2071 * girepository/girparser.c: Parse dependencies.
2072 * girepository/gtypelib.c: Add 4 bytes for
2074 * tests/Makefile.am: Kill off gobject.gir,
2075 it conflicts with the real one.
2076 * tests/object.gir: Dep on GObject.
2077 * tools/generate.c: Take --includedir
2078 argument to say which directories to search
2079 for typelibs. Print out dependencies.
2081 2008-08-30 Colin Walters <walters@verbum.org>
2083 * giscanner/glibtransformer.py: Reduce warning noise.
2085 2008-08-29 Colin Walters <walters@verbum.org>
2087 * girepository/ginfo.c: Add some assertions regarding
2088 refcounts, just to be sure.
2089 * giscanner/glibtransformer.py: Blacklist a few more
2092 2008-08-29 Colin Walters <walters@verbum.org>
2094 * giscanner/glibtransformer.py: Blacklist a few
2095 functions that use GError oddly
2097 2008-08-29 Colin Walters <walters@verbum.org>
2099 * girepository/gtypelib.c: Don't crash if no
2102 2008-08-29 Colin Walters <walters@verbum.org>
2104 * girepository/girparser.c: Handle chains of aliases
2105 across modules by ensuring we fully qualify aliases
2108 2008-08-29 Colin Walters <walters@verbum.org>
2110 * girepository/girparser.c: Don't search aliases
2113 2008-08-29 Colin Walters <walters@verbum.org>
2115 * girepository/girparser.c: Rewrite type parsing
2116 to handle both GLib parsing case as well as correctly
2117 handling GLib.List and friends. Don't try to treat
2118 e.g. ListStore as a List.
2120 2008-08-29 Colin Walters <walters@verbum.org>
2122 * girepository/gtypelib.c: Add more context
2125 2008-08-29 Colin Walters <walters@verbum.org>
2127 * giscanner/glibtransformer.py: Add some informative
2128 logging messages in corner cases. Be sure we use
2129 the most recent node set instead of a cache
2130 when generating result set.
2131 * tests/: Remove duplicated bits in expected girs
2132 * girepository/girparser.c: Accept both List (for
2133 compiling GLib) and GLib.List (what the scanner
2136 * tools/generate.c: Generate canonical form.
2138 2008-08-29 Johan Dahlin <johan@gnome.org>
2140 * giscanner/config.py.in:
2141 Use datarootdir instead of datadir to avoid
2142 an autoconf warning.
2144 2008-08-29 Johan Dahlin <johan@gnome.org>
2148 * examples/gdk-pixbuf.gidl:
2150 Update and remove old cruft.
2152 2008-08-29 Johan Dahlin <johan@gnome.org>
2155 * docs/g-ir-compiler.1:
2156 * docs/g-ir-generate.1:
2157 * docs/g-ir-scanner.1:
2158 Add man pages for the generator and compiler.
2160 2008-08-29 Johan Dahlin <johan@gnome.org>
2162 * docs/g-ir-scanner.1: Document
2164 * giscanner/Makefile.am:
2165 * giscanner/gidlparser.py:
2166 * giscanner/gidlwriter.py:
2167 * tools/g-ir-scanner:
2168 Remove gidl support.
2170 2008-08-28 Colin Walters <walters@verbum.org>
2172 * tests/scanner/Makefile.am: Pass the right
2173 --includedir args. Add a Makefile dep.
2174 * tools/compiler.c: Pass includedirs down.
2175 * girepository/girparser.c: Actually put
2176 includedirs in context, pass down. Fix
2179 2008-08-28 Colin Walters <walters@verbum.org>
2181 * gir/Makefile.am: Use --includedir
2182 * girepository/girparser.c: Recursively parse
2183 includes to pull in aliases and expand them.
2184 We need this to avoid putting unknown names in
2186 * tools/compiler.c: Add --includedir option.
2187 * giscanner/ast.py: Map size/ssize to types
2190 2008-08-28 Tor Lillqvist <tml@novell.com>
2192 Make check now runs successfully on Windows.
2194 * tools/compiler.c (write_out_typelib): Use binary mode for output
2197 * girepository/girnode.c: Don't print NULL strings.
2199 * tests/invoke/Makefile.am
2200 * tests/scanner/Makefile.am: Use -no-undefined on Windows to
2201 convince libtool to build shared libraries.
2203 * tests/invoke/invoke.c: Don't needlessly include <dlfcn.h>. Use
2204 g_assert() instead of printing out expected errors.
2206 2008-08-28 Tor Lillqvist <tml@novell.com>
2208 * girepository/gtypelib.h: Change type of bitfield fields from
2209 guint to the most suitable smaller type. This makes the struct
2210 sizes match the ones on Linux that the sanity check expects when
2211 using gcc -mms-bitfields on Windows.
2213 2008-08-28 Johan Dahlin <johan@gnome.org>
2218 * giscanner/Makefile.am:
2219 * tests/Makefile.am:
2220 * tests/scanner/Makefile.am:
2221 Make distcheck pass.
2223 2008-08-27 Johan Dahlin <johan@gnome.org>
2225 * giscanner/Makefile.am:
2226 Only send in -no-undefined on Win32 as it breaks on MacOS X.
2228 2008-08-27 Tor Lillqvist <tml@novell.com>
2230 Make g-ir-scanner work on Windows. Still problems with the typelib
2231 code. Changes okayed by jdahlin.
2233 * configure.ac: Check for Windows, set Automake conditional
2234 OS_WIN32. Change backslashes to forward slashes in pyexecdir to
2235 avoid shell quoting issues
2237 * girepository/Makefile.am: Use -no-undefined so that libtool
2238 agrees to build a shared library on Windows.
2240 * girepository/girparser.c (backtrace_stderr): No backtrace() on
2241 Windows. Empty implementation on Windows so far.
2243 * girepository/gtypelib.c (g_typelib_check_sanity): Give more
2244 informative error message for the assertion failures. Tell also
2245 what the expected size of the struct is. Check all sizes first and
2246 fail afterwards if at least one size was different from expected.
2248 * tools/Makefile.am: Reorder libraries into proper logical
2251 * tools/generate.c: Don't include <dlfcn.h>, not used.
2253 * giscanner/Makefile.am: On Windows, link with the Python library,
2254 and install the module DLL as _giscanner.pyd. Remove the
2255 unnecessary import library and libtool library that libtool has
2258 * giscanner/scannerlexer.l: Recognize the gcc __attribute__ syntax
2259 and just skip it. Recognize also two "l" suffixes for long long
2260 constants. Recognize also __inline__.
2262 * giscanner/grealpath.h (g_realpath): Implement on Windows, using
2263 GetFullPathName(). As such, GetFullPathName() does more than the
2264 UNIX realpath(). It also changes relative paths into absolute
2265 paths. But for our purposes that shouldn't matter.
2267 * giscanner/giscannermodule.c (pygi_source_scanner_parse_file): On
2268 Windows the file descriptor passed to us is from Python. Python
2269 Python2.5 uses the msvcr71.dll C library, while mingw-built code
2270 uses msvcrt.dll. On Windows, file descriptors are specific to
2271 which C library is used. So we must find out what underlying OS
2272 handle corresponds to the file descriptor Python passes us, and
2273 then make that into a file descriptor valid for the C library this
2276 * giscanner/sourcescanner.py (_parse): Don't need to bypass
2277 __attribute__ as the lexer now handles it. The definition as empty
2278 was ineffective for mingw anyway, as mingw's _mingw.h undefines
2279 __attribute__. Close the temp file before unlinking it.
2281 * giscanner/cgobject.py: Use correct library name for the gobject
2284 * gir/Makefile.am: Must pass the full basename of the DLLs on
2285 Windows to g-ir-scanner. It's a bit ugly that we have to "know"
2286 that the names of the GLib DLLs are like libglib-2.0-0.dll, but in
2287 reality they won't change, until there is a GLib 3, and then also
2288 the Unix code here needs changing.
2290 Must pass CPPFLAGS to g-ir-scanner when building GLib.gir so that
2293 2008-08-26 Colin Walters <walters@verbum.org>
2295 * girepository/girepository.c: Search
2296 $DATADIR/girepository instead of
2297 $DATADIR/gitypelibs; this naming makes
2298 it clearer that e.g. jgir can install
2300 * gir/Makefile.am: Install there.
2302 2008-08-26 Colin Walters <walters@verbum.org>
2304 * girepository/gtypelib.c (_g_typelib_init): Also
2305 use G_MODULE_SUFFIX instead of hardcoding .so.
2307 2008-08-26 Colin Walters <walters@verbum.org>
2309 * girepository/gtypelib.c (_g_typelib_init): Free
2310 string in the right place.
2312 2008-08-26 Colin Walters <walters@verbum.org>
2314 * girepository/gtypelib.c (_g_typelib_init): Handle
2315 both .la and .so names; this works better in the
2316 uninstalled library case.
2318 2008-08-26 Johan Dahlin <johan@gnome.org>
2321 * giscanner/Makefile.am:
2322 * giscanner/cgobject.py:
2323 * giscanner/config.py.in:
2324 * giscanner/sourcescanner.py:
2325 Avoid undeffing __GNUC__, instead define
2326 __attribute__ & friends. Remove glibconfig.h hack.
2327 This makes gobject-introspection work better on
2328 MacOS X, Thanks to Richard Hult for kind help.
2330 2008-08-25 Colin Walters <walters@verbum.org>
2332 * giscanner/glibtransformer.py: Always print
2335 2008-08-25 Colin Walters <walters@verbum.org>
2337 * giscanner/glibtransformer.py: Skip over
2338 interfaces we don't know.
2340 2008-08-25 Colin Walters <walters@verbum.org>
2342 * girepository/girparser.c: Parse new implements
2343 syntax, drop gapi one.
2344 * tests/object.gir: Update.
2345 * tools/generate.c: Generate new syntax.
2347 2008-08-25 Colin Walters <walters@verbum.org>
2349 * giscanner/ast.py: Add interfaces property
2351 * giscanner/girwriter.py: Write out implemented
2353 * giscanner/glibtransformer.py: Introspect
2354 implemented interfaces.
2355 * tests/scanner/*: Make FooObject implement
2358 2008-08-25 Colin Walters <walters@verbum.org>
2360 * giscanner/glibtransformer.py: More correctly pair
2361 methods; if we have a symbol that starts with
2362 e.g. hippo_canvas look for a matching HippoCanvas
2363 class before accepting e.g. HippoCanvasImage.
2365 2008-08-24 Colin Walters <walters@verbum.org>
2367 * tools/g-ir-scanner: Filter out unknown options from
2370 2008-08-24 Colin Walters <walters@verbum.org>
2372 * giscanner/glibtransformer.py: Fail with better
2373 error if we can't find library.
2375 2008-08-24 Colin Walters <walters@verbum.org>
2377 * tools/g-ir-scanner: Use subprocess instead of
2378 commands, works on Windows and avoids the evil
2381 2008-08-24 Colin Walters <walters@verbum.org>
2383 * giscanner/glibtransformer.py: Skip over
2384 g_object_get_type from GLib trunk.
2386 2008-08-24 Colin Walters <walters@verbum.org>
2388 * girepository/girepository.c (g_irepository_require):
2389 Don't open shared library here; we already do it
2392 2008-08-24 Colin Walters <walters@verbum.org>
2394 * girepository/gtypelib.c: Add context stack so
2395 when we get an error we can print out nicely
2398 2008-08-24 Johan Dahlin <johan@gnome.org>
2400 * girepository/girparser.c (start_glib_boxed), (start_function),
2401 (start_field), (start_alias):
2402 Refactor a couple of parsing functions to be simpler to follow.
2405 2008-08-24 Johan Dahlin <johan@gnome.org>
2407 * girepository/girparser.c (start_function):
2408 Remove left-over code, checking type of function.
2410 2008-08-23 Colin Walters <walters@verbum.org>
2412 * giscanner/config.py: Define DATADIR.
2413 * giscanner/transformer.py: Look in DATADIR.
2415 2008-08-23 Colin Walters <walters@verbum.org>
2417 * girepository/gtypelib.c: Check constructor
2419 * girepository/girnode.c: Small tweaks.
2420 * girepository/ginfo.c: Calculate signature offsets
2422 * girepository/girparser.c: Remove duplicate
2424 * giscanner/glibtransformer.py: Avoid marking
2425 functions which return a basic type as
2428 2008-08-23 Colin Walters <walters@verbum.org>
2430 * girepository/girparser.c: Ignore <include>.
2431 * giscanner/girparser.py: Parse them.
2432 * giscanner/girwriter.py: Generate them.
2433 * giscanner/transformer.py: Process <include>
2434 recursively. Don't require full path for
2435 includes, look in {$XDG_DATA_DIRS}/gir.
2436 * tools/g-ir-scanner: Pass through includes.
2437 * Makefile.am: Remove extra --include
2439 * *-expected.gir: Add expected includes.
2441 2008-08-23 Johan Dahlin <johan@gnome.org>
2443 * tests/scanner/Makefile.am:
2444 * tests/scanner/annotation-expected.gir:
2445 * tests/scanner/drawable-expected.gir:
2446 Avoid duplication in the Makefile, regenerate with new
2447 namespaces (same as the filename)
2449 2008-08-22 Colin Walters <walters@verbum.org>
2451 * girepository/girnode.c: Don't hardcode integers,
2454 2008-08-22 Johan Dahlin <johan@gnome.org>
2456 * giscanner/sourcescanner.py:
2457 Check for ../gobject-introspection-1.0.pc.in to determine
2458 if we run installed or uninstalled.
2460 2008-08-22 Johan Dahlin <johan@gnome.org>
2463 * giscanner/sourcescanner.py:
2464 Send in undefs/defines via writing it directly to stdin
2465 of cpp instead of via arguments.
2467 2008-08-22 Colin Walters <walters@verbum.org>
2469 * tools/generate.c, tools/compiler.c: Default
2471 * all Makefile.am: Update.
2473 2008-08-22 Colin Walters <walters@verbum.org>
2475 * girepository/girparser.c: Pass through
2476 recursive types. Avoid overwriting errors.
2477 * giscanner/xmlwriter.py: Always write the
2479 * tests/*.gir: Adjust.
2480 * tests/scanner/Makefile.am: Build typelibs,
2481 and generate XML from those. Once we
2482 have a good diff mechanism...
2483 * tests/scanner/*-expected.gir: Add XML
2485 * tools/g-ir-scanner: Accept --typelib-xml
2487 * tools/generate.c: Better defaults for transfer.
2489 2008-08-22 Johan Dahlin <johan@gnome.org>
2493 * giscanner/Makefile.am:
2494 * giscanner/config.py.in:
2495 * giscanner/sourcescanner.py:
2496 Use the generated glibconfig.h for all scanner invokations.
2497 Rename it to glibconfig-scanner.h and install it.
2498 Add a config.py which so far contains the include dir.
2500 2008-08-22 Johan Dahlin <johan@gnome.org>
2503 Replace glibconfig.h with our own, do some replacement
2504 for CPP/C features we do not support
2506 2008-08-22 Colin Walters <walters@verbum.org>
2508 * tools/generate.c (write_callable_info): Fix unref
2511 2008-08-22 Colin Walters <walters@verbum.org>
2513 * gobject-introspection-1.0.pc.in: Add g-ir-generate.
2514 * tests/Makefile.am: Support $(DEBUG)
2515 * tools/generate.c: Do immediate close tags if no
2518 2008-08-21 Colin Walters <walters@verbum.org>
2520 * tests/scanner/drawable-expected.gir,
2521 * tests/scanner/drawable.c,
2522 * tests/scanner/drawable.h:
2525 2008-08-21 Colin Walters <walters@verbum.org>
2527 * giscanner/glibtransformer.py: Compute prefix
2528 by searching through the symbol for bits
2529 rather than going directly from ctype; this fixes
2532 2008-08-21 Colin Walters <walters@verbum.org>
2534 * giscanner/glibtransformer.py: Also try squashing
2535 underscores from namespace, fixes webkit_web_view_new.
2537 2008-08-21 Colin Walters <walters@verbum.org>
2539 * giscanner/glibtransformer.py: More ctor work,
2540 avoid having gtk_window_group_new end up under
2543 2008-08-21 Colin Walters <walters@verbum.org>
2545 * giscanner/glibtransformer.py: Much simpler approach
2546 of mapping uscored names to classes.
2547 * giscanner/utils.py: Remove unnecessary function.
2549 2008-08-21 Johan Dahlin <johan@gnome.org>
2551 * girepository/girepository.c (g_irepository_require):
2552 Plug memory leak and avoid using freed memory.
2553 Resolve the whole module path, here as well.
2555 2008-08-21 Colin Walters <walters@verbum.org>
2557 * giscanner/glibtransformer.py: Look up all permutations
2558 of class names when scanning methods/ctors based on
2559 the prefix instead of using the return value. This
2560 associates gtk_window_new with the right class.
2562 2008-08-21 Colin Walters <walters@verbum.org>
2564 * girepository/girmodule.c (g_ir_module_build_typelib):
2565 Revert change to increment header_size; we do that in
2568 2008-08-21 Colin Walters <walters@verbum.org>
2570 * girepository/girnode.c (write_string): Tweak to
2571 use UINT instead of INT. Not likely to matter.
2572 * girepository/girmodule.c (g_ir_module_build_typelib):
2573 Add to header_offset as well for header strings
2574 to match what write_string does.
2575 * girepository/gtypelib.c: Replace is_name with
2576 validate_name, which more strongly validates and
2577 handles errors in a better way. Update all callers.
2578 * giscanner/glibtransformer.py: Handle constructors
2581 2008-08-21 Johan Dahlin <johan@gnome.org>
2583 * gir/Makefile.am (typelibs_DATA): Build and
2584 install the Gio.typelib too
2586 * girepository/gtypelib.c (_g_typelib_init):
2587 Use g_module_build_path to resolve the shlib name
2589 2008-08-21 Colin Walters <walters@verbum.org>
2591 * gir/Makefile.am: CLEANFILES typelibs too.
2593 2008-08-21 Johan Dahlin <johan@gnome.org>
2595 * giscanner/glibtransformer.py:
2596 Do not send .la files through find_library.
2598 2008-08-21 Colin Walters <walters@verbum.org>
2600 * girepository/girparser.c (g_irepository_require):
2601 Fix one small leak in error case.
2603 2008-08-21 Johan Dahlin <johan@gnome.org>
2606 Parse glibconfig.h as well and install the compiled
2609 2008-08-21 Johan Dahlin <johan@gnome.org>
2612 * giscanner/glibtransformer.py:
2613 * tools/g-ir-scanner:
2614 Do not hard-core library names in the Makefile, reuse
2615 ctypes find_library instead.
2617 2008-08-21 Johan Dahlin <johan@gnome.org>
2619 * girepository/girparser.c (resolve_aliases):
2620 Remove compilation warnings
2622 2008-08-21 Johan Dahlin <johan@gnome.org>
2624 * girepository/girepository.c (g_irepository_require):
2625 Rewrap and fix double free bug by leaking a bit.
2627 2008-08-20 Colin Walters <walters@verbum.org>
2629 * girepository/girepository.c: Add new function
2630 g_irepository_get_typelib_path which tells
2631 us from where we loaded a namespace.
2633 2008-08-20 Colin Walters <walters@verbum.org>
2635 * tests/scanner/*-expected.gir: Adjust for
2636 added shared-library.
2637 * giscanner/giwriter.py: Make pylint happy.
2639 2008-08-20 Colin Walters <walters@verbum.org>
2641 * girepository/girmodule.c (g_ir_module_build_typelib):
2642 Calculate size correctly, avoid use-after-free.
2644 2008-08-20 Colin Walters <walters@verbum.org>
2646 * girepository/girepository.c: Remove
2647 g_irepository_register_file in favor of
2648 g_irepository_require. There are two
2649 possible deployment scenarios for typelibs:
2650 First, separate in $DATADIR/gitypelibs/. Second,
2651 they may be embedded in shlibs. However since
2652 the first is now the normal case, the API is
2653 optimized around it.
2655 Refactor internals to look up typelibs for
2656 namespaces just-in-time, but we expect
2657 consumers to call g_irepository_require.
2659 Also, add some docs. No one has died from that
2661 * gir/Makefile.am: Need --library for glib.
2662 * giscanner/girwriter.py: Write out shared-library.
2663 * tools/g-ir-writer: Take the first --library
2664 argument as the target of shared-library. In
2665 the future we should make this nicer with pkg-config
2668 2008-08-20 Colin Walters <walters@verbum.org>
2670 * girepository/girparser.py: And parse them.
2672 2008-08-20 Johan Dahlin <johan@gnome.org>
2674 * giscanner/glibast.py: Add gshort/gushort types
2676 2008-08-20 Colin Walters <walters@verbum.org>
2678 * gir/Makefile.am: Rename .gir files using GI namespace.
2679 * girepository/girepository.c: Use XDG_DATA_DIRS for
2680 looking up typelibs. Also typelibs are now suffixed
2682 * tests/invoke/Makefile.am: Only use metadata.
2683 * girepository/Makefile.am: Remove unnecessary include.
2684 * tests/scanner/Makefile.am: Update using GI namespaces
2685 for scanner includes.
2687 2008-08-20 Colin Walters <walters@verbum.org>
2689 * girepository/transformer.py: Suppress aliases whose
2691 * girepository/ast.py: Define some more aliases.
2693 2008-08-20 Colin Walters <walters@verbum.org>
2695 * girepository/girparser.c: Avoid alias infloops.
2697 2008-08-20 Colin Walters <walters@verbum.org>
2699 * tests/scanner/foo-expected.gir: Fix expected list type.
2701 2008-08-20 Johan Dahlin <johan@gnome.org>
2703 * giscanner/glibtransformer.py (GLibTransformer._resolve_type_name):
2704 Add a workaround for #548689.
2705 We can now compile gtk!
2707 2008-08-20 Colin Walters <walters@verbum.org>
2709 * giscanner/glibtransformer.py: Try to look up
2710 aliases using the c:type too.
2712 2008-08-20 Colin Walters <walters@verbum.org>
2714 * girepository/girparser.c: Parse union fields.
2716 2008-08-20 Johan Dahlin <johan@gnome.org>
2718 * giscanner/ast.py: Make time_t an alias for long
2720 * gir/gio-2.0-good.gir:
2721 * gir/glib-2.0-good.gir:
2722 * gir/gobject-2.0-good.gir:
2724 * giscanner/glibtransformer.py:
2725 Do not delete Class structures, we need them in gdk/gtk.
2726 * tests/scanner/drawable-expected.gir:
2727 * tests/scanner/foo-expected.gir:
2728 * tests/scanner/utility-expected.gir:
2731 2008-08-20 Johan Dahlin <johan@gnome.org>
2733 * tests/scanner/Makefile.am:
2734 * tests/scanner/annotation-expected.gir:
2735 * tests/scanner/annotation.c (annotation_object_class_init),
2736 (annotation_object_init), (annotation_object_method),
2737 (annotation_object_in), (annotation_object_out),
2738 (annotation_object_inout), (annotation_object_inout2),
2739 (annotation_object_inout3), (annotation_object_calleeowns),
2740 (annotation_object_calleesowns), (annotation_object_get_strings),
2741 (annotation_object_with_voidp), (annotation_object_get_objects),
2742 (annotation_object_create_object), (annotation_object_allow_none):
2743 * tests/scanner/annotation.h:
2744 * tests/scanner/foo-expected.gir:
2745 * tests/scanner/foo.c:
2746 * tests/scanner/foo.h:
2747 Split out annotation tests out of foo
2749 2008-08-20 Johan Dahlin <johan@gnome.org>
2751 * tests/scanner/Foo-expected.gir:
2752 * tests/scanner/Makefile.am:
2753 * tests/scanner/foo-expected.gir:
2754 * tests/scanner/foo-object.h:
2755 * tests/scanner/foo.c:
2756 Foo->foo, foo-object.h -> foo.h
2758 2008-08-20 Johan Dahlin <johan@gnome.org>
2760 * tests/scanner/Foo-expected.gir:
2761 * tests/scanner/Makefile.am:
2762 * tests/scanner/drawable-expected.gir:
2763 * tests/scanner/drawable.c (test_drawable_class_init),
2764 (test_drawable_init):
2765 * tests/scanner/drawable.h:
2766 * tests/scanner/foo-object.h:
2767 * tests/scanner/foo.c (foo_boxed_method):
2768 Move the drawable parts out of Foo to its own test.
2770 2008-08-20 Johan Dahlin <johan@gnome.org>
2772 * tests/scanner/Foo-expected.gir:
2773 * tests/scanner/foo-object.h:
2774 * tests/scanner/foo.c (foo_drawable_class_init),
2775 (foo_drawable_init):
2776 Add a based on GdkDrawable which generates
2779 2008-08-19 Colin Walters <walters@verbum.org>
2781 * giscanner/transformer.py: Don't try
2782 to strip prefix before namespace.
2784 2008-08-19 Johan Dahlin <johan@gnome.org>
2786 * giscanner/transformer.py:
2787 * tests/scanner/Foo-expected.gir:
2788 * tests/scanner/foo-object.h:
2789 Add support for typedef void foo type of
2792 2008-08-19 Johan Dahlin <johan@gnome.org>
2795 * giscanner/girwriter.py:
2796 * giscanner/glibtransformer.py:
2797 * giscanner/transformer.py:
2798 * tests/scanner/Foo-expected.gir:
2799 Add basic support for union, base the code much
2800 on Struct. Add a testcase.
2802 2008-08-19 Johan Dahlin <johan@gnome.org>
2804 * tests/scanner/Foo-expected.gir:
2805 * tests/scanner/foo-object.h:
2806 Add a union testcase which the compiler currently
2809 2008-08-19 Johan Dahlin <johan@gnome.org>
2811 * gobject-introspection-1.0.pc.in:
2812 Add a g_ir_compiler variable
2814 2008-08-19 Colin Walters <walters@verbum.org>
2816 * giscanner/ast.py: Rework types to be more closely
2818 * giscanner/girparser.py: Parse more bits.
2819 * giscanner/girwriter.py: Write sequences in a new
2820 way that specifies container type.
2821 * giscanner/glibast.py: Adjust for ast.py changes,
2822 add 'ctype' property to GLibObject and GLibInterface
2823 so we can look things up by it later.
2824 * gicanner/transformer.py: Names is new class holding
2825 the various namespaces we manage. Do not confuse
2826 with Namespace which is toplevel XML node effectively.
2827 Rework all type resolution to go through
2828 _resolve_type_name_1.
2829 * giscanner/glibtransformer.py: Raise UnknownTypeError
2830 instead of ValueError for cleanliness. Add Unresolved
2831 class to mark types whose parent we haven't seen yet.
2832 Use new Names object from transformer.py.
2833 Correctly look up parent=.
2834 Fix type validation to handle sequences.
2835 * tests/scanner/Foo-expected.gir: Update for sequence
2836 work, int instead of int32.
2837 * tools/g-ir-scanner: Add --noclosure option
2838 * gir/Makefile.am: Use --noclosure by default for
2841 2008-08-18 Johan Dahlin <johan@gnome.org>
2843 * gir/gio-2.0-good.gir:
2844 * gir/glib-2.0-good.gir:
2845 * gir/gobject-2.0-good.gir:
2848 2008-08-18 Johan Dahlin <johan@gnome.org>
2851 * giscanner/girparser.py:
2852 * giscanner/girwriter.py:
2853 * giscanner/glibast.py:
2854 * giscanner/glibtransformer.py:
2855 * giscanner/transformer.py:
2856 * tests/scanner/Foo-expected.gir:
2857 * tests/scanner/foo-object.h:
2858 * tests/scanner/utility-expected.gir:
2859 * tests/scanner/utility.h:
2860 Redo type resolving and validation.
2861 Add a couple of new tests.
2862 Patch mostly written by Colin.
2864 2008-08-18 Johan Dahlin <johan@gnome.org>
2867 * giscanner/girparser.py:
2869 * giscanner/transformer.py:
2870 Improve enum parsing for enums without a GType.
2871 Make flags/enum references to other girs work
2872 * giscanner/utils.py:
2874 * tests/scanner/Makefile.am:
2875 * tests/scanner/foo-object.h:
2876 * tests/scanner/utility-expected.gir:
2877 * tests/scanner/utility.h:
2878 Add a new test for external enum references
2880 2008-08-18 Johan Dahlin <johan@gnome.org>
2882 * docs/global-module-registry.txt: Update
2884 * tests/array.gir: Update with new type proposal
2886 * girepository/girepository.c (g_type_tag_to_string):
2887 * girepository/girepository.h:
2888 * girepository/girnode.c (g_ir_node_get_full_size_internal),
2890 * girepository/girnode.h:
2891 Make enum serializing functions public. Clean up some whitespace.
2893 2008-08-17 Johan Dahlin <johan@gnome.org>
2895 * docs/global-module-registry.txt:
2896 Add a document for an on disk module registry format
2898 2008-08-17 Johan Dahlin <johan@gnome.org>
2901 * gir/gio-2.0-good.gir:
2904 2008-08-17 Johan Dahlin <johan@gnome.org>
2907 * gir/glib-2.0-good.gir:
2908 * gir/gobject-2.0-good.gir:
2909 * giscanner/cgobject.py:
2910 * giscanner/glibtransformer.py:
2911 Regenerate GObject & GType.
2912 Avoid warnings when generating gobject-2.0.gir.
2913 Introspect a little more, and skip *_get_type functions.
2915 2008-08-17 Colin Walters <walters@verbum.org>
2917 * gir/glib-2.0.gir, gir/gobject-2.0.gir:
2918 Rename to -good, always generate during build.
2919 * gir/Makefile.am: Ensure .gir files dep on
2920 all scanner sources.
2921 * Makefile.am: Switch build order to ensure
2922 the scanner is ready before we do gir/.
2923 * tools/g-ir-scanner: Look for .git too.
2925 2008-08-17 Johan Dahlin <johan@gnome.org>
2927 * girepository/gtypelib.c (validate_enum_blob):
2928 * giscanner/glibtransformer.py:
2929 * giscanner/transformer.py:
2930 Remove resolve_possible_typedefs, it was unused.
2931 Allow multiple enum values of the sample value in an enum,
2932 since it's actually pretty common.
2933 Register enums so they can be resolved too.
2935 2008-08-16 Johan Dahlin <johan@gnome.org>
2937 * giscanner/girparser.py:
2938 Parse enumeration/bitfield.
2940 2008-08-16 Johan Dahlin <johan@gnome.org>
2942 * giscanner/girparser.py:
2945 2008-08-16 Johan Dahlin <johan@gnome.org>
2947 * giscanner/glibtransformer.py:
2948 Resolve type names for alias targets
2949 * giscanner/transformer.py:
2950 Skip FILE* parameters fow now
2952 2008-08-16 Johan Dahlin <johan@gnome.org>
2955 * gir/gobject-2.0.gir:
2958 * tests/scanner/Makefile.am:
2961 2008-08-15 Colin Walters <walters@verbum.org>
2963 * giscanner/glibtransformer.py: Explicitly construct
2964 new list, since we're deleting as we iterate.
2965 Don't delete all structures which end in Class; just
2966 ones which have a paired GObject.
2967 Fix printing of type warning.
2968 * giscanner/transformer.py: Make strip_namespace_object
2969 be the identity function if it doesn't match the
2972 2008-08-15 Colin Walters <walters@verbum.org>
2974 * giscanner/cgobject.py: Define yet more argument
2975 prototypes; fix prototype for g_type_fundamental.
2977 2008-08-14 Johan Dahlin <johan@gnome.org>
2979 * tests/Makefile.am:
2980 * tests/constant.gir:
2981 * tests/gobject.gir:
2983 * tools/generate.c (write_struct_info):
2984 Fix generator for constant/gobject/struct
2986 2008-08-14 Johan Dahlin <johan@gnome.org>
2988 * tests/Makefile.am:
2990 * tools/generate.c (write_enum_info):
2991 Fix generation of enum/bitfields
2993 2008-08-14 Johan Dahlin <johan@gnome.org>
2995 * girepository/girparser.c (start_field), (start_constant),
2996 (start_type), (end_element_handler):
2997 Clear up constant parsing
3002 * tools/generate.c (write_callable_info), (write_function_info),
3003 (write_callback_info), (write_constant_info), (write_signal_info),
3004 (write_vfunc_info), (write_property_info), (write_object_info),
3005 (write_interface_info):
3006 Constants/Signals are handled now.
3008 2008-08-14 Johan Dahlin <johan@gnome.org>
3010 * girepository/girparser.c (start_type):
3011 Don't require c:type.
3012 * tests/Makefile.am:
3015 Update, remove parts we don't support yet
3016 * tests/roundtrips.sh:
3018 * tools/generate.c (write_type_info), (write_field_info),
3019 (write_callable_info), (write_struct_info):
3020 Make it emit proper gir.
3022 2008-08-14 Johan Dahlin <johan@gnome.org>
3024 * giscanner/transformer.py:
3025 New internal function for adding a new node.
3027 2008-08-14 Johan Dahlin <johan@gnome.org>
3030 Define an internal _H_ variable so we skip parsing both
3031 i18n headers, only one is needed.
3033 Add the glib-2.0.gir too.
3034 * giscanner/glibast.py:
3035 Add gconstpointer as an alias for ANY
3036 * giscanner/transformer.py:
3037 Do not lower case enumeration names per se.
3038 Skip functions which has parameters called 'va_list'
3040 2008-08-14 Colin Walters <walters@verbum.org>
3042 * giscanner/transformer.py: Comment data structures.
3043 Also squash pointers in resolve_type_name to correspond
3044 with what we do for params.
3045 * giscanner/glibtransformer.py: Print warnings in more
3046 situations. Rework checks for method/constructor to
3047 look up in our GType database instead of just checking
3048 for *. Avoid generating <record> for GObject which
3049 duplicate the <class>.
3050 * gir/Makefile.am: Generate glib-2.0.gir and gobject-2.0.gir
3053 2008-08-14 Johan Dahlin <johan@gnome.org>
3055 * giscanner/girwriter.py:
3056 * giscanner/glibast.py:
3057 * giscanner/glibtransformer.py:
3058 * giscanner/transformer.py:
3060 * tests/Makefile.am:
3061 Add pyflakes.py and run it in make check.
3062 Update the source code to fix the errors reported by
3065 2008-08-14 Johan Dahlin <johan@gnome.org>
3068 * giscanner/girparser.py:
3069 * giscanner/glibast.py:
3070 * giscanner/glibtransformer.py:
3071 Refactor the parser a bit.
3072 Add parent type to interfaces and update callsites.
3074 2008-08-14 Johan Dahlin <johan@gnome.org>
3076 * giscanner/glibtransformer.py:
3077 * giscanner/utils.py:
3078 Refactor a bit, avoid isinstance and add a method
3079 for each type we parse.
3081 2008-08-14 Johan Dahlin <johan@gnome.org>
3084 * giscanner/girparser.py:
3085 * giscanner/glibtransformer.py:
3086 * tests/Makefile.am:
3087 Run pep8.py in make check, fix old errors.
3089 2008-08-13 Colin Walters <walters@verbum.org>
3091 * giscanner/girparser.py: Parse records.
3093 2008-08-13 Colin Walters <walters@verbum.org>
3095 * gir/Makefile.am: Install again.
3096 * gir/gobject-2.0.gir: Add some more bits.
3098 2008-08-13 Colin Walters <walters@verbum.org>
3100 * gir/gobject-2.0.gir: Use correct namespace, add GType.
3101 * giscanner/girparser.py: Handle aliases.
3102 * giscanner/transformer.py: Record aliases. Make resolver
3103 functions public; we now call into these explicitly from
3104 glibtransformer. Handle resolving aliases.
3105 * giscanner/glibtransformer.py: Separate our internal namespace
3106 from included ones. Call up into transformer's resolver functions.
3108 2008-08-13 Johan Dahlin <johan@gnome.org>
3110 * girepository/girnode.c (g_ir_node_get_full_size_internal):
3111 * girepository/girparser.c (start_class):
3112 * giscanner/glibtransformer.py:
3113 Allow get_type to be None, set a get_type for GInitiallyUnowned too.
3115 2008-08-13 Johan Dahlin <johan@gnome.org>
3117 * giscanner/cgobject.py:
3118 Register GInitiallyUnowned
3119 * giscanner/girwriter.py:
3120 * giscanner/glibtransformer.py:
3121 Special case GObject/GInitially owned as they are a bit special to use.
3123 2008-08-13 Colin Walters <walters@verbum.org>
3125 * tests/scanner/Foo-expected.gir, tests/scanner/utility-expected.gir:
3126 Object is in GObject namespace.
3128 2008-08-13 Colin Walters <walters@verbum.org>
3130 * giscanner/girparser.py: Fix processing of functions
3133 2008-08-13 Colin Walters <walters@verbum.org>
3135 * giscanner/girparser.py: Parse more than just <class.
3136 * giscanner/glibtransformer.py: Put aliases in a separate
3137 data structure since their name is not canonicall.
3138 * giscanner/transformer.py: Handle resolving type names
3141 2008-08-13 Johan Dahlin <johan@gnome.org>
3143 * tools/g-ir-scanner:
3144 Allow multiple libraries
3145 * giscanner/glibtransformer.py:
3146 Rename load_library to add_library, traverse over all libraries
3147 when trying to resolve a function
3149 2008-08-12 Colin Walters <walters@verbum.org>
3151 * giscanner/transformer.py: Record typedefs as <alias> elements.
3152 Also attempt to look up types in external namespaces.
3153 * giscanner/girwriter.py: Write them.
3154 * giscanner/glibtransformer.py: Rework resolver using real instanceof
3155 checks. Resolve interface methods and properties.
3156 * tests/scanner/foo-object.h: Add a method with typedef.
3157 * tests/scanner/Foo-expected.gir: Update.
3158 * girepository/girnode.c: Debug tweaks.
3159 * girepository/girparser.c: Make a first pass through the XML where we
3160 record all the aliases. This lets us resolve them as we go through the
3162 * gir/Makefile.am: Don't install gobject-2.0.gir; we want that to come
3163 from gir-repository.
3165 2008-08-12 Colin Walters <walters@verbum.org>
3167 * giscanner/glibtransformer.py: Resolve typedefs (e.g. AtkAttributeSet -> GSList).
3168 Correctly do subclasseing in 2nd pass resolution. Handle callbacks in structure
3170 * giscanner/transformer.py: Record typedefs and expose public API for resolving
3172 * tests/scanner/Foo-expected.gir: Fix expected callback types.
3174 2008-08-12 Colin Walters <walters@verbum.org>
3176 * giscanner/glibtransformer.py: Also transform object properties.
3178 2008-08-12 Colin Walters <walters@verbum.org>
3180 * giscanner/glibtransformer.py: Also transform callbacks
3181 and structure field types.
3182 * tests/scanner/Fooe-expected.gir: Update to expect correct
3183 names for callbacks and structs.
3185 2008-08-12 Colin Walters <walters@verbum.org>
3187 * girepository/girparser.c: Handle 'any'.
3188 * tests/scanner/Foo-expected.gir, tests/scanner/foo-object.h:
3189 Add test for void *.
3191 2008-08-12 Colin Walters <walters@verbum.org>
3193 * giscanner/glibtransformer.py: We need to do type
3194 resolution in a second pass after we've seen all the
3195 enums, records, etc.
3197 2008-08-12 Colin Walters <walters@verbum.org>
3199 * tests/scanner/Foo-expected.gir, tests/scanner/foo-object.h:
3200 Add enum return value.
3201 * giscanner/glibtransformer.py: Transform function return types
3204 2008-08-12 Colin Walters <walters@verbum.org>
3206 * tests/scanner/Makefile.am: Dep .gir files on scanner
3207 sources too. Also remove @ so we see scanner invocations.
3209 2008-08-12 Colin Walters <walters@verbum.org>
3211 * girepository/girparser.c, girepository/gtypelib.c,
3212 girepository/gtypelib.h, girepository/girnode.c:
3213 Remove usage of (GAPI-oriented) TypeTag in favor of
3214 GITypeTag from girepository.h.
3216 2008-08-10 Colin Walters <walters@verbum.org>
3218 * tests/roundtrips.sh: Use the correct tests.
3220 2008-08-10 Colin Walters <walters@verbum.org>
3222 * giscanner/cgobject.py: Declare/wrap a few more functions.
3223 Fix parameter types for g_object_new and g_type_fundamental.
3225 2008-08-10 Colin Walters <walters@verbum.org>
3227 * giscanner/cgobject.py: Add new decorator @gwrap which forces
3228 us to declare types for both return value and parameters. The
3229 ctypes default of 'int' is bad because it hides 32/64 bit
3230 problems. Convert all existing functions to use it.
3232 2008-08-09 Johan Dahlin <johan@gnome.org>
3234 * giscanner/__init__.py:
3236 * giscanner/cgobject.py:
3237 * giscanner/gidlparser.py:
3238 * giscanner/gidlwriter.py:
3239 * giscanner/girparser.py:
3240 * giscanner/girwriter.py:
3241 * giscanner/glibast.py:
3242 * giscanner/glibtransformer.py:
3243 * giscanner/odict.py:
3244 * giscanner/sourcescanner.py:
3245 * giscanner/transformer.py:
3246 * giscanner/utils.py:
3247 * giscanner/xmlwriter.py:
3248 * tools/g-ir-scanner:
3252 2008-08-09 Johan Dahlin <johan@gnome.org>
3255 * relaxng/c-types.xml:
3256 * relaxng/g-types.xml:
3257 * relaxng/relaxng.rng:
3259 Remove outdated relaxng schemas.
3261 2008-08-09 Johan Dahlin <johan@gnome.org>
3264 Rename metadata to typelib in variable names,
3267 2008-08-09 Johan Dahlin <johan@gnome.org>
3271 Remove old C scanner, which got rewritten in python.
3273 2008-08-09 Johan Dahlin <johan@gnome.org>
3275 * girepository/Makefile.am:
3276 * tools/Makefile.am:
3277 * tools/girmodule.c:
3278 * tools/girmodule.h:
3281 * tools/girparser.c:
3282 * tools/girparser.h:
3283 * tools/girwriter.c:
3284 * tools/girwriter.h:
3285 Move shared *.[ch] files to girepository from tools
3287 2008-08-09 Johan Dahlin <johan@gnome.org>
3289 * tests/Makefile.am:
3292 * tests/constant.test:
3294 * tests/errors.test:
3295 * tests/function.test:
3296 * tests/gobject.test:
3297 * tests/interface.test:
3298 * tests/object.test:
3299 * tests/struct.test:
3304 Rename *.test to *.gir
3306 2008-08-09 Johan Dahlin <johan@gnome.org>
3309 * tests/Makefile.am:
3310 * tests/parser/Foo-expected.gir:
3311 * tests/parser/Makefile.am:
3312 * tests/parser/foo-object.h:
3313 * tests/parser/foo.c:
3314 * tests/parser/utility-expected.gir:
3315 * tests/parser/utility.c:
3316 * tests/parser/utility.h:
3317 * tests/scanner/Makefile.am:
3318 Rename tests/parser to test/scanner
3320 2008-08-08 Colin Walters <walters@verbum.org>
3322 * tests/roundtrips.sh: Use local .gir files again.
3324 2008-08-08 Colin Walters <walters@verbum.org>
3326 * tests/invoke/Makefile.am: .gir file depends on libtool
3329 2008-08-08 Colin Walters <walters@verbum.org>
3331 * tools/girnode.c: Pass through parent node so we can
3332 print the node whose child is NULL, if that occurs.
3334 2008-08-08 Johan Dahlin <johan@gnome.org>
3336 * tests/Makefile.am:
3337 Disable roundtrip tests which are not yet working
3338 * tests/invoke/testfns.gir:
3341 2008-08-08 Johan Dahlin <johan@gnome.org>
3343 * giscanner/girwriter.py:
3345 * giscanner/glibast.py:
3346 * giscanner/glibtransformer.py:
3347 Swap order of members, to keep it consistent with
3350 2008-08-08 Johan Dahlin <johan@gnome.org>
3352 * girepository/gtypelib.c (validate_header):
3353 * girepository/gtypelib.h:
3355 * giscanner/girwriter.py:
3356 * giscanner/sourcescanner.c (gi_source_symbol_ref),
3357 (gi_source_symbol_unref):
3360 * tests/constant.test:
3362 * tests/errors.test:
3363 * tests/function.test:
3364 * tests/gobject.test:
3365 * tests/interface.test:
3366 * tests/invoke/Makefile.am:
3367 * tests/invoke/testfns.xml:
3368 * tests/object.test:
3369 * tests/parser/Makefile.am:
3370 * tests/roundtrips.sh:
3371 * tests/struct.test:
3376 * tools/Makefile.am:
3377 * tools/compiler.c (main):
3378 * tools/generate.c (write_callable_info), (write_function_info),
3380 * tools/gidlmodule.c:
3381 * tools/gidlmodule.h:
3384 * tools/gidlparser.c:
3385 * tools/gidlparser.h:
3386 * tools/gidlwriter.c:
3387 * tools/gidlwriter.h:
3388 * tools/scanner.c (create_node_from_gtype),
3389 (create_node_from_ctype), (g_igenerator_process_properties),
3390 (g_igenerator_process_signals), (g_igenerator_create_object),
3391 (g_igenerator_create_interface), (g_igenerator_create_boxed),
3392 (g_igenerator_create_enum), (g_igenerator_create_flags),
3393 (g_igenerator_process_function_symbol),
3394 (g_igenerator_process_unregistered_struct_typedef),
3395 (g_igenerator_process_struct_typedef),
3396 (g_igenerator_process_union_typedef),
3397 (g_igenerator_process_enum_typedef),
3398 (g_igenerator_process_function_typedef),
3399 (g_igenerator_process_constant), (g_igenerator_process_symbols),
3400 (g_igenerator_add_module), (g_igenerator_add_include_idl):
3401 Merge in the gir-compiler branch.
3402 Thanks to Philip and Colin for their help.
3404 2008-07-26 Colin Walters <walters@verbum.org>
3406 * tools/Makefile.am (bin_PROGRAMS): Install g-idl-compiler
3407 and g-idl-generate to go along with how we're changing this
3408 module to be installed.
3409 * gobject-introspection-1.0.pc.in: Set up Cflags and Libs.
3411 2008-07-24 Colin Walters <walters@verbum.org>
3413 * girepository/girepository.c (g_irepository_register): Add
3414 environment variable G_IREPOSITORY_VERBOSE so we can print
3415 out what we're doing.
3416 * girepository/girepository.c (g_irepository_register_file):
3417 Add GError error message to g_debug call.
3419 2008-07-08 Jürg Billeter <j@bitron.ch>
3421 * giscanner/glibast.py:
3425 2008-06-21 Johan Dahlin <jdahlin@async.com.br>
3427 * giscanner/girparser.py (GIRParser._parse_api): Ignore a few
3430 2008-06-20 Johan Dahlin <jdahlin@async.com.br>
3433 * giscanner/girwriter.py:
3434 * giscanner/transformer.py:
3435 * tests/parser/Foo-expected.gir:
3436 * tests/parser/foo-object.h:
3437 * tests/parser/foo.c (foo_object_allow_none):
3438 Add support for gtk-doc annotations for allow-none.
3441 2008-06-19 Johan Dahlin <jdahlin@async.com.br>
3444 * giscanner/girwriter.py:
3445 * giscanner/glibast.py:
3446 * giscanner/glibtransformer.py:
3447 * giscanner/transformer.py:
3448 * tests/parser/Foo-expected.gir:
3449 Start using abstract type instead of the raw C types.
3450 Register a bunch of glib types we care about.
3452 2008-06-19 Rob Taylor <rob.taylor@codethink.co.uk>
3457 2008-06-08 Philip Van Hoof <pvanhoof@gnome.org>
3459 * girepository/girepository.c:
3460 * girepository/gtypelib.c:
3461 * girepository/ginfo.c:
3462 * girepository/ginvoke.c:
3463 * girepository/girepository.h:
3464 * girepository/gtypelib.h:
3465 * girepository/gmetadata.c:
3466 * girepository/Makefile.am:
3467 * girepository/gmetadata.h:
3469 * tools/gidlmodule.c:
3472 * tools/gidlmodule.h:
3473 * tools/gidlparser.c:
3475 Renamed GMetadata to GTypelib
3477 2008-06-07 Johan Dahlin <jdahlin@async.com.br>
3479 * giscanner/xmlwriter.py:
3480 Improve line wrapping when > 79 charaters
3482 2008-06-05 Jürg Billeter <j@bitron.ch>
3485 * giscanner/girwriter.py:
3486 * giscanner/transformer.py:
3487 Use <type> element for field types
3488 * tests/parser/Foo-expected.gir:
3491 2008-06-04 Johan Dahlin <jdahlin@async.com.br>
3493 * giscanner/glibtransformer.py:
3494 Fix a bug which prevented GdkEvent from being generated
3496 2008-06-03 Johan Dahlin <jdahlin@async.com.br>
3498 * giscanner/Makefile.am:
3500 * giscanner/girwriter.py:
3501 * giscanner/glibast.py:
3502 * giscanner/glibtransformer.py:
3503 * giscanner/transformer.py:
3504 * giscanner/utils.py:
3505 * tests/parser/Foo-expected.gir:
3506 Improve enum member parsing and introspection
3508 2008-05-31 Johan Dahlin <jdahlin@async.com.br>
3510 * giscanner/scannerparser.y:
3511 * giscanner/sourcescanner.h:
3512 * giscanner/sourcescanner.py:
3513 Add a new source type enum for member.
3514 Use __repr__ for improved debugging
3515 * giscanner/girparser.py:
3517 * giscanner/transformer.py:
3518 Improve parsing of struct members.
3519 * tests/parser/foo-object.h:
3522 2008-05-31 Johan Dahlin <jdahlin@async.com.br>
3524 * giscanner/xmlwriter.py:
3525 Improve error reporting when trying to quote None.
3526 * giscanner/girparser.py:
3527 Do not print warnings when including more complete .gir files
3528 * giscanner/girwriter.py:
3529 Do not require a name for parameters, add a todo for singletons
3530 * giscanner/glibtransformer.py:
3531 Refactor the way structs are done, add a couple of hacks to allow
3533 * giscanner/transformer.py:
3534 Add enough hacks so cairo, atk and pango.gir can be parsed properly
3535 * gobject-introspection-1.0.pc.in:
3536 Export girdir, so we can access gobject-2.0.gir from outside
3538 2008-05-31 Johan Dahlin <jdahlin@async.com.br>
3540 * tools/g-ir-scanner:
3541 * tests/parser/Makefile.am:
3542 Update sys.path before running the parser so we don't have
3543 to setup PYTHONPATH ourselves.
3547 * girepository/Makefile.am:
3548 * giscanner/transformer.py:
3549 * gobject-introspection-1.0.pc.in:
3550 * gobject-introspection.pc.in:
3551 * tools/Makefile.am:
3553 Rename pkg-config name to gobject-introspection-1.0,
3554 Do not installed anything which is not using the gir format.
3555 Disable compililation the old C scanner, but still keep the source
3556 until all the remaning functionallity has been ported.
3558 2008-05-31 Johan Dahlin <jdahlin@async.com.br>
3560 * giscanner/giscannermodule.c (symbol_get_ident): Prevent
3561 a crash when symbol->indent is NULL.
3563 * giscanner/sourcescanner.py (ctype_name): Add ctype_name,
3564 a function to convert a CTYPE symbol to a string
3566 2008-05-24 Johan Dahlin <jdahlin@async.com.br>
3569 * giscanner/girwriter.py:
3570 * giscanner/giscannermodule.c
3571 (pygi_source_scanner_append_filename),
3572 (pygi_source_scanner_parse_file):
3573 * giscanner/glibtransformer.py:
3574 * giscanner/sourcescanner.py:
3575 Revert back to using temporary files to send in headers.
3576 Allow Functions to be passed in as callbacks, add a couple
3577 of try/excepts missing features.
3578 We can now scan pango
3580 2008-05-08 Johan Dahlin <johan@gnome.org>
3582 * giscanner/glibtransformer.py:
3583 * giscanner/transformer.py:
3584 Move namespace stripping glibtransformer->transformer
3586 2008-05-08 Johan Dahlin <johan@gnome.org>
3589 * giscanner/girwriter.py:
3590 * giscanner/glibtransformer.py:
3591 * giscanner/transformer.py:
3592 * tools/g-ir-scanner:
3593 Introduce a namespace ast node
3595 2008-05-05 Johan Dahlin <johan@gnome.org>
3597 * giscanner/__init__.py:
3598 * giscanner/sourcescanner.py:
3599 * giscanner/transformer.py:
3600 Move sourcescanner symbols to the sourcescanner module, instead
3601 of in the global __init__ namespace.
3603 2008-05-03 Johan Dahlin <johan@gnome.org>
3605 * giscanner/glibtransformer.py:
3606 * tools/g-ir-scanner:
3607 Handle missing parameters better, allow - and + in .la dlname
3610 2008-05-03 Johan Dahlin <johan@gnome.org>
3612 * giscanner/__init__.py:
3614 * giscanner/girwriter.py:
3615 * giscanner/glibtransformer.py:
3616 * giscanner/transformer.py:
3617 Parse struct fields properly, improve debugging.
3619 2008-04-29 Johan Dahlin <johan@gnome.org>
3622 * giscanner/girwriter.py:
3623 * giscanner/transformer.py:
3624 * tests/parser/Foo-expected.gir:
3626 Use transfer-ownership everywhere, to mark ownership/calle/caller etc.
3628 2008-04-29 Johan Dahlin <jdahlin@async.com.br>
3631 * docs/g-ir-scanner.1:
3632 * metadata-annotations-proposal.txt:
3633 * metadata-format.txt:
3634 Add a basic, unfinshed man page for g-ir-scanner, move documents into .txt
3636 2008-04-29 Johan Dahlin <jdahlin@async.com.br>
3638 * giscanner/girwriter.py:
3639 * giscanner/glibtransformer.py:
3640 * giscanner/transformer.py:
3641 * giscanner/xmlwriter.py:
3642 * tests/parser/Foo-expected.gir:
3643 * tests/parser/foo-object.h:
3644 Write record/structs to gir file too. Add a couple of tests,
3645 fix an off by one error in xmlwriter.py.
3647 2008-04-28 Johan Dahlin <johan@gnome.org>
3649 * giscanner/xmlwriter.py: Calculate the line length properly,
3650 include the provided extra indentation in the calculation, really.
3652 2008-04-28 Johan Dahlin <jdahlin@async.com.br>
3655 * giscanner/glibast.py:
3656 * giscanner/glibtransformer.py:
3657 * giscanner/transformer.py:
3658 * tools/g-ir-scanner:
3659 Add a --strip-prefix and sort out confusion between names and symbols
3660 for functions and struct + derivaties.
3661 Refactor bootstrap of g-ir-scanner, so we can set options on
3662 Transformer() before parsing everything.
3664 2008-04-28 Johan Dahlin <johan@gnome.org>
3666 * giscanner/transformer.py (Transformer._traverse_one): Avoid recursion
3667 when scanning girepository.h
3669 * giscanner/sourcescanner.py (SourceScanner._preprocess): Define
3670 a __GI_SCANNER__ when we run.
3672 2008-04-28 Johan Dahlin <jdahlin@async.com.br>
3675 * giscanner/girwriter.py:
3676 * giscanner/glibast.py:
3677 * giscanner/glibtransformer.py:
3678 * tests/parser/Foo-expected.gir:
3679 * tests/parser/utility-expected.gir:
3680 Rename most c:identifier to c:type. Add new ones to
3681 class/interface/enum/boxed.
3683 2008-04-28 Johan Dahlin <jdahlin@async.com.br>
3686 * giscanner/girwriter.py:
3687 * giscanner/glibtransformer.py:
3688 * tests/parser/Foo-expected.gidl:
3689 * tests/parser/Makefile.am:
3690 Move c:identifier from return-value to subchild type,
3691 as per Jürgs suggestion
3693 2008-04-28 Johan Dahlin <johan@gnome.org>
3695 * giscanner/girwriter.py:
3696 * tests/parser/Foo-expected.gir:
3697 Write property.type as a child node.
3699 2008-04-27 Johan Dahlin <johan@gnome.org>
3704 * gidl/gobject-2.0.gidl:
3706 * gir/gobject-2.0.gir:
3707 * tests/parser/Makefile.am:
3708 Replace the GObject gidl with a GObject gir.
3710 2008-04-27 Johan Dahlin <johan@gnome.org>
3712 * tools/Makefile.am (bin_SCRIPTS): g-ir-scanner is a script,
3715 * giscanner/xmlwriter.py:
3716 * tests/parser/Foo-expected.gir:
3717 Include indentation in line length calculation
3719 2008-04-27 Johan Dahlin <johan@gnome.org>
3721 * giscanner/girparser.py:
3722 Prettify NS parsing using elementtree.
3724 2008-04-27 Johan Dahlin <johan@gnome.org>
3727 * giscanner/Makefile.am:
3728 * giscanner/girparser.py:
3729 * giscanner/glibtransformer.py:
3730 * tests/parser/Foo-expected.gidl:
3731 * tests/parser/Foo-expected.gir:
3732 * tests/parser/Makefile.am:
3733 * tests/parser/utility-expected.gidl:
3734 * tests/parser/utility-expected.gir:
3735 * tools/g-ir-scanner:
3736 Switch over to GIR as the default format. Add a simple GIDL
3738 Update tests and fix simplify makefiles by depending
3739 on GNU make extensions.
3741 2008-04-27 Johan Dahlin <johan@gnome.org>
3743 * giscanner/xmlwriter.py:
3744 Wrap attributes for lines which are wider than 79 characters
3746 * giscanner/scannerlexer.l:
3747 Allow parenthesis in annotations
3750 * giscanner/gidlwriter.py:
3751 * giscanner/girwriter.py:
3752 * giscanner/glibtransformer.py:
3753 * giscanner/transformer.py:
3754 Add initial sequence support, including annotation.
3755 Refactor type handling a bit.
3757 2008-04-27 Johan Dahlin <johan@gnome.org>
3759 * tests/parser/Foo-expected.gidl:
3760 * tests/parser/foo-object.h:
3761 * tests/parser/foo.c (foo_object_class_init),
3762 (foo_object_get_strings), (foo_object_get_objects):
3763 Add two new functions to check sequence return values.
3764 Also fixes a compilation warning.
3766 2008-04-27 Johan Dahlin <johan@gnome.org>
3768 * giscanner/giscannermodule.c (]): Cast the getter, avoids
3769 a compilation warning.
3771 * tools/Makefile.am (g_ir_scanner_SOURCES):
3772 g-ir-scanner has no sources.
3774 2008-04-25 Johan Dahlin <johan@gnome.org>
3776 * giscanner/Makefile.am:
3778 * giscanner/gidlparser.py:
3779 * giscanner/gidlwriter.py:
3780 * giscanner/girwriter.py:
3781 * giscanner/glibast.py:
3782 * giscanner/glibtransformer.py:
3783 * giscanner/transformer.py:
3784 Split out nodes to ast.py and glibast.py
3786 2008-04-25 Johan Dahlin <jdahlin@async.com.br>
3788 * giscanner/Makefile.am:
3789 * giscanner/gidlparser.py:
3790 * giscanner/gidlwriter.py:
3791 * giscanner/girwriter.py:
3792 * giscanner/glibtransformer.py:
3793 * giscanner/gobjecttreebuilder.py:
3794 * giscanner/transformer.py:
3795 * giscanner/treebuilder.py:
3796 * tools/g-ir-scanner:
3797 Rename treebuilder to transformer and
3798 gobjectreebuilder to glibtransformer.
3800 2008-04-25 Johan Dahlin <jdahlin@async.com.br>
3802 * giscanner/Makefile.am:
3803 * giscanner/__init__.py:
3804 * giscanner/cgobject.py:
3805 * giscanner/gidlparser.py:
3806 * giscanner/gidlwriter.py:
3807 * giscanner/girwriter.py:
3808 * giscanner/gobjecttreebuilder.py:
3809 * giscanner/odict.py:
3810 * giscanner/sourcescanner.py:
3811 * giscanner/treebuilder.py:
3812 * giscanner/xmlwriter.py:
3813 * tools/Makefile.am:
3814 * tools/g-ir-scanner:
3815 Add LGPLv2 license header and install all python files
3817 2008-04-25 Johan Dahlin <jdahlin@async.com.br>
3820 * giscanner/gidlwriter.py:
3821 * giscanner/giscannermodule.c (pygi_source_directive_new),
3822 (directive_get_options), (pygi_source_symbol_new),
3823 (symbol_get_base_type), (pygi_source_type_new),
3824 (type_get_base_type), (type_get_child_list),
3825 (pygi_source_scanner_get_symbols),
3826 (pygi_source_scanner_get_directives):
3827 * giscanner/gobjecttreebuilder.py:
3828 * giscanner/sourcescanner.py:
3829 * giscanner/treebuilder.py:
3830 * tests/parser/foo-object.h:
3831 Add support for virtual methods.
3832 Pair struct FooClass with struct Foo.
3833 Clean up the SourceScanner bindings a bit.
3834 Add a testcase for virtual methods.
3836 2008-04-25 Johan Dahlin <jdahlin@async.com.br>
3838 * giscanner/cgobject.py:
3839 * giscanner/gidlwriter.py:
3840 * giscanner/gobjecttreebuilder.py:
3841 Add support for signals
3843 * tests/parser/foo.c (foo_object_class_init):
3844 * Foo-expected.gidl:
3845 Add a signal and update the expected output.
3847 2008-04-24 Johan Dahlin <jdahlin@async.com.br>
3849 * giscanner/gidlwriter.py:
3850 * giscanner/girwriter.py:
3851 * giscanner/giscannermodule.c (directive_get_name),
3852 (directive_get_value), (directive_get_options),
3853 (symbol_get_directives), (symbol_set_directives),
3854 (pygi_source_scanner_parse_file),
3855 (pygi_source_scanner_lex_filename),
3856 (pygi_source_scanner_get_directives), (init_giscanner):
3857 * giscanner/sourcescanner.c (gi_source_scanner_get_directives):
3858 * giscanner/sourcescanner.h:
3859 * giscanner/sourcescanner.py:
3860 * giscanner/treebuilder.py:
3861 * tools/g-ir-scanner:
3862 Add support for source/header annotations.
3864 2008-04-22 Johan Dahlin <jdahlin@async.com.br>
3866 * giscanner/gidlwriter.py:
3867 * giscanner/girwriter.py:
3868 * giscanner/gobjecttreebuilder.py:
3869 * giscanner/treebuilder.py:
3870 Add support for Callbacks
3872 2008-04-22 Havoc Pennington <hp@pobox.com>
3874 * girepository/ginvoke.c (g_function_info_invoke): If a symbol is
3875 not in metadata->module, look for it in the global module, in case
3876 some other object or the app itself provides the symbol.
3878 2008-04-22 Havoc Pennington <hp@pobox.com>
3880 * girepository/gmetadata.c (_g_metadata_init): hack to avoid
3881 dlopening a library that is already in the main app, by checking
3882 whether one of the lib's symbols is already loaded.
3884 2008-04-22 Johan Dahlin <jdahlin@async.com.br>
3886 * tests/parser/Foo-expected.gidl:
3887 * tests/parser/foo-object.h:
3890 2008-04-22 Havoc Pennington <hp@pobox.com>
3892 * girepository/ginfo.c (g_interface_info_find_method):
3893 Use interface_blob_size not object_blob_size to compute offset.
3895 2008-04-22 Havoc Pennington <hp@pobox.com>
3897 * girepository/gmetadata.c (_g_metadata_init): remove
3898 G_MODULE_BIND_LOCAL flag when loading libraries, since some libs
3899 (Glade and Clutter for example) rely on being loaded globally.
3901 2008-04-22 Havoc Pennington <hp@pobox.com>
3903 * girepository/ginfo.c (g_registered_type_info_get_g_type): new
3904 function to get the GType given a RegisteredTypeInfo
3906 2008-04-22 Johan Dahlin <johan@gnome.org>
3908 * COPYING: Add a LGPL license, to prevent automake to
3909 put in a copy of GPL here. Pointed out by Havoc.
3911 * girepository/ginfo.c (g_info_from_entry), (g_type_info_new),
3912 (g_type_info_is_pointer), (g_type_info_get_tag),
3913 (g_type_info_get_param_type), (g_type_info_get_interface),
3914 (g_type_info_get_array_length), (g_type_info_is_zero_terminated),
3915 (g_type_info_get_n_error_domains), (g_type_info_get_error_domain),
3916 (g_error_domain_info_get_codes), (g_enum_info_get_value),
3917 (g_object_info_get_interface), (g_object_info_get_field),
3918 (g_interface_info_get_prerequisite),
3919 (g_signal_info_get_class_closure), (g_constant_info_get_value):
3920 * girepository/ginvoke.c (get_ffi_type):
3921 * girepository/girepository.h:
3922 * girepository/gmetadata.c (g_metadata_get_dir_entry),
3923 (g_metadata_check_sanity), (validate_header),
3924 (validate_array_type_blob), (validate_iface_type_blob),
3925 (validate_param_type_blob), (validate_error_type_blob),
3926 (validate_type_blob), (validate_constant_blob),
3927 (validate_struct_blob), (validate_enum_blob):
3928 * girepository/gmetadata.h:
3929 * tests/Makefile.am:
3930 * tests/invoke/Makefile.am:
3931 * tests/invoke/invoke.c (main):
3932 * tests/roundtrips.sh:
3933 * tools/Makefile.am:
3934 * tools/compiler.c (format_output), (write_out_metadata), (main):
3935 * tools/generate.c (write_type_name), (write_type_info),
3936 (write_constant_value), (write_enum_info), (load_metadata), (main):
3937 * tools/gidlcompilercontext.c:
3938 * tools/gidlcompilercontext.h:
3939 * tools/gidlcompilerentrynode.c:
3940 * tools/gidlcompilerentrynode.h:
3941 * tools/gidlcompilertypenode.c:
3942 * tools/gidlcompilertypenode.h:
3943 * tools/gidlmodule.c (g_idl_module_build_metadata):
3944 * tools/gidlmodule.h:
3945 * tools/gidlnode.c (init_stats), (dump_stats),
3946 (g_idl_node_get_size), (g_idl_node_get_full_size),
3947 (g_idl_node_cmp), (g_idl_node_can_have_member),
3948 (g_idl_node_add_member), (g_idl_node_param_direction_string),
3949 (parse_int_value), (parse_uint_value), (parse_float_value),
3950 (parse_boolean_value), (find_entry_node), (find_entry),
3951 (serialize_type), (g_idl_node_build_metadata), (write_string):
3953 * tools/gidlparser.c (parse_type_internal):
3954 * tools/quote-file.sh:
3955 Revert revisions 157,149-148,136-129 and 120.
3956 Move back to using g-idl-generate to generate the metadata and
3957 avoids dependency on a c compiler.
3959 2008-04-22 Johan Dahlin <jdahlin@async.com.br>
3961 * giscanner/girwriter.py:
3962 * tools/g-ir-scanner:
3963 Add an initial GIR writer and a --format option to g-ir-scanner
3965 2008-04-21 Johan Dahlin <johan@gnome.org>
3967 * giscanner/cgobject.py: Use ctypes.util.find_library to locate
3968 gobject-2.0 and raise ImportError if not found.
3970 * giscanner/gidlparser.py:
3971 * giscanner/gidlwriter.py:
3972 * giscanner/gobjecttreebuilder.py:
3973 * tools/g-ir-scanner:
3974 Add a --include argument to include types from other idls.
3975 Add a minimalistic GIDL parser (just objects for now)
3976 Implement resolving of external type references and use it to
3977 resolve parent types, argument types and return types.
3979 2008-04-21 Johan Dahlin <johan@gnome.org>
3981 * giscanner/gidlwriter.py:
3982 * giscanner/gobjecttreebuilder.py:
3983 * giscanner/treebuilder.py:
3984 Add support for properties.
3985 Refactor Class/Interface support a bit, to share more code and
3986 always initialize their method attribute to an empty list.
3988 2008-04-21 Johan Dahlin <johan@gnome.org>
3990 * giscanner/cgobject.py:
3991 Add a workaround for a glib bug interface introspection bug
3992 (object_interface_list_properties, object_class_list_properties):
3993 Cast the return value to GParamSpec.
3995 * tests/parser/Foo-expected.gidl: Update
3996 * tests/parser/foo.c: Add a string property
3998 * giscanner/gobjecttreebuilder.py:
3999 After stripping namespaces, remove the original
4000 item to avoid duplication (GtkButton struct and Button object)
4002 2008-04-21 Johan Dahlin <johan@gnome.org>
4004 * giscanner/gobjecttreebuilder.py:
4005 * giscanner/treebuilder.py:
4006 Strip namespaces before objects, so we'll export
4007 GtkButton as Button in the gtk namespace
4009 2008-04-21 Johan Dahlin <johan@gnome.org>
4011 * giscanner/gidlwriter.py:
4012 * giscanner/gobjecttreebuilder.py:
4013 * giscanner/treebuilder.py:
4014 Add constructors for object/boxed types.
4016 2008-04-21 Johan Dahlin <johan@gnome.org>
4018 * giscanner/gidlwriter.py:
4019 * giscanner/gobjecttreebuilder.py:
4020 Add support for boxed types
4022 2008-04-21 Johan Dahlin <johan@gnome.org>
4024 * giscanner/giscannermodule.c: Mark structures as const,
4025 wrap SourceType.const_string.
4027 * tests/parser/foo-object.h: Add a couple of constants.
4029 * giscanner/gidlwriter.py:
4030 * giscanner/gobjecttreebuilder.py:
4031 * giscanner/treebuilder.py:
4032 Add basic support for interfaces
4034 * tools/g-ir-scanner:
4035 Add -o/--output for writing to a file
4037 2008-04-21 Havoc Pennington <hp@redhat.com>
4039 * TODO: add some C API wishlist items I could think of quickly
4041 2008-04-21 Johan Dahlin <jdahlin@async.com.br>
4043 * giscanner/gidlwriter.py:
4044 * giscanner/xmlwriter.py:
4045 Add a simple api for writing tags which can be used
4046 with the new 'with statement' in python 2.5
4048 2008-04-21 Johan Dahlin <johan@gnome.org>
4050 * giscanner/gobjecttreebuilder.py:
4051 Strip namespace and object prefix from method names.
4053 2008-04-21 Johan Dahlin <johan@gnome.org>
4055 * tools/g-ir-scanner (main): Add --pkg option to pass in
4056 pkg-config modules to get cflags from.
4058 * giscanner/gidlwriter.py (GIDLWriter._write_method):
4059 Avoid duplication, reuse function writer for methods.
4061 2008-04-21 Johan Dahlin <jdahlin@async.com.br>
4063 * giscanner/gidlwriter.py:
4064 * giscanner/gobjecttreebuilder.py:
4065 * giscanner/treebuilder.py:
4066 * tools/g-ir-scanner:
4067 Resolve libtool .la files.
4068 Strip name spaces for methods.
4069 Add function symbols
4071 2008-04-20 Johan Dahlin <jdahlin@async.com.br>
4073 * giscanner/cgobject.py:
4074 * giscanner/gidlwriter.py:
4075 * giscanner/gobjecttreebuilder.py:
4076 * giscanner/treebuilder.py:
4077 Add support for classes and methods
4079 2008-04-20 Johan Dahlin <johan@gnome.org>
4081 * giscanner/gidlwriter.py:
4082 * giscanner/gobjecttreebuilder.py:
4083 * giscanner/odict.py:
4084 Avoid conflicts, keep the output ordered similar to
4085 the order of the input.
4086 Add a simple ordered dictionary implemenation
4088 2008-04-19 Johan Dahlin <johan@gnome.org>
4090 * giscanner/cgobject.py:
4091 * giscanner/gidlwriter.py:
4092 * giscanner/gobjecttreebuilder.py:
4093 * tools/g-ir-scanner:
4094 Start introspecting get-type functions.
4095 Implement support for GLib/GFlags GTypes.
4096 Add a ctype based GObject binding.
4098 2008-04-18 Johan Dahlin <jdahlin@async.com.br>
4100 * giscanner/gidlwriter.py:
4101 * giscanner/xmlwriter.py:
4102 * tools/g-ir-scanner:
4103 Add a simplistic gidl writer, which can't do too much.
4105 2008-04-18 Johan Dahlin <johan@gnome.org>
4107 * giscanner/sourcescanner.py:
4108 * giscanner/treebuilder.py:
4109 * tools/g-ir-scanner:
4110 split tree building and source scanning interface to separate files.
4112 2008-04-18 Johan Dahlin <johan@gnome.org>
4114 * tools/g-ir-scanner (Parameter.__init__): Start constructing
4116 - Add support for struct/parameter/return, start parsing of ctypes
4118 * giscanner/giscannermodule.c: wrap GISourceType.child_list and
4121 2008-03-31 Johan Dahlin <johan@gnome.org>
4123 * tools/g-ir-scanner:
4124 Start to build abstract syntax node of scanned sources.
4125 Add support for cpp options.
4127 2008-03-27 Johan Dahlin <johan@gnome.org>
4129 * giscanner/giscannermodule.c:
4130 * giscanner/scannerlexer.l:
4131 * giscanner/sourcescanner.c:
4132 * tools/g-ir-scanner:
4134 Add simple pre-processor using subprocess and a PIPE.
4135 Change the parse_file apis to accept a file descriptor.
4137 2008-03-25 Johan Dahlin <johan@gnome.org>
4139 * giscanner/__init__.py:
4140 * tools/g-ir-scanner:
4141 Fix a typo and add an example python test program.
4143 2008-03-25 Johan Dahlin <johan@gnome.org>
4145 * giscanner/__init__.py:
4146 * giscanner/giscannermodule.c:
4147 * giscanner/sourcescanner.c:
4148 * giscanner/sourcescanner.h:
4149 Add constants and wrap a few more SymbolType fields
4151 2008-03-25 Johan Dahlin <johan@gnome.org>
4155 * giscanner/__init__.py:
4156 * giscanner/giscannermodule.c:
4157 * giscanner/Makefile.am:
4159 Add initial python bindings for the scanner and
4160 depend on python 2.5.
4162 2008-03-25 Johan Dahlin <johan@gnome.org>
4166 * giscanner/Makefile.am:
4167 * giscanner/sourcescanner.c:
4168 * giscanner/sourcescanner.h:
4169 * tools/Makefile.am:
4170 * tools/grealpath.h:
4171 * tools/sourcescanner.c:
4172 * tools/sourcescanner.h:
4174 Move the scanner to a separate library.
4176 2008-03-23 Johan Dahlin <johan@gnome.org>
4178 * tools/Makefile.am:
4181 * tools/scannerlexer.l:
4182 * tools/scannerparser.y:
4183 * tools/sourcescanner.c:
4184 * tools/sourcescanner.h:
4185 Split out the source scanner from the generator.
4186 Rename the symbols used in the scanner to use the gi_ prefix.
4187 This should make it possible to use the raw C parser from
4190 2008-03-23 Johan Dahlin <johan@gnome.org>
4192 * tests/parser/Makefile.am (utility.gidl):
4193 * tests/parser/utility-expected.gidl:
4194 Pass in the gobject.gidl since we're defining a GObject.
4196 2008-03-12 Johan Dahlin <johan@gnome.org>
4198 * relaxng/relaxng.rng:
4199 Add a releaxng in relaxng we can use to validate the relaxngs
4202 2008-03-12 Jürg Billeter <j@bitron.ch>
4204 * tools/scanner.c: (g_igenerator_new):
4205 * tools/scannerparser.y:
4206 Fix compiler warnings.
4208 2008-03-12 Jürg Billeter <j@bitron.ch>
4212 * tools/scannerparser.y:
4213 Start fixing memory management in g-idl-scanner.
4215 2008-03-12 Rob Taylor <rob.taylor@codethink.co.uk>
4217 * tools/gidlcompilercontext.c: (write_compiled):
4218 Fix critical warning when no shlib passed to g-idl-compiler.
4220 2008-03-12 Johan Dahlin <johan@gnome.org>
4222 * tests/parser/utility-expected.gidl:
4223 * tests/parser/utility.h:
4224 Add a get_type-function, so the scanner actually
4225 parses it as an object.
4227 2008-03-12 Johan Dahlin <johan@gnome.org>
4229 * tools/gidlwriter.c (function_generate): Add missing trailing quote.
4232 * tests/parser/Foo-expected.gidl:
4233 * tests/parser/Makefile.am:
4234 * tests/parser/foo-object.h:
4235 * tests/parser/foo.c:
4236 * tests/parser/utility-expected.gidl:
4237 * tests/parser/utility.c:
4238 * tests/parser/utility.h:
4240 Add a new gidl test. 'utility.gidl', which is used to be able
4241 to test external type references. Add a reference to UtilityObject*
4244 2008-03-11 Johan Dahlin <johan@gnome.org>
4248 Remove most global variables
4250 2008-03-11 Philip Van Hoof <me@pvanhoof.be>
4252 * tools/scannerlexer.l:
4254 * tests/parser/Foo-expected.gidl:
4255 * tests/parser/foo.c:
4256 * tests/parser/Makefile.am:
4257 * tests/parser/foo-object.h:
4259 Added a few extra tests. Which resulted in finding a few
4260 bugs. Which resulted in me fixing those bugs
4262 2008-03-11 Rob Taylor <rob.taylor@codethink.co.uk>
4264 * tools/gidlcompilercontext.c: (g_idl_compiler_write_dir_entry),
4265 (g_idl_compiler_write_xref_entry), (g_idl_compiler_add_xref):
4266 Add some comments for strings into generated output for
4269 2008-03-11 Rob Taylor <rob.taylor@codethink.co.uk>
4271 * tools/gidlcompilercontext.c: (write_compiled):
4272 Write out the shlibs variable before writing out the strings
4273 length. Fixes compiler warning when using '-l' flag with
4276 2008-03-11 Johan Dahlin <johan@gnome.org>
4278 * tests/parser/Foo-expected.gidl:
4279 * tests/parser/foo-object.h:
4282 * tools/scannerlexer.l:
4283 Add support for parsing return arguments. Add support for
4284 caller-owns return types.
4285 Patch by Philip Van Hoof.
4287 * tools/scannerparser.y:
4288 Remove parsing of the @deprecated syntax used in headers.
4289 We will support gtk-doc deprecation in the future instead.
4291 2008-03-11 Johan Dahlin <johan@gnome.org>
4293 * tools/compiler.c (main): Coding style fixes
4295 2008-03-10 Johan Dahlin <johan@gnome.org>
4298 Add GCOV_LIBS to GILIBS
4300 2008-03-10 Johan Dahlin <johan@gnome.org>
4302 * tests/parser/Foo-expected.gidl:
4303 * tests/parser/foo.c:
4304 Rename null-ok to direction=out
4306 2008-03-10 Philip Van Hoof <me@pvanhoof.be>
4308 reviewed and extensively tested by Johan
4310 * tests/parser/Foo-expected.gidl:
4311 * tests/parser/foo-object.h:
4312 * tests/parser/foo.c:
4315 * tools/gidlwriter.c:
4318 * tools/scannerlexer.l:
4319 * tools/scannerparser.y:
4321 Add support for scanning for gtk-doc comments inside
4322 C source files. Add tests
4324 2008-03-10 Johan Dahlin <johan@gnome.org>
4326 * tests/parser/Makefile.am:
4327 * tests/parser/foo.c:
4330 * tools/scannerparser.y:
4331 Add an api to lex filenames.
4332 Lex all source .c files passed in on the command line.
4333 Scan sources in a test and a couple of private structures
4334 which should not be included in the generated gidl
4336 2008-03-10 Johan Dahlin <johan@gnome.org>
4338 * tests/invoke/Makefile.am: Make the generated metadata
4339 depend on the g-idl-compiler
4341 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4343 * tools/gidlmodule.c
4344 * tools/gidlmodule.h
4347 Remove the old g-idl-compiler code.
4350 2008-02-22 Mark Doffman <mark.doffman@codethink.co.uk>
4352 * tools/quote-file.sh
4355 Move to using the 'C' struct compiler code.
4357 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4359 * girepository/ginfo.c
4361 Change the way that external references with no namespace
4362 are dealt with. External references with no namespace
4363 are placed into the XML as-if they are a local reference.
4364 This is temporary, but helps with roundtrip tests.
4366 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4368 * girepository/ginfo.c
4369 Add the ability to get the value of a constant of
4370 type TYPE_TAG_SYMBOL. In the case of a symbol the value
4371 is provided as a string.
4373 This would deal properly with:
4374 typedef char* random;
4375 const random = "A string";
4377 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4379 * girepository/ginfo.c
4380 * girepository/girepository.h
4382 Add a function to check if an enum is registered or not.
4383 Previously anything testing this relied on the g-type
4384 string offset having a value of 0.
4386 * girepository/gmetadata.c
4387 * girepository/gmetadata.h
4389 Remove unneccesary or erroneous checks. There were two
4390 metadata validation checks which made sure that the blob
4391 sizes were the same as some magic numbers compiled into the code.
4392 This is wrong as it breaks any forwards compatibility that may
4395 Checks were also present that made sure that unregistered type
4396 blobs had a value of 0 in the g-type offset field. This is
4397 unneccessary. If a type blob is unregistered then any value
4398 in its g-type field is simply invalid.
4400 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4402 * girepository/ginfo.c
4403 * girepository/gmetadata.c
4404 * girepository/gmetadata.h
4406 Change the metadata format to have a standard header
4407 for all the type blobs. Merge the SimpleTypeBlob
4408 and InterfaceTypeBlob into a union. A union of these
4409 two blobs existed previously but was not explicit
4410 in the metadata format.
4412 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4414 * tools/gidlcompilercontext.c
4415 * tools/gidlcompilercontext.h
4416 * tools/gidlcompilerentrynode.c
4417 * tools/gidlcompilerentrynode.h
4418 * tools/gidlcompilertypenode.c
4419 * tools/gidlcompilertypenode.h
4421 Add code to compile a tree of GIdlNodes to
4422 a 'C' struct representing the metadata.
4423 This is to aid cross-compiling. Previously
4424 the g-idl-compiler created a binary blob with
4425 data written in the byte order and alignment
4426 of the tool rather than the intended target.
4428 Cleaned up and improved by Johan and Robert :-)
4430 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4432 * girepository/ginvoke.c
4433 * girepository/girepository.h
4434 * girepository/gmetadata.c
4435 * girepository/gmetadata.h
4437 * tools/gidlparser.c
4438 Modify TYPE_TAG_INTERFACE to TYPE_TAG_SYMBOL
4439 to avoid confusion with the interface blob.
4442 * tools/gidlparser.c
4443 Remove magic numbers and replace with type-tag
4444 enumeration symbols.
4446 * girepository/gmetadata.c
4447 Add validate declaration.
4449 2008-03-10 Jürg Billeter <j@bitron.ch>
4451 * tools/gidlparser.c: (parse_type_internal):
4452 * tools/scannerlexer.l:
4453 * tools/scannerparser.y:
4454 Support C99 _Bool type in scanner.
4456 2008-03-10 Jürg Billeter <j@bitron.ch>
4458 * tests/parser/Foo-expected.gidl:
4459 * tests/parser/foo-object.h:
4460 * tests/parser/foo.c: (foo_enum_method):
4461 * tools/scanner.c: (g_igenerator_process_function_symbol):
4462 Don't skip functions that are defined in the namespace of a type
4463 that doesn't support methods, as for example enums.
4465 2008-03-10 Johan Dahlin <johan@gnome.org>
4467 * gidl.dtd: Remove, we're using relaxng for now
4469 * tests/parser/Foo-expected.gidl:
4470 * tests/parser/foo-object.h:
4471 * tests/parser/foo.c:
4472 Rename the enum/flags get_type functions to include the whole type.
4474 2008-03-08 Marc-Andre Lureau <marcandre.lureau@gmail.com>
4476 * tools/gidlwriter.c (enum_generate): added "type-name",
4477 "get-type" and "deprecated" missing arguments.
4478 * tests/parser/Foo-expected.gidl:
4479 * tests/parser/foo-object.h: test enum type, and no type.
4481 2008-03-06 Johan Dahlin <jdahlin@async.com.br>
4484 Consistent checks, add missing 'test'
4486 2008-03-05 Havoc Pennington <hp@redhat.com>
4488 * configure.ac: Take advantage of a libffi.pc if one exists, as it
4489 does on Fedora 8. Make libffi a hard requirement, since it was in
4490 practice anyway (was not really conditional in the code or
4491 makefile, only in configure).
4493 2008-02-21 Mark Doffman <mark.doffman@codethink.co.uk>
4495 reviewed by: Rob Taylor <rob.taylor@codethink.co.uk>
4496 reviewed by: Johan Dahlin <johan@gnome.org>
4498 * tests/Makefile.am:
4499 * tests/roundtrips.sh:
4500 Modify the roundtrips test so that they do not use the
4501 --raw option of the gidl compiler but instead compile a
4502 shared library to use with g_module.
4504 * tests/invoke/Makefile.am:
4505 * tests/invoke/invoke.c:
4506 Modify the invoke tests to build a shared library rather
4507 than use the --raw option.
4509 * tests/invoke/invoke-namespace-find.sh: Removed:
4510 Noone knows why this was here, so removed.
4512 2008-02-19 Rob Taylor <rob.taylor@codethink.co.uk>
4514 * tools/scanner.c: (g_igenerator_process_function_symbol):
4515 Move g_idl_node_can_have_member test later, as it broke spotting
4516 get_type's for nodes that can't have members.
4518 2008-02-18 Rob Taylor <rob.taylor@codethink.co.uk>
4521 * tools/gidlnode.c: (g_idl_node_can_have_member):
4522 Add g_idl_node_can_have_member.
4524 * tools/scanner.c: (g_igenerator_process_function_symbol):
4525 Use g_idl_node_can_have_member to test if we should add a function
4526 as a member of the type node.
4528 2008-02-18 Rob Taylor <rob.taylor@codethink.co.uk>
4530 * gidl/GLib.gidl: Renamed to gidl/gobject-2.0.gidl:
4532 * tests/parser/Makefile.am:
4533 Rename GLib.gidl to gobject-2.0.gidl and install in /usr/share/gidl.
4535 2008-02-18 Rob Taylor <rob.taylor@codethink.co.uk>
4537 * tools/scanner.c: (main):
4538 Ignore -pthread when passed to g-idl-scanner.
4540 2008-02-18 Rob Taylor <rob.taylor@codethink.co.uk>
4542 * tools/grealpath.h: Added:
4543 * tools/scanner.c: (main):
4544 * tools/scannerlexer.l:
4545 * tools/Makefile.am:
4546 Always use absolute paths with symbolic links resolved when
4547 comparing filenames.
4549 2008-02-18 Rob Taylor <rob.taylor@codethink.co.uk>
4551 * gobject-introspection.pc.in:
4552 Provide variables for g-idl-parser, scanner and compiler in the
4555 2008-02-13 Rob Taylor <rob.taylor@codethink.co.uk>
4558 * girepository/Makefile.am:
4559 * tools/Makefile.am:
4560 Rename GCOV_SOURCES to GCOVSOURCES to top automake complaining.
4562 2008-02-10 Johan Dahlin <johan@gnome.org>
4564 * tests/parser/Foo-expected.gidl:
4565 * tests/parser/foo-object.h:
4566 * tests/parser/foo.c: (foo_boxed_copy), (foo_boxed_free),
4567 (foo_boxed_get_type), (foo_boxed_new), (foo_boxed_method):
4570 2008-02-10 Johan Dahlin <johan@gnome.org>
4572 * tests/parser/Foo-expected.gidl:
4573 * tests/parser/foo-object.h:
4574 * tests/parser/foo.c: (foo_enum_get_type), (foo_flags_get_type):
4575 Add enum and flags test.
4577 2008-02-10 Johan Dahlin <johan@gnome.org>
4581 * girepository/Makefile.am:
4582 Make 'make distcheck' work again.
4584 2008-02-10 Johan Dahlin <johan@gnome.org>
4586 * m4/Makefile.am (EXTRA_DIST): its called as-compiler-flag.m4,
4589 * tests/parser/Makefile.am: Only create Foo.gidl when running make
4590 check, eg exclude it from BUILT_SOURCES.
4592 2008-02-08 Rob Taylor <rob.taylor@codethink.co.uk>
4597 * girepository/Makefile.am:
4598 * m4/Makefile.am: Added:
4599 * m4/as-compiler-flag.m4: Added:
4600 * m4/gcov.m4: Added:
4601 * tools/Makefile.am:
4602 Add ability to generate a coverage report.
4603 Adds configure option --enable-gcov and make rule 'check-coverage'.
4605 2008-02-08 Rob Taylor <rob.taylor@codethink.co.uk>
4609 * gidl/Makefile.am: Added:
4610 * girepository/Makefile.am: Added:
4611 * src/Makefile.am: Renamed to tools/Makefile.am:
4612 * src/compiler.c: Renamed to tools/compiler.c:
4613 * src/g-idl-offsets.pl: Renamed to tools/g-idl-offsets.pl:
4614 * src/generate.c: Renamed to tools/generate.c:
4615 * src/gidlmodule.c: Renamed to tools/gidlmodule.c:
4616 * src/gidlmodule.h: Renamed to tools/gidlmodule.h:
4617 * src/gidlnode.c: Renamed to tools/gidlnode.c:
4618 * src/gidlnode.h: Renamed to tools/gidlnode.h:
4619 * src/gidlparser.c: Renamed to tools/gidlparser.c:
4620 * src/gidlparser.h: Renamed to tools/gidlparser.h:
4621 * src/gidlwriter.c: Renamed to tools/gidlwriter.c:
4622 * src/gidlwriter.h: Renamed to tools/gidlwriter.h:
4623 * src/ginfo.c: Renamed to girepository/ginfo.c:
4624 * src/ginvoke.c: Renamed to girepository/ginvoke.c:
4625 * src/girepository.c: Renamed to girepository/girepository.c:
4626 * src/girepository.h: Renamed to girepository/girepository.h:
4627 * src/gmetadata.c: Renamed to girepository/gmetadata.c:
4628 * src/gmetadata.h: Renamed to girepository/gmetadata.h:
4629 * src/scanner.c: Renamed to tools/scanner.c:
4630 * src/scanner.h: Renamed to tools/scanner.h:
4631 * src/scannerlexer.l: Renamed to tools/scannerlexer.l:
4632 * src/scannerparser.y: Renamed to tools/scannerparser.y:
4633 * tests/invoke/Makefile.am:
4634 Split src/ into girepository/ and tools/
4638 * girepository/Makefile.am:
4639 * tests/Makefile.am:
4640 * tests/invoke/Makefile.am:
4641 * tests/parser/Makefile.am:
4642 * tests/roundtrips.sh:
4643 * tools/Makefile.am:
4644 Make distcheck work.
4646 2008-02-04 Rob Taylor <rob.taylor@codethink.co.uk>
4648 * tests/invoke/invoke.c: (main):
4649 * tests/invoke/testfns.c: (test6), (test7):
4650 * tests/invoke/testfns.xml:
4651 Add tests for invokation with a GList argument.
4652 Also tests caller-owns return values.
4654 2008-02-04 Rob Taylor <robtaylor@floopily.org>
4657 Add some documentation for GICallableInfo
4659 2008-02-01 Mark Doffman <mark.doffman@codethink.co.uk>
4662 Correct syntax errors in the DTD file.
4664 * relaxng/c-types.xml:
4665 * relaxng/g-types.xml:
4667 Add a RelaxNG specification for the GObject Introspection XML data.
4668 The Specification has validated all of the test files.
4670 2008-01-25 Rob Taylor <robtaylor@floopily.org>
4672 * tests/roundtrips.sh:
4673 * tests/struct.test:
4674 Add roundtrip tests for structs.
4676 2008-01-11 Johan Dahlin <johan@gnome.org>
4678 * src/scanner.c (g_igenerator_process_function_symbol):
4679 Refactor out g_idle_node_add_member.
4680 (create_node_from_gtype, create_node_from_ctype):
4681 Use case instead of if...else
4682 (get_type_from_type_id):
4683 Rename to create_node_from_gtype
4684 (get_type_from_ctype):
4685 Rename to create_node_from_ctype
4687 Rename ginode -> node, gitype -> type, gifunc -> func.
4689 * src/gidlnode.c (g_idl_node_add_member, g_idl_node_cmp):
4690 Two new functions, refactor out of scanner.c
4692 * src/scanner.c: (g_igenerator_process_function_symbol):
4693 * src/scannerlexer.l:
4694 Do not save the content of the deprecated variable, only
4697 2008-01-11 Johan Dahlin <johan@gnome.org>
4699 * tests/parser/foo-object.h: Add a couple of comment parser tests.
4701 2008-01-11 Jürg Billeter <j@bitron.ch>
4703 * src/scannerlexer.l:
4704 Fix GTK-Doc parsing.
4706 2008-01-11 Jürg Billeter <j@bitron.ch>
4708 * src/scannerlexer.l:
4709 Fix GTK-Doc parsing.
4711 2008-01-11 Jürg Billeter <j@bitron.ch>
4713 * src/scanner.c: (lookup_symbol):
4714 Return unresolved name if we find unknown symbol.
4716 2008-01-11 Jürg Billeter <j@bitron.ch>
4718 * src/scanner.c: (g_igenerator_generate):
4719 Initialize GObject to fix scanning interface properties.
4721 * tests/parser/Foo-expected.gidl:
4722 * tests/parser/foo-object.h:
4723 * tests/parser/foo.c: (foo_interface_get_type):
4724 Test interfaces with GObject prerequisite.
4726 * tests/parser/Makefile.am:
4727 Set G_DEBUG=fatal_warnings to abort test on warnings and criticals.
4729 2007-12-27 Johan Dahlin <johan@gnome.org>
4731 * src/scannerlexer.l:
4732 Parse gtk-doc comments.
4734 * src/gidlwriter.c: (function_generate):
4735 Reorganize, avoid duplication and add support for
4736 writing deprecated functions.
4738 * src/scannerparser.y:
4740 Add new structure CDirective and functions to create/free them.
4742 * src/scanner.c: (g_igenerator_process_function_symbol),
4743 (g_igenerator_process_unregistered_struct_typedef),
4744 (g_igenerator_process_struct_typedef),
4745 (g_igenerator_process_union_typedef),
4746 (g_igenerator_process_enum_typedef),
4747 (g_igenerator_process_function_typedef), (g_igenerator_add_symbol),
4748 (g_igenerator_start_preprocessor):
4749 Parse @deprecated directive for functions.
4750 Remove some more C99isms.
4751 Send in -C to cpp to avoid stripping comments.
4753 * tests/parser/foo-object.h:
4754 * tests/parser/Foo-expected.gidl:
4755 Add deprecated directive
4757 2007-12-27 Johan Dahlin <johan@gnome.org>
4759 * src/scannerlexer.l (intsuffix): Add emacs mode line and
4760 escape ' and " so it looks more like C.
4763 Unlink temporary file used.
4765 2007-12-27 Johan Dahlin <johan@gnome.org>
4767 * src/scanner.c: (g_igenerator_new), (g_igenerator_free),
4768 (g_igenerator_start_preprocessor), (main):
4770 * src/scannerparser.y:
4771 Plug a couple of simple memory leaks.
4773 2007-12-27 Johan Dahlin <johan@gnome.org>
4775 * src/scanner.c: (g_igenerator_parse_macros),
4776 (g_igenerator_start_preprocessor), (g_igenerator_set_verbose),
4779 * src/scannerparser.y:
4780 * tests/parser/Makefile.am:
4782 Improve error reporting, return when the preprocessor fails.
4783 Add a verbose parameter, to aid debugging.
4784 Revert to using a temporary file to communicate between the
4785 preprocessor and the parser, because we need to wait for
4786 the exit code from the pre-processor before starting to parse.
4788 2007-12-16 Johan Dahlin <jdahlin@async.com.br>
4790 * src/Makefile.am: Rename clexer.l to scannerlexer.l and
4791 cparser.y to scannerparser.y
4793 2007-12-11 Johan Dahlin <johan@gnome.org>
4797 * src/scanner.c: (g_igenerator_new):
4799 Get rid of the global the_generator variable.
4801 2007-12-10 Johan Dahlin <johan@gnome.org>
4803 * src/scanner.c (main): Add an output option,
4804 add checks for required parameters
4807 set BUILD_SOURCES and CLEANFILES properly
4809 * src/gidlwriter.c: (g_writer_write_inline), (g_writer_write),
4810 (g_writer_write_indent), (g_writer_write_unindent),
4811 (field_generate), (value_generate), (constant_generate),
4812 (property_generate), (function_generate), (vfunc_generate),
4813 (signal_generate), (interface_generate), (struct_generate),
4814 (union_generate), (boxed_generate), (enum_generate),
4815 (node_generate), (g_writer_write_module), (g_idl_writer_save_file):
4817 * src/scanner.c: (g_igenerator_generate):
4819 * src/scannerwriter.c:
4821 Refactor scannerwriter to only be tied to a GIdlModule and move
4822 it (again!) to gidlwriter.c. Change the writer function to take
4825 2007-12-10 Johan Dahlin <johan@gnome.org>
4828 * src/scanner.c: (g_igenerator_generate):
4830 * src/scannerwriter.c: (g_igenerator_write_inline),
4831 (g_igenerator_write), (g_igenerator_write_indent),
4832 (g_igenerator_write_unindent), (field_generate), (value_generate),
4833 (constant_generate), (property_generate), (function_generate),
4834 (vfunc_generate), (signal_generate), (interface_generate),
4835 (struct_generate), (union_generate), (boxed_generate),
4836 (enum_generate), (node_generate), (module_generate),
4837 (g_scanner_write_file):
4839 Move the scanner gidl writing to a separate source file.
4841 2007-12-10 Johan Dahlin <johan@gnome.org>
4846 Move over all CType construction functions.
4848 * tests/parser/Makefile.am:
4849 Be verbose when printing parsing tests results.
4851 2007-12-10 Johan Dahlin <johan@gnome.org>
4853 * src/scanner.c (g_igenerator_start_preprocessor): Refactor
4854 preprocessor handling to here. Start cpp insteado of cc -E,
4855 always include -U__GNUC__, since it's specific to the preprocessor
4858 * tests/parser/Makefile.am (check-local): Silent diff and skip
4859 -U__GNUC__ which is always defined now
4861 2007-12-10 Johan Dahlin,,, <jdahlin@plasttroll>
4863 reviewed by: <delete if not using a buddy>
4865 * src/scanner.c: (g_igenerator_start_preprocessor), (main):
4866 * tests/parser/Makefile.am:
4868 2007-12-09 Johan Dahlin <johan@gnome.org>
4871 Use GOption for command line options.
4872 (g_igenerator_new, main): Simplify constructor and they way
4873 parameters are passed into it.
4879 * src/gen-introspect.c:
4880 * src/gen-introspect.h:
4882 Rename gen-introspect.[ch] to scanner.[ch]
4884 2007-12-09 Johan Dahlin <johan@gnome.org>
4888 * src/Makefile.am: Rename gen-introspect to g-idl-scanner,
4889 don't make the repository library and the other utilites link against
4892 * src/gen-introspect.c: (g_igenerator_create_object),
4893 (g_igenerator_create_interface), (g_igenerator_create_boxed),
4894 (g_igenerator_create_enum), (g_igenerator_create_flags),
4895 (g_igenerator_process_module_symbol),
4896 (g_igenerator_process_module), (g_igenerator_generate), (main):
4897 * src/gen-introspect.h:
4898 Refactor g_igenerator_process_types into smaller pieces.
4900 * tests/parser/Makefile.am:
4901 Depend on the gen-introspect binary
4903 2007-12-09 Johan Dahlin <johan@gnome.org>
4905 * src/gen-introspect.c (g_igenerator_process_types):
4906 Break into smaller pieces, one for each generated node type.
4908 2007-12-08 Johan Dahlin <johan@gnome.org>
4910 * src/gen-introspect.c: (g_igenerator_process_types),
4911 (g_igenerator_add_module):
4912 * tests/parser/Foo-expected.gidl:
4913 * tests/parser/foo-object.h:
4914 * tests/parser/foo.c: (foo_subobject_class_init),
4915 (foo_subobject_init):
4917 Add a subobject test and make sure to register defined classes
4918 in the lookup symbol hash table.
4920 2007-12-08 Johan Dahlin <johan@gnome.org>
4924 * src/gen-introspect.c: (g_igenerator_new), (lookup_symbol),
4925 (g_igenerator_process_types), (g_igenerator_add_module),
4926 (g_igenerator_add_include_idl), (main):
4927 * src/gen-introspect.h:
4928 * tests/parser/Makefile.am:
4929 * tests/parser/Foo-expected.gidl:
4931 Change the gen-introspect to generate namespaced module names,
4932 such as GLib.Object instead of GObject.
4933 Add a GLib.gidl which introduces GLib.Object and GLib.InitiallyUnowned,
4934 add a --include-idl parameter to gen-introspect,
4935 and update the parser test.
4937 2007-12-08 Johan Dahlin <johan@gnome.org>
4939 * src/gen-introspect.c:
4940 Move main to the end of the file and attempt to make it valid
4943 * tests/parser/Makefile.am (BUILT_SOURCES): Remove .repo here,
4944 we're not quite ready to generate metadata yet.
4949 Add a simple gen-introspect parser test
4951 2007-12-06 Gustavo J. A. M. Carneiro <gjc@gnome.org>
4953 reviewed by: Johan Dahlin <johan@gnome.org>
4956 * gobject-introspection.pc.in:
4958 * src/compiler.c: (format_output), (write_out_metadata), (main):
4959 * src/gen-introspect.c: (main):
4960 * src/gen-introspect.h:
4961 * src/generate.c: (write_callable_info), (write_repository),
4962 (load_metadata), (main):
4963 * src/gidlmodule.c: (g_idl_module_new),
4964 (g_idl_module_build_metadata):
4966 * src/gidlparser.c: (start_element_handler):
4967 * src/ginfo.c: (g_info_new), (g_info_from_entry),
4968 (g_base_info_get_name), (g_base_info_get_namespace),
4969 (g_base_info_is_deprecated), (g_base_info_get_annotation),
4970 (g_base_info_get_metadata), (g_function_info_get_symbol),
4971 (g_function_info_get_flags), (g_function_info_get_property),
4972 (g_function_info_get_vfunc), (signature_offset), (g_type_info_new),
4973 (g_callable_info_may_return_null),
4974 (g_callable_info_get_caller_owns), (g_callable_info_get_n_args),
4975 (g_callable_info_get_arg), (g_arg_info_get_direction),
4976 (g_arg_info_is_return_value), (g_arg_info_is_dipper),
4977 (g_arg_info_is_optional), (g_arg_info_may_be_null),
4978 (g_arg_info_get_ownership_transfer), (g_type_info_is_pointer),
4979 (g_type_info_get_tag), (g_type_info_get_param_type),
4980 (g_type_info_get_interface), (g_type_info_get_array_length),
4981 (g_type_info_is_zero_terminated),
4982 (g_type_info_get_n_error_domains), (g_type_info_get_error_domain),
4983 (g_error_domain_info_get_quark), (g_error_domain_info_get_codes),
4984 (g_value_info_get_value), (g_field_info_get_flags),
4985 (g_field_info_get_size), (g_field_info_get_offset),
4986 (g_registered_type_info_get_type_name),
4987 (g_registered_type_info_get_type_init),
4988 (g_struct_info_get_n_fields), (g_struct_info_get_field),
4989 (g_struct_info_get_n_methods), (g_struct_info_get_method),
4990 (find_method), (g_struct_info_find_method),
4991 (g_enum_info_get_n_values), (g_enum_info_get_value),
4992 (g_object_info_get_parent), (g_object_info_get_type_name),
4993 (g_object_info_get_type_init), (g_object_info_get_n_interfaces),
4994 (g_object_info_get_interface), (g_object_info_get_n_fields),
4995 (g_object_info_get_field), (g_object_info_get_n_properties),
4996 (g_object_info_get_property), (g_object_info_get_n_methods),
4997 (g_object_info_get_method), (g_object_info_find_method),
4998 (g_object_info_get_n_signals), (g_object_info_get_signal),
4999 (g_object_info_get_n_vfuncs), (g_object_info_get_vfunc),
5000 (g_object_info_get_n_constants), (g_object_info_get_constant),
5001 (g_interface_info_get_n_prerequisites),
5002 (g_interface_info_get_prerequisite),
5003 (g_interface_info_get_n_properties),
5004 (g_interface_info_get_property), (g_interface_info_get_n_methods),
5005 (g_interface_info_get_method), (g_interface_info_find_method),
5006 (g_interface_info_get_n_signals), (g_interface_info_get_signal),
5007 (g_interface_info_get_n_vfuncs), (g_interface_info_get_vfunc),
5008 (g_interface_info_get_n_constants),
5009 (g_interface_info_get_constant), (g_property_info_get_flags),
5010 (g_signal_info_get_flags), (g_signal_info_get_class_closure),
5011 (g_signal_info_true_stops_emit), (g_vfunc_info_get_flags),
5012 (g_vfunc_info_get_offset), (g_vfunc_info_get_signal),
5013 (g_constant_info_get_value), (g_union_info_get_n_fields),
5014 (g_union_info_get_field), (g_union_info_get_n_methods),
5015 (g_union_info_get_method), (g_union_info_is_discriminated),
5016 (g_union_info_get_discriminator_offset),
5017 (g_union_info_get_discriminator):
5018 * src/ginvoke.c: (g_function_info_invoke):
5019 * src/girepository.c: (g_irepository_register),
5020 (g_irepository_unregister), (g_irepository_get_default),
5021 (count_interfaces), (g_irepository_get_n_infos), (find_interface),
5022 (g_irepository_get_info), (g_irepository_find_by_name),
5023 (g_irepository_get_shared_library),
5024 (g_irepository_build_search_path), (g_irepository_register_file),
5025 (g_irepository_error_quark):
5026 * src/girepository.h:
5027 * src/gmetadata.c: (g_metadata_get_dir_entry),
5028 (g_metadata_check_sanity), (validate_header),
5029 (validate_array_type_blob), (validate_iface_type_blob),
5030 (validate_param_type_blob), (validate_error_type_blob),
5031 (validate_type_blob), (validate_arg_blob),
5032 (validate_signature_blob), (validate_function_blob),
5033 (validate_callback_blob), (validate_constant_blob),
5034 (validate_value_blob), (validate_field_blob),
5035 (validate_property_blob), (validate_signal_blob),
5036 (validate_vfunc_blob), (validate_struct_blob),
5037 (validate_enum_blob), (validate_object_blob),
5038 (validate_interface_blob), (validate_errordomain_blob),
5039 (validate_union_blob), (validate_blob), (validate_directory),
5040 (validate_annotations), (g_metadata_validate), (_g_metadata_init),
5041 (g_metadata_new_from_memory), (g_metadata_new_from_const_memory),
5042 (g_metadata_new_from_mapped_file), (g_metadata_free),
5043 (g_metadata_set_module), (g_metadata_get_namespace):
5045 * tests/Makefile.am:
5046 * tests/invoke/Makefile.am:
5047 * tests/invoke/invoke-namespace-find.sh:
5048 * tests/invoke/invoke.c: (main):
5050 Add a namespace/shared library mapping. fixes #313268.
5052 2007-12-03 Johan Dahlin <johan@gnome.org>
5054 * src/gidlparser.c (parse_type_internal): Disable char/gchar and
5057 2007-11-30 Jürg Billeter <j@bitron.ch>
5063 * src/gen-introspect.c: (g_idl_node_cmp), (g_igenerator_new),
5064 (g_igenerator_write_inline), (g_igenerator_write),
5065 (g_igenerator_write_indent), (g_igenerator_write_unindent),
5066 (field_generate), (value_generate), (constant_generate),
5067 (property_generate), (function_generate), (vfunc_generate),
5068 (signal_generate), (interface_generate), (struct_generate),
5069 (union_generate), (boxed_generate), (enum_generate),
5070 (node_generate), (module_generate), (get_type_from_type_id),
5071 (str_replace), (g_igenerator_process_properties),
5072 (g_igenerator_process_signals), (g_igenerator_process_types),
5073 (get_type_from_ctype), (g_igenerator_process_function_symbol),
5074 (g_igenerator_process_unregistered_struct_typedef),
5075 (g_igenerator_process_struct_typedef),
5076 (g_igenerator_process_union_typedef),
5077 (g_igenerator_process_enum_typedef),
5078 (g_igenerator_process_function_typedef),
5079 (g_igenerator_process_constant), (g_igenerator_process_symbols),
5080 (g_igenerator_add_symbol), (g_igenerator_is_typedef),
5081 (g_igenerator_generate), (main), (csymbol_new),
5082 (csymbol_get_const_boolean), (ctype_new), (ctype_copy),
5083 (cbasic_type_new), (ctypedef_new), (cstruct_new), (cunion_new),
5084 (cenum_new), (cpointer_new), (carray_new), (cfunction_new),
5085 (eat_hspace), (eat_line), (read_identifier),
5086 (g_igenerator_parse_macros):
5087 * src/gen-introspect.h:
5089 Import gen-introspect to generate introspection information by
5092 2007-11-30 Jürg Billeter <j@bitron.ch>
5094 * src/gidlnode.c: (g_idl_node_new): support creating callback nodes
5096 2007-11-30 Jürg Billeter <j@bitron.ch>
5098 * src/gidlparser.c: (end_element_handler): Don't leave requires
5101 2007-11-29 Johan Dahlin <johan@gnome.org>
5103 * src/gidlparser.c (parse_type_internal): Add char,
5104 gchar and guchar to the builtin types.
5106 2007-11-26 Johan Dahlin <johan@gnome.org>
5108 * src/ginfo.c: (g_object_info_get_type_name),
5109 (g_object_info_get_type_init):
5110 * src/girepository.c: (g_irepository_is_registered):
5111 * src/girepository.h:
5113 Add g_object_info_get_type_name, g_object_info_get_type_init and
5114 g_irepository_is_registered.
5116 2006-08-14 Jürg Billeter <j@bitron.ch>
5118 * src/gidlparser.c: (end_element_handler): Don't leave
5119 namespace and implements states too early.
5122 2007-11-26 Johan Dahlin <johan@gnome.org>
5124 * src/gmetadata.c (validate_struct_blob):
5125 pass blob_type to validate_function_blob instead of
5126 hard-coding BLOB_TYPE_STRUCT.
5128 Patch by Torsten Schoenfeld, fixes #314190
5130 2006-10-03 Torsten Schoenfeld <tsch@cvs.gnome.org>
5132 * src/compiler.c, src/generate.c, src/gidlnode.c,
5133 src/gidlparser.c, src/ginfo.c, src/girepository.c,
5134 tests/invoke/invoke.c, test/invoke/testfns.c: Hush compiler
5135 warnings about return values, signedness mismatches, unused
5136 variables, and unhandles enum values in switch statements.
5138 * tests/invoke/Makefile.am: Don't install the invoke test program.
5139 Add -I ../../src to the cflags used for the test functions files.
5141 2005-08-31 Torsten Schoenfeld <tsch@cvs.gnome.org>
5143 * src/girepository.h: Export g_invoke_error_quark.
5145 2005-08-31 Torsten Schoenfeld <tsch@cvs.gnome.org>
5147 * src/ginvoke.c: Remove the fallback implementation of
5148 g_function_info_invoke since we now formally depend on libffi.
5150 2005-07-25 Matthias Clasen <mclasen@redhat.com>
5152 * src/Makefile, tests/Makefile, tests/invoke/Makefile:
5153 Remove these files from cvs, as they are now generated.
5155 * src/gmetadata.c (validate_iface_type_blob): Don't
5156 complain if blob->pointer is not set, since that
5157 happens for enum and flag types. (#308935, Gustavo
5160 * Commit an autoconf-conversion patch by
5161 Gustavo Carneiro (#308708)
5163 2005-05-24 Matthias Clasen <mclasen@redhat.com>
5165 * src/compiler.c (main): Use it here to validate
5166 the generated metadata.
5168 * src/gmetadata.[hc]: Add code to validate a
5171 * metadata-format.txt: Updates
5173 2005-05-22 Matthias Clasen <mclasen@redhat.com>
5175 * tests/*: Add struct offsets to field and vfunc
5178 * src/generate.c (write_vfunc_info): Write offset
5179 information for vfuncs.
5181 * src/gidlnode.c (g_idl_node_build_metadata): Write
5182 the struct offsets into the metadata.
5184 * src/gidlparser.c: Parse the offset attributes of
5185 field and vfunc elements.
5187 * src/gidlnode.h: Add offset members to field and
5190 2005-05-21 Matthias Clasen <mclasen@redhat.com>
5194 * gidl.dtd: Updates.
5196 * src/g-idl-offsets.pl: A perl script which reads a .gidl
5197 file, creates, compiles and runs a C file, and folds the
5198 resulting struct offsets back into the .gidl file.
5200 2005-05-20 Matthias Clasen <mclasen@redhat.com>
5202 * src/gidlparser.c (start_field): Make fields in objects
5205 * src/gidlmodule.c: Include string.h
5210 * metadata-format.txt: Cleanup basic types.
5211 * src/*: Adapt to the changes.
5212 * tests/*: Adapt to the changes.
5213 * examples/gdk-pixbuf.gidl: Adapt to the changes.
5215 * src/gidlnode.c (g_idl_node_get_size): Report the correct
5216 size for enum blobs.
5217 (g_idl_node_get_full_size): Report the correct size for
5220 * src/gidlmodule.c (g_idl_module_build_metadata): Add some
5221 error checking for blob sizes.
5223 2005-05-19 Matthias Clasen <mclasen@redhat.com>
5225 * src/gidlnode.c (g_idl_node_build_metadata): Correctly handle
5226 interface types for which is_pointer is FALSE, e.g. enums.
5228 * src/gidlnode.c (g_idl_node_get_full_size)
5229 * src/gidlparser.c (parse_type_internal):
5230 * src/generate.c (write_type_info): Support unspecialized
5231 lists, hashtables and errors. Also emit a '*' after these.
5235 2005-05-17 Matthias Clasen <mclasen@redhat.com>
5239 * metadata-format.txt: Cleanups by Maciej Katafiasz.
5241 2005-05-15 Matthias Clasen <mclasen@redhat.com>
5243 * src/*.c: Change the directory to be addressed by
5244 1-based indexes, and use an index of zero to mean
5247 2005-05-15 Matthias Clasen <mclasen@redhat.com>
5249 * tests/roundtrips.sh (SIMPLE_TESTS): Add union.test.
5251 * tests/union.test: Add a union test.
5253 * src/generate.c: Handle unions.
5255 * src/girepository.h:
5256 * src/ginfo.c: Add GIUnionInfo and functions to access it.
5258 * src/gidlnode.c: Handle GIdlNodeUnion nodes.
5260 * src/gidlparser.c (start_union): Parse <union> elements.
5262 * src/gidlnode.h: Add a GIdlNodeUnion.
5264 * gidl.dtd: Add a <union> element.
5266 * src/gmetadata.c (g_metadata_check_sanity): Check
5269 * src/gmetadata.h: Add union_blob_size to Header,
5272 * metadata-format.txt: Add a UnionBlob.
5274 2005-05-13 Matthias Clasen <mclasen@redhat.com>
5276 * tests/*: Update testcases.
5278 * src/generate.c (write_callable_info): Don't forget to
5279 write transfer and null-ok attributes for return types
5282 * src/girepository.h:
5283 * src/ginfo.c (g_callable_info_may_return_null):
5284 New function to find out if a function may return NULL.
5286 * src/compiler.c (format_output): Make the generated
5289 * README: Point to a recent libffi snapshot.
5291 * tests/invoke/*: Some invoke tests.
5293 * src/Makefile: Add ginvoke.c and the necessary
5296 * src/girepository.h (g_function_info_invoke): Add
5299 * src/ginvoke.c (g_function_info_invoke): Initial
5300 implementation of invoke functionality based on libffi.
5302 * src/gidlnode.c (g_idl_node_build_metadata): Pass the
5303 strings and types hash tables in the right order when
5305 (find_entry_node): Free the name parts.
5307 2005-05-12 Johan Dahlin <johan@gnome.org>
5309 * src/generate.c: Generate consistent end tags.
5313 2005-05-12 Matthias Clasen <mclasen@redhat.com>
5317 * src/gidlparser.c (start_function): Actually add
5318 methods to objects. (Steven Walter)
5320 * src/girepository.h:
5321 * src/ginfo.c: Rename Transfer and Direction to
5322 GITransfer and GIDirection. (Torsten Schoenfeld)
5324 * tests/*: Make tests work with the changes in name
5327 * src/gidlnode.c (find_entry_node): Parse qualified
5328 names and generate xref nodes for them if needed. Don't
5329 require all modules to be loaded any more.
5331 * src/gidlmodule.c (g_idl_module_build_metadata): Choke
5334 * src/ginfo.c (g_object_info_get_parent): Return NULL
5335 if blob->parent is 0. Still need to make sure index
5338 * src/generate.c: Generate qualified names when
5339 referring to non-local types. Emit transfer attribute
5342 * src/compiler.c (format_output): Put the function
5343 attributes where gcc accepts them.
5345 2005-05-11 Matthias Clasen <mclasen@redhat.com>
5347 * src/compiler.c (main): Add a --verbose cmdline option
5348 and only log messages if it is specified.
5351 * src/gidlnode.c (init_stats, dump_stats): Collect some
5352 statistics on string and type sharing.
5354 * src/gidlmodule.c (g_idl_module_build_metadata): Use
5355 g_message() instead of fprintf().
5357 * src/gidlnode.c (g_idl_node_free): Make this more robust.
5358 (g_idl_node_get_size): Implement for structs.
5359 (g_idl_node_get_full_size): Handle parent being NULL.
5360 (serialize_type): Handle lookup failures more gracefully.
5362 2005-05-10 Matthias Clasen <mclasen@redhat.com>
5364 * src/gidlnode.c (g_idl_node_get_full_size): Correct the
5365 size calculation for 2-parameter types and for objects.
5367 * src/compiler.c: Add a cmdline option for debug output
5368 and install a log handler to implement it.
5369 * src/gidlnode.c: Add some debug spew.
5373 * src/gidlmodule.c (g_idl_module_build_metadata): Don't
5374 forget to count the module name when calculating the
5375 required size for the metadata.
5378 * src/gidlparser.c: Fix compiler warnings.
5380 2005-05-09 Matthias Clasen <mclasen@redhat.com>
5382 * src/compiler.c (main): Free the option context.
5384 * gidl.dtd: Clean up handling of names. All elements
5385 have a "name", only the elements corresponding to
5386 actual callable functions (function, method, constructor),
5387 have an additional "symbol" attribute holding the
5388 dlsym()-able function name.
5390 * src/generate.c: Adapt to generate xml matching the
5394 * src/gidlnode.c: Adapt to parse the new dtd.
5396 * tests/*.test: Adjust to the new dtd.
5398 * metadata-format.txt:
5399 * src/gmetadata.h: Remove the short_name field
5401 * src/gmetadata.c: Shrink size of ValueBlob to 12.
5402 * src/girepository.h:
5403 * src/ginfo.c (g_value_info_get_short_name): Removed
5405 2005-05-09 Matthias Clasen <mclasen@redhat.com>
5407 * gidl.dtd: Allow constructors for boxed types,
5408 patch by Jonathan Blandford.
5411 2005-05-09 Matthias Clasen <mclasen@redhat.com>
5413 * --- Initial import ---