Forum Discussion

Altera_Forum's avatar
Altera_Forum
Icon for Honored Contributor rankHonored Contributor
18 years ago

About BinaryToolchain

i followed the passage on niosWiki:

binarytoolchain (http://www.niosforum.com/pages/forum.php?cat_id=5)

i run the command in terminal:

*********************

su -# your root passwd

tar jxf /home/hippo/download/nios2gcc.tar.bz2 -C /

exit

***********************

after that, i found the cross gcc tools in "/opt/nios2", then i opened the file".bash_profile" and added "PATH=$PATH:/opt/nios2/bin:$HOME/bin" into it.

but when i run the command "nios2-linux-uclibc-gcc -v", the terminal showed followed error:

"bash:nios2-linux-uclibc-gcc -v : can't find the command",

i hope someone can help me! thanks

3 Replies

  • Altera_Forum's avatar
    Altera_Forum
    Icon for Honored Contributor rankHonored Contributor

    after you change the .bashprofile, you need to logout and login again.

  • Altera_Forum's avatar
    Altera_Forum
    Icon for Honored Contributor rankHonored Contributor

    --- Quote Start ---

    originally posted by hippo@Apr 4 2007, 12:16 AM

    after you change the .bashprofile, you need to logout and login again.

    <div align='right'><{post_snapback}> (index.php?act=findpost&pid=22782)

    --- quote end ---

    --- Quote End ---

    thanks, hippo.but i still can&#39;t run the command "nios2-linux-uclibc-gcc -v" after logining again. and my .bash_profile&#39;s content is :

    ======================================# ~/.bash_profile: executed by bash(1) for login shells.# see /usr/share/doc/bash/examples/startup-files for examples.# the files are located in the bash-doc package.

    # the default umask is set in /etc/login.defs# umask 022

    # include .bashrc if it exists

    if [ -f ~/.bashrc ]; then

    . ~/.bashrc

    fi

    # set PATH so it includes user&#39;s private bin if it exists

    if [ -d ~/bin ] ; then

    PATH=~/bin:"${PATH}"

    fi

    PATH=$PATH:/opt/nios2/bin:$HOME/bin

    =======================================

    is there any problem whit it? hope you can help me ,thanks!

    by the way, my linux-OS is Ubuntu6.1
  • Altera_Forum's avatar
    Altera_Forum
    Icon for Honored Contributor rankHonored Contributor

    i have solved the problem, i setted the PATH in the file ".bashrc", adding following text:# ###

    export PATH="$PATH:/opt/nios2/bin:$HOME/bin"# ###

    then i can run the command "nios2-linux-uclibc-gcc -v ".

    i think the PATH settings vary from different linux OS, maybe! http://forum.niosforum.com/work2/style_emoticons/<#EMO_DIR#>/smile.gif