# Problem while installing openoffice.org-3



## weziw (Dec 15, 2009)

I did a make install clean in the /usr/ports/editors/openoffice.org-3] port and I get the following error:


```
checking for strstr... yes
checking for strtol... yes
checking for strtoull... yes
checking for backtrace... no
checking for backtrace_symbols... no
checking whether Python support is requested... checking whether /usr/local/bin/python2.6 version >= 2.5... yes
checking for /usr/local/bin/python2.6 version... 2.6
checking for /usr/local/bin/python2.6 platform... freebsd8
checking for /usr/local/bin/python2.6 script directory... ${prefix}/lib/python2.6/site-packages
checking for /usr/local/bin/python2.6 extension module directory... ${exec_prefix}/lib/python2.6/site-packages
checking for headers required to compile python extensions... not found
configure: error: Python headers not found
===>  Script "configure" failed unexpectedly.
Please run the gnomelogalyzer, available from
"http://www.freebsd.org/gnome/gnomelogalyzer.sh", which will diagnose the
problem and suggest a solution. If - and only if - the gnomelogalyzer cannot
solve the problem, report the build failure to the FreeBSD GNOME team at
gnome@FreeBSD.org, and attach (a)
"/usr/ports/devel/gobject-introspection/work/gobject-introspection-0.6.6/config.log",
(b) the output of the failed make command, and (c) the gnomelogalyzer output.
Also, it might be a good idea to provide an overview of all packages installed
on your system (i.e. an `ls /var/db/pkg`). Put your attachment up on any
website, copy-and-paste into http://freebsd-gnome.pastebin.com, or use
send-pr(1) with the attachment. Try to avoid sending any attachments to the
mailing list (gnome@FreeBSD.org), because attachments sent to FreeBSD mailing
lists are usually discarded by the mailing list software.
*** Error code 1

Stop in /usr/ports/devel/gobject-introspection
```

I tried  to go into the /usr/ports/devel/gobject-introspection port but there are no configurable options.
Now I am stuck and can not install openoffice. Can anyone help?


----------



## aragon (Dec 15, 2009)

Looks like it just needs lang/python?


----------



## DutchDaemon (Dec 15, 2009)

See /usr/local/lib/python2.6/site-packages/README ? I think there's a command to create them if they don't exist. They seem to be missing in your case.


----------



## weziw (Dec 19, 2009)

Hey guys, thanks for the replies. I read the /usr/local/lib/python2.6/site-packages/README file and this is what it says:


> cat /usr/local/lib/python2.6/site-packages/README | less
> This directory exists so that 3rd party packages can be installed
> here.  Read the source for site.py for more details.



Now how do I get to the source for site.py?

I am also not sure how to install the python headers as suggested. These are all the directories I have on the system:

```
cd /usr/ports/lang/py
py-mx-base/                   python-doc-pdf-a4/            python-mode.el/               python26/
py-prolog/                    python-doc-pdf-letter/        python23/                     python30/
python/                       python-doc-postscript-a4/     python24/                     python31/
python-doc-html/              python-doc-postscript-letter/ python25/
```

Thanks again and sorry for the late reply. I was sick and not at my desk for a couple of days. I did a make install clean in python31 and then ran pkgdb -F to resolve the dependencies. Went back to the editors/openoffice.org-3 port and did a make install clean and got the error again.


----------



## fronclynne (Dec 19, 2009)

weziw said:
			
		

> Hey guys, thanks for the replies. I read the /usr/local/lib/python2.6/site-packages/README file and this is what it says:
> 
> 
> Now how do I get to the source for site.py?


So long as you have python installed (I have 2.6 here) it should be in /usr/local/lib/python3.1/site.py.  Or I guess you could extract the source tarball and use find(1) on it.



> I am also not sure how to install the python headers as suggested. These are all the directories I have on the system:
> 
> ```
> cd /usr/ports/lang/py
> ...



Try setting PYTHON_DEFAULT_VERSION= python3.1 in /etc/make.conf & then `# make clean` in editors/openoffice.org-3 & trying to build again.


----------



## achix (Dec 19, 2009)

Is the file Python.h present in your system? Find this by doing 
`# locate Python.h`
in one of my systems /usr/local/include/python2.6/Python.h is indeed owned by python26-2.6.4 .
Your problem is that devel/gobject-introspection is looking to test if Python2.6 headers are there, by trying to compile a program which starts like


```
#include <Python.h>
```

Maybe reinstalling Python26 would install the include headers correctly as well, thus solving your problem.


----------



## nickolas (Dec 21, 2009)

It's bug in gobject-introspection port - it can't work with python pth option enabled.

I've just found workaround:


```
pkg_deinstall -r pth
cd /usr/ports/lang/python26
make config

//Disable pth in python build options

cd /usr/ports/editors/openoffice.org-3
make clean
make install clean
```


Please, send somebody a PR


----------



## vigol (Dec 22, 2009)

I had same problem with apache22 & python26 & python31.
I've installed in this order and compiling goes wrong:
py31 -> apache22 -> py26
but the following order works fun:
py26 -> apache22 -> p31


----------

