diff --git a/CMakeLists.txt b/CMakeLists.txt index c524f167..e656184d 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -163,6 +163,9 @@ endif() if(USE_OPENSSL_MD5) list(APPEND LXW_PRIVATE_COMPILE_DEFINITIONS USE_OPENSSL_MD5) + if(NOT MSVC) + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-deprecated-declarations") + endif() endif() if(USE_MEM_FILE OR USE_FMEMOPEN) diff --git a/src/Makefile b/src/Makefile index 5caba2bc..a273fd32 100644 --- a/src/Makefile +++ b/src/Makefile @@ -49,7 +49,7 @@ ifdef USE_NO_MD5 CFLAGS += -DUSE_NO_MD5 else ifdef USE_OPENSSL_MD5 -CFLAGS += -DUSE_OPENSSL_MD5 +CFLAGS += -DUSE_OPENSSL_MD5 -Wno-deprecated-declarations LIBS += -lcrypto else # Use md5 (the default).