From bf1f1e64d61c04f627b8710fb4620f0573628b6b Mon Sep 17 00:00:00 2001 From: cfallows-amd Date: Fri, 15 Nov 2024 17:16:05 -0500 Subject: [PATCH] Run papi lib configure step as nonparallel during build (#29) 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 --- cmake/PAPI.cmake | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/cmake/PAPI.cmake b/cmake/PAPI.cmake index 7c933669..780dd101 100644 --- a/cmake/PAPI.cmake +++ b/cmake/PAPI.cmake @@ -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) @@ -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 ""