Closed samarthjain96 closed 1 year ago
Hi!
Reading this log, it seems to me, it is not compiled with the C++20 feature set.
I did not test for GCC and am not particularly familiar with it. For cross-platform checks, I use Clang, which usually ensures language conformity. Are you sure it is compiled with C++20 support and that your GCC version supports the following features?
Hi, I tried with g++/gcc 11 and C++ 20. This is my CMakeList.
cmake_minimum_required(VERSION 3.10)
project(
ModernCMakeExample LANGUAGES CXX VERSION 0.1)
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++20")
#set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=gnu++2a")
include_directories(/home/jainsamarth/tbb/include)
add_executable(MyExample test.cpp)
target_link_libraries(MyExample PRIVATE ~/tbb/build/linux_intel64_gcc_cc11.1.0_libc2.27_kernel5.8.0_release/libtbb.so octree.h octree_container.h)
The log is
/home/jainsamarth/Downloads/Octree/octree.h:887:81: error: there are no arguments to ‘log2’ that depend on a template parameter, so a declaration of ‘log2’ must be available [-fpermissive]
887 | autoc nDepthEstimated = std::min(nDepthMax, static_cast<depth_type>(ceil((log2(nElementInNodeAvg) + 1) / static_cast<float>(nDimension))));
I haven't tested with clang yet.
Hi, After trying to compile with GCC 11.3, I resolved a few ussies, but - if I understand well - the currently used library does not support the execution policies with std::span, maybe TBB would do. Could you do another try? Thx!
I solved the GCC compilation and added a mini CMake project to the repo in the GCC folder.
Hi, I am not able to install and use the repository in ubuntu 18. Can you lay down the steps how I can use it and what other dependencies and libraries I need to install for the same. One of the error I am getting while compiling is shown below.
Thanks