Skip to content

Commit a481201

Browse files
committed
Readd some overzealously removed code
1 parent 9704ced commit a481201

File tree

4 files changed

+17
-21
lines changed

4 files changed

+17
-21
lines changed

include/json/autolink.h

Lines changed: 0 additions & 19 deletions
This file was deleted.

include/json/config.h

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,22 @@
3030
/// Remarks: it is automatically defined in the generated amalgamated header.
3131
// #define JSON_IS_AMALGAMATION
3232

33+
// Export macros for DLL visibility
34+
#if defined(JSON_DLL_BUILD)
35+
#if defined(_MSC_VER) || defined(__MINGW32__)
36+
#define JSON_API __declspec(dllexport)
37+
#define JSONCPP_DISABLE_DLL_INTERFACE_WARNING
38+
#elif defined(__GNUC__) || defined(__clang__)
39+
#define JSON_API __attribute__((visibility("default")))
40+
#endif // if defined(_MSC_VER)
41+
42+
#elif defined(JSON_DLL)
43+
#if defined(_MSC_VER) || defined(__MINGW32__)
44+
#define JSON_API __declspec(dllimport)
45+
#define JSONCPP_DISABLE_DLL_INTERFACE_WARNING
46+
#endif // if defined(_MSC_VER)
47+
#endif // ifdef JSON_DLL_BUILD
48+
3349
#if !defined(JSON_API)
3450
#define JSON_API
3551
#endif

include/json/json.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
#ifndef JSON_JSON_H_INCLUDED
77
#define JSON_JSON_H_INCLUDED
88

9-
#include "autolink.h"
9+
#include "config.h"
1010
#include "json_features.h"
1111
#include "reader.h"
1212
#include "value.h"

meson.build

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,6 @@ project(
2121
jsoncpp_headers = [
2222
'include/json/allocator.h',
2323
'include/json/assertions.h',
24-
'include/json/autolink.h',
2524
'include/json/config.h',
2625
'include/json/json_features.h',
2726
'include/json/forwards.h',

0 commit comments

Comments
 (0)