[gtk/gtk-3-24-meson] meson.build: Fix generating .pc files
- From: Chun-wei Fan <fanchunwei src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk/gtk-3-24-meson] meson.build: Fix generating .pc files
- Date: Thu, 4 Apr 2019 02:27:06 +0000 (UTC)
commit a58390cad8c9c018e1a5e4d1ad214e7ecd3395f8
Author: Chun-wei Fan <fanchunwei src gnome org>
Date: Thu Apr 4 09:43:04 2019 +0800
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.
meson.build | 16 ++++++++--------
1 file changed, 8 insertions(+), 8 deletions(-)
---
diff --git a/meson.build b/meson.build
index 45f0d7a16a..bf91cf612f 100644
--- a/meson.build
+++ b/meson.build
@@ -476,8 +476,6 @@ foreach backend: [ ['cairo-xlib', cairo_req, x11_enabled],
cairo_backends += cairo_backend
endif
endforeach
- elif cc.get_id() == 'msvc' and cairo_dep.found()
- cairo_backends += 'cairo-win32'
endif
endif
endforeach
@@ -835,17 +833,20 @@ gdk_packages = ' '.join([ pango_pkgname, pango_req,
'pangocairo', pango_req,
'gdk-pixbuf-2.0', gdk_pixbuf_req ])
+cairo_packages = ''
+
if cairo_pkg_found
- gdk_packages += ' '.join([ ' cairo', cairo_req ])
+ cairo_packages += ' '.join([ ' cairo', cairo_req ])
elif cc.get_id() == 'msvc' and cairo_dep.found()
- gdk_packages += ' '.join([ ' -lcairo' ])
+ cairo_packages += ' '.join([ ' -lcairo' ])
endif
if cairogobj_pkg_found
- gdk_packages += ' '.join([ ' cairo-gobject', cairo_req ])
+ cairo_packages += ' '.join([ ' cairo-gobject', cairo_req ])
elif cc.get_id() == 'msvc' and cairogobj_dep.found()
- gdk_packages += ' '.join([ ' -lcairo-gobject' ])
+ cairo_packages += ' '.join([ ' -lcairo-gobject' ])
endif
+gdk_packages += cairo_packages
pkgconf.set('GDK_PACKAGES', gdk_packages)
if have_gio_unix
@@ -861,8 +862,7 @@ pkgconf.set('GDK_PRIVATE_PACKAGES',
gtk_packages = ' '.join([
atk_dep.name(), atk_req,
- cairo_dep.name(), cairo_req,
- cairogobj_dep.name(), cairo_req,
+ cairo_packages,
pixbuf_dep.name(), gdk_pixbuf_req,
'gio-2.0', glib_req,
])
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]