Re: Install a package to alternative location

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]



On Fri, 18 Aug 2023 11:00:37 +0900
"lain." <lain@xxxxxxxx> wrote:

> This is how I have set it up:
> /usr/bin = systemwide binaries
> /usr/lib = systemwide libraries
> ~/.local/bin = user binaries
> ~/.local/lib = user libraries
> 
> I don't really like to use /usr/local/* on Linux, because it's not as
> portable as just /usr.
> I use it only in FreeBSD and OpenBSD, simply because it's the default
> behavior there.
> 
> If you compile from source (includes AUR):
> ./configure --prefix="~/.local"
> make DESTDIR="~/.local" install
> 
> If directly from the pacman repo's:
> pacman -S android-ndk -r ~/.local -b /var/lib/pacman
> The one downside of that is that it'll install for example
> "android-tools" under ~/.local/usr/bin rather than ~/.local/bin though,
> but with a bit of manual labor, you can correct that.
> 
> Then in your .bashrc or .zshrc:
> export PATH=~/.local/bin:$PATH
> 
> This way you can install multiple versions of software, and binaries in
> ~/.local will take preference over those in /usr, and you can always
> just run /usr/bin/whatever if you want to run the systemwide version
> instead.

And none of them are likely to work. It'll have no way to find it's libraries
or other resources. You CANNOT use pacman for something like this.



[Index of Archives]     [Linux Wireless]     [Linux Kernel]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Share Photos]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Device Mapper]

  Powered by Linux