installer doesn't modify root path

Harald Hanche-Olsen hanche at math.ntnu.no
Tue Feb 2 06:57:39 PST 2016


Well, you did not say in the bug report that you were using sudo, so no wonder it got closed.

My own systems are too heavily modified at the moment for me to be sure, but I have a file /etc/paths.d/45-macports containing the two lines

/opt/local/bin
/opt/local/sbin

These should be enough to ensure that those directories appear in the path when you run sudo. You can check by running “sudo printenv PATH”. I believe that file is installed by the macports installer? If not, you can install it yourself. But from what you say, I gather you must have this file? What about /etc/sudoers? Have you made any modifications to that file?

– Harald

-----Original Message-----
From: Phil Oertel <phillipao at gmail.com>
Date: 2 February 2016 at 06:34:21

> I'm unable to sudo run any port commands after installing macports (version
> 2.3.4, system is El Capitan 10.11.3). I installed via the package
> installer. After running the installer and opening a new shell, my login
> user has /opt/local/bin on his path, but root does not. So `sudo port`
> results in "not found".
>  
> I filed a bug, https://trac.macports.org/ticket/50503, and it was promptly
> closed […]



More information about the macports-users mailing list