summaryrefslogtreecommitdiff
path: root/tools
Commit message (Collapse)AuthorAgeFilesLines
* tools/defs_gen/h2def.py: Recognize Graphene type namesHEADmasterKjell Ahlstedt2023-04-261-3/+16
| | | | A typical type name is not GraphenePoint, but graphene_point_t.
* Add Gio::Subprocess, SubprocessLauncher and examples/subprocessKjell Ahlstedt2023-04-171-0/+5
| | | | Fixes #106
* gmmproc: Generate callback functions with C linkageKjell Ahlstedt2023-04-093-12/+79
| | | | | | | | | | | * tools/m4/signal.m4: Add an optional parameter to _SIGNAL_PH. * tools/m4/vfunc.m4: Add an optional parameter to _VFUNC_PH. * tools/pm/Output.pm: output_wrap_vfunc_h(): Add $objCDefsFunc->args_names_only() in call to _VFUNC_PH. output_wrap_default_signal_handler_h(): Add $objCDefsFunc->args_names_only() in call to _SIGNAL_PH. Part of issue #1
* generate_wrap_init.pl.in: Disable warning C4273Chun-wei Fan2023-01-091-0/+7
| | | | | | | | | | | | ... for Visual Studio builds, as GLib 2.75.x and later applied __declspec(dllimport) via macros to DLL builds of the GLib libraries, meaning that when we put the GQuark and GType function prototypes into wrap_init.cc warning C4273 will be raised as the prototypes in wrap_init.cc does not have any dllimport decorations (and would not have otherwise mattered). This allows builds with '-Dwarnings=fatal' to proceed with Visual Studio builds.
* Add Gio::BytesIconKjell Ahlstedt2022-12-021-0/+1
| | | | | | | | | | | | | * gio/giomm.h: * gio/giomm/meson.build: * gio/src/filelist.am: Add BytesIcon. * glib/src/bytes.[ccg|hg]: Add Glib::Value specialization. Required by _WRAP_PROPERTY in bytesicon.hg. * tools/extra_defs_gen/generate_defs_gio.cc: Add G_TYPE_BYTES_ICON. * gio/src/gio_signals.defs: Add BytesIcon property. * gio/src/bytesicon.[ccg|hg]: New files. Fixes #107
* Gio: Add some methods for glibmm 2.74Kjell Ahlstedt2022-08-221-0/+1
| | | | | | | | | | | | | * configure.ac: * meson.build: Require glib-2.0 >= 2.73.2. * gio/src/appinfo.hg: Add get_default_for_type_async/finish(), get_default_for_uri_scheme_async/finish(). * gio/src/file.hg: Add make_symbolic_link_async/finish(). * gio/src/liststore.hg: Add property_n_items(). * gio/src/resolver.hg: Add enum Resolver::NameLookupFlags, lookup_by_name_with_flags(), lookup_by_name_with_flags_async/finish(). * gio/src/gio_docs_override.xml: * tools/m4/convert_gio.m4: Add conversions for Resolver::NameLookupFlags.
* gmmproc: Make h2def.py recognize G_DEFINE_AUTOPTR_CLEANUP_FUNCKjell Ahlstedt2022-07-231-0/+4
|
* gmmproc, DocsParser.pm: Improve the handling of gi-docgen syntax, part 3Kjell Ahlstedt2022-07-071-0/+3
|
* gmmproc: Improved handling of final typesKjell Ahlstedt2022-06-081-8/+49
| | | | | | | | | | | Some GObject-derived classes shall not be derived from. * glib/glibmm/class.cc: * glib/glibmm/interface.cc: Don't derive or add interfaces to a class if G_TYPE_IS_FINAL(gtype) is true. * tools/m4/class_shared.m4: Fix gtype_ when _DO_NOT_DERIVE_GTYPE is used. Add _ABI_AS_WITH_DERIVED_GTYPE, making it possible to add _DO_NOT_DERIVE_GTYPE without breaking ABI.
* Update tools/test_scripts/testheaders.shKjell Ahlstedt2022-06-011-5/+15
|
* Add Gio::AppInfoMonitorKjell Ahlstedt2022-02-161-0/+1
| | | | Fixes #97
* meson.build: Specify 'check' option in run_command()Kjell Ahlstedt2022-02-142-3/+4
| | | | | | The default value will be changed in future Meson releases. Don't use deprecated python3.path() and execute(..., gui_app: ...).
* gmmproc: Add "ignore_deprecations" argument in _WRAP_METHOD()Kjell Ahlstedt2021-11-263-8/+20
| | | | | Makes it easier to suppress deprecation warnings when a C method has been deprecated, but the corresponding C++ method shall not (yet) be deprecated.
* Glib, Gio: Add some methods for glibmm 2.70Kjell Ahlstedt2021-10-051-0/+1
| | | | | | | | | | | | | | | | | | * configure.ac: * meson.build: Require glib-2.0 >= 2.69.1. * glib/src/binding.[ccg|hg]: Add dup_source(), dup_target(), Deprecate get_source(), get_target(). * glib/src/spawn.[ccg|hg]: Change parameter name, exit_status to wait_status. * glib/src/timezone.[ccg|hg]: Add operator bool(), create_identifier(). Deprecate create(). * gio/src/fileinfo.hg: Add get/set_access_date(), get/set_creation_date(). * gio/src/notification.hg: Add set_category(). * gio/src/tlscertificate.hg: Add property/get_not_valid_before(), property/get_not_valid_after(), property/get_subject_name(), property/get_issuer_name(). * gio/src/tlsconnection.hg: Add enum Gio::TlsProtocolVersion, property/get_protocol_version(), property/get_ciphersuite_name(). * tools/m4/convert_gio.m4: Add conversion for enum TlsProtocolVersion.
* handle-built-files.py: Specify file encoding on generated filesKjell Ahlstedt2021-07-161-5/+2
| | | | | The default file encoding is platform dependent in Python. Better specify which encoding is preferred.
* gmmproc, DocsParser.pm: 2nd improve the handling of gi-docgen syntaxKjell Ahlstedt2021-06-041-18/+15
|
* gmmproc, DocsParser.pm: Improve the handling of gi-docgen syntaxKjell Ahlstedt2021-06-011-24/+65
|
* gmmproc, DocsParser.pm: Handle gi-docgen syntax in documentationKjell Ahlstedt2021-05-251-11/+73
| | | | | | | | | | gtk4 has started using gi-docgen instead of gtk-doc. It has a different syntax for referring to methods, signals, properties and other stuff in the documentation. gmmproc does not handle the gi-docgen syntax perfectly when it converts to Doxygen syntax and C++ names. It has never handled gtk-doc syntax perfectly, either. Hopefully it's good enough in most cases.
* error.h Avoid exporting class deriving frm std::exceptionChun-wei Fan2021-05-071-5/+5
| | | | | | | | | This will avoid having the ABI tied to a particular STL and compiler version, and so will eliminate C4275 compiler warnings when building the code. Also update gerror.m4 so that it will generate code deriving from Glib::Error with the export macro markings with the member functions, so that things continue to build properly
* Subprojects can use meson.add_dist_script() if meson.version() >= 0.58.0Kjell Ahlstedt2021-05-051-2/+5
| | | | | | | | | | | * meson.build: * docs/reference/meson.build: * gio/giomm/meson.build: * glib/glibmm/meson.build: Call add_dist_script() in a subproject, if meson.version() >= 0.58.0. * tools/build_scripts/handle-built-files.py: Use MESON_PROJECT_DIST_ROOT if it exists, else MESON_DIST_ROOT. It exists if meson.version() >= 0.58.0.
* Meson build: Make quiet installations possibleKjell Ahlstedt2021-04-191-1/+3
| | | | | | * tools/build_scripts/handle-built-files.py: Don't print names of installed files if environment variable MESON_INSTALL_QUIET is set. It is set by "meson install --quiet" in Meson 0.54.0 and newer.
* Meson build: No implicit_include_directoriesKjell Ahlstedt2021-04-081-0/+2
|
* Meson build: No implicit_include_directoriesKjell Ahlstedt2021-03-261-0/+1
| | | | | | | It shall not be possible to find a glibmm header file with #include <xxx.h> instead of #include <glibmm/xxx.h>. Not fully fixed until https://github.com/mesonbuild/meson/issues/8562 has been fixed.
* Add tools/defs_gen/enumextract.pyKjell Ahlstedt2021-03-174-1/+472
| | | | | A Python script that can replace the Perl script tools/enum.pl. Why? Just because I've got fond of Python.
* Meson build: Make it possible to use glibmm as a subprojectKjell Ahlstedt2021-03-122-2/+17
| | | | glib and sigc++ can be subprojects of glibmm.
* tools/gen_scripts: Ignore gio/gwin32api-*.hKjell Ahlstedt2021-03-062-4/+4
| | | | | Ignore some new glib header files when generating gio/src/gio_enums.defs and gio/src/gio_methods.defs.
* Change the ABI to glibmm-2.68Kjell Ahlstedt2020-12-112-7/+7
| | | | | | | So we can use the 2.66 version numbers for stable releases in the glibmm-2.4 ABI series. We've done similar ABI name changes several times before.
* Remove unnecessary TODO and README filesKjell Ahlstedt2020-11-193-17/+0
|
* generate_wrap_init.pl.in: Use g_type_ensure()Kjell Ahlstedt2020-11-181-7/+1
| | | | | | | | | | | Call g_type_ensure(SomeClass::get_type()). Redefining the G_GNUC_CONST preprocessor macro does not have the intended effect (SomeClass::get_type() actually being called) if the package is compiled and linked with the -flto option. LTO = link time optimization https://mail.gnome.org/archives/gtkmm-list/2020-November/msg00009.html
* Meson build: Fix versioning on macOS for libglibmm_generate_extra_defsKjell Ahlstedt2020-10-011-1/+3
|
* class_interface.m4: Export the generated private classChun-wei Fan2020-08-311-1/+1
| | | | | | As in the case of class_shared.m4, we need to do the same for class_interface.m4 as well, in order to export the items in the private headers fully.
* Merge branch 'private-export' into 'master'Chun-wei Fan2020-08-301-1/+1
|\ | | | | | | | | class_shared.m4: Decorate private class prototype if `_WRAP_GOBJECT` has a function decoration specified (master branch) See merge request GNOME/glibmm!39
| * class_shared.m4: Decorate private class prototypeChun-wei Fan2020-08-281-1/+1
| | | | | | | | | | | | ...when using _WRAP_GOBJECT with a function decoration. This will help expose the class definition in the generated private/*_p.h in the built DLLs/LIBs that is built with Visual Studio or clang-cl.
* | gmmproc: Make h2def.py recognize more macrosKjell Ahlstedt2020-08-291-2/+6
|/ | | | | When parsing function declarations, remove G_DECLARE_DERIVABLE_TYPE and GDK_DECLARE_INTERNAL_TYPE.
* gmmproc: _CLASS_BOXEDTYPE, _CLASS_OPAQUE_COPYABLE: Fix move assignmentKjell Ahlstedt2020-07-112-2/+2
| | | | | Add a std::move() to avoid copying. Fixes #76
* Meson/Visual Studio builds: Include toolset version by defaultChun-wei Fan2020-06-181-2/+2
| | | | | | | | | | | | | | | | | | This makes the built DLL and .lib's contain the toolset version if the build is carried out using Visual Studio 2017 or later, unless the 'msvc14x-parallel-installable' option is set to be false during configuration. The reasoning behind this change is that there are subtle problems when, for instance, one tries to link to a Visual Studio 2017-built glibmm when building gtkmm and libxml++ with Visual Studio 2019. This is unfortunate as Microsoft did try hard to make interoperating between binaries built with Visual Studio 2015, 2017 and 2019 as easy as possible in terms of ABI and API, but unfortunately this hits the corner cases where this compatibility does not work. As the name suggests, this attempts to make Visual Studio 2017 and 2019 builds share a single set of underlying C DLLs easier, while avoiding breakages caused by such subtle differences.
* tools/defs_gen/*.py: Specify that this is python3 codeKjell Ahlstedt2020-05-213-6/+4
| | | | | | Specify #!/usr/bin/env python3, making it unnecessary to have a python command which is a link to python3. In h2def.py, use the built-in set() instead of Set() from the sets module.
* tools/m4/compare.m4: Allow decorating comparison operatorsChun-wei Fan2020-04-111-14/+21
| | | | | | This allows one to pass in deocrations for the comparison operators so that those decorations may be defined as compiler directives to export symbols in a more fine-grained manner.
* tools/[gerror|enum].m4: Make template<> classes exportableChun-wei Fan2020-04-044-13/+15
| | | | | | | | | Allow to apply the decl_prefix argument onto the template<> classes that we generate for the _WRAP_GERROR and _WRAP_ENUM directives in the various *.hg files, if specified. Please note that this is done in GNU m4 style for enum.m4 since we are using the 10th argument.
* Meson build: Install generate_extra_defs.hKjell Ahlstedt2020-03-192-8/+7
| | | | Fixes #70
* Change the ABI to glibmm-2.66Kjell Ahlstedt2020-03-172-7/+7
| | | | | | | | | So we can use the 2.64 version numbers for stable releases in the glibmm-2.4 ABI series. We don't need to release a stable ABI-parallel glibmm until we need to release gtkmm 4.0, and that won't happen until GTK 4.0.0 happens. We've done similar ABI name changes several times before.
* m4: Apply function decoration more thoroughlyChun-wei Fan2020-03-095-5/+5
| | | | | | Apparently more items in the generated code must be marked with the function decoration that is specified, otherwise the exported symbols will not be complete.
* tools: Allow generating Glib:Error class with decorationsChun-wei Fan2020-03-073-12/+18
| | | | | | | | This allows one to export the generated Glib::Error class with decorations so that one may be able to use this to export it using compiler directives. This allows specifications that start with decl_prefix, and this also decorates the `friend wrap_init() method in the generated Glib::Error class
* tools/m4: Allow one to decorate the generated wrap() prototypeChun-wei Fan2020-03-056-5/+20
| | | | | This allows the compiler to use the decoration macro to export those methods from the generated items
* Meson build: Add some dependencies when generating source filesKjell Ahlstedt2020-03-021-3/+4
| | | | | wrap_init.cc shall be rebuilt when generate_wrap_init.pl has been rebuilt. Generated .h and .cc files shall be rebuilt when gmmproc has been rebuilt.
* tools: Fix 'meson dist'Chun-wei Fan2020-03-022-31/+20
| | | | | | | | | The former method of using gendef.exe to generate the import library for glibmm_generate_extra_defs somehow breaks 'meson dist' and builds from release tarballs, unless one builds giomm first. Fix this by using the __declspec(dll[ex|im]port) directives, since glibmm_generate_extra_defs is a simple utility library.
* meson: Build items in tools/extra_defs_gen on MSVC tooChun-wei Fan2020-03-021-13/+41
| | | | | | | | | | Ensure we can generate the import lib for glibmm_generate_extra_defs on Visual Studio builds by using the same technique we used for glibmm and giomm, and build the two programs that is to be built along side with it. Also re-order the items in meson.build a bit so that we are able to use our gendef tool.
* tools: Use POSIX-style path for m4 in gmmprocChun-wei Fan2020-03-021-1/+1
| | | | Otherwise the script gets confused as the slashes were not escaped
* Add support for building glibmm with MesonKjell Ahlstedt2020-03-0113-0/+506
| | | | | | glibmm can be built with either Autotools or Meson. See MR !27
* Prepare existing files for building with MesonKjell Ahlstedt2020-03-012-3/+7
| | | | | | | | * examples/network/resolver.cc: Don't include config.h. It's not used. * glib/glibmm/ustring.cc: Check if GLIBMM_SIZEOF_WCHAR_T is defined. * tools/generate_wrap_init.pl.in: * tools/gmmproc.in: Change '\@' to '\ @'. Meson's configure_file() removes a backslash immediately before an at-sign.