diff options
Diffstat (limited to 'build/linux/system.gyp')
-rw-r--r-- | build/linux/system.gyp | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/build/linux/system.gyp b/build/linux/system.gyp index cf25bb1..7193c67 100644 --- a/build/linux/system.gyp +++ b/build/linux/system.gyp @@ -225,7 +225,17 @@ '<!@(<(pkg-config) --libs-only-l x11)', ], }, - }]] + }], + # When XInput2 is available (i.e. inputproto version is 2.0), the + # pkg-config command will succeed, so the output will be empty. + ['"<!@(<(pkg-config) --atleast-version=2.0 inputproto || echo $?)"==""', { + 'direct_dependent_settings': { + 'defines': [ + 'HAVE_XINPUT2', + ], + }, + }], + ], }, { 'target_name': 'xext', |