Skip to content

Commit

Permalink
[loadgen]: Allow one to pass in custom CXX_FLAGS by passing the MLPER…
Browse files Browse the repository at this point in the history
…F_LOADGEN_CXX_FLAGS cmake variable. This allows upstream projects to specify extra CXX_FLAGs. (#1140)

Co-authored-by: rameshchukka <rnaidu02@yahoo.com>
  • Loading branch information
abduld and rnaidu02 authored Jun 6, 2022
1 parent 98776fd commit 1483c8f
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions loadgen/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,10 @@ message("mlperf_loadgen v${mlperf_loadgen_VERSION_MAJOR}.${mlperf_loadgen_VERSIO
if (NOT MSVC)
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -O3 -W -Wall")
endif()
# Extra build options can be specified by setting the MLPERF_LOADGEN_CXX_FLAGS variable
if (MLPERF_LOADGEN_CXX_FLAGS)
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${MLPERF_LOADGEN_CXX_FLAGS}")
endif()
message(STATUS "Using C++ compiler flags: ${CMAKE_CXX_FLAGS}")
set(CMAKE_CXX_STANDARD "14")
message(STATUS "Using C++ standard: ${CMAKE_CXX_STANDARD}")
Expand Down

0 comments on commit 1483c8f

Please sign in to comment.