wayland: Simplify cross build
Now that we have a pkg-config wrapper, we can get build-time deps via pkg-config.
This commit is contained in:
parent
162c0c3e61
commit
f005272623
@ -23,16 +23,17 @@ in stdenv.mkDerivation rec {
|
||||
|
||||
mesonFlags = [ "-Ddocumentation=${lib.boolToString withDocumentation}" ];
|
||||
|
||||
patches = lib.optional isCross ./fix-wayland-cross-compilation.patch;
|
||||
|
||||
postPatch = lib.optionalString withDocumentation ''
|
||||
patchShebangs doc/doxygen/gen-doxygen.py
|
||||
'' + lib.optionalString isCross ''
|
||||
substituteInPlace egl/meson.build --replace \
|
||||
"find_program('nm').path()" \
|
||||
"find_program('${stdenv.cc.targetPrefix}nm').path()"
|
||||
'';
|
||||
|
||||
depsBuildBuild = [
|
||||
pkgconfig
|
||||
];
|
||||
|
||||
nativeBuildInputs = [
|
||||
meson pkgconfig ninja
|
||||
] ++ lib.optionals isCross [
|
||||
|
@ -1,14 +0,0 @@
|
||||
diff --git a/src/meson.build b/src/meson.build
|
||||
index 3e8c9bf..75241cb 100644
|
||||
--- a/src/meson.build
|
||||
+++ b/src/meson.build
|
||||
@@ -55,8 +55,7 @@ pkgconfig.generate(
|
||||
)
|
||||
|
||||
if meson.is_cross_build()
|
||||
- scanner_dep = dependency('wayland-scanner', native: true, version: '>=1.14.0')
|
||||
- wayland_scanner_for_build = find_program(scanner_dep.get_pkgconfig_variable('wayland_scanner'))
|
||||
+ wayland_scanner_for_build = find_program('wayland-scanner', native: true, version: '>=1.14.0')
|
||||
else
|
||||
wayland_scanner_for_build = wayland_scanner
|
||||
endif
|
Loading…
Reference in New Issue
Block a user