From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 20067 invoked by alias); 30 Oct 2008 21:21:27 -0000 Received: (qmail 15922 invoked by uid 22791); 30 Oct 2008 21:19:35 -0000 X-Spam-Check-By: sourceware.org Received: from qmta08.emeryville.ca.mail.comcast.net (HELO QMTA08.emeryville.ca.mail.comcast.net) (76.96.30.80) by sourceware.org (qpsmtpd/0.31) with ESMTP; Thu, 30 Oct 2008 21:17:33 +0000 Received: from OMTA08.emeryville.ca.mail.comcast.net ([76.96.30.12]) by QMTA08.emeryville.ca.mail.comcast.net with comcast id Z04r1a0020FhH24A87VP8S; Thu, 30 Oct 2008 19:29:23 +0000 Received: from helium ([69.140.173.30]) by OMTA08.emeryville.ca.mail.comcast.net with comcast id Z7VL1a00Y0fipUd8U7VNm7; Thu, 30 Oct 2008 19:29:22 +0000 X-Authority-Analysis: v=1.0 c=1 a=DGBOHcsZmO3UW4apZzUA:9 a=S9ngF0l2z6OcoQQ9QMYA:7 a=POmzR6g3d54BawAcjaI8Emo-6zIA:4 a=MxZ3bB5I4kYA:10 Received: from helium ([127.0.0.1] helo=D77E1BASCHULMA1.aa.ad.epa.gov) by helium with smtp (Exim 4.69) (envelope-from ) id 1KvdCq-00083j-9v for cygwin-apps@cygwin.com; Thu, 30 Oct 2008 15:29:20 -0400 From: Andrew Schulman To: cygwin-apps@cygwin.com Subject: Re: cygport-0.9.3 in release-2 Date: Thu, 30 Oct 2008 21:21:00 -0000 Message-ID: References: <4906B2F8.4000708@users.sourceforge.net> <747eg4dsfpl4befpo8gb4qkgo3sm0d8fbi@4ax.com> <747eg4dsfpl4befpo8gb4qkgo3sm0d8fbi-e09XROE/p8c@public.gmane.org> <4907C0F1.2040005@cwilson.fastmail.fm> In-Reply-To: <4907C0F1.2040005@cwilson.fastmail.fm> X-Mailer: Forte Agent 4.2/32.1118 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: quoted-printable X-Archive: encrypt Mailing-List: contact cygwin-apps-help@cygwin.com; run by ezmlm Precedence: bulk Sender: cygwin-apps-owner@cygwin.com List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Mail-Followup-To: cygwin-apps@cygwin.com X-SW-Source: 2008-10/txt/msg00099.txt.bz2 > Andrew, please post one of your .cygports that actually requires the > src_prep_fini_hook(). I'd like to reach a resolution on this (these) > issues, so I can either drop the patches entirely or get some > replacement/reimplementation in cygport. OK, here's how I use it. Several of my packages require multiple patches to compile and run properly= in Cygwin. Instead of maintaining them all together as One Big Patch, I find = it easier to manage them as individual, discrete patch files, and apply them a= ll at package build time. I also have extra files, such as README and setup.hint, that I like to just= copy in before building, instead of maintaining them as patches. Again, this is easier for me in the long run. So, in general I include the following code in my .cygport files: src_prep_fini_hook () { cd "${top}" # copy in extra files if [ -d extras -a "$(ls extras)" ] ; then __step "Copying in extra files" cp -a extras/* "${S}" fi # apply patches if [ -d patches -a "$(ls patches | grep '\.patch$')" ] ; then __step "Applying patches" cd "${S}" cygpatch ${top}/patches/*.patch fi } The above is from screen-4.0.3-1.cygport. If there's a better way to do this, then I'm all ears. I hadn't thought of doing it during compile() but that seems fine. Note that the problem you mentioned of the patches being applied twice does= n't occur. If I'm building the packages, then the extras/ and patches/ directo= ries are present. Someone else who's building the binary package from source do= esn't have those directories, so there's no conflict. Thanks, Andrew.