c++: Fix (some) solaris breakage

Solaris' sys/socket uses the poisoned bcopy identifier, so we must
preemptively copy a bit of cody's inclusion logic to get it earlier.

	gcc/cp/
	* mapper-client.cc: Include sys/socket.h before system.h.
This commit is contained in:
Nathan Sidwell 2020-12-16 05:10:16 -08:00
parent 1c4aefb681
commit 6ff747f023

View file

@ -19,6 +19,11 @@ along with GCC; see the file COPYING3. If not see
<http://www.gnu.org/licenses/>. */
#include "config.h"
#if defined (__unix__)
// Solaris11's socket header used bcopy, which we poison. cody.hh
// will include it later under the above check
#include <sys/socket.h>
#endif
#include "system.h"
#include "line-map.h"
@ -28,6 +33,10 @@ along with GCC; see the file COPYING3. If not see
#include "../../c++tools/resolver.h"
#if !HOST_HAS_O_CLOEXEC
#define O_CLOEXEC 0
#endif
module_client::module_client (pex_obj *p, int fd_from, int fd_to)
: Client (fd_from, fd_to), pex (p)
{