Compare commits
1 Commits
jetpack-4.
...
master
Author | SHA1 | Date |
---|---|---|
dchvs | af2e8ef832 |
42
install.sh
42
install.sh
|
@ -30,7 +30,7 @@ chkhost(){
|
||||||
#check if bsp installed in the correct folder on host machine
|
#check if bsp installed in the correct folder on host machine
|
||||||
chkfolder(){
|
chkfolder(){
|
||||||
|
|
||||||
if [ $(basename $(dirname $(pwd))) != "Linux_for_Tegra" ] || [ $(basename $(pwd)) != "CTI-L4T" ]; then
|
if [ $(basename $(dirname $(dirname $(pwd)))) != "Linux_for_Tegra" ] || [ $(basename $(pwd)) != "CTI-L4T" ]; then
|
||||||
echo "This BSP should be extracted in the Linux_for_Tegra directory"
|
echo "This BSP should be extracted in the Linux_for_Tegra directory"
|
||||||
echo "of your Jetpack install. This install script must be run from the"
|
echo "of your Jetpack install. This install script must be run from the"
|
||||||
echo "Linux_for_Tegra/CTI-L4T directory"
|
echo "Linux_for_Tegra/CTI-L4T directory"
|
||||||
|
@ -40,67 +40,67 @@ chkfolder(){
|
||||||
}
|
}
|
||||||
|
|
||||||
update_debsrc_list(){
|
update_debsrc_list(){
|
||||||
if [ -f ../rootfs/etc/apt/sources.list.d/nvidia-l4t-apt-source.list ]; then
|
if [ -f $PWD/../../rootfs/etc/apt/sources.list.d/nvidia-l4t-apt-source.list ]; then
|
||||||
echo "Suppressing nvidia-l4t-apt-source"
|
echo "Suppressing nvidia-l4t-apt-source"
|
||||||
if ! type sed > /dev/null; then
|
if ! type sed > /dev/null; then
|
||||||
mv ../rootfs/etc/apt/sources.list.d/nvidia-l4t-apt-source.list ../rootfs/etc/apt/sources.list.d/nvidia-l4t-apt-source.list.old
|
mv $PWD/../../rootfs/etc/apt/sources.list.d/nvidia-l4t-apt-source.list $PWD/../../rootfs/etc/apt/sources.list.d/nvidia-l4t-apt-source.list.old
|
||||||
else
|
else
|
||||||
sed -i 's/^/#/' ../rootfs/etc/apt/sources.list.d/nvidia-l4t-apt-source.list
|
sed -i 's/^/#/' $PWD/../../rootfs/etc/apt/sources.list.d/nvidia-l4t-apt-source.list
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
install_extra(){
|
install_extra(){
|
||||||
cp ./extra/*.deb ../nv_tegra/l4t_deb_packages/
|
cp ./extra/*.deb $PWD/../../nv_tegra/l4t_deb_packages/
|
||||||
#cp ./extra/*.asc ../rootfs/etc/apt/trusted.gpg.d/
|
#cp ./extra/*.asc $PWD/../../rootfs/etc/apt/trusted.gpg.d/
|
||||||
cp ./extra/*.list ../rootfs/etc/apt/sources.list.d/
|
cp ./extra/*.list $PWD/../../rootfs/etc/apt/sources.list.d/
|
||||||
}
|
}
|
||||||
|
|
||||||
install_key(){
|
install_key(){
|
||||||
cp -f ./key/* ../rootfs/etc/apt/trusted.gpg.d/
|
cp -f ./key/* $PWD/../../rootfs/etc/apt/trusted.gpg.d/
|
||||||
}
|
}
|
||||||
|
|
||||||
install_conf(){
|
install_conf(){
|
||||||
|
|
||||||
cp -rf ./conf/* ../
|
cp -rf ./conf/* $PWD/../../
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
install_dtb(){
|
install_dtb(){
|
||||||
cp ./kernel/dtb/* ../kernel/dtb/
|
cp ./kernel/dtb/* $PWD/../../kernel/dtb/
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
install_kernel(){
|
install_kernel(){
|
||||||
# remove old debs
|
# remove old debs
|
||||||
rm ../kernel/*.deb
|
rm $PWD/../../kernel/*.deb
|
||||||
|
|
||||||
# copy kernel debs
|
# copy kernel debs
|
||||||
cp ./kernel/*.deb ../kernel
|
cp ./kernel/*.deb $PWD/../../kernel
|
||||||
cp ./kernel/*Image ../kernel
|
cp ./kernel/*Image $PWD/../../kernel
|
||||||
cp ./kernel/kernel_supplements.tbz2 ../kernel/
|
cp ./kernel/kernel_supplements.tbz2 $PWD/../../kernel/
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
install_bl(){
|
install_bl(){
|
||||||
if [ "$(ls -A ./bl)" ]; then
|
if [ "$(ls -A ./bl)" ]; then
|
||||||
cp -r ./bl/* ../bootloader/
|
cp -r ./bl/* $PWD/../../bootloader/
|
||||||
fi
|
fi
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
install_rootfs(){
|
install_rootfs(){
|
||||||
if [ "$(ls -A ./rootfs)" ]; then
|
if [ "$(ls -A ./rootfs)" ]; then
|
||||||
cp -r ./rootfs/* ../rootfs/
|
cp -r ./rootfs/* $PWD/../../rootfs/
|
||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
install_ver_file(){
|
install_ver_file(){
|
||||||
|
|
||||||
mkdir -p ../rootfs/etc/cti
|
mkdir -p $PWD/../../rootfs/etc/cti
|
||||||
|
|
||||||
echo $CTI_L4T_VER > ../rootfs/etc/cti/CTI-L4T.version
|
echo $CTI_L4T_VER > $PWD/../../rootfs/etc/cti/CTI-L4T.version
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -144,8 +144,8 @@ chkfolder
|
||||||
tar -pxzf resources.tgz
|
tar -pxzf resources.tgz
|
||||||
|
|
||||||
#install CTI-flash
|
#install CTI-flash
|
||||||
mv cti-flash.sh ..
|
mv cti-flash.sh $PWD/../../
|
||||||
chmod +x ../cti-flash.sh
|
chmod +x $PWD/../../cti-flash.sh
|
||||||
|
|
||||||
install_conf
|
install_conf
|
||||||
|
|
||||||
|
@ -159,7 +159,7 @@ install_ver_file
|
||||||
|
|
||||||
install_extra
|
install_extra
|
||||||
|
|
||||||
pushd ..
|
pushd $PWD/../../
|
||||||
|
|
||||||
./apply_binaries.sh
|
./apply_binaries.sh
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue