├── .gitignore ├── BOOK ├── INSTALL.md ├── Makefile ├── arm-index.xml ├── beyond │ ├── chapter.xml │ └── common │ │ ├── dropbear.xml │ │ ├── introduction.xml │ │ ├── netplug.xml │ │ ├── packages.xml │ │ ├── patches.xml │ │ ├── wireless_tools.xml │ │ └── zlib.xml ├── bootable │ ├── chapter.xml │ └── common │ │ ├── bootloaders.xml │ │ ├── fstab.xml │ │ ├── introduction.xml │ │ └── kernel.xml ├── bootscripts │ ├── chapter.xml │ └── common │ │ ├── bootscripts.xml │ │ ├── hostname.xml │ │ ├── hosts.xml │ │ ├── inittab.xml │ │ ├── introduction.xml │ │ ├── mdev.xml │ │ ├── network.xml │ │ └── profile.xml ├── cleanup │ ├── chapter.xml │ ├── chowning.xml │ ├── copy-to-target.xml │ └── copylibs.xml ├── cross-tools │ ├── arm-chapter.xml │ ├── arm │ │ ├── gcc-final.xml │ │ ├── gcc-static.xml │ │ └── variables.xml │ ├── common │ │ ├── abi.xml │ │ ├── binutils.xml │ │ ├── cflags.xml │ │ ├── gcc-final.xml │ │ ├── gcc-static.xml │ │ ├── introduction.xml │ │ ├── libc.xml │ │ ├── linux-headers.xml │ │ ├── sysroot.xml │ │ ├── toolchain.xml │ │ └── variables.xml │ ├── mips-chapter.xml │ ├── mips │ │ ├── abi.xml │ │ ├── gcc-final.xml │ │ ├── gcc-static.xml │ │ └── variables.xml │ ├── x86-chapter.xml │ └── x86 │ │ ├── gcc-final.xml │ │ ├── gcc-static.xml │ │ └── variables.xml ├── filesize.sh ├── final-preps │ ├── aboutclfs.xml │ ├── addinguser.xml │ ├── chapter.xml │ └── settingenviron.xml ├── final-system │ ├── chapter.xml │ └── common │ │ ├── busybox.xml │ │ ├── creatingdirs.xml │ │ ├── creatingfiles.xml │ │ ├── iana-etc.xml │ │ └── introduction.xml ├── general.ent ├── images │ ├── caution.png │ ├── important.png │ ├── note.png │ ├── tip.png │ └── warning.png ├── index.xml ├── introduction │ ├── chapter.xml │ └── common │ │ ├── askforhelp.xml │ │ ├── hostreqs.xml │ │ ├── how.xml │ │ └── resources.xml ├── materials │ ├── chapter.xml │ └── common │ │ ├── creatingbuilddir.xml │ │ ├── introduction.xml │ │ ├── packages.xml │ │ └── patches.xml ├── mips-index.xml ├── packages.ent ├── patches.ent ├── preface │ ├── arm │ │ └── bookinfo.xml │ ├── common │ │ ├── acknowledgements.xml │ │ ├── audience.xml │ │ ├── changelog.xml │ │ ├── dedication.xml │ │ ├── errata.xml │ │ ├── foreword.xml │ │ ├── license.xml │ │ ├── organization.xml │ │ ├── prerequisites.xml │ │ └── typography.xml │ ├── mips │ │ └── bookinfo.xml │ ├── preface.xml │ └── x86 │ │ └── bookinfo.xml ├── schema │ └── docbook │ │ └── 4.5 │ │ └── rng │ │ ├── calstblx.rnc │ │ ├── calstblx.rng │ │ ├── dbhierx.rnc │ │ ├── dbhierx.rng │ │ ├── dbnotnx.rnc │ │ ├── dbnotnx.rng │ │ ├── dbpoolx.rnc │ │ ├── dbpoolx.rng │ │ ├── docbook.rnc │ │ ├── docbook.rng │ │ ├── htmltblx.rnc │ │ └── htmltblx.rng ├── stylesheets │ ├── clfs-chunked.xsl │ ├── clfs-nochunks.xsl │ ├── clfs-pdf.xsl │ ├── dump-commands.xsl │ ├── lfs-xsl │ │ ├── chunk-master.xsl │ │ ├── chunk-slave.xsl │ │ ├── chunkfast.xsl │ │ ├── common.xsl │ │ ├── docbook-xsl-snapshot │ │ │ ├── COPYING │ │ │ ├── VERSION │ │ │ ├── common │ │ │ │ ├── common.xsl │ │ │ │ ├── de.xml │ │ │ │ ├── en.xml │ │ │ │ ├── entities.ent │ │ │ │ ├── es.xml │ │ │ │ ├── fr.xml │ │ │ │ ├── gentext.xsl │ │ │ │ ├── insertfile.xsl │ │ │ │ ├── it.xml │ │ │ │ ├── l10n.dtd │ │ │ │ ├── l10n.xml │ │ │ │ ├── l10n.xsl │ │ │ │ ├── labels.xsl │ │ │ │ ├── olink.xsl │ │ │ │ ├── pi.xsl │ │ │ │ ├── refentry.xsl │ │ │ │ ├── stripns.xsl │ │ │ │ ├── subtitles.xsl │ │ │ │ ├── table.xsl │ │ │ │ ├── targetdatabase.dtd │ │ │ │ ├── targets.xsl │ │ │ │ ├── titles.xsl │ │ │ │ ├── utility.xsl │ │ │ │ ├── zh_cn.xml │ │ │ │ └── zh_tw.xml │ │ │ ├── fo │ │ │ │ ├── admon.xsl │ │ │ │ ├── annotations.xsl │ │ │ │ ├── autoidx-kimber.xsl │ │ │ │ ├── autoidx-kosek.xsl │ │ │ │ ├── autoidx-ng.xsl │ │ │ │ ├── autoidx.xsl │ │ │ │ ├── autotoc.xsl │ │ │ │ ├── axf.xsl │ │ │ │ ├── biblio-iso690.xsl │ │ │ │ ├── biblio.xsl │ │ │ │ ├── block.xsl │ │ │ │ ├── callout.xsl │ │ │ │ ├── component.xsl │ │ │ │ ├── division.xsl │ │ │ │ ├── docbook.xsl │ │ │ │ ├── ebnf.xsl │ │ │ │ ├── fo-rtf.xsl │ │ │ │ ├── fo.xsl │ │ │ │ ├── footnote.xsl │ │ │ │ ├── fop.xsl │ │ │ │ ├── fop1.xsl │ │ │ │ ├── formal.xsl │ │ │ │ ├── glossary.xsl │ │ │ │ ├── graphics.xsl │ │ │ │ ├── highlight.xsl │ │ │ │ ├── htmltbl.xsl │ │ │ │ ├── index.xsl │ │ │ │ ├── info.xsl │ │ │ │ ├── inline.xsl │ │ │ │ ├── keywords.xsl │ │ │ │ ├── lists.xsl │ │ │ │ ├── math.xsl │ │ │ │ ├── pagesetup.xsl │ │ │ │ ├── param.xsl │ │ │ │ ├── passivetex.xsl │ │ │ │ ├── pdf2index │ │ │ │ ├── pi.xsl │ │ │ │ ├── profile-docbook.xsl │ │ │ │ ├── ptc.xsl │ │ │ │ ├── qandaset.xsl │ │ │ │ ├── refentry.xsl │ │ │ │ ├── sections.xsl │ │ │ │ ├── spaces.xsl │ │ │ │ ├── synop.xsl │ │ │ │ ├── table.xsl │ │ │ │ ├── task.xsl │ │ │ │ ├── titlepage.templates.xml │ │ │ │ ├── titlepage.templates.xsl │ │ │ │ ├── titlepage.xsl │ │ │ │ ├── toc.xsl │ │ │ │ ├── verbatim.xsl │ │ │ │ ├── xep.xsl │ │ │ │ └── xref.xsl │ │ │ ├── highlighting │ │ │ │ └── common.xsl │ │ │ ├── html │ │ │ │ └── chunker.xsl │ │ │ ├── lib │ │ │ │ └── lib.xsl │ │ │ ├── profiling │ │ │ │ ├── profile-mode.xsl │ │ │ │ ├── profile.xsl │ │ │ │ ├── strip-attributes.xsl │ │ │ │ └── xsl2profile.xsl │ │ │ └── xhtml │ │ │ │ ├── admon.xsl │ │ │ │ ├── annotations.xsl │ │ │ │ ├── autoidx-kimber.xsl │ │ │ │ ├── autoidx-kosek.xsl │ │ │ │ ├── autoidx-ng.xsl │ │ │ │ ├── autoidx.xsl │ │ │ │ ├── autotoc.xsl │ │ │ │ ├── biblio-iso690.xsl │ │ │ │ ├── biblio.xsl │ │ │ │ ├── block.xsl │ │ │ │ ├── callout.xsl │ │ │ │ ├── changebars.xsl │ │ │ │ ├── chunk-code.xsl │ │ │ │ ├── chunk-common.xsl │ │ │ │ ├── chunk.xsl │ │ │ │ ├── chunker.xsl │ │ │ │ ├── chunkfast.xsl │ │ │ │ ├── chunktoc.xsl │ │ │ │ ├── component.xsl │ │ │ │ ├── division.xsl │ │ │ │ ├── docbook.xsl │ │ │ │ ├── ebnf.xsl │ │ │ │ ├── footnote.xsl │ │ │ │ ├── formal.xsl │ │ │ │ ├── glossary.xsl │ │ │ │ ├── graphics.xsl │ │ │ │ ├── highlight.xsl │ │ │ │ ├── html-rtf.xsl │ │ │ │ ├── html.xsl │ │ │ │ ├── htmltbl.xsl │ │ │ │ ├── index.xsl │ │ │ │ ├── info.xsl │ │ │ │ ├── inline.xsl │ │ │ │ ├── keywords.xsl │ │ │ │ ├── lists.xsl │ │ │ │ ├── maketoc.xsl │ │ │ │ ├── manifest.xsl │ │ │ │ ├── math.xsl │ │ │ │ ├── oldchunker.xsl │ │ │ │ ├── onechunk.xsl │ │ │ │ ├── param.xsl │ │ │ │ ├── pi.xsl │ │ │ │ ├── profile-chunk-code.xsl │ │ │ │ ├── profile-chunk.xsl │ │ │ │ ├── profile-docbook.xsl │ │ │ │ ├── profile-onechunk.xsl │ │ │ │ ├── qandaset.xsl │ │ │ │ ├── refentry.xsl │ │ │ │ ├── sections.xsl │ │ │ │ ├── synop.xsl │ │ │ │ ├── table.xsl │ │ │ │ ├── task.xsl │ │ │ │ ├── titlepage.templates.xsl │ │ │ │ ├── titlepage.xsl │ │ │ │ ├── toc.xsl │ │ │ │ ├── verbatim.xsl │ │ │ │ └── xref.xsl │ │ ├── lfs-l10n.xml │ │ ├── lfs-print.css │ │ ├── lfs.css │ │ ├── nochunks.xsl │ │ ├── pdf.xsl │ │ ├── pdf │ │ │ ├── lfs-admon.xsl │ │ │ ├── lfs-index.xsl │ │ │ ├── lfs-lists.xsl │ │ │ ├── lfs-mixed.xsl │ │ │ ├── lfs-pagesetup.xsl │ │ │ └── lfs-xref.xsl │ │ ├── profile.xsl │ │ └── xhtml │ │ │ ├── lfs-admon.xsl │ │ │ ├── lfs-index.xsl │ │ │ ├── lfs-legalnotice.xsl │ │ │ ├── lfs-mixed.xsl │ │ │ ├── lfs-navigational.xsl │ │ │ ├── lfs-sections.xsl │ │ │ ├── lfs-titles.xsl │ │ │ ├── lfs-toc.xsl │ │ │ └── lfs-xref.xsl │ ├── patcheslist.xsl │ ├── top-index.xsl │ └── wget.xsl ├── the-end │ ├── chapter.xml │ ├── theend.xml │ └── whatnow.xml ├── tidy.conf ├── tidy.sh └── x86-index.xml ├── LICENSE ├── README.md └── patches ├── iana-etc-2.30-update-2.patch └── netplug-1.2.9.2-fixes-1.patch /.gitignore: -------------------------------------------------------------------------------- 1 | /render/ 2 | *.swp 3 | \#*# 4 | *~ 5 | -------------------------------------------------------------------------------- /BOOK/INSTALL.md: -------------------------------------------------------------------------------- 1 | CLFS Book Conversion Tools 2 | ========================== 3 | 4 | After downloading the book source, there are some things that need to be set up 5 | on your computer if you want to convert the XML source into something easier to 6 | read (e.g. HTML, TXT, or PDF). 7 | 8 | If you want to convert the Docbook XML to HTML, install the following: 9 | 10 | * libxml2 11 | * libxslt 12 | * DocBook DTD 13 | * DocBook XSL Stylesheets 14 | * HTMLTidy 15 | 16 | If you want to convert the Docbook XML to TXT, install the above items, and then 17 | install the following: 18 | 19 | * lynx 20 | 21 | If you want to convert the Docbook XML to PDF, install the items listed above 22 | (except lynx) and then install the following: 23 | 24 | * JDK 25 | * FOP and JAI 26 | 27 | On a reasonably recent Debian or Ubuntu, this should suffice: 28 | 29 | ``` 30 | sudo apt install docbook-xml docbook-xsl fop libxml2-utils lynx make xsltproc tidy 31 | ``` 32 | 33 | To actually convert the Docbook XML source into rendered form, which will be 34 | located at ../render by default (override with BASEDIR=), execute: 35 | 36 | * To XHTML: `make` 37 | * To single file XHTML (nochunks): `make nochunks` 38 | * To PDF: `make pdf` 39 | -------------------------------------------------------------------------------- /BOOK/arm-index.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | %general-entities; 6 | ]> 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | Introduction 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | Preparing for the Build 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | Make the Cross-Compile Tools 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | Building the CLFS System 44 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | Beyond CLFS Embedded 55 | 56 | 57 | 58 | 59 | 60 | 61 | 62 | 63 | Cleanup and Boot 64 | 65 | 66 | 67 | 68 | 69 | 70 | 71 | 72 | 73 | -------------------------------------------------------------------------------- /BOOK/beyond/chapter.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | %general-entities; 6 | ]> 7 | 8 | 9 | 10 | 11 | 12 | Beyond CLFS Embedded 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | -------------------------------------------------------------------------------- /BOOK/beyond/common/dropbear.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | %general-entities; 6 | ]> 7 | 8 | 9 | 10 | 11 | Dropbear-&dropbear-version; 12 | 13 | 14 | Dropbear 15 | 16 | 17 | 18 | 19 | 20 | <para>Dropbear is a relatively small SSH server and client. Dropbear has a small 21 | memory footprint suitable for memory-constrained environments, while still having 22 | the same features as OpenSSH. It does not depend on OpenSSL and it has a MIT 23 | style license.</para> 24 | 25 | </sect2> 26 | 27 | <sect2 role="installation"> 28 | <title>Installation of Dropbear 29 | 30 | Fix dropbear so it doesn't install man pages: 31 | 32 | sed -i 's/.*mandir.*//g' Makefile.in 33 | 34 | Configure dropbear: 35 | 36 | CC="${CC} -Os" ./configure --prefix=/usr --host=${CLFS_TARGET} 37 | 38 | We are just telling dropbear to use the default 39 | configuration plus scp. For those for more adventureous, edit options.h 40 | to further configure dropbear. 41 | 42 | Compile the package: 43 | 44 | make MULTI=1 \ 45 | PROGRAMS="dropbear dbclient dropbearkey dropbearconvert scp" 46 | 47 | Install the package: 48 | 49 | make MULTI=1 \ 50 | PROGRAMS="dropbear dbclient dropbearkey dropbearconvert scp" \ 51 | install DESTDIR=${CLFS}/targetfs 52 | 53 | Create the directory for the dropbear key files: 54 | 55 | install -dv ${CLFS}/targetfs/etc/dropbear 56 | 57 | 58 | 59 | 60 | Installation of Dropbear Bootscripts 61 | 62 | From the clfs-bootscripts package, install the Dropbear 63 | bootscripts: 64 | 65 | make install-dropbear DESTDIR=${CLFS}/targetfs 66 | 67 | 68 | 69 | 70 | 71 | Contents of Dropbear 72 | 73 | 74 | Installed programs 75 | 76 | 77 | /usr/bin/dropbearmulti 78 | 79 | 80 | 81 | 82 | 83 | 84 | -------------------------------------------------------------------------------- /BOOK/beyond/common/introduction.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | %general-entities; 6 | ]> 7 | 8 | 9 | 10 | 11 | Introduction 12 | 13 | Now that we have our base system built, we may add some optional 14 | additional networking software. 15 | 16 | 17 | -------------------------------------------------------------------------------- /BOOK/beyond/common/netplug.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | %general-entities; 6 | ]> 7 | 8 | 9 | 10 | 11 | Netplug-&netplug-version; 12 | 13 | 14 | Netplug 15 | 16 | 17 | 18 | 19 | 20 | <para>Netplug is a daemon that detects insertion and removal of network 21 | cables and reacts to bring up or take down the network interface.</para> 22 | 23 | </sect2> 24 | 25 | <sect2 role="installation"> 26 | <title>Installation of Netplug 27 | 28 | Patch netplug to fix issues: 29 | 30 | patch -Np1 -i ../&netplug-patch; 31 | 32 | Compile the package: 33 | 34 | make 35 | 36 | Install the package: 37 | 38 | make DESTDIR=${CLFS}/targetfs install 39 | 40 | 41 | 42 | 43 | Installation of Netplug Bootscripts 44 | 45 | From the clfs-bootscripts package, install the Netplug 46 | bootscripts: 47 | 48 | make install-netplug DESTDIR=${CLFS}/targetfs 49 | 50 | 51 | 52 | 53 | 54 | Contents of Netplug 55 | 56 | 57 | Installed programs 58 | 59 | 60 | /sbin/netplugd 61 | 62 | 63 | 64 | 65 | 66 | 67 | -------------------------------------------------------------------------------- /BOOK/beyond/common/packages.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | %general-entities; 6 | ]> 7 | 8 | 9 | 10 | 11 | Beyond CLFS Packages 12 | 13 | Download or otherwise obtain the following packages: 14 | 15 | 16 | 17 | 18 | Dropbear (&dropbear-version;) - &dropbear-size;: 19 | 20 | Home page: 21 | Download: 22 | MD5 sum: &dropbear-md5; 23 | 24 | 25 | 26 | 27 | Netplug (&netplug-version;) - &netplug-size;: 28 | 29 | Home page: 30 | Download: 31 | MD5 sum: &netplug-md5; 32 | 33 | 34 | 35 | 36 | Wireless Tools (&wireless_tools-version;) - &wireless_tools-size;: 37 | 38 | Home page: 39 | Download: 40 | MD5 sum: &wireless_tools-md5; 41 | 42 | 43 | 44 | 45 | Zlib (&zlib-version;) - &zlib-size;: 46 | 47 | Home page: 48 | Download: 49 | MD5 sum: &zlib-md5; 50 | 51 | 52 | 53 | 54 | 55 | Total size of these packages: about 56 | 57 | 58 | -------------------------------------------------------------------------------- /BOOK/beyond/common/patches.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | %general-entities; 6 | ]> 7 | 8 | 9 | 10 | 11 | Beyond CLFS Patches 12 | 13 | In addition to the packages, several patches are also required. 14 | These patches correct any mistakes in the packages that should be 15 | fixed by the maintainer. The patches also make small modifications to 16 | make the packages easier to work with. The following patches will be 17 | needed in order to build the associated packages: 18 | 19 | 20 | 21 | 22 | Netplug Patch - &netplug-patch-size;: 23 | 24 | Download: 26 | MD5 sum: &netplug-patch-md5; 27 | 28 | 29 | 30 | 31 | 32 | Total size of these patches: about 33 | 34 | 35 | -------------------------------------------------------------------------------- /BOOK/beyond/common/wireless_tools.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | %general-entities; 6 | ]> 7 | 8 | 9 | 10 | 11 | Wireless Tools-&wireless_tools-version; 12 | 13 | 14 | wireless_tools 15 | 16 | 17 | 18 | 19 | 20 | <para>Wireless Tools is the reference implementation of tools supporting the 21 | ability to manipulate the Wireless Extensions API supported by most wireless 22 | LAN networking drivers.</para> 23 | 24 | </sect2> 25 | 26 | <sect2 role="installation"> 27 | <title>Installation of Wireless Tools 28 | 29 | Wireless Tools' Makefile contains 30 | explicitly which gcc, ar, and 31 | ranlib to use. Make sure the 32 | ${CLFS}/cross-tools versions of 33 | these programs are used instead of the host's: 34 | 35 | sed -i s/gcc/\$\{CLFS\_TARGET\}\-gcc/g Makefile 36 | sed -i s/\ ar/\ \$\{CLFS\_TARGET\}\-ar/g Makefile 37 | sed -i s/ranlib/\$\{CLFS\_TARGET\}\-ranlib/g Makefile 38 | 39 | Compile the package: 40 | 41 | There are options that can be passed to make 42 | and make install that will reduce the size and 43 | functionality of the Wireless Tools. See the Wireless Tools 44 | INSTALL file for more information. 45 | 46 | make PREFIX=${CLFS}/targetfs/usr 47 | 48 | Install the package: 49 | 50 | make install PREFIX=${CLFS}/targetfs/usr 51 | 52 | 53 | 54 | 55 | Contents of Wireless Tools 56 | 57 | 58 | Installed programs 59 | Installed libraries 60 | 61 | 62 | iwconfig, iwevent, iwgetid, iwlist,iwpriv, and iwspy 63 | libiw.so 64 | 65 | 66 | 67 | 68 | 69 | 70 | -------------------------------------------------------------------------------- /BOOK/beyond/common/zlib.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | %general-entities; 6 | ]> 7 | 8 | 9 | 10 | 11 | Zlib-&zlib-version; 12 | 13 | 14 | Zlib 15 | 16 | 17 | 18 | 19 | 20 | <para>The Zlib package contains compression and decompression routines 21 | used by some programs.</para> 22 | 23 | </sect2> 24 | 25 | <sect2 role="installation"> 26 | <title>Installation of Zlib 27 | 28 | Prepare Zlib for compilation and set to optimize for size: 29 | 30 | CFLAGS="-Os" ./configure --shared 31 | 32 | 33 | The meaning of the configure options: 34 | 35 | 36 | --shared 37 | 38 | Tells Zlib to build its shared library. 39 | 40 | 41 | 42 | 43 | 44 | Compile the package: 45 | 46 | make 47 | 48 | Install the package: 49 | 50 | make prefix=${CLFS}/cross-tools/${CLFS_TARGET} install 51 | 52 | 53 | 54 | 55 | Contents of Zlib 56 | 57 | 58 | Installed libraries 59 | 60 | 61 | libz.[a,so] 62 | 63 | 64 | 65 | 66 | Short Descriptions 67 | 68 | 69 | 70 | 71 | libz 72 | 73 | Contains compression and decompression 74 | functions used by some programs 75 | 76 | libz 77 | 78 | 79 | 80 | 81 | 82 | 83 | 84 | 85 | 86 | -------------------------------------------------------------------------------- /BOOK/bootable/chapter.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | %general-entities; 6 | ]> 7 | 8 | 9 | 10 | 11 | 12 | Making the CLFS System Bootable 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | -------------------------------------------------------------------------------- /BOOK/bootable/common/bootloaders.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | %general-entities; 6 | ]> 7 | 8 | 9 | 10 | 11 | Bootloaders 12 | 13 | There are many different bootloaders. Creating detailed instructions on 14 | how to use even the more popular ones is difficult as each architecture and 15 | board often has different levels of support or configuration options within 16 | each bootloader. Often, development kits will ship with a bootloader 17 | already configured, if your board comes with a bootloader pre-configured, 18 | it's best to start using that and then venture on to building the bootloader 19 | yourself later. 20 | 21 | A few of the popular bootloaders include: 22 | 23 | 24 | 25 | 26 | Barebox 27 | 28 | 29 | 30 | 31 | CoLo 32 | 33 | 34 | 35 | 36 | GNU GRUB 37 | 38 | 39 | 40 | 41 | Syslinux 42 | 43 | 44 | 45 | 46 | u-boot 47 | 48 | 49 | 50 | 51 | 52 | 53 | -------------------------------------------------------------------------------- /BOOK/bootable/common/fstab.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | %general-entities; 6 | ]> 7 | 8 | 9 | 10 | 11 | Creating the /etc/fstab File 12 | 13 | 14 | /etc/fstab 15 | 16 | 17 | The /etc/fstab file is used by some 18 | programs to determine where file systems are to be mounted by default, 19 | in which order, and which must be checked (for integrity errors) prior 20 | to mounting. Create a new file systems table like this: 21 | 22 | cat > ${CLFS}/targetfs/etc/fstab << "EOF" 23 | # file-system mount-point type options dump fsck 24 | /dev/[xxx] / [fff] defaults 1 1 25 | EOF 26 | 27 | Replace [xxx] 28 | and [fff] 29 | with the values appropriate for the system, for example, mmcblk0p2 31 | and ext4. For details on the 32 | fields in this file, see man 5 fstab. 33 | 34 | You may also add any other file systems, such as swap or other partitions 35 | or network file systems, to this fstab as well. 36 | 37 | 38 | -------------------------------------------------------------------------------- /BOOK/bootable/common/introduction.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | %general-entities; 6 | ]> 7 | 8 | 9 | 10 | 11 | Introduction 12 | 13 | It is time to make the CLFS system bootable. This chapter 14 | discusses creating an fstab file, building a 15 | kernel for the new CLFS system, and installing the boot loader so 16 | that the CLFS system can be selected for booting at startup. 17 | 18 | 19 | 20 | -------------------------------------------------------------------------------- /BOOK/bootscripts/chapter.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | %general-entities; 6 | ]> 7 | 8 | 9 | 10 | 11 | 12 | Setting Up System Bootscripts 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | -------------------------------------------------------------------------------- /BOOK/bootscripts/common/hostname.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | %general-entities; 6 | ]> 7 | 8 | 9 | 10 | 11 | Setting Hostname 12 | 13 | 14 | localnet 15 | configuring 16 | 17 | Part of the job of the bootscripts is 18 | setting the system's hostname. This needs to be configured in the 19 | /etc/HOSTNAME file. 20 | 21 | Create the HOSTNAME file 22 | and enter a hostname by running: 23 | 24 | echo "[clfs]" > ${CLFS}/targetfs/etc/HOSTNAME 25 | 26 | [clfs] needs to be replaced with the 27 | name given to the computer. Do not enter the Fully Qualified 28 | Domain Name (FQDN) here. That information will be put in the 29 | /etc/hosts file in the next section. 30 | 31 | 32 | -------------------------------------------------------------------------------- /BOOK/bootscripts/common/hosts.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | %general-entities; 6 | ]> 7 | 8 | 9 | 10 | 11 | Customizing the /etc/hosts File 12 | 13 | 14 | /etc/hosts 15 | 16 | 17 | 18 | localnet 19 | /etc/hosts 20 | 21 | 22 | network 23 | /etc/hosts 24 | 25 | If a network card is to be configured, decide on the IP address, 26 | FQDN, and possible aliases for use in the 27 | /etc/hosts file. The syntax is: 28 | 29 | <IP address> myhost.example.org aliases 30 | 31 | Unless the computer is to be visible to the Internet (i.e., 32 | there is a registered domain and a valid block of assigned IP 33 | addresses—most users do not have this), make sure that the IP 34 | address is in the private network IP address range. Valid ranges 35 | are: 36 | 37 | Class Networks 38 | A 10.0.0.0 39 | B 172.16.0.0 through 172.31.0.255 40 | C 192.168.0.0 through 192.168.255.255 41 | 42 | A valid IP address could be 192.168.1.1. A valid FQDN for this 43 | IP could be www.linuxfromscratch.org (not recommended 44 | because this is a valid registered domain address and could cause 45 | domain name server issues). 46 | 47 | Even if not using a network card, an FQDN is still required. 48 | This is necessary for certain programs to operate correctly. 49 | 50 | Create the /etc/hosts file by running: 51 | 52 | cat > ${CLFS}/targetfs/etc/hosts << "EOF" 53 | # Begin /etc/hosts (network card version) 54 | 55 | 127.0.0.1 localhost 56 | [192.168.1.1] [<HOSTNAME>.example.org] [HOSTNAME] 57 | 58 | # End /etc/hosts (network card version) 59 | EOF 60 | 61 | The [192.168.1.1] and 62 | [<HOSTNAME>.example.org] 63 | values need to be changed for specific users or requirements (if 64 | assigned an IP address by a network/system administrator and the 65 | machine will be connected to an existing network). 66 | 67 | 68 | If a network card is not going to be configured, create the 69 | /etc/hosts file by running: 70 | 71 | cat > ${CLFS}/targetfs/etc/hosts << "EOF" 72 | # Begin /etc/hosts (no network card version) 73 | 74 | 127.0.0.1 [<HOSTNAME>.example.org] [HOSTNAME] localhost 75 | 76 | # End /etc/hosts (no network card version) 77 | EOF 78 | 79 | 80 | -------------------------------------------------------------------------------- /BOOK/bootscripts/common/inittab.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | %general-entities; 6 | ]> 7 | 8 | 9 | 10 | 11 | Creating /etc/inittab 12 | 13 | 14 | /etc/inittab 15 | 16 | 17 | Is the file that specifices how to boot and shutdown a system. 18 | 19 | Now we will create the inittab file for use with our system, 20 | please note that if you'd like a login prompt on a serial console to 21 | uncomment enabling of this and verify the serial port device name as 22 | many embedded boards have serial ports which are not named 'ttyS': 23 | 24 | cat > ${CLFS}/targetfs/etc/inittab<< "EOF" 25 | # /etc/inittab 26 | 27 | ::sysinit:/etc/rc.d/startup 28 | 29 | tty1::respawn:/sbin/getty 38400 tty1 30 | tty2::respawn:/sbin/getty 38400 tty2 31 | tty3::respawn:/sbin/getty 38400 tty3 32 | tty4::respawn:/sbin/getty 38400 tty4 33 | tty5::respawn:/sbin/getty 38400 tty5 34 | tty6::respawn:/sbin/getty 38400 tty6 35 | 36 | # Put a getty on the serial line (for a terminal) 37 | # uncomment this line if your using a serial console 38 | #::respawn:/sbin/getty -L ttyS0 115200 vt100 39 | 40 | ::shutdown:/etc/rc.d/shutdown 41 | ::ctrlaltdel:/sbin/reboot 42 | EOF 43 | 44 | 45 | -------------------------------------------------------------------------------- /BOOK/bootscripts/common/introduction.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | %general-entities; 6 | ]> 7 | 8 | 9 | 10 | 11 | Introduction 12 | 13 | This chapter details how to install and configure the CLFS-Bootscripts 14 | package. Most of these scripts will work without modification, but a few 15 | require additional configuration files because they deal with 16 | hardware-dependent information. 17 | 18 | System-V style init scripts are employed in this book because they 19 | are widely used. For additional options, a hint detailing the BSD style 20 | init setup is available at . 22 | Searching the LFS mailing lists for depinit will also offer 23 | additional choices. 24 | 25 | If using an alternative style of init scripts, skip this chapter and 26 | move on to . 27 | 28 | 29 | -------------------------------------------------------------------------------- /BOOK/bootscripts/common/network.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | %general-entities; 6 | ]> 7 | 8 | 9 | 10 | 11 | Configuring the network Script 12 | 13 | 14 | network 15 | configuring 16 | 17 | 18 | Creating Network Interface Configuration Files 19 | 20 | Which interfaces are brought up and down by the network utilities 21 | depends on the files and directories in the 22 | /etc/network directory. The 23 | interfaces file should contain a 24 | description of the interfaces, as done by Debian, and each of the 25 | directories contain scripts for actions to perform on each type of network 26 | event. 27 | 28 | The following command creates the required directories and the 29 | interfaces file, assuming DHCP will be used for 30 | eth0: 31 | 32 | mkdir -pv ${CLFS}/targetfs/etc/network/if-{post-{up,down},pre-{up,down},up,down}.d 33 | mkdir -pv ${CLFS}/targetfs/usr/share/udhcpc 34 | 35 | cat > ${CLFS}/targetfs/etc/network/interfaces << "EOF" 36 | auto eth0 37 | iface eth0 inet dhcp 38 | EOF 39 | 40 | For DHCP to work properly with udhcpc, the BusyBox dhcp client, a 41 | configuration script is needed. Create a simple script to assign the 42 | provided DHCP address and update /etc/resolv.conf: 43 | 44 | cat > ${CLFS}/targetfs/usr/share/udhcpc/default.script << "EOF" 45 | #!/bin/sh 46 | # udhcpc Interface Configuration 47 | # Based on http://lists.debian.org/debian-boot/2002/11/msg00500.html 48 | # udhcpc script edited by Tim Riker <Tim@Rikers.org> 49 | 50 | [ -z "$1" ] && echo "Error: should be called from udhcpc" && exit 1 51 | 52 | RESOLV_CONF="/etc/resolv.conf" 53 | [ -n "$broadcast" ] && BROADCAST="broadcast $broadcast" 54 | [ -n "$subnet" ] && NETMASK="netmask $subnet" 55 | 56 | case "$1" in 57 | deconfig) 58 | /sbin/ifconfig $interface 0.0.0.0 59 | ;; 60 | 61 | renew|bound) 62 | /sbin/ifconfig $interface $ip $BROADCAST $NETMASK 63 | 64 | if [ -n "$router" ] ; then 65 | while route del default gw 0.0.0.0 dev $interface ; do 66 | true 67 | done 68 | 69 | for i in $router ; do 70 | route add default gw $i dev $interface 71 | done 72 | fi 73 | 74 | echo -n > $RESOLV_CONF 75 | [ -n "$domain" ] && echo search $domain >> $RESOLV_CONF 76 | for i in $dns ; do 77 | echo nameserver $i >> $RESOLV_CONF 78 | done 79 | ;; 80 | esac 81 | 82 | exit 0 83 | EOF 84 | 85 | chmod +x ${CLFS}/targetfs/usr/share/udhcpc/default.script 86 | 87 | 88 | 89 | 90 | -------------------------------------------------------------------------------- /BOOK/bootscripts/common/profile.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | %general-entities; 6 | ]> 7 | 8 | 9 | 10 | 11 | Creating /etc/profile 12 | 13 | 14 | /etc/profile 15 | 16 | 17 | Is the file that specifices how to your environment will function. 18 | 19 | Now we will create the profile file for use with our system: 20 | 21 | cat > ${CLFS}/targetfs/etc/profile<< "EOF" 22 | # /etc/profile 23 | 24 | # Set the initial path 25 | export PATH=/bin:/usr/bin 26 | 27 | if [ `id -u` -eq 0 ] ; then 28 | PATH=/bin:/sbin:/usr/bin:/usr/sbin 29 | unset HISTFILE 30 | fi 31 | 32 | # Setup some environment variables. 33 | export USER=`id -un` 34 | export LOGNAME=$USER 35 | export HOSTNAME=`/bin/hostname` 36 | export HISTSIZE=1000 37 | export HISTFILESIZE=1000 38 | export PAGER='/bin/more ' 39 | export EDITOR='/bin/vi' 40 | 41 | # End /etc/profile 42 | EOF 43 | 44 | 45 | -------------------------------------------------------------------------------- /BOOK/cleanup/chapter.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | %general-entities; 6 | ]> 7 | 8 | 9 | 10 | 11 | 12 | Backup and Cleanup 13 | 14 | 15 | 16 | 17 | 18 | 19 | -------------------------------------------------------------------------------- /BOOK/cleanup/chowning.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | %general-entities; 6 | ]> 7 | 8 | 9 | 10 | 11 | Changing the Ownership of the CLFS System 12 | 13 | Throughout the book, every package has been compiled and installed as 14 | the clfs user. The final system 15 | should be owned by root. 16 | 17 | 18 | 19 | The commands on this page of the book must be performed while 20 | logged in as root. Check that 21 | ${CLFS} is still set: 22 | 23 | echo ${CLFS} 24 | 25 | 26 | 27 | Make root the owner of the 28 | entire CLFS system: 29 | 30 | chown -Rv root:root ${CLFS}/targetfs 31 | 32 | The following files should not to belong to the 33 | root group, they should belong 34 | to the utmp group (group 13): 35 | 36 | chgrp -v 13 ${CLFS}/targetfs/var/run/utmp ${CLFS}/targetfs/var/log/lastlog 37 | 38 | 39 | -------------------------------------------------------------------------------- /BOOK/cleanup/copy-to-target.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | %general-entities; 6 | ]> 7 | 8 | 9 | 10 | 11 | Copy to Target 12 | 13 | We just created a cleaned-up version of our build, now 14 | compress it so it can be archived and transferred to the target. 15 | 16 | Create a tarball of the build: 17 | 18 | install -dv ${CLFS}/build 19 | cd ${CLFS}/targetfs 20 | tar jcfv ${CLFS}/build/clfs-embedded.tar.bz2 * 21 | 22 | Now you can move your compressed tarball to your target 23 | system. This will be different on every embedded device. 24 | 25 | When uncompressing the tarball, make sure to pass tar the "-p" 26 | switch to ensure permissions are preserved. 27 | 28 | 29 | -------------------------------------------------------------------------------- /BOOK/cleanup/copylibs.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | %general-entities; 6 | ]> 7 | 8 | 9 | 10 | 11 | Copy Libraries 12 | 13 | Since the cross compiler was built within 14 | ${CLFS}/cross-tools, the generated libraries need to be 15 | copied to the target: 16 | 17 | cp -vP ${CLFS}/cross-tools/${CLFS_TARGET}/lib/*.so* ${CLFS}/targetfs/lib/ 18 | 19 | Optionally, strip the libraries to reduce their size: 20 | 21 | ${CLFS_TARGET}-strip ${CLFS}/targetfs/lib/* 22 | 23 | 24 | -------------------------------------------------------------------------------- /BOOK/cross-tools/arm-chapter.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | %general-entities; 6 | ]> 7 | 8 | 9 | 10 | 11 | 12 | Constructing Cross-Compile Tools 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | -------------------------------------------------------------------------------- /BOOK/cross-tools/arm/gcc-final.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | %general-entities; 6 | ]> 7 | 8 | 9 | 10 | 11 | 12 | 13 | GCC-&gcc-version; - Final 14 | 15 | 16 | GCC 17 | cross tools, final 18 | 19 | 20 | 23 | 24 | 25 | Installation of GCC Cross Compiler 26 | 27 | 30 | 31 | 34 | 35 | 38 | 39 | 42 | 43 | 46 | 47 | 50 | 51 | ../gcc-&gcc-version;/configure \ 52 | --prefix=${CLFS}/cross-tools \ 53 | --build=${CLFS_HOST} \ 54 | --target=${CLFS_TARGET} \ 55 | --host=${CLFS_HOST} \ 56 | --with-sysroot=${CLFS}/cross-tools/${CLFS_TARGET} \ 57 | --disable-nls \ 58 | --enable-languages=c \ 59 | --enable-c99 \ 60 | --enable-long-long \ 61 | --disable-libmudflap \ 62 | --disable-multilib \ 63 | --with-mpfr-include=$(pwd)/../gcc-&gcc-version;/mpfr/src \ 64 | --with-mpfr-lib=$(pwd)/mpfr/src/.libs \ 65 | --with-arch=${CLFS_ARM_ARCH} \ 66 | --with-float=${CLFS_FLOAT} \ 67 | --with-fpu=${CLFS_FPU} 68 | 69 | 72 | 73 | 76 | 77 | 80 | 81 | 84 | 85 | 88 | 89 | 90 | 91 | 94 | 95 | 96 | -------------------------------------------------------------------------------- /BOOK/cross-tools/common/abi.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | %general-entities; 6 | ]> 7 | 8 | 9 | 10 | 11 | ABI Variables 12 | 13 | Setup for a Particular ABI: 14 | 15 | export CLFS_ABI="[From Chart]" 16 | echo export CLFS_ABI=\""${CLFS_ABI}\"" >> ~/.bashrc 17 | 18 | The following table gives the entires for the different ABI's 19 | that CLFS Embedded supports. Make sure you select one for your build, this 20 | will ensure capatibilty of your build with your target architecture. 21 | 22 | 23 | 24 | 25 | -------------------------------------------------------------------------------- /BOOK/cross-tools/common/cflags.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | %general-entities; 6 | ]> 7 | 8 | 9 | 10 | 11 | Build CFLAGS 12 | 13 | CFLAGS must not be 14 | set during the building of cross-tools. 15 | 16 | To disable CFLAGS 17 | use the following commands: 18 | 19 | unset CFLAGS 20 | echo unset CFLAGS >> ~/.bashrc 21 | 22 | 23 | -------------------------------------------------------------------------------- /BOOK/cross-tools/common/introduction.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | %general-entities; 6 | ]> 7 | 8 | 9 | 10 | 11 | Introduction 12 | 13 | This chapter shows you how to create cross platform tools. 14 | 15 | If for some reason you have to stop and come back later, remember 16 | to use the su - clfs command, and it will setup the 17 | build environment that you left. 18 | 19 | 20 | Common Notes 21 | 22 | 23 | Before issuing the build instructions for a package, the package 24 | should be unpacked as user clfs, 25 | and a cd into the created directory should be 26 | performed. The build instructions assume that the bash 27 | shell is in use. 28 | 29 | 30 | Several of the packages are patched before compilation, but only 31 | when the patch is needed to circumvent a problem or supply a default 32 | configuration. Warning messages about offset or 33 | fuzz may also be encountered when applying a patch. 34 | Do not worry about these warnings, as the patch was still successfully 35 | applied. 36 | 37 | During the compilation of most packages, there will be several 38 | warnings that scroll by on the screen. These are normal and can safely 39 | be ignored. These warnings are as they appear—warnings about 40 | deprecated, but not invalid, use of the C or C++ syntax. C standards 41 | change fairly often, and some packages still use the older standard. 42 | This is not a problem, but does prompt the warning. 43 | 44 | 45 | After installing each package, both in this and the next chapters, 46 | delete its source and build directories, unless specifically instructed 47 | otherwise. 48 | 49 | 50 | 51 | 52 | 53 | -------------------------------------------------------------------------------- /BOOK/cross-tools/common/linux-headers.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | %general-entities; 6 | ]> 7 | 8 | 9 | 10 | 11 | Linux-Headers-&linux-version; 12 | 13 | 14 | Linux-Headers 15 | 16 | 17 | 18 | 19 | 20 | <para>The Linux Kernel contains a make target that installs 21 | <quote>sanitized</quote> kernel headers.</para> 22 | 23 | </sect2> 24 | 25 | <sect2 role="installation"> 26 | <title>Installation of Linux Headers 27 | 28 | For this step you will need the kernel tarball. 29 | 30 | Install the header files that are common to all architectures: 31 | 32 | make mrproper 33 | make ARCH=${CLFS_ARCH} headers_check 34 | make ARCH=${CLFS_ARCH} INSTALL_HDR_PATH=${CLFS}/cross-tools/${CLFS_TARGET} headers_install 35 | 36 | 37 | 38 | 39 | Contents of Linux-Headers 40 | 41 | 42 | Installed headers 43 | 44 | 45 | ${CLFS}/cross-tools/${CLFS_TARGET}/include/{asm,asm-generic,drm,linux,mtd,rdma,scsi,sound,video,xen}/*.h 46 | 47 | 48 | 49 | 50 | Short Descriptions 51 | 52 | 53 | 54 | 55 | ${CLFS}/cross-tools/${CLFS_TARGET}/include/{asm,asm-generic,drm,linux,mtd,rdma,scsi,sound,video,xen}/*.h 56 | 57 | The Linux API headers 58 | 59 | /usr/include/{asm,linux}/*.h 61 | 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | -------------------------------------------------------------------------------- /BOOK/cross-tools/common/sysroot.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | %general-entities; 6 | ]> 7 | 8 | 9 | 10 | 11 | Create the Sysroot Directory 12 | 13 | Create a sysroot directory which will be used when building the cross 14 | compiler and link its usr directory 15 | to itself such that everything installs to the sysroot: 16 | 17 | mkdir -p ${CLFS}/cross-tools/${CLFS_TARGET} 18 | ln -sfv . ${CLFS}/cross-tools/${CLFS_TARGET}/usr 19 | 20 | 21 | -------------------------------------------------------------------------------- /BOOK/cross-tools/common/toolchain.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | %general-entities; 6 | ]> 7 | 8 | 9 | 10 | 11 | ToolChain Variables 12 | 13 | Setup target-specific variables for the compiler 14 | and linkers. This time we keep them: 15 | 16 | echo export CC=\""${CLFS_TARGET}-gcc\"" >> ~/.bashrc 17 | echo export CXX=\""${CLFS_TARGET}-g++\"" >> ~/.bashrc 18 | echo export AR=\""${CLFS_TARGET}-ar\"" >> ~/.bashrc 19 | echo export AS=\""${CLFS_TARGET}-as\"" >> ~/.bashrc 20 | echo export LD=\""${CLFS_TARGET}-ld\"" >> ~/.bashrc 21 | echo export RANLIB=\""${CLFS_TARGET}-ranlib\"" >> ~/.bashrc 22 | echo export READELF=\""${CLFS_TARGET}-readelf\"" >> ~/.bashrc 23 | echo export STRIP=\""${CLFS_TARGET}-strip\"" >> ~/.bashrc 24 | source ~/.bashrc 25 | 26 | 27 | -------------------------------------------------------------------------------- /BOOK/cross-tools/common/variables.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | %general-entities; 6 | ]> 7 | 8 | 9 | 10 | 11 | Build Variables 12 | 13 | Setting Host and Target 14 | 15 | export CLFS_HOST=$(echo ${MACHTYPE} | sed "s/-[^-]*/-cross/") 16 | export CLFS_TARGET="[target triplet]" 17 | 18 | Now we will set the architecture and endianess of the CPU based 19 | on the target triplet provided above: 20 | 21 | export CLFS_ARCH=$(echo ${CLFS_TARGET} | sed -e 's/-.*//' -e 's/i.86/i386/') 22 | export CLFS_ENDIAN=little 23 | 24 | Now we will add this to ~/.bashrc, just in 25 | case you have to exit and restart building later: 26 | 27 | echo export CLFS_HOST=\""${CLFS_HOST}\"" >> ~/.bashrc 28 | echo export CLFS_TARGET=\""${CLFS_TARGET}\"" >> ~/.bashrc 29 | echo export CLFS_ARCH=\""${CLFS_ARCH}\"" >> ~/.bashrc 30 | echo export CLFS_ENDIAN=\""${CLFS_ENDIAN}\"" >> ~/.bashrc 31 | 32 | 33 | -------------------------------------------------------------------------------- /BOOK/cross-tools/mips-chapter.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | %general-entities; 6 | ]> 7 | 8 | 9 | 10 | 11 | 12 | Constructing Cross-Compile Tools 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | -------------------------------------------------------------------------------- /BOOK/cross-tools/mips/abi.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | %general-entities; 6 | ]> 7 | 8 | 9 | 10 | 11 | ABI Variables 12 | 13 | 16 | 17 | 20 | 21 | 24 | 25 | 26 | List of Build Variables 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | ABI 38 | CLFS_ABI=Value 39 | Notes 40 | 41 | 42 | 43 | 44 | 45 | O32 46 | 32 47 | For 32 bit CPUs only 48 | 49 | 50 | N32 51 | n32 52 | For 64 bit CPUs operating in 32 bit mode 53 | 54 | 55 | N64 56 | 64 57 | For 64 bit CPUs operating in 64 bit mode 58 | 59 | 60 | 61 | 62 | 63 |
64 | 65 |
66 | 67 | -------------------------------------------------------------------------------- /BOOK/cross-tools/mips/gcc-final.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | %general-entities; 6 | ]> 7 | 8 | 9 | 10 | 11 | 12 | 13 | GCC-&gcc-version; - Final 14 | 15 | 16 | GCC 17 | cross tools, final 18 | 19 | 20 | 23 | 24 | 25 | Installation of GCC Cross Compiler 26 | 27 | 30 | 31 | 34 | 35 | 38 | 39 | 42 | 43 | 46 | 47 | 50 | 51 | ../gcc-&gcc-version;/configure \ 52 | --prefix=${CLFS}/cross-tools \ 53 | --build=${CLFS_HOST} \ 54 | --target=${CLFS_TARGET} \ 55 | --host=${CLFS_HOST} \ 56 | --with-sysroot=${CLFS}/cross-tools/${CLFS_TARGET} \ 57 | --disable-nls \ 58 | --enable-languages=c \ 59 | --enable-c99 \ 60 | --enable-long-long \ 61 | --disable-libmudflap \ 62 | --disable-multilib \ 63 | --with-mpfr-include=$(pwd)/../gcc-&gcc-version;/mpfr/src \ 64 | --with-mpfr-lib=$(pwd)/mpfr/src/.libs \ 65 | --with-abi=${CLFS_ABI} \ 66 | --with-arch=mips${CLFS_MIPS_LEVEL} \ 67 | --with-float=${CLFS_FLOAT} \ 68 | --with-endian=${CLFS_ENDIAN} 69 | 70 | 73 | 74 | 77 | 78 | 81 | 82 | 85 | 86 | 89 | 90 | 91 | 92 | 95 | 96 | 97 | -------------------------------------------------------------------------------- /BOOK/cross-tools/x86-chapter.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | %general-entities; 6 | ]> 7 | 8 | 9 | 10 | 11 | 12 | Constructing Cross-Compile Tools 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | -------------------------------------------------------------------------------- /BOOK/cross-tools/x86/gcc-final.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | %general-entities; 6 | ]> 7 | 8 | 9 | 10 | 11 | 12 | 13 | GCC-&gcc-version; - Final 14 | 15 | 16 | GCC 17 | cross tools, final 18 | 19 | 20 | 23 | 24 | 25 | Installation of GCC Cross Compiler 26 | 27 | 30 | 31 | 34 | 35 | 38 | 39 | 42 | 43 | 46 | 47 | 50 | 51 | ../gcc-&gcc-version;/configure \ 52 | --prefix=${CLFS}/cross-tools \ 53 | --build=${CLFS_HOST} \ 54 | --target=${CLFS_TARGET} \ 55 | --host=${CLFS_HOST} \ 56 | --with-sysroot=${CLFS}/cross-tools/${CLFS_TARGET} \ 57 | --disable-nls \ 58 | --enable-languages=c \ 59 | --enable-c99 \ 60 | --enable-long-long \ 61 | --disable-libmudflap \ 62 | --disable-multilib \ 63 | --with-mpfr-include=$(pwd)/../gcc-&gcc-version;/mpfr/src \ 64 | --with-mpfr-lib=$(pwd)/mpfr/src/.libs \ 65 | --with-arch=${CLFS_CPU} 66 | 67 | 70 | 71 | 74 | 75 | 78 | 79 | 82 | 83 | 86 | 87 | 88 | 89 | 92 | 93 | 94 | -------------------------------------------------------------------------------- /BOOK/cross-tools/x86/variables.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | %general-entities; 6 | ]> 7 | 8 | 9 | 10 | 11 | Build Variables 12 | 13 | Setting Host and Target 14 | 15 | During the building of the cross-compile tools you will need to 16 | set a few variables that will be dependent on your particular needs. 17 | You will need to set the target triplet for the target architecture, and the 18 | CPU type. If you do not know what triplet or CPU type you want, 19 | you can use the table as a reference. Set 20 | the command using the method listed below: 21 | 22 | export CLFS_HOST=$(echo ${MACHTYPE} | sed "s/-[^-]*/-cross/") 23 | export CLFS_TARGET=[target triplet] 24 | export CLFS_CPU=[cpu type] 25 | 26 | 27 | Processor Type and Target Triplets 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | Processor 40 | Target Triplet 41 | CPU Type 42 | Note 43 | 44 | 45 | 46 | 47 | 48 | 486 Compatibles 49 | i486-linux-musl 50 | i486 51 | Intel's i486 52 | 53 | 54 | Pentium, K6, 586 Compatibles 55 | i586-linux-musl 56 | i586 57 | Intel Pentium without MMX 58 | 59 | 60 | Pentium II, Pentium III, Pentium 4 61 | i686-linux-musl 62 | i686 63 | PentiumPro instruction set 64 | 65 | 66 | Athlon 67 | i686-linux-musl 68 | athlon 69 | AMD 32 bit Athlon 70 | 71 | 72 | Opteron 73 | x86_64-linux-musl 74 | k8 75 | AMD K8 processors with x86-64 76 | 77 | 78 | 79 | 80 | 81 |
82 | 83 | Now set the architecture of the CPU: 84 | 85 | export CLFS_ARCH="x86" 86 | 87 | Now we will add this to ~/.bashrc, just in 88 | case you have to exit and restart building later: 89 | 90 | echo export CLFS_HOST=\""${CLFS_HOST}\"" >> ~/.bashrc 91 | echo export CLFS_TARGET=\""${CLFS_TARGET}\"" >> ~/.bashrc 92 | echo export CLFS_ARCH=\""${CLFS_ARCH}\"" >> ~/.bashrc 93 | echo export CLFS_CPU=\""${CLFS_CPU}\"" >> ~/.bashrc 94 | 95 |
96 | -------------------------------------------------------------------------------- /BOOK/filesize.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | FILENAME=$1 4 | 5 | if [ "${FILENAME}" = "" ]; then 6 | echo "To Calculate the proper file size use the following command." 7 | echo "$0 filename" 8 | exit 255 9 | else 10 | FILESIZE=$(ls -l ${FILENAME} | cut -f5 -d' ') 11 | ((size=${FILESIZE}/1024)) 12 | if [ "${size}" = "0" ]; then 13 | size=$(echo .$(echo ${FILESIZE} | cut -b1)) 14 | fi 15 | FILEMD5SUM=$(md5sum ${FILENAME}) 16 | 17 | echo "${size} KB" 18 | echo "${FILEMD5SUM}" 19 | fi 20 | -------------------------------------------------------------------------------- /BOOK/final-preps/aboutclfs.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | %general-entities; 6 | ]> 7 | 8 | 9 | 10 | 11 | About $CLFS 12 | 13 | Throughout this book, the environment variable CLFS will 14 | be used several times. It is paramount that this variable is always defined. 15 | It should be set to the mount point chosen for the CLFS partition. 16 | Check that the CLFS variable is set up properly with: 17 | 18 | echo ${CLFS} 19 | 20 | Make sure the output shows the path to the CLFS partition's mount 21 | point, which is /mnt/clfs if the 22 | provided example was followed. If the output is incorrect, the 23 | variable can be set with: 24 | 25 | export CLFS=/mnt/clfs 26 | 27 | Having this variable set is beneficial in that commands such as 28 | install -d ${CLFS}/tools can be typed literally. The shell 29 | will automatically replace ${CLFS} with 30 | /mnt/clfs (or whatever the variable was set to) when it 31 | processes the command line. 32 | 33 | Do not forget to check that ${CLFS} is set whenever 34 | you leave and reenter the current working environment (as when doing a 35 | su to root or 36 | another user). 37 | 38 | 39 | -------------------------------------------------------------------------------- /BOOK/final-preps/chapter.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | %general-entities; 6 | ]> 7 | 8 | 9 | 10 | 11 | 12 | Final Preparations 13 | 14 | 15 | 16 | 17 | 18 | 19 | -------------------------------------------------------------------------------- /BOOK/final-system/chapter.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | %general-entities; 6 | ]> 7 | 8 | 9 | 10 | 11 | 12 | Installing Basic System Software 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | -------------------------------------------------------------------------------- /BOOK/final-system/common/creatingdirs.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | %general-entities; 6 | ]> 7 | 8 | 9 | 10 | 11 | Creating Directories 12 | 13 | It is time to create some structure in the target CLFS file system. 14 | Create a standard directory tree by issuing the following commands: 15 | 16 | mkdir -pv ${CLFS}/targetfs/{bin,boot,dev,etc,home,lib/{firmware,modules}} 17 | mkdir -pv ${CLFS}/targetfs/{mnt,opt,proc,sbin,srv,sys} 18 | mkdir -pv ${CLFS}/targetfs/var/{cache,lib,local,lock,log,opt,run,spool} 19 | install -dv -m 0750 ${CLFS}/targetfs/root 20 | install -dv -m 1777 ${CLFS}/targetfs/tmp 21 | mkdir -pv ${CLFS}/targetfs/usr/{,local/}{bin,include,lib,sbin,share,src} 22 | 23 | Directories are, by default, created with permission mode 755, but 24 | this is not desirable for all directories. In the commands above, two 25 | changes are made—one to the home directory of user root, and another to the directories for 27 | temporary files. 28 | 29 | The first mode change ensures that not just anybody can enter 30 | the /root directory—the 31 | same as a normal user would do with his or her home directory. The 32 | second mode change makes sure that any user can write to the 33 | /tmp and /var/tmp directories, but cannot remove 35 | another user's files from them. The latter is prohibited by the so-called 36 | sticky bit, the highest bit (1) in the 1777 bit mask. 37 | 38 | 39 | FHS Compliance Note 40 | 41 | The directory tree is based on the Filesystem Hierarchy Standard (FHS) 42 | (available at ). 43 | 44 | 45 | 46 | 47 | -------------------------------------------------------------------------------- /BOOK/final-system/common/iana-etc.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | %general-entities; 6 | ]> 7 | 8 | 9 | 10 | 11 | iana-etc-&iana-etc-version; 12 | 13 | 14 | iana-etc 15 | 16 | 17 | 18 | 19 | 20 | <para>The iana-etc package provides data for network services and 21 | protocols.</para> 22 | 23 | </sect2> 24 | 25 | <sect2 role="installation"> 26 | <title>Installation of Iana-Etc 27 | 28 | iana-etc comes with outdated data and IANA has changed the 29 | download location used to obtain up-to-date data. Apply the following patch 30 | to correct the download location: 31 | 32 | patch -Np1 -i ../&iana-etc-update-patch; 33 | 34 | Update the data used to the current IANA lists: 35 | make get 36 | 37 | 38 | The following command converts the raw data provided by IANA into 39 | the correct formats for the /etc/protocols and 40 | /etc/services data files: 41 | 42 | make STRIP=yes 43 | 44 | Install the package: 45 | 46 | make DESTDIR=${CLFS}/targetfs install 47 | 48 | 49 | 50 | 51 | Contents of iana-etc 52 | 53 | 54 | Installed files 55 | 56 | 57 | /etc/protocols and /etc/services 58 | 59 | 60 | 61 | 62 | Short Descriptions 63 | 64 | 65 | 66 | 67 | /etc/protocols 68 | 69 | Describes the various DARPA Internet protocols that are 70 | available from the TCP/IP subsystem 71 | 72 | /etc/protocols 73 | 74 | 75 | 76 | 77 | 78 | /etc/services 79 | 80 | Provides a mapping between friendly textual names for internet 81 | services, and their underlying assigned port numbers and protocol 82 | types 83 | 84 | /etc/services 85 | 86 | 87 | 88 | 89 | 90 | 91 | 92 | 93 | 94 | -------------------------------------------------------------------------------- /BOOK/final-system/common/introduction.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | %general-entities; 6 | ]> 7 | 8 | 9 | 10 | 11 | Introduction 12 | 13 | In this chapter, we enter the building site and start 14 | constructing the CLFS system in earnest. The installation of this 15 | software is straightforward. Although in many cases the installation 16 | instructions could be made shorter and more generic, we have opted 17 | to provide the full instructions for every package to minimize the 18 | possibilities for mistakes. The key to learning what makes a Linux 19 | system work is to know what each package is used for and why the user 20 | (or the system) needs it. For every installed package, a summary of 21 | its contents is given, followed by concise descriptions of each 22 | program and library the package installed. 23 | 24 | The order that packages are installed in this chapter needs to 25 | be strictly followed to ensure that no program accidentally acquires a 26 | path referring to ${CLFS}/cross-tools 27 | hard-wired into it. For the same reason, do not compile packages in 28 | parallel. Compiling in parallel may save time (especially on dual-CPU 29 | machines), but it could result in a program containing a hard-wired 30 | path to ${CLFS}/cross-tools, which will 31 | cause the program to stop working when that directory is 32 | removed. 33 | 34 | 35 | -------------------------------------------------------------------------------- /BOOK/general.ent: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | %packages-entities; 38 | 39 | 40 | %patches-entities; 41 | -------------------------------------------------------------------------------- /BOOK/images/caution.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bradfa/clfs-embedded-pregithub/173cc96fc136fe34ea4d46c31b387012aa253f10/BOOK/images/caution.png -------------------------------------------------------------------------------- /BOOK/images/important.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bradfa/clfs-embedded-pregithub/173cc96fc136fe34ea4d46c31b387012aa253f10/BOOK/images/important.png -------------------------------------------------------------------------------- /BOOK/images/note.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bradfa/clfs-embedded-pregithub/173cc96fc136fe34ea4d46c31b387012aa253f10/BOOK/images/note.png -------------------------------------------------------------------------------- /BOOK/images/tip.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bradfa/clfs-embedded-pregithub/173cc96fc136fe34ea4d46c31b387012aa253f10/BOOK/images/tip.png -------------------------------------------------------------------------------- /BOOK/images/warning.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bradfa/clfs-embedded-pregithub/173cc96fc136fe34ea4d46c31b387012aa253f10/BOOK/images/warning.png -------------------------------------------------------------------------------- /BOOK/index.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | %general-entities; 6 | ]> 7 | 8 | 9 | Cross-Compiled Linux From Scratch - Embedded 10 | Version &version; 11 | 12 | 13 | 14 | Andrew 15 | Bradford 16 | 17 | 18 | Joe 19 | Ciccone 20 | 21 | 22 | Jim 23 | Gifford 24 | 25 | 26 | Maarten 27 | Lankhorst 28 | 29 | 30 | Ryan 31 | Oliver 32 | 33 | 34 | 35 | 36 | 2005–&year; 37 | Andrew Bradford, Joe Ciccone, Jim Gifford, Maarten Lankhorst, & Ryan Oliver 38 | 39 | 40 | 41 | 42 | -------------------------------------------------------------------------------- /BOOK/introduction/chapter.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | %general-entities; 6 | ]> 7 | 8 | 9 | 10 | 11 | 12 | Introduction 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | -------------------------------------------------------------------------------- /BOOK/introduction/common/resources.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | %general-entities; 6 | ]> 7 | 8 | 9 | 10 | 11 | Resources 12 | 13 | 14 | FAQ 15 | 16 | If during the building of the CLFS system you encounter any 17 | errors, have any questions, or think there is a typo in the book, 18 | please start by consulting the Frequently Asked Questions (FAQ) 19 | that is located at . 20 | 21 | 22 | 23 | 24 | Mailing Lists 25 | 26 | The clfs.org server hosts a number of 27 | mailing lists used for the development of the CLFS project. These lists 28 | include the main development and support lists, among others. If the 29 | FAQ does not solve the problem you are having, the next step would be to 30 | search the mailing lists at . 31 | 32 | For information on the different lists, how to subscribe, archive 33 | locations, and additional information, visit 34 | . 35 | 36 | 37 | 38 | 39 | IRC 40 | 41 | Several members of the CLFS community offer assistance on our 42 | community Internet Relay Chat (IRC) network. Before using this support, 43 | please make sure that your question is not already answered in the CLFS 44 | FAQ or the mailing list archives. You can find the IRC network at 45 | chat.freenode.net. The support channel for cross-lfs 46 | is named #cross-lfs. If you need to show people the output of your 47 | problems, please use and 48 | reference the pastebin URL when asking your questions. 49 | 50 | 51 | 52 | 53 | Mirror Sites 54 | 55 | The CLFS project has a number of world-wide mirrors to make 56 | accessing the website and downloading the required packages more 57 | convenient. Please visit for 58 | CLFS mirror information. 59 | 60 | 61 | 62 | 63 | Contact Information 64 | 65 | Please direct all your questions and comments to one of the 66 | CLFS mailing lists (see above). 67 | 68 | 69 | 70 | 71 | -------------------------------------------------------------------------------- /BOOK/materials/chapter.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | %general-entities; 6 | ]> 7 | 8 | 9 | 10 | 11 | 12 | Build Directory, Packages, and Patches 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | -------------------------------------------------------------------------------- /BOOK/materials/common/creatingbuilddir.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | %general-entities; 6 | ]> 7 | 8 | 9 | 10 | 11 | Creating Build and Sources Directories 12 | 13 | Create a directory for the CLFS build (the exact location is up to 14 | you): 15 | 16 | mkdir -p /mnt/clfs 17 | 18 | Assign it to the CLFS environment variable: 19 | 20 | export CLFS=/mnt/clfs 21 | 22 | Ensure that this new directory has permissions that are not too 23 | restrictive such that you can write to it as a non-root user. 24 | 25 | chmod 777 ${CLFS} 26 | 27 | Downloaded packages and patches will need to be stored somewhere 28 | that is conveniently available throughout the entire build. A working 29 | directory is also required to unpack the sources and build them. 30 | ${CLFS}/sources can be used both 31 | as the place to store the tarballs and patches and as a working 32 | directory. 33 | 34 | Create a directory to store the sources: 35 | 36 | mkdir -v ${CLFS}/sources 37 | 38 | 39 | -------------------------------------------------------------------------------- /BOOK/materials/common/introduction.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | %general-entities; 6 | ]> 7 | 8 | 9 | 10 | 11 | Introduction 12 | 13 | This chapter creates a directory where the cross compiler toolchain wil 14 | be built and a directory where sources are kept. It includes a list of 15 | packages that need to be downloaded for building a basic Linux 16 | system. 17 | 18 | The listed version numbers correspond to versions of the software that 19 | are known to work, and this book is based on their use. We highly recommend 20 | not using newer or older versions because the build commands for one version may not 21 | work with another version. 22 | 23 | Download locations may not always be accessible. If a download 24 | location has changed since this book was published, Google () provides a useful search engine for 26 | most packages. 27 | 28 | 29 | -------------------------------------------------------------------------------- /BOOK/materials/common/patches.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | %general-entities; 6 | ]> 7 | 8 | 9 | 10 | 11 | Needed Patches 12 | 13 | In addition to the packages, several patches are also required. 14 | These patches correct any mistakes in the packages that should be 15 | fixed by the maintainer. The patches also make small modifications to 16 | make the packages easier to work with. The following patches will be 17 | needed to build a CLFS system: 18 | 19 | 20 | 21 | 31 | 32 | 33 | Iana-Etc Update Patch - &iana-etc-update-patch-size;: 34 | 35 | Download: 37 | MD5 sum: &iana-etc-update-patch-md5; 38 | 39 | 40 | 41 | 42 | 43 | Total size of these patches: about 44 | 45 | 46 | -------------------------------------------------------------------------------- /BOOK/mips-index.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | %general-entities; 6 | ]> 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | Introduction 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | Preparing for the Build 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | Make the Cross-Compile Tools 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | Building the CLFS System 44 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | Beyond CLFS Embedded 55 | 56 | 57 | 58 | 59 | 60 | 61 | 62 | 63 | Cleanup and Boot 64 | 65 | 66 | 67 | 68 | 69 | 70 | 71 | 72 | 73 | -------------------------------------------------------------------------------- /BOOK/patches.ent: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | -------------------------------------------------------------------------------- /BOOK/preface/arm/bookinfo.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | %general-entities; 6 | ]> 7 | 8 | 9 | 10 | 13 | 14 | Version &version-arm; 15 | 16 | 19 | 20 | 23 | 24 | 25 | -------------------------------------------------------------------------------- /BOOK/preface/common/acknowledgements.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | %general-entities; 6 | ]> 7 | 8 | 9 | Cross-LFS Acknowledgements 10 | 11 | 12 | The CLFS team would like to acknowledge people who 13 | have assisted in making the book what it is today. 14 | 15 | Our Leaders: 16 | 17 | 18 | 19 | Ryan Oliver - Build Process Developer. 20 | 21 | 22 | Joe Ciccone - Lead Developer. 23 | 24 | 25 | Jim Gifford - Lead Developer. 26 | 27 | 28 | 29 | Our CLFS Team: 30 | 31 | 32 | 33 | Andrew Bradford - Embedded Developer. 34 | 35 | 36 | Manuel Canales Esparcia - Book XML. 37 | 38 | 39 | Justin Knierim - Website Architect. 40 | 41 | 42 | Maarten Lankhorst - MIPS/WRT Embedded Developer. 43 | 44 | 45 | Chris Staub - Testing and Quality Control. 46 | 47 | 48 | Zack Winkles - Testing and Quality Control. 49 | 50 | 51 | 52 | 60 | 73 | 74 | Thank you all for your support. 75 | 76 | 77 | -------------------------------------------------------------------------------- /BOOK/preface/common/dedication.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | %general-entities; 6 | ]> 7 | 8 | 9 | Dedication 10 | This book is dedicated 11 | 12 | -------------------------------------------------------------------------------- /BOOK/preface/common/errata.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | %general-entities; 6 | ]> 7 | 8 | 9 | 10 | 11 | Errata 12 | 13 | The software used to create a CLFS system is constantly being 14 | updated and enhanced. Security warnings and bug fixes may become 15 | available after the CLFS book has been released. Once a release of 16 | the CLFS Embedded book is made, this page will provide a link to the 17 | CLFS Embedded errata page. 18 | 24 | 25 | 26 | -------------------------------------------------------------------------------- /BOOK/preface/common/foreword.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | %general-entities; 6 | ]> 7 | 8 | 9 | 10 | 11 | Foreword 12 | 13 | The Linux From Scratch Project has seen many changes in the 14 | few years of its existence. I personally became involved with the 15 | project in 2000, around the time of the 3.x releases. At that time, 16 | the build process was to create static binaries with the host system, 17 | then chroot and build the final binaries on top of the static ones. 18 | 19 | Later came the use of the /static directory to hold the initial 20 | static builds, keeping them separated from the final system, then 21 | the PureLFS process developed by Ryan Oliver and Greg Schafer, 22 | introducing a new toolchain build process that divorces even our initial 23 | builds from the host. Finally, LFS 6 bought Linux Kernel 2.6, the 24 | udev dynamic device structure, sanitized kernel headers, and other 25 | improvements to the Linux From Scratch system. 26 | 27 | The one "flaw" in LFS is that it has always been based on an x86 28 | class processor. With the advent of the Athlon 64 and Intel EM64T 29 | processors, the x86-only LFS is no longer ideal. Throughout this time, 30 | Ryan Oliver developed and documented a process by which you could 31 | build Linux for any system and from any system, by use of 32 | cross-compilation techniques. Thus, the Cross-Compiled LFS (CLFS) was 33 | born. 34 | 35 | CLFS Embedded follows the same guiding principles the LFS project has 36 | always followed, e.g., knowing your system inside and out by virtue 37 | of having built the system yourself. Additionally, during a CLFS Embedded 38 | build, you will learn advanced techniques such as cross-build toolchains, 39 | and how to create a smaller footprint system supporting architectures 40 | such as ARM and MIPS, in addition to x86. 41 | 42 | We hope you enjoy building your own CLFS Embedded system, and the benefits 43 | that come from a system tailored to your needs. 44 | 45 | -- 46 | Jim Gifford, CLFS Project Co-leader (Page Author) 47 | Jeremy Utley, CLFS 1.x Release Manager (Page Author) 48 | Ryan Oliver, CLFS Project Co-leader 49 | Joe Ciccone, Justin Knierim, Chris Staub, Matt Darcy, Ken Moffat, 50 | Maarten Lankhorst, Zack Winkles, Manuel Canales Esparcia, 51 | Nathan Coulson, and Andrew Bradford - CLFS Developers 52 | 53 | 54 | -------------------------------------------------------------------------------- /BOOK/preface/common/organization.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | %general-entities; 6 | ]> 7 | 8 | 9 | 10 | Structure 11 | 12 | This book is divided into the following parts. 13 | 14 | 15 | Part I - Introduction 16 | 17 | Part I explains a few important notes on how to proceed with the 18 | Cross-LFS installation. This section also provides meta-information about 19 | the book. 20 | 21 | 22 | 23 | 24 | Part II - Preparing for the Build 25 | 26 | Part II describes how to prepare for the building 27 | process including downloading the packages. 28 | 29 | 30 | 31 | 32 | Part III - Make the Cross-Compile Tools 33 | 34 | Part III shows you how to make a set of Cross-Compiler 35 | tools. These tools can run on your host system but allow you to 36 | build packages that will run on your target system. 37 | 38 | 39 | 40 | 41 | Part IV - Building the CLFS System 42 | 43 | Part IV shows you how to build the core CLFS system. Compiling 44 | and installing Buxybox and other required packages, making the system 45 | bootable, setting up the bootscripts, and installing a bootloader. 46 | 47 | 48 | 49 | 50 | Part V - Beyond CLFS Embedded 51 | 52 | Part V provides instructions on optional packages that can be 53 | installed to enhance your CLFS system. 54 | 55 | 56 | 57 | 58 | Part VI - Cleanup and Boot 59 | 60 | Part VI finishes up the system by making sure the target file system 61 | is ready to be booted, copying it to the target, and finally booting the 62 | system. 63 | 64 | 65 | 66 | 67 | -------------------------------------------------------------------------------- /BOOK/preface/common/prerequisites.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | %general-entities; 6 | ]> 7 | 8 | 9 | 10 | 11 | Prerequisites 12 | 13 | Building a CLFS system is not a simple task. It requires a certain 14 | level of existing knowledge of Unix system administration in order to 15 | resolve problems, and correctly execute the commands listed. In particular, 16 | as an absolute minimum, the reader should already have the ability to use 17 | the command line (shell) to copy or move files and directories, list 18 | directory and file contents, and change the current directory. It is also 19 | expected that the reader has a reasonable knowledge of using and installing 20 | Linux software. A basic knowledge of the architectures being used in 21 | the Cross LFS process and the host operating systems in use is also 22 | required. 23 | 24 | Because the CLFS book assumes at least this basic 25 | level of skill, the various CLFS support forums are unlikely to be able to 26 | provide you with much assistance. Your questions regarding such basic knowledge 27 | will likely go unanswered, or you will be referred to the CLFS essential 28 | pre-reading list. 29 | 30 | Before building a CLFS system, we recommend reading the following 31 | HOWTOs: 32 | 33 | 34 | 35 | Software-Building-HOWTO 36 | 37 | 38 | This is a comprehensive guide to building and installing 39 | generic Unix software distributions under Linux. 40 | 41 | 42 | The Essential Pre-Reading Hint 43 | 44 | 45 | This is a hint written specifically for users new to Linux. 46 | It includes a list of links to excellent sources of information on a 47 | wide range of topics. Anyone attempting to install CLFS should have an 48 | understanding of many of the topics in this hint. 49 | 50 | 51 | 52 | 53 | -------------------------------------------------------------------------------- /BOOK/preface/common/typography.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | %general-entities; 6 | ]> 7 | 8 | 9 | 10 | 11 | Typography 12 | 13 | To make things easier to follow, there are a few typographical 14 | conventions used throughout this book. This section contains some 15 | examples of the typographical format found throughout Linux From 16 | Scratch. 17 | 18 | ./configure --prefix=/usr 19 | 20 | This form of text is designed to be typed exactly as seen unless 21 | otherwise noted in the surrounding text. It is also used in the 22 | explanation sections to identify which of the commands is being 23 | referenced. 24 | 25 | install-info: unknown option '--dir-file=/mnt/clfs/usr/info/dir' 26 | 27 | This form of text (fixed-width text) shows screen output, 28 | probably as the result of commands issued. This format is also used 29 | to show filenames, such as /etc/ld.so.conf. 30 | 31 | Emphasis 32 | 33 | This form of text is used for several purposes in the book. 34 | Its main purpose is to emphasize important points or items. 35 | 36 | 37 | 38 | This format is used for hyperlinks, both within the CLFS 39 | community and to external pages. It includes HOWTOs, download locations, 40 | and websites. 41 | 42 | cat > ${CLFS}/etc/group << "EOF" 43 | root:x:0: 44 | bin:x:1: 45 | ...... 46 | EOF 47 | 48 | This format is used when creating configuration files. The first 49 | command tells the system to create the file 50 | ${CLFS}/etc/group from whatever is typed on the 51 | following lines until the sequence end of file (EOF) is encountered. 52 | Therefore, this entire section is generally typed as seen. 53 | 54 | [REPLACED TEXT] 55 | 56 | This format is used to encapsulate text that is not to be typed 57 | as seen or copied-and-pasted. 58 | 59 | passwd(5) 60 | 61 | This format is used to refer to a specific manual page (hereinafter 62 | referred to simply as a man page). The number inside 63 | parentheses indicates a specific section inside of man. 64 | For example, passwd has two man pages. 65 | man passwd will print the first man page it finds 66 | that matches passwd, which will be 67 | /usr/share/man/man1/passwd.1. For this example, 68 | you will need to run man 5 passwd in order to read 69 | the specific page being referred to. It should be noted that most man 70 | pages do not have duplicate page names in different sections. Therefore, 71 | man [program name] is 72 | generally sufficient. 73 | 74 | 75 | -------------------------------------------------------------------------------- /BOOK/preface/mips/bookinfo.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | %general-entities; 6 | ]> 7 | 8 | 9 | 10 | 13 | 14 | Version &version-mips; 15 | 16 | 19 | 20 | 23 | 24 | 25 | -------------------------------------------------------------------------------- /BOOK/preface/preface.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | %general-entities; 6 | ]> 7 | 8 | 9 | 10 | 11 | 12 | Preface 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | -------------------------------------------------------------------------------- /BOOK/preface/x86/bookinfo.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | %general-entities; 6 | ]> 7 | 8 | 9 | 10 | 13 | 14 | Version &version-x86; 15 | 16 | 19 | 20 | 21 | Copyright © 2005-&year;, Joe Ciccone, Jim Gifford, Maarten Lankhorst, & Ryan Oliver 22 | 23 | All rights reserved. 24 | 25 | This material may be distributed only subject to the terms and 26 | conditions set forth in the v1.0 or later 27 | (the latest version is presently available at ). 29 | 30 | 32 | 33 | Linux is a registered 34 | trademark of Linus Torvalds. 35 | 36 | 37 | 38 | 39 | -------------------------------------------------------------------------------- /BOOK/schema/docbook/4.5/rng/dbnotnx.rnc: -------------------------------------------------------------------------------- 1 | # ...................................................................... 2 | 3 | # DocBook notations module V4.5 ........................................ 4 | 5 | # File dbnotnx.mod ..................................................... 6 | 7 | # Copyright 1992-2004 HaL Computer Systems, Inc., 8 | # O'Reilly & Associates, Inc., ArborText, Inc., Fujitsu Software 9 | # Corporation, Norman Walsh, Sun Microsystems, Inc., and the 10 | # Organization for the Advancement of Structured Information 11 | # Standards (OASIS). 12 | # 13 | # $Id: dbnotnx.mod 6340 2006-10-03 13:23:24Z nwalsh $ 14 | # 15 | # Permission to use, copy, modify and distribute the DocBook DTD 16 | # and its accompanying documentation for any purpose and without fee 17 | # is hereby granted in perpetuity, provided that the above copyright 18 | # notice and this paragraph appear in all copies. The copyright 19 | # holders make no representation about the suitability of the DTD for 20 | # any purpose. It is provided "as is" without expressed or implied 21 | # warranty. 22 | # 23 | # If you modify the DocBook DTD in any way, except for declaring and 24 | # referencing additional sets of general entities and declaring 25 | # additional notations, label your DTD as a variant of DocBook. See 26 | # the maintenance documentation for more information. 27 | # 28 | # Please direct all questions, bug reports, or suggestions for 29 | # changes to the docbook@lists.oasis-open.org mailing list. For more 30 | # information, see http://www.oasis-open.org/docbook/. 31 | 32 | # ...................................................................... 33 | 34 | # This module contains the notation declarations used by DocBook. 35 | # 36 | # In DTD driver files referring to this module, please use an entity 37 | # declaration that uses the public identifier shown below: 38 | # 39 | # 42 | # %dbnotn; 43 | # 44 | # See the documentation for detailed information on the parameter 45 | # entity and module scheme used in DocBook, customizing DocBook and 46 | # planning for interchange, and changes made since the last release 47 | # of DocBook. 48 | 49 | local.notation.class = notAllowed 50 | notation.class = 51 | "BMP" 52 | | "CGM-CHAR" 53 | | "CGM-BINARY" 54 | | "CGM-CLEAR" 55 | | "DITROFF" 56 | | "DVI" 57 | | "EPS" 58 | | "EQN" 59 | | "FAX" 60 | | "GIF" 61 | | "GIF87a" 62 | | "GIF89a" 63 | | "JPG" 64 | | "JPEG" 65 | | "IGES" 66 | | "PCX" 67 | | "PIC" 68 | | "PNG" 69 | | "PS" 70 | | "SGML" 71 | | "TBL" 72 | | "TEX" 73 | | "TIFF" 74 | | "WMF" 75 | | "WPG" 76 | | "SVG" 77 | | "PDF" 78 | | "SWF" 79 | | "linespecific" 80 | | local.notation.class 81 | # WordPerfect Graphic format 82 | 83 | # End of DocBook notations module V4.5 ................................. 84 | 85 | # ...................................................................... 86 | -------------------------------------------------------------------------------- /BOOK/stylesheets/clfs-chunked.xsl: -------------------------------------------------------------------------------- 1 | 2 | 3 | 7 | 8 | 11 | 12 | 13 | 14 | 15 | 16 | clfs 17 | 18 | 19 | -------------------------------------------------------------------------------- /BOOK/stylesheets/clfs-nochunks.xsl: -------------------------------------------------------------------------------- 1 | 2 | 3 | 7 | 8 | 11 | 12 | 13 | 14 | 15 | 16 | clfs 17 | 18 | 19 | -------------------------------------------------------------------------------- /BOOK/stylesheets/clfs-pdf.xsl: -------------------------------------------------------------------------------- 1 | 2 | 3 | 7 | 8 | 11 | 12 | 13 | 14 | 15 | 16 | clfs 17 | 18 | 19 | -------------------------------------------------------------------------------- /BOOK/stylesheets/dump-commands.xsl: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 00 29 | 30 | 31 | 32 | 0 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | # Run this as root 53 | 54 | # End root commands 55 | 56 | 57 | 58 | 59 | 60 | 61 | 62 | 63 | 64 | 65 | 66 | 67 | # This block must be edited to suit your needs. 68 | 69 | 70 | 71 | 72 | 73 | # End of editable block. 74 | 75 | 76 | 77 | 78 | 79 | **EDITME 80 | 81 | EDITME** 82 | 83 | 84 | 85 | -------------------------------------------------------------------------------- /BOOK/stylesheets/lfs-xsl/chunk-master.xsl: -------------------------------------------------------------------------------- 1 | 2 | 3 | 7 | 8 | 11 | 12 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 33 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | -------------------------------------------------------------------------------- /BOOK/stylesheets/lfs-xsl/chunk-slave.xsl: -------------------------------------------------------------------------------- 1 | 2 | 3 | 7 | 8 | 11 | 12 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | book toc,title 51 | preface toc 52 | part toc 53 | chapter toc 54 | appendix nop 55 | sect1 nop 56 | sect2 nop 57 | sect3 nop 58 | sect4 nop 59 | sect5 nop 60 | section nop 61 | 62 | 63 | 64 | 1 65 | 66 | 67 | 3 68 | 69 | 70 | -------------------------------------------------------------------------------- /BOOK/stylesheets/lfs-xsl/chunkfast.xsl: -------------------------------------------------------------------------------- 1 | 2 | 3 | 7 | 8 | 14 | 15 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | 55 | 56 | 57 | 58 | 59 | 60 | 61 | 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | 71 | 72 | 73 | 74 | 75 | 76 | 77 | -------------------------------------------------------------------------------- /BOOK/stylesheets/lfs-xsl/docbook-xsl-snapshot/COPYING: -------------------------------------------------------------------------------- 1 | Copyright 2 | --------- 3 | Copyright (C) 1999-2007 Norman Walsh 4 | Copyright (C) 2003 Jiří Kosek 5 | Copyright (C) 2004-2007 Steve Ball 6 | Copyright (C) 2005-2007 The DocBook Project 7 | 8 | Permission is hereby granted, free of charge, to any person 9 | obtaining a copy of this software and associated documentation 10 | files (the ``Software''), to deal in the Software without 11 | restriction, including without limitation the rights to use, 12 | copy, modify, merge, publish, distribute, sublicense, and/or 13 | sell copies of the Software, and to permit persons to whom the 14 | Software is furnished to do so, subject to the following 15 | conditions: 16 | 17 | The above copyright notice and this permission notice shall be 18 | included in all copies or substantial portions of the Software. 19 | 20 | Except as contained in this notice, the names of individuals 21 | credited with contribution to this software shall not be used in 22 | advertising or otherwise to promote the sale, use or other 23 | dealings in this Software without prior written authorization 24 | from the individuals in question. 25 | 26 | Any stylesheet derived from this Software that is publically 27 | distributed will be identified with a different name and the 28 | version strings in any derived Software will be changed so that 29 | no possibility of confusion between the derived package and this 30 | Software will exist. 31 | 32 | Warranty 33 | -------- 34 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, 35 | EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES 36 | OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND 37 | NONINFRINGEMENT. IN NO EVENT SHALL NORMAN WALSH OR ANY OTHER 38 | CONTRIBUTOR BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, 39 | WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING 40 | FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR 41 | OTHER DEALINGS IN THE SOFTWARE. 42 | 43 | Contacting the Author 44 | --------------------- 45 | The DocBook XSL stylesheets are maintained by Norman Walsh, 46 | , and members of the DocBook Project, 47 | 48 | -------------------------------------------------------------------------------- /BOOK/stylesheets/lfs-xsl/docbook-xsl-snapshot/common/l10n.dtd: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 20 | 21 | 22 | 27 | 28 | 29 | 34 | 35 | 36 | 41 | 42 | 43 | 46 | 47 | 48 | 54 | 55 | 56 | 59 | 60 | 61 | 64 | -------------------------------------------------------------------------------- /BOOK/stylesheets/lfs-xsl/docbook-xsl-snapshot/common/l10n.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | ]> 11 | 12 | &de; 13 | &en; 14 | &es; 15 | &fr; 16 | ⁢ 17 | &zh_cn; 18 | &zh_tw; 19 | 20 | -------------------------------------------------------------------------------- /BOOK/stylesheets/lfs-xsl/docbook-xsl-snapshot/common/targetdatabase.dtd: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 14 | 15 | 16 | 23 | 24 | 25 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 50 | -------------------------------------------------------------------------------- /BOOK/stylesheets/lfs-xsl/docbook-xsl-snapshot/fo/annotations.xsl: -------------------------------------------------------------------------------- 1 | 2 | 5 | 6 | 15 | 16 | 17 | 18 | 19 | -------------------------------------------------------------------------------- /BOOK/stylesheets/lfs-xsl/docbook-xsl-snapshot/fo/autoidx-ng.xsl: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 14 | 15 | 16 | 17 | 18 | kosek 19 | 20 | 21 | -------------------------------------------------------------------------------- /BOOK/stylesheets/lfs-xsl/docbook-xsl-snapshot/fo/biblio-iso690.xsl: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bradfa/clfs-embedded-pregithub/173cc96fc136fe34ea4d46c31b387012aa253f10/BOOK/stylesheets/lfs-xsl/docbook-xsl-snapshot/fo/biblio-iso690.xsl -------------------------------------------------------------------------------- /BOOK/stylesheets/lfs-xsl/docbook-xsl-snapshot/fo/fo.xsl: -------------------------------------------------------------------------------- 1 | 2 | 5 | 6 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | bullet 31 | 32 | 33 | o 34 | © 35 | 36 | 37 | ® 38 | (SM) 39 | " 40 | " 41 | ' 42 | ' 43 | 44 | - 45 | o 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | 55 | 56 | 57 | 58 | 59 | 60 | 61 | 62 | 63 | 64 | # 65 | 66 | 67 | 68 | 69 | 70 | 71 | 72 | -------------------------------------------------------------------------------- /BOOK/stylesheets/lfs-xsl/docbook-xsl-snapshot/fo/fop1.xsl: -------------------------------------------------------------------------------- 1 | 2 | 5 | 6 | 7 | 8 | 9 | 10 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 54 | 55 | 56 | 57 | 58 | 59 | 60 | 61 | 62 | 63 | 64 | 65 | 68 | 69 | 70 | 71 | 72 | -------------------------------------------------------------------------------- /BOOK/stylesheets/lfs-xsl/docbook-xsl-snapshot/fo/highlight.xsl: -------------------------------------------------------------------------------- 1 | 2 | 7 | 8 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 55 | 56 | 57 | 58 | -------------------------------------------------------------------------------- /BOOK/stylesheets/lfs-xsl/docbook-xsl-snapshot/fo/info.xsl: -------------------------------------------------------------------------------- 1 | 2 | 5 | 6 | 15 | 16 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | -------------------------------------------------------------------------------- /BOOK/stylesheets/lfs-xsl/docbook-xsl-snapshot/fo/keywords.xsl: -------------------------------------------------------------------------------- 1 | 2 | 5 | 6 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | -------------------------------------------------------------------------------- /BOOK/stylesheets/lfs-xsl/docbook-xsl-snapshot/fo/passivetex.xsl: -------------------------------------------------------------------------------- 1 | 2 | 5 | 6 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 23 | 24 | 25 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | -------------------------------------------------------------------------------- /BOOK/stylesheets/lfs-xsl/docbook-xsl-snapshot/fo/pdf2index: -------------------------------------------------------------------------------- 1 | #!/usr/bin/perl -- # -*- Perl -*- 2 | 3 | # this needs some cleanup... 4 | 5 | my $PSTOTEXT = "pstotext"; 6 | 7 | my $pdf = shift @ARGV; 8 | 9 | my $index = ""; 10 | my $inindex = 0; 11 | open (F, "$PSTOTEXT $pdf |"); 12 | while () { 13 | if (/^<\/index/) { 14 | $index .= $_; 15 | $inindex = 0; 16 | } 17 | $inindex = 1 if /^.*?<\/phrase>\s*)+)/s) { 26 | $cindex .= $1; 27 | $_ = $2; 28 | $index = $'; # ' 29 | 30 | my @pages = m/.*?<\/phrase>\s*/sg; 31 | 32 | # Expand ranges 33 | if ($#pages >= 0) { 34 | my @mpages = (); 35 | foreach my $page (@pages) { 36 | my $pageno = &pageno($page); 37 | if ($pageno =~ /^([0-9]+)[^0-9]([0-9]+)$/) { # funky - 38 | for (my $count = $1; $count <= $2; $count++) { 39 | push (@mpages, "$count"); 40 | } 41 | } else { 42 | push (@mpages, $page); 43 | } 44 | } 45 | @pages = sort rangesort @mpages; 46 | } 47 | 48 | # Remove duplicates... 49 | if ($#pages > 0) { 50 | my @mpages = (); 51 | my $current = ""; 52 | foreach my $page (@pages) { 53 | my $pageno = &pageno($page); 54 | if ($pageno ne $current) { 55 | push (@mpages, $page); 56 | $current = $pageno; 57 | } 58 | } 59 | @pages = @mpages; 60 | } 61 | 62 | # Collapse ranges... 63 | if ($#pages > 1) { 64 | my @cpages = (); 65 | while (@pages) { 66 | my $count = 0; 67 | my $len = &rangelen($count, @pages); 68 | if ($len <= 2) { 69 | my $page = shift @pages; 70 | push (@cpages, $page); 71 | } else { 72 | my $fpage = shift @pages; 73 | my $lpage = ""; 74 | while ($len > 1) { 75 | $lpage = shift @pages; 76 | $len--; 77 | } 78 | my $fpno = &pageno($fpage); 79 | my $lpno = &pageno($lpage); 80 | $fpage =~ s/>$fpno${fpno}-$lpno//; 104 | $page =~ s/^//; 105 | 106 | return $1 if $page =~ /^([^<>]+)/; 107 | return "?"; 108 | } 109 | 110 | sub rangesort { 111 | my $apno = &pageno($a); 112 | my $bpno = &pageno($b); 113 | 114 | # Make sure roman pages come before arabic ones, otherwise sort them in order 115 | return -1 if ($apno !~ /^\d+/ && $bpno =~ /^\d+/); 116 | return 1 if ($apno =~ /^\d+/ && $bpno !~ /^\d+/); 117 | return $apno <=> $bpno; 118 | } 119 | 120 | sub rangelen { 121 | my $count = shift; 122 | my @pages = @_; 123 | my $len = 1; 124 | my $inrange = 1; 125 | 126 | my $current = &pageno($pages[$count]); 127 | while ($count < $#pages && $inrange) { 128 | $count++; 129 | my $next = &pageno($pages[$count]); 130 | if ($current + 1 eq $next) { 131 | $current = $next; 132 | $inrange = 1; 133 | $len++; 134 | } else { 135 | $inrange = 0; 136 | } 137 | } 138 | 139 | return $len; 140 | } 141 | -------------------------------------------------------------------------------- /BOOK/stylesheets/lfs-xsl/docbook-xsl-snapshot/fo/task.xsl: -------------------------------------------------------------------------------- 1 | 2 | 5 | 6 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | before 33 | 34 | 35 | 36 | 37 | 38 | 39 | 42 | 43 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | 55 | 56 | 57 | 58 | 59 | 60 | 61 | 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | 71 | 72 | 73 | 74 | 75 | 76 | 77 | 78 | 79 | 80 | 81 | 82 | -------------------------------------------------------------------------------- /BOOK/stylesheets/lfs-xsl/docbook-xsl-snapshot/highlighting/common.xsl: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /BOOK/stylesheets/lfs-xsl/docbook-xsl-snapshot/profiling/profile.xsl: -------------------------------------------------------------------------------- 1 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 17 | 18 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | -------------------------------------------------------------------------------- /BOOK/stylesheets/lfs-xsl/docbook-xsl-snapshot/profiling/strip-attributes.xsl: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 6 | 7 | 8 | 9 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | -------------------------------------------------------------------------------- /BOOK/stylesheets/lfs-xsl/docbook-xsl-snapshot/xhtml/autoidx-ng.xsl: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 15 | 16 | 17 | 18 | 19 | kosek 20 | 21 | 22 | -------------------------------------------------------------------------------- /BOOK/stylesheets/lfs-xsl/docbook-xsl-snapshot/xhtml/chunk.xsl: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 15 | 16 | 17 | 18 | 25 | 26 | 27 | 32 | 33 | 34 | 36 | 37 | 50 | 51 | 52 | 53 | -------------------------------------------------------------------------------- /BOOK/stylesheets/lfs-xsl/docbook-xsl-snapshot/xhtml/chunkfast.xsl: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | 55 | 56 | 57 | 58 | 59 | 60 | 61 | 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | -------------------------------------------------------------------------------- /BOOK/stylesheets/lfs-xsl/docbook-xsl-snapshot/xhtml/highlight.xsl: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | -------------------------------------------------------------------------------- /BOOK/stylesheets/lfs-xsl/docbook-xsl-snapshot/xhtml/htmltbl.xsl: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | 55 | 56 | 57 | -------------------------------------------------------------------------------- /BOOK/stylesheets/lfs-xsl/docbook-xsl-snapshot/xhtml/info.xsl: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 15 | 16 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | -------------------------------------------------------------------------------- /BOOK/stylesheets/lfs-xsl/docbook-xsl-snapshot/xhtml/keywords.xsl: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | , 32 | 33 | 34 | 35 | 36 | 37 | -------------------------------------------------------------------------------- /BOOK/stylesheets/lfs-xsl/docbook-xsl-snapshot/xhtml/maketoc.xsl: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | filename=" 54 | 55 | " 56 | 57 | 58 | 59 | 60 | 61 | 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | 71 | 72 | 73 | 74 | 75 | 76 | 77 | 78 | 79 | 80 | 81 | 82 | 83 | 84 | 85 | 86 | 87 | 88 | 89 | 90 | 91 | 92 | -------------------------------------------------------------------------------- /BOOK/stylesheets/lfs-xsl/docbook-xsl-snapshot/xhtml/manifest.xsl: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | -------------------------------------------------------------------------------- /BOOK/stylesheets/lfs-xsl/docbook-xsl-snapshot/xhtml/onechunk.xsl: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 1 27 | 28 | 29 | 30 | # 31 | 32 | 33 | 34 | 35 | 36 | 37 | -------------------------------------------------------------------------------- /BOOK/stylesheets/lfs-xsl/docbook-xsl-snapshot/xhtml/profile-chunk.xsl: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 15 | 16 | 17 | 18 | 25 | 26 | 27 | 32 | 33 | 34 | 36 | 37 | 50 | 51 | 52 | 53 | -------------------------------------------------------------------------------- /BOOK/stylesheets/lfs-xsl/docbook-xsl-snapshot/xhtml/profile-onechunk.xsl: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 1 27 | 28 | 29 | 30 | # 31 | 32 | 33 | 34 | 35 | 36 | 37 | -------------------------------------------------------------------------------- /BOOK/stylesheets/lfs-xsl/docbook-xsl-snapshot/xhtml/task.xsl: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | before 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 |
36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 |
49 |
50 | 51 | 52 | 53 | 54 | 55 | 56 | 57 | 58 | 59 | 60 | 61 | 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | 71 | 72 | 73 |
74 | -------------------------------------------------------------------------------- /BOOK/stylesheets/lfs-xsl/lfs-l10n.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 7 | 8 | 9 | 10 | 11 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | 55 | 56 | 57 | 58 | 59 | 60 | 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | 71 | 72 | 73 | 74 | 75 | 76 | -------------------------------------------------------------------------------- /BOOK/stylesheets/lfs-xsl/lfs-print.css: -------------------------------------------------------------------------------- 1 | /* 2 | $LastChangedBy$ 3 | $Date$ 4 | */ 5 | @import url(lfs.css); 6 | 7 | .navfooter, .headerlinks { 8 | display: none; 9 | } 10 | -------------------------------------------------------------------------------- /BOOK/stylesheets/lfs-xsl/pdf/lfs-admon.xsl: -------------------------------------------------------------------------------- 1 | 2 | 3 | 7 | 8 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | always 31 | 32 | 33 | 0.6em 34 | 0.4em 35 | 0.8em 36 | 0.6em 37 | 0.4em 38 | 0.8em 39 | 5pt 40 | 5pt 41 | 5pt 42 | solid 43 | 0.5pt 44 | #FFFFE6 45 | 46 | 47 | #E0E0E0 48 | #DCC 49 | 50 | 51 | 52 | 53 | 54 | 55 | 14pt 56 | bold 57 | false 58 | always 59 | 60 | 61 | #500 63 | #000 64 | 65 | 66 | 67 | 68 | 69 | 70 | 5pt 71 | 72 | 73 | 75 | 76 | 77 | 78 | 24pt 79 | 80 | 81 | 82 | -------------------------------------------------------------------------------- /BOOK/stylesheets/lfs-xsl/profile.xsl: -------------------------------------------------------------------------------- 1 | 2 | 3 | 7 | 8 | 10 | 11 | 13 | 14 | 15 | 16 | 17 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 28 | 29 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | 55 | 56 | -------------------------------------------------------------------------------- /BOOK/stylesheets/lfs-xsl/xhtml/lfs-admon.xsl: -------------------------------------------------------------------------------- 1 | 2 | 3 | 7 | 8 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 20 | ../images/ 21 | 22 | 23 | 24 | 25 | 29 | 30 | 31 | 32 | 33 | Note 34 | Warning 35 | Caution 36 | Tip 37 | Important 38 | Note 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 |
47 | [{$alt}] 48 | 49 | 50 | 51 | 52 |

53 | 54 |

55 | 56 |
57 |
58 | 59 |
60 | -------------------------------------------------------------------------------- /BOOK/stylesheets/lfs-xsl/xhtml/lfs-legalnotice.xsl: -------------------------------------------------------------------------------- 1 | 2 | 3 | 7 | 8 | 11 | 12 | 13 | 14 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 |
33 | 34 |
35 | 51 | 52 | 53 |
54 |
55 |
56 | 57 | 59 | 60 | 61 |

62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | copyright 70 | 71 | 72 | 73 | 74 | 75 | 76 | 77 | 78 | 79 |

80 |
81 | 82 |
83 | -------------------------------------------------------------------------------- /BOOK/stylesheets/patcheslist.xsl: -------------------------------------------------------------------------------- 1 | 2 | 4 | %general-entities; 5 | ]> 6 | 7 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | #! /bin/bash 19 | 20 | function copy 21 | { 22 | cp $1 $2 >>copyerrs 2>&1 23 | } 24 | 25 | umask 002 26 | 27 | 28 | install -d -m 775 -g lfswww 29 | 30 | && 31 | cd 32 | 33 | && 34 | 35 | rm -f *.patch copyerrs && 36 | 37 | 38 | chgrp lfswww *.patch && 39 | 40 | if [ `wc -l copyerrs | sed 's/ *//' | cut -f1 -d' '` -gt 0 ]; then 41 | mail -s "Missing CLFS patches" cross-lfs-dev@linuxfromscratch.org < copyerrs 42 | fi 43 | 44 | exit 45 | 46 | 47 | 48 | 49 | 50 | 51 | 53 | 54 | 56 | 57 | 58 | - 59 | 60 | 61 | copy /home/httpd/www.linuxfromscratch.org/patches/downloads/ 62 | 63 | / 64 | 65 | . 66 | 67 | 68 | 69 | 70 | -------------------------------------------------------------------------------- /BOOK/stylesheets/top-index.xsl: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/bradfa/clfs-embedded-pregithub/173cc96fc136fe34ea4d46c31b387012aa253f10/BOOK/stylesheets/top-index.xsl -------------------------------------------------------------------------------- /BOOK/stylesheets/wget.xsl: -------------------------------------------------------------------------------- 1 | 2 | 4 | %general-entities; 5 | ]> 6 | 7 | 15 | 16 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 28 | 29 | 30 | 31 | 32 | 34 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | -------------------------------------------------------------------------------- /BOOK/the-end/chapter.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | %general-entities; 6 | ]> 7 | 8 | 9 | 10 | 11 | 12 | The End 13 | 14 | 15 | 16 | 17 | 18 | -------------------------------------------------------------------------------- /BOOK/the-end/theend.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | %general-entities; 6 | ]> 7 | 8 | 9 | 10 | 11 | The End 12 | 13 | Well done! The new CLFS system is installed! We wish you much 14 | success with your shiny new custom-built Linux system. 15 | 16 | Assuming the boot loader was set up properly, 17 | CLFS &version; will boot automatically when you power on 18 | the target. 19 | 20 | 21 | -------------------------------------------------------------------------------- /BOOK/tidy.conf: -------------------------------------------------------------------------------- 1 | indent-spaces: 2 2 | wrap: 78 3 | tab-size: 8 4 | input-encoding: latin1 5 | output-encoding: latin1 6 | newline: CRLF 7 | write-back: yes 8 | markup: yes 9 | indent: yes 10 | hide-endtags: no 11 | uppercase-tags: no 12 | logical-emphasis: no 13 | drop-font-tags: no 14 | tidy-mark: no 15 | numeric-entities: no 16 | show-warnings: no 17 | quiet: yes 18 | newline: LF 19 | -------------------------------------------------------------------------------- /BOOK/tidy.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | # Written By: Joe Ciccone 3 | 4 | if test -z "$1"; then 5 | echo "Usage: $0 path" 6 | exit 1 7 | fi 8 | 9 | TOP=`dirname $0` 10 | 11 | if test -d "$1"; then 12 | find "$1" -type f -name \*.html | while read file; do 13 | tidy -config "${TOP}/tidy.conf" "$file" 14 | sed -i -e "s@text/html@application/xhtml+xml@g" "$file" 15 | done 16 | else 17 | tidy -config "${TOP}/tidy.conf" "$1" 18 | sed -i -e "s@text/html@application/xhtml+xml@g" "$1" 19 | fi 20 | 21 | exit $? 22 | -------------------------------------------------------------------------------- /BOOK/x86-index.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | %general-entities; 6 | ]> 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | Introduction 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | Preparing for the Build 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | Make the Cross-Compile Tools 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | Building the CLFS System 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | 55 | Beyond CLFS Embedded 56 | 57 | 58 | 59 | 60 | 61 | 62 | 63 | 64 | Cleanup and Boot 65 | 66 | 67 | 68 | 69 | 70 | 71 | 72 | 73 | 74 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | Cross Linux From Scratch Embedded 2 | ================================= 3 | 4 | Cross Linux From Scratch (CLFS) Embedded shows you how to build a Linux system 5 | from source, targeting users who want to make a very small system. 6 | 7 | Running with 16 MB of RAM and 16 MB of "disk" is very possible. 8 | 9 | For more information about CLFS, visit the [CLFS website][trac]. 10 | 11 | To build the book, please see the BOOK/INSTALL.md file for requirements and 12 | exact steps. 13 | 14 | [trac]:http://trac.clfs.org 15 | -------------------------------------------------------------------------------- /patches/netplug-1.2.9.2-fixes-1.patch: -------------------------------------------------------------------------------- 1 | Submitted By: Andrew Bradford 2 | Date: 2013-10-25 3 | Initial Package Version: 1.2.9.2 4 | Origin: CLFS specific 5 | Upstream Status: Not Applied 6 | Description: Fixes build problems. 7 | 8 | diff -Naur netplug-1.2.9.2.orig/lib.c netplug-1.2.9.2/lib.c 9 | --- netplug-1.2.9.2.orig/lib.c 2013-10-25 16:23:21.270934264 -0400 10 | +++ netplug-1.2.9.2/lib.c 2013-10-25 16:24:26.067667210 -0400 11 | @@ -200,20 +200,6 @@ 12 | } 13 | 14 | 15 | -void 16 | -__assert_fail(const char *assertion, const char *file, 17 | - unsigned int line, const char *function) 18 | -{ 19 | - do_log(LOG_CRIT, "%s:%u: %s%sAssertion `%s' failed", 20 | - file, line, 21 | - function ? function : "", 22 | - function ? ": " : "", 23 | - assertion); 24 | - 25 | - abort(); 26 | -} 27 | - 28 | - 29 | /* 30 | * Local variables: 31 | * c-file-style: "stroustrup" 32 | diff -Naur netplug-1.2.9.2.orig/netplug.h netplug-1.2.9.2/netplug.h 33 | --- netplug-1.2.9.2.orig/netplug.h 2013-10-25 16:23:21.270934264 -0400 34 | +++ netplug-1.2.9.2/netplug.h 2013-10-25 16:24:17.054324652 -0400 35 | @@ -25,6 +25,7 @@ 36 | #include 37 | #include 38 | #include 39 | +#include 40 | 41 | #define NP_SCRIPT NP_SCRIPT_DIR "/netplug" 42 | 43 | --------------------------------------------------------------------------------