diff options
author | Jack Lloyd <[email protected]> | 2019-08-06 03:39:49 -0400 |
---|---|---|
committer | Jack Lloyd <[email protected]> | 2019-09-06 07:04:46 -0400 |
commit | d187ddcaebe11a324f0efb20eb67a842929adc6f (patch) | |
tree | a8ec6b1076eff60f7475dd7a904a1934192fcf10 /src/lib/utils/compiler.h | |
parent | cc6b42d71b0cdc2ebfa2b33b5039991f2d79f606 (diff) |
Deprecate many publically available headers
Diffstat (limited to 'src/lib/utils/compiler.h')
-rw-r--r-- | src/lib/utils/compiler.h | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/src/lib/utils/compiler.h b/src/lib/utils/compiler.h index 2da40b665..a38bffb5d 100644 --- a/src/lib/utils/compiler.h +++ b/src/lib/utils/compiler.h @@ -103,14 +103,26 @@ #define BOTAN_DEPRECATED(msg) __attribute__ ((deprecated)) #define BOTAN_DEPRECATED_HEADER(hdr) _Pragma("message \"this header is deprecated\"") + #if !defined(BOTAN_IS_BEING_BUILT) + #define BOTAN_FUTURE_INTERNAL_HEADER(hdr) _Pragma("message \"this header will be made internal in the future\"") + #endif + #elif defined(_MSC_VER) #define BOTAN_DEPRECATED(msg) __declspec(deprecated(msg)) #define BOTAN_DEPRECATED_HEADER(hdr) __pragma("message \"this header is deprecated\"") + #if !defined(BOTAN_IS_BEING_BUILT) + #define BOTAN_FUTURE_INTERNAL_HEADER(hdr) __pragma("message \"this header will be made internal in the future\"") + #endif + #elif defined(__GNUC__) /* msg supported since GCC 4.5, earliest we support is 4.8 */ #define BOTAN_DEPRECATED(msg) __attribute__ ((deprecated(msg))) #define BOTAN_DEPRECATED_HEADER(hdr) _Pragma("GCC warning \"this header is deprecated\"") + + #if !defined(BOTAN_IS_BEING_BUILT) + #define BOTAN_FUTURE_INTERNAL_HEADER(hdr) _Pragma("GCC warning \"this header will be made internal in the future\"") + #endif #endif #endif @@ -123,6 +135,10 @@ #define BOTAN_DEPRECATED_HEADER(hdr) #endif +#if !defined(BOTAN_FUTURE_INTERNAL_HEADER) + #define BOTAN_FUTURE_INTERNAL_HEADER(hdr) +#endif + /* * Define BOTAN_NORETURN */ |