util-linux: use meson to build
Compiles faster, is PIC by default, and does not have pkgconfig files with wrong paths. Add various fixes to it as it seems cross compilation was never tested. Signed-off-by: Rosen Penev <rosenp@gmail.com>
This commit is contained in:
committed by
Christian Lamparter
parent
d93aae1d67
commit
28cec43807
@@ -0,0 +1,34 @@
|
||||
From e25db9169450d3d5fb43656a2eae5c08999310f4 Mon Sep 17 00:00:00 2001
|
||||
From: Rosen Penev <rosenp@gmail.com>
|
||||
Date: Fri, 29 Apr 2022 16:56:54 -0700
|
||||
Subject: [PATCH 2/7] meson: don't use run
|
||||
|
||||
Fixes cross compilation. run is not needed anyway.
|
||||
|
||||
Signed-off-by: Rosen Penev <rosenp@gmail.com>
|
||||
---
|
||||
meson.build | 6 ++----
|
||||
1 file changed, 2 insertions(+), 4 deletions(-)
|
||||
|
||||
--- a/meson.build
|
||||
+++ b/meson.build
|
||||
@@ -577,8 +577,7 @@ int main(void) {
|
||||
return tzname ? 0 : 1;
|
||||
}
|
||||
'''.format(have ? 1 : 0)
|
||||
-result = cc.run(code, name : 'using tzname[]')
|
||||
-have = result.compiled() and result.returncode() == 0
|
||||
+have = cc.compiles(code, name : 'using tzname[]')
|
||||
conf.set('HAVE_TZNAME', have ? 1 : false)
|
||||
|
||||
socket_libs = []
|
||||
@@ -641,8 +640,7 @@ int main(void) {
|
||||
return (*__progname != 0);
|
||||
}
|
||||
'''
|
||||
-result = cc.run(code, name : 'using __progname')
|
||||
-have = result.compiled() and result.returncode() == 0
|
||||
+have = cc.compiles(code, name : 'using __progname')
|
||||
conf.set('HAVE___PROGNAME', have ? 1 : false)
|
||||
|
||||
build_plymouth_support = get_option('build-plymouth-support')
|
||||
Reference in New Issue
Block a user