From 574b523ab5d9b63a114ac905e5ff8494f4b2f233 Mon Sep 17 00:00:00 2001 From: akdjka Date: Mon, 28 Nov 2022 21:49:55 +0000 Subject: Fix compilation under musl libc. --- meson.build | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/meson.build b/meson.build index ae49ba5..3cfa30a 100644 --- a/meson.build +++ b/meson.build @@ -129,6 +129,8 @@ compgen_sources = files( cc = meson.get_compiler('c') librt = cc.find_library('rt', required: false) libm = cc.find_library('m', required: false) +# On systems where libc doesn't provide fts (i.e. musl) we require libfts +libfts = cc.find_library('fts', required: not cc.has_function('fts_read')) freetype = dependency('freetype2') harfbuzz = dependency('harfbuzz') cairo = dependency('cairo') @@ -189,7 +191,7 @@ subdir('test') executable( 'tofi', files('src/main.c'), common_sources, wl_proto_src, wl_proto_headers, - dependencies: [librt, libm, freetype, harfbuzz, cairo, pangocairo, wayland_client, xkbcommon, glib, gio_unix], + dependencies: [librt, libm, libfts, freetype, harfbuzz, cairo, pangocairo, wayland_client, xkbcommon, glib, gio_unix], install: true ) -- cgit v1.2.3