-
Notifications
You must be signed in to change notification settings - Fork 191
Xu update cmake build options for linux #833
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Xu update cmake build options for linux #833
Conversation
@alheinecke please review it. |
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.
It seems the changes are based on "make reaclean && make" on some system and then options are copied over. However, the actual logic in Makefile and Makefile.inc needs to be ported over.
|
||
add_definitions(-DLIBXSMM_DEFAULT_CONFIG -U_DEBUG) | ||
if(NOT MSVC) | ||
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC") |
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.
Flags (incl. arch SSE4, AVX, etc.) should be read from parameters as in case of using make, default should be sse4.2. Same is for options like PEDANTIC, OMP, SIMD, etc.
|
||
add_definitions(-DLIBXSMM_DEFAULT_CONFIG) | ||
add_definitions(-DNDEBUG) | ||
add_definitions(-DLIBXSMM_NOFORTRAN) |
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.
Same as compiler knobs, these defines need to be discovered by the build system and not just set.
original build option from makefile:
ported to cmake build: