Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

QT 5 static build with QTCreator #21

Open
FraDiavolo7 opened this issue Apr 22, 2013 · 6 comments
Open

QT 5 static build with QTCreator #21

FraDiavolo7 opened this issue Apr 22, 2013 · 6 comments

Comments

@FraDiavolo7
Copy link

Compiling with --static-qt works just fine, but the lack of qtcreator is not something my team can be using so I need to compile it one way or another.

What I have done so far :

  • I activated all the packages that are disabled by "$( [[ $STATIC_DEPS == no ]] " in the package_order.sh script
  • ICU cannot compile as it is, due to the naming of the produced sicu**.a libraries, so I copied them manually (think I'm gonna throw an issue to them on this point) so they are named libsicu**.a
  • in the buildall script I replaced BUILD_QTCREATOR=no by BUILD_QTCREATOR=yes

Compilation is running to test the last part.

In another issue ( #20 ) you told me to use a "toolchains builded with threads=win32 to avoid dependency from libwinpthread-1.dll"
So my next try is this. I have prepared my buildall script by adding
URL_MINGW64=http://sourceforge.net/projects/mingwbuilds/files/host-windows/releases/4.8.0/64-bit/threads-win32/seh/x64-4.8.0-release-win32-seh-rev2.7z
at the end of the --static-qt analysis block.
I am still not sure if I should let the "-lwinpthread" in then "STATIC_LD" variable, but I think I will find out sooner or later...

Sidenote : it might be possible to overcome the ICU compilation problem by creating, before compilation of ICU, symbolic links libcisu**.a pointing to sicu**.a but I am not sure MSYS handle that well...

@niXman
Copy link

niXman commented Apr 22, 2013

Thanks!

@Alexpux
Copy link
Owner

Alexpux commented Apr 22, 2013

MSYS doesn't creates symlinks. It copy files instead

@FraDiavolo7
Copy link
Author

Yep, I found that out at my depends... I am lauching another run from ICU and fixing it bit by bit so I don't encounter problems afterwards.

My last build failed on QTCreator on a undefined reference problem, hope it will solve it...

@FraDiavolo7
Copy link
Author

Update.

My undefined reference ( protocol.o ) was due to a mistake in QT configure call (forgot to remove --no-icu and the likes). So back to QT building.

After modification of configure, I encounter another error.

When QT is configured, there is missing folders, which lead to a missing files during build. Missing folders are databases and all subfolders, in the final QT folder. This missing leads to a missing libpq--fe.h file.

I am looking through the configuration process to find where this problem is coming from, but it is quite confusing.

I compared logs between succeed x64 and failed x64-static configurations steps, there is no significant difference before the claim :
x64 :
Environment:
INCLUDE=

  E:\MSys\home\user\Qt-builds\toolchains\mingw64\x86_64-w64-mingw32\include

  c:\QtSDK\ported64\include

  c:\QtSDK\ported64\include\libxml2

  c:\QtSDK\Qt64-5.0.1\databases\firebird\include

  c:\QtSDK\Qt64-5.0.1\databases\mysql\include\mysql

  c:\QtSDK\Qt64-5.0.1\databases\pgsql\include

  c:\QtSDK\Qt64-5.0.1\databases\oci\include

x64-static :
Environment:
INCLUDE=

  E:\MSys\home\user\Qt-builds\toolchains\mingw64\x86_64-w64-mingw32\include

  c:\QtSDK\ported64-s\include

  c:\QtSDK\ported64-s\include\libxml2

I need to find where these includes are coming from and then find out why they are missing.

Reminder of done modifications :

@Alexpux
Copy link
Owner

Alexpux commented Apr 24, 2013

Remove folder Databases in QTDIR and restart build

@FraDiavolo7
Copy link
Author

that is the interesting part, there is no databases folder in QTDIR... So maybe I have to restart from step 1 flushing everything?

Do you know which step is creating this folder?

@Alexpux
Copy link
Owner

Alexpux commented Apr 25, 2013

It create in qt-$version.sh script. But it only needed when building shared Qt. If you build static Qt you need to remove any sql drivers from configure parameters

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants