diff --git a/meson.build b/meson.build
index 0bd51b8bd1a45645b70e81cbb28690ffccac907e..ebbdaa15d072bed4114cbdc88e1fdf51381f2482 100644
--- a/meson.build
+++ b/meson.build
@@ -65,7 +65,7 @@ endif
 
 ## Root hints
 root_hints = join_paths(etc_dir, get_option('root_hints'))
-if keyfile_default == join_paths(etc_dir, 'root.hints')
+if root_hints == join_paths(etc_dir, 'root.hints')
   install_root_hints = true
 else
   install_root_hints = false