Re: [Qt-creator] linking libs with shadow builds fails

2010-09-24 Thread Matthias Pospiech

 Am 24.09.2010 02:04, schrieb Danny Price:

I didn't provide a link. I said I could provide a sample project if you need it.

Your post said that the library was created as a project in a subdir therefore 
it is not an 'external' library. And the path is not correct - if it was 
correct you would not be having these problems.
It is a library that I create, but that is not the point. it could as 
well be the a normal application.
While my library is compiled and linked the external lib is not linked 
to my library.
If my App can link to my lib is something I do not see since this can 
not happen

if my lib was not created. (this is what you are talking about)

The whole point is that for an external lib I do not need to provide an 
build path.


What I provide (still it has nothing to do with the external lib)
in the src.pro


PROJECT_ROOT = ..
BIN_DIR = $${PROJECT_ROOT}/lib

CONFIG(debug, debug|release):DESTDIR  = $${BIN_DIR}/$${COMPILER}/debug/

CONFIG(release, debug|release):DESTDIR  = $${BIN_DIR}/$${COMPILER}/release/

BUILD_DIR = $${PROJECT_ROOT}/build

CONFIG(debug, debug|release):OBJECTS_DIR  = $${BUILD_DIR}/debug/

CONFIG(release, debug|release):OBJECTS_DIR  = $${BUILD_DIR}/release/

EXAMPLE_DIR = $${PROJECT_ROOT}/example/bin

CONFIG(debug, debug|release):DLLDESTDIR  = $${EXAMPLE_DIR}/$${COMPILER}/debug/

CONFIG(release, debug|release):DLLDESTDIR  = 
$${EXAMPLE_DIR}/$${COMPILER}/release/

Thus my own lib is created in
/project/lib/mingw/debug/mylib.dll
the example in
/project/example/bin/mingw/debug/myapp.exe
where the dll is copied to.

In example.pro I link against this with:
CONFIG(debug, debug|release):LIBS  += -L../lib/$${COMPILER}/debug/ 
-l$${LIBRARY_NAME}
CONFIG(release, debug|release):LIBS  += -L../lib/$${COMPILER}/release/ 
-l$${LIBRARY_NAME}

The examplesOBJECTS_DIRis currenty not the same as the one for the lib.
Why is that necessary for shadow builds?


 

___
Qt-creator mailing list
Qt-creator@trolltech.com
http://lists.trolltech.com/mailman/listinfo/qt-creator


Re: [Qt-creator] plain C++ project

2010-09-24 Thread Matthias Pospiech
  Am 24.09.2010 08:13, schrieb André Pönitz:
 However I experienced that without Qt debugging of a plain c++ project
 failed. The easy solution was to readd QtCore again.
 That sounds like you were (not...) using the compiled debugging helpers,
 i.e. you are either on Mac, or more likely using an too old gdb.
It was not my computer. I gave around Qt SDK 4.6.3 and QtCreator 2.0.1.
To be true I have no idea what the 'compiled debugging helpers' are or how
I could have no been using them.

Matthias
___
Qt-creator mailing list
Qt-creator@trolltech.com
http://lists.trolltech.com/mailman/listinfo/qt-creator


Re: [Qt-creator] linking libs with shadow builds fails

2010-09-24 Thread Matthias Pospiech
  Am 24.09.2010 09:18, schrieb Christian Kandeler:

 I am using subdirs. In src.pro I am using this code to link:
 LIBS += -L../lib/fftw/32/ -lfftw3-3
 LIBS += -L $$OUT_PWD/../lib/fftw/32/ -lfftw3-3
What is OUT_PWD ? what does it contain.
Are therer other similar predefined variables?

Matthias
___
Qt-creator mailing list
Qt-creator@trolltech.com
http://lists.trolltech.com/mailman/listinfo/qt-creator


Re: [Qt-creator] plain C++ project

2010-09-23 Thread Matthias Pospiech
  Am 23.09.2010 17:24, schrieb Coda Highland:
 The only change needed to the .pro file is CONFIG -= qt, and
 forgetting that just means that the application LINKS to QtCore and
 QtGui -- it doesn't require you to use any Qt classes or tools in the
 source code.
I have been using QtCreator in a class lately as well. The problems of 
all students were not at all
related to the make system. It is much much more important to have a 
easy learnable IDE and understandable
error messages.

However I experienced that without Qt debugging of a plain c++ project 
failed. The easy solution was to readd QtCore again.

Matthias
___
Qt-creator mailing list
Qt-creator@trolltech.com
http://lists.trolltech.com/mailman/listinfo/qt-creator


[Qt-creator] linking libs with shadow builds fails

2010-09-23 Thread Matthias Pospiech
 I experience so frequently problems with shadow builds that I switch 
them off by default.
However I understand the principle behind the shadow builds and would 
also like to understand

how to get my project working with shadow builds.

Here is what I do: A project which creates a lib which is later linked 
in the example.


/project/example/
/project/fftw/32/libfftw3-3.a - the lib file I want to link against
/project/src/ - my own libary code, containing src.pro

I am using subdirs. In src.pro I am using this code to link:
LIBS += -L../lib/fftw/32/ -lfftw3-3

which _fails_ with shadow builds

If I use this code:
LIBS += -L../lib/other/fftw/32/libfftw3-3.a
then it does not complain about not finding the lib file.
However non of the containing functions are found. Which means it was no 
linked.


without shadow builds everything works as expected.

Solutions of this problem are welcome,
however any solution requiring an absolute path c:\user\ is a no go.

Matthias






___
Qt-creator mailing list
Qt-creator@trolltech.com
http://lists.trolltech.com/mailman/listinfo/qt-creator


Re: [Qt-creator] linking libs with shadow builds fails

2010-09-23 Thread Matthias Pospiech
  Am 24.09.2010 00:27, schrieb Danny Price:
 I think your code is failing because you're not accounting for the 
 paths within the build directory.

Sorry, but I do not see the link to the information you provide. I have 
a problem with an external library.
And the path to the library is correct.

Matthias
___
Qt-creator mailing list
Qt-creator@trolltech.com
http://lists.trolltech.com/mailman/listinfo/qt-creator


Re: [Qt-creator] Experience using QtCreator in Cpp Course

2010-09-16 Thread Matthias Pospiech
  Am 16.09.2010 08:03, schrieb Nicolas Arnaud-Cormos:
 On Thursday 16 September 2010 23:10:01 Matthias Pospiech wrote:
   No student taking the course (3 hours in one day) had any C++
 environment installed, so I gave the latest windows sdk and the
 QtCreator 2.0.1
 installation around.
 Why don't you install Qt SDK instead of Windows SDK+Qt Creator? It has
 everything you need: compiler, debugger and creator and it's working out of
 the box.
I have provided both, because the latest SDK does not ship with the 
latest QtCreator.
I do know that the SDK comes with QtCreator.

Matthias

___
Qt-creator mailing list
Qt-creator@trolltech.com
http://lists.trolltech.com/mailman/listinfo/qt-creator


Re: [Qt-creator] Experience using QtCreator in Cpp Course

2010-09-16 Thread Matthias Pospiech
  Am 16.09.2010 01:34, schrieb Bill King:
 This is  very worthwhile input, sorry to sound like I'm fobbing you off
 elsewhere, but it would be excellent if you could turn this into a
 suggestion task over at http://bugreports.qt.nokia.com.

Added as http://bugreports.qt.nokia.com/browse/QTCREATORBUG-2372

Matthias
___
Qt-creator mailing list
Qt-creator@trolltech.com
http://lists.trolltech.com/mailman/listinfo/qt-creator


[Qt-creator] Experience using QtCreator in Cpp Course

2010-09-15 Thread Matthias Pospiech
  I would like to share my experience in a workshop I have given lately.
It was about c++ and a basic introduction of classes. It had nothing to 
do with Qt, though
I used it in one example for plotting a function, and I created all 
example projects with QtCreator.

No student taking the course (3 hours in one day) had any C++ 
environment installed, so I gave the latest windows sdk and the 
QtCreator 2.0.1
installation around. Unfortunately neither of the programs put any path 
into the PATH (why ?) . That meant that we had to add a Qt environment
in Creator. Aport from being very confusing for all students none of 
them understood which path to add. I had displayed my path on the projector,
but nevertheless most of the got it wrong.

Then we started writing code. However in most cases Creator did not 
compile anything but instead printed a mesage about make not found or 
similar.
We first thougth that the path would be wrong, but that was not the 
problem. Instead nothing was set up wrong. We had to restart QtCreator 
to get it working.

The third error was that in my example for all students the project 
could not link the project relative path libraries. Why ? Because of 
shadow builds. So no student including me understood the usage of shadow 
builds because they just break your project from compilation.

Once everything worked they were happy with it.

So could these basic first-set-up procedure be improved?

Matthias

___
Qt-creator mailing list
Qt-creator@trolltech.com
http://lists.trolltech.com/mailman/listinfo/qt-creator


[Qt-creator] application ends in debug mode on exception

2010-08-27 Thread Matthias Pospiech
I get exeptions like this:
terminate called after throwing an instance of 'std::out_of_range'

what(): vector::_M_range_check

but I have no chance to debug it, since the debugger ends instead of 
showing the occurence of the problem.

Can this be changed somehow?

Matthias


___
Qt-creator mailing list
Qt-creator@trolltech.com
http://lists.trolltech.com/mailman/listinfo/qt-creator


Re: [Qt-creator] how to set binary different in debug and release mode

2010-08-16 Thread Matthias Pospiech
André Pönitz schrieb:
 On Monday 16 August 2010 12:55:24 ext Matthias Pospiech wrote:
   
 I set up the binary path different to the qmake standard. this means 
 that QtCreator always fails to execute the binary since it is not found.
 Therefore I set up the path manually. However this can only be done for 
 a project and not independed for debug and release mode.

 However, I put release and debug version in different path and they have 
 different names.

 So my question is: can QtCreator (lastes stable version) define in one 
 project the executable different for debug and release mode?
 

 See http://doc.trolltech.com/4.6/qmake-common-projects.html, especially the 
 bits in the section titled Building and Installing in Debug and Release 
 Modes.
   
You probably misunderstood me. I have set up qmake correct. The problem 
is within QtCreator and its project settings (or the likly missing of such)

The pro file contains this code:

win32-g++:COMPILER = mingw

win32-msvc*:COMPILER = msvc

linux-g++:COMPILER = gcc


CONFIG(debug, debug|release):win32:BINARY_NAME = $$join(BINARY_NAME,,,d)

TARGET = $${BINARY_NAME}

BIN_DIR = ../bin

debug:DESTDIR = $${BIN_DIR}/$${COMPILER}/debug/

release:DESTDIR = $${BIN_DIR}/$${COMPILER}/release/

but if I set in project settings that I want to use the directory and 
binary:

E:\SVN\BeamProfileEvolution\bin\mingw\debug\BeamProfileEvolutiond.exe

then for release mode the _same_ binary is chosen which is obviously 
wrong. If I change it in release mode than in debug it is wrong.
So my question is whether the executable can be chosen differen in 
_QtCreator_ for debug and release mode.

Matthias

___
Qt-creator mailing list
Qt-creator@trolltech.com
http://lists.trolltech.com/mailman/listinfo/qt-creator


Re: [Qt-creator] how to set binary different in debug and release mode

2010-08-16 Thread Matthias Pospiech
André Pönitz schrieb:
 On Monday 16 August 2010 15:11:30 ext Matthias Pospiech wrote:
   
 [...]
 CONFIG(debug, debug|release):win32:BINARY_NAME = $$join(BINARY_NAME,,,d)

 TARGET = $${BINARY_NAME}

 BIN_DIR = ../bin

 debug:DESTDIR = $${BIN_DIR}/$${COMPILER}/debug/
 [...]
 

 Does using 

CONFIG(debug, debug|release):DESTDIR = $${BIN_DIR}/$${COMPILER}/debug/

 make a difference?
   
It is true that this is necessary if I compile in both modes, currently 
I have the other switched of which means that my code works.
But anyway I am not talking about qmake code- because that works. I was 
only interested if one could set different binarys in the QtCreator 
project settings.

Matthias

___
Qt-creator mailing list
Qt-creator@trolltech.com
http://lists.trolltech.com/mailman/listinfo/qt-creator


[Qt-creator] debug QVector

2010-08-05 Thread Matthias Pospiech
If I want to look at the contents of a QVector I only get this:
unavailable synchroneous data

which means I am not able to get any information.
The Version is 2.0 with mingw.

So how do I get this information?

Matthias
___
Qt-creator mailing list
Qt-creator@trolltech.com
http://lists.trolltech.com/mailman/listinfo/qt-creator


Re: [Qt-creator] Adding header files

2010-07-23 Thread Matthias Pospiech
André Pönitz schrieb:
 On Friday 23 July 2010 13:45:33 ext Jothy wrote:
   
 I simply added INCLUDEPATH += -I C:\boost

 Now its able to find all the header files except file path starting with 
 boost/
 

 Drop the '-I' from INCLUDEPATH
   
What does the -I switch mean anyway?

Matthias

___
Qt-creator mailing list
Qt-creator@trolltech.com
http://lists.trolltech.com/mailman/listinfo/qt-creator


[Qt-creator] make tries to link .obj file that will never be build

2010-07-19 Thread Matthias Pospiech
I am trying to work around the __dllspec Definitions in a case where I 
want to use a class in different dlls.
What I have done now is to move the class which is used in many project 
to a header file only
and include that in the project class file. This looks like this:

-
#ifndef CAMERAIMAGE_H_
#define CAMERAIMAGE_H_

// for each project using this file this needs to be defined
#ifdef QSMXCAMERA_EXPORT
#define QCAMERAIMAGEEXPORT QSMXCAMERA_EXPORT
#else
#define QCAMERAIMAGEEXPORT
#endif

class QCAMERAIMAGEEXPORT QCameraImage : public QWidget
{
Q_OBJECT
public:
...
};
#endif
--

-
#ifndef QCAMERAWIDGET_H
#define QCAMERAWIDGET_H

// this class is in the project and knows how to define QSMXCAMERA_EXPORT
#include QCameraSMXGlobal.h
#include QCameraImage.h

class QSMXCAMERA_EXPORT QCameraWidget : public QCameraImage
{
Q_OBJECT
public:
explicit QCameraWidget(QWidget *parent = 0);

signals:

public slots:

};

#endif // QCAMERAWIDGET_H
--

With this however I get the error
LINK : fatal error LNK1181: Eingabedatei build\debug\QCameraImage.obj 
kann nicht geöffnet werden.

However there is no QCameraImage.cpp which could be build. And I can not 
include such a file because then the header would be loaded with 
incorrect Export definitions.

Why is this happening and how can I get around it?
Concerning QtCreator - is there anything I can define within the .pro 
file to solve this?

Matthias
___
Qt-creator mailing list
Qt-creator@trolltech.com
http://lists.trolltech.com/mailman/listinfo/qt-creator


Re: [Qt-creator] How to install dll directly after compilation

2010-06-18 Thread Matthias Pospiech
Carsten Breuer schrieb:
 Hi Mathias,
 hi all,

   
 I have a project which compiles first the dll and second the 
 corresponding test example.
 Right now I have to copy the dll each time to the example bin folder to 
 test it.
 

 The better way during development is to define the path in
 the project settings for execute (in the test application)
 like qt do it for the mingw dlls.
   
I define the execute path anyway. But that does not mean that the 
executable finds the dll in a complete different path,
or have I missed something?

 BTW: Is the frame grabber / camera now working?
  Feedback to the supporters is a nice thing ;-)!
   
This was a different project (positioning stage). I will continue to 
work on the camera project probably
beginning of next week. And I promise to give some feedback - and ask back.
(this is related to a discussion [Qt-interest] How to use Windows 
Message System in Qt/Win Application?,
further discussion happened on 
http://www.c-plusplus.de/forum/viewtopic-var-p-is-1909882.html)

Matthias
___
Qt-creator mailing list
Qt-creator@trolltech.com
http://lists.trolltech.com/mailman/listinfo/qt-creator


[Qt-creator] qmake Path on Commandline not searched

2010-06-17 Thread Matthias Pospiech
Hallo,
I have a variable 'LIBRARYPATH'

which is used in the following way

LIBRARYPATH = E:/Daten/Dev/SVN/library/
INCLUDEPATH += $${LIBRARYPATH}include/Micos/

however this path is different on every computer. If I add
LIBRARYPATH = E:/Daten/Dev/SVN/library/ to the qmake command line
options the part is not added to the INCLUDEPATH anymore and thus all 
include files
within that path are not found. (Marked green in the editor)

So how can I add a Path to qmake on commandline such that QtCreator 
still uses it ?

Matthias
___
Qt-creator mailing list
Qt-creator@trolltech.com
http://lists.trolltech.com/mailman/listinfo/qt-creator


Re: [Qt-creator] howto activate cdb

2010-03-18 Thread Matthias Pospiech
Robert Löhning schrieb:
 ext Matthias Pospiech schrieb:
   
 I have installed cdb and configured the path correct.

 
 Hi Matthias,

 did you enable cdb in Tools / Options / Debugger / Cdb ? You have to 
 check the box and enter the path where cdb.exe is located.
   

That is what I meant by 'I have installed cdb and configured the path 
correct.' However I forgot the restart QtCreator.

However now I get the error:
Ausgabe Hilfbibliothek nicht gefunden (which could be translated as 
output help library not found)

What does this mean now?

Matthias

___
Qt-creator mailing list
Qt-creator@trolltech.com
http://lists.trolltech.com/mailman/listinfo/qt-creator


[Qt-creator] How to set up compilation toochain for msvc

2010-03-02 Thread Matthias Pospiech
I am using QtCreator from 4.6.2 SDK.

I have installed an older Qt 4.5.2 compiled with msvc 8.0 (2005) which I 
require for a project which
needs a comercial msvc build lib.

Now I want to set up QtCreator to use the msvc toolchain. Thus qmake + 
nmake (+ nmake clean).

I can select in the build configuration the version 4.5.2 and creator 
selects 'Microsoft Visual C++'
But in the buildssteps only qmake is correct. Everything else is still 
mingw32-make.

Why does it not select nmake?

I can overwrite mingw32-make with nmake which leads to a compilation.
But the process of setting it up is strange.

Matthias
___
Qt-creator mailing list
Qt-creator@trolltech.com
http://lists.trolltech.com/mailman/listinfo/qt-creator


[Qt-creator] Howto switch between header and cpp file

2010-03-02 Thread Matthias Pospiech
I often write my functions in the cpp file first and then add them to 
the header file.
However I could not see any way to switch by a key kombination between 
header and cpp file.
Is this possible and if how? (This assumes of course that both have the 
same name, but that should
be in most cases valid).

Matthias
___
Qt-creator mailing list
Qt-creator@trolltech.com
http://lists.trolltech.com/mailman/listinfo/qt-creator


Re: [Qt-creator] Target name wrong, zero number appended

2010-02-14 Thread Matthias Pospiech
Coda Highland schrieb:
 You mean the specific format used to name the DLL files? I don't know.
 The VER_MAJ variable is documented in the qmake manual.
   
I can take out the VER_MAJ variable, but still the name is with an 
appended 0.

Matthias
___
Qt-creator mailing list
Qt-creator@trolltech.com
http://lists.trolltech.com/mailman/listinfo/qt-creator


Re: [Qt-creator] mingw32-make.exe: Interrupt/Exception caught (code = 0xc0000005, addr = 0x41f96e)

2010-02-02 Thread Matthias Pospiech
Daniel Teske schrieb:
 On Saturday 30 January 2010 16:06:55 ext Matthias Pospiech wrote:
   
 I get the following error on any compilation started within qtCreator
 (1.3.1, QT 4.6.1).

 mingw32-make.exe: Interrupt/Exception caught (code = 0xc005, addr =
 0x41f96e)

 However if I compile the same project from the qt command prompt I have
 no problem.
 
 Does it work if you start Qt Creator from that command line? Is the path to 
 the MinGW version set in the Tool/Options/Qt Dialog?
   
It does not work if Qt Creator is started from commandline.
And the path to Mingw is set to 'C:\Qt\SDK\2010.01\mingw'

Matthias

___
Qt-creator mailing list
Qt-creator@trolltech.com
http://lists.trolltech.com/mailman/listinfo/qt-creator


Re: [Qt-creator] mingw32-make.exe: Interrupt/Exception caught (code = 0xc0000005, addr = 0x41f96e)

2010-02-01 Thread Matthias Pospiech
Matthias Pospiech schrieb:
 I get the following error on any compilation started within qtCreator 
 (1.3.1, QT 4.6.1).

 mingw32-make.exe: Interrupt/Exception caught (code = 0xc005, addr = 
 0x41f96e)

 However if I compile the same project from the qt command prompt I have 
 no problem.

 The System is Window 7.

 Any idea?
   
Can anyone from Qt comment on this problem?
Currently I can not use QtCreator at all, since it does not compile 
anything.

Matthias

___
Qt-creator mailing list
Qt-creator@trolltech.com
http://lists.trolltech.com/mailman/listinfo/qt-creator


Re: [Qt-creator] qt-creator and multiple projects link issue with msvc

2010-01-27 Thread Matthias Pospiech
Sandro Cavazzoni schrieb:
 Under linux with gcc i've no problem... it compile my .so objects and 
 after that it compile main binary linking it with my .so
 Under windows with msvc it doesn't work... it compile correctly my dll 
 but when it compile main binary it cannot link with it because it want a 
 .lib and not a .dll
The .lib contains information necessary to load the dll.
A .lib however is only created if your library contains the necessary 
code elements.
I mean the '__declspec(dllexport)' and the corresponding import one.
This is only necessary with the msvc compiler. An example is shown here
http://de.wikipedia.org/wiki/Dynamic_Link_Library#Erstellen_einer_DLL


Matthias
___
Qt-creator mailing list
Qt-creator@trolltech.com
http://lists.trolltech.com/mailman/listinfo/qt-creator


Re: [Qt-creator] ideas

2009-10-07 Thread Matthias Pospiech
Andre Poenitz schrieb:
 On Tue, Oct 06, 2009 at 06:13:37PM +0100, Danny Price wrote:
   
 The frustrating thing about this situation is that it seems relatively  
 simple to fix without compromising the locator system or changing any  
 QMake or Creator fundamentals - a second file containing file groups  
 is one solution.
 

 *gosh*

 If it is that easy, why don't you simply implement it and submit a merge
 request? This would save time on both sides.
   
This seams to be a discussion with frustrated people on both sides - 
users and developers.
I personally agree with Danny. Maybe it is not that simple, and I could 
not implement a patch either,
but if there was a single note from the developer team that they are 
going to implement this and where it is placed
on the roadmap that could end the discussion and give people like me the 
option to switch to qtcreator after this
has been implemented.

I am not using 1000 files, but something like 200 classes and 500 files 
with about 30 'filters' in Visual Studio
in my biggest project (simulation and device control  for my phd).

Matthias


___
Qt-creator mailing list
Qt-creator@trolltech.com
http://lists.trolltech.com/mailman/listinfo/qt-creator


Re: [Qt-creator] Debug problem - File not found

2009-07-31 Thread Matthias Pospiech
Hendrik Thering schrieb:
 Hi,
 when i want to debug my project i get an error message, that the
 exe-file cannot be opened. In this message-box it tells me, that the
 file d:\project\debug\project.exe could not be found.
 The problem obviously is, that i have changed the target directories in
 the project.pro file via

 BIN_DIR = bin

 COMPILER = mingw


 debug:DESTDIR = $${BIN_DIR}/$${COMPILER}/debug/

 release:DESTDIR = $${BIN_DIR}/$${COMPILER}/release/


 to d:\project\bin\mingw\debug\project.exe. When i start this file
 manually, everything works quite fine, but i cannot use the debugger to
 check the contents of my variables while the programm is running.

   
I have the same problem, using QtCreator 1.1.
I could work around it by defining a new project run configuration.

But it is still highly confusing - why is QtCreator not using the pro 
file settings but instead hardcoded settings for the executable and 
working directory?

Matthias

___
Qt-creator mailing list
Qt-creator@trolltech.com
http://lists.trolltech.com/mailman/listinfo/qt-creator


[Qt-creator] Path for designer plugins

2009-07-29 Thread Matthias Pospiech
I am looking for the path where QtCreator-Designer is looking for the 
plugins. I put it to the path of Qt-Designer (the standalone one), but 
that does not mean that QtCreator finds it.

Matthias
___
Qt-creator mailing list
Qt-creator@trolltech.com
http://lists.trolltech.com/mailman/listinfo/qt-creator


Re: [Qt-creator] Antwort: Compile a single .cpp file?

2009-05-27 Thread Matthias Pospiech
Robert Caldecott schrieb:
 Until recently I lived in a Visual Studio world where the ability to
 compile (and not link) a single .cpp file is something people have
 grown used to. 
I totally agree with your ideas, especially the single cpp file 
compilation and the virtual folders.
However for virtual folders something must be added to qmake .pro file 
syntax I assume.

Matthias
___
Qt-creator mailing list
Qt-creator@trolltech.com
http://lists.trolltech.com/mailman/listinfo/qt-creator


[Qt-creator] mixed debug and release build

2009-05-25 Thread Matthias Pospiech
I have set build configuration to release, but I get a build which is 
using debug and release libaries:

g++ -enable-stdcall-fixup -Wl,-enable-auto-import 
-Wl,-enable-runtime-pseudo-reloc -Wl,-s -Wl,-subsystem,console -mthreads 
-Wl -o bin\mingw\release\QLaserDynamic.exe 
object_script.QLaserDynamic.Release 
-Lc:\Programme\Qt\SDK\2009.02\qt\lib -Llib/wwwidgets/mingw/debug 
-lwwwidgets4d -Llib/qwt/mingw/debug -lqwtd5 
-Llib/wwwidgets/mingw/release -lwwwidgets4 -Llib/qwt/mingw/release 
-lqwt5 -lQtGui4 -lQtCore4


you can see that
wwwidgets4d and wwwidgets4
qwtd5 and qwt5

are linked, which is not ok.
this means that both release and debug qt dlls are required.

Here is the total .pro file. I would like to know if this is not ok for 
using inside qtcreator or if this problem is qtcreator specific.
(Sorry, but email messes up the intendation)

#CONFIG += debug_and_release

#CONFIG += build_all

#CONFIG -= release

#CONFIG += debug

CONFIG += qt thread warn_on

CONFIG += console

TEMPLATE = app

# -

# Define Variables

# -

BINARY_NAME = QLaserDynamic

BUILD_DIR = build

BIN_DIR = bin

COMPILER = mingw

# -

win32 {

RELEASE_SUFFIX =

DEBUG_SUFFIX = d

}

CONFIG(debug, debug|release) {

SUFFIX_STR = $${DEBUG_SUFFIX}

}

else {

SUFFIX_STR = $${RELEASE_SUFFIX}

}

# -

# Target Directory

# -

debug:DESTDIR = $${BIN_DIR}/$${COMPILER}/debug/

release:DESTDIR = $${BIN_DIR}/$${COMPILER}/release/

# -

# Executable Filename

# -

TARGET = $${BINARY_NAME}$${SUFFIX_STR}

# -

# Prepocessor Definitions

# -

win32{

DEFINES += WIN32

DEFINES += _WINDOWS

DEFINES += QT

DEFINES += QT_DLL

DEFINES += QWT_DLL

DEFINES += wwwidgets

debug {

DEFINES += _DEBUG

}

release {

DEFINES += NDEBUG

DEFINES += QT_NO_DEBUG

}

}

DEFINES += NOMINMAX

DEFINES += QT_LARGEFILE_SUPPORT

DEFINES += QT_THREAD_SUPPORT

# -

# Objects Directory

# -

debug{

OBJECTS_DIR = $${BUILD_DIR}/$${BINARY_NAME}/debug/

}

release{

OBJECTS_DIR = $${BUILD_DIR}/$${BINARY_NAME}/release/

}

# -

# Moc Directory

# -

MOC_DIR = $${BUILD_DIR}/$${BINARY_NAME}/

# -

# Ui Directory

# -

UI_DIR = $${BUILD_DIR}/$${BINARY_NAME}/ui

# -

# Include directories

# -

INCLUDEPATH += src \

ui \

include \

include/eigen \

include/boost \

include/fftw \

include/qwt \

include/wwwidgets \

include/qextserialport \

include/matthias/qtwidgets \

include/matthias/SMX \

include/matthias/GPIB \

include/matthias/PI \

include/matthias/PiezoJena \

include/matthias/Math \

include/matthias/qwtplot \

include/matthias/Common \

# -

# Libaries

# -

unix{

}

# COMPILER_LIBARY_SUFFIX = .a

win32 {

debug{

# qtmaind.lib

# QtCored4.lib

# QtGuid4.lib

LIBS += -Llib/wwwidgets/$${COMPILER}/debug -lwwwidgets4d

LIBS += -Llib/qwt/$${COMPILER}/debug -lqwtd5

# LIBS += -Llib/qextserialport/debug -lqextserialport

}

release {

# qtmain.lib

# QtCore4.lib

# QtGui4.lib

LIBS += -Llib/wwwidgets/$${COMPILER}/release -lwwwidgets4

LIBS += -Llib/qwt/$${COMPILER}/release -lqwt5

# LIBS += -Llib/qextserialport/release -lqextserialport

}

# LIBS += -Llib/fftw/double -llibfftw3-3

# LIBS += -Llib/GPIB -lgpib-32.obj

# LIBS += -Llib/MMC -lMMC413

}

# -

# Sources

# -

FORMS += ui/mainwindow.ui \

ui/DialogLoadProject.ui \

ui/DialogSaveProject.ui \

ui/DialogSetCalcParameters.ui \

ui/DialogSetLaserParameters.ui

SOURCES += src/main.cpp \

src/MainWindow.cpp \

src/DialogLoadProject.cpp \

src/DialogSaveProject.cpp \

src/DialogSetCalcParameters.cpp \

src/DialogSetLaserParameters.cpp \

src/laser.cpp \

src/laserdynamics.cpp \

src/laserdynamicsbase.cpp \

src/saturableabsorber.cpp \

include/matthias/qtwidgets/QScienceSpinBox.cpp \

include/matthias/qwtplot/QCurvePlot.cpp

HEADERS += src/MainWindow.h \

src/DialogLoadProject.h \

src/DialogSaveProject.h \

src/DialogSetCalcParameters.h \

src/DialogSetLaserParameters.h \

src/laser.h \

src/laserdynamics.h \

src/laserdynamicsbase.h \

src/saturableabsorber.h \

include/matthias/qtwidgets/QScienceSpinBox.h \