LeFroid / Viper-Browser

A lightweight Qt5 web browser using QtWebEngine
GNU General Public License v3.0
215 stars 21 forks source link

cant compile in FreeBSD 14-CURRENT regardless if i use clang or gcc #22

Closed justfly1111 closed 2 years ago

justfly1111 commented 3 years ago

See bellow low for compilation failure in brief

145 template<> class codecvt<char32_t, char, mbstate_t>; ^ In file included from /usr/local/lib/gcc10/include/c++/string:55, from /usr/local/lib/gcc10/include/c++/stdexcept:39, from /usr/local/lib/gcc10/include/c++/system_error:41, from /usr/local/lib/gcc10/include/c++/mutex:42, from /home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/core/database/sqlite/internal/implementation.h:4, from /home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/core/database/sqlite/internal/implementation.cpp:2: /usr/local/lib/gcc10/include/c++/bits/basic_string.h: In function 'int std::__cxx11::stoi(const wstring&, std::size_t*, int)': /usr/local/lib/gcc10/include/c++/bits/basic_string.h:6678:47: error: 'wcstol' is not a member of 'std' 6678 { return __gnu_cxx::stoa<long, int>(&std::wcstol, "stoi", str.c_str(), ^~ /usr/local/lib/gcc10/include/c++/bits/basic_string.h: In function 'long int std::__cxx11::stol(const wstring&, std::size_t*, int)': /usr/local/lib/gcc10/include/c++/bits/basic_string.h:6683:36: error: 'wcstol' is not a member of 'std' 6683 { return __gnu_cxx::stoa(&std::wcstol, "stol", str.c_str(), ^~ /usr/local/lib/gcc10/include/c++/bits/basic_string.h: In function 'long unsigned int std::__cxx11::stoul(const wstring&, std::size_t*, int)': /usr/local/lib/gcc10/include/c++/bits/basic_string.h:6688:36: error: 'wcstoul' is not a member of 'std' 6688 { return __gnu_cxx::stoa(&std::wcstoul, "stoul", str.c_str(), ^~~ /usr/local/lib/gcc10/include/c++/bits/basic_string.h: In function 'float std::__cxx11::stof(const wstring&, std::size_t*)': /usr/local/lib/gcc10/include/c++/bits/basic_string.h:6704:36: error: 'wcstof' is not a member of 'std' 6704 { return gnu_cxx::stoa(&std::wcstof, "stof", str.c_str(), idx); } ^~ /usr/local/lib/gcc10/include/c++/bits/basic_string.h: In function 'double std::__cxx11::stod(const wstring&, std::size_t*)': /usr/local/lib/gcc10/include/c++/bits/basic_string.h:6708:36: error: 'wcstod' is not a member of 'std' 6708 { return gnu_cxx::stoa(&std::wcstod, "stod", str.c_str(), idx); } ^~ /usr/local/lib/gcc10/include/c++/bits/basic_string.h: In function 'std::wstring std::__cxx11::to_wstring(int)': /usr/local/lib/gcc10/include/c++/bits/basic_string.h:6718:51: error: 'vswprint ' is not a member of 'std'; did you mean 'isprint'? 6718 { return __gnu_cxx::__to_xstring(&std::vswprintf, 4 * sizeof(int), ^~~~~ isprint /usr/local/lib/gcc10/include/c++/bits/basic_string.h: In function 'std::wstring std::__cxx11::to_wstring(unsigned int)': /usr/local/lib/gcc10/include/c++/bits/basic_string.h:6723:51: error: 'vswprint ' is not a member of 'std'; did you mean 'isprint'? 6723 { return __gnu_cxx::__to_xstring(&std::vswprintf, ^~~~~ isprint /usr/local/lib/gcc10/include/c++/bits/basic_string.h: In function 'std::wstring std::__cxx11::to_wstring(long int)': /usr/local/lib/gcc10/include/c++/bits/basic_string.h:6729:51: error: 'vswprint ' is not a member of 'std'; did you mean 'isprint'? 6729 { return __gnu_cxx::__to_xstring(&std::vswprintf, 4 * sizeof(long), ^~~~~ isprint /usr/local/lib/gcc10/include/c++/bits/basic_string.h: In function 'std::wstring std::__cxx11::to_wstring(long unsigned int)': /usr/local/lib/gcc10/include/c++/bits/basic_string.h:6734:51: error: 'vswprint ' is not a member of 'std'; did you mean 'isprint'? 6734 { return __gnu_cxx::__to_xstring(&std::vswprintf, ^~~~~ isprint /usr/local/lib/gcc10/include/c++/bits/basic_string.h: In function 'std::wstring std::__cxx11::to_wstring(long long int)': /usr/local/lib/gcc10/include/c++/bits/basic_string.h:6740:51: error: 'vswprint ' is not a member of 'std'; did you mean 'isprint'? 6740 { return __gnu_cxx::__to_xstring(&std::vswprintf, ^~~~~ isprint /usr/local/lib/gcc10/include/c++/bits/basic_string.h: In function 'std::wstring std::__cxx11::to_wstring(long long unsigned int)': /usr/local/lib/gcc10/include/c++/bits/basic_string.h:6746:51: error: 'vswprint ' is not a member of 'std'; did you mean 'isprint'? 6746 { return __gnu_cxx::__to_xstring(&std::vswprintf, ^~~~~ isprint /usr/local/lib/gcc10/include/c++/bits/basic_string.h: In function 'std::wstring std::__cxx11::to_wstring(float)': /usr/local/lib/gcc10/include/c++/bits/basic_string.h:6755:51: error: 'vswprint ' is not a member of 'std'; did you mean 'isprint'? 6755 return gnu_cxx::__to_xstring(&std::vswprintf, n, ^~~~~ isprint /usr/local/lib/gcc10/include/c++/bits/basic_string.h: In function 'std::wstring std::__cxx11::to_wstring(double)': /usr/local/lib/gcc10/include/c++/bits/basic_string.h:6764:51: error: 'vswprint ' is not a member of 'std'; did you mean 'isprint'? 6764 return gnu_cxx::__to_xstring(&std::vswprintf, n, ^~~~~ isprint /usr/local/lib/gcc10/include/c++/bits/basic_string.h: In function 'std::wstring std::__cxx11::to_wstring(long double)': /usr/local/lib/gcc10/include/c++/bits/basic_string.h:6773:51: error: 'vswprint ' is not a member of 'std'; did you mean 'isprint'? 6773 return gnu_cxx::__to_xstring(&std::vswprintf, n, ^~~~~ isprint In file included from /home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/core/database/sqlite/internal/implementation.cpp:6: /usr/local/lib/gcc10/include/c++/thread: In function 'std::thread::id std::this_thread::get_id()': /usr/local/lib/gcc10/include/c++/thread:373:20: error: invalid conversion from 'int' to 'std::thread::native_handle_type' {aka 'pthread*'} [-fpermissive] 373 return thread::id(1); ^
int

/usr/local/lib/gcc10/include/c++/thread:96:29: note: initializing argument 1 of 'std::thread::id::id(std::thread::native

LeFroid commented 3 years ago

Can you share the compiler flags being used? For example, relative to my build directory, I can find the flags in this file src/core/CMakeFiles/viper-core.dir/flags.make

CXX_FLAGS =  -Wall -Wextra -msse2 -msse3 -msse4 -O2 -g -DNDEBUG -fPIC -std=gnu++17
justfly1111 commented 3 years ago

So like i said it doesnt make a difference whether i uae clang or gpp but bellow is the compiler flags for both clang/clang++compilation fail flags: doeboy1111@danornz ~/git/wayland-desktop-apps/Viper-Browser/build $ cat src/core/CMakeFiles/viper-core.dir/flags.make

CMAKE generated file: DO NOT EDIT!

Generated by "Unix Makefiles" Generator, CMake Version 3.20

compile CXX with /usr/bin/c++

CXX_DEFINES = -DQT_CONCURRENT_LIB -DQT_CORE_LIB -DQT_GUI_LIB -DQT_NETWORK_LIB -DQT_NO_DEBUG -DQT_POSITIONING_LIB -DQT_PRINTSUPPORT_LIB -DQT_QMLMODELS_LIB -DQT_QML_LIB -DQT_QUICKWIDGETS_LIB -DQT_QUICK_LIB -DQT_SVG_LIB -DQT_WEBCHANNEL_LIB -DQT_WEBENGINECORE_LIB -DQT_WEBENGINEWIDGETS_LIB -DQT_WIDGETS_LIB -DUSE_KWALLET

CXX_INCLUDES = -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/build/src/core -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/core -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/build/src/core/viper-core_autogen/include -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/app -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/core/adblock -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/core/app -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/core/autofill -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/core/bookmarks -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/core/cache -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/core/cookies -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/core/credentials -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/core/database -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/core/database/sqlite -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/core/downloads -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/core/extensions -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/core/highlighters -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/core/history -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/core/icons -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/core/ipc -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/core/network -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/core/search -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/core/session -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/core/settings -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/core/text_finder -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/core/threading -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/core/url_suggestion -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/core/user_agents -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/core/user_scripts -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/core/utility -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/core/web -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/ui/adblock -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/ui/autofill -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/ui/bookmarks -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/ui/cookies -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/ui/downloads -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/ui/history -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/ui/network -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/ui/preferences -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/ui/url_suggestion -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/ui/user_agents -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/ui/user_scripts -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/ui/web -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/ui/widgets -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/ui/window -isystem /usr/local/include -isystem /usr/local/include/qt5 -isystem /usr/local/include/qt5/QtCore -isystem /usr/local/lib/qt5/mkspecs/freebsd-clang -isystem /usr/local/include/qt5/QtConcurrent -isystem /usr/local/include/qt5/QtGui -isystem /usr/local/include/qt5/QtNetwork -isystem /usr/local/include/qt5/QtPrintSupport -isystem /usr/local/include/qt5/QtWidgets -isystem /usr/local/include/qt5/QtSvg -isystem /usr/local/include/qt5/QtQuickWidgets -isystem /usr/local/include/qt5/QtQuick -isystem /usr/local/include/qt5/QtQmlModels -isystem /usr/local/include/qt5/QtQml -isystem /usr/local/include/qt5/QtWebChannel -isystem /usr/local/include/qt5/QtWebEngineCore -isystem /usr/local/include/qt5/QtPositioning -isystem /usr/local/include/qt5/QtWebEngineWidgets

CXX_FLAGS = -Wall -Wextra -msse2 -msse3 -msse4 -O3 -fPIC -std=gnu++17

doeboy1111@danornz ~/gi

GCC/GNU/G++ compilation failed flags doeboy1111@danornz ~/git/wayland-desktop-apps/Viper-Browser/build $ cat src/core/CMakeFiles/viper-core.dir/flags.make

CMAKE generated file: DO NOT EDIT!

Generated by "Unix Makefiles" Generator, CMake Version 3.20

compile CXX with /usr/local/bin/g++

CXX_DEFINES = -DQT_CONCURRENT_LIB -DQT_CORE_LIB -DQT_GUI_LIB -DQT_NETWORK_LIB -DQT_NO_DEBUG -DQT_POSITIONING_LIB -DQT_PRINTSUPPORT_LIB -DQT_QMLMODELS_LIB -DQT_QML_LIB -DQT_QUICKWIDGETS_LIB -DQT_QUICK_LIB -DQT_SVG_LIB -DQT_WEBCHANNEL_LIB -DQT_WEBENGINECORE_LIB -DQT_WEBENGINEWIDGETS_LIB -DQT_WIDGETS_LIB -DUSE_KWALLET

CXX_INCLUDES = -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/build/src/core -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/core -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/build/src/core/viper-core_autogen/include -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/app -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/core/adblock -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/core/app -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/core/autofill -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/core/bookmarks -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/core/cache -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/core/cookies -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/core/credentials -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/core/database -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/core/database/sqlite -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/core/downloads -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/core/extensions -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/core/highlighters -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/core/history -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/core/icons -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/core/ipc -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/core/network -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/core/search -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/core/session -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/core/settings -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/core/text_finder -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/core/threading -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/core/url_suggestion -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/core/user_agents -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/core/user_scripts -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/core/utility -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/core/web -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/ui/adblock -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/ui/autofill -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/ui/bookmarks -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/ui/cookies -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/ui/downloads -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/ui/history -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/ui/network -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/ui/preferences -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/ui/url_suggestion -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/ui/user_agents -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/ui/user_scripts -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/ui/web -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/ui/widgets -I/home/doeboy1111/git/wayland-desktop-apps/Viper-Browser/src/ui/window -isystem /usr/local/include/qt5 -isystem /usr/local/include/qt5/QtCore -isystem /usr/local/lib/qt5/mkspecs/freebsd-clang -isystem /usr/local/include/qt5/QtConcurrent -isystem /usr/local/include/qt5/QtGui -isystem /usr/local/include/qt5/QtNetwork -isystem /usr/local/include/qt5/QtPrintSupport -isystem /usr/local/include/qt5/QtWidgets -isystem /usr/local/include/qt5/QtSvg -isystem /usr/local/include/qt5/QtQuickWidgets -isystem /usr/local/include/qt5/QtQuick -isystem /usr/local/include/qt5/QtQmlModels -isystem /usr/local/include/qt5/QtQml -isystem /usr/local/include/qt5/QtWebChannel -isystem /usr/local/include/qt5/QtWebEngineCore -isystem /usr/local/include/qt5/QtPositioning -isystem /usr/local/include/qt5/QtWebEngineWidgets

CXX_FLAGS = -Wall -Wextra -msse2 -msse3 -msse4 -O3 -fPIC -std=gnu++17

LeFroid commented 3 years ago

I'm thinking the -Wall -Wextra flags might be at fault. As far as I can tell, these errors are only triggered by the #include to standard C++ library headers. Please pull the latest commit and try to build from a fresh build directory. If there are still compilation errors, please share the entire build logs for further review.

probonopd commented 2 years ago

I am able to compile it on FreeBSD 12.2 helloSystem, but when I try to launch it I get a crash. Will open a new ticket.

LeFroid commented 2 years ago

Closing due to inactivity