[Gambas Bug Tracker] Bug #1059: Compilation fails with Qt 5.7

classic Classic list List threaded Threaded
13 messages Options
Reply | Threaded
Open this post in threaded view
|

[Gambas Bug Tracker] Bug #1059: Compilation fails with Qt 5.7

bugtracker
http://gambaswiki.org/bugtracker/edit?object=BUG.1059&from=L21haW4-

Eduardo SANCHEZ reported a new bug.

Summary
-------

Compilation fails with Qt 5.7

Type             : Bug
Priority         : Medium
Gambas version   : 3.9
Product          : Unknown


Description
-----------

This report is valid for Gambas 3.9.2

I use Slackware64-current. I have both Qt 4 (4.8.7) and Qt 5 (5.7.0) in a dual setup.
In order to compile, I followed the steps outlined in the relevant wiki: ./reconf-all && ./configure -C && make

However, compilation fails when gambas goes to build gb_qt5.
The problem is that Qt 5.7 requires C++11. Now, even despite I tried to set the CXXFLAGS env variable to "-std=c++11", compilation fails. It seems that gambas does not honor that variable.
I even tried to hack the Makefile *after* ./configure -C to add that CXXFLAGS variable to no avail.

This is the first error shown:

/usr/lib64/qt5/bin/moc -o main_moc.cpp main.h
  CXX      gb_qt5_la-main_moc.lo
In file included from /usr/include/qt5/QtCore/qatomic.h:46:0,
                 from /usr/include/qt5/QtCore/qglobal.h:1145,
                 from /usr/include/qt5/QtCore/qnamespace.h:43,
                 from /usr/include/qt5/QtCore/qcoreevent.h:43,
                 from /usr/include/qt5/QtCore/QEvent:1,
                 from main.h:30,
                 from main_moc.cpp:9:
/usr/include/qt5/QtCore/qbasicatomic.h:61:4: error: #error "Qt requires C++11 support"
 #  error "Qt requires C++11 support"
    ^

Thanks,

Eduardo


System information
------------------

This is something I pasted with Gambas 3.9.0, which I built before the upgrade to Qt 5.7 and continues to operate normally.

[System]
Gambas=3.9
OperatingSystem=Linux
Kernel=4.4.38
Architecture=x86_64
Distribution=slackware Slackware 14.2
Desktop=KDE5
Theme=Breeze
Language=es_PY.UTF-8
Memory=11916M

[Libraries]

[Environment]
CPLUS_INCLUDE_PATH=/usr/lib64/qt/include
DBUS_SESSION_BUS_ADDRESS=unix:abstract=/tmp/dbus-HqhA8X74HO,guid=9b0a399f4a8f1580e07f0bac58701f8d
DESKTOP_SESSION=/usr/share/xsessions/plasma
DISPLAY=:0
GB_GUI=gb.qt5
GDK_USE_XFT=1
GS_LIB=<home>/.fonts
G_BROKEN_FILENAMES=1
G_FILENAME_ENCODING=@locale
HOME=<home>
HOSTNAME=<hostname>.sombragris.org
INPUTRC=/etc/inputrc
JAVA_HOME=/usr/lib64/java
KDEDIRS=/usr
KDE_FULL_SESSION=true
KDE_SESSION_UID=1000
KDE_SESSION_VERSION=5
LANG=es_PY.UTF-8
LANGUAGE=en_US
LC_COLLATE=C
LESS=-M
LESSOPEN=|lesspipe.sh %s
LOGNAME=<user>
LS_COLORS=
LS_OPTIONS=-F -b -T 0 --color=auto
MANPATH=/usr/local/man:/usr/man:/usr/lib64/java/man
MINICOM=-c on
PATH=/usr/local/bin:/usr/bin:/bin:/usr/games:/usr/lib64/kf5:/usr/lib64/kde4/libexec:/usr/lib64/java/bin:/usr/lib64/java/jre/bin:/usr/lib64/qt/bin:/usr/lib64/qt5/bin
PKG_CONFIG_PATH=/usr/local/lib64/pkgconfig:/usr/local/share/pkgconfig:/usr/lib64/pkgconfig:/usr/share/pkgconfig
PWD=<home>
QMLSCENE_DEVICE=
QSG_RENDER_LOOP=
QT4DIR=/usr/lib64/qt
QT5DIR=/usr/lib64/qt5
QT_AUTO_SCREEN_SCALE_FACTOR=0
QT_NO_GLIB=1
SAL_USE_VCLPLUGIN=kde4
SESSION_MANAGER=local/<hostname>:@/tmp/.ICE-unix/1382,unix/<hostname>:/tmp/.ICE-unix/1382
SHELL=/bin/bash
SHLVL=1
T1LIB_CONFIG=/usr/share/t1lib/t1lib.config
TERM=dumb
TZ=:/etc/localtime
USER=<user>
VDPAU_LOG=0
XAUTHORITY=<home>/.Xauthority
XCURSOR_THEME=breeze_cursors
XDG_CONFIG_DIRS=/etc/xdg:/etc/kde/xdg
XDG_CURRENT_DESKTOP=KDE
XDG_DATA_DIRS=/usr/share:/usr/share:/usr/local/share
XDG_RUNTIME_DIR=/tmp/xdg-runtime-<user>
XDG_SEAT=seat0
XDG_SEAT_PATH=/org/freedesktop/DisplayManager/Seat0
XDG_SESSION_CLASS=user
XDG_SESSION_COOKIE=<hostname>-1483743117.959646-1603446457
XDG_SESSION_DESKTOP=KDE
XDG_SESSION_PATH=/org/freedesktop/DisplayManager/Session1
XDG_SESSION_TYPE=x11
XDG_VTNR=7
_=/usr/bin/kwrapper5



------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
_______________________________________________
Gambas-user mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gambas-user
Reply | Threaded
Open this post in threaded view
|

[Gambas Bug Tracker] Bug #1059: Compilation fails with Qt 5.7

bugtracker
http://gambaswiki.org/bugtracker/edit?object=BUG.1059&from=L21haW4-

Comment #1 by Benoît MINISINI:

What does 'gcc --version' return on your system?



------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
_______________________________________________
Gambas-user mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gambas-user
Reply | Threaded
Open this post in threaded view
|

[Gambas Bug Tracker] Bug #1059: Compilation fails with Qt 5.7

bugtracker
In reply to this post by bugtracker
http://gambaswiki.org/bugtracker/edit?object=BUG.1059&from=L21haW4-

Benoît MINISINI changed the state of the bug to: NeedsInfo.




------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
_______________________________________________
Gambas-user mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gambas-user
Reply | Threaded
Open this post in threaded view
|

[Gambas Bug Tracker] Bug #1059: Compilation fails with Qt 5.7

bugtracker
In reply to this post by bugtracker
http://gambaswiki.org/bugtracker/edit?object=BUG.1059&from=L21haW4-

Comment #2 by Eduardo SANCHEZ:

Hi Benoît,

gcc --version shows the following:

[eduardo:~]$ gcc --version
gcc (GCC) 5.4.0
Copyright (C) 2015 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.



------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
_______________________________________________
Gambas-user mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gambas-user
Reply | Threaded
Open this post in threaded view
|

[Gambas Bug Tracker] Bug #1059: Compilation fails with Qt 5.7

bugtracker
In reply to this post by bugtracker
http://gambaswiki.org/bugtracker/edit?object=BUG.1059&from=L21haW4-

Comment #3 by Fabien BODARD:

strange ...
[fabien@fabien ~]$ gcc --version
gcc (GCC) 6.2.1 20160830
Copyright © 2016 Free Software Foundation, Inc.
Ce logiciel est libre; voir les sources pour les conditions de copie.  Il n'y a PAS
GARANTIE; ni implicite pour le MARCHANDAGE ou pour un BUT PARTICULIER.



------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
_______________________________________________
Gambas-user mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gambas-user
Reply | Threaded
Open this post in threaded view
|

[Gambas Bug Tracker] Bug #1059: Compilation fails with Qt 5.7

bugtracker
In reply to this post by bugtracker
http://gambaswiki.org/bugtracker/edit?object=BUG.1059&from=L21haW4-

Comment #4 by Fabien BODARD:

and no problem



------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
_______________________________________________
Gambas-user mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gambas-user
Reply | Threaded
Open this post in threaded view
|

[Gambas Bug Tracker] Bug #1059: Compilation fails with Qt 5.7

bugtracker
In reply to this post by bugtracker
http://gambaswiki.org/bugtracker/edit?object=BUG.1059&from=L21haW4-

Comment #5 by Eduardo SANCHEZ:

AFAICT it's not necessary the presence of a gcc version but the presence of Qt > 5.7.0. From 5.7 onwards, Qt requires C++11 for compiling anything.



------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
_______________________________________________
Gambas-user mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gambas-user
Reply | Threaded
Open this post in threaded view
|

[Gambas Bug Tracker] Bug #1059: Compilation fails with Qt 5.7

bugtracker
In reply to this post by bugtracker
http://gambaswiki.org/bugtracker/edit?object=BUG.1059&from=L21haW4-

Comment #6 by Eduardo SANCHEZ:

Sorry. I expressed myself not very clearly.
What I wanted to say is that as far as I can see gcc's version is not really an issue; the issue is that Qt 5.7 and higher reqires C++11 for building anything against it. Usually. one could ensure this by passing the flag "-std=c++11" to the compiler. I try to do this but somehow when building gb_qt5 this is ignored and compilation stops with an error no matter how hard I try to set CXXFLAGS="-std=c++11" or something similar.



------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
_______________________________________________
Gambas-user mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gambas-user
Reply | Threaded
Open this post in threaded view
|

[Gambas Bug Tracker] Bug #1059: Compilation fails with Qt 5.7

bugtracker
In reply to this post by bugtracker
http://gambaswiki.org/bugtracker/edit?object=BUG.1059&from=L21haW4-

Comment #7 by Benoît MINISINI:

Can you try revision #8049?



------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
_______________________________________________
Gambas-user mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gambas-user
Reply | Threaded
Open this post in threaded view
|

[Gambas Bug Tracker] Bug #1059: Compilation fails with Qt 5.7

bugtracker
In reply to this post by bugtracker
http://gambaswiki.org/bugtracker/edit?object=BUG.1059&from=L21haW4-

Comment #8 by Eduardo SANCHEZ:

Hi Benoît,

I tried to build revision #8049.

On the good side, gb_qt5 begins to build smoothly and without problems.

However, compilation fails on the webkit part of gb_qt5 with the same error message. Below is the output where the first error began to appear.

Thanks again for all the help,

Eduardo

OUTPUT:

  CXXLD    gb.qt5.la
make[5]: Leaving directory '/run/media/eduardo/Seagate Backup Plus Drive/build/slackbuilds/gambas3/gambas-code-8049-gambas-trunk/gb.qt5/src'
Making all in webkit
make[5]: Entering directory '/run/media/eduardo/Seagate Backup Plus Drive/build/slackbuilds/gambas3/gambas-code-8049-gambas-trunk/gb.qt5/src/webkit'
  CXX      gb_qt5_webkit_la-main.lo
In file included from /usr/include/qt5/QtCore/qatomic.h:46:0,
                 from /usr/include/qt5/QtCore/qglobal.h:1145,
                 from /usr/include/qt5/QtCore/qchar.h:43,
                 from /usr/include/qt5/QtCore/qstring.h:48,
                 from /usr/include/qt5/QtCore/qdatetime.h:43,
                 from /usr/include/qt5/QtCore/QDateTime:1,
                 from main.cpp:31:
/usr/include/qt5/QtCore/qbasicatomic.h:61:4: error: #error "Qt requires C++11 support"
 #  error "Qt requires C++11 support"
    ^



------------------------------------------------------------------------------
Developer Access Program for Intel Xeon Phi Processors
Access to Intel Xeon Phi processor-based developer platforms.
With one year of Intel Parallel Studio XE.
Training and support from Colfax.
Order your platform today. http://sdm.link/xeonphi
_______________________________________________
Gambas-user mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gambas-user
Reply | Threaded
Open this post in threaded view
|

[Gambas Bug Tracker] Bug #1059: Compilation fails with Qt 5.7

bugtracker
In reply to this post by bugtracker
http://gambaswiki.org/bugtracker/edit?object=BUG.1059&from=L21haW4-

Comment #9 by Benoît MINISINI:

OK, I forgot the other qt5 components. It should work with revision #8050.



------------------------------------------------------------------------------
Developer Access Program for Intel Xeon Phi Processors
Access to Intel Xeon Phi processor-based developer platforms.
With one year of Intel Parallel Studio XE.
Training and support from Colfax.
Order your platform today. http://sdm.link/xeonphi
_______________________________________________
Gambas-user mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gambas-user
Reply | Threaded
Open this post in threaded view
|

[Gambas Bug Tracker] Bug #1059: Compilation fails with Qt 5.7

bugtracker
In reply to this post by bugtracker
http://gambaswiki.org/bugtracker/edit?object=BUG.1059&from=L21haW4-

Comment #10 by Eduardo SANCHEZ:

Hi Benoît, thank you!

I downloaded revision #8051.

gb_qt5_webkit builds correctly now but gb_qt5_ext_la still fails.

OUTPUT from the first error:

make[5]: Entering directory '/run/media/eduardo/Seagate Backup Plus Drive/build/slackbuilds/gambas3/gambas-code-8051-gambas-trunk/gb.qt5/src/ext'
  CXX      gb_qt5_ext_la-main.lo
In file included from /usr/include/qt5/QtCore/qatomic.h:46:0,
                 from /usr/include/qt5/QtCore/qglobal.h:1145,
                 from /usr/include/qt5/QtGui/qwindowdefs.h:43,
                 from /usr/include/qt5/QtWidgets/qwidget.h:43,
                 from /usr/include/qt5/QtWidgets/QWidget:1,
                 from ../gb.qt.h:34,
                 from main.h:28,
                 from main.cpp:31:
/usr/include/qt5/QtCore/qbasicatomic.h:61:4: error: #error "Qt requires C++11 support"
 #  error "Qt requires C++11 support"
    ^
====================

Thanks,

Eduardo



------------------------------------------------------------------------------
Developer Access Program for Intel Xeon Phi Processors
Access to Intel Xeon Phi processor-based developer platforms.
With one year of Intel Parallel Studio XE.
Training and support from Colfax.
Order your platform today. http://sdm.link/xeonphi
_______________________________________________
Gambas-user mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gambas-user
Reply | Threaded
Open this post in threaded view
|

[Gambas Bug Tracker] Bug #1059: Compilation fails with Qt 5.7

bugtracker
In reply to this post by bugtracker
http://gambaswiki.org/bugtracker/edit?object=BUG.1059&from=L21haW4-

Comment #11 by Benoît MINISINI:

It should be fixed in revision #8061.

Benoît MINISINI changed the state of the bug to: Fixed.



------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
_______________________________________________
Gambas-user mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gambas-user