"port: command not found" after installing MacPorts-1.6.0-10.5-Leopard.dmg

Ryan Schmidt ryandesign at macports.org
Fri Feb 8 23:10:51 PST 2008


On Feb 8, 2008, at 23:02, Esteban Barahona wrote:

> El feb 8, 2551 BE, a las 00:00, Ryan Schmidt escribió:
>
>> On Feb 7, 2008, at 21:23, Esteban Barahona wrote:
>>
>>> Asunto: "port: command not found" after installing  
>>> MacPorts-1.6.0-10.5-Leopard.dmg
>>>
>>> I downloaded the latest package to install macports; but the  
>>> "port command" doesn't work.
>>> I read the guide up to 2.4. MacPorts and the Shell (at http:// 
>>> guide.macports.org)
>>>
>>> after disabling "invisible files" and searching for the .profile  
>>> file, it did not appear...
>>> This seems like quite a basic problem… but I cann't continue with  
>>> testing ports.
>>>
>>> Maybe what's left is to configure the terminal so that it can  
>>> accept the "port command"?
>>
>> MacPorts installer is supposed to configure this for you, but  
>> because of a bug in 1.6.0, this does not happen. This will be  
>> fixed in 1.6.1. You will have to set up your .profile yourself.  
>> Since you don't have a .profile, create an empty file, then follow  
>> the instructions in the guide:
>>
>> http://guide.macports.org/#installing.shell
>>
>> You will need to set the PATH variable. If running Mac OS X 10.4  
>> or earlier, you should also set the DISPLAY variable. If after  
>> opening a new Terminal window, "man port" does not work, you  
>> should also add the MANPATH variable.
>
> thanks, but it didn't work, maybe it was because I made an empty  
> file .profile... where can I download manually this file? ...I will  
> wait for the 1.6.1 installer or try it from source (an oportunity  
> to learn more I guess...). For when is this update planed?

.profile is a place for you to customize your shell. It's fine to  
start from any empty file, if you have no other customizations you  
want to make.

If you have a .bash_profile, that gets used instead of .profile so  
you should modify .bash_profile instead. If you have neither, you can  
create either and modify it.


It should contain a line like this:

export PATH=/opt/local/bin:/opt/local/sbin:$PATH


I'm on Tiger, so my .bash_profile also contains this line:

export DISPLAY=:0.0

If you're on Leopard, do not add that line; DISPLAY is already set up  
for you by the operating system.


Add this line only if "man port" does not show you the port manpage:

export MANPATH=/opt/local/share/man:$MANPATH


Note that after changing your .bash_profile you need to open a new  
Terminal window. Any Terminal windows already open won't inherit the  
changes.



More information about the macports-users mailing list