Saturday, December 26, 2020

Chapter 11 : Setting up the environment for the "lfs" user

Hi,

In this chapter, we are going to setup the environment for the "lfs" user.

As part of setting up the environment, we are going to create two files namely

1. .bash_profile

2. .bashrc

3. .profile

Open a terminal and execute the following commands, keep that in mind...now you should have logged in as lfs user at the terminal.

Use the content below to create .bash_profile file 

cat > ~/.bash_profile << "EOF"

exec env -i HOME=$HOME TERM=$TERM PS1='\u:\w\$ ' /bin/bash

EOF


Use the content below to create .bashrc file
cat > ~/.bashrc << "EOF"
set +h
umask 022
LFS=/mnt/lfs
LC_ALL=POSIX
LFS_TGT=$(uname -m)-lfs-linux-gnu
PATH=/usr/bin
if [ ! -L /bin ]; then PATH=/bin:$PATH; fi
PATH=$LFS/tools/bin:$PATH
export LFS LC_ALL LFS_TGT PATH
EOF

$ source ~/.bash_profile

If you like to have a detailed explanation about these two files, you can checkout the following link below


Use the content below to create .profile file
cat > ~/.profile << "EOF"

export LFS=/mnt/lfs

EOF




No comments:

Post a Comment

Addressing Modes of 8080 / 8085 MicroProcessor

Hi,   In this post I am going to talk about different addressing modes of 8080/8085...without much talking let us get into the topic.   Ther...