summaryrefslogtreecommitdiff
path: root/pango/meson.build
diff options
context:
space:
mode:
authorChun-wei Fan <fanchunwei@src.gnome.org>2017-08-04 17:38:30 +0800
committerChun-wei Fan <fanchunwei@src.gnome.org>2017-09-09 00:15:55 +0800
commit2b4f16068602a2ed9e3af0ea4d4273812cf3973c (patch)
treed0b7c20080f402757a79132250422b5c5a5c41e1 /pango/meson.build
parentfd429398a64bc2d7a01da64efa736bbb6eec6a29 (diff)
downloadpango-2b4f16068602a2ed9e3af0ea4d4273812cf3973c.tar.gz
meson: Build .rc files on Windows
Like the autotools builds, build the .rc files for the PangoCairo, PangoFT2, PangoWin32 and Pango DLLs so that people can see the version info more easily. https://bugzilla.gnome.org/show_bug.cgi?id=783274
Diffstat (limited to 'pango/meson.build')
-rw-r--r--pango/meson.build39
1 files changed, 39 insertions, 0 deletions
diff --git a/pango/meson.build b/pango/meson.build
index e963aaaf..a335abbf 100644
--- a/pango/meson.build
+++ b/pango/meson.build
@@ -64,6 +64,8 @@ pango_features_conf = configuration_data()
pango_features_conf.set('PANGO_VERSION_MAJOR', pango_major_version)
pango_features_conf.set('PANGO_VERSION_MINOR', pango_minor_version)
pango_features_conf.set('PANGO_VERSION_MICRO', pango_micro_version)
+pango_features_conf.set('PANGO_API_VERSION', pango_api_version)
+pango_features_conf.set('PANGO_CURRENT_MINUS_AGE', '0')
configure_file(input: 'pango-features.h.meson',
output: 'pango-features.h',
@@ -80,6 +82,16 @@ pango_enums = gnome.mkenums('pango-enum-types',
install_header: true)
pango_enum_h = pango_enums[1]
+if host_system == 'windows'
+ pango_rc = configure_file(
+ input: 'pango.rc.in',
+ output: 'pango.rc',
+ configuration: pango_features_conf,
+ )
+ pango_res = import('windows').compile_resources(pango_rc)
+ pango_sources += pango_res
+endif
+
pango_cflags = [
'-DG_LOG_DOMAIN="Pango"',
'-DG_LOG_USE_STRUCTURED=1',
@@ -156,6 +168,16 @@ if freetype_dep.found()
'pango-ot-tag.c',
]
+ if host_system == 'windows'
+ pangoft2_rc = configure_file(
+ input: 'pangoft2.rc.in',
+ output: 'pangoft2.rc',
+ configuration: pango_features_conf,
+ )
+ pangoft2_res = import('windows').compile_resources(pangoft2_rc)
+ pangoft2_sources += pangoft2_res
+ endif
+
install_headers(pangoft2_headers, subdir: pango_api_path)
libpangoft2 = shared_library('pangoft2-@0@'.format(pango_api_version),
@@ -265,6 +287,14 @@ if host_system == 'windows'
cc.find_library('usp10'),
]
+ pangowin32_rc = configure_file(
+ input: 'pangowin32.rc.in',
+ output: 'pangowin32.rc',
+ configuration: pango_features_conf,
+ )
+ pangowin32_res = import('windows').compile_resources(pangowin32_rc)
+ pangowin32_sources += pangowin32_res
+
install_headers(pangowin32_headers, subdir: pango_api_path)
libpangowin32 = shared_library('pangowin32-@0@'.format(pango_api_version),
@@ -317,6 +347,15 @@ if cairo_dep.found()
'pangocairo-win32font.c',
'pangocairo-win32fontmap.c',
]
+
+ pangocairo_rc = configure_file(
+ input: 'pangocairo.rc.in',
+ output: 'pangocairo.rc',
+ configuration: pango_features_conf,
+ )
+ pangocairo_res = import('windows').compile_resources(pangocairo_rc)
+ pangocairo_sources += pangocairo_res
+
pangocairo_deps += cc.find_library('gdi32')
pangocairo_deps += libpangowin32_dep
endif