I am trying to install Bedtools in a user directory, however I looked at the manual for its makefile, and there is no such argument like "--prefix" for me to change. Is there a way to install all Bedtools in a directory that I specify? Thanks!
I am trying to install Bedtools in a user directory, however I looked at the manual for its makefile, and there is no such argument like "--prefix" for me to change. Is there a way to install all Bedtools in a directory that I specify? Thanks!
According to the manual, the make procedure will place all binaries into /BEDTools.<version>./bin/, so you can just copy all the files from there to the directory of your choosing (as discussed in the comments, the target directory should presumably be contained in your $PATH variable).
From what you are telling it looks like you are bound to use a restricted login shell. This might be a rare situation, but under these circumstances you will be unable to build and run any program that is not on the predefined path already (unless your admin is a dummy) or change that path, this has nothing to do with bedtools. You need to contact your sysadmin to install any additional program you want to run.
Sorry, just saw that this was posted 9 months ago.
You might want to discuss with your systems administrator the restriction about changing environment variables. But if you can't change your PATH environment variable, then perhaps you could try using the 'alias' command:
alias bedtools=/path/to/bin/bedtools
Are you allowed to edit your shell's profile? You should be able to add this alias (among the other shell wrappers in the bedtools/bin).
[EDIT]
As pointed out by @Michael Dondrup, alias solution as is above will not work. However, there is a caveat in the restrictions, namely, the following from the bash manual
When a command that is found to be a shell script is executed (see COMMAND EXECUTION above), rbash turns off any restrictions in the shell spawned to execute the script
So to take advantage of this, one could create an alias prepending 'bash' to the bedtools scripts, like so,
alias intersectbed="bash /path/to/intersectbed.sh"
This should work; but please let me know if it doesn't!
Use of this site constitutes acceptance of our User Agreement and Privacy Policy.
Couldn't you just compile it and then put the executable files wherever you want? Then add that directory to your path? That's how I normally do it.
thanks! but I cannot add the directory to my path due to permission limitations...
if you run SETENV or EXPORT in order to set your environment variables, what exactly shell tells you? I didn't know one can disable user's ability to set those.
yes it's possible to prevent setting PATH using restricted shell:
but you should quarrel with your sysadmin, because it's just annoying (and not more secure unless installed absolutely the correct way) or try to break out of it, how to is in the wikipedia article. So, I guess that you are in some sort of 'high-security' setting, like a hospital server with personal genomics data. If restricted shell is used correctly, you will possibly not be able to install and run any software from your home but need to ask your IT guy to install it.
Run
echo $PATH
to find directories from which you can run binaries. Copy your binaries-of-interest to one of these folders. If you have no permissions to change the contents of these folders, edit your shell's profile to add a local directory (one which you have control over) to yourPATH
variable (e.g., http://www.troubleshooters.com/linux/prepostpath.htm). Copy your binaries-of-interest to this local directory.Or just write the whole path when you invoke the programs