1 |
On 2017-04-28 09:33, Danny YUE wrote: |
2 |
|
3 |
> I am compiling RISC-V tools...I am just curious how do you manage your |
4 |
> manually compiled software? |
5 |
|
6 |
Michael already posted the "correct answer", and that's what I'm slowly |
7 |
migrating towards, myself. |
8 |
|
9 |
But the best way I've found before that was install it in a specific |
10 |
subtree of my ~ (that way I don't need root at any time), and manage |
11 |
PATH semi-automatically, as follows: |
12 |
|
13 |
1. make a symlink in ~/bin to each subdirectory containing programs. |
14 |
For example, if I install foopkg in ~/foopkg/ and the foo program is |
15 |
~/foopkg/bin/foo , I symlink ~/bin/foopkg -> ../foopkg/bin . |
16 |
|
17 |
2. this snippet very early in my .bashrc adds each such subdirectory to |
18 |
the PATH: |
19 |
|
20 |
case $PATH in |
21 |
(*/rc-scripts*) |
22 |
: |
23 |
;; |
24 |
(*) |
25 |
PATH=$PATH:$( find ~/bin -type l -xtype d | paste -sd: ) |
26 |
;; |
27 |
esac |
28 |
|
29 |
The first case is there to prevent recursion, as I know that rc-scripts |
30 |
will always be one of the symlinks. |
31 |
|
32 |
hth, |
33 |
|
34 |
-- |
35 |
Please *no* private Cc: on mailing lists and newsgroups |
36 |
Personal signed mail: please _encrypt_ and sign |
37 |
Don't clear-text sign: |
38 |
http://primate.net/~itz/blog/the-problem-with-gpg-signatures.html |