# Install software from tar.gz



## vist (Oct 23, 2011)

Dear colleagues, please tell me how to install software from tar.gz packages? I've tried to look at handbook, but I found nothing...


----------



## johnd (Oct 23, 2011)

Try looking at the documentation of the software you want to install. What software are you talking about? IsnÂ´t it available from the ports tree under /usr/ports? If you donÂ´t know if itÂ´s available try: 
	
	



```
whereis firefox
```
 in case firefox is the software you want to install.

If you want to unpack your tar.gz-file use: 
	
	



```
tar -xf file.tar.gz
```
. Tar should detect the compression used automatically on newer Versions of FreeBSD. Consult tar(1) on your System.


----------



## vist (Oct 23, 2011)

It is not a problem to extract the package. I can't install it... I want to install the package from CD-ROM drive.


----------



## shitson (Oct 23, 2011)

Have you mounted the CD-ROM?


```
su -
```


```
mount /cdrom
```


----------



## johnd (Oct 23, 2011)

A little bit information would be very helpful. What are you trying to install and what have you done so far? Have you tried the whereis command? Last time i have installed software from CD-ROM was in 2006 
Did you mount the CD?


----------



## vist (Oct 23, 2011)

KDE mounted the CD-ROM automatically. I am running FreeBSD under VMWARE Workstation 7.1. To run video driver correctly I must install VMWARE tools package, that is mounted to the virtual machine as CD-ROM. The CD contains tar.gz package. I can access it. I tried to extract the package with console tar and graphical tar, but it does now want to compile.


```
cd /folder/package_folder
make install
```

"don't know how to make package"

If I try


```
pkg_add /cdrom/package.tar.gz
```

it tells me "unable to extract table of contents file"...


----------



## johnd (Oct 23, 2011)

Hmm, I donÂ´t use FreeBSD as a guest under VMWARE. But I found this: http://www.vmware.com/support/ws5/doc/ws_newguest_tools_freebsd.html


----------



## Bunyan (Oct 23, 2011)

vist said:
			
		

> If I try
> 
> 
> ```
> ...



It will always say that, because *pkg_add* operates with *.tbz files only.


----------



## vist (Oct 23, 2011)

Bunyan said:
			
		

> It will always say that, because *pkg_add* operates with *.tbz files only.



Ok, clear. So, how should I install tar.gz?


----------



## wblock@ (Oct 23, 2011)

tar.gz is just a compressed archive file, it could contain anything.  How to install the contents will depend on what those contents are.

Ports like emulators/open-vm-tools might be a better alternative.


----------



## Bunyan (Oct 24, 2011)

vist said:
			
		

> please tell me how to install software from tar.gz packages?


1) Unpack the archive.
2) Enter the DIR
3) *less README*
4) *./configure --help*
5) *./configure*
6) *make* (*gmake*)
7) *sudo make* (*gmake*) *install*


----------



## silverglade00 (Oct 25, 2011)

This is how we do vmware-tools at my job. 

An installed version of Perl is needed.
The compatibility layer for BSD version 6.x is needed

`# cd /usr/ports/misc/compat6x`
`# make install clean`

Present the guest OS using vSphere -> Guest ->   Install/Upgrade VMware Tools
The presents a virtual cdrom to the guest OS.

Mount the cdrom
`# mount /cdrom`

Mount the tools file from cdrom
`# cp /cdrom/vmware-freebsd-tools.tar.gz /root`
uncompress them
`# gzip -d vmware-freebsd-tools.tar.gz`
untar them
`# tar -xvf vmware-freebsd-tools.tar`
move into the directory
`# cd vmware-tools-distrib`
execute the install script
`# ./vmware-install.pl`
answer a bunch of questions.  The defualts setting are fine.

Please remember to configure your network by adding:

```
ifconfig_vxn0="dhcp"
```
to the /etc/rc.conf file and start the network with:
`# /etc/netstart`
to use the vmxnet interface using DHCP.

The new virtual interface is hidden from the OS.  The VMware host can now talk to the guest OS via the vxn0 interface.


----------



## freekays (Nov 29, 2022)

tar.gz rename format tgz

file.tar.gz >>>>> file.tgz
rename ok


----------

