Skip to content

Commit

Permalink
Run papi lib configure step as nonparallel during build (#29)
Browse files Browse the repository at this point in the history
Limit to single job during the configure step of rocprofiler-systems-papi-build; error due to files not being available in time if number of jobs is too low.

Signed-off-by: Carrie Fallows <[email protected]>
  • Loading branch information
cfallows-amd authored Nov 15, 2024
1 parent ba0efac commit bf1f1e6
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions cmake/PAPI.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,9 @@ if(NOT EXISTS "${ROCPROFSYS_PAPI_INSTALL_DIR}")
${ROCPROFSYS_PAPI_INSTALL_DIR}/lib/libpfm.so)
endif()

# Set ROCPROFSYS_PAPI_CONFIGURE_JOBS for commands that need to be run nonparallel
set(ROCPROFSYS_PAPI_CONFIGURE_JOBS 1)

rocprofiler_systems_add_option(ROCPROFSYS_PAPI_AUTO_COMPONENTS
"Automatically enable components" OFF)

Expand Down Expand Up @@ -212,8 +215,10 @@ externalproject_add(
--with-perf-events --with-tests=no
--with-components=${_ROCPROFSYS_PAPI_COMPONENTS}
--libdir=${ROCPROFSYS_PAPI_INSTALL_DIR}/lib
CONFIGURE_COMMAND ${CMAKE_COMMAND} -E env CFLAGS=-fPIC\ -O3\ -Wno-stringop-truncation
${ROCPROFSYS_PAPI_EXTRA_ENV} ${MAKE_EXECUTABLE} static install -s
CONFIGURE_COMMAND
${CMAKE_COMMAND} -E env CFLAGS=-fPIC\ -O3\ -Wno-stringop-truncation
${ROCPROFSYS_PAPI_EXTRA_ENV} ${MAKE_EXECUTABLE} static install -s -j
${ROCPROFSYS_PAPI_CONFIGURE_JOBS}
BUILD_COMMAND ${CMAKE_COMMAND} -E env CFLAGS=-fPIC\ -O3\ -Wno-stringop-truncation
${ROCPROFSYS_PAPI_EXTRA_ENV} ${MAKE_EXECUTABLE} utils install-utils -s
INSTALL_COMMAND ""
Expand Down

0 comments on commit bf1f1e6

Please sign in to comment.