Skip to content

Commit

Permalink
Vutils
Browse files Browse the repository at this point in the history
  • Loading branch information
vic4key committed Oct 31, 2023
1 parent e813e52 commit e597f6e
Showing 1 changed file with 22 additions and 7 deletions.
29 changes: 22 additions & 7 deletions include/Vutils.h
Original file line number Diff line number Diff line change
Expand Up @@ -3686,20 +3686,35 @@ class Debouncer : public SingletonT<Debouncer>
#endif // VUTILS_H

/**
* Automatic linking Vutils library when compiler performs building
* Automatically linking Vutils library when compiler performs building
*/

#if !defined(Vutils_EXPORTS) && !defined(Vutils_SHOWN_LINKING)
#if defined(_MSC_VER) || defined(__BCPLUSPLUS__)

#if defined(_DLL) // MD & MDd
#ifdef _DEBUG // MDd
#pragma comment(lib, "Vutils-MDd.lib")
#define Vutils_LIB_NAME "Vutils-MDd.lib"
#else // MD
#pragma comment(lib, "Vutils-MD.lib")
#define Vutils_LIB_NAME "Vutils-MD.lib"
#endif // _DEBUG
#else // MT & MTd
#ifdef _DEBUG // MTd
#pragma comment(lib, "Vutils-MTd.lib")
#define Vutils_LIB_NAME "Vutils-MTd.lib"
#else // MT
#pragma comment(lib, "Vutils-MT.lib")
#define Vutils_LIB_NAME "Vutils-MT.lib"
#endif // _DEBUG
#endif
#endif // _DLL
#endif // _DLL
#pragma comment(lib, Vutils_LIB_NAME)

#if defined(_M_X64) || defined(__x86_64__) // 64-bit
#define Vutils_ARCH_NAME "64-bit"
#else // 32-bit
#define Vutils_ARCH_NAME "32-bit"
#endif // _M_X64 || __x86_64__

#pragma message("Automatically linking with Vutils library ('" Vutils_LIB_NAME "' " Vutils_ARCH_NAME ")")
#define Vutils_SHOWN_LINKING

#endif // _MSC_VER || __BCPLUSPLUS__
#endif // Vutils_EXPORTS

0 comments on commit e597f6e

Please sign in to comment.