# Conflict between libiodbc and unixODBC while updating ports



## jtl (Jan 18, 2011)

I'm trying to update all my ports with portmaster(8) per the instructions at the bottom of the portmaster(8) man page, and I've run into a problem I don't know how to resolve.  Portmaster stopped with this error:

```
===>  libiodbc-3.52.7 conflicts with installed package(s): 
      unixODBC-2.3.0_1

      They will not build together.
      Please remove them first with pkg_delete(1).
*** Error code 1

Stop in /usr/ports/databases/libiodbc.
*** Error code 1

Stop in /usr/ports/textproc/soprano.
*** Error code 1

Stop in /usr/ports/textproc/soprano.

===>>> make failed for textproc/soprano
===>>> Aborting update

===>>> Update for textproc/soprano failed
===>>> Aborting update

===>>> Update for x11/kdebase4 failed
===>>> Aborting update

Terminated
```
There is a note regarding unixODBC in /usr/ports/UPDATING but it refers to an older version (2.2.14) and doesn't suggest anything related to this issue. There is no note regarding libiodbc.  I did find an entry on kdebase the recommends the following:
`# pkg_delete -f kdehier4\* kdelibs-4\* kdebase-4\* kdebase-runtime-4\* kdebase-workspace-4\*`
`# rm -rf /usr/local/kde4/share/PolicyKit/policy`
`# cd /usr/ports/misc/kdehier4 && make install clean`
`# portmaster -a`
I suspect this is what I need to do, but having been warned about the dangers of running `# portmaster -a`, I'm looking for some reassurance that this is correct, or some better direction about how to resolve this issue.  I'm also concerned about rebuilding all my ports again when I'm not yet done with my current attempt to rebuild all the ports (no small investment of time).  Is there a way to rebuild only those ports that depend on kde4, assuming that's what I need to do?  Thanks for any help.


----------



## SirDice (Jan 18, 2011)

There is a very old entry in /usr/ports/UPDATING:


> 2006-10-09
> 
> Affects: users of ports using ODBC (databases/libiodbc or databases/unixODBC)
> 
> ...



They both have a CONFLICT line in their Makefile:
libiodbc:

```
CONFLICTS=	unixODBC-[0-9]*
```
unixODBC:

```
CONFLICTS=	libiodbc-[0-9]* virtuoso-*
```

This basically means you'll need to choose one and remove the other.


----------



## sk8harddiefast (Jan 18, 2011)

```
cd /usr/ports/databases/unixODBC
make deinstall clean
Portsclean --CDD
Portmaster -a
```

[cmd=]portsclean -CDD[/cmd] cleans all ports and useless distfiles. Is part of ports-mgmt/portupgrade so you must install first ports-mgmt/portupgrade to run [cmd=]portsclean[/cmd]


```
cd /usr/ports/ports-mgmt/portupgrade
make install clean
```


----------



## jtl (Jan 18, 2011)

For some reason there's nothing in my /usr/ports/UPDATING file that predates 2008.  In any case, I did find a thread in the forums from last month with detailed info on this issue:

kde4 installation fails, libiodbc-3.52.7 conflicts with unixODBC-2.3.0

I should have searched more carefully before posting.


----------



## dead-elk (Apr 18, 2012)

*I*'m using unixodbc too, and this helped me to *make install* erlang with odbc: 

```
#cat /etc/make.conf
WITH_UNIXODBC                   =       YES
DRIVER_MANAGER                  =       unixodbc
#
```


----------

