Multiple target patterns in Makefile
Hi,
I am trying to run a simple hello world program and when I try to make the .pro file I get the error:
Makefile:92: *** multiple target patterns. Stop.
Line 92 of my Makefile is:
Makefile: hello2.pro C:\Qt\3.2.1NonCommercial\mkspecs\cygwin-g++\qmake.conf
I am using cygwin.
Does anyone know what I should do?
-Melissa
Re: Multiple target patterns in Makefile
Quote:
Originally Posted by
mea36
Makefile: hello2.pro C:\Qt\3.2.1NonCommercial\mkspecs\cygwin-g++\qmake.conf
I think that the problem is that your Makefile contains a windows paths, not Unix ones and Cygwin's make gets confused.
I'm not sure if Qt 3.2.1 non-commercial can be used with Cygwin. Maybe you should try normal windows command prompt --- cmd.exe?
Re: Multiple target patterns in Makefile
Quote:
Originally Posted by
jacek
I'm not sure if Qt 3.2.1 non-commercial can be used with Cygwin.
AFAIR 3.2.1NC supports only MSVC and Borland compilers. I think g++ won't be able to (at least) link with the library produced for MSVC or Borland (there are two distinct versions - each for one of the compiler families).
Re: Multiple target patterns in Makefile
My orignal problem was that qmake couldn't read QMAKESPEC conf file:
$ qmake hello.pro
Failure to read QMAKESPEC conf file /usr/lib/qt3/mkspecs/cygwin-g++\qmake.conf.
Error processing project file: C:/cygwin/home/Melissa Aaron/opengl/hello/hello.pro
So I then set QMAKESPEC to equal "C:/Qt/3.2.1NonCommercial/mkspecs/cygwin-g++"
If I do that then $qmake hello.pro doesn't give me any errors, but $make gives me the multiple target patterns error.
Re: Multiple target patterns in Makefile
Quote:
Originally Posted by
mea36
So I then set QMAKESPEC to equal "C:/Qt/3.2.1NonCommercial/mkspecs/cygwin-g++"
Maybe you should try "/c/Qt/3.2.1NonCommercial/mkspecs/cygwin-g++"?
Re: Multiple target patterns in Makefile
No, That doesn't work either. It's that backslash and I don't know what to do about it.
Do you know if there's anyway to change that backslash?
And thanks for your help.
Re: Multiple target patterns in Makefile
Quote:
Originally Posted by
mea36
Do you know if there's anyway to change that backslash?
I'm afraid that if qmake insists on putting that backslash there, it might not be suitable for use with Cygwin. Are you sure that the Qt version you have supports g++?
Re: Multiple target patterns in Makefile
Quote:
Originally Posted by
jacek
I'm afraid that if qmake insists on putting that backslash there, it might not be suitable for use with Cygwin. Are you sure that the Qt version you have supports g++?
I don't know if it supports g++. I'm using version 3.3.4-2
Re: Multiple target patterns in Makefile
No, it doesn't. As I have written above, it only supports MSVC and Borland compilers.
Re: Multiple target patterns in Makefile
o, Thanks. Sorry I didn't notice that before. So what can/do I do now?
Re: Multiple target patterns in Makefile
Switch compilers or switch Qt versions. If you insist on using 3.2.1NC, then you should be able to compile applications with the MSVC version available on Microsoft website (it's called Express or something like that). An alternative is to switch to Qt4.
Re: Multiple target patterns in Makefile
Actually, now that I think about it... initially I was able to get it working. And then I tried to recomplie the code and thats when I began to run into all the errors. So how can g++ be uncompatible if I was able to make it work?
Re: Multiple target patterns in Makefile
I don't know, maybe MinGW is binary compatible with Borland?