Skip to content

Commit

Permalink
Win32: Fixed build and added DENG2_C_API_ONLY
Browse files Browse the repository at this point in the history
For C++ sources, the DENG2_C_API_ONLY define ensures that the C++ headers
are not included.
  • Loading branch information
skyjake committed May 23, 2012
1 parent a5875c3 commit 792cbd0
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 3 deletions.
4 changes: 2 additions & 2 deletions doomsday/libdeng2/include/de/libdeng2.h
Expand Up @@ -24,7 +24,7 @@
* @file libdeng2.h Common definitions for libdeng2.
*/

#ifdef __cplusplus
#if defined(__cplusplus) && !defined(DENG2_C_API_ONLY)
# define DENG2_USE_QT
#endif

Expand Down Expand Up @@ -98,7 +98,7 @@
#define DENG2_FOR_EACH(Iter, ContainerRef, IterClass) \
for(IterClass Iter = (ContainerRef).begin(); Iter != (ContainerRef).end(); ++Iter)

#ifdef __cplusplus
#if defined(__cplusplus) && !defined(DENG2_C_API_ONLY)
namespace de {

/**
Expand Down
2 changes: 2 additions & 0 deletions doomsday/plugins/directsound/src/driver_directsound.cpp
Expand Up @@ -44,7 +44,9 @@

#pragma warning (disable: 4035 4244)

#define DENG2_C_API_ONLY
#include <de/c_wrapper.h>

#include "doomsday.h"
#include "sys_audiod.h"
#include "sys_audiod_sfx.h"
Expand Down
4 changes: 3 additions & 1 deletion doomsday/plugins/winmm/src/dswinmm.cpp
Expand Up @@ -28,9 +28,11 @@

// HEADER FILES ------------------------------------------------------------

#include <math.h>
#define DENG2_C_API_ONLY
#include <de/c_wrapper.h>

#include <math.h>

#include "dswinmm.h"
#include "midistream.h"

Expand Down

0 comments on commit 792cbd0

Please sign in to comment.