From patchwork Sun Dec 9 18:49:14 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: [libbacktrace] Fix build on hpux10 Date: Sun, 09 Dec 2012 08:49:14 -0000 From: John David Anglin X-Patchwork-Id: 204771 Message-Id: <20121209184914.GA20230@hiauly1.hia.nrc.ca> To: gcc-patches@gcc.gnu.org HP-UX 10 doesn't define MAP_FAILED. Patch fixes build. Tested on hppa1.1-hp-hpux10.20 and hppa2.0w-hp-hpux11.11. OK for trunk? Dave Index: mmapio.c =================================================================== --- mmapio.c (revision 194272) +++ mmapio.c (working copy) @@ -40,6 +40,10 @@ #include "backtrace.h" #include "internal.h" +#ifndef MAP_FAILED +#define MAP_FAILED ((void *)-1) +#endif + /* This file implements file views and memory allocation when mmap is available. */