Sunday, September 25, 2011

Time to upgrade libpng

又到電腦經痛時候了。這周末media-libs/libpng-1.5進入了~arch。一大堆和media-libs/libpng-1.4 link的package相繼倒下。不過我也下定决心用sys-apps/portage-2.2。Keyword加emerge:

1316989305:  === (1 of 1) Compiling/Merging (sys-apps/portage-2.2.0_alpha59::/gentoo/portage/sys-apps/portage/portage-2.2.0_alpha59.ebuild)
1316989348:  ::: completed emerge (1 of 1) sys-apps/portage-2.2.0_alpha59 to /
1316989374:  === (1 of 3) Compiling/Merging (sys-libs/zlib-1.2.5.1-r2::/gentoo/portage/sys-libs/zlib/zlib-1.2.5.1-r2.ebuild)
1316989497:  ::: completed emerge (1 of 3) sys-libs/zlib-1.2.5.1-r2 to /
1316989498:  === (2 of 3) Compiling/Merging (media-libs/libpng-1.5.5::/gentoo/portage/media-libs/libpng/libpng-1.5.5.ebuild)
1316989563:  ::: completed emerge (2 of 3) media-libs/libpng-1.5.5 to /
1316989564:  === (3 of 3) Compiling/Merging (media-libs/libpng-1.2.46::/gentoo/portage/media-libs/libpng/libpng-1.2.46.ebuild)
1316989612:  ::: completed emerge (3 of 3) media-libs/libpng-1.2.46 to /
成功後重建鏈接media-libs/libpng包的長跑開始。

第一步是跑revdep-rebuild看有那些斷掉的link:

revdep-rebuild -L libpng14.so.14 -- --ask
...
emerge --complete-graph --oneshot --ask --keep-going app-editors/emacs:23 app-office/dia:0 app-text/dvipdfmx:0 app-text/evince:0 app-text/ghostscript-gpl:0 app-text/gtkspell:0 app-text/poppler:0 app-text/texlive-core:0 app-text/xdvipdfmx:0 dev-cpp/cairomm:0 dev-lang/php:5.3 dev-libs/DirectFB:0 dev-libs/libgweather:2 dev-perl/perl-tk:0 dev-python/matplotlib:0 dev-python/notify-python:0 dev-python/pygtkglext:0 dev-tex/luatex:0 gnome-base/gnome-panel:0 gnome-base/gnome-settings-daemon:0 gnome-base/libglade:2.0 gnome-base/librsvg:2 gnome-extra/evolution-data-server:0 gnome-extra/gnome-utils:0 mail-client/evolution:2.0 media-gfx/fbgrab:0 media-gfx/gtkimageview:0 media-gfx/imagemagick:0 media-gfx/inkscape:0 media-gfx/splashutils:0 media-gfx/transfig:0 media-gfx/xfig:0 media-libs/gd:2 media-libs/imlib2:0 media-libs/libquicktime:0 media-libs/libwebp:0 media-libs/libwmf:0 media-libs/ming:0 media-libs/netpbm:0 media-libs/openjpeg:0 media-libs/plotutils:0 media-libs/swfdec:0 media-video/dvdauthor:0 media-video/mjpegtools:1 media-video/mplayer2:0 media-video/totem:0 media-video/vlc:0 net-libs/webkit-gtk:2 net-libs/xulrunner:1.9 net-print/cups:0 net-print/gnome-cups-manager:0 sys-libs/slang:0 www-client/chromium:0 www-client/firefox:0 x11-apps/xcursorgen:0 x11-libs/cairo:0 x11-libs/gdk-pixbuf:2 x11-libs/gtk+:3 x11-libs/libgksu:2 x11-libs/libnotify:0 x11-libs/openmotif:0 x11-libs/qt-gui:4 x11-libs/wxGTK:2.8 x11-themes/gtk-engines-equinox:0 x11-themes/gtk-engines-murrine:0 x11-wm/compiz:0 x11-wm/fvwm:0 xfce-base/xfce4-session:0
或者跑
emerge -a @preserved-rebuild
也可以。但直接跑emerge有不少包(例如mail-client/evolution)會以以下錯誤失敗告終:
make[4]: Entering directory `/var/tmp/portage/mail-client/evolution-2.32.3/work/evolution-2.32.3/plugins/calendar-weather'
  CC     liborg_gnome_calendar_weather_la-calendar-weather.lo
  CCLD   liborg-gnome-calendar-weather.la
/usr/lib/gcc/i686-pc-linux-gnu/4.5.3/../../../../i686-pc-linux-gnu/bin/ld: cannot find -lpng14
collect2: ld returned 1 exit status
make[4]: *** [liborg-gnome-calendar-weather.la] Error 1
原因是有些包的.la檔還在找-lpng14。要先修好那些:

$ find /usr/lib -iname '*a' -print0 | xargs -0 grep -l 'lpng14' | xargs qfile -CSq | uniq | sort
dev-cpp/cairomm:0
dev-libs/DirectFB:0
dev-libs/libgweather:2
dev-python/pygtksourceview:2
gnome-base/gdm:0
gnome-base/libgnomeui:0
gnome-base/libgnomekbd:0
gnome-base/libgnomeprintui:2.2 
gnome-base/libgnomecanvas:0
...
但結果也不是那麼順利的。Murphy's Law總是要kick in:
configure: error: Package requirements (glib-2.0 >= 2.27.3    atk >= 1.29.2    pango >= 1.20    cairo >= 1.6    gdk-pixbuf-2.0 >= 2.21.0) were not met:

Package libpng14 was not found in the pkg-config search path.
Perhaps you should add the directory containing `libpng14.pc'
to the PKG_CONFIG_PATH environment variable
Package 'libpng14', required by 'GdkPixbuf', not found
也就是說上面的revdep-rebuildfind的方法都没有發現x11-libs/gdk-pixbuf也鏈接libpng14.so.14。所以要手加進emerge list去:
emerge --oneshot --keep-going gdk-pixbuf
然後在一步一步重來,雖然不是一帆風順,但也一步一迭地慢慢地把系統清潔起來:
1316991104:  === (1 of 13) Compiling/Merging (x11-libs/gdk-pixbuf-2.24.0-r1::/gentoo/portage/x11-libs/gdk-pixbuf/gdk-pixbuf-2.24.0-r1.ebuild)
1316991303:  === (1 of 13) Merging (x11-libs/gdk-pixbuf-2.24.0-r1::/gentoo/portage/x11-libs/gdk-pixbuf/gdk-pixbuf-2.24.0-r1.ebuild)
1316991335:  ::: completed emerge (1 of 13) x11-libs/gdk-pixbuf-2.24.0-r1 to /
1316991337:  === (2 of 13) Compiling/Merging (x11-libs/gtk+-2.24.6::/gentoo/portage/x11-libs/gtk+/gtk+-2.24.6.ebuild)
1316992439:  === (2 of 13) Merging (x11-libs/gtk+-2.24.6::/gentoo/portage/x11-libs/gtk+/gtk+-2.24.6.ebuild)
1316992475:  ::: completed emerge (2 of 13) x11-libs/gtk+-2.24.6 to /
1316992475:  === (3 of 13) Compiling/Merging (gnome-base/libgnomecanvas-2.30.3::/gentoo/portage/gnome-base/libgnomecanvas/libgnomecanvas-2.30.3.ebuild)
1316992543:  === (3 of 13) Merging (gnome-base/libgnomecanvas-2.30.3::/gentoo/portage/gnome-base/libgnomecanvas/libgnomecanvas-2.30.3.ebuild)
1316992565:  ::: completed emerge (3 of 13) gnome-base/libgnomecanvas-2.30.3 to /
1316992565:  === (4 of 13) Compiling/Merging (gnome-extra/evolution-data-server-2.32.3-r1::/gentoo/portage/gnome-extra/evolution-data-server/evolution-data-server-2.32.3-r1.ebuild)
1316996504:  === (1 of 9) Compiling/Merging (gnome-base/libgnomeui-2.24.5::/gentoo/portage/gnome-base/libgnomeui/libgnomeui-2.24.5.ebuild)
1316996701:  === (1 of 9) Merging (gnome-base/libgnomeui-2.24.5::/gentoo/portage/gnome-base/libgnomeui/libgnomeui-2.24.5.ebuild)
1316996720:  ::: completed emerge (1 of 9) gnome-base/libgnomeui-2.24.5 to /
1316996721:  === (2 of 9) Compiling/Merging (x11-libs/gtk+-3.0.12::/var/lib/layman/gentoo-zh/x11-libs/gtk+/gtk+-3.0.12.ebuild)
1316997611:  === (2 of 9) Merging (x11-libs/gtk+-3.0.12::/var/lib/layman/gentoo-zh/x11-libs/gtk+/gtk+-3.0.12.ebuild)
1316997638:  ::: completed emerge (2 of 9) x11-libs/gtk+-3.0.12 to /
1316997639:  === (3 of 9) Compiling/Merging (x11-libs/gtksourceview-2.10.5-r1::/gentoo/portage/x11-libs/gtksourceview/gtksourceview-2.10.5-r1.ebuild)
1316997738:  === (3 of 9) Merging (x11-libs/gtksourceview-2.10.5-r1::/gentoo/portage/x11-libs/gtksourceview/gtksourceview-2.10.5-r1.ebuild)
1316997757:  ::: completed emerge (3 of 9) x11-libs/gtksourceview-2.10.5-r1 to /
1316997757:  === (4 of 9) Compiling/Merging (x11-libs/libwnck-2.30.7::/gentoo/portage/x11-libs/libwnck/libwnck-2.30.7.ebuild)
1316997852:  === (4 of 9) Merging (x11-libs/libwnck-2.30.7::/gentoo/portage/x11-libs/libwnck/libwnck-2.30.7.ebuild)
1316997873:  ::: completed emerge (4 of 9) x11-libs/libwnck-2.30.7 to /
1316997873:  === (5 of 9) Compiling/Merging (gnome-base/libgnomekbd-2.32.0::/gentoo/portage/gnome-base/libgnomekbd/libgnomekbd-2.32.0.ebuild)
1316997934:  === (5 of 9) Merging (gnome-base/libgnomekbd-2.32.0::/gentoo/portage/gnome-base/libgnomekbd/libgnomekbd-2.32.0.ebuild)
1316997954:  ::: completed emerge (5 of 9) gnome-base/libgnomekbd-2.32.0 to /
1316997954:  === (6 of 9) Compiling/Merging (gnome-base/libgnomeprintui-2.18.6::/gentoo/portage/gnome-base/libgnomeprintui/libgnomeprintui-2.18.6.ebuild)
1316998037:  === (6 of 9) Merging (gnome-base/libgnomeprintui-2.18.6::/gentoo/portage/gnome-base/libgnomeprintui/libgnomeprintui-2.18.6.ebuild)
1316998054:  ::: completed emerge (6 of 9) gnome-base/libgnomeprintui-2.18.6 to /
1316998055:  === (7 of 9) Compiling/Merging (mail-client/evolution-2.32.3::/gentoo/portage/mail-client/evolution/evolution-2.32.3.ebuild)
1317003419:  === (1 of 20) Compiling/Merging (dev-libs/libgweather-2.30.3::/gentoo/portage/dev-libs/libgweather/libgweather-2.30.3.ebuild)
1317003582:  === (1 of 20) Merging (dev-libs/libgweather-2.30.3::/gentoo/portage/dev-libs/libgweather/libgweather-2.30.3.ebuild)
1317003647:  ::: completed emerge (1 of 20) dev-libs/libgweather-2.30.3 to /
1317003648:  === (2 of 20) Compiling/Merging (media-gfx/gtkimageview-1.6.4::/gentoo/portage/media-gfx/gtkimageview/gtkimageview-1.6.4.ebuild)
1317003764:  === (2 of 20) Merging (media-gfx/gtkimageview-1.6.4::/gentoo/portage/media-gfx/gtkimageview/gtkimageview-1.6.4.ebuild)
1317003782:  ::: completed emerge (2 of 20) media-gfx/gtkimageview-1.6.4 to /
1317003783:  === (3 of 20) Compiling/Merging (app-text/gtkspell-2.0.16::/gentoo/portage/app-text/gtkspell/gtkspell-2.0.16.ebuild)
1317003818:  === (3 of 20) Merging (app-text/gtkspell-2.0.16::/gentoo/portage/app-text/gtkspell/gtkspell-2.0.16.ebuild)
1317003833:  ::: completed emerge (3 of 20) app-text/gtkspell-2.0.16 to /
1317003833:  === (4 of 20) Compiling/Merging (dev-cpp/cairomm-1.9.8::/gentoo/portage/dev-cpp/cairomm/cairomm-1.9.8.ebuild)
1317003880:  === (4 of 20) Merging (dev-cpp/cairomm-1.9.8::/gentoo/portage/dev-cpp/cairomm/cairomm-1.9.8.ebuild)
1317003893:  ::: completed emerge (4 of 20) dev-cpp/cairomm-1.9.8 to /
1317003893:  === (5 of 20) Compiling/Merging (dev-python/pygtksourceview-2.10.1::/gentoo/portage/dev-python/pygtksourceview/pygtksourceview-2.10.1.ebuild)
1317003933:  === (5 of 20) Merging (dev-python/pygtksourceview-2.10.1::/gentoo/portage/dev-python/pygtksourceview/pygtksourceview-2.10.1.ebuild)
1317003950:  ::: completed emerge (5 of 20) dev-python/pygtksourceview-2.10.1 to /
1317003950:  === (6 of 20) Compiling/Merging (gnome-extra/bug-buddy-2.32.0-r2::/gentoo/portage/gnome-extra/bug-buddy/bug-buddy-2.32.0-r2.ebuild)
1317004006:  === (6 of 20) Merging (gnome-extra/bug-buddy-2.32.0-r2::/gentoo/portage/gnome-extra/bug-buddy/bug-buddy-2.32.0-r2.ebuild)
1317004032:  ::: completed emerge (6 of 20) gnome-extra/bug-buddy-2.32.0-r2 to /
1317004032:  === (7 of 20) Compiling/Merging (gnome-extra/gnome-media-2.32.0-r1::/gentoo/portage/gnome-extra/gnome-media/gnome-media-2.32.0-r1.ebuild)
1317004157:  === (7 of 20) Merging (gnome-extra/gnome-media-2.32.0-r1::/gentoo/portage/gnome-extra/gnome-media/gnome-media-2.32.0-r1.ebuild)
1317004180:  ::: completed emerge (7 of 20) gnome-extra/gnome-media-2.32.0-r1 to /
1317004180:  === (8 of 20) Compiling/Merging (media-gfx/pstoedit-3.60::/gentoo/portage/media-gfx/pstoedit/pstoedit-3.60.ebuild)
1317004347:  === (8 of 20) Merging (media-gfx/pstoedit-3.60::/gentoo/portage/media-gfx/pstoedit/pstoedit-3.60.ebuild)
1317004362:  ::: completed emerge (8 of 20) media-gfx/pstoedit-3.60 to /
1317004363:  === (9 of 20) Compiling/Merging (media-libs/swfdec-0.8.4::/gentoo/portage/media-libs/swfdec/swfdec-0.8.4.ebuild)
1317004670:  === (9 of 20) Merging (media-libs/swfdec-0.8.4::/gentoo/portage/media-libs/swfdec/swfdec-0.8.4.ebuild)
1317004686:  ::: completed emerge (9 of 20) media-libs/swfdec-0.8.4 to /
1317004687:  === (10 of 20) Compiling/Merging (net-print/gnome-cups-manager-0.33-r2::/gentoo/portage/net-print/gnome-cups-manager/gnome-cups-manager-0.33-r2.ebuild)
1317004814:  === (10 of 20) Merging (net-print/gnome-cups-manager-0.33-r2::/gentoo/portage/net-print/gnome-cups-manager/gnome-cups-manager-0.33-r2.ebuild)
1317004835:  ::: completed emerge (10 of 20) net-print/gnome-cups-manager-0.33-r2 to /
1317004835:  === (11 of 20) Compiling/Merging (x11-themes/gtk-engines-aurora-1.5.1::/gentoo/portage/x11-themes/gtk-engines-aurora/gtk-engines-aurora-1.5.1.ebuild)
1317004877:  === (11 of 20) Merging (x11-themes/gtk-engines-aurora-1.5.1::/gentoo/portage/x11-themes/gtk-engines-aurora/gtk-engines-aurora-1.5.1.ebuild)
1317004890:  ::: completed emerge (11 of 20) x11-themes/gtk-engines-aurora-1.5.1 to /
1317004890:  === (12 of 20) Compiling/Merging (x11-themes/gtk-engines-equinox-1.40::/usr/local/portage/x11-themes/gtk-engines-equinox/gtk-engines-equinox-1.40.ebuild)
1317004939:  === (12 of 20) Merging (x11-themes/gtk-engines-equinox-1.40::/usr/local/portage/x11-themes/gtk-engines-equinox/gtk-engines-equinox-1.40.ebuild)
1317004955:  ::: completed emerge (12 of 20) x11-themes/gtk-engines-equinox-1.40 to /
1317004955:  === (13 of 20) Compiling/Merging (x11-themes/gtk-engines-murrine-9999::/usr/local/portage/x11-themes/gtk-engines-murrine/gtk-engines-murrine-9999.ebuild)
1317005029:  === (13 of 20) Merging (x11-themes/gtk-engines-murrine-9999::/usr/local/portage/x11-themes/gtk-engines-murrine/gtk-engines-murrine-9999.ebuild)
1317005044:  ::: completed emerge (13 of 20) x11-themes/gtk-engines-murrine-9999 to /
1317005045:  === (14 of 20) Compiling/Merging (dev-libs/DirectFB-1.4.9-r1::/gentoo/portage/dev-libs/DirectFB/DirectFB-1.4.9-r1.ebuild)
1317005256:  === (14 of 20) Merging (dev-libs/DirectFB-1.4.9-r1::/gentoo/portage/dev-libs/DirectFB/DirectFB-1.4.9-r1.ebuild)
1317005272:  ::: completed emerge (14 of 20) dev-libs/DirectFB-1.4.9-r1 to /
1317005272:  === (15 of 20) Compiling/Merging (gnome-base/gdm-2.20.11-r1::/gentoo/portage/gnome-base/gdm/gdm-2.20.11-r1.ebuild)
1317005492:  === (15 of 20) Merging (gnome-base/gdm-2.20.11-r1::/gentoo/portage/gnome-base/gdm/gdm-2.20.11-r1.ebuild)
1317005517:  ::: completed emerge (15 of 20) gnome-base/gdm-2.20.11-r1 to /
1317005524:  === (16 of 20) Compiling/Merging (mail-client/evolution-2.32.3::/gentoo/portage/mail-client/evolution/evolution-2.32.3.ebuild)
1317008055:  === (16 of 20) Merging (mail-client/evolution-2.32.3::/gentoo/portage/mail-client/evolution/evolution-2.32.3.ebuild)
1317008154:  ::: completed emerge (16 of 20) mail-client/evolution-2.32.3 to /
1317008155:  === (17 of 20) Compiling/Merging (media-gfx/splashutils-1.5.4.4::/gentoo/portage/media-gfx/splashutils/splashutils-1.5.4.4.ebuild)
1317008405:  === (17 of 20) Merging (media-gfx/splashutils-1.5.4.4::/gentoo/portage/media-gfx/splashutils/splashutils-1.5.4.4.ebuild)
1317008426:  ::: completed emerge (17 of 20) media-gfx/splashutils-1.5.4.4 to /
1317008426:  === (18 of 20) Compiling/Merging (media-libs/imlib2-1.4.4::/gentoo/portage/media-libs/imlib2/imlib2-1.4.4.ebuild)
1317008551:  === (18 of 20) Merging (media-libs/imlib2-1.4.4::/gentoo/portage/media-libs/imlib2/imlib2-1.4.4.ebuild)
1317008566:  ::: completed emerge (18 of 20) media-libs/imlib2-1.4.4 to /
1317008566:  === (19 of 20) Compiling/Merging (media-libs/libquicktime-1.2.3-r1::/gentoo/portage/media-libs/libquicktime/libquicktime-1.2.3-r1.ebuild)
1317008812:  === (19 of 20) Merging (media-libs/libquicktime-1.2.3-r1::/gentoo/portage/media-libs/libquicktime/libquicktime-1.2.3-r1.ebuild)
1317008826:  ::: completed emerge (19 of 20) media-libs/libquicktime-1.2.3-r1 to /
1317008827:  === (20 of 20) Compiling/Merging (x11-libs/gtkglext-1.2.0::/gentoo/portage/x11-libs/gtkglext/gtkglext-1.2.0.ebuild)
1317008959:  === (20 of 20) Merging (x11-libs/gtkglext-1.2.0::/gentoo/portage/x11-libs/gtkglext/gtkglext-1.2.0.ebuild)
1317008974:  ::: completed emerge (20 of 20) x11-libs/gtkglext-1.2.0 to /

No comments: