# Packages



## Meikj (Jun 6, 2009)

Hi. I have been very interested in FreeBSD and I have been reading up about it. The subject of ports and packages confuses me a little bit and I'm hoping you will be able to clear up any of my misunderstandings. 

My question is about the package manager in FreeBSD. Can the package manager download the software automatically for me by searching the repositories? Or do I need to manually download the packages myself?

What if I want to install a group of packages which make up the XFce desktop environment? I was browsing the packages on the FTP server and they were all individual packages. Would I need to manually download all these packages or will the package manager be able to sort this all out for me.

Thanks in return.


----------



## vivek (Jun 6, 2009)

Meikj said:
			
		

> My question is about the package manager in FreeBSD. Can the package manager download the software automatically for me by searching the repositories? Or do I need to manually download the packages myself?
> No FreeBSD will download and install all software for you. There is no such thing called repos in FreeBSD (repoes are for different linux distros).





			
				Meikj said:
			
		

> What if I want to install a group of packages which make up the XFce desktop environment? I was browsing the packages on the FTP server and they were all individual packages. Would I need to manually download all these packages or will the package manager be able to sort this all out for me.


Yes, freebsd ports will download and install packages as you need. There is also pkg_add binary package tool which can install all software on demand.


Ports - Download all software source, compile and install it. 
Package - Download prebuilt binary files and install it (just like deb or rpm files).
You can use any one of the method or mix both. End result will same. Read this chapter for more info: http://www.freebsd.org/doc/en/books/handbook/ports.html


----------



## ale (Jun 6, 2009)

Meikj said:
			
		

> Can the package manager download the software automatically for me by searching the repositories?


Yes.
http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/packages-using.html



			
				Meikj said:
			
		

> What if I want to install a group of packages which make up the XFce desktop environment?


Look for example here:
http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/x11-wm.html#X11-WM-XFCE-INSTALL


----------



## Meikj (Jun 6, 2009)

Can this pkg_add tool download the binaries for me? Because I was looking at example syntax and the user was explicitly passing the package file name he downloaded via FTP. But what if I want to install a group of packages which make up XFce? Can I just pass "xfce" to pkg_add and it will download all the packages which make up XFce?


----------



## Meikj (Jun 6, 2009)

ale said:
			
		

> Yes.
> http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/packages-using.html
> 
> Look for example here:
> http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/x11-wm.html#X11-WM-XFCE-INSTALL


Thanks for the links. I was reading the first one but due to my ignorance I only read the start. Both completely answer my question.

Thank you both of you!


----------



## vivek (Jun 6, 2009)

Yes, just type the following and it will install everything needed to run xfce4 desktop including X.org:

```
pkg_add -r xfce4
```
Again, please read freebsd handbook, it has all info: http://www.freebsd.org/doc/en/books/handbook/x11.html


----------

