cmake: avoid security warnings under msvc
fopen, sscanf are error checked and only used in the examples. this matches Makefile.vc. Change-Id: I411c3ace6b5db092656d6b03dc5b438bd70616fc
This commit is contained in:
parent
650eac5542
commit
80285d97ad
@ -103,7 +103,10 @@ endforeach()
|
|||||||
|
|
||||||
### Define the mandatory libraries.
|
### Define the mandatory libraries.
|
||||||
# Build the webpdecoder library.
|
# Build the webpdecoder library.
|
||||||
if(NOT MSVC)
|
if(MSVC)
|
||||||
|
# avoid security warnings for e.g., fopen() used in the examples.
|
||||||
|
add_definitions(-D_CRT_SECURE_NO_WARNINGS)
|
||||||
|
else()
|
||||||
add_definitions(-Wall)
|
add_definitions(-Wall)
|
||||||
endif()
|
endif()
|
||||||
include_directories(${CMAKE_CURRENT_SOURCE_DIR} ${WEBP_DEP_INCLUDE_DIRS})
|
include_directories(${CMAKE_CURRENT_SOURCE_DIR} ${WEBP_DEP_INCLUDE_DIRS})
|
||||||
|
Loading…
x
Reference in New Issue
Block a user