[英]Changing .bashrc after manually installing a tool
I am working off of a cluster and since I do not have sudo privileges there, I had to install a toolkit at a different path ~/bin/tool_kit
. 我正在使用集群,并且由于那里没有sudo特权,因此我不得不在其他路径
~/bin/tool_kit
上安装工具箱。 This path now contains the following directories: bin
, include
and lib
. 现在,该路径包含以下目录:
bin
, include
和lib
。 This may be a very newbie question, but what changes do I make to my .bashrc
so that I am able to use this toolkit. 这可能是一个非常新手的问题,但是我需要对
.bashrc
进行哪些更改,以便能够使用此工具包。
For example, the $PATH
variable might be augmented like: export PATH = ~/bin/tool_kit/bin:$PATH
. 例如,
$PATH
变量可能会增加,例如: export PATH = ~/bin/tool_kit/bin:$PATH
。 How do I include lib
and include
? 如何包含
lib
和include
?
bin
is the only location you definitely need to do anything with: bin
是您绝对需要执行任何操作的唯一位置:
# using end of the PATH, unless you know you want to override like-named system binaries
PATH=$PATH:$HOME/bin/tool_kit/bin
No export
is needed here, as the PATH
variable is already in the environment. 这里不需要
export
,因为PATH
变量已经在环境中。
If and only if your software didn't compile in a rpath
pointing to the anticipated runtime library locations, you may also wish to set an LD_LIBRARY_PATH: 当且仅当您的软件未在指向预期运行时库位置的
rpath
编译时,您才可能希望设置LD_LIBRARY_PATH:
export LD_LIBRARY_PATH=${LD_LIBRARY_PATH+$LD_LIBRARY_PATH:}$HOME/bin/tool_kit/lib
include
files are used only when compiling other software, and are not generally needed at runtime. include
文件仅在编译其他软件时使用,并且在运行时通常不需要。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.