Skip to content

goocanvas-3.0: Prepare sources for building with Visual Studio

Chun-wei Fan requested to merge prep-msvc-3.0 into goocanvas-3.0

Hi,

This MR attempts to prepare the headers (and thus the code) to be usable for building and usage with Visual Studio compilers, by:

  • Adding a header, goocanvasexports.h, that defines macros to be used to mark APIs and public variables that should be exported (and to be imported properly, in the cases of public variables). The public headers, as well as goocanvasatk.h (since the items there need to be introspected) have been updated accordingly.

  • Make sure that goocanvasatk,c includes goocanvasatk.h, so that things in there do indeed get exported on Visual Studio-style builds.

  • Update how goocanvasenumtypes.h is generated, so that the prototypes there are also marked with the macros we added in goocanvasexports.h.

This does not attempt to add a build system for Visual Studio-like builds, since any needed updates for that should go into the new Meson port that is being under work.

With blessings, thank you!

Merge request reports