diff --git a/.github/workflows/nightly.yml b/.github/workflows/nightly.yml index 0609fef70..641a354f0 100644 --- a/.github/workflows/nightly.yml +++ b/.github/workflows/nightly.yml @@ -6,6 +6,7 @@ on: workflow_dispatch: schedule: - cron: '0 4 * * *' + pull_request: permissions: contents: read diff --git a/.github/workflows/pr_push.yml b/.github/workflows/pr_push.yml index fffdc7373..633fbe7c9 100644 --- a/.github/workflows/pr_push.yml +++ b/.github/workflows/pr_push.yml @@ -6,7 +6,7 @@ on: push: branches-ignore: - 'dependabot/**' - pull_request: + # pull_request: concurrency: group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }} diff --git a/CMakeLists.txt b/CMakeLists.txt index fe6599d6c..8d4a6118a 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -329,7 +329,25 @@ if(UMF_LINK_HWLOC_STATICALLY) # ./configure invocation below, so hwloc would otherwise be built with # the ambient host compiler instead of the one CMake was configured to # use (e.g. a sysroot- or toolchain-file-pinned compiler), causing an - # ABI mismatch against the rest of the build. + # ABI mismatch against the rest of the build. CC/CXX are passed as + # space-separated "compiler [flags...]" strings (like CC="ccache gcc"), + # so --sysroot/--gcc-toolchain can be appended directly; make + # word-splits them unquoted when invoking the compiler. + set(UMF_HWLOC_CC "${CMAKE_C_COMPILER}") + set(UMF_HWLOC_CXX "${CMAKE_CXX_COMPILER}") + if(CMAKE_SYSROOT) + string(APPEND UMF_HWLOC_CC " --sysroot=${CMAKE_SYSROOT}") + string(APPEND UMF_HWLOC_CXX " --sysroot=${CMAKE_SYSROOT}") + endif() + if(CMAKE_C_COMPILER_EXTERNAL_TOOLCHAIN) + string(APPEND UMF_HWLOC_CC + " --gcc-toolchain=${CMAKE_C_COMPILER_EXTERNAL_TOOLCHAIN}") + endif() + if(CMAKE_CXX_COMPILER_EXTERNAL_TOOLCHAIN) + string(APPEND UMF_HWLOC_CXX + " --gcc-toolchain=${CMAKE_CXX_COMPILER_EXTERNAL_TOOLCHAIN}") + endif() + ExternalProject_Add( hwloc_targ PREFIX ${hwloc_targ_PREFIX} @@ -338,11 +356,11 @@ if(UMF_LINK_HWLOC_STATICALLY) UPDATE_DISCONNECTED TRUE PATCH_COMMAND git apply ${PROJECT_SOURCE_DIR}/cmake/fix_coverity_issues.patch - CONFIGURE_COMMAND ${CMAKE_COMMAND} -E env CC=${CMAKE_C_COMPILER} - CXX=${CMAKE_CXX_COMPILER} /autogen.sh + CONFIGURE_COMMAND ${CMAKE_COMMAND} -E env "CC=${UMF_HWLOC_CC}" + "CXX=${UMF_HWLOC_CXX}" /autogen.sh COMMAND - ${CMAKE_COMMAND} -E env CC=${CMAKE_C_COMPILER} - CXX=${CMAKE_CXX_COMPILER} /configure + ${CMAKE_COMMAND} -E env "CC=${UMF_HWLOC_CC}" + "CXX=${UMF_HWLOC_CXX}" /configure --prefix= --enable-static=yes --enable-shared=no --disable-libxml2 --disable-pci --disable-levelzero --disable-opencl --disable-cuda --disable-nvml --disable-libudev