From owner-p4-projects@FreeBSD.ORG Sun May 30 03:55:18 2010 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 16D501065672; Sun, 30 May 2010 03:55:18 +0000 (UTC) Delivered-To: perforce@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id B77AB106566C for ; Sun, 30 May 2010 03:55:17 +0000 (UTC) (envelope-from yanegomi@gmail.com) Received: from mail-iw0-f182.google.com (mail-iw0-f182.google.com [209.85.214.182]) by mx1.freebsd.org (Postfix) with ESMTP id 694C98FC08 for ; Sun, 30 May 2010 03:55:16 +0000 (UTC) Received: by iwn5 with SMTP id 5so320799iwn.13 for ; Sat, 29 May 2010 20:55:16 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:sender:received :in-reply-to:references:date:x-google-sender-auth:message-id:subject :from:to:cc:content-type:content-transfer-encoding; bh=svLRpTXFujfA/Tes3PndCnMAoALWbx2ONntko6pH0+Q=; b=K5YijNZHUhJ8ibk0z5+82zL9IKRvDY60qPU2srDjMwtle0yiemeKGeABwtalbZctjp BqvXFSlgP4QMmCicwi6/2TeU++DBgCTkrxxaV+gg3wvYTDJhiC3PKdFx8vbMn+iSexgH FWxgfMXY9kLrKR5Bu+a1K6L30v309AoeayjA8= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:sender:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:to:cc:content-type :content-transfer-encoding; b=u2UTTEujA9sxYhH/WiZE/GmBLfGpeeqQmymBX6E6fY44S4FmvfyHbmx/qS9SURtXFt B20wQE+7XqoFk4r9wqQ98hr0B5mDvvGKZ+8J+CQTG8asSAoJ5EG/R63CgrnMsMhXnpHx G3ufFLGHpkBuyZ2u7rtXo3Sm6LzvSVHpsnqLM= MIME-Version: 1.0 Received: by 10.231.157.4 with SMTP id z4mr3361564ibw.32.1275191716085; Sat, 29 May 2010 20:55:16 -0700 (PDT) Sender: yanegomi@gmail.com Received: by 10.231.70.16 with HTTP; Sat, 29 May 2010 20:55:16 -0700 (PDT) In-Reply-To: <201005300157.o4U1vbnm051835@repoman.freebsd.org> References: <201005300157.o4U1vbnm051835@repoman.freebsd.org> Date: Sat, 29 May 2010 20:55:16 -0700 X-Google-Sender-Auth: 2qmxqx7CE7EkbxFcaszxhoEjno0 Message-ID: From: Garrett Cooper To: Julien Laffaye Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Cc: Perforce Change Reviews Subject: Re: PERFORCE change 178963 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 30 May 2010 03:55:18 -0000 On Sat, May 29, 2010 at 6:57 PM, Julien Laffaye wrot= e: > http://p4web.freebsd.org/@@178963?ac=3D10 > > Change 178963 by jlaffaye@gsoc on 2010/05/30 01:57:14 > > =A0 =A0 =A0 =A0Plans and thoughts for complete packages support. > > Affected files ... > > .. //depot/projects/soc2010/pkg_complete/Milestones#2 edit > > Differences ... > > =3D=3D=3D=3D //depot/projects/soc2010/pkg_complete/Milestones#2 (text+ko)= =3D=3D=3D=3D > > @@ -1,0 +1,26 @@ > +pkg_create: > + =A0 =A0 =A0 The options of pkg_create are useless for creating a comple= te package. > +Should we add support for complete package in pkg_create or into a new t= ool? > +The tool for creating a complete package would take for first argument t= he meta > +(traditionnal) package. Then the tool read the plist to look for @pkgdep= and > +repeat the operation for each dependency. > +After ordering the dependencies, the tool tar'up all the traditionnal pa= ckages > +(without compression as the packages are already bz'ed). > +This step would require factorisation of the code in pkg_info into a lib= pkg > +function, with libarchive support for efficiency. > + > +ports tree: > + =A0 =A0 =A0 Add a "complete-package" target which depends on package-re= cursive and > +call the tool of step 1. Check with portmgr (at least flz), but it would probably be better to stick with the package- prefixed target status quo. FWIW though this will require rewriting bits of package-noinstall, or similar targets, as ports currently doesn't use pkg_install except to register the install of all of the bits from ${WRKDIR} (/usr/ports/.../work if not specified otherwise) into ${PREFIX}. > +pkg_add: > + =A0 =A0 =A0 Add simple routine to test if the package is a traditionnal= or complete package. > +If the package is complete, loop over the traditionnal packages in it, > +call the function to install a traditionnal package (this function may w= ork > +with streams). If the package is tradionnal, pass directly the stream to= the > +function. > + > +As a side effect, remove playpen and embrace libarchive. Yes... this will be a good thing, as several people have agreed, but requires a ton of tests (including negative ones), and there's some forethought that needs to be done and potential rewriting that's required as whether or not the installed bits exist in the right spots, and the permissions are sane will need to be properly evaluated beforehand. You can't completely remove libarchive unless you properly use the mktemp(3) family of functions though because there are some files (like +CONTENTS) which need to be generated on the fly. > +pkg_info: > + =A0 =A0 =A0 Show if the package is complete (list of contained packages= ) or the > +info of the traditionnal package. s/traditionnal/traditional/ Thanks! -Garrett