From a7a04d7af5bf0009919935d834849da543f5ab32 Mon Sep 17 00:00:00 2001 From: Andre Caron Date: Mon, 13 Oct 2014 15:01:24 -0400 Subject: [PATCH] Changes DLL_EXPORT to SODIUM_DLL_EXPORT. This macro conflicts with other projects. This results in the inability to build one DLL that depends on libsodium if the other DLL also uses the DLL_EXPORT macro to control visibility of library symbols. Since the choice of name for this macro is arbitrary, use of a library prefix is preferred. --- builds/msvc/vs2010/libsodium/libsodium.props | 2 +- builds/msvc/vs2012/libsodium/libsodium.props | 2 +- builds/msvc/vs2013/libsodium/libsodium.props | 2 +- src/libsodium/include/sodium/export.h | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/builds/msvc/vs2010/libsodium/libsodium.props b/builds/msvc/vs2010/libsodium/libsodium.props index 7e9bca4f..0afdec61 100644 --- a/builds/msvc/vs2010/libsodium/libsodium.props +++ b/builds/msvc/vs2010/libsodium/libsodium.props @@ -25,7 +25,7 @@ false inline=__inline;NATIVE_LITTLE_ENDIAN;_CRT_SECURE_NO_WARNINGS;%(PreprocessorDefinitions) SODIUM_STATIC;%(PreprocessorDefinitions) - DLL_EXPORT;%(PreprocessorDefinitions) + SODIUM_DLL_EXPORT;%(PreprocessorDefinitions) HAVE_AMD64_ASM;%(PreprocessorDefinitions) diff --git a/builds/msvc/vs2012/libsodium/libsodium.props b/builds/msvc/vs2012/libsodium/libsodium.props index 7e9bca4f..0afdec61 100644 --- a/builds/msvc/vs2012/libsodium/libsodium.props +++ b/builds/msvc/vs2012/libsodium/libsodium.props @@ -25,7 +25,7 @@ false inline=__inline;NATIVE_LITTLE_ENDIAN;_CRT_SECURE_NO_WARNINGS;%(PreprocessorDefinitions) SODIUM_STATIC;%(PreprocessorDefinitions) - DLL_EXPORT;%(PreprocessorDefinitions) + SODIUM_DLL_EXPORT;%(PreprocessorDefinitions) HAVE_AMD64_ASM;%(PreprocessorDefinitions) diff --git a/builds/msvc/vs2013/libsodium/libsodium.props b/builds/msvc/vs2013/libsodium/libsodium.props index 7e9bca4f..0afdec61 100644 --- a/builds/msvc/vs2013/libsodium/libsodium.props +++ b/builds/msvc/vs2013/libsodium/libsodium.props @@ -25,7 +25,7 @@ false inline=__inline;NATIVE_LITTLE_ENDIAN;_CRT_SECURE_NO_WARNINGS;%(PreprocessorDefinitions) SODIUM_STATIC;%(PreprocessorDefinitions) - DLL_EXPORT;%(PreprocessorDefinitions) + SODIUM_DLL_EXPORT;%(PreprocessorDefinitions) HAVE_AMD64_ASM;%(PreprocessorDefinitions) diff --git a/src/libsodium/include/sodium/export.h b/src/libsodium/include/sodium/export.h index 32d9fa18..53fcd7b5 100644 --- a/src/libsodium/include/sodium/export.h +++ b/src/libsodium/include/sodium/export.h @@ -13,7 +13,7 @@ # define SODIUM_EXPORT #else # if defined(_MSC_VER) -# ifdef DLL_EXPORT +# ifdef SODIUM_DLL_EXPORT # define SODIUM_EXPORT __declspec(dllexport) # else # define SODIUM_EXPORT __declspec(dllimport)