diff options
author | Simon Ser <contact@emersion.fr> | 2023-02-02 11:58:07 +0100 |
---|---|---|
committer | Simon Zeni <simon@bl4ckb0ne.ca> | 2023-02-02 18:15:29 +0000 |
commit | 8df62e4016ebb633ab281c9dce4583422a070cfa (patch) | |
tree | c760ce1e6e449856f9000b8bf1fac0bd8b36d1b6 /backend/drm | |
parent | abd9c8c3c160820e47babb92f137f76013db59f1 (diff) |
backend/drm: require hwdata pkg-config file
The hardcoded fallback "/usr/share/hwdata/pnp.ids" was only a
temporary solution to get things working while distributions were
still working on shipping it.
Diffstat (limited to 'backend/drm')
-rw-r--r-- | backend/drm/meson.build | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/backend/drm/meson.build b/backend/drm/meson.build index fc4d84d6..9abf1350 100644 --- a/backend/drm/meson.build +++ b/backend/drm/meson.build @@ -1,19 +1,19 @@ -if not features['session'] - subdir_done() -endif +hwdata = dependency( + 'hwdata', + required: 'drm' in backends, + native: true, + not_found_message: 'Required for the DRM backend.', +) -hwdata = dependency('hwdata', required: false, native: true) -if hwdata.found() - hwdata_dir = hwdata.get_variable(pkgconfig: 'pkgdatadir') - pnp_ids = files(hwdata_dir / 'pnp.ids') -else - pnp_ids = files('/usr/share/hwdata/pnp.ids') +if not (hwdata.found() and features['session']) + subdir_done() endif +hwdata_dir = hwdata.get_variable(pkgconfig: 'pkgdatadir') pnpids_c = custom_target( 'pnpids.c', output: 'pnpids.c', - input: pnp_ids, + input: files(hwdata_dir / 'pnp.ids'), feed: true, capture: true, command: files('gen_pnpids.sh'), |