meson: skip translations if gettext is not available
authorTim-Philipp Müller <tim@centricular.com>
Tue, 26 Dec 2017 12:50:24 +0000 (13:50 +0100)
committerTim-Philipp Müller <tim@centricular.com>
Tue, 26 Dec 2017 12:50:24 +0000 (13:50 +0100)
meson.build

index 6c1868b..f322ed0 100644 (file)
@@ -280,9 +280,13 @@ subdir('gst')
 subdir('sys')
 subdir('ext')
 subdir('tests')
-subdir('po')
 subdir('pkgconfig')
 
+# xgettext is optional (on Windows for instance)
+if find_program('xgettext', required : false).found()
+  subdir('po')
+endif
+
 configure_file(output : 'config.h', configuration : cdata)
 
 python3 = import('python3').find_python()