Qt-interest Archive, March 2007
qmake + VS
Message 1 in thread
Hi,
I use qmake to generate Visual Studio project files from .pro files. I
have installed both Visual Studio 2003 and 2005. How can I configure
qmake to generates project files for a distinct VS version? I don't want
to work with command-line parameters here but would prefer to e.g. set
an environment variable telling qmake to always generate the VS 2003 format.
Any help appreciated!
M
--
[ signature omitted ]
Message 2 in thread
QMartin [mailto:martin.umgeher@xxxxxxxxxxx] wrote:
> I use qmake to generate Visual Studio project files from .pro files. I
> have installed both Visual Studio 2003 and 2005. How can I configure
> qmake to generates project files for a distinct VS version? I
> don't want
> to work with command-line parameters here but would prefer to e.g. set
> an environment variable telling qmake to always generate the
> VS 2003 format.
Create a 'qmake.bat' calling the real qmake with appropriate
parameters and make sure qmake.bat is found early in your %PATH%
[Of course 'myqmake200{3,5}.bat' would result in less confusion...]
Andre'
--
[ signature omitted ]
Message 3 in thread
André Pönitz schrieb:
> QMartin [mailto:martin.umgeher@xxxxxxxxxxx] wrote:
>> I use qmake to generate Visual Studio project files from .pro files. I
>> have installed both Visual Studio 2003 and 2005. How can I configure
>> qmake to generates project files for a distinct VS version? I
>> don't want
>> to work with command-line parameters here but would prefer to e.g. set
>> an environment variable telling qmake to always generate the
>> VS 2003 format.
>
> Create a 'qmake.bat' calling the real qmake with appropriate
> parameters and make sure qmake.bat is found early in your %PATH%
>
> [Of course 'myqmake200{3,5}.bat' would result in less confusion...]
>
> Andre'
Pragmatic, but should work. Thanks :) But what would the "appropriate
parameters" be?
M
--
[ signature omitted ]
Message 4 in thread
QMartin schrieb:
> André Pönitz schrieb:
>> ...
>> Create a 'qmake.bat' calling the real qmake with appropriate
>> parameters and make sure qmake.bat is found early in your %PATH%
>>
>> [Of course 'myqmake200{3,5}.bat' would result in less confusion...]
>>
>> Andre'
>
> Pragmatic, but should work. Thanks :) But what would the "appropriate
> parameters" be?
I'm not sure if you can pass parameters to qmake, but I think it also
looks at the environment variable QMAKESPEC as to decide for which
Visual Studio to create project files, no?
Try setting QMAKESPEC=win32-msvc2005 and QMAKESPEC=win32-msvc2005
respective. But I believe you can also pass the "QMAKESPEC" to use as
parameter to qmake, see docs.
Cheers, Oliver
--
[ signature omitted ]
Message 5 in thread
Till Oliver Knoll schrieb:
> QMartin schrieb:
>> André Pönitz schrieb:
>>> ...
>>> Create a 'qmake.bat' calling the real qmake with appropriate
>>> parameters and make sure qmake.bat is found early in your %PATH%
>>>
>>> [Of course 'myqmake200{3,5}.bat' would result in less confusion...]
>>>
>>> Andre'
>> Pragmatic, but should work. Thanks :) But what would the "appropriate
>> parameters" be?
>
> I'm not sure if you can pass parameters to qmake, but I think it also
> looks at the environment variable QMAKESPEC as to decide for which
> Visual Studio to create project files, no?
>
> Try setting QMAKESPEC=win32-msvc2005 and QMAKESPEC=win32-msvc2005
> respective. But I believe you can also pass the "QMAKESPEC" to use as
> parameter to qmake, see docs.
>
> Cheers, Oliver
>
Ah, that's what I was looking for. Setting QMAKESPEC to win32-msvc seems
to do the trick (i.e. generate VS 2003 files).
thx!
M
--
[ signature omitted ]