Gentoo Archives: gentoo-user

From: Ian Zimmerman <itz@×××××××.net>
To: gentoo-user@l.g.o
Subject: [gentoo-user] Re: How do you manage manually compiled software?
Date: Fri, 28 Apr 2017 03:35:52
Message-Id: 20170428032354.26417.066F1B0E@matica.foolinux.mooo.com
In Reply to: [gentoo-user] How do you manage manually compiled software? by Danny YUE
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