UPDATING 20110730

Andriy Gapon avg at FreeBSD.org
Sun Jul 31 11:19:41 UTC 2011


on 31/07/2011 04:32 Doug Barton said the following:
> On 07/30/2011 12:38, Andriy Gapon wrote:
>>> 20110730:
>>>   AFFECTS: users of x11-toolkits/gtk20
>>>   AUTHOR: gnome at FreeBSD.org
>>>
>>>   The gtk-update-icon-cache utility has been slipt out of the gtk20 port.
>>
>> A minor typo in the above line - slipt -> split.
>>
>>>   Use the following instructions to update your system.
>>>   
>>>   # pkg_delete -f gtk-2.\*
>>>   # portmaster x11-toolkits/gtk20
>>
>> I would like to warn other users and at the same time ask for alternative
>> instructions.
> 
> I don't think that's necessary.

Well, I decided to report what I experienced firsthand.

>> I have a regular (consumer) HDD and not so huge amount of RAM.
>> I also have many (maybe very many) ports depending on gtk20 and some other
>> loosely related ports like glib and gobject-introspection.
>> Execution of the above command already takes more than an hour which is spent
>> inside portmaster. 
> 
> I am not sure what you mean by "inside portmaster" is quite accurate. I
> followed the instructions and everything worked according to plan. The
> vast majority of the wall clock time spent following these instructions
> is in the compilation of the various ports.

Well, then we have different experiences and maybe environments.
I am quite sure that more than 1 hour of wall time was spent in portmaster
proper after portmaster performed upgrade of gio-fam-backend-2.28.8 and before
portmaster had a a chance to proceed to the next port - I pressed  ^C at that
moment.  I pressed ^T quite a few times during that hour and portmaster was
actually running grep or pkg_info at those times, mostly pkg_info.  E.g.:
load: 0.25  cmd: pkg_info 49079 [zio->io_cv)] 10.83r 0.01u 0.25s 1% 2856k
load: 0.23  cmd: pkg_info 49093 [zio->io_cv)] 4.13r 0.00u 0.09s 0% 2660k
load: 0.29  cmd: grep 49324 [zio->io_cv)] 1.37r 0.00u 0.03s 0% 1756k

Some stats about my ports:
$ l /var/db/pkg/ | wc -l
    1088
$ pkg_info -R gio-fam-backend-2.28.8| wc -l
      27
$ pkg_info -R gtk-2.24.5 | wc -l
     132
$ pkg_info -R gobject-introspection-0.10.8| wc -l
     219

> Very very little is actually
> spent "in portmaster" in the sense of time spent by portmaster
> performing its functions.
> 
>> I have hundreds of lines like the following in portmaster output:
>>
>>         ===>>> x11-toolkits/gtk20 is listed as a dependency
>>         ===>>> but there is no installed version
> 
> Yes, that's to be expected since it's accurate. :)  Every time
> portmaster installs a port it updates the +CONTENTS and +REQUIRED_BY
> files as appropriate. If the condition described above exists it lets
> you know, but since this is almost always a transient error it continues
> processing which is usually what is necessary to correct the problem
> anyway.
> 
> I've considered adding code to avoid the spurious warnings but they are
> harmless and don't happen very often so I haven't bothered.
> 
> In short, I don't think there is anything wrong here.

I am not complaining about the messages.
My complaint is about the performance of handling this case.

Here's what I did after ^C.
$ cd /usr/ports/devel/gobject-introspection
$ make install
$ cd /usr/ports/x11-toolkits/gtk20
$ make install
$ portmaster x11-toolkits/gtk20 devel/gobject-introspection

The last portmaster command decided to upgrade almost the same set of ports and
did that much much faster in my environment.
Here's what the original portmaster run intended to do:
===>>> The following actions will be taken if you choose to proceed:
        Install x11-toolkits/gtk20
        Upgrade atk-1.32.0 to atk-2.0.1
        Upgrade gio-fam-backend-2.26.1 to gio-fam-backend-2.28.8
        Upgrade glib-2.26.1_1 to glib-2.28.8
        Upgrade gobject-introspection-0.9.12_1 to gobject-introspection-0.10.8
        Upgrade gdk-pixbuf-2.22.1 to gdk-pixbuf-2.23.5
        Install graphics/gtk-update-icon-cache
        Upgrade pango-1.28.3 to pango-1.28.4

Here's what portmaster intended to do on the second run:
===>>> The following actions will be taken if you choose to proceed:
        Re-install gtk-2.24.5
        Upgrade atk-1.32.0 to atk-2.0.1
        Re-install gobject-introspection-0.10.8
        Upgrade gdk-pixbuf-2.22.1 to gdk-pixbuf-2.23.5
        Upgrade pango-1.28.3 to pango-1.28.4

I am not sure how to distill the above into a minimalistic test-case.
But it seems to me that portmaster spends too much time churning away when there
are a lot of installed ports/packages with a missing dependency.
I guess it's something in update_contents() or iport_from_origin() or in code
that calls update_contents().


-- 
Andriy Gapon


More information about the freebsd-ports mailing list