Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Install with Qt 5.12.1: Cannot convert QJsonArray::iterator #40

Open
AntonioFasano opened this issue Feb 28, 2019 · 6 comments
Open

Install with Qt 5.12.1: Cannot convert QJsonArray::iterator #40

AntonioFasano opened this issue Feb 28, 2019 · 6 comments

Comments

@AntonioFasano
Copy link

In Arch Linux Qt 5.12.1, setup fails with the following error

> install_github("ggobi/qtbase")
...

[ 52%] Building CXX object kdebindings/smoke/qt/CMakeFiles/smokeqt.dir/x_8.cpp.o
/tmp/RtmpxVOX0Z/R.INSTALL10026c8251da/qtbase/src-build/kdebindings/smoke/qt/x_8.cpp: In member function ‘void __smokeqt::x_QJsonArray::x_25(Smoke::Stack)’:
/tmp/RtmpxVOX0Z/R.INSTALL10026c8251da/qtbase/src-build/kdebindings/smoke/qt/x_8.cpp:4940:53: error: cannot convert ‘QJsonArray::iterator’ to ‘const QChar*’ in initialization
         const QChar* xret = this->QJsonArray::begin();
...

Thanks for any support.

@lawremi
Copy link
Member

lawremi commented Mar 1, 2019

Thanks. It will take a while to update support to 5.12. Every release they find new ways to confuse our compiler. I think in this case we need to ignore typedefs within classes.

@AntonioFasano
Copy link
Author

Thank you. Please, which is the last supported Qt version.

As I understand, it is quite unlikely to install the package with rolling distros. One possibility could be to download and build from source:

https://download.qt.io/archive/qt/5.12/5.12.1/submodules/qtbase-everywhere-src-5.12.1.tar.xz

where 5.12.1 is replaced with the last supported version.

Then:

export QTDIR="/path/to/new/qt/"
export PATH="${QTDIR}/bin:${PATH}"
export LD_LIBRARY_PATH="${QTDIR}/lib"
export CMAKE_PREFIX_PATH="${QTDIR}"
export PKG_CONFIG_PATH="${QTDIR}/lib/pkgconfig"
R
install_github("ggobi/qtbase")

What do you think?

@lawremi
Copy link
Member

lawremi commented Mar 2, 2019

Something like that should work. Not sure how cmake finds Qt5, but it should be documented. I pushed some changes yesterday that get us pretty close, but there are a couple more issues.

@leovan
Copy link

leovan commented Mar 11, 2019

I got some other errors on macOS when compiling against R 3.5.2 and Qt 5.12.1, really hope it can support the latest Qt 5.12.* soon.

Generating SMOKE sources...
preparing SMOKE data [qt]
writing out smokedata.cpp [qt]
writing out x_*.cpp [qt]
Done.
[ 45%] Automatic MOC for target smokeqt
[ 45%] Built target smokeqt_autogen
Scanning dependencies of target smokeqt
[ 46%] Building CXX object kdebindings/smoke/qt/CMakeFiles/smokeqt.dir/smokedata.cpp.o
/private/var/folders/w0/tsvfs60x117d_vcxs0jhhsv00000gn/T/Rtmp9hb2Rs/R.INSTALL130de2433b2eb/qtbase/src-build/kdebindings/smoke/qt/smokedata.cpp:10362:35: error: 
      use of undeclared identifier 'RegisterType'; did you mean 'QMetaType::registerType'?
        case 1390: return (void*)(RegisterType*)xptr;
                                  ^~~~~~~~~~~~
                                  QMetaType::registerType
/usr/local/opt/qt/lib/QtCore.framework/Headers/qmetatype.h:511:16: note: 'QMetaType::registerType' declared here
    static int registerType(const char *typeName, Deleter deleter,
               ^
/private/var/folders/w0/tsvfs60x117d_vcxs0jhhsv00000gn/T/Rtmp9hb2Rs/R.INSTALL130de2433b2eb/qtbase/src-build/kdebindings/smoke/qt/smokedata.cpp:10362:48: error: 
      expected expression
        case 1390: return (void*)(RegisterType*)xptr;
                                               ^

@ryellow
Copy link

ryellow commented Apr 8, 2020

@leovan I've got exactly the same error. Qt 5.12.8 and R 3.6.3
@lawremi I hope you can support soon the latest Qt 5.12*

@ryellow
Copy link

ryellow commented Apr 17, 2020

@AntonioFasano : On MacOS, R3.6.3, I am able to compile and install qtbase with Qt 5.9.9. It seems work as expected. With Qt 5.12.8 the compilation fails. I Hope this help you

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants