installing binary archives as non-root user
ryandesign at macports.org
Sun Nov 19 22:52:47 UTC 2017
On Nov 19, 2017, at 15:46, db wrote:
> On 18 Nov 2017, at 20:38, Ryan Schmidt wrote:
>> Yeah, really, nope. Ports are able to make decisions based on the install user; some ports do different things when installing as root vs. installing as a normal user.
> I've been reading some of Homebrew's documentation before giving it a try and found out that it doesn't use root. How would you compare both approaches?
I have no knowledge of what homebrew does. But the description at that link says running homebrew with sudo is bad because that would make the build commands that homebrew runs run as root. I agree that would be bad. As I explained, MacPorts doesn't do that. Instead, when you run MacPorts with sudo, it drops privileges by switching to the "macports" user. This is better than using a non-root MacPorts installation, because a non-root MacPorts installation runs MacPorts as whatever user you installed it as, for example your own user account. Using the "macports" user is safer because it has fewer privileges than your user account.
More information about the macports-users