Skip to content
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

Explicitly require VS2015 or greater #189

Merged
merged 2 commits into from
Nov 11, 2016
Merged

Explicitly require VS2015 or greater #189

merged 2 commits into from
Nov 11, 2016

Conversation

jslee02
Copy link
Member

@jslee02 jslee02 commented Nov 10, 2016

Related issue: #184

@jslee02 jslee02 added this to the FCL 0.6.0 milestone Nov 10, 2016
Copy link
Member

@sherm1 sherm1 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good, one minor comment.

if(MSVC)
if(MSVC_VERSION VERSION_LESS 1900)
message(FATAL_ERROR "${PROJECT_NAME} requires Visual Studio 2015 or greater.")
endif()
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /EHsc /MP /W1 /bigobj")
if(FCL_TREAT_WARNINGS_AS_ERRORS)
add_definitions(/WX)
endif(FCL_TREAT_WARNINGS_AS_ERRORS)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Consider endif() for consistency.

Copy link
Member Author

@jslee02 jslee02 Nov 10, 2016

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actually, I don't know which one is the convention here. Some endif() contain the parameter while some don't. Do we want to use endif() for other places as well?

Edit: I personally prefer endif() because sometimes it's not clear which parameter should be used. For example:

if(SOME_CONDITION)
  ...
elseif(SOME_OTHER_CONDITION)
  ...
endif(SOME_CONDITION? or SOME_OTHER_CONDITIONS?)

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I agree! endif() is always better, IMO. That is very clear when the original condition is some complicated expression!

@jslee02
Copy link
Member Author

jslee02 commented Nov 10, 2016

I removed conditions from endif(). It seems endif() is the convention according to the CMakeLists.txt files of FCL.

@jslee02 jslee02 merged commit 09c1685 into master Nov 11, 2016
@jslee02 jslee02 deleted the msvc14 branch December 9, 2016 20:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants