codecov / feedback

A place to discuss feedback about the pull request and web product experience.
35 stars 6 forks source link

Setting up codecov with cmake-multi-platform #209

Closed WehrWolff closed 9 months ago

WehrWolff commented 9 months ago

Im using the following configuration to test my C/C++ project on multiple platforms and with multiple compilers (the Test section is the important one here), I'm not going in to much detail here since I think its pretty self explanatory just so much: Previously I was just using ctest --build-config ${{ matrix.build_type }} --output-on-failure for testing (since that did not work I changed it to the below)

# This starter workflow is for a CMake project running on multiple platforms. There is a different starter workflow if you just want a single platform.
# See: https://github.com/actions/starter-workflows/blob/main/ci/cmake-single-platform.yml
name: CMake on multiple platforms

on:
  push:
    branches: [ "action-config" ]
  pull_request:
    branches: [ "action-config" ]

jobs:
  build:
    runs-on: ${{ matrix.os }}

    strategy:
      # Set fail-fast to false to ensure that feedback is delivered for all matrix combinations. Consider changing this to true when your workflow is stable.
      fail-fast: false

      # Set up a matrix to run the following 3 configurations:
      # 1. <Windows, Release, latest MSVC compiler toolchain on the default runner image, default generator>
      # 2. <Linux, Release, latest GCC compiler toolchain on the default runner image, default generator>
      # 3. <Linux, Release, latest Clang compiler toolchain on the default runner image, default generator>
      #
      # To add more build types (Release, Debug, RelWithDebInfo, etc.) customize the build_type list.
      matrix:
        os: [ubuntu-latest, windows-latest]
        build_type: [Release]
        c_compiler: [gcc, clang, cl]
        include:
          - os: windows-latest
            c_compiler: cl
            cpp_compiler: cl
            conan_compiler: msvc
            compiler_version: 193
            conan_toolchain_path: build/build/generators/conan_toolchain.cmake
          - os: ubuntu-latest
            c_compiler: gcc
            cpp_compiler: g++
            conan_compiler: gcc
            compiler_version: 11
            libcxx: --settings=compiler.libcxx=libstdc++11
            conan_toolchain_path: build/build/Release/generators/conan_toolchain.cmake
          - os: ubuntu-latest
            c_compiler: clang
            cpp_compiler: clang++
            conan_compiler: clang
            compiler_version: 15
            libcxx: --settings=compiler.libcxx=libstdc++11
            conan_toolchain_path: build/build/Release/generators/conan_toolchain.cmake
#/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)" && (echo; echo 'eval "$(/home/linuxbrew/.linuxbrew/bin/brew shellenv)"') >> /home/runner/.bashrc && eval "$(/home/linuxbrew/.linuxbrew/bin/brew shellenv)" && brew install libcxx
        exclude:
          - os: windows-latest
            c_compiler: gcc
          - os: windows-latest
            c_compiler: clang
          - os: ubuntu-latest
            c_compiler: cl

    steps:
    - uses: actions/checkout@v3

    - name: Set reusable strings
      # Turn repeated input strings (such as the build output directory) into step outputs. These step outputs can be used throughout the workflow file.
      id: strings
      shell: bash
      run: |
        echo "build-output-dir=${{ github.workspace }}/build" >> "$GITHUB_OUTPUT"

    - name: Manage Packages with Conan          
      run: |
        pip install conan
        conan profile detect || true
        conan install . --output-folder=./build --build=missing --settings=compiler.cppstd=20 --settings=build_type=${{ matrix.build_type }} --settings=compiler=${{ matrix.conan_compiler }} --settings=compiler.version=${{ matrix.compiler_version }} ${{ matrix.libcxx }}

    - name: Configure CMake
      # Configure CMake in a 'build' subdirectory. `CMAKE_BUILD_TYPE` is only required if you are using a single-configuration generator such as make.
      # See https://cmake.org/cmake/help/latest/variable/CMAKE_BUILD_TYPE.html?highlight=cmake_build_type
      run: >
        cmake -B ${{ steps.strings.outputs.build-output-dir }}
        -DCMAKE_POLICY_DEFAULT_CMP0091=NEW
        -DCMAKE_CXX_COMPILER=${{ matrix.cpp_compiler }}
        -DCMAKE_C_COMPILER=${{ matrix.c_compiler }}
        -DCMAKE_BUILD_TYPE=${{ matrix.build_type }}
        -DCMAKE_TOOLCHAIN_FILE=${{ github.workspace }}/${{ matrix.conan_toolchain_path }}
        -DCODE_COVERAGE=ON
        -S ${{ github.workspace }}
      #-G "Unix Makefiles"

    - name: Build
      # Build your program with the given configuration. Note that --config is needed because the default Windows generator is a multi-config generator (Visual Studio generator).
      run: |
        sudo apt-get install lcov
        cmake --build ${{ steps.strings.outputs.build-output-dir }} --config ${{ matrix.build_type }}

    - name: Test
      working-directory: ${{ steps.strings.outputs.build-output-dir }}
      # Execute tests defined by the CMake configuration. Note that --build-config is needed because the default Windows generator is a multi-config generator (Visual Studio generator).
      # See https://cmake.org/cmake/help/latest/manual/ctest.1.html for more detail

      #ctest --build-config ${{ matrix.build_type }} --output-on-failure -fprofile-arcs -ftest-coverage
      run: |
        ctest --build-config ${{ matrix.build_type }} --output-on-failure CTEST_CUSTOM_PRE_TEST="CC='gcc -fprofile-arcs -ftest-coverage' CXX='g++ -fprofile-arcs -ftest-coverage'"
        cmake --build . --target coverage

    - name: Upload coverage reports to Codecov
      uses: codecov/codecov-action@v3
      env:
        CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}

My CMakeLists.txt is looking like this:

cmake_minimum_required(VERSION 3.12)
project(babel)

set(CMAKE_CXX_STANDARD 20)
set(CMAKE_CXX_STANDARD_REQUIRED ON)
set(CMAKE_EXPORT_COMPILE_COMMANDS ON)

set(SOURCE_FILES
    src/shell.cpp
)

find_package(Boost 1.83.0 REQUIRED COMPONENTS algorithm)

add_executable(babel ${SOURCE_FILES})
target_include_directories(babel PRIVATE src)
target_link_libraries(babel PRIVATE ${Boost_LIBRARIES})

# ----- Testing Configuration -----

set(TEST_FILES
    tests/test_shell.cpp
)

include_directories(src test)
find_package(GTest REQUIRED)

add_executable(babel_tests ${TEST_FILES})
target_include_directories(babel_tests PRIVATE ${GTEST_INCLUDE_DIRS})
target_link_libraries(babel_tests PRIVATE GTest::GTest GTest::Main)
target_link_libraries(babel_tests PRIVATE ${Boost_LIBRARIES})

if(CMAKE_COMPILER_IS_GNUCXX OR CMAKE_CXX_COMPILER_ID STREQUAL "Clang")
    add_compile_options(-fprofile-arcs -ftest-coverage)
    add_link_options(-lgcov)
endif()

enable_testing()
add_test(NAME BabelTests COMMAND babel_tests)

add_custom_target(coverage
    COMMAND ${CMAKE_COMMAND} -E remove coverage.info
    COMMAND lcov --capture --directory . --output-file coverage.info
    COMMAND lcov --remove coverage.info '/usr/*' --output-file coverage.info
    COMMAND lcov --list coverage.info
    WORKING_DIRECTORY ${CMAKE_BINARY_DIR}
    DEPENDS babel_tests
    COMMENT "Generating coverage information..."
)

Thanks in advance for looking into this.

drazisil-codecov commented 9 months ago

Hi @WehrWolff

What have you tried and what errors are you getting?

WehrWolff commented 9 months ago

Oh wow totally forgot to say that. I'm smart. Anyway I changed both files a bit since last time, the yaml has the following change (matrix.cmd is an installation command for lcov, only on ubuntu):

- name: Test
      working-directory: ${{ steps.strings.outputs.build-output-dir }}

      run: |
        ${{ matrix.cmd }}
        pip install codecov
        ctest --build-config ${{ matrix.build_type }} --output-on-failure CTEST_CUSTOM_PRE_TEST="CC='gcc -fprofile-arcs -ftest-coverage' CXX='g++ -fprofile-arcs -ftest-coverage'"

The CMakeLists.txt now looks like this:

cmake_minimum_required(VERSION 3.12)
project(babel)

set(CMAKE_CXX_STANDARD 20)
set(CMAKE_CXX_STANDARD_REQUIRED ON)
set(CMAKE_EXPORT_COMPILE_COMMANDS ON)

set(SOURCE_FILES
    src/shell.cpp
)

find_package(Boost 1.83.0 REQUIRED COMPONENTS algorithm)

add_executable(babel ${SOURCE_FILES})
target_include_directories(babel PRIVATE src)
target_link_libraries(babel PRIVATE ${Boost_LIBRARIES})

# ----- Testing Configuration -----

set(TEST_FILES
    tests/test_shell.cpp
)

include_directories(src test)
find_package(GTest REQUIRED)

add_executable(babel_tests ${TEST_FILES})
target_include_directories(babel_tests PRIVATE ${GTEST_INCLUDE_DIRS})
target_link_libraries(babel_tests PRIVATE GTest::GTest GTest::Main)
target_link_libraries(babel_tests PRIVATE ${Boost_LIBRARIES})

if (CMAKE_COMPILER_IS_GNUCXX OR CMAKE_CXX_COMPILER_ID MATCHES "Clang")
    set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fprofile-arcs -ftest-coverage")
    set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fprofile-arcs -ftest-coverage")
    set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -fprofile-arcs -ftest-coverage")
endif()

enable_testing()
add_test(NAME BabelTests COMMAND babel_tests)

if (CMAKE_BUILD_TYPE STREQUAL "Release")
    if (CMAKE_CXX_COMPILER_ID MATCHES "GNU" OR CMAKE_CXX_COMPILER_ID MATCHES "Clang")
        target_compile_options(babel PRIVATE -fprofile-arcs -ftest-coverage)
        target_link_options(babel PRIVATE --coverage)

        add_custom_target(coverage
            COMMAND ${CMAKE_CTEST_COMMAND} --output-on-failure
            COMMAND lcov --directory . --capture --output-file coverage.info
            COMMAND lcov --remove coverage.info '/usr/*' --output-file coverage.info
            COMMAND lcov --list coverage.info
        )
        elseif (CMAKE_CXX_COMPILER_ID MATCHES "MSVC")
        target_compile_options(babel PRIVATE /MDd /Zi /Z7)
        target_link_options(babel PRIVATE /DEBUG /OPT:REF /OPT:ICF /INCREMENTAL:NO)

        add_custom_target(coverage
            COMMAND ${CMAKE_CTEST_COMMAND} --output-on-failure
            COMMAND codecov -f coverage.xml
        )
    endif()
endif()

My setup works fine with gcc on ubuntu, however there are errors with clang on ubuntu and on windows. On windows the tests work and are uploaded to codecov but on the website it says that the reports are unusable, here is log for the uploading step:

Run codecov/codecov-action@v3
  with:
  env:
    CODECOV_TOKEN: ***
==> windows OS detected
https://uploader.codecov.io/latest/windows/codecov.exe.SHA[2](https://github.com/WehrWolff/babel/actions/runs/7379793685/job/20076678421#step:8:2)56SUM
==> SHASUM file signed by key id 806bb28aed779869
==> Uploader SHASUM verified (a44[3](https://github.com/WehrWolff/babel/actions/runs/7379793685/job/20076678421#step:8:3)ec6[4](https://github.com/WehrWolff/babel/actions/runs/7379793685/job/20076678421#step:8:4)c6c44e3b4fe6244418ef63[5](https://github.com/WehrWolff/babel/actions/runs/7379793685/job/20076678421#step:8:6)abe044db490abbd1[6](https://github.com/WehrWolff/babel/actions/runs/7379793685/job/20076678421#step:8:7)1d[7](https://github.com/WehrWolff/babel/actions/runs/7379793685/job/20076678421#step:8:8)f2[8](https://github.com/WehrWolff/babel/actions/runs/7379793685/job/20076678421#step:8:9)72cdd4c447  codecov.exe)
==> Running version latest
==> Running version v0.7.1
D:\a\_actions\codecov\codecov-action\v3\dist\codecov.exe -n "" -Q github-action-3.1.4
[2024-01-01T20:57:41.4[9](https://github.com/WehrWolff/babel/actions/runs/7379793685/job/20076678421#step:8:10)5Z] ['info'] 
     _____          _
    / ____|        | |
   | |     ___   __| | ___  ___ _____   __
   | |    / _ \ / _` |/ _ \/ __/ _ \ \ / /
   | |___| (_) | (_| |  __/ (_| (_) \ V /
    \_____\___/ \__,_|\___|\___\___/ \_/

  Codecov report uploader 0.7.1
[2024-01-01T20:57:41.550Z] ['info'] => Project root located at: D:/a/babel/babel
[2024-01-01T20:57:41.551Z] ['info'] ->  Token found by environment variables
[2024-01-01T20:57:41.771Z] ['info'] Searching for coverage files...
[2024-01-01T20:57:41.829Z] ['info'] Warning: Some files located via search were excluded from upload.
[2024-01-01T20:57:41.829Z] ['info'] If Codecov did not locate your files, please review https://docs.codecov.com/docs/supported-report-formats
[2024-01-01T20:57:41.830Z] ['info'] => Found 3 possible coverage files:
  build/coverage.vcxproj
  build/coverage.vcxproj.filters
  build/CMakeFiles/ba244c8abb1c4f95a8debfe2a54cc27e/coverage.rule
[2024-01-01T20:57:41.830Z] ['info'] Processing D:/a/babel/babel/build/coverage.vcxproj...
[2024-01-01T20:57:41.832Z] ['info'] Processing D:/a/babel/babel/build/coverage.vcxproj.filters...
[2024-01-01T20:57:41.832Z] ['info'] Processing D:/a/babel/babel/build/CMakeFiles/ba244c8abb1c4f95a8debfe2a54cc27e/coverage.rule...
[2024-01-01T20:57:41.834Z] ['info'] Detected GitHub Actions as the CI provider.
[2024-01-01T20:57:42.158Z] ['info'] Pinging Codecov: https://codecov.io/upload/v4?package=github-action-3.1.4-uploader-0.7.1&token=*******&branch=action-config&build=7379793685&build_url=https%3A%2F%2Fgithub.com%2FWehrWolff%2Fbabel%2Factions%2Fruns%2F7379793685&commit=f6e91b03e2b778dbfebb94f12a1464026424c37b&job=CMake+on+multiple+platforms&pr=&service=github-actions&slug=WehrWolff%2Fbabel&name=&tag=&flags=&parent=
[2024-01-01T20:57:42.505Z] ['info'] https://app.codecov.io/github/WehrWolff/babel/commit/f6e91b03e2b778dbfebb94f12a1464026424c37b
https://storage.googleapis.com/codecov/v4/raw/2024-01-01/3D483AAE721796A772ABCE73B5D39338/f6e91b03e2b778dbfebb94f12a1464026424c37b/053ad44b-c087-4517-b61e-e622c369de55.txt?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=GOOG1EJOGFN2JQ4OCTGA2MU5AEIT7OT5Z7HTFOAN2SPG4NWSN2UJYOY5U6LZQ%2F20240[10](https://github.com/WehrWolff/babel/actions/runs/7379793685/job/20076678421#step:8:11)1%2FUS%2Fs3%2Faws4_request&X-Amz-Date=20240101T205742Z&X-Amz-Expires=10&X-Amz-SignedHeaders=host&X-Amz-Signature=57764194b0b76fee2d3cc1fadf7b73445b432449ccfc6851d22926fe3d81d194
[2024-01-01T20:57:42.506Z] ['info'] Uploading...
[2024-01-01T20:57:42.775Z] ['info'] {"status":"processing","resultURL":"https://app.codecov.io/github/WehrWolff/babel/commit/f6e91b03e2b778dbfebb94f[12](https://github.com/WehrWolff/babel/actions/runs/7379793685/job/20076678421#step:8:13)a[14](https://github.com/WehrWolff/babel/actions/runs/7379793685/job/20076678421#step:8:15)640264[24](https://github.com/WehrWolff/babel/actions/runs/7379793685/job/20076678421#step:8:25)c[37](https://github.com/WehrWolff/babel/actions/runs/7379793685/job/20076678421#step:8:38)b"}

This is not so much related to codecov but clang on ubuntu also results in errors for me but this has to do with the boost and gtest libraries that are important for the tests. While there are no problems with this on the other jobs this one fails due to an error of either gtest or boost when trying to manage them with Conan. The log with the gtest error looks like the following:

gtest/1.11.0: Building from source
gtest/1.11.0: Package gtest/1.11.0:4940cb624127460406993ce86442e19d6ce8ef1f
gtest/1.11.0: Copying sources to build folder
gtest/1.11.0: Building your package in /home/runner/.conan2/p/b/gtest1d6a17e498e64/b
gtest/1.11.0: Calling generate()
gtest/1.11.0: Generators folder: /home/runner/.conan2/p/b/gtest1d6a17e498e64/b/build/Release/generators
gtest/1.11.0: CMakeToolchain generated: conan_toolchain.cmake
gtest/1.11.0: CMakeToolchain generated: CMakePresets.json
gtest/1.11.0: CMakeToolchain generated: ../../../src/CMakeUserPresets.json
gtest/1.11.0: Generating aggregated env files
gtest/1.11.0: Generated aggregated env files: ['conanbuild.sh', 'conanrun.sh']
gtest/1.11.0: Calling build()
gtest/1.11.0: Apply patch (file): patches/gtest-1.11.0.patch
gtest/1.11.0: Running CMake.configure()
gtest/1.11.0: RUN: cmake -G "Unix Makefiles" -DCMAKE_TOOLCHAIN_FILE="/home/runner/.conan2/p/b/gtest1d6a17e498e64/b/build/Release/generators/conan_toolchain.cmake" -DCMAKE_INSTALL_PREFIX="/home/runner/.conan2/p/b/gtest1d6a17e498e64/p" -DCMAKE_POLICY_DEFAULT_CMP0077="NEW" -DBUILD_GMOCK="ON" -Dgtest_hide_internal_symbols="OFF" -DCMAKE_POLICY_DEFAULT_CMP0091="NEW" -DCMAKE_BUILD_TYPE="Release" "/home/runner/.conan2/p/b/gtest1d6a17e498e64/b/src"
CMake Deprecation Warning at CMakeLists.txt:4 (cmake_minimum_required):
  Compatibility with CMake < 3.5 will be removed from a future version of
  CMake.

  Update the VERSION argument <min> value or use a ...<max> suffix to tell
  CMake that the project does not need compatibility with older versions.

-- Using Conan toolchain: /home/runner/.conan2/p/b/gtest1d6a17e498e64/b/build/Release/generators/conan_toolchain.cmake
-- Conan toolchain: Setting CMAKE_POSITION_INDEPENDENT_CODE=ON (options.fPIC)
-- Conan toolchain: C++ Standard 20 with extensions OFF
-- Conan toolchain: Setting BUILD_SHARED_LIBS = OFF
-- The C compiler identification is GNU 11.4.0
-- The CXX compiler identification is GNU 11.4.0
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working C compiler: /usr/bin/cc - skipped
-- Detecting C compile features
-- Detecting C compile features - done
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - failed
-- Check for working CXX compiler: /usr/bin/c++
-- Check for working CXX compiler: /usr/bin/c++ - broken
CMake Error at /usr/local/share/cmake-3.28/Modules/CMakeTestCXXCompiler.cmake:60 (message):
  The C++ compiler

    "/usr/bin/c++"

  is not able to compile a simple test program.

  It fails with the following output:

    Change Dir: '/home/runner/.conan2/p/b/gtest1d6a17e498e64/b/build/Release/CMakeFiles/CMakeScratch/TryCompile-SHpFqf'

    Run Build Command(s): /usr/local/bin/cmake -E env VERBOSE=1 /usr/bin/gmake -f Makefile cmTC_a929c/fast
    /usr/bin/gmake  -f CMakeFiles/cmTC_a929c.dir/build.make CMakeFiles/cmTC_a929c.dir/build
    gmake[1]: Entering directory '/home/runner/.conan2/p/b/gtest1d6a17e498e64/b/build/Release/CMakeFiles/CMakeScratch/TryCompile-SHpFqf'
    Building CXX object CMakeFiles/cmTC_a929c.dir/testCXXCompiler.cxx.o
    /usr/bin/c++ -D_GLIBCXX_USE_CXX11_ABI=0  -m64 -stdlib=libstdc++  -std=c++20 -fPIE -o CMakeFiles/cmTC_a929c.dir/testCXXCompiler.cxx.o -c /home/runner/.conan2/p/b/gtest1d6a17e498e64/b/build/Release/CMakeFiles/CMakeScratch/TryCompile-SHpFqf/testCXXCompiler.cxx
    c++: error: unrecognized command-line option ‘-stdlib=libstdc++’
    gmake[1]: *** [CMakeFiles/cmTC_a929c.dir/build.make:78: CMakeFiles/cmTC_a929c.dir/testCXXCompiler.cxx.o] Error 1
    gmake[1]: Leaving directory '/home/runner/.conan2/p/b/gtest1d6a17e498e64/b/build/Release/CMakeFiles/CMakeScratch/TryCompile-SHpFqf'
    gmake: *** [Makefile:127: cmTC_a929c/fast] Error 2

  CMake will not be able to correctly generate this project.
Call Stack (most recent call first):
  CMakeLists.txt:10 (project)

-- Configuring incomplete, errors occurred!

gtest/1.11.0: ERROR: 
Package '4940cb6241[274](https://github.com/WehrWolff/babel/actions/runs/7379793685/job/20076678421#step:4:275)60406993ce86442e19d6ce8ef1f' build failed
gtest/1.11.0: WARN: Build folder /home/runner/.conan2/p/b/gtest1d6a17e498e64/b/build/Release
ERROR: gtest/1.11.0: Error in build() method, line 152
    cmake.configure()
    ConanException: Error 1 while executing
Error: Process completed with exit code 1.

the main takeaway is c++: error: unrecognized command-line option ‘-stdlib=libstdc++’ which I'm setting in the action file, the problem however is that all possibilities for this option Possible values are ['libstdc++', 'libstdc++11', 'libc++', 'c++_shared', 'c++_static'], including not setting it at all lead to an error with gtest like the previous one or with boost like the following log shows:

-------- Installing package boost/1.83.0 (6 of 6) --------
boost/1.83.0: Building from source
boost/1.83.0: Package boost/1.83.0:1b7ad8fc444edeb17713e222cbf2c0342dca06c2
boost/1.83.0: Building your package in /home/runner/.conan2/p/b/boost94ee3ccdaefa7/b
boost/1.83.0: Calling generate()
boost/1.83.0: Generators folder: /home/runner/.conan2/p/b/boost94ee3ccdaefa7/b/build-release/conan
boost/1.83.0: Generating aggregated env files
boost/1.83.0: Generated aggregated env files: ['conanbuild.sh', 'conanrun.sh']
boost/1.83.0: Calling build()
boost/1.83.0: WARN: replace_in_file didn't find pattern '/* thread_local */' in '/home/runner/.conan2/p/boost1d9916eed0e5d/s/src/boost/stacktrace/detail/libbacktrace_impls.hpp' file.
boost/1.83.0: WARN: replace_in_file didn't find pattern '/* static __thread */' in '/home/runner/.conan2/p/boost1d9916eed0e5d/s/src/boost/stacktrace/detail/libbacktrace_impls.hpp' file.
boost/1.83.0: WARN: replace_in_file didn't find pattern 'local generic-os = [ set.difference $(all-os) : aix darwin vxworks solaris osf hpux ] ;' in '/home/runner/.conan2/p/boost1d9916eed0e5d/s/src/tools/build/src/tools/gcc.jam' file.
boost/1.83.0: WARN: replace_in_file didn't find pattern 'local no-threading = android beos haiku sgi darwin vxworks ;' in '/home/runner/.conan2/p/boost1d9916eed0e5d/s/src/tools/build/src/tools/gcc.jam' file.
boost/1.83.0: WARN: Patching user-config.jam
boost/1.83.0: WARN: 
using zlib : 1.3 : <include>"/home/runner/.conan2/p/b/zlibf4262fa8a9303/p/include" <search>"/home/runner/.conan2/p/b/zlibf4262fa8a9303/p/lib" <name>z ;
using bzip2 : 1.0.8 : <include>"/home/runner/.conan2/p/b/bzip255a462fb49fad/p/include" <search>"/home/runner/.conan2/p/b/bzip255a462fb49fad/p/lib" <name>bz2 ;
using "clang" :  :  "/usr/bin/clang++" : 
<compileflags>"-I/home/runner/.conan2/p/b/libba7c4b89e339ee3/p/include" <linkflags>"-L/home/runner/.conan2/p/b/libba7c4b89e339ee3/p/lib"  ;
boost/1.83.0: WARN: b2 -q numa=on target-os=linux architecture=x86 address-model=64 binary-format=elf abi=sysv --layout=system --user-config=/home/runner/.conan2/p/boost1d9916eed0e5d/s/src/tools/build/user-config.jam -sNO_ZLIB=0 -sNO_BZIP2=0 -sNO_LZMA=1 -sNO_ZSTD=1 boost.locale.icu=off --disable-icu boost.locale.iconv=on boost.locale.iconv.lib=libc threading=multi visibility=hidden link=static variant=release --with-atomic --with-chrono --with-container --with-context --with-contract --with-coroutine --with-date_time --with-exception --with-fiber --with-filesystem --with-graph --with-iostreams --with-json --with-locale --with-log --with-math --with-nowide --with-program_options --with-random --with-regex --with-serialization --with-stacktrace --with-system --with-test --with-thread --with-timer --with-type_erasure --with-url --with-wave toolset=clang cxxflags=-std=c++2a pch=on -sLIBBACKTRACE_PATH=/home/runner/.conan2/p/b/libba7c4b89e339ee3/p linkflags="-stdlib=None" cxxflags="-fPIC -stdlib=None -DBOOST_STACKTRACE_ADDR2LINE_LOCATION=/usr/bin/addr2line" install --prefix=/home/runner/.conan2/p/b/boost94ee3ccdaefa7/p -j4 --abbreviate-paths -d0 --debug-configuration --build-dir="/home/runner/.conan2/p/b/boost94ee3ccdaefa7/b/build-release"
boost/1.83.0: RUN: b2 -q numa=on target-os=linux architecture=x86 address-model=64 binary-format=elf abi=sysv --layout=system --user-config=/home/runner/.conan2/p/boost1d9916eed0e5d/s/src/tools/build/user-config.jam -sNO_ZLIB=0 -sNO_BZIP2=0 -sNO_LZMA=1 -sNO_ZSTD=1 boost.locale.icu=off --disable-icu boost.locale.iconv=on boost.locale.iconv.lib=libc threading=multi visibility=hidden link=static variant=release --with-atomic --with-chrono --with-container --with-context --with-contract --with-coroutine --with-date_time --with-exception --with-fiber --with-filesystem --with-graph --with-iostreams --with-json --with-locale --with-log --with-math --with-nowide --with-program_options --with-random --with-regex --with-serialization --with-stacktrace --with-system --with-test --with-thread --with-timer --with-type_erasure --with-url --with-wave toolset=clang cxxflags=-std=c++2a pch=on -sLIBBACKTRACE_PATH=/home/runner/.conan2/p/b/libba7c4b89e339ee3/p linkflags="-stdlib=None" cxxflags="-fPIC -stdlib=None -DBOOST_STACKTRACE_ADDR2LINE_LOCATION=/usr/bin/addr2line" install --prefix=/home/runner/.conan2/p/b/boost94ee3ccdaefa7/p -j4 --abbreviate-paths -d0 --debug-configuration --build-dir="/home/runner/.conan2/p/b/boost94ee3ccdaefa7/b/build-release"
notice: found boost-build.jam at /home/runner/.conan2/p/boost1d9916eed0e5d/s/src/boost-build.jam
notice: loading B2 from /home/runner/.conan2/p/b2a87f948dd463f/p/bin/.b2/kernel/bootstrap.jam
notice: Searching '/etc' '/home/runner' '/home/runner/.conan2/p/b2a87f948dd463f/p/bin/.b2/kernel' '/home/runner/.conan2/p/b2a87f948dd463f/p/bin/.b2/util' '/home/runner/.conan2/p/b2a87f948dd463f/p/bin/.b2/build' '/home/runner/.conan2/p/b2a87f948dd463f/p/bin/.b2/tools' '/home/runner/.conan2/p/b2a87f948dd463f/p/bin/.b2/contrib' '/home/runner/.conan2/p/b2a87f948dd463f/p/bin/.b2/.' for site-config configuration file 'site-config.jam'.
notice: Configuration file 'site-config.jam' not found in '/etc' '/home/runner' '/home/runner/.conan2/p/b2a87f948dd463f/p/bin/.b2/kernel' '/home/runner/.conan2/p/b2a87f948dd463f/p/bin/.b2/util' '/home/runner/.conan2/p/b2a87f948dd463f/p/bin/.b2/build' '/home/runner/.conan2/p/b2a87f948dd463f/p/bin/.b2/tools' '/home/runner/.conan2/p/b2a87f948dd463f/p/bin/.b2/contrib' '/home/runner/.conan2/p/b2a87f948dd463f/p/bin/.b2/.'.
notice: Loading explicitly specified user configuration file:
    /home/runner/.conan2/p/boost1d9916eed0e5d/s/src/tools/build/user-config.jam
notice: Searching '/home/runner/.conan2/p/boost1d9916eed0e5d/s/src/tools/build' for user-config configuration file 'user-config.jam'.
notice: Loading user-config configuration file 'user-config.jam' from '/home/runner/.conan2/p/boost1d9916eed0e5d/s/src/tools/build'.
notice: [zlib] Using pre-installed library
notice: [zlib] Condition
notice: [bzip2] Using pre-installed library
notice: [bzip2] Condition
notice: will use '/usr/bin/clang++' for clang-linux, condition <toolset>clang-linux-14
notice: [zlib] zlib is already configured
notice: [bzip2] bzip is already configured
notice: iostreams: not using lzma compression 
notice: iostreams: not using zstd compression 
notice: [python-cfg] Configuring python...
notice: [python-cfg] Checking interpreter command "python"...
notice: [python-cfg] running command 'python -c "from sys import *; print('version=%d.%d\nplatform=%s\nprefix=%s\nexec_prefix=%s\nexecutable=%s' % (version_info[0],version_info[1],platform,prefix,exec_prefix,executable))" 2>&1'
notice: [python-cfg] ...requested configuration matched!
notice: [python-cfg] Details of this Python configuration:
notice: [python-cfg]   interpreter command: "python"
notice: [python-cfg]   include path: "/usr/include/python3.10"
notice: [python-cfg]   library path: "/usr/lib/python3.10/config" "/usr/lib"
notice: [python-cfg] Checking for NumPy...
notice: [python-cfg] running command 'python -c "import sys; sys.stderr = sys.stdout; import numpy; print(numpy.get_include())"'
notice: [python-cfg] NumPy disabled. Reason:
notice: [python-cfg]   python -c "import sys; sys.stderr = sys.stdout; import numpy; print(numpy.get_include())" aborted with 
notice: [python-cfg]   Traceback (most recent call last):
  File "<string>", line 1, in <module>
ModuleNotFoundError: No module named 'numpy'
Performing configuration checks

    - default address-model    : none [1]
    - default architecture     : none [1]
    - compiler supports SSE2   : no [2]
    - compiler supports SSE4.1 : no [2]
    - has std::atomic_ref      : no [2]
    - has statx                : no [2]
    - has statx syscall        : no [2]
    - has init_priority attribute : no [2]
    - has stat::st_blksize     : no [2]
    - has stat::st_mtim        : no [2]
    - has stat::st_mtimensec   : no [2]
    - has stat::st_mtimespec   : no [2]
    - has stat::st_birthtim    : no [2]
    - has stat::st_birthtimensec : no [2]
    - has stat::st_birthtimespec : no [2]
    - has fdopendir(O_NOFOLLOW) : no [2]
    - has dirent::d_type       : no [2]
    - has POSIX *at APIs       : no [2]
    - cxx11_auto_declarations  : no [2]
    - cxx11_auto_declarations  : no [3]
    - has_icu builds           : no [2]
    - zlib                     : no [4]
    - bzip2                    : no [4]
    - cxx11_constexpr          : no [2]
    - cxx11_constexpr          : no [3]
    - iconv (libc)             : no [2]
    - iconv (separate)         : no [2]
- Boost.Locale needs either iconv or ICU library to be built.
    - iconv (libc)             : no [3]
    - iconv (separate)         : no [3]
- Boost.Locale needs either iconv or ICU library to be built.
    - native atomic int32 supported : no [2]
    - native syslog supported  : no [2]
    - pthread supports robust mutexes : no [2]
    - lockfree boost::atomic_flag : no [2]
    - compiler supports SSSE3  : no [2]
    - compiler supports AVX2   : no [2]
    - gcc visibility           : no [2]
    - cxx11_noexcept           : no [2]
    - gcc visibility           : no [3]
    - cxx11_noexcept           : no [3]
    - libbacktrace builds      : no [2]
    - libbacktrace builds      : no [3]
    - addr2line builds         : no [2]
    - addr2line builds         : no [3]
    - WinDbg builds            : no [2]
    - WinDbg builds            : no [3]
    - WinDbgCached builds      : no [2]
    - WinDbgCached builds      : no [3]
    - BOOST_COMP_GNUC >= 4.3.0 : no [2]

[1] clng-14
[2] clng-lnx-14/rls/adrs-mdl-64/archt-x86/bst.l-lbc/bst.l-on/bst.l-off/lnk-sttc/nm-on/pythn-3.10/thrd-mlt/vsblt-hdn
[3] clng-lnx-14/rls/adrs-mdl-64/archt-x86/bst.l-lbc/bst.l-on/bst.l-off/bld-no/lnk-sttc/nm-on/pythn-3.10/thrd-mlt/vsblt-hdn
[4] lnk-sttc

Component configuration:

    - atomic                   : building
    - chrono                   : building
    - container                : building
    - context                  : building
    - contract                 : building
    - coroutine                : building
    - date_time                : building
    - exception                : building
    - fiber                    : building
    - filesystem               : building
    - graph                    : building
    - graph_parallel           : not building
    - headers                  : not building
    - iostreams                : building
    - json                     : building
    - locale                   : building
    - log                      : building
    - math                     : building
    - mpi                      : not building
    - nowide                   : building
    - program_options          : building
    - python                   : not building
    - random                   : building
    - regex                    : building
    - serialization            : building
    - stacktrace               : building
    - system                   : building
    - test                     : building
    - thread                   : building
    - timer                    : building
    - type_erasure             : building
    - url                      : building
    - wave                     : building

clang: error: invalid library name in argument '-stdlib=None'
clang: error: invalid library name in argument '-stdlib=None'
clang: error: invalid library name in argument '-stdlib=None'
...failed updating 3 targets...

boost/1.83.0: ERROR: 
Package '1b7ad8fc444edeb17[713](https://github.com/WehrWolff/babel/actions/runs/7379557101/job/20075952982#step:4:714)e222cbf2c0342dca06c2' build failed
boost/1.83.0: WARN: Build folder /home/runner/.conan2/p/b/boost94ee3ccdaefa7/b/build-release
ERROR: boost/1.83.0: Error in build() method, line 887
    self.run(full_command)
    ConanException: Error 1 while executing
Error: Process completed with exit code 1.

Sorry for forgetting the actual results and logs and thanks again for looking into this.

drazisil-codecov commented 9 months ago

Hi @WehrWolff ,

Thank you for that. It looks like you uploaded 3 files:

[2024-01-01T20:57:41.830Z] ['info'] Processing D:/a/babel/babel/build/coverage.vcxproj... [2024-01-01T20:57:41.832Z] ['info'] Processing D:/a/babel/babel/build/coverage.vcxproj.filters... [2024-01-01T20:57:41.832Z] ['info'] Processing D:/a/babel/babel/build/CMakeFiles/ba244c8abb1c4f95a8debfe2a54cc27e/coverage.rule...

It doesn't look like any of those are actually coverage reports, so it sounds like the issue is what you say further down, that they aren't being generated. Codecov upload and processes your reports, we don't generate them.

I really hate to say this after all the details you shared, but it look like I would need to refer you back to the clang support community. Much as I'd love to help, troubleshooting compilation issues isn't in my scope of support (or knowledge) and I unfortunately do not have the bandwidth to dig in further.

Once you have successfully generated the reports, please come back and tag me if we still are having troubles accepting them. I wish you luck!

drazisil-codecov commented 9 months ago

@WehrWolff , If I were to start digging in, I would probably make sure that the build-essential package is on the machine.

Possible https://gist.github.com/treuherz/bc943aecbbb5ae16f1c4bf6ca01dcdfc may help.