FreeBSD Bugzilla – Attachment 98796 Details for
Bug 137762
[handbook] [patch] proposed: mention "make delete-old" in sec 24.7 Rebuilding World
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
chapter.sgml.diff
chapter.sgml.diff (text/x-diff; charset=us-ascii), 4.95 KB, created by
Anton Shterenlikht
on 2010-07-28 21:11:24 UTC
(
hide
)
Description:
chapter.sgml.diff
Filename:
MIME Type:
Creator:
Anton Shterenlikht
Created:
2010-07-28 21:11:24 UTC
Size:
4.95 KB
patch
obsolete
>--- /doc/en_US.ISO8859-1/books/handbook/cutting-edge/chapter.sgml 2010-07-07 16:23:31.000000000 +0100 >+++ chapter.sgml 2010-07-28 21:05:43.000000000 +0100 >@@ -1977,6 +1977,35 @@ > <para>A full machine reboot is needed now to load the new kernel > and new world with new configuration files.</para> > </listitem> >+ >+ <listitem> >+ <para><command>make check-old</command></para> >+ >+ <para>When new files, directories or libraries (or new versions >+ of existing files) are installed, the old versions might become >+ obsolete. This command will show all obsolete files. >+ </para> >+ </listitem> >+ >+ <listitem> >+ <para><command>make delete-old</command></para> >+ >+ <para>Deleting obsolete files is recommended. >+ In some cases deleting obsolete files is required >+ to avoid various compilation problems. More on that below. >+ </para> >+ <warning> >+ <title>Warning</title> >+ >+ <para>Before deleting old versions of shared libraries, you need >+ to make sure that no ports depend on those. Any port that >+ does depend on old versions of shared libraries will have to be >+ rebuilt prior to your deleting old versions. Otherwise, >+ you might find that some ports don't work anymore. >+ </para> >+ </warning> >+ </listitem> >+ > </orderedlist> > > <para>Note that if you're upgrading from one release of the same &os; >@@ -2729,13 +2758,94 @@ > <sect2 id="updating-upgrading-rebooting"> > <title>Rebooting</title> > >- <para>You are now done. After you have verified that everything appears >+ <para>You are now nearly done. After you have verified that everything appears > to be in the right place you can reboot the system. A simple > &man.shutdown.8; should do it:</para> > > <screen>&prompt.root; <userinput>shutdown -r now</userinput></screen> > </sect2> > >+ <sect2 id="delete-old"> >+ <title>Deleting obsolete files, directories, libraries</title> >+ >+ <para>Now you need to make sure there are no obsolete >+ files which might cause various compilation problems with >+ the base operating system, the kernel and ports. >+ </para> >+ >+ <para>Do</para> >+ <screen>&prompt.root; <userinput>cd /usr/src</userinput></screen> >+ >+ <para>and start with</para> >+ <screen>&prompt.root; <userinput>make check-old</userinput></screen> >+ >+ <para>This will check for old files, directories and shared >+ libraries. If any obsolete files are found, you can >+ then do</para> >+ <screen>&prompt.root; <userinput>make delete-old</userinput></screen> >+ >+ <tip> >+ <para>Have a look at <filename>/usr/src/Makefile</filename> >+ for more targets of interest, e.g.</para> >+ <screen> >+# check-old - List obsolete directories/files/libraries. >+# check-old-dirs - List obsolete directories. >+# check-old-files - List obsolete files. >+# check-old-libs - List obsolete libraries. >+# delete-old - Delete obsolete directories/files/libraries. >+# delete-old-dirs - Delete obsolete directories. >+# delete-old-files - Delete obsolete files. >+# delete-old-libs - Delete obsolete libraries. >+ </screen> >+ <para>More detailed comments are provided for each target in >+ the makefile itself.</para> >+ </tip> >+ >+ <para>You will be prompted before deleting each file or >+ directory. Be particularly careful when offered to >+ delete a shared library. If there are ports which >+ depend on it, these ports will not run if you choose >+ to delete it. >+ </para> >+ >+ <para> You might want to use >+ <ulink url="http://www.freshports.org/sysutils/libchk/">libchk</ulink> >+ port to find out which ports, if any, depend on an old >+ version of shared library. You are advised to rebuild >+ all such ports, to use the new version of shared >+ libraries. Then, if you are satisfied that there are >+ no more ports which depend on the old version >+ of shared library, you can delete it. >+ </para> >+ >+ <para>If you don't delete obsolete shared libraries, you might >+ end up getting messages like this: >+ </para> >+ <screen> >+/usr/bin/ld: warning: libz.so.4, needed by /usr/local/lib/libtiff.so, may conflict with libz.so.5 >+/usr/bin/ld: warning: librpcsvc.so.4, needed by /usr/local/lib/libXext.so, may conflict with librpcsvc.so.5 >+ </screen> >+ >+ <para>In both examples linker is complaining about ports >+ compiled with old versions of shared libraries, while the >+ new versions are available. Conflicts are possible if >+ these ports depend on other ports which are built with >+ the new version of the same shared library.</para> >+ >+ <para>Fortunately the solution is very simple. First >+ find which port installed the file in question:</para> >+ >+ <screen> >+&prompt.root; <userinput>pkg_info -W /usr/local/lib/libtiff.so</userinput> >+/usr/local/lib/libtiff.so was installed by package tiff-3.9.4 >+&prompt.root; <userinput>pkg_info -W /usr/local/lib/libXext.so</userinput> >+/usr/local/lib/libXext.so was installed by package libXext-1.1.1,1 >+ </screen> >+ >+ <para>Then just rebuild the ports in question.</para> >+ >+ </sect2> >+ > <sect2> > <title>Finished</title> >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 137762
: 98796