Skip to content
This repository has been archived by the owner on Aug 8, 2023. It is now read-only.

Bitrise Qt5 build bot is failing #6794

Closed
brunoabinader opened this issue Oct 22, 2016 · 11 comments · Fixed by #6804
Closed

Bitrise Qt5 build bot is failing #6794

brunoabinader opened this issue Oct 22, 2016 · 11 comments · Fixed by #6804
Labels
build Qt Mapbox Maps SDK for Qt, aka Qt Location Mapbox GL

Comments

@brunoabinader
Copy link
Member

This is probably caused by a wrong selection of the clang compiler version:

These errors started to pop up on Bitrise and also on my macOS:

In file included from ../../../include/mbgl/util/constants.hpp:3:
../../../include/mbgl/util/chrono.hpp:36:49: error: no template named 'enable_if_t' in namespace 'std'; did you mean 'enable_if'?
template <class Rep, class Period, class = std::enable_if_t<
../../../include/mbgl/util/optional.hpp:8:37: error: no type named 'optional' in namespace 'std::experimental'
using optional = std::experimental::optional<T>;
                 ~~~~~~~~~~~~~~~~~~~^

I'm going to disable Qt5 build bot until we find a fix for this.

/cc @tmpsantos @kkaefer

@brunoabinader brunoabinader added build Qt Mapbox Maps SDK for Qt, aka Qt Location Mapbox GL labels Oct 22, 2016
@assanegu
Copy link

Good evening,

I am getting this error when i try to run "make qt-lib".
I am using a MacOS Sierra; and Qt5.7 professional.
Do you have any workaround or solution to this?
thank you for your time.

@brunoabinader
Copy link
Member Author

Once #6804 gets merged, we can re-enable the Bitrise Qt5 build bot.

@assanegu - yes, see 2d908c8.

@brunoabinader
Copy link
Member Author

#6804 is now merged, I'm going to re-enable our Bitrise Qt5 bot 👍

@brunoabinader
Copy link
Member Author

Bitrise Qt5 macOS build bot is now back on track 💯

@assanegu
Copy link

Thank you for the update.
The error is no longer happening; but I am still getting a different error that might not related to Mapbox.

FYI, here is the error:
/Users/systemName/Qt/5.7/ios/include/QtGui/qopengl.h:69:13: fatal error: 'OpenGLES/ES3/gl.h' file not found

@brunoabinader
Copy link
Member Author

@assanegu this looks like something is missing on your environment setup - can you please provide details e.g. what operating system and build commands are you using to build?

@assanegu
Copy link

Hi Bruno,
Thank you for your prompt reply. I am using a MacOS Sierra; and Qt5.7 professional.
As for the issue, I think I resolved the issue. The Qt5Core_DIR was pointing to iOS directory not to the clang_64 directory. meaning:
Qt5Core_DIR = /Users/myMac/Qt/5.7/ios/lib/cmake/Qt5Core
so I change it to:
Qt5Core_DIR =/Users/myMac/Qt/5.7/clang_64/lib/cmake/Qt5Core
and I was able to build it using "make qt-lib".
However, I did get the following warnings at the end of the build:
----beginning of the warning -----------
3 warnings generated.
[206/214] Linking CXX static library libmbgl-core.a
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ranlib: file: libmbgl-core.a(circle_vertex.cpp.o) has no symbols
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ranlib: file: libmbgl-core.a(collision_box_vertex.cpp.o) has no symbols
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ranlib: file: libmbgl-core.a(fill_vertex.cpp.o) has no symbols
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ranlib: file: libmbgl-core.a(line_vertex.cpp.o) has no symbols
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ranlib: file: libmbgl-core.a(raster_vertex.cpp.o) has no symbols
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ranlib: file: libmbgl-core.a(symbol_vertex.cpp.o) has no symbols
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ranlib: file: libmbgl-core.a(circle_vertex.cpp.o) has no symbols
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ranlib: file: libmbgl-core.a(collision_box_vertex.cpp.o) has no symbols
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ranlib: file: libmbgl-core.a(fill_vertex.cpp.o) has no symbols
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ranlib: file: libmbgl-core.a(line_vertex.cpp.o) has no symbols
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ranlib: file: libmbgl-core.a(raster_vertex.cpp.o) has no symbols
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ranlib: file: libmbgl-core.a(symbol_vertex.cpp.o) has no symbols
[214/214] Linking CXX shared library libqmapboxgl.dylib
clang: warning: argument unused during compilation: '-pthread'

----end of the warning -----------

Also after building the library, and running make run-qt-app; i got the error:
myMac-MBP:mapbox-gl-native assanegueye$ make run-qt-app
platform/macos/ninja -j4 -C build/qt-macos-x86_64/Debug mbgl-qt
ninja: Entering directory `build/qt-macos-x86_64/Debug'
[3/9] Generating CMakeFiles/mbgl-qt.dir/qrc_common.cpp
Generating moc_mapwindow.cpp
[9/9] Linking CXX executable mbgl-qt
build/qt-macos-x86_64/Debug/mbgl-qt
[ERROR] {}[Setup]: loading style failed: HTTP status code 401

@jfirebaugh
Copy link
Contributor

You need to provide an environment variable with your Mapbox access token as described in the README.

@assanegu
Copy link

You are right, I did not set the MAPBOX_ACCESS_TOKEN. now it's working. Thank you for your assistance.

@ghost
Copy link

ghost commented Feb 7, 2018

Hello !

Can you explain me How you set access_token ?

Is it in .pro or directly in the QML ?

Thx

@brunoabinader
Copy link
Member Author

Hi @ducmaxime, this repository only contains the C++ API (QMapboxGL), whereas the QML one is hosted in QtLocation repository.

You can find documentation about the Mapbox GL QtLocation plugin here: https://doc.qt.io/qt-5.10/location-plugin-mapboxgl.html#parameters

See below an example on how to provide access token information in QML:

    Map {
        plugin: Plugin {
            name: "mapboxgl"
            PluginParameter {
                name: "mapboxgl.access_token"
                value: <access token goes here>
            }
        }
    }

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
build Qt Mapbox Maps SDK for Qt, aka Qt Location Mapbox GL
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants