OpenCores
URL https://opencores.org/ocsvn/minsoc/minsoc/trunk

Subversion Repositories minsoc

Compare Revisions

  • This comparison shows the changes necessary to convert path
    /minsoc/trunk/utils
    from Rev 168 to Rev 167
    Reverse comparison

Rev 168 → Rev 167

/setup/minsoc-install.sh
50,56 → 50,28
fi;
 
 
# Selecting automated or advanced intallation modes
# Wizard
if [ -z "${AUTO}" ]
# Testing necessary tools
cecho "Testing if necessary tools are installed, program "whereis" is required."
testtool wget
testtool svn
testtool bzip2
testtool tar
testtool sed
testtool patch
testtool gcc
testtool make
testtool makeinfo
testtool libncurses
testtool flex
testtool bison
testtool libz
if [ "$ENV" == "Cygwin" ]
then
while [ "${AUTO}" != "R" ] && [ "${AUTO}" != "A" ]
do
cecho "Select installation mode.";
cnecho " Enter R for Resumed or A for Advanced mode or H for Help: "
read AUTO;
if [ ${AUTO} == "H" ]
then
cecho "Advanced mode:"
cecho " the script only downloads and installs the required tools. Dependency libraries and tools are checked during individual tool compilation. Furthermore, the install directory is not added to the system PATH. You have to do it yourself. Libusb, libftdi and Icarus Verilog are supposed to be installed by the user.\n"
cecho "Resumed mode:"
cecho " the script checks if the dependency libraries and tools are installed before doing anything. It also adds the installation directory to the system PATH variable for bash shells on HOME/.bashrc. Libusb, libftdi and Icarus Verilog are automatically installed for you.\n"
fi
done
if [ "${AUTO}" == "R" ]
then
cecho "Resumed mode selected";
else
cecho "Advanced mode selected";
fi
testtool ioperm
testtool libusb
fi
 
 
# Testing necessary tools
if [ "${AUTO}" == "R" ]
then
cecho "Testing if necessary tools are installed, program "whereis" is required."
testtool wget
testtool svn
testtool bzip2
testtool tar
testtool sed
testtool patch
testtool gcc
testtool make
testtool makeinfo
testtool libncurses
testtool flex
testtool bison
testtool libz
if [ "$ENV" == "Cygwin" ]
then
testtool ioperm
testtool libusb
fi
fi
 
# Wizard
if [ -z "${ALTDIR}" ]
then
151,15 → 123,12
execcmd "Downloading GDB" "wget ftp://anonymous:anonymous@ftp.gnu.org/gnu/gdb/gdb-6.8a.tar.bz2"
execcmd "wget ftp://ocuser:ocuser@openrisc.opencores.org/toolchain/or32-gdb-6.8-patch-2.4.bz2"
execcmd "svn export -q http://opencores.org/ocsvn/adv_debug_sys/adv_debug_sys/trunk/Patches/GDB6.8/gdb-6.8-bz436037-reg-no-longer-active.patch"
if [ "${AUTO}" == "R" ]
if [ "$ENV" != "Cygwin" ]
then
if [ "$ENV" != "Cygwin" ]
then
execcmd "Downloading libusb-0.1 for Advanced Debug System" "wget http://sourceforge.net/projects/libusb/files/libusb-0.1%20%28LEGACY%29/0.1.12/libusb-0.1.12.tar.gz"
fi
execcmd "Downloading libftdi for Advanced Debug System" "wget http://www.intra2net.com/en/developer/libftdi/download/libftdi-0.19.tar.gz"
execcmd "Downloading Icarus Verilog" "wget ftp://icarus.com/pub/eda/verilog/v0.9/verilog-0.9.4.tar.gz"
execcmd "Downloading libusb-0.1 for Advanced Debug System" "wget http://sourceforge.net/projects/libusb/files/libusb-0.1%20%28LEGACY%29/0.1.12/libusb-0.1.12.tar.gz"
fi
execcmd "Downloading libftdi for Advanced Debug System" "wget http://www.intra2net.com/en/developer/libftdi/download/libftdi-0.19.tar.gz"
execcmd "Downloading Icarus Verilog" "wget ftp://icarus.com/pub/eda/verilog/v0.9/verilog-0.9.4.tar.gz"
 
 
#Uncompressing everything
178,15 → 147,12
fi
execcmd "tar -jxf gdb-6.8a.tar.bz2"
execcmd "bzip2 -d or32-gdb-6.8-patch-2.4.bz2"
if [ "${AUTO}" == "R" ]
if [ "$ENV" != "Cygwin" ]
then
if [ "$ENV" != "Cygwin" ]
then
execcmd "tar zxf libusb-0.1.12.tar.gz"
fi
execcmd "tar zxf libftdi-0.19.tar.gz"
execcmd "tar zxf verilog-0.9.4.tar.gz"
execcmd "tar zxf libusb-0.1.12.tar.gz"
fi
execcmd "tar zxf libftdi-0.19.tar.gz"
execcmd "tar zxf verilog-0.9.4.tar.gz"
 
 
#Compiling and Installing all packages
221,23 → 187,20
 
 
#Installing Advanced JTAG Bridge support libraries
if [ "${AUTO}" == "R" ]
if [ "$ENV" != "Cygwin" ]
then
if [ "$ENV" != "Cygwin" ]
then
execcmd "cd ${DIR_TO_INSTALL}/download/libusb-0.1.12"
execcmd "./configure --prefix=${DIR_TO_INSTALL}/tools"
execcmd "Installing libusb-0.1" "make"
execcmd "make install"
fi
 
execcmd "cd ${DIR_TO_INSTALL}/download/libftdi-0.19"
execcmd "PATH=\"$PATH:${DIR_TO_INSTALL}/tools/bin\" ./configure --prefix=${DIR_TO_INSTALL}/tools CPPFLAGS=-I${DIR_TO_INSTALL}/tools/include"
execcmd "Compiling libftdi" "make"
execcmd "make install"
execcmd "cd ${DIR_TO_INSTALL}/download/libusb-0.1.12"
execcmd "./configure --prefix=${DIR_TO_INSTALL}/tools"
execcmd "Installing libusb-0.1" "make"
execcmd "make install"
fi
 
execcmd "cd ${DIR_TO_INSTALL}/download/libftdi-0.19"
execcmd "PATH=\"$PATH:${DIR_TO_INSTALL}/tools/bin\" ./configure --prefix=${DIR_TO_INSTALL}/tools CPPFLAGS=-I${DIR_TO_INSTALL}/tools/include"
execcmd "Compiling libftdi" "make"
execcmd "make install"
 
 
#Installing Advanced JTAG Bridge
execcmd "cd ${DIR_TO_INSTALL}/minsoc/rtl/verilog/adv_debug_sys/Software/adv_jtag_bridge"
execcmd "./autogen.sh"
247,13 → 210,10
 
 
#Installing Icarus Verilog
if [ "${AUTO}" == "R" ]
then
execcmd "cd ${DIR_TO_INSTALL}/download/verilog-0.9.4"
execcmd "./configure --prefix=${DIR_TO_INSTALL}/tools"
execcmd "Compiling Icarus Verilog" "make"
execcmd "make install"
fi
execcmd "cd ${DIR_TO_INSTALL}/download/verilog-0.9.4"
execcmd "./configure --prefix=${DIR_TO_INSTALL}/tools"
execcmd "Compiling Icarus Verilog" "make"
execcmd "make install"
 
 
#Configuring MinSoC, Advanced Debug System and patching OpenRISC
261,20 → 221,10
 
 
#Setting-up new variables
if [ "${AUTO}" == "R" ]
then
cecho "\nSystem configurations"
execcmd "Adding MinSoC tools to PATH" "echo \"PATH=\\\"\\\$PATH:$DIR_TO_INSTALL/tools/bin\\\"\" >> /home/$(whoami)/.bashrc;";
execcmd "Adding OpenRISC toolchain to PATH" "echo \"PATH=\\\"\\\$PATH:$DIR_TO_INSTALL/tools/or32-elf/bin/\\\"\" >> /home/$(whoami)/.bashrc;";
cecho "\nSystem configurations"
execcmd "Adding MinSoC tools to PATH" "echo \"PATH=\\\"\\\$PATH:$DIR_TO_INSTALL/tools/bin\\\"\" >> /home/$(whoami)/.bashrc;";
execcmd "Adding OpenRISC toolchain to PATH" "echo \"PATH=\\\"\\\$PATH:$DIR_TO_INSTALL/tools/or32-elf/bin/\\\"\" >> /home/$(whoami)/.bashrc;";
 
cecho "\nInstallation Complete!"
cecho "Before using the system, load the new environment variables doing this: source /home/$(whoami)/.bashrc"
cecho "You may remove the ${DIR_TO_INSTALL}/download directory if you wish."
else
cecho "\nInstallation Complete!\n"
cecho "Remember to add the two following directories in the following order to the PATH system variable."
cecho "1) $DIR_TO_INSTALL/tools/bin "
cecho "2) $DIR_TO_INSTALL/tools/or32-elf/bin "
cecho "You may remove the ${DIR_TO_INSTALL}/download directory if you wish."
fi
 
cecho "\nInstallation Complete!"
cecho "Before using the system, load the new environment variables doing this: source /home/$(whoami)/.bashrc"
cecho "You may remove the ${DIR_TO_INSTALL}/download directory if you wish."

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.