Building on Windows

Joep Admiraal

I am trying to build the current version (checkout from original master) of QLC+ on Windows 7 32bit.
I installed these components:
- QT5.1.1-mingw
- mingw 4.8.1
- fftw3-3.3.3-1-mingw32-dev
- glib_2.24.0-2_win32
- pkg-config_0.26-1_win32

In powershell I go to c:\qlcplus and run qmake and mingw32-make.
I get the following result:

PS C:\qlcplus> mingw32-make.exe
cd hotplugmonitor\ && ( if not exist Makefile C:\Qt\Qt5.1.1\5.1.1\mingw48_32\bin\qmake.exe C:\qlcplus\hotplugmonitor\hot
plugmonitor.pro -o Makefile ) && C:/MinGW/bin/mingw32-make -f Makefile
mingw32-make[1]: Entering directory 'C:/qlcplus/hotplugmonitor'
test wordt niet herkend als een interne of externe opdracht, programma of batchbestand.
De syntaxis van de opdracht is onjuist.
Makefile:39: recipe for target 'sub-src-make_first' failed
mingw32-make[1]: *** [sub-src-make_first] Error 1
mingw32-make[1]: Leaving directory 'C:/qlcplus/hotplugmonitor'
Makefile:50: recipe for target 'sub-hotplugmonitor-make_first-ordered' failed
mingw32-make: *** [sub-hotplugmonitor-make_first-ordered] Error 2

It seems it is expecting a program or batch file called test and it does not exist.
Do you have any idea what the problem can be?

Thanks,
Joep
Massimo Callegari

...like if I speak dutch... :)

Anyway, as stated in the QLC+ wiki: https://github.com/mcallegari/qlcplus/wiki
"Note: QLC+ hasn't been ported to Qt 5.x yet. So let's stick with Qt 4.8.5 for now !"
Joep Admiraal

Well, I noticed this commit:
da8ea7a845b4e8e6a0329f066b2bc733702e83db HUGE one - QLC+ ported to Qt5 !

So I thought lets give it a try.
I did this in a virtual machine so can easily switch back to my Qt4 machine for now.
Massimo Callegari

It's not official and it's not tested on Windows.
I just built it and launched it on Linux.

Have you ever compiled QLC+ on Windows ? (with Qt 4.8.x)
I assure you it's a pain in the ass
Joep Admiraal

Yeah I tried with 4.8 and ran into trouble before.
I will do a clean setup tonight (as described in the wiki).
I want to test my changes for the sysex messages on Windows :-)
Massimo Callegari

I see. If you want I can help. I've got a working environment at home.
The only thing is that I don't know how to monitor sysex on Windows
I can try with this: http://www.midiox.com/
Joep Admiraal

Ok, I did another test on a new VM. I used a QLC+ revision from just before the Qt5 commit. I followed the instructions from the wiki.
I used the same software as stated in my first post except for Qt which is now 4.8.5.
One thing I noticed is that the Qt installation complains about W32API3.13 because MinGW has a newer version of this file.

Now when running qmake and make from powershell I get this error:
./debug\avolitesd4parser.o:avolitesd4parser.cpp:(.eh_frame$_ZN7QStringaSEPKc+0x13): undefined reference to `__gxx_person
ality_v0'

I attached a more complete error log.
Googling this error shows similar errors when gcc is used when g++ should have been used. I doubt that this is the case since the logs show g++ is used.

Any ideas?
Thanks
Attachments
qlcplus_win_error.txt
(2.92 KiB) Downloaded 180 times
Massimo Callegari

Did you forget to install g++ when you installed MinGW ?
What does g++ -v say ?

EDIT: By the way, the changes to work on Qt5 are backward compatible. QLC+ still compiles on Qt 4.8.x
Joep Admiraal

g++ is installed with MinGW.
g++ -v output:

PS C:\qlcplus> g++ -v
Using built-in specs.
COLLECT_GCC=C:\MinGW\bin\g++.exe
COLLECT_LTO_WRAPPER=c:/mingw/bin/../libexec/gcc/mingw32/4.8.1/lto-wrapper.exe
Target: mingw32
Configured with: ../gcc-4.8.1/configure --prefix=/mingw --host=mingw32 --build=mingw32 --without-pic --enable-shared --e
nable-static --with-gnu-ld --enable-lto --enable-libssp --disable-multilib --enable-languages=c,c++,fortran,objc,obj-c++
,ada --disable-sjlj-exceptions --with-dwarf2 --disable-win32-registry --enable-libstdcxx-debug --enable-version-specific
-runtime-libs --with-gmp=/usr/src/pkg/gmp-5.1.2-1-mingw32-src/bld --with-mpc=/usr/src/pkg/mpc-1.0.1-1-mingw32-src/bld --
with-mpfr= --with-system-zlib --with-gnu-as --enable-decimal-float=yes --enable-libgomp --enable-threads --with-libiconv
-prefix=/mingw32 --with-libintl-prefix=/mingw --disable-bootstrap LDFLAGS=-s CFLAGS=-D_USE_32BIT_TIME_T
Thread model: win32
gcc version 4.8.1 (GCC)
Massimo Callegari

Hmmm...GCC 4.8 might be problematic...although I had reports of users compiling with it on Linux.
I use Windows 7 64bit and mingw 32 bit on GCC 4.6.
I can try your same steps one of this nights but I'm not sure if I have enough time (also, spending time on Windows makes me nervous... :) )
Massimo Callegari

By the way, have you set the environment variables like PATH, QTDIR and so on?
I remember I got a hell of time on that
Joep Admiraal

Yes environment vars are in place.I noticed that the package gcc-v3-g++ was also installed. So I removed the normal g++ package and tried to compile with the v3 version. That did not work. Then I compiled with only the normal g++ package in place and that did work.It then complained about openssl but once that was installed make completed without errors.I will do some more tests and then update the wiki.
Massimo Callegari

Just a tiny note on openssl. I guess you found that issue building the webaccess module. It is not needed and yesterday I pushed a little fix on the mongoose flags.

Honestly I've never heard about v3 and non v3 g++ package. Before updating the wiki, please let me double check the procedure.

Thanks
Joep Admiraal

I did make install and renamed the .a files to .dll files.
Now when I try to strart qlcplus.exe I get an appcrash:

Cannot start the application (0xc0000005).

Signature:
P1: qlcplus.exe
P2: 0.0.0.0
P3: 52663c2b
P4: QtCored4.dll
P5: 4.8.5.0
P6: 51cc9cc0
P7: c0000005
P8: 001e1b7c
P9:
P10:

It generates a crashdump file, but before I start analysing that, do you have any idea what this could be?
Massimo Callegari

Windows is terrible when it comes to debug something. I see what you see: a crash somewhere into QtCore :(

Did you launch it from a terminal or double clicked from windows explorer ?
Have you copied the additional DLLs needed for audio and OSC ?
Obviously it all depends if you built them in or not
Massimo Callegari

A quick summary. I've spent 2 hours on Windows and I got...nowhere !
I saved my previous mingw installation and I tried to rebuild it from scratch with the new installer.
First, they changed it all. Now it's fully graphic. Might be better or not.
After downloading all the base system, I opened a powershell and the command "make" does absolutely nothing. (gcc and g++ work ok)

So I opened a MSYS shell and got a little bit further. Although I got stuck again, cause for some reason qlcconfig.h doesn't exist.
It is supposed to be created by qmake.

I can spend some more time, maybe tomorrow, but this is indeed a problem. :(
Joep Admiraal

I am able to compile QLC (without the plugins, except for midi).
If you have other (more important) things to work on, please do so.
For me this is not a high priority issue, and eventually I will find the cause of this problem. When I got it running I will update the wiki.
Massimo Callegari

I've been able to understand the issue of compiling with MSYS shell. It's more UNIX style.
After building the whole QLC+ I got your same result: error 0xc0000005.
Gonna investigate this later.
Massimo Callegari

I fear this is it: https://qt-project.org/forums/viewthread/21853/
Means latest MinGW is not binary compatible with Qt 4.8.5.
Joep Admiraal

Ah great you found the problem.
I tried MinGW 4.4 and it works.

Thanks for looking into this.
Post Reply