blob: 64ac6aab0b1f44c169aca6d7bebf85ec3b167414 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
|
Cross compiling tools / qemu-img results in "ninja: no work to do"
Description of problem:
I have the following Dockerfile setting up a cross-compile environment for QEMU.
I am trying to build qemu-img.exe only at the moment
```
FROM fedora as builder
RUN --mount=type=cache,target=/var/cache \
dnf -v install --assumeyes strace gcc make mingw64-gcc mingw64-binutils python-setuptools meson mingw64-glib2-static mingw64-glib2 diffutils
FROM builder as qemu-builder
WORKDIR /src/qemu #assuming qemu source tree is already available at /src/qemu
RUN
RUN ./configure --cross-prefix=x86_64-w64-mingw32- --target-list='' --static
RUN make V=1 tools
```
With either `make tools` or `make qemu-img.exe` I get
```
#10 0.265 changing dir to build for make "tools"...
#10 0.267 make[1]: Entering directory '/src/qemu/build'
#10 0.330 ninja: no work to do.
#10 0.331 { \
#10 0.331 echo 'ninja-targets = \'; \
#10 0.331 /usr/bin/ninja -t targets all | sed 's/:.*//; $!s/$/ \\/'; \
#10 0.331 echo 'build-files = \'; \
#10 0.331 /usr/bin/ninja -t query build.ninja | sed -n '1,/^ input:/d; /^ outputs:/q; s/$/ \\/p'; \
#10 0.331 } > Makefile.ninja.tmp && mv Makefile.ninja.tmp Makefile.ninja
#10 0.363 /src/qemu/build/pyvenv/bin/meson introspect --targets --tests --benchmarks | /src/qemu/build/pyvenv/bin/python3 -B scripts/mtest2make.py > Makefile.mtest
#10 0.634 make[1]: Nothing to be done for 'tools'.
#10 0.634 make[1]: Leaving directory '/src/qemu/build'
#10 DONE 0.6s
```
Following the info in `make help`, I tried `make qemu-img.o` which resulted in
```
cc -c -o qemu-img.o qemu-img.c
qemu-img.c:25:10: fatal error: qemu/osdep.h: No such file or directory
25 | #include "qemu/osdep.h"
| ^~~~~~~~~~~~~~
```
Additional information:
|