diff --git a/lang/cpp/src/global.h b/lang/cpp/src/global.h index b48ec074..9be5202c 100644 --- a/lang/cpp/src/global.h +++ b/lang/cpp/src/global.h @@ -28,6 +28,7 @@ #include "gpgmepp_export.h" #include +#include namespace GpgME { @@ -152,4 +153,54 @@ GPGMEPP_EXPORT bool hasFeature(unsigned long feature, unsigned long feature2); operator unspecified_bool_type() const { return ( Cond ) ? &__safe_bool_dummy__::nonnull : 0 ; } # endif +inline int _gpgmepp_strcmp(const char *s1, const char *s2) +{ + return s1 ? s2 ? std::strcmp(s1, s2) : 1 : s2 ? -1 : 0; +} + +#define _GPGMEPP_MAKE_STRCMP( Name, expr, cmp ) \ + template