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

MSVC with "/MD" when using CMake? #2116

Open
fei4xu opened this issue Jul 17, 2019 · 0 comments
Open

MSVC with "/MD" when using CMake? #2116

fei4xu opened this issue Jul 17, 2019 · 0 comments

Comments

@fei4xu
Copy link

fei4xu commented Jul 17, 2019

Anyway to use /MD in Cinder?

I see

if( MSVC )
	# Override the default /MD with /MT
	foreach( 
		flag_var
		CMAKE_C_FLAGS CMAKE_C_FLAGS_DEBUG CMAKE_C_FLAGS_RELEASE CMAKE_C_FLAGS_MINSIZEREL CMAKE_C_FLAGS_RELWITHDEBINFO 
		CMAKE_CXX_FLAGS CMAKE_CXX_FLAGS_DEBUG CMAKE_CXX_FLAGS_RELEASE CMAKE_CXX_FLAGS_MINSIZEREL CMAKE_CXX_FLAGS_RELWITHDEBINFO 
	)
		if( ${flag_var} MATCHES "/MD" )
			string( REGEX REPLACE "/MD" "/MT" ${flag_var} "${${flag_var}}" )
		endif()
	endforeach()
	
	
endif()

Can we add an MSVC_MD switch?

@fei4xu fei4xu changed the title MSVC with MD? MSVC with "/MD"? Jul 17, 2019
@paulhoux paulhoux changed the title MSVC with "/MD"? MSVC with "/MD" when using CMake? Feb 12, 2020
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

No branches or pull requests

1 participant