Subject: install/31099: postinstall denies to remove obsolete directory
To: None <install-manager@netbsd.org, gnats-admin@netbsd.org,>
From: None <netbsd@eq.cz>
List: netbsd-bugs
Date: 08/30/2005 14:45:00
>Number:         31099
>Category:       install
>Synopsis:       postinstall denies to remove obsolete directory
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    install-manager
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Tue Aug 30 14:45:00 +0000 2005
>Originator:     rudolf
>Release:        NetBSD-2.0.2
>Organization:
>Environment:
NetBSD 2.0.2 (GENERIC) i386
>Description:
When upgrading from NetBSD-2 (or NetBSD-2.0.2) to NetBSD-3.0_BETA using build.sh script, postinstall can't fix 'obsolete' target:

obsolete fix:
rmdir: ///usr/X11R6/lib/modules/codeconv: Directory not empty
        Can't remove obsolete directory ///usr/X11R6/lib/modules/codeconv

$ ls -al /usr/X11R6/lib/modules/codeconv/
total 363
drwxr-xr-x  2 root  wheel   1024 Aug 28 16:05 .
drwxr-xr-x  7 root  wheel   1024 Aug 28 20:28 ..
-r--r--r--  1 root  wheel   7432 Mar 23 09:43 libARABIC.a
-r--r--r--  1 root  wheel   2956 Mar 23 09:43 libARMSCII8.a
-r--r--r--  1 root  wheel  36890 Mar 23 09:43 libBIG5.a
-r--r--r--  1 root  wheel  51250 Mar 23 09:43 libBIG5HKSCS.a
-r--r--r--  1 root  wheel   4572 Mar 23 09:43 libDOSENCODING.a
-r--r--r--  1 root  wheel  19400 Mar 23 09:43 libGB2312.a
-r--r--r--  1 root  wheel  51056 Mar 23 09:43 libGBK.a
-r--r--r--  1 root  wheel   3470 Mar 23 09:43 libGEORGIAN.a
-r--r--r--  1 root  wheel   3984 Mar 23 09:43 libISO8859_1.a
-r--r--r--  1 root  wheel   2972 Mar 23 09:43 libISO8859_10.a
-r--r--r--  1 root  wheel   3148 Mar 23 09:43 libISO8859_11.a
-r--r--r--  1 root  wheel   2972 Mar 23 09:43 libISO8859_14.a
-r--r--r--  1 root  wheel   2340 Mar 23 09:43 libISO8859_15.a
-r--r--r--  1 root  wheel   5498 Mar 23 09:43 libISO8859_2.a
-r--r--r--  1 root  wheel   2962 Mar 23 09:43 libISO8859_3.a
-r--r--r--  1 root  wheel   2962 Mar 23 09:43 libISO8859_4.a
-r--r--r--  1 root  wheel   4636 Mar 23 09:43 libISO8859_5.a
-r--r--r--  1 root  wheel   5286 Mar 23 09:43 libISO8859_6.a
-r--r--r--  1 root  wheel   4122 Mar 23 09:43 libISO8859_7.a
-r--r--r--  1 root  wheel   3516 Mar 23 09:43 libISO8859_8.a
-r--r--r--  1 root  wheel   2962 Mar 23 09:43 libISO8859_9.a
-r--r--r--  1 root  wheel   3658 Mar 23 09:43 libJISX0201.a
-r--r--r--  1 root  wheel  19742 Mar 23 09:43 libJISX0208.a
-r--r--r--  1 root  wheel  17552 Mar 23 09:43 libJISX0212.a
-r--r--r--  1 root  wheel   5888 Mar 23 09:43 libKOI8.a
-r--r--r--  1 root  wheel  21020 Mar 23 09:43 libKSC5601.a
-r--r--r--  1 root  wheel  50712 Mar 23 09:43 libKSCJOHAB.a
-r--r--r--  1 root  wheel   4198 Mar 23 09:43 libMULEENCODING.a
-r--r--r--  1 root  wheel   3162 Mar 23 09:43 libTCVN.a
-r--r--r--  1 root  wheel   3192 Mar 23 09:43 libVISCII.a 


For more info please follow this discussion:
http://mail-index.netbsd.org/netbsd-help/2005/08/14/0000.html
http://mail-index.netbsd.org/netbsd-help/2005/08/24/0001.html
http://mail-index.netbsd.org/netbsd-help/2005/08/28/0008.html

>How-To-Repeat:
cd /usr/src
./build.sh -O /usr/B/obj -T /usr/B/tools -u tools distribution kernel=GENERIC
[copy the new kernel, reboot, cd /usr/src]
./build.sh -u -O /usr/B/obj -T /usr/B/tools install=/
/usr/src/usr.sbin/postinstall/postinstall -s /usr/src -d // fix obsolete

>Fix: