# Problem with libbsdyml



## robbtek (May 17, 2013)

```
freebsd9-64bit# portversion -l '<'
[Updating the pkgdb <format:bdb_btree> in /var/db/pkg ... USING PKGNG
Shared object "libbsdyml.so.0" not found, required by "libpkg.so.0"
```


```
freebsd9-64bit#  pkg check -da
Shared object "libbsdyml.so.0" not found, required by "libpkg.so.0"
```


```
freebsd9-64bit# locate libbsdyml
(no result)
```

How can I solve it?

Thanks


----------



## SirDice (May 17, 2013)

Are you sure libbsd*y*ml is correct?


```
root@molly:/usr/src# ll /usr/lib/libbsdxml*
-r--r--r--  1 root  wheel  255376 Apr 15 17:11 /usr/lib/libbsdxml.a
lrwxr-xr-x  1 root  wheel      19 Apr 15 17:11 /usr/lib/libbsdxml.so -> /lib/libbsdxml.so.4
-r--r--r--  1 root  wheel  266640 Apr 15 17:11 /usr/lib/libbsdxml_p.a
```

Because I have a libbsd*x*ml.


```
root@molly:/usr/src# ldd /usr/local/sbin/pkg
/usr/local/sbin/pkg:
        libpkg.so.0 => /usr/local/lib/libpkg.so.0 (0x800830000)
        libarchive.so.5 => /usr/lib/libarchive.so.5 (0x800b07000)
        libutil.so.9 => /lib/libutil.so.9 (0x800d48000)
        libthr.so.3 => /lib/libthr.so.3 (0x800f5b000)
        libsbuf.so.6 => /lib/libsbuf.so.6 (0x80117e000)
        libfetch.so.6 => /usr/lib/libfetch.so.6 (0x801380000)
        libssl.so.6 => /usr/lib/libssl.so.6 (0x801590000)
        libcrypto.so.6 => /lib/libcrypto.so.6 (0x8017e6000)
        libmd.so.5 => /lib/libmd.so.5 (0x801b8e000)
        libz.so.6 => /lib/libz.so.6 (0x801d9e000)
        libbz2.so.4 => /usr/lib/libbz2.so.4 (0x801fb2000)
        liblzma.so.5 => /usr/lib/liblzma.so.5 (0x8021c2000)
        libjail.so.1 => /lib/libjail.so.1 (0x8023e5000)
        libc.so.7 => /lib/libc.so.7 (0x8025ea000)
        libelf.so.1 => /usr/lib/libelf.so.1 (0x802944000)
        libedit.so.7 => /lib/libedit.so.7 (0x802b5d000)
        [b]libbsdxml.so.4 => /lib/libbsdxml.so.4 (0x802d85000)[/b]
        libncurses.so.8 => /lib/libncurses.so.8 (0x802fa9000)
```


----------



## robbtek (May 17, 2013)

```
freebsd9-64bit# ll /usr/lib/libbsdxml*
-r--r--r--  1 root  wheel  223756 Dec  6 16:02 /usr/lib/libbsdxml.a
lrwxr-xr-x  1 root  wheel      19 Dec  6 16:02 /usr/lib/libbsdxml.so -> /lib/libbsdxml.so.4
-r--r--r--  1 root  wheel  253028 Dec  6 16:02 /usr/lib/libbsdxml_p.a
```

Where is the problem ?


----------



## SirDice (May 17, 2013)

What does `ldd /usr/local/sbin/pkg` show?


----------



## robbtek (May 17, 2013)

```
freebsd9-64bit# ldd /usr/local/sbin/pkg
/usr/local/sbin/pkg:
        libpkg.so.0 => /usr/local/lib/libpkg.so.0 (0x800830000)
        libarchive.so.6 => /usr/lib/libarchive.so.6 (0x800b11000)
        libutil.so.9 => /lib/libutil.so.9 (0x800d9d000)
        libthr.so.3 => /lib/libthr.so.3 (0x800faf000)
        libsbuf.so.6 => /lib/libsbuf.so.6 (0x8011d4000)
        libfetch.so.6 => /usr/lib/libfetch.so.6 (0x8013d6000)
        libssl.so.7 => /usr/lib/libssl.so.7 (0x8015e6000)
        libcrypto.so.7 => /lib/libcrypto.so.7 (0x80184d000)
        libmd.so.6 => /lib/libmd.so.6 (0x801c2e000)
        libz.so.6 => /lib/libz.so.6 (0x801e3d000)
        libbz2.so.4 => /usr/lib/libbz2.so.4 (0x802052000)
        liblzma.so.5 => /usr/lib/liblzma.so.5 (0x802263000)
        libjail.so.1 => /lib/libjail.so.1 (0x802486000)
        libc.so.7 => /lib/libc.so.7 (0x80268b000)
        libbsdyml.so.0 => not found (0)
        libelf.so.1 => /usr/lib/libelf.so.1 (0x8029f6000)
        libedit.so.7 => /lib/libedit.so.7 (0x802c0b000)
        libbsdxml.so.4 => /lib/libbsdxml.so.4 (0x802e35000)
        libncurses.so.8 => /lib/libncurses.so.8 (0x803059000)
```

*T*hanks.


----------



## kpa (May 17, 2013)

There's no libbsdyml.so on 9.1-RELEASE, it must have been added to 9-STABLE recently. Recompile ports-mgmt/pkg to get proper dependencies.


----------



## SirDice (May 17, 2013)

There's no mention of libbsdyml so I'm wondering where that comes from :\


----------



## SirDice (May 17, 2013)

Did you perhaps muck about with libmap.conf(5)?


----------



## kpa (May 17, 2013)

I believe it was linked statically to pkg previously but was then imported to 9-STABLE as a shared library.


----------



## SirDice (May 17, 2013)

There is no libbsdyml on 9-STABLE. At least not on any of mine. There is a libbsdxml though.


----------



## robbtek (May 17, 2013)

kpa said:
			
		

> There's no libbsdyml.so on 9.1-RELEASE, it must have been added to 9-STABLE recently. Recompile ports-mgmt/pkg to get proper dependencies.




```
freebsd9-64bit# cd /usr/ports/ports-mgmt/pkg
freebsd9-64bit# make deinstall && make clean && make install
Shared object "libbsdyml.so.0" not found, required by "libpkg.so.0"
===>  Deinstalling for ports-mgmt/pkg
Shared object "libbsdyml.so.0" not found, required by "libpkg.so.0"
===>   pkg not installed, skipping
Shared object "libbsdyml.so.0" not found, required by "libpkg.so.0"
Shared object "libbsdyml.so.0" not found, required by "libpkg.so.0"
===>  Cleaning for pkg-1.0.12_1
Shared object "libbsdyml.so.0" not found, required by "libpkg.so.0"
Shared object "libbsdyml.so.0" not found, required by "libpkg.so.0"
You are about to convert your system to pkgng while you have ports/packages
installed with the old pkg_install tools.

You can choose to: 
- keep pkg_install as the package management system by adding this line to /etc/make.conf:

    WITHOUT_PKGNG=yes

- switch to pkgng:
    1) Add WITHOUT_PKGNG to /etc/make.conf
    2) Install ports-mgmt/pkg
    3) Convert your package database by running pkg2ng
    4) Remove WITHOUT_PKGNG from /etc/make.conf

*** [pre-everything] Error code 1

Stop in /usr/ports/ports-mgmt/pkg.
```


----------



## kpa (May 17, 2013)

Post the output of `uname -a`. What does the version number read in /usr/ports/ports-mgmt/pkg/Makefile?


----------



## robbtek (May 18, 2013)

I've solved the previous problem, but now the problem is:


```
===>   Compressing manual pages for perl-5.16.2_1
===>   Registering installation for perl-5.16.2_1
Installing perl-5.16.2_1...pkg: perl-5.16.2_1 conflicts with perl-5.16.2_1 (installs files into the same place).  Problematic file: /usr/local/share/licenses/perl-5.16.2_1/catalog.mk
*** [fake-pkg] Error code 70

Stop in /usr/ports/lang/perl5.16.

===>>> Installation of perl-5.16.2_1 (lang/perl5.16) failed
===>>> Aborting update

===>>> Update for lang/perl5.16 failed
===>>> Aborting update

Terminated
```


----------



## robbtek (May 27, 2013)

I think it's solved, and I open a new post for Perl and PKGNG problem.

Thanks all.


----------

