bash :: / usr / X11R6 / lib:/ usr / local / lib:没有这样的文件或目录

时间:2014-11-26 14:43:01

标签: bash

我开始安装ns2,之后我打开终端时收到此消息

bash :: / usr / X11R6 / lib:/ usr / local / lib:没有这样的文件或目录

有什么想法吗?!

我将此添加到我的bashrc

# LD_LIBRARY_PATH
OTCL_LIB=/home/Apps/ns-allinone-2.35/otcl-1.14
NS2_LIB=/home/Apps/ns-allinone-2.35/lib
X11_LIB=/usr/X11R6/lib
USR_LOCAL_LIB=/usr/local/lib
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$OTCL_LIB:$NS2_LIB
:$X11_LIB:$USR_LOCAL_LIB

# TCL_LIBRARY
TCL_LIB=/home/Apps/ns-allinone-2.35/tcl8.5.10/library
USR_LIB=/usr/lib
export TCL_LIBRARY=$TCL_LIB:$USR_LIB

# PATH
XGRAPH=/home/Apps/ns-allinone-2.35/bin:/home/Apps/ns-allinone-2.35/tcl8.5.10/unix:/home/Apps/ns-allinone-2.35/tk8.5.10/unix:/home/Apps/ns-allinone-2.33/xgraph-12.2/
NS=/home/Apps/ns-allinone-2.35/ns-2.35/
NAM=/home/Apps/ns-allinone-2.35/nam-1.15/
export PATH=$PATH:$XGRAPH:$NS:$NAM

1 个答案:

答案 0 :(得分:0)

您正在尝试安装NS-2,但是您添加到.bashrc文件的行略有错误。相反,您必须在.bashrc中添加以下行来设置环境变量(请记住将/path_to/替换为您提取ns的位置;通过查看您的帖子,{{1} }):

/home/Apps/

在此之后您必须重新启动系统,或者您可以使用

  

source~ / .bashrc

重新加载# LD_LIBRARY_PATH OTCL_LIB=/path_to/ns-allinone-2.35/otcl-1.14/ NS2_LIB=/path_to/ns-allinone-2.35/lib/ USR_Local_LIB=/usr/local/lib/ export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$OTCL_LIB:$NS2_LIB:$USR_Local_LIB # TCL_LIBRARY TCL_LIB=/path_to/ns-allinone-2.35/tcl8.5.10/library/ USR_LIB=/usr/lib/ export TCL_LIBRARY=$TCL_LIBRARY:$TCL_LIB:$USR_LIB # PATH XGRAPH=/path_to/ns-allinone-2.35/xgraph-12.2/:/path_to/ns-allinone-2.35/bin/:/path_to/ns-allinone-2.35/tcl8.5.10/unix/:/path_to/ns-allinone-2.35/tk8.5.10/unix/ NS=/path_to/ns-allinone-2.35/ns-2.35/ NAM=/path_to/ns-allinone-2.35/nam-1.15/ export PATH=$PATH:$XGRAPH:$NS:$NAM 。现在运行.bashrc,您将获得ns

您可能需要参阅此博客以获取安装说明http://installwithme.blogspot.in/2014/05/how-to-install-ns-2.35-in-ubuntu-13.10-or-14.04.html