-
Notifications
You must be signed in to change notification settings - Fork 393
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
9 changed files
with
253 additions
and
243 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,39 +1,45 @@ | ||
cmake_minimum_required(VERSION 3.5.1) | ||
project(ConvertInputFormat) | ||
|
||
set(CMAKE_CXX_STANDARD 11) | ||
|
||
# Set the CFLAGS and CXXFLAGS depending on the options the user specified. | ||
# Only GCC-like compilers support -Wextra, and other compilers give tons of | ||
# output for -Wall, so only -Wall and -Wextra on GCC. | ||
#if(CMAKE_COMPILER_IS_GNUCC OR "${CMAKE_CXX_COMPILER_ID}" STREQUAL "Clang") | ||
# set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall -Wextra -pedantic") | ||
# set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wall -Wextra -pedantic") | ||
#endif(CMAKE_COMPILER_IS_GNUCC OR "${CMAKE_CXX_COMPILER_ID}" STREQUAL "Clang") | ||
# | ||
if(APPLE OR UNIX) | ||
add_executable(ConvertInputFormat main.cpp) | ||
else() # windows | ||
add_executable(ConvertInputFormat main.cpp) # "${CMAKE_CURRENT_BINARY_DIR}/energyplus.rc" ) | ||
endif() | ||
|
||
|
||
target_link_libraries(ConvertInputFormat PRIVATE project_options project_warnings) | ||
if (CMAKE_COMPILER_IS_GNUCC OR "${CMAKE_CXX_COMPILER_ID}" STREQUAL "Clang") | ||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall -Wextra -pedantic") | ||
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wall -Wextra -pedantic") | ||
endif (CMAKE_COMPILER_IS_GNUCC OR "${CMAKE_CXX_COMPILER_ID}" STREQUAL "Clang") | ||
|
||
# Detect OpenMP support in a compiler. If the compiler supports OpenMP, the | ||
# flags to compile with OpenMP are returned and added. | ||
find_package(OpenMP) | ||
if(OpenMP_CXX_FOUND) | ||
target_link_libraries(ConvertInputFormat PRIVATE OpenMP::OpenMP_CXX) | ||
if (OPENMP_FOUND) | ||
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${OpenMP_C_FLAGS}") | ||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${OpenMP_CXX_FLAGS}") | ||
endif (OPENMP_FOUND) | ||
|
||
if (UNIX) | ||
ADD_DEFINITIONS("-fPIC") | ||
endif() | ||
|
||
if (APPLE OR UNIX) | ||
add_executable( ConvertInputFormat main.cpp ) | ||
else() # windows | ||
add_executable( ConvertInputFormat main.cpp ) # "${CMAKE_CURRENT_BINARY_DIR}/energyplus.rc" ) | ||
endif() | ||
|
||
target_link_libraries( ConvertInputFormat energyplusparser ) | ||
|
||
target_link_libraries(ConvertInputFormat PRIVATE energyplusparser ${CMAKE_DL_LIBS}) | ||
if(UNIX AND NOT APPLE) | ||
target_link_libraries( ConvertInputFormat dl ) | ||
endif() | ||
|
||
if(WIN32) | ||
target_link_libraries(ConvertInputFormat PRIVATE Shlwapi) | ||
if (WIN32) | ||
target_link_libraries( ConvertInputFormat Shlwapi ) | ||
endif() | ||
|
||
set_target_properties(ConvertInputFormat PROPERTIES VERSION ${ENERGYPLUS_VERSION}) | ||
set_target_properties(ConvertInputFormat PROPERTIES FOLDER Auxiliary) | ||
|
||
install(TARGETS ConvertInputFormat DESTINATION ./) | ||
|
||
install( TARGETS ConvertInputFormat DESTINATION ./ ) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
0354a59
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
cmake_modernize (lefticus) - x86_64-MacOS-10.15-clang-11.0.0: OK (2998 of 2998 tests passed, 0 test warnings)
0354a59
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
cmake_modernize (lefticus) - x86_64-Linux-Ubuntu-18.04-gcc-7.5: OK (3038 of 3038 tests passed, 0 test warnings)
0354a59
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
cmake_modernize (lefticus) - x86_64-Linux-Ubuntu-18.04-gcc-7.5-UnitTestsCoverage-Debug: OK (1563 of 1564 tests passed, 0 test warnings)
Failures:\n
EnergyPlusFixture Test Summary
0354a59
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
cmake_modernize (lefticus) - x86_64-Linux-Ubuntu-18.04-gcc-7.5-IntegrationCoverage-Debug: OK (721 of 721 tests passed, 0 test warnings)
0354a59
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
cmake_modernize (lefticus) - Win64-Windows-10-VisualStudio-16: OK (2255 of 2255 tests passed, 0 test warnings)