X-Recipient: archive-cygwin AT delorie DOT com DomainKey-Signature: a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:content-type:mime-version:subject:from :in-reply-to:date:content-transfer-encoding:message-id :references:to; q=dns; s=default; b=KMssZpbPV6dd9OnUSnMrxIAlMrSE 3r63ytYzK/v4tshDO1xBAm51UEPl7Kkre+WkcuhQs0i8IWbskfu9nsmhT7be52OE 7fFxassuSvSbnd1h52dTiZS7XEXyWOk8IM7BdIVCT0TS/HPYh9Y0uOgh7E1QJyAp dv4K4V5DKNv7Ujk= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:content-type:mime-version:subject:from :in-reply-to:date:content-transfer-encoding:message-id :references:to; s=default; bh=7hHj27yqhNOQW/4oWeNE3OQrZKI=; b=Tm tIbvxsVZjJftCVOUQXa7teD1DG5DClnWxtasphRC4nRK99dlfOPgEBx3NJjMpXoj zAJWlfkpWXSJ9cYdohp+RvEiQEB20GrEwfhj0cHhLJ3IBEdjYyh11DSieiJmSD3b 8+14OHgIt8UWcBKHs1brflHoLYgVu2sMN6spBhrfc= Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com Delivered-To: mailing list cygwin AT cygwin DOT com Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=0.8 required=5.0 tests=AWL,BAYES_05,KAM_LAZY_DOMAIN_SECURITY,RP_MATCHES_RCVD autolearn=no version=3.3.2 spammy=H*i:sk:CAFo71_, H*MI:sk:56B8C25, H*i:Bx_bvbzGvVCs, H*i:sk:jj4r9Ax X-HELO: etr-usa.com Content-Type: text/plain; charset=utf-8 Mime-Version: 1.0 (Mac OS X Mail 8.2 \(2104\)) Subject: Re: Problem with new acl code and cdrtools From: Warren Young In-Reply-To: Date: Mon, 8 Feb 2016 21:14:10 -0700 Message-Id: References: <20160208131835 DOT GC12975 AT calimero DOT vinschen DOT de> <56B8C25F DOT 7050206 AT lysator DOT liu DOT se> To: The Cygwin Mailing List X-IsSubscribed: yes Content-Transfer-Encoding: 8bit X-MIME-Autoconverted: from quoted-printable to 8bit by delorie.com id u194EPYB016613 On Feb 8, 2016, at 9:59 AM, Ismail Donmez wrote: > > On Mon, Feb 8, 2016 at 6:29 PM, Peter Rosin wrote: >> On 2016-02-08 14:31, Ismail Donmez wrote: >>> This is a generic code so I don't want to add a cygwin specific >>> dependency there. Is there a preprocessor definition for cygwin >>> version? I could use that to disable HAVE_SUN_ACL for cygwin 2.5+ >> >> Pardon me for butting in, but isn't adding a Cygwin version check >> about as non-generic as it gets? >> >> Wouldn't something like this work: >> >> .../configure ac_cv_func_aclfromtext=no > > Thats a hack :) I don’t know if that smiley means you’re joking or if you’re just trying to soften a negative judgement, but Peter’s proposal is as far from a hack as it gets. He is proposing that you write an autoconf test that determines if the platform has this new ACL behavior. Then in your C code: #include #if HAVE_FUNC_ACLFROMTEXT # include #endif Now you’re not dependent on Cygwin header file #defines that don’t exist yet, and will continue to not exist on older Cygwin installs. You only include the Cygwin header if your autoconf test determines that this is necessary. This is standard Autoconf practice: check for features, not for platforms or platform versions. This practice comes from 40+ years of Unix portability experience, which is that platform and version tests often break, but feature tests rarely do. -- Problem reports: http://cygwin.com/problems.html FAQ: http://cygwin.com/faq/ Documentation: http://cygwin.com/docs.html Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple