From LedHed's Wiki
Jump to: navigation, search
(Created page with ' == Portsnap == Portsnap is used to update the FreeBSD ports tree This will fetch a new copy of the ports tree portsnap fetch This will extract the new tree to /usr/ports por...')
 
 
(2 intermediate revisions by the same user not shown)
Line 1: Line 1:
 
 
== Portsnap ==
 
== Portsnap ==
 
Portsnap is used to update the FreeBSD ports tree
 
Portsnap is used to update the FreeBSD ports tree
  
This will fetch a new copy of the ports tree
 
 
  portsnap fetch
 
  portsnap fetch
 +
This will fetch a new copy of the ports tree
  
This will extract the new tree to /usr/ports
 
 
  portsnap extract
 
  portsnap extract
 +
This will extract the new tree to /usr/ports
  
  
Line 20: Line 19:
 
== Installing Ports ==
 
== Installing Ports ==
 
  cd /usr/ports/<CATEGORY>/<PORT>
 
  cd /usr/ports/<CATEGORY>/<PORT>
  make install clean
+
  make install
 
+
If make config hasn't been run previously, then make config will also pop up.
  
 
== Removing Ports ==
 
== Removing Ports ==
Line 31: Line 30:
 
  make config
 
  make config
 
  make deinstall ;; make reinstall
 
  make deinstall ;; make reinstall
 +
make reinstall won't overwrite existing configs.
 +
  
  
 
== Clean Up ==
 
== Clean Up ==
 
  make clean
 
  make clean
 +
clears out the working directory
 +
 +
 +
 +
== Resetting Configs ==
 +
make rmconfig
 +
resets the make config back to default
 +
 +
 +
 +
== Portsnap and Proxy Servers ==
 +
If your FreeBSD server sits behind a proxy server then you will have trouble performing a portsnap fetch.
 +
To get around this set the following environment variables.<br>
 +
Note: I find it easier to export env vars with the 'sh' shell as opposed to the 'csh' shell.
 +
sh
 +
export HTTP_PROXY=http://proxyip:proxyport/
 +
export HTTP_PROXY_AUTH=basic:*:username:password
 +
This should allow you to authenticate and perform updates through the proxy.
  
  
 
[[Category:Ports]]
 
[[Category:Ports]]

Latest revision as of 18:52, 5 April 2013

Portsnap

Portsnap is used to update the FreeBSD ports tree

portsnap fetch

This will fetch a new copy of the ports tree

portsnap extract

This will extract the new tree to /usr/ports


Finding Ports

find /usr/ports/ -name <NAME OF PORT>*

or

locate <NAME OF PORT>


Installing Ports

cd /usr/ports/<CATEGORY>/<PORT>
make install

If make config hasn't been run previously, then make config will also pop up.

Removing Ports

cd /usr/ports/<CATEGORY>/<PORT>
make deinstall

Making Changes / Reinstalling Ports

cd /usr/ports/<CATEGORY>/<PORT>
make config
make deinstall ;; make reinstall

make reinstall won't overwrite existing configs.


Clean Up

make clean

clears out the working directory


Resetting Configs

make rmconfig

resets the make config back to default


Portsnap and Proxy Servers

If your FreeBSD server sits behind a proxy server then you will have trouble performing a portsnap fetch. To get around this set the following environment variables.
Note: I find it easier to export env vars with the 'sh' shell as opposed to the 'csh' shell.

sh
export HTTP_PROXY=http://proxyip:proxyport/
export HTTP_PROXY_AUTH=basic:*:username:password

This should allow you to authenticate and perform updates through the proxy.