this post was submitted on 05 Aug 2023
43 points (92.2% liked)

Linux

45530 readers
1026 users here now

From Wikipedia, the free encyclopedia

Linux is a family of open source Unix-like operating systems based on the Linux kernel, an operating system kernel first released on September 17, 1991 by Linus Torvalds. Linux is typically packaged in a Linux distribution (or distro for short).

Distributions include the Linux kernel and supporting system software and libraries, many of which are provided by the GNU Project. Many Linux distributions use the word "Linux" in their name, but the Free Software Foundation uses the name GNU/Linux to emphasize the importance of GNU software, causing some controversy.

Rules

Related Communities

Community icon by Alpár-Etele Méder, licensed under CC BY 3.0

founded 5 years ago
MODERATORS
 

I'm doing a bunch of AI stuff that needs compiling to try various unrelated apps. I'm making a mess of config files and extras. I've been using distrobox and conda. How could I do this better? Chroot? Different user logins for extra home directories? Groups? Most of the packages need access to CUDA and localhost. I would like to keep them out of my main home directory.

you are viewing a single comment's thread
view the rest of the comments
[–] [email protected] 19 points 11 months ago* (last edited 11 months ago) (10 children)

I did Linux From Scratch recently and they have a brilliant solution. Here's the full text but it's a long read so I'll briefly explain it. https://www.linuxfromscratch.org/hints/downloads/files/more_control_and_pkg_man.txt

Basically you make a new user with the name of the package you want to install. Login to that user then compile and install the package.

Now when you search for files owned by the user with the same name as the package you will find every file that package installed.

You can document that somewhere or just use the find command when you are ready to remove all files related to the package.

I didn't actually do this for my own LFS build so I have no further experience on the matter. I think it will eventually lead to dependency hell when two packages want to install the same file.

I guess flatpaks are better about keeping libraries separate but I'm not sure if they leave random files all over your hard drive the way apt remove/apt purge does. (Getting really annoyed about all the crud left in my home dir)

[–] [email protected] 6 points 11 months ago (2 children)

That’s clever. It should work on any system, shouldn’t it?

[–] [email protected] 2 points 11 months ago (1 children)

Any POSIX compliant system as far as I know.

[–] [email protected] 3 points 11 months ago

Thanks. I’ll keep that in mind for again.

load more comments (7 replies)