> On Aug 24, 2017, at 4:41 PM, Cleber Rosa <cr...@redhat.com> wrote: > > > > On 08/24/2017 03:10 PM, Programmingkid wrote: >> I think 'make test' is an abandoned testing option for QEMU so this report >> might be unimportant. Here is my results for running 'make test': >> >> $ make test >> make -C tests/tcg test >> LINK test_path >> Undefined symbols for architecture x86_64: >> "_buffer_is_zero", referenced from: >> _qemu_iovec_is_zero in test_path.o >> ld: symbol(s) not found for architecture x86_64 >> clang: error: linker command failed with exit code 1 (use -v to see >> invocation) >> make[1]: *** [test_path] Error 1 >> make: *** [test] Error 2 >> >> > > I went through the same experience, and reported it (in the form of > patches) here: > > http://lists.nongnu.org/archive/html/qemu-devel/2017-08/msg00378.html > > Although it looks like you're clang, so it'd be nice to check if these > fixes work for you too. > > Regards, > > -- > Cleber Rosa > [ Sr Software Engineer - Virtualization Team - Red Hat ] > [ Avocado Test Framework - avocado-framework.github.io ] > [ 7ABB 96EB 8B46 B94D 5E0F E9BB 657E 8D33 A5F2 09F3 ] >
After applying the patches I saw this error: $ make test make -C tests/tcg test CC test_path.o LINK test_path ./test_path cc -m32 -nostdlib -Wall -O2 -g -fno-strict-aliasing -static -o hello-i386 hello-i386.c hello-i386.c:1:10: fatal error: 'asm/unistd.h' file not found #include <asm/unistd.h> ^ 1 error generated. make[1]: *** [hello-i386] Error 1 make: *** [test] Error 2 The path to this header file is /usr/include/unistd.h and /usr/include/sys/unistd.h on my computer. Maybe you could add this to your patches to make them more Mac-friendly: #ifdef __MACH__ /* Mach kernel - what's used in Mac OS X */ #include <unistd.h> #endif http://pubs.opengroup.org/onlinepubs/7908799/xsh/unistd.h.html Then again this page states you should be able to do a "#include <unistd.h>" on your posix compatible platform. Thank you.