Skip to content

Commit

Permalink
Fix Cygwin compile due to missing <signal.h>
Browse files Browse the repository at this point in the history
  • Loading branch information
noloader committed Oct 2, 2016
1 parent 856d3d5 commit e09d8a2
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 2 deletions.
4 changes: 4 additions & 0 deletions config.compat
Original file line number Diff line number Diff line change
Expand Up @@ -690,6 +690,10 @@ NAMESPACE_END
# define THREADS_AVAILABLE
#endif

#if defined(CRYPTOPP_BSD_AVAILABLE) || defined(CRYPTOPP_UNIX_AVAILABLE) || defined(__CYGWIN__)
# define UNIX_SIGNALS_AVAILABLE 1
#endif

#ifdef CRYPTOPP_WIN32_AVAILABLE
# if !defined(WINAPI_FAMILY)
# define HAS_WINTHREADS
Expand Down
4 changes: 4 additions & 0 deletions config.h
Original file line number Diff line number Diff line change
Expand Up @@ -690,6 +690,10 @@ NAMESPACE_END
# define THREADS_AVAILABLE
#endif

#if defined(CRYPTOPP_BSD_AVAILABLE) || defined(CRYPTOPP_UNIX_AVAILABLE) || defined(__CYGWIN__)
# define UNIX_SIGNALS_AVAILABLE 1
#endif

#ifdef CRYPTOPP_WIN32_AVAILABLE
# if !defined(WINAPI_FAMILY)
# define HAS_WINTHREADS
Expand Down
4 changes: 2 additions & 2 deletions ossig.h
Original file line number Diff line number Diff line change
Expand Up @@ -9,15 +9,15 @@

#include "config.h"

#if defined(CRYPTOPP_BSD_AVAILABLE) || defined(CRYPTOPP_UNIX_AVAILABLE)
#if defined(UNIX_SIGNALS_AVAILABLE)
# include <signal.h>
#endif

NAMESPACE_BEGIN(CryptoPP)

// ************** Unix and Linux compatibles ***************

#if defined(CRYPTOPP_BSD_AVAILABLE) || defined(CRYPTOPP_UNIX_AVAILABLE) || defined(CRYPTOPP_DOXYGEN_PROCESSING)
#if defined(UNIX_SIGNALS_AVAILABLE) || defined(CRYPTOPP_DOXYGEN_PROCESSING)

//! \brief Signal handler function pointer
//! \details SignalHandlerFn is provided as a stand alone function pointer with external "C" linkage
Expand Down
4 changes: 4 additions & 0 deletions stdcpp.h
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,10 @@ namespace std {
#include <mutex>
#endif

#if defined(CRYPTOPP_CXX11_RVALUES)
# include <utility>
#endif

#include <cstdlib>
#include <cstddef>
#include <cstring>
Expand Down

0 comments on commit e09d8a2

Please sign in to comment.