build: Make exported package in gir consistent

Additionally Cogl was missing xlib as an include

Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1918>
This commit is contained in:
Zander Brown 2021-07-06 19:03:10 +01:00 committed by Marge Bot
parent b62f2667db
commit 6a445d2eef
4 changed files with 21 additions and 11 deletions

View File

@ -333,6 +333,7 @@ if have_introspection
nsversion: libmutter_api_version,
header: 'cally/cally.h',
namespace: 'Cally',
export_packages: [libmutter_clutter_name],
includes: [
libmutter_mtk_gir[0],
libmutter_cogl_gir[0],

View File

@ -21,7 +21,8 @@ cogl_pango_deps = [
libmutter_cogl_dep,
]
libmutter_cogl_pango = shared_library('mutter-cogl-pango-' + libmutter_api_version,
libmutter_cogl_pango_name = 'mutter-cogl-pango-' + libmutter_api_version
libmutter_cogl_pango = shared_library(libmutter_cogl_pango_name,
sources: [cogl_pango_sources, cogl_pango_public_headers],
version: '0.0.0',
soversion: 0,
@ -56,7 +57,7 @@ if have_introspection
pango_dep,
libmutter_cogl_pango_dep,
],
export_packages: 'mutter-cogl-pango-@0@'.format(libmutter_api_version),
export_packages: [libmutter_cogl_pango_name],
extra_args: introspection_args + [
'-UCOGL_COMPILATION',
'-DG_LOG_DOMAIN="CoglPango"',
@ -70,7 +71,7 @@ install_headers(cogl_pango_public_headers, subdir: cogl_pango_includesubdir)
pkg.generate(libmutter_cogl_pango,
name: 'CoglPango',
filebase: 'mutter-cogl-pango-' + libmutter_api_version,
filebase: libmutter_cogl_pango_name,
description: 'A text rendering for Cogl in mutter',
subdirs: pkgname / 'cogl',
requires: [cogl_pkg_deps, libmutter_cogl_name, pango_dep, pangocairo_dep],

View File

@ -1,6 +1,18 @@
cogl_cogl_includesubdir = cogl_includesubdir / 'cogl'
cogl_cogl_includedir = cogl_includedir / 'cogl'
cogl_gir_includes = [
'GL-1.0',
'GObject-2.0',
'Graphene-1.0',
]
if have_introspection
cogl_gir_includes += [
libmutter_mtk_gir[0],
]
endif
cogl_deprecated_headers = [
'deprecated/cogl-program.h',
'deprecated/cogl-shader.h',
@ -293,6 +305,7 @@ cogl_sources = [
]
if have_x11
cogl_gir_includes += ['xlib-2.0']
cogl_nonintrospected_headers += [
'cogl-xlib.h',
'winsys/cogl-texture-pixmap-x11.h',
@ -403,14 +416,9 @@ if have_introspection
sources: cogl_introspected_headers,
nsversion: libmutter_api_version,
namespace: 'Cogl',
includes: [
libmutter_mtk_gir[0],
'GL-1.0',
'GObject-2.0',
'Graphene-1.0',
],
export_packages: [libmutter_cogl_name],
includes: cogl_gir_includes,
dependencies: [cogl_deps],
export_packages: 'mutter-cogl-@0@'.format(libmutter_api_version),
extra_args: introspection_args + [
'-UCOGL_COMPILATION',
'-D__COGL_H_INSIDE__',

View File

@ -1279,7 +1279,7 @@ if have_introspection
libmutter_dep,
mutter_deps,
],
export_packages: 'libmutter-@0@'.format(libmutter_api_version),
export_packages: ['libmutter-@0@'.format(libmutter_api_version)],
extra_args: mutter_c_args + introspection_args,
kwargs: introspection_common,
)