From patchwork Sun Dec 9 18:49:14 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: John David Anglin X-Patchwork-Id: 204771 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) by ozlabs.org (Postfix) with SMTP id A18252C01FB for ; Mon, 10 Dec 2012 05:49:27 +1100 (EST) Comment: DKIM? See http://www.dkim.org DKIM-Signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d=gcc.gnu.org; s=default; x=1355683769; h=Comment: DomainKey-Signature:Received:Received:Received:Received:Date: From:To:Subject:Message-ID:Reply-To:MIME-Version:Content-Type: Content-Disposition:User-Agent:Mailing-List:Precedence:List-Id: List-Unsubscribe:List-Archive:List-Post:List-Help:Sender: Delivered-To; bh=anM3B/cPL7PfzZxfLYNXUkxgF7g=; b=DCIa1s8U9XgL5K8 qLZNI9s63ume6iDeweNIxMzyEc0sanrTfTzVQnratMi05wT7d5gT4UfJQrcD5nLQ QMJ0iqJRVb1gbOj+5e2ye2S0x4BJ2KAdL8L15HyCmjkuSLwGBiOp+y3+Lr3aqTp4 mxh6GZLfOcF5muNII3PuTsLO6V44= Comment: DomainKeys? See http://antispam.yahoo.com/domainkeys DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=default; d=gcc.gnu.org; h=Received:Received:X-SWARE-Spam-Status:X-Spam-Check-By:Received:Received:Date:From:To:Subject:Message-ID:Reply-To:MIME-Version:Content-Type:Content-Disposition:User-Agent:Mailing-List:Precedence:List-Id:List-Unsubscribe:List-Archive:List-Post:List-Help:Sender:Delivered-To; b=Vicm2mJmqmI/4O63hztfRT1roatwUvmwuCubg8WECRavkVmhmWfqlvIMSPsQ9W otoEWlXJBdvE8zIWazShiVRWSLIzTHPo1skEENfBYPu+/vmC4L2uZea5aBvvp+fN 9g1pNQhQ4V9jWuftC/N4Lj/06m5mpR57aIX2Nw663eYw0=; Received: (qmail 16325 invoked by alias); 9 Dec 2012 18:49:24 -0000 Received: (qmail 16315 invoked by uid 22791); 9 Dec 2012 18:49:23 -0000 X-SWARE-Spam-Status: No, hits=-2.0 required=5.0 tests=AWL, BAYES_00, RP_MATCHES_RCVD X-Spam-Check-By: sourceware.org Received: from hiauly1.hia.nrc.ca (HELO hiauly1.hia.nrc.ca) (132.246.10.84) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Sun, 09 Dec 2012 18:49:17 +0000 Received: by hiauly1.hia.nrc.ca (Postfix, from userid 1000) id E971C4D18; Sun, 9 Dec 2012 13:49:15 -0500 (EST) Date: Sun, 9 Dec 2012 13:49:14 -0500 From: John David Anglin To: gcc-patches@gcc.gnu.org Subject: [PATCH, libbacktrace] Fix build on hpux10 Message-ID: <20121209184914.GA20230@hiauly1.hia.nrc.ca> Reply-To: John David Anglin MIME-Version: 1.0 Content-Disposition: inline User-Agent: Mutt/1.5.16 (2007-06-09) Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Delivered-To: mailing list 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. */