diff options
author | Matthias Clasen <mclasen@redhat.com> | 2019-07-09 18:52:14 -0400 |
---|---|---|
committer | Matthias Clasen <mclasen@redhat.com> | 2019-07-09 19:33:19 -0400 |
commit | ad5c0fe4cee2fe84e4dd98b3c0de19295b39aea4 (patch) | |
tree | 5059ef8b8cffde16fbb39699592611b9f9237978 | |
parent | a030bdf67986ce90c7999d773f4077928442ad68 (diff) | |
download | pango-ad5c0fe4cee2fe84e4dd98b3c0de19295b39aea4.tar.gz |
win32: Fix the build
-rw-r--r-- | pango/meson.build | 93 |
1 files changed, 41 insertions, 52 deletions
diff --git a/pango/meson.build b/pango/meson.build index be651aec..7217a51d 100644 --- a/pango/meson.build +++ b/pango/meson.build @@ -58,6 +58,22 @@ pango_headers = [ install_headers(pango_headers, subdir: pango_api_path) +# Features header +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', + configuration: pango_features_conf, + install: true, + install_dir: join_paths(pango_includedir, pango_api_path), +) + # FreeType if build_pangoft2 pangoft2_headers = [ @@ -115,14 +131,6 @@ 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 endif if host_system == 'darwin' and pango_font_backends.contains('quartz') @@ -140,21 +148,31 @@ if cairo_dep.found() pango_sources += pangocairo_sources endif -# Features header -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') +# Win32 +if host_system == 'windows' + pangowin32_headers = [ + 'pangowin32.h', + ] -configure_file( - input: 'pango-features.h.meson', - output: 'pango-features.h', - configuration: pango_features_conf, - install: true, - install_dir: join_paths(pango_includedir, pango_api_path), -) + pangowin32_sources = [ + 'pangowin32.c', + 'pangowin32-fontcache.c', + 'pangowin32-fontmap.c', + 'pangowin32-shape.c', + ] + + # usp10 needs to be before gdi32 + # see https://bugzilla.gnome.org/show_bug.cgi?id=795045#c0 + pangowin32_deps = [ + cc.find_library('usp10'), + cc.find_library('gdi32'), + ] + + install_headers(pangowin32_headers, subdir: pango_api_path) + + pango_sources += pangowin32_sources + pango_deps += pangowin32_deps +endif # Enumerations for GType pango_enums = gnome.mkenums( @@ -377,38 +395,9 @@ endif # Win32 if host_system == 'windows' - pangowin32_headers = [ - 'pangowin32.h', - ] - - pangowin32_sources = [ - 'pangowin32.c', - 'pangowin32-fontcache.c', - 'pangowin32-fontmap.c', - 'pangowin32-shape.c', - ] - - # usp10 needs to be before gdi32 - # see https://bugzilla.gnome.org/show_bug.cgi?id=795045#c0 - pangowin32_deps = pango_deps + [ - libpango_dep, - cc.find_library('usp10'), - cc.find_library('gdi32'), - ] - - 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 = library( 'pangowin32-@0@'.format(pango_api_version), - sources: pangowin32_sources, + sources: [], version: pango_libversion, soversion: pango_soversion, install: true, |