From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from pigeon.gentoo.org ([208.92.234.80] helo=lists.gentoo.org) by finch.gentoo.org with esmtp (Exim 4.60) (envelope-from ) id 1OUOgo-0004VN-Oq for garchives@archives.gentoo.org; Thu, 01 Jul 2010 18:40:47 +0000 Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id C4C2CE08CD; Thu, 1 Jul 2010 18:40:21 +0000 (UTC) Received: from mail-bw0-f53.google.com (mail-bw0-f53.google.com [209.85.214.53]) by pigeon.gentoo.org (Postfix) with ESMTP id 7D486E08CD for ; Thu, 1 Jul 2010 18:40:21 +0000 (UTC) Received: by bwz6 with SMTP id 6so1283171bwz.40 for ; Thu, 01 Jul 2010 11:40:20 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:received:in-reply-to :references:date:message-id:subject:from:to:content-type; bh=YynWsgf9Z8BDdMiWmtxxxa4fyDulU44a5YFd9gI0sZ8=; b=bIoZFG8aV7s8e1OD/Un4rvEEO6QI2QrJVWgbIx4lFwbYafeaCR7NwLV5wtIWCPU/6c BF1QxiMtMQWcO1fu64L2u5RBoPHpiqKnPOCS7Z1Pw5imB/i7K13HU1jv6+haPVYWhJs1 c4YVYDtDBoqdKKQgPq8KG6rm1GC/HRiXIsesk= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type; b=LNMqntAgTaDWAAXzkuaN4M3zV/2eRV3s53F4EoElSqKTE1/25OKMbIY3qIqHTssjqv EEKMvL6W2eEwaect2GQjxXL1iJTbs2nK1nUJgoFsmS403bZQXyiMjp1LiRsE7+OzBiMv WDGFyaZdWRF8k/P5TPkt/owDYHSrikPdQHfsU= Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-user@lists.gentoo.org Reply-to: gentoo-user@lists.gentoo.org MIME-Version: 1.0 Received: by 10.204.139.218 with SMTP id f26mr7749272bku.180.1278009620195; Thu, 01 Jul 2010 11:40:20 -0700 (PDT) Received: by 10.204.160.138 with HTTP; Thu, 1 Jul 2010 11:40:20 -0700 (PDT) In-Reply-To: References: <4C2BDD7C.2010406@gmail.com> Date: Thu, 1 Jul 2010 21:40:20 +0300 Message-ID: Subject: Re: [gentoo-user] Re: Patch via perl script in an ebuild? From: "Arttu V." To: gentoo-user@lists.gentoo.org Content-Type: text/plain; charset=ISO-8859-1 X-Archives-Salt: ab70badf-60e8-46f6-b0c6-1ca59a6f782e X-Archives-Hash: 6e4ce743a954ecd72b55c13ab16082e6 On 7/1/10, Grant wrote: > Thank you Arttu. Here is the link to the SOAP::WSDL: > > http://soap-wsdl.svn.sourceforge.net/viewvc/soap-wsdl/SOAP-WSDL/branches/Typemap.tar.gz?view=tar&pathrev=846 > > from the README: > > http://code.google.com/p/google-api-adwords-perl/source/browse/trunk/README Ok, I see they're shipping the same version which is available from CPAN as the dev version (2.00.99_3). But the patch is still not made for its code ... maybe it is for _2 or _1? The patch keeps failing out of the box: cpan -i Text::Patch tar xvzf Typemap.tar.gz tar xvzf awapi_perl_lib_1.3.2.tar.gz ~/tempski $ awapi_perl_lib_1.3.2/bin/soap_wsdl_patches.pl Typemap Trying to patch Typemap/lib/SOAP/WSDL/Generator/Template/XSD/Interface/POD/Operation.tt... patch successful. Trying to patch Typemap/lib/SOAP/WSDL/Generator/Template/XSD/Server.tt... patch successful. Trying to patch Typemap/lib/SOAP/WSDL/Generator/Template/Plugin/XSD.pm... patch successful. Trying to patch Typemap/lib/SOAP/WSDL/XSD/Typelib/Builtin/anyType.pm... patch successful. Trying to patch Typemap/lib/SOAP/WSDL/XSD/Typelib/ComplexType.pm...Hunk #2 failed at line 425. ~/tempski $ Anyway, only three files' small chunks fail from the patch, and they're short and mostly just semantically adding some formerly non-existent subroutines and changing the return values of others. I think with some manual labour we could turn that patch into a fixed regular patch, which we could then apply in an ebuild for SOAP::WSDL via a USE flag. For example, something along these lines for dev-perl/SOAP-WSDL-2.00.99.3.ebuild (licenses etc might be wrong): # Copyright 1999-2010 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 # $Header: $ EAPI=2 MODULE_AUTHOR=MKUTTER MY_P="${P:0:17}_3" inherit eutils perl-module DESCRIPTION="SOAP::WSDL module" LICENSE="Artistic" SLOT="0" KEYWORDS="amd64 x86" IUSE="adwords" src_prepare() { perl-module_src_prepare use adwords && epatch "${FILESDIR}/${PV}-adwords.patch" } This SOAP-WSDL package could then in turn be made a dependency for your real google-adwords package (dev-perl/Google-Adwords?): RDEPENDS="dev-perl/SOAP-WSDL[adwords]" Am I making any sense? Theoretically (if you insist), you could still use the perl's Text::Patch route as well, but (if I'm not entirely wrong, see the excerpted attempted patch run above) the patch would still need to be touched up to match properly with the _3 dev release code. And it would add a dependency to Text::Patch, and make an odd call to perl in the middle of the ebuild. (I assume it must be made explicitly as I don't know if perl-module.eclass has any automation for this. Probably not since AFAICT Text::Patch isn't even installed by default). HTH -- Arttu V. -- Running Gentoo is like running with scissors