casmac <1482995...@qq.com> writes:
> Hi all, > I am having trouble running qemu tests. basically ,can not run > check-tcg and check-unit. > Before executing the tests, I did the configuration: configure > --target-list=sparc-softmmu --cross-prefix=x86_64-w64-mingw32- --enable-gtk > --enable-sdl --enable-debug > The source code is built alrigtht . but can not execute the > tests. > Running make check-tcg returned nothing but: > $ make check-tcg > BUILD TCG tests for sparc-softmmu > BUILD sparc-softmmu guest-tests SKIPPED > RUN TCG tests for sparc-softmmu > RUN tests for sparc-softmmu SKIPPED You will either need docker/podman setup so we can use those images to cross-build the tests for other architectures or have cross compilers installed for your targets. This is documented in docs/devel/testing.rst > Runing make check-unit, give me "undefined reference"error message: > $ make check-unit > C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/9.3.0/../../../../x86_64-w64-mingw32/bin/ld.exe: > tests/test-bitmap.o: in function `check_bitmap_copy_with_offset': > D:/cuix/workspace_devl/qemu-4.2.0/tests/test-bitmap.c:25: undefined reference > to `random' > C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/9.3.0/../../../../x86_64-w64-mingw32/bin/ld.exe: > D:/cuix/workspace_devl/qemu-4.2.0/tests/test-bitmap.c:26: undefined > reference to `random' > C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/9.3.0/../../../../x86_64-w64-mingw32/bin/ld.exe: > D:/cuix/workspace_devl/qemu-4.2.0/tests/test-bitmap.c:27: undefined > reference to `random' > C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/9.3.0/../../../../x86_64-w64-mingw32/bin/ld.exe: > D:/cuix/workspace_devl/qemu-4.2.0/tests/test-bitmap.c:28: undefined > reference to `random' > collect2.exe: error: ld returned 1 exit status > make: *** [/d/cuix/workspace_devl/qemu-4.2.0/rules.mak:124: > tests/test-bitmap.exe] error 1 Hmm not sure about this but I suspect the unit tests are written assuming a POSIX environment although I would have thought glib would have smoothed over those differences. > > Something went wrong but I have no clue at all. Any > suggestions? > Thanks a lot. > > > regards, > > > xiaolei -- Alex Bennée