Commit Graph

47 Commits

Author SHA1 Message Date
Christoph Reiter
94555371f5 meson: print disabled backends in the final build summary
It's easy to miss what's not getting build otherwise
2019-06-17 17:50:42 +00:00
Christian Hergert
ef67eb0b3c gdk: backport GdkProfiler
This is a backport of the GdkProfiler from master. It does not include
the pixel bandwidth numbers that come from gdkdrawcontext.c since there
does not seem to be an analog in 3.x.

Additionally, this implements the recent changes for SYsprof's D-Bus
profiler API which adds a Capabilities property and an options hash-table
to the D-Bus interface for forward portability.
2019-06-06 17:17:20 -07:00
Christoph Reiter
6536646720 build: Remove mingw check for SetupDiGetDevicePropertyW
It was mssing when the check was added in 2016, but was fixed upstream
in https://github.com/mirror/mingw-w64/commit/9ef49367378c50553943bd
shortly after.

Assume everyone has updated by now.

See !861 for a related change on the master branch.
2019-05-21 09:18:55 +02:00
Nirbheek Chauhan
6bdc1137f2 Merge branch 'fix-meson-on-macos' into 'gtk-3-24'
meson: Fix build on macOS

See merge request GNOME/gtk!735
2019-04-12 06:12:29 +00:00
Chun-wei Fan
a4410e9c01 meson.build: Clean up previous commit
Don't hardcode things, and move only deduce `current` for non-Visual
Studio builds, as it is only used there.
2019-04-12 14:01:31 +08:00
James Westman
9d9b023166 meson: Fix build on macOS
Previously, Meson failed to run on macOS. This was because a value that should
have been an array of strings was instead a single string.
2019-04-12 00:30:23 -05:00
Chun-wei Fan
f5408e5061 meson.build: Fix Visual Studio builds
Commits a04fef4 and cc7f9c4 inadvertedly broke Visual Studio builds as
it caused the following to show up when configuring:

gdk\meson.build:281:0: ERROR: Invalid Shared library version "vs9.2404.4". Must be of the form X.Y.Z where all three are numbers. Y and Z are optional.

Since we do not set a library version that mingles with the minor and
micro versions, along with libtool current for any Visual Studio builds,
just set those versions as 3 on Visual Studio builds, and things should
work the way they did before.
2019-04-12 11:29:52 +08:00
Christoph Reiter
cc7f9c44e4 meson: Also add a library version for libgailutil
See a04fef4b9e
2019-04-11 21:21:50 +02:00
Emmanuele Bassi
ce86b411f8 meson: Update versions
GTK 3.24.8 was just released.
2019-04-11 19:34:06 +01:00
Emmanuele Bassi
a04fef4b9e meson: Preserve compatibility with Autotools build
The Meson build is missing the libtool versioning of the shared
libraries.
2019-04-11 19:33:25 +01:00
Christoph Reiter
749a58ab26 meson: simplify builtin_immodules build option
Make it a yes/no/auto combo. "yes" means all modules are built into libgtk,
"no" that none are and "auto" uses the platform defaults, yes on win32,
no otherwise.

If we need more we can always extend it later.
2019-04-11 16:46:22 +02:00
Christoph Reiter
3462fcf9a0 meson: Follow gnome conventions for build option names 2019-04-11 16:46:22 +02:00
Chun-wei Fan
0432b22e02 meson.build: Output DLL names similar to the MSVC projects
This makes the DLL names match those that are produced by the Visual
Studio projects by default.

This, currently, however, names the .lib files same as the ones that
are produced for other platforms (i.e. <libname>-3.lib).  This is
actually not that bad as one can just copy those .lib's into
<libname>-3.0.lib when needed and the binaries that link to those .lib's
ultimately link to the same DLLs, so this should not harm binary
compatibility.
2019-04-11 16:46:22 +02:00
Chun-wei Fan
33589f154e meson.build: Fix generating .pc files
It may be so that Cairo is not found using pkg-config files, so we
cannot just use .name() on the Cairo deps directly.

Since we already have a similar mechanism for generating the GDK .pc
files, re-use and share that mechanism.
2019-04-11 16:46:22 +02:00
Chun-wei Fan
d2ef356f1d meson.build: MSVC-Add fallback dep search for HarfBuzz
It seems that Meson 0.50.0 broke dependency search using CMake for
HarfBuzz at least, so we add a workaround for it to look for the
HarfBuzz headers and libraries manually when we couldn't find HarfBuzz
using the pkg-config and CMake method.
2019-04-11 16:46:22 +02:00
Christoph Reiter
c5789127a7 meson: set soversion to 'vs<VSVer>' for MSVC
This should result in <libname>-vs<VSVer>.dll filenames.
2019-04-11 16:46:22 +02:00
Christoph Reiter
28833783cc meson: Various config.h related fixes
Various adjustments to make the config.h output between autotools
and meson more similar by testing on Linux and Windows/MSYS2.

Setting things to 1 instead of true and shifting things around is motivated
by reducing the diff between the generated files.
2019-04-11 16:46:22 +02:00
Christoph Reiter
068f7f7423 meson: set the soversion to just '0' everywhere
This is what glib did for the meson port, so can't be that wrong.
This also makes the DLL names match the autotools Windows DLLs.
2019-04-11 16:45:37 +02:00
Christoph Reiter
65f2fe828c meson: statically link immodules under mingw by default
To match what the autotools build does right now.
2019-04-11 16:45:37 +02:00
Christoph Reiter
e47440def5 meson: Don't make the man pages build depend on the documentation option
Include all meson build files under docs/ and check with get_option() there.
2019-04-11 16:45:36 +02:00
Christoph Reiter
26d32f3bd0 meson: build all input modules; fix static build on Linux 2019-04-11 16:45:36 +02:00
Christoph Reiter
310dc4b6c4 meson: cloudproviders fixes
Set min cloudproviders version.
Add libcloudproviders to gdk Requires.private.
CI: build/test with cloudproviders
2019-04-11 16:45:36 +02:00
Christoph Reiter
59055fd9f7 meson: set interface age; pass soversion to libgdk as well 2019-04-11 16:45:36 +02:00
Christoph Reiter
a33bf3da56 meson: Install gail-3.0.pc and gtk-3.0.m4 2019-04-11 16:45:36 +02:00
Christoph Reiter
490cf8dff6 meson: make the gtk/gdk .pc files match autotools on Linux
Try to include the same things and in a similar order so differences
are easier to catch.

This also adds the backend specific .pc files for gdk like gdk-x11-3.0.pc
2019-04-11 16:45:36 +02:00
Christoph Reiter
212efbdd81 meson: build docs and man pages
Lots of warnings, so something is probably still missing.
2019-04-11 16:45:36 +02:00
Christoph Reiter
5a84730b4a meson: build and install translations 2019-04-11 16:45:36 +02:00
Christoph Reiter
09fe0b0edc meson: disable some broken immodules for now
To fix the build.
We need to port the source generation logic from gtk4 for this.
2019-04-11 16:45:36 +02:00
Christoph Reiter
857b9a55a4 meson: fix build of immultipress.c with mingw
There is no need to escape the quotes since we are not in a shell here
and things get passed to the compiler as is.
2019-04-11 16:45:36 +02:00
Christoph Reiter
b185f69334 meson: check for and set HAVE_IPRINTDIALOGCALLBACK
It's needed under mingw in the print backend
2019-04-11 16:45:36 +02:00
Christoph Reiter
74f6832001 meson: add fribidi dep 2019-04-11 16:45:36 +02:00
Chun-wei Fan
7586e88204 meson: Build libgail-util
This adds libgail-util to the build process.
2019-04-11 16:45:36 +02:00
Chun-wei Fan
5e8edec254 meson: Build the input modules
Build the input modules for GTK+, either as modules or built directly
into GTK.  Also provide a configure option to build the specified
immodules, or all, or the backend immodule(s) or none of the immodules
into GTK.  Note that for Visual Studio all immodules are built into
the GTK DLL by default, like what is done in the Visual Studio projects.

Note that building the backend immodules for Quartz, X11 and Wayland are
currently untested.
2019-04-11 16:45:36 +02:00
Chun-wei Fan
e24e0dd8a5 meson: Make post-install script a Python script
This is so that the post install script will work on environments where
*NIX shell scripts are not supported, such as on Windows cmd.exe for
Visual Studio builds.
2019-04-11 16:45:36 +02:00
Chun-wei Fan
4da82356bc meson: Enable GLES Windows builds via libANGLE
Check whether the libepoxy library is built on Windows with support for
GLES.  If so, enable GLES/EGL support on Windows as well.
2019-04-11 16:45:36 +02:00
Chun-wei Fan
1e7988531a meson: Only use fallbacks for PangoFT2 and FreeType when needed
PangoFT2 is optional on Windows, so we only really need the fallback if
when it is required.

Along with that, since FreeType does not typically ship with pkg-config
files in its CMake builds, check for the needed headers, .lib and
function and then use the fallback when they could not be found and
PangoFT2 is used.
2019-04-11 16:45:36 +02:00
Chun-wei Fan
2d2ad0a997 meson: Only use cairo fallbacks when needed
On Visual Studio builds, since Cairo builds tend not to generate
pkg-config files for us, look for the headers and .lib's, before
attempting to download the Cairo repo (which is quite large) and
building it.

We can simplify this process when Meson gains the ability to check
for the dependencies in a declarative fashion, but before that, this
is what must be done.
2019-04-11 16:45:36 +02:00
Chun-wei Fan
8dc95560e2 meson.build: Bump version 2019-04-11 16:45:36 +02:00
Nirbheek Chauhan
20c29fd8c0 meson: Fix introspection generation on Linux 2019-04-11 16:45:36 +02:00
Nirbheek Chauhan
a8ffb42739 meson: Don't target gnu89 as the c_std
Meson propagates c_std to all subprojects, including those that
require gnu99 or c11, etc.

https://github.com/mesonbuild/meson/issues/1889
2019-04-11 16:45:36 +02:00
Nirbheek Chauhan
d9000a0740 meson: Disable discarded-qualifiers warning
This branch is not going to receive the reworks required fix warnings
about discarding of const qualifiers, so disable that warning instead.
2019-04-11 16:45:36 +02:00
Nirbheek Chauhan
ca63c98447 meson: Add fallback subprojects for more dependencies 2019-04-11 16:45:36 +02:00
Philippe Normand
215c2be76f meson: Set the compatibility version correctly on macOS
And bump to Meson 0.48 as this feature requires it.
2019-04-11 16:45:36 +02:00
Philippe Normand
89d5c543ac meson: Build fixes for macOS 2019-04-11 16:45:36 +02:00
Philippe Normand
9109efb19e meson: Disable X11 support on Darwin
The Quartz backend should fulfill most requirements anyway.
2019-04-11 16:45:36 +02:00
Nirbheek Chauhan
a4fe15d9f0 meson: Sync build files with master and update to 3.24 2019-04-11 16:45:27 +02:00
Nirbheek Chauhan
8ec004cc08 Import meson build files from an 3.22
Specifically, from 6dd6660c68
2019-04-11 16:40:33 +02:00