creating directories for destroot pahse
markd at macports.org
markd at macports.org
Wed Aug 15 08:40:25 PDT 2007
Juan Manuel Palacios <jmpp at macports.org> writes:
>>>> Question 1: I thought I had to create directories manually when
>>>> copying
>>>> my own destroot or pre- or post- destroot phases. If not, can it
>>>> simply
>>>> be omitted for the file specified in the MacPorts guide under
>>>> "MacPorts
>>>> File Hierarchy". That is the mtree, correct?
>>>>
>>>> I think I create directories in destroot for a lot of ports, and I
>>>> thought
>>>> others did too so I'm confused.
>>>
>>> Don't worry, I've just discovered that by mistake, I haven't created
>>> an mtree directory and xinstall didn't complain.
>>> I think they are created before the destroot stage and that these
>>> that remain empty after are deleted in destroot_finish.
>>
>> Okay, so the rule must be that you don't need to create directories
>> manaually to put files in top-level mtree directories for destroot or
>> post-destroot phases, otherwise yes.
>>
>> Mark
>
>
> There's the ${prefix}/etc/macports/prefix.mtree file and whatever is
>listed there is created by MacPorts itself during the pre-destroot
>stage as the installation bed for a destrooting port (destroot_start
>proc in base/src/port1.0/portdestroot.tcl [1]). Once the destroot
>stage is done, whatever directory in the destroot that's void of any
>files (that is, the destrooting port didn't place anything in them)
>gets pruned during the post-destroot closing stage. Therefore,
>anything else that's not in the default mtree needs to be created
>manually and anything you intend to keep for installation even if
>empty has to be safeguarded through a destroot.keepdirs clause.
>
> HTH! Ping me if not ;-)
Nice. I got it. More fodder for the new guide.
Mark
More information about the macports-dev
mailing list