[Bug 1885827] Re: building plugin failed on Windows with mingw

2021-07-05 Thread Launchpad Bug Tracker
[Expired for QEMU because there has been no activity for 60 days.] ** Changed in: qemu Status: Incomplete => Expired -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https://bugs.launchpad.net/bugs/1885827 Title: building pl

[Bug 1885827] Re: building plugin failed on Windows with mingw

2021-05-06 Thread Thomas Huth
The QEMU project is currently moving its bug tracking to another system. For this we need to know which bugs are still valid and which could be closed already. Thus we are setting the bug state to "Incomplete" now. If the bug has already been fixed in the latest upstream version of QEMU, then plea

Re: [Bug 1885827] Re: building plugin failed on Windows with mingw

2020-07-09 Thread Alex Bennée
Emilio G. Cota <1885...@bugs.launchpad.net> writes: > You should then find out why libqemu_plugin.dll.a is not working. It is > possible though that your linked is calling the import library something > else, for instance adding a .dll extension to it. > > You will have to run a few tests with y

[Bug 1885827] Re: building plugin failed on Windows with mingw

2020-07-08 Thread Emilio G. Cota
You should then find out why libqemu_plugin.dll.a is not working. It is possible though that your linked is calling the import library something else, for instance adding a .dll extension to it. You will have to run a few tests with your linker (I'd just use the examples from the stackoverflow lin

[Bug 1885827] Re: building plugin failed on Windows with mingw

2020-07-07 Thread Xiaolei
Hi Emilio, I got the ideas for the attempt with a dummy dll. However, my collegue and I both failed to generate libqemu_plugin.dll.a during make process. And running "make install" yields errors as follows: mkdir -p "C:/QEMU_install/QEMUa/applications" install -c -m 0644 /c/QRS_Project/simd

[Bug 1885827] Re: building plugin failed on Windows with mingw

2020-07-06 Thread Emilio G. Cota
You're getting close. 1. From the build directory, find the import library created, e.g. `find . -name 'libqemu_plugin.dll.a'`. If you're building x86_64-linux-user, it should be in `x86_64-linux-user/libqemu_plugin.dll.a`. 2. Go back to the `build/tests/plugin` directory. 3. Link the empty plug

[Bug 1885827] Re: building plugin failed on Windows with mingw

2020-07-05 Thread Xiaolei
Hi, I patched configure file and makefile. The output is listed below. The project is configured as : #../configure --target-list=dsp-softmmu --cross-prefix=x86_64-w64-mingw32- --enable-gtk --enable-sdl --enable-debug --enable-plugins --extra-cflags="-DBUILDING_DLL" But running make ye

[Bug 1885827] Re: building plugin failed on Windows with mingw

2020-07-04 Thread Emilio G. Cota
Xiaolei confirmed to me via email that adding -DBUILDING_DLL is not enough to fix the problem. I looked into this a bit further and it looks like we need an "import library" to be created when compiling the QEMU binary. This is accomplished by adding "-Wl,--out-implib,libqemu_plugin.a" to the li

re??[Bug 1885827] Re: building plugin failed on Windows with mingw

2020-07-03 Thread casmac
------- : "Emilio G. Cota"<1885...@bugs.launchpad.net>; : 2020??7??4??(??) 11:16: "casmac"<1482995...@qq.com>; : [Bug 1885827] Re: building plugin failed on Windows with mingw I never built the plugin code on anything other than Linux :( All I did for Win

[Bug 1885827] Re: building plugin failed on Windows with mingw

2020-07-03 Thread Emilio G. Cota
I never built the plugin code on anything other than Linux :( All I did for Windows is to try to follow https://gcc.gnu.org/wiki/Visibility Can you please try the following patch (with no other changes)? The patch applies on top of v4.2.0. diff --git a/tests/plugin/Makefile b/tests/plugin/Makefil

Re: [Bug 1885827] Re: building plugin failed on Windows with mingw

2020-07-03 Thread Alex Bennée
Xiaolei <1885...@bugs.launchpad.net> writes: > If I keep "-Wl,-soname,$@" in the command , I got similar linking errors. > > makefile: > SONAMES := $(addsuffix .dll,$(addprefix lib,$(NAMES))) > > QEMU_CFLAGS += -fPIC -fno-stack-protector -DBUILDING_DLL > QEMU_CFLAGS += -I$(SRC_PATH)/include/q

[Bug 1885827] Re: building plugin failed on Windows with mingw

2020-07-03 Thread Xiaolei
If I keep "-Wl,-soname,$@" in the command , I got similar linking errors. makefile: SONAMES := $(addsuffix .dll,$(addprefix lib,$(NAMES))) QEMU_CFLAGS += -fPIC -fno-stack-protector -DBUILDING_DLL QEMU_CFLAGS += -I$(SRC_PATH)/include/qemu all: $(SONAMES) lib%.dll: %.o $(CC) -shared -Wl,-son