X-Original-To: alpine-devel@lists.alpinelinux.org Delivered-To: alpine-devel@mail.alpinelinux.org Received: from mail-pa0-f48.google.com (mail-pa0-f48.google.com [209.85.220.48]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (No client certificate requested) by mail.alpinelinux.org (Postfix) with ESMTPS id E59D9DC0B58 for ; Wed, 23 Jul 2014 05:50:50 +0000 (UTC) Received: by mail-pa0-f48.google.com with SMTP id et14so1034452pad.7 for ; Tue, 22 Jul 2014 22:50:49 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=date:from:to:cc:subject:message-id:references:mime-version :content-type:content-disposition:in-reply-to:user-agent; bh=DuBiyNPG9tP/PkSgL4riPfM36GPyqURZKLfUml3OsIo=; b=0DSM2R22QaAjGj4vtZsEDbKPZO3RiLK5r1hrm9lf8vo9xXph2xCB9PRUyOxfNO2WZv HVf4FQuG7aZ29PFeSFE7NoZY9X4zyOTm0hblA0oA7392kyrOfH6GHzy/Mqke14aOic+3 SI2de+vfe+G1VohES4F8qRbdmArfqQ1SzmYd9rmpzJBGU1Y7xumVytEFAYZM0lPXlhHH uMlnkMm2k93p/nH4Co1DWY+1o3Ko413TfqVNnbkO3U+EDiQiWEuiPEk/DzW+y8wTSk2T JVYgvROtK3cxMiC/btgHWe7g585TEolHaANNs9djYnGSaIShjuqZEdpzYtNCbC5bmqC5 KPXw== X-Received: by 10.66.229.98 with SMTP id sp2mr24487932pac.95.1406094649820; Tue, 22 Jul 2014 22:50:49 -0700 (PDT) Received: from newbook ([50.0.224.39]) by mx.google.com with ESMTPSA id oo3sm1548614pdb.19.2014.07.22.22.50.47 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 22 Jul 2014 22:50:48 -0700 (PDT) Date: Tue, 22 Jul 2014 22:50:45 -0700 From: Isaac Dunham To: Timo Teras Cc: Natanael Copa , William Pitcock , alpine-devel@lists.alpinelinux.org Subject: Re: [alpine-devel] [PATCH] testing/sword: add new package Message-ID: <20140723055044.GA17046@newbook> References: <1405457044-3186-1-git-send-email-ibid.ag@gmail.com> <20140715162818.0f5adca9@ncopa-desktop.alpinelinux.org> <20140716212248.GA1780@newbook> <20140722142728.6a7efbbe@ncopa-desktop.alpinelinux.org> <20140723040141.GA3905@newbook> <20140723081936.2ca2eb87@vostro> X-Mailinglist: alpine-devel Precedence: list List-Id: Alpine Development List-Unsubscribe: List-Post: List-Help: List-Subscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20140723081936.2ca2eb87@vostro> User-Agent: Mutt/1.5.23 (2014-03-12) On Wed, Jul 23, 2014 at 08:19:36AM +0300, Timo Teras wrote: > On Tue, 22 Jul 2014 21:01:42 -0700 > Isaac Dunham wrote: > > > On Tue, Jul 22, 2014 at 02:27:28PM +0200, Natanael Copa wrote: > > > How about using /var/lib/sword as default and have a > > > 'sword' group with write permissions there? > > > > > > They you can just add your users to the sword group to be able to > > > install the data files. > > > > > That should work. > > One question/minor issue: > > > > abuild warns about chown in the post-install script. > > > > But it would seem that there's no other sane way to make sure that > > /var/lib/sword belongs to the "sword" group: to make it belong to > > root:sword in the package, this group must exist when the package is > > built and when it is extracted. > > I presume pre-install could do the latter, but manipulating groups in > > a build script is insanity. > > > > If I can ignore that warning (assuming it belongs in abuild), I have a > > script ready to go. > > > > What's the preferred approach? > > Use pkgusers and pkggroups in APKBUILD, and do chown in the package() > or subpkg split function. See 'transmission' or any other package with > pkgusers in it for an example. And create the user in pre-install > script. > > This allows apk to keep track of the file permissions properly. > Doing chown in post-install would make the file permissions mismatch > with what is in the apk database, and thus make 'apk audit' give > spurious results. Ok, thanks for the explanation. Patch should be incoming as soon as I've built and tested it. ... I might drop clucene as a build dependency, since sword seems to pick up the libc regex interface. But I'd rather not do that right now. Thanks, Isaac Dunham --- Unsubscribe: alpine-devel+unsubscribe@lists.alpinelinux.org Help: alpine-devel+help@lists.alpinelinux.org ---