From owner-freebsd-ports@FreeBSD.ORG Thu Sep 26 20:20:11 2013 Return-Path: Delivered-To: freebsd-ports@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id 4C9D5672 for ; Thu, 26 Sep 2013 20:20:11 +0000 (UTC) (envelope-from kpaasial@gmail.com) Received: from mail-qe0-x229.google.com (mail-qe0-x229.google.com [IPv6:2607:f8b0:400d:c02::229]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 0E0C42877 for ; Thu, 26 Sep 2013 20:20:10 +0000 (UTC) Received: by mail-qe0-f41.google.com with SMTP id 1so1219738qee.28 for ; Thu, 26 Sep 2013 13:20:10 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; bh=8NKue/FJ6IBc183Ba9WrfvYY3Z1nKOGiTb0rhI+DF14=; b=NyX700t97xKY5akWYsyiV6LrF6ToYBxlFMAuFpKjXRwtfLQxYKSoqEJBbqp9/GFWkK T5Fw2/8S14yMu9e/fe4/mR4EGve+9KCIcU0YVXat+UPJtzn+hNTeKQ0btXlKWivavZcc yTjRxUcLeqtO17r0RstmJOexhtGCj3vhCnrekPLtwAllnmRVyh9RZrkKsgxRGrXCnYiF aP+uXpuY8nhj7LoWB0IbTXMV9KaitiAIbgDPARjFqYYhnN0WSdJ0IB8QlHQiCFKRjC1v dovGFIvB4ReNMlBUtocxFqoGsOiG99Eol5seiRVTxhQ7IOSRAotQaJ1YRZtDyF20s2mw AMtQ== MIME-Version: 1.0 X-Received: by 10.224.114.201 with SMTP id f9mr9318247qaq.4.1380226810244; Thu, 26 Sep 2013 13:20:10 -0700 (PDT) Received: by 10.224.88.197 with HTTP; Thu, 26 Sep 2013 13:20:10 -0700 (PDT) In-Reply-To: <5244878F.6090203@dreamchaser.org> References: <5244625E.3070108@dreamchaser.org> <5244878F.6090203@dreamchaser.org> Date: Thu, 26 Sep 2013 23:20:10 +0300 Message-ID: Subject: Re: portmaster -- preserving added files? From: Kimmo Paasiala To: freebsd@dreamchaser.org Content-Type: text/plain; charset=UTF-8 Cc: Scot Hetzel , FreeBSD Mailing List X-BeenThere: freebsd-ports@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Porting software to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 26 Sep 2013 20:20:11 -0000 On Thu, Sep 26, 2013 at 10:14 PM, Gary Aitken wrote: > On 09/26/13 12:39, Kimmo Paasiala wrote: >> On Thu, Sep 26, 2013 at 9:25 PM, Scot Hetzel wrote: >>> On Thu, Sep 26, 2013 at 11:35 AM, Gary Aitken wrote: >>>> Is portmaster supposed to retain files which it did not install when updating / >>>> reinstalling a port? >>>> >>>> For example, jave extensions are normally installed by placing a jar file in >>>> /usr/local/openjdk6/jre/lib/ext/ >>>> >>>> When reinstalling, these are wiped out. > >>> The problem is not with portmaster, as it runs the pkg or pkg_install >>> commands to remove the port. If you have files that are missing after >>> uninstalling a port, then you'll need to check what that port is >>> doing. Most likely the port has a @dirrm instead of an @dirrmtry for >>> that directory in it's pkg-plist file. >>> >>> I had a look at the java/openjdk6/Makefile, and it creates the list of >>> directories to remove with @dirrm instead of @dirrmtry. So it looks >>> like the issue is with java/openjdk6 removing that directory. > >> It's a larger problem with no clear solution. What the programs that >> install additional files after the initial installation should do is >> to use /var/db/xyz for the additional files so that they are contained >> in a separate directory alltogether. > > > That presumes all additional files are installed via the ports mechanism, > or at least know about it, which is highly unlikely. With plugins of > various types and machine-independent binaries like java .class files > abounding, requiring every add-on to be installed by the ports mechanism > isn't likely to work in the long run. > > I can see how a program installed by the ports mechanism should use the > mechanism you're advocating, but I don't think it applies to all cases. > > In this case, it was a mysql driver, obtained as a binary (.jar of > java .class files). But things like gimp plugins have the same issue. > > Gary > I was referring to untracked files that have not been installed via the ports system or packages. However, it seems impossible to convince software writers that /usr and /usr/local might be read-only at run-time :/ -Kimmo