Re: libQt...4d.a files set
I don't know if it helps, but for the shared version the debug libraries are in the bin directory.
Regards
Re: libQt...4d.a files set
Here is how I compile the Qt Windows Opensource version.
As it uses mingw, which sets INCLUDE and LIB environment variables, and this causes compilation errors in some machines. So after talking to hte trolltech support team( and ya, they answers question from Opensource guys ;) ). they have asked me to unset these varaibles. So I edited my qtvars.bat ( C:\Qt\4.3.1\bin\qtvars.bat ) file as follows
Code:
@echo off
rem
rem This file is generated
rem
echo Setting up a MinGW/Qt only environment...
echo -- QTDIR set to C:\Qt\4.3.1
echo -- PATH set to C:\Qt\4.3.1\bin
echo -- Adding C:\MinGW\bin to PATH
echo -- Adding %SystemRoot%\System32 to PATH
echo -- QMAKESPEC set to win32-g++
set LIB=
set INCLUDE=
set QTDIR=C:\Qt\4.3.1
set PATH=C:\Qt\4.3.1\bin
set PATH=%PATH%;C:\MinGW\bin
set PATH=%PATH%;%SystemRoot%\System32
set QMAKESPEC=win32-g++
if not "%1"=="compile_debug" goto END
cd %QTDIR%
echo This will configure and compile qt in debug.
echo The release libraries will not be recompiled.
pause
configure -plugin-sql-sqlite -plugin-sql-odbc -qt-libpng -qt-libjpeg
cd %QTDIR%\src
qmake
mingw32-make debug
:END
Notice the set LIB= and INCLUDE= ( linenumber 13, 14 )
Works for me :D
Re: libQt...4d.a files set
Maybe this question sounds stupid, but what is the point of having static debug libraries (unless you just want to fill up your harddisk and you didn't find an easier way to do it)?
Re: libQt...4d.a files set
Thanks for your answers. Solution was found. libQt...d4.a files are creating for "shared" compilation ONLY. They are absent after "static" compilation of Qt sources.
Many makefiles of "examples" and "demos" after "static" compilation contains "...d4" libs references. I think it's a some sort of bug. qmake shouldn't put refs to "...d4" libs while Qt configured statically. Btw - after patching Makefiles manually and removing "4" at the end of lib names - they are compiling perfectly.
So - is that a bug of qmake?
Re: libQt...4d.a files set
It's not a bug (at least not directly). When compiling statically, you should only compile sub-src (thus omitting examples, tools, etc.) and it would have worked anyway if you told qmake to compile in release mode.
I'd still like to know the answer to my question :)
Re: libQt...4d.a files set
If you mean "what is the point of having static debug libraries" - my point is that compiled statically apps loads faster. It takes much more time to load all dinamically linked libraries then statically linked ones.
Re: libQt...4d.a files set
But in such situation (if the load speed was your primary goal) you'd use libraries built in release mode and not in debug mode. Use of these only makes sense when you're developping the application and that's usualy done with shared libraries (among other reasons the compilation is faster).
Re: libQt...4d.a files set
Thanks. Problem solved. Just put somewhere in faq that ...d4 libs in static mode aren't created.
Re: libQt...4d.a files set
btw, "sub-src" param doesn't helps - all examples and demos are compiled (including ..d4 libs which aren't existing). I still think it's at least low-level priority bug.
Re: libQt...4d.a files set
Quote:
Originally Posted by
brokensword
btw, "sub-src" param doesn't helps - all examples and demos are compiled
This is not possible. You must have used it in a wrong way (your script in the first post is invalid - it changes the current directory to src and then calls make sub-src, instead of calling it from the top level directory). I meant something like this:
cd qtsourcedir
configure.exe -static
make sub-src
Re: libQt...4d.a files set
it builds examples and demos anyway.
QT_BUILD_PARTS -= examples
QT_BUILD_PARTS -= demos
solve this problem.
Re: libQt...4d.a files set
btw, the main question remains - why static "*d4.a" libraries can't be built?
Re: libQt...4d.a files set
I don't know if they *can't* be built, but if so, then I'd say that because nobody assumed that anyone would ever want to build them.