This patch should enable building on OpenBSD 5.4.
- added a processinfo implementation based heavily off of the same
code for freebsd.
- fixed a few scons problems in mongo and v8
- added __openbsd__ directives to s2 build
- Don't disturb bswap() functions on freebsd.
- Fixed indentation sloppiness. No code changes.
Signed-off-by: Mark Benvenuto <mark.benvenuto@mongodb.com>
The following change was backported:
https://code.google.com/p/gperftools/source/detail?r=18fbc316eebea9db2d7ec41e161c0a3fbb09fa42
Another change we wanted was:
https://code.google.com/p/gperftools/source/detail?r=6287bbbbad8730712cfd1ee28ecc0648cbaa9f94#
However, since that patch must hit every PR/SC instance and the code has evolved from that point
we instead just ran the following two scripts over the gperftools source tree:
find . -type f | xargs egrep -l '"PR\w+"' | xargs perl -pi -e 's|"PR(\w+)"|" PR\1 "|g'
find . -type f | xargs egrep -l '"SC\w+"' | xargs perl -pi -e 's|"SC(\w+)"|" SC\1 "|g'
and then manually fixing up the one reference to GPRIuPTHREAD, which achieved the same result.
Finally, remove the logic preventing mixture of C++11 and gperftools from the build system.
This also opens the exciting possibility of displaying the base address
of the file containing the address, which would let us dump stacks when
ASLR is in use. However, this implementation preserves the format used
in the Linux backtrace_symbols() implementation.
The MongoDB C++ client driver now resides in a separate repo and is maintained
independently of the server. The targets in this repo that used to build or test
the driver will now print an error message explaining the change and referring
users to the relevant documentation.
- We want to use whatever compiler SCons tooling picks now that we support clang.
- /usr/64 isn't a thing on modern Darwin (at least since 10.6, which is our minimum)
- It probably never made sense to look in /usr/64/include for anything
- If you want to use MacPorts, use --extrapath=/opt/local, similar for Fink
Introduce new flags --dbg and --opt which permit independent control over optimization and
debugging. The old --d, --dd, and --release flags were not independent, and had surprising
interactions, particularly on Windows.
The old flags are still supported in a legacy mode for --d and --dd builds, cannot be mixed
with the new.
For builds specifying none of --dbg, --opt, --d, or --dd, there should be no behavior change,
except on Windows. On that platform, a no-flags-specified build will now default to
optimization enabled, whereas before it did not.
Do not make direct calls to backtrace, backtrace_symbols or backtrace_symbols_fd,
which are present in Solaris 11 but not in Solaris 10. Instead, see if they are
available in a loaded library (which will be libc.so.1) at runtime and either
call them or call an emulation.