From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on inbox.vuxu.org X-Spam-Level: X-Spam-Status: No, score=-1.0 required=5.0 tests=MAILING_LIST_MULTI, RCVD_IN_DNSWL_NONE autolearn=ham autolearn_force=no version=3.4.2 Received: from primenet.com.au (ns1.primenet.com.au [203.24.36.2]) by inbox.vuxu.org (OpenSMTPD) with ESMTP id 8b066b53 for ; Mon, 26 Aug 2019 04:30:42 +0000 (UTC) Received: (qmail 14764 invoked by alias); 26 Aug 2019 04:30:33 -0000 Mailing-List: contact zsh-workers-help@zsh.org; run by ezmlm Precedence: bulk X-No-Archive: yes List-Id: Zsh Workers List List-Post: List-Help: List-Unsubscribe: X-Seq: 44709 Received: (qmail 15120 invoked by uid 1010); 26 Aug 2019 04:30:33 -0000 X-Qmail-Scanner-Diagnostics: from rcpt-expgw.biglobe.ne.jp by f.primenet.com.au (envelope-from , uid 7791) with qmail-scanner-2.11 (clamdscan: 0.101.2/25552. spamassassin: 3.4.2. Clear:RC:0(133.208.98.4):SA:0(-2.6/5.0):. Processed in 2.362556 secs); 26 Aug 2019 04:30:33 -0000 X-Envelope-From: takimoto-j@kba.biglobe.ne.jp X-Qmail-Scanner-Mime-Attachments: | X-Qmail-Scanner-Zip-Files: | Received-SPF: pass (ns1.primenet.com.au: SPF record at spf01.biglobe.ne.jp designates 133.208.98.4 as permitted sender) X-Biglobe-Sender: From: Jun T Content-Type: multipart/alternative; boundary="Apple-Mail=_62E4CA7F-3213-47D7-94D7-F23EB2E74586" Mime-Version: 1.0 (Mac OS X Mail 12.4 \(3445.104.11\)) Subject: [PATCH] include sys/capability.h only if HAVE_CAP_GET_PROC is defined Message-Id: Date: Mon, 26 Aug 2019 13:29:55 +0900 To: zsh-workers@zsh.org X-Mailer: Apple Mail (2.3445.104.11) X-Biglobe-Spnum: 39642 --Apple-Mail=_62E4CA7F-3213-47D7-94D7-F23EB2E74586 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=us-ascii I'm getting the following warnings on FreeBSD-12.0: In file included from ./zsh_system.h:526: /usr/include/sys/capability.h:43:2: warning: this file includes = which is deprecated FreeBSD has sys/capability.h (deprecated and should be replaced by sys/capsicum.h) but it has nothing to do with libcap. I believe we need to include sys/capability.h only if HAVE_CAP_GET_PROC is defined. diff --git a/Src/zsh_system.h b/Src/zsh_system.h index e7d529b6e..85e198f2e 100644 --- a/Src/zsh_system.h +++ b/Src/zsh_system.h @@ -522,7 +522,7 @@ struct timespec { # define RLIMIT_VMEM RLIMIT_AS #endif =20 -#ifdef HAVE_SYS_CAPABILITY_H +#if defined(HAVE_SYS_CAPABILITY_H) && defined(HAVE_CAP_GET_PROC) # include #endif =20 --Apple-Mail=_62E4CA7F-3213-47D7-94D7-F23EB2E74586--