This commit is contained in:
r.koeppe
2024-05-14 02:14:13 +02:00
parent 0052d3984b
commit 2d22ccd2d6
1423 changed files with 354055 additions and 7 deletions

View File

@ -0,0 +1,37 @@
#ifndef _VN_UTIL_COMPILER_H
#define _VN_UTIL_COMPILER_H
/* This header provides some simple checks for various features supported by the
* current compiler. */
/* Determine the level of standard C support. */
#if __STDC__
#if defined (__STDC_VERSION__)
#if (__STDC_VERSION__ >= 199901L)
#define C99
#endif
#endif
#endif
/* Determine if the compiler has stdbool.h. */
#if defined(C99) || _MSC_VER >= 1800
#define VN_HAVE_STDBOOL_H 1
#else
#define VN_HAVE_STDBOOL_H 0
#endif
/* Determine if the secure CRT is available. */
#if defined(_MSC_VER)
#define VN_HAVE_SECURE_CRT 1
#else
#define VN_HAVE_SECURE_CRT 0
#endif
#endif
/* Determine if the generic type math library (tgmath.h) is available. */
#if defined(C99)
#define VN_HAVE_GENERIC_TYPE_MATH 1
#else
#define VN_HAVE_GENERIC_TYPE_MATH 0
#endif

View File

@ -0,0 +1,16 @@
#ifndef VNEXPORT_H_INCLUDED
#define VNEXPORT_H_INCLUDED
/* Not only does this have to be windows to use __declspec */
/* it also needs to actually be outputting a DLL */
#if defined _WINDOWS && defined _WINDLL
#if proglib_c_EXPORTS
#define DllExport __declspec(dllexport)
#else
#define DllExport __declspec(dllimport)
#endif
#else
#define DllExport
#endif
#endif

View File

@ -0,0 +1,19 @@
#ifndef VNPORT_H_INCLUDED
#define VNPORT_H_INCLUDED
/** Basic portability measures. */
/** VNAPI - DLL linkage specifier. */
#ifdef _MSC_VER
#if VN_LINKED_AS_SHARED_LIBRARY
#define VNAPI __declspec(dllimport)
#elif VN_CREATE_SHARED_LIBRARY
#define VNAPI __declspec(dllexport)
#endif
#endif
#ifndef VNAPI
#define VNAPI
#endif
#endif