From 51197c0d6f6b2ea3aa857bed9b46bf0b64871a89 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Joakim=20So=CC=88derberg?= Date: Fri, 22 Feb 2013 09:28:13 +0800 Subject: [PATCH] Set the _DEBUG macro for CMake also. --- CMakeLists.txt | 6 ++++++ config.h.cmake | 4 ++++ 2 files changed, 10 insertions(+) diff --git a/CMakeLists.txt b/CMakeLists.txt index ab546a9f..3b507b44 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -104,6 +104,12 @@ if (WITHOUT_CLIENT) set(LWS_NO_CLIENT 1) endif() +if (WITHOUT_DEBUG) + set(_DEBUG 0) +else() + set(_DEBUG 1) +endif() + if (MINGW) set(LWS_MINGW_SUPPORT 1) endif() diff --git a/config.h.cmake b/config.h.cmake index 92882672..e55d7154 100644 --- a/config.h.cmake +++ b/config.h.cmake @@ -1,5 +1,9 @@ /* config.h.in. Generated from configure.ac by autoheader. */ +#ifndef WIN32 +#cmakedefine _DEBUG +#endif + /* Define to 1 to use CyaSSL as a replacement for OpenSSL. * LWS_OPENSSL_SUPPORT needs to be set also for this to work. */ #cmakedefine USE_CYASSL