If you use a script(s) to install LFS (majority here?) you might
consider it best to download the sources through the scripts rather
than storing them all up front before running the scripts. I've been
playing with this and found that it is straightforward to do. What I
did:

You need to install wget at the end of Ch 6. This requires openssl to
be installed first.

The commands for openssl are:

./config --prefix=/usr         \
         --openssldir=/etc/ssl \
         --libdir=lib          \
         shared

make

sed -i '/INSTALL_LIBS/s/libcrypto.a libssl.a//' Makefile
make DESTDIR=$LFS MANSUFFIX=ssl install

I don't know if all these are strictly necessary, but these are what I
used, based on what is in Ch 8.

I added these as 058-openssl at the end of lfs-commands/chapter06,
after gcc-pass2.

The commands for wget are:

PKG_CONFIG_PATH=$LFS/usr/lib/pkgconfig \
                ./configure --prefix=/usr \
                --with-ssl=openssl \
                --host=$LFS_TGT \
                --build=$(build-aux/config.guess)

make

make DESTDIR=$LFS install

These were added as 059-wget in chapter06. I needed PKG_CONFIG_PATH in
order for wget to find openssl.

Notice that openssl doesn't have a config.guess script but this didn't
stop it compiling.

Once wget is installed all you need is /etc/resolv.conf, specifying
the nameserver, to connect to the web in Ch 7 and 8. Easy?

There are no certificates installed but sites like Perl need
--no-check-certificate to download.

So it's a fairly painless solution to get your scripts to download the
sources at install time when you're in chroot. Of course, where a
source file is needed more than once, gcc, binutils and some in Ch 8,
you don't need to download them again.

Downsides?

jb.
-- 
http://lists.linuxfromscratch.org/listinfo/lfs-dev
FAQ: http://www.linuxfromscratch.org/faq/
Unsubscribe: See the above information page

Reply via email to