Add rules in the helper NMake Makefiles to generate the GResource
sources for gtk3-widget-factory. This prepares for us to add project
files to build that demo program.
The source listing is not likely to change for this one, so clean up the
build files a bit, and make the gtk3-icon-browser MSVC project a
complete one instead of a template.
This way, we can re-use items when we want to support generating project
files from the templates, such as building with project files directly
from a GIT checkout, or when we add sources and want to quickly add them
into the project files.
Use VS1X instead of VS10 in the variable names in the NMake Makefiles,
since the VS2010 MSBuild Visual Studio project files really apply to all Visual
Studio versions at or after VS2010.
Also use variable substitution here to ease future maintenance.
It is probably still possible with older GLib and GObject-Introspection
versions, but it is certainly not recommended with the advent of Meson.
One will not be able to re-generate demos.h.win32 (for
enabling/disabling the Font Features Demo) with Python 2.7.x-Python 3.x
or PERL must be used.
Append the detected Visual Studio version and target arch to the various
NMake Makefile snippets we generate on the fly, so that if multiple
items access the helper NMake Makefiles at the same time, we will be
much less prone to trouble.
This is not 100% fool-proof, but should make things much more robust when
attempting to build via different Visual Studio versions and configs at
the same time.
The scripts that are used during the build to generate the sources now
do require Python 3.x to work, so make this clear to people.
In the Visual Studio projects, update the default Python installation to
correspond with Python 3.7.x or later, which is the lowest supported
version series of Python at this point.
This uses CVDisplayLink to drive the GdkFrameClock. A GdkWindow
can register a frame callback to thaw their frame clock as necessary
based on the next notification from CVDisplayLink.
CVDisplayLink notifies us on a high-priority thread. We use the same
NSEventas gdkeventloop-quartz.c to wakeup the main loop. This is done
so that we don’t pathologically wake up the select thread to then
continue notifying the main loop.
We use an embedded GList node in the GdkWindowImplQuartz so that we
can avoid allocating any lists or arrays for pending frame callbacks.
Compare this to the same design in GdkWindow for children.
We no longer use the autotools 'dist-hook' to generate the items that we
need to build introspection with the Visual Studio projects, so drop the
autotools files and bits that we had to support this. So, for
introspection on Visual Studio via the project files, it is purely via
NMake at this point.
By doing so, we can drop the autotools rules that we use to generate the
file lists and rules for building introspection via NMake Makefiles for
Visual Studio builds via the project files.
Like what was done in the *.vcxprojin templates, consolidate project configs
that are repetitive, and use the 'Condition=' directive to distinguish between
configuration and/or target platform differences.
...for Visual Studio 2010 and later, since we used to copy them and
merely update the value of $(VSVer) during 'make dist' as needed.
Instead of doing that, move the property sheets for Visual Studio 2010,
which is the base version that we use, into a directory of its own, and
make the Visual Studio 2010~2022 projects look for them in that
directory, and set VSVer according to the toolset version identified by
each of the project files.
The ARM64-specific property sheet needed for VS2017 and the VS2008
property sheets will remain as they are.
We can again use MSBuild trickery to do what was done in the dropped
property sheet.
Unfortunately, like the last commit, I couldn't figure out a way do to
something similar in the VS2008 project files... :|
... and so stop using gtk3-install.[vsprops|props], and remove that
property sheet from the dist and dist the NMake Makefile for the
purpose.
Also remove win32/vs10/gtk3-install.vcxproj.filters as well, as it is
no longer needed.
We will remove the gtk3-install.[vsprops|[props][.in] in a subsequent
commit.
This is an NMake Makefile that will replace the property sheets in the
Visual Studio project files so that we can call it from the project
files to "install" the binaries and introspection files that were built,
along with the header files and other data files, which aims to be
easier to maintain for the current approach.
This will also be expanded upon to optionally build the translation
files and make the installed files more in-line with what are done in
the Meson build files, where there could be compatibility problems with
older Visual Studio toolchains.
This is a follow-up commit so that the generated GResources sources for
the demos are included in the project files.
As a result, don't include demo_resources.c when regenerating
gtk3-demo.vc[x]proj for toggling on or off the font features demo, as it
would have been there.
The Visual Studio projects have support for generating these, especially
that the encoded string that result from them may become too big for the
Visual Studio compiler to handle (such as for gtk3-demo) and we are normally
supposed to generate the GResources sources for all builds, as the
generated code depends on the compiler being used).