Qt-interest Archive, July 2003
mingw32-make path interactions
Message 1 in thread
I am currently attempting to build Qt 3.2.0 (release) with MinGW. I
have attempted this with the installer as well, and get similar
results. I have mapped C:\Qt\3.2.0 to /qt in /etc/fstab. (I have also
attempted this without the mapping, and results are the same)
/qt > configure.exe -stl -rtti -exceptions
The generated makefiles use a backslash as the path separator.
mingw32-make and g++ do not understand these backslashes, so they
cannot find the files. Manually editing the makefiles will fix the
problem, but that's hardly an acceptable solution.
James
Message 2 in thread
Hi,
> I am currently attempting to build Qt 3.2.0 (release) with MinGW. I
> have attempted this with the installer as well, and get similar results.
> I have mapped C:\Qt\3.2.0 to /qt in /etc/fstab. (I have also attempted
> this without the mapping, and results are the same)
>
> /qt > configure.exe -stl -rtti -exceptions
>
> The generated makefiles use a backslash as the path separator.
> mingw32-make and g++ do not understand these backslashes, so they cannot
> find the files. Manually editing the makefiles will fix the problem,
> but that's hardly an acceptable solution.
From what I know, you shouldn't install mingw32-make. When installing
MSYS, you'll see a message saying something like "Thank god,
mingw32-make is not installed... Keep it this way!"
Uninstall mingw32-make and try again.
--
[ signature omitted ]
Message 3 in thread
Dimitri wrote:
> From what I know, you shouldn't install mingw32-make. When installing
> MSYS, you'll see a message saying something like "Thank god,
> mingw32-make is not installed... Keep it this way!"
>
> Uninstall mingw32-make and try again.
I have just been installing MSYS and the message is :
"Oh, joy, you do not have c:/mingw/bin/make.exe. Keep it that way."
All the Makefile generated by the Qt install use mingw32-make, the
build.log show it.
In addition the documentation of mingw and msys it is notice to erase
the make.exe in the mingw/bin directory.
I don't understand all the problem, but when we change the backslash by
a slash, all fine.
Perhaps there are a trouble with make from MinGW ?
regards
joris
Message 4 in thread
On Monday 21 July 2003 21:38, James Emerton wrote:
> I am currently attempting to build Qt 3.2.0 (release) with MinGW. I
[snip]
> The generated makefiles use a backslash as the path separator.
> mingw32-make and g++ do not understand these backslashes, so they
> cannot find the files. Manually editing the makefiles will fix the
> problem, but that's hardly an acceptable solution.
The MinGW makefile generator is expecting a windows shell. That includes
path issues and shell commands like "del". This is helpful for people
switching from msvc to mingw but might be disappointing to people with
linux background.
There are 2 solutions:
1) The unofficialy supported way (without MSYS): After installing the MinGW
distribution rename "mingw32-make.exe" into "make.exe" in the mingw/bin
directory and if you have MSYS installed make sure "sh.exe" is not in the
path. In this configuration Qt3.2.0 compiles out of the box with the
provided installer from trolltech.
2) If you prefer to use a more powerful unix shell, like it's provided with
MSYS ( which is generally the way recommended by the mingw team), you have
patch the mingw-makefile generator (qt/qmake/
generators/win32/mingw_make.cpp) to use "/" and unix shell commands, same
applies to the specs files and the toplevel makefiles in QTDIR and in
QTDIR/qmake.
But I agree, since gnu make on windows handles also forward slashes as
directory separators they should be used in all cases here.
Greetings
Heiko
Message 5 in thread
Heiko wrote :
>2) If you prefer to use a more powerful unix shell, like it's provided
>with
>MSYS ( which is generally the way recommended by the mingw team), you
>have
>patch the mingw-makefile generator (qt/qmake/
>generators/win32/mingw_make.cpp) to use "/" and unix shell commands,
>same
>applies to the specs files and the toplevel makefiles in QTDIR and in
>QTDIR/qmake.
>
>But I agree, since gnu make on windows handles also forward slashes as
>directory separators they should be used in all cases here.
wow,
can you explain more in detail for me,
in addition if you don't use exceptions and rtti put :
QMAKE_CFLAGS = -fno-exceptions -fno-rtti
in C:\Qt\3.2.0\mkspecs\win32-g++\qmake.conf
because by default MinGW use them and the Qt install and Qt configure
don't put them for the future compilation.
With this you win 30% in size of you .exe and dll ;-)
thanks Heiko and trolls
joris
Message 6 in thread
Hi all,
I found my trouble with the backslash and other with the Qt install and
MinGW
In my path environment i remove :
c:\cygwin\bin;C:\msys\1.0\bin
and now all works fine
perhaps this info can help you ;-)
regards
joris
Message 7 in thread
On Tuesday 22 July 2003 14:58, joris Marcillac wrote:
> Hi all,
> I found my trouble with the backslash and other with the Qt install and
> MinGW
>
> In my path environment i remove :
> c:\cygwin\bin;C:\msys\1.0\bin
> and now all works fine
> perhaps this info can help you ;-)
As I said in a previous post: To use the MinGW-Makefile generator that
comes with QT320 you have to work with the windows shell (unless you want
to hack your way through). That means:
1) you have to use the make.exe from the mingw/bin directory which usually
is named mingw32-make.exe. (Rename it back to make.exe if you don't use
MSYS)
2) You have to make sure, that there is no sh.exe ( the unix shell) in your
path cause gnu make uses sh.exe per default for subprocesses if it finds
it, even if the parent process works in a windows shell.
Point 2 is the reason why removing cygwin and msys from your path solved
your problem, cause both directories contain a "sh.exe". But it is
sufficient to rename sh.exe in those dirs so that you still can use the
gnu tools supplied with MSYS and cygwin.
> in addition if you don't use exceptions and rtti put :
> QMAKE_CFLAGS = -fno-exceptions -fno-rtti
> in C:\Qt\3.2.0\mkspecs\win32-g++\qmake.conf
> because by default MinGW use them and the Qt install and Qt configure
> don't put them for the future compilation.
> With this you win 30% in size of you .exe and dll ;-)
It is no longer necessary to set this in QMAKE-CFLAGS cause in Qt320 this
is managed by the configure options (see the specs file).
Greetings
Heiko