Merge branch 'joystick-platform' of https://github.com/jamessan/kitty
This commit is contained in:
commit
336ee53fea
@ -8,10 +8,7 @@ import re
|
|||||||
import sys
|
import sys
|
||||||
|
|
||||||
_plat = sys.platform.lower()
|
_plat = sys.platform.lower()
|
||||||
is_freebsd = 'freebsd' in _plat
|
is_linux = 'linux' in _plat
|
||||||
is_netbsd = 'netbsd' in _plat
|
|
||||||
is_dragonflybsd = 'dragonfly' in _plat
|
|
||||||
is_bsd = is_freebsd or is_netbsd or is_dragonflybsd
|
|
||||||
base = os.path.dirname(os.path.abspath(__file__))
|
base = os.path.dirname(os.path.abspath(__file__))
|
||||||
|
|
||||||
|
|
||||||
@ -30,7 +27,7 @@ def init_env(env, pkg_config, at_least_version, test_compile, module='x11'):
|
|||||||
sinfo = json.load(f)
|
sinfo = json.load(f)
|
||||||
module_sources = list(sinfo[module]['sources'])
|
module_sources = list(sinfo[module]['sources'])
|
||||||
if module in ('x11', 'wayland'):
|
if module in ('x11', 'wayland'):
|
||||||
remove = 'linux_joystick.c' if is_bsd else 'null_joystick.c'
|
remove = 'null_joystick.c' if is_linux else 'linux_joystick.c'
|
||||||
module_sources.remove(remove)
|
module_sources.remove(remove)
|
||||||
|
|
||||||
ans.sources = sinfo['common']['sources'] + module_sources
|
ans.sources = sinfo['common']['sources'] + module_sources
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user