Just mimic autoconf file, DPMS is disabled with Xquartz

Signed-off-by: Laurent Carlier <lordhea...@gmail.com>
---
 include/meson.build | 2 +-
 meson.build         | 6 +++++-
 meson_options.txt   | 2 ++
 3 files changed, 8 insertions(+), 2 deletions(-)

diff --git a/include/meson.build b/include/meson.build
index 00ec057..8822e79 100644
--- a/include/meson.build
+++ b/include/meson.build
@@ -163,7 +163,7 @@ conf_data.set('BIGREQS', '1')
 conf_data.set('COMPOSITE', '1')
 conf_data.set('DAMAGE', '1')
 conf_data.set('DBE', '1')
-conf_data.set('DPMSExtension', '1')
+conf_data.set('DPMSExtension', build_dpms)
 conf_data.set('DRI2', build_dri2)
 conf_data.set('DRI3', build_dri3)
 conf_data.set_quoted('DRI_DRIVER_PATH', 
dri_dep.get_pkgconfig_variable('dridriverdir'))
diff --git a/meson.build b/meson.build
index 3c1d54c..9baec54 100644
--- a/meson.build
+++ b/meson.build
@@ -335,10 +335,14 @@ else
     build_vgahw = get_option('vgahw') == 'true'
 endif
 
+build_dpms = get_option('dpms')
+if build_xquartz
+    build_dpms = false
+endif
+
 # XXX: Allow configuration of these.
 build_apm = false
 build_acpi = false
-build_dpms = true
 build_mitshm = true
 build_res = true
 build_screensaver = true
diff --git a/meson_options.txt b/meson_options.txt
index 294279a..5d37b75 100644
--- a/meson_options.txt
+++ b/meson_options.txt
@@ -57,6 +57,8 @@ option('vbe', type: 'combo', choices: ['true', 'false', 
'auto'], value: 'auto',
        description: 'Xorg VBE module')
 option('vgahw', type: 'combo', choices: ['true', 'false', 'auto'], value: 
'auto',
        description: 'Xorg VGA access module')
+option('dpms', type: 'boolean', value: true,
+       description: 'Xorg DPMS extension')
 
 option('dri1', type: 'combo', choices: ['true', 'false', 'auto'], value: 
'auto', description: 'Build DRI1 extension (default: auto)')
 option('dri2', type: 'combo', choices: ['true', 'false', 'auto'], value: 
'auto', description: 'Build DRI2 extension (default: auto)')
-- 
2.16.1

_______________________________________________
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: https://lists.x.org/mailman/listinfo/xorg-devel

Reply via email to