From a9efaa00e87c37c2994e6db78bb0138326e83c60 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Peter=20K=C3=BCmmel?= Date: Sun, 2 Dec 2007 18:37:58 +0000 Subject: [PATCH] export when building vld git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@21927 a592a061-630c-0410-9148-cb99ea01b6c8 --- development/Win32/vld/include/vld.h | 19 +++++++++++-------- 1 file changed, 11 insertions(+), 8 deletions(-) diff --git a/development/Win32/vld/include/vld.h b/development/Win32/vld/include/vld.h index 66af3f0639..c6213de000 100644 --- a/development/Win32/vld/include/vld.h +++ b/development/Win32/vld/include/vld.h @@ -1,5 +1,4 @@ //////////////////////////////////////////////////////////////////////////////// -// $Id: vld.h,v 1.29 2006/11/18 03:12:35 dmouldin Exp $ // // Visual Leak Detector - Import Library Header // Copyright (c) 2006 Dan Moulding @@ -24,9 +23,11 @@ #pragma once -#ifndef VLD_BUILD +#ifdef VLD_BUILD +#define VLD_EXPORT __declspec(dllexport) +#else -#ifdef _DEBUG +#define VLD_EXPORT __declspec(dllimport) #pragma comment(lib, "vld.lib") @@ -35,6 +36,11 @@ // even if no code otherwise imports any of the DLL's exports. #pragma comment(linker, "/include:__imp_?vld@@3VVisualLeakDetector@@A") +#endif + + +#ifdef _DEBUG + //////////////////////////////////////////////////////////////////////////////// // // Visual Leak Detector APIs @@ -64,7 +70,7 @@ extern "C" { // // None. // -__declspec(dllimport) void VLDDisable (); +VLD_EXPORT void VLDDisable (); // VLDEnable - Enables Visual Leak Detector's memory leak detection at runtime. // If memory leak detection is already enabled, which it is by default, then @@ -86,7 +92,7 @@ __declspec(dllimport) void VLDDisable (); // // None. // -__declspec(dllimport) void VLDEnable (); +VLD_EXPORT void VLDEnable (); #ifdef __cplusplus } @@ -98,6 +104,3 @@ __declspec(dllimport) void VLDEnable (); #define VLDDisable() #endif // _DEBUG - -#endif //VLD_BUILD -