Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion SConstruct
Original file line number Diff line number Diff line change
Expand Up @@ -1368,7 +1368,7 @@ if env['_LIBDEPS'] == '$_LIBDEPS_LIBS':
# toolchain, or may be using it for the archiver but not the
# linker, and binutils currently is the olny thing that supports
# thin archives. Don't even try on those platforms.
if not env.TargetOSIs('solaris', 'darwin', 'windows'):
if not env.TargetOSIs('solaris', 'darwin', 'windows', 'openbsd'):
env.Tool('thin_archive')

if env.TargetOSIs('linux', 'freebsd', 'openbsd'):
Expand Down
2 changes: 1 addition & 1 deletion src/mongo/crypto/sha_block_openssl.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@
#include <openssl/hmac.h>
#include <openssl/sha.h>

#if OPENSSL_VERSION_NUMBER < 0x10100000L
#if OPENSSL_VERSION_NUMBER < 0x10100000L || defined(LIBRESSL_VERSION_NUMBER)
namespace {
// Copies of OpenSSL after 1.1.0 define new EVP digest routines. We must
// polyfill used definitions to interact with older OpenSSL versions.
Expand Down
1 change: 1 addition & 0 deletions src/mongo/platform/stack_locator_openbsd.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@

#include "mongo/platform/stack_locator.h"

#include <pthread.h>
#include <pthread_np.h>
#include <sys/signal.h>

Expand Down
2 changes: 1 addition & 1 deletion src/mongo/util/net/ssl_manager.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -227,7 +227,7 @@ IMPLEMENT_ASN1_ENCODE_FUNCTIONS_const_fname(ASN1_SEQUENCE_ANY, ASN1_SET_ANY, ASN
#endif // MONGO_CONFIG_NEEDS_ASN1_ANY_DEFINITIONS
// clang-format on

#if OPENSSL_VERSION_NUMBER < 0x10100000L
#if OPENSSL_VERSION_NUMBER < 0x10100000L || defined(LIBRESSL_VERSION_NUMBER)
// Copies of OpenSSL after 1.1.0 define new functions for interaction with
// X509 structure. We must polyfill used definitions to interact with older
// OpenSSL versions.
Expand Down
8 changes: 8 additions & 0 deletions src/mongo/util/processinfo_openbsd.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -208,4 +208,12 @@ bool ProcessInfo::pagesInMemory(const void* start, size_t numPages, vector<char>
}
return true;
}

// get the number of CPUs available to the scheduler
boost::optional<unsigned long> ProcessInfo::getNumAvailableCores() {
long nprocs = sysconf(_SC_NPROCESSORS_ONLN);
if (nprocs)
return nprocs;
return boost::none;
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ typedef BID_UINT128 _Quad;
#define SQRT80 sqrtl
#else
#define BINARY80 __float80
//#define BINARY128 __float128
//#define BINARY128 __float128
#define BINARY128 BID_UINT128
#define SQRT80 sqrtw
#endif
Expand Down Expand Up @@ -159,7 +159,7 @@ typedef unsigned long fexcept_t;
typedef unsigned bid__int64 fexcept_t;
#endif
#else
#ifdef __QNX__
#if defined(__QNX__) || defined(__OpenBSD__)
#include <fenv.h>
#else
typedef unsigned short int fexcept_t;
Expand Down