PDA

View Full Version : QMAKE problem: gcc instead of g++



hipogrito
19th September 2018, 20:49
Hi,

I have a QT program that compiles in Ubuntu 16.04 and works perfectly. Hurrah!

I updated my computer to Ubuntu 18.04.

When I compile now, I get an error in the first c++ include.

If I look at the Makefile that QMAKE creates, I see that is trying to compile with CC instead of CXX.

I have Ubuntu 16.04 in a separate computer and I have verified that it still works there.


So, what kind of general QT/QMAKE environment or whatever I don't have in my Ubuntu 18.04 that I did have in my Ubuntu 16.04 that is confusing QMAKE?

BTW, I check qmake -query, and it does not look wrong...
QMAKE_SPEC:linux-g++
QMAKE_XSPEC:linux-g++
QMAKE_VERSION:3.1
QT_VERSION:5.9.5


Any idea?

Thanks,

Hipo

Added after 35 minutes:

Hi,

I'll answer myself...

I fixed it by removing qt5 and installing qt4.

Not sure what environment variables or default parameters change when you do that, but that fixes it for me...

Thanks in any case to anybody that read the thread,

Regards,
Hipo

d_stranz
20th September 2018, 18:38
I fixed it by removing qt5 and installing qt4.

That sounds like a pretty poor solution to me. It seems like you have a configuration problem in your Qt5 / Ubuntu 18.04 environment that should be easy to fix.