Date: Sat, 23 Oct 2010 20:16:02 -0700 From: Garrett Cooper <gcooper@FreeBSD.org> To: "sbruno@freebsd.org" <sbruno@freebsd.org> Cc: freebsd-current <freebsd-current@freebsd.org> Subject: Re: Small /etc/src.conf Message-ID: <AANLkTikfE-79gVaaDUYXuTqwW=sg9GVUdSzZs-uQjA9E@mail.gmail.com> In-Reply-To: <AANLkTikYci8WbWEGHierPR6c02MgD6nsAFDN5GuzEYx%2B@mail.gmail.com> References: <1287866401.2580.5.camel@home-yahoo> <AANLkTim7vr%2B6F7=9TX15sojn25HZMEw8PG2U48BCcrjT@mail.gmail.com> <1287873322.2580.16.camel@home-yahoo> <AANLkTikYci8WbWEGHierPR6c02MgD6nsAFDN5GuzEYx%2B@mail.gmail.com>
next in thread | previous in thread | raw e-mail | index | archive | help
On Sat, Oct 23, 2010 at 7:19 PM, Garrett Cooper <gcooper@freebsd.org> wrote= : > On Sat, Oct 23, 2010 at 3:35 PM, Sean Bruno <seanbru@yahoo-inc.com> wrote= : >> On Sat, 2010-10-23 at 14:21 -0700, Rob Farmer wrote: >>> On Sat, Oct 23, 2010 at 13:40, Sean Bruno <seanbru@yahoo-inc.com> wrote= : >>> > Anyone have a src.conf + make.conf that I can steal to build a small >>> > installation of BSD? =A0I've been trying to shrink the installation s= o I >>> > can cram an ISO of BSD across the network into a remote installation >>> > thing in an HP box. >>> >>> Have you checked this: >>> http://phk.freebsd.dk/misc/build_options/ >>> >>> I'm not sure exactly what you're looking for, but in my experience (I >>> care more about build time than size though, and still want a fairly >>> functional system) these are the most important variables to set: >>> >>> NO_MODULES (stick everything in the kernel - tons of stuff is built >>> twice, like ufs support) >>> WITHOUT_PROFILE >>> WITHOUT_LIB32 >>> WITHOUT_CLANG >>> WITHOUT_KERBEROS >>> WITHOUT_CDDL >>> >>> Some of the options involving src/share like WITHOUT_LOCALES seem to >>> kill a lot of files too. >>> >>> Everything else either just skips a couple files (of course, that can >>> add up) or starts to cut into basic functionality (like no man pages), >>> IMHO. >>> >> >> Thanks for the clue, I've come up with some stuff now that got me down >> to ~100MB, but I think I can go smaller. >> src.conf: >> WITHOUT_AMD=3Dtrue >> WITHOUT_APM=3Dtrue >> WITHOUT_BIND=3Dtrue >> WITHOUT_BSNMP=3Dtrue >> WITHOUT_BSD_CPIO=3Dtrue >> WITHOUT_BZIP2=3Dtrue >> WITHOUT_BLUETOOTH=3Dtree >> WITHOUT_CDDL=3Dtrue >> WITHOUT_CLANG=3Dtrue >> WITHOUT_CPP=3Dtrue >> WITHOUT_CRYPT=3Dtrue >> WITHOUT_CTM=3Dtrue >> WITHOUT_CVS=3Dtrue >> WITHOUT_CXX=3Dtrue >> WITHOUT_DICT=3Dtrue >> WITHOUT_EXAMPLES=3Dtrue >> WITHOUT_FREEBSD_UPDATE=3Dtrue >> WITHOUT_GAMES=3Dtrue >> WITHOUT_GDB=3Dtrue >> WITHOUT_GNU=3Dtrue >> WITHOUT_GPIB=3Dtrue >> WITHOUT_GROFF=3Dtrue >> WITHOUT_GCOV=3Dtrue >> WITHOUT_HTML=3Dtrue >> WITHOUT_INET6=3Dtrue >> WITHOUT_INFO=3Dtrue >> #WITHOUT_INSTALLLIB=3Dtrue >> WITHOUT_IPFILTER=3Dtrue >> WITHOUT_IPFW=3Dtrue >> WITHOUT_IPX=3Dtrue >> WITHOUT_IPX_SUPPORT=3Dtrue >> WITHOUT_JAIL=3Dtrue >> WITHOUT_LIB32=3Dtrue >> WITHOUT_LOCATE=3Dtrue >> WITHOUT_LPR=3Dtrue >> WITHOUT_MAIL=3Dtrue >> WITHOUT_MAN=3Dtrue >> WITHOUT_NCP=3Dtrue >> WITHOUT_NDIS=3Dtrue >> WITHOUT_NETGRAPH=3Dtrue >> WITHOUT_NIS=3Dtrue >> WITHOUT_NLS=3Dtrue >> WITHOUT_NLS_CATALOGS=3Dtrue >> WITHOUT_NS_CACHING=3Dtrue >> WITHOUT_NTP=3Dtrue >> WITHOUT_OBJC=3Dtrue >> WITHOUT_PAM=3Dtrue >> WITHOUT_PF=3Dtrue >> WITHOUT_PORTSNAP=3Dtrue >> WITHOUT_PPP=3Dtrue >> WITHOUT_PROFILE=3Dtrue >> WITHOUT_QUOTAS=3Dtrue >> WITHOUT_RCMDS=3Dtrue >> WITHOUT_RCS=3Dtrue >> WITHOUT_RESCUE=3Dtrue >> WITHOUT_ROUTED=3Dtrue >> WITHOUT_SHAREDOCS=3Dtrue >> WITHOUT_SYSINSTALL=3Dtrue >> WITHOUT_TCSH=3Dtrue >> WITHOUT_TELNET=3Dtrue >> WITHOUT_TOOLCHAIN=3Dtrue >> WITHOUT_WIRELESS=3Dtrue >> >> make.conf: >> NO_MODULES=3Dtrue >> NO_SHARE=3Dtrue > > =A0 =A0Looks about right (I don't optimize things that much in all cases, > but I've come close before). Here's a PR I opened that would tune the > rc.d scripts, because you'll probably notice that there's a ton of > noise involved at bootup when you do the above items: > > http://www.freebsd.org/cgi/query-pr.cgi?pr=3Dconf/145344 > > =A0 =A0If desired, I can update the patch with latest HEAD for the PR. I > would need for someone to review the item though and help commit it. One thing though: being pedantic and setting true is ok, but just doing: WITHOUT_TCSH=3D etc is sufficient. Another thing you could do is: FEATURES=3D \ AMD \ APM \ ... WIRELESS .for feature in ${FEATURES} WITHOUT_${feature}=3D .endfor (that's what I did in one instance where I source the src.conf file from another Makefile). It's up to you depending on your target audience for the file on what approach you want to take. Cheers, -Garrett
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?AANLkTikfE-79gVaaDUYXuTqwW=sg9GVUdSzZs-uQjA9E>