Hi, I have the following options in /etc/make.conf: NO_PROFILE=true NO_SENDMAIL=true NO_GAMES=true NO_I4B=true NO_ATM=true NO_INET6=true NO_BLUETOOTH=true NO_IPFILTER=true NO_RCMDS=true NO_KERBEROS=true However after a "make buildworld installworld" the utilities and libs associated with these packages are still installed, is there any easy way to remove them from the system? Thanks Tom
Victor Snezhko
2007-Jan-17 19:07 UTC
Removing unused core components. (Disabled in make.conf)
Tom Judge <tom@tomjudge.com> writes:> Hi, > > I have the following options in /etc/make.conf: > > NO_PROFILE=true > NO_SENDMAIL=true > NO_GAMES=true > NO_I4B=true > NO_ATM=true > NO_INET6=true > NO_BLUETOOTH=true > NO_IPFILTER=true > NO_RCMDS=true > NO_KERBEROS=true > > > However after a "make buildworld installworld" the utilities and libs > associated with these packages are still installed, is there any easy > way to remove them from the system?make delete-old -- WBR, Victor V. Snezhko E-mail: snezhko@indorsoft.ru
Freddie Cash
2007-Jan-17 20:12 UTC
Removing unused core components. (Disabled in make.conf)
On Wednesday 17 January 2007 10:20 am, Tom Judge wrote:> I have the following options in /etc/make.conf: > NO_PROFILE=true > NO_SENDMAIL=true > NO_GAMES=true > NO_I4B=true > NO_ATM=true > NO_INET6=true > NO_BLUETOOTH=true > NO_IPFILTER=true > NO_RCMDS=true > NO_KERBEROS=true > > However after a "make buildworld installworld" the utilities and libs > associated with these packages are still installed, is there any easy > way to remove them from the system?There are scripts floating around the Internet that automate this. There are a couple linked off http://www.bsdforums.org/forums/ but you'll have to search the archives to find them. There's nothing built-in to FreeBSD that handles this. At least not that I've found / heard of. I could be wrong, though. -- Freddie Cash fcash@ocis.net
Doug Barton
2007-Jan-17 20:19 UTC
Removing unused core components. (Disabled in make.conf)
Tom Judge wrote:> Hi, > > I have the following options in /etc/make.conf: > > NO_PROFILE=true > NO_SENDMAIL=true > NO_GAMES=true > NO_I4B=true > NO_ATM=true > NO_INET6=true > NO_BLUETOOTH=true > NO_IPFILTER=true > NO_RCMDS=true > NO_KERBEROS=true > > > However after a "make buildworld installworld" the utilities and libs > associated with these packages are still installed, is there any easy > way to remove them from the system?I've used the following successfully for a long time: doinstall () { cd /usr && [ -d include-old ] && /bin/rm -r include-old; [ ! -e include-old ] && mv -i include include-old; /bin/rm -r /usr/share/man; cd /usr/src && touch /var/tmp/installdate && make installworld } Then I use the attached script to delete things that weren't installed above. One caveat, if you did not clean out /usr/obj before you built the world, valid libraries will show up as older than the install because of how the file dates are set in bsd.lib.mk. So, if you cleared out /usr/obj before your build, then you can mv the libraries safely. If you didn't, when the first library comes up hit q. hth, Doug -- This .signature sanitized for your protection -------------- next part -------------- #!/bin/sh PATH=/usr/bin:/bin export PATH for dir in /bin /libexec /rescue /sbin /usr/bin /usr/games /usr/libdata \ /usr/libexec /usr/sbin /usr/share/games /usr/lib /lib ; do if [ ! -d "$dir" ]; then continue; fi for file in `find $dir \( -type f -o -type l \) -a \ ! -newer /var/tmp/installdate`; do case "${file}" in /usr/lib/compat/*|*/0ld/*|/usr/libdata/perl/*) ;; */libexec/ld-elf.so.1*|/sbin/init.bak|/usr/bin/perl*) ;; *) echo '' ls -lao ${file} read -p " *** Move ${file} to ${file%/*}/0ld? [n] " M case ${M} in [yY]*) mkdir -p ${file%/*}/0ld chflags 0 ${file} && mv -i ${file} ${file%/*}/0ld/ ;; [qQ]) exit 0 ;; esac ;; esac done done exit 0