# Installing devel/glade3 from ports fails



## Navigium (Apr 21, 2011)

I tried to install glade3 from the port. There seems to be some problem with Python versions. I get the following error:


```
[...]
  `which xml2po` -m docbook -e -t "${mo}" \
    "${d}C/glade.xml" > glade.xml.tmp && \
    cp glade.xml.tmp glade.xml && rm -f glade.xml.tmp)
Traceback (most recent call last):
  File "/usr/local/bin/xml2po", line 191, in <module>
    main(sys.argv[1:])
  File "/usr/local/bin/xml2po", line 88, in main
    from xml2po import Main
  File "/usr/local/lib/python2.6/site-packages/xml2po/__init__.py", line 27, in <module>
    import libxml2
ImportError: No module named libxml2
gmake[2]: *** [bg/glade.xml] Error 1
gmake[2]: Leaving directory `/usr/ports/devel/glade3/work/glade3-3.7.3/help'
gmake[1]: *** [all-recursive] Error 1
gmake[1]: Leaving directory `/usr/ports/devel/glade3/work/glade3-3.7.3'
gmake: *** [all] Error 2
*** Error code 1
```

Somehow building this port seems to depend on python 2.6 - but the default version on my quite fresh FreeBSD install seems to be another one.


```
$ python -V
Python 2.7.1
```

Also the port 
ports/textproc/py-libxml2
seems to install the version for python 2.7. I tried to import the libxml2 in python2.6 which didn't work


```
Python 2.6.6 (r266:84292, Apr 21 2011, 12:51:54) 
[GCC 4.2.1 20070719  [FreeBSD]] on freebsd8
Type "help", "copyright", "credits" or "license" for more information.
>>> import libxml2
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
ImportError: No module named libxml2
```

Removing Python 2.6 doesn't solve the issue, it just gives another error


```
`which xml2po` -m docbook -e -t "${mo}" \
    "${d}C/glade.xml" > glade.xml.tmp && \
    cp glade.xml.tmp glade.xml && rm -f glade.xml.tmp)
/usr/local/bin/xml2po: not found
gmake[2]: *** [bg/glade.xml] Error 127
```

the first line of 

/usr/local/bin/xml2po

suggests that it depends on python 2.6


```
#!/usr/local/bin/python2.6
```

Probably the only solution would be to install a version of py-libxml2 that works with python2.6 - but how do I achieve that?


----------



## Navigium (Apr 21, 2011)

Solved the problem finally: The solution is the same as mentioned in 

http://forums.freebsd.org/showthread.php?t=5319

You have to reinstall textproc/gnome-doc-utils with
`# make deinstall`
followed by
`# make reinstall`


----------

