Fix building of tests, and building libpkg under some cases

/usr/bin/ld: //usr/lib/libssl.so.7: invalid DSO for symbol `SSL_load_error_strings' definition

Issue:	#989
Fix pkg-search test.

The return status from pkgcli_update() needs to be improved.
Add a regression test about #1005
Revert "Fix pkg-search test."

This reverts commit c254b510a4c6a22223df320aa61eb95d5306ffbd.
Use the same mecanism for pkg register as for pkg to register a package

This allows the check the conflicts before actually start installing
anything

Fixes #1005
Do not enforce any ABI for test to pass everywhere
Avoid hitting pkgcli_update()
Properly sandbox pkg search test
Revert "Revert "Fix pkg-search test.""

This reverts commit 71e17873ab5c9eb836290d3e47d9b2bc4d001c15.

Conflicts:
	tests/frontend/search.shin
I should probably work my math

Reported by:	marino
Add a private function to retrive annotations
Add support for the annotation no_provide_shlib

This will cleanup the provided libs from the manifest (still making sure
to to require a lib provided but not exposed)
Remove invalid free and assign toFree to NULL to free only cleans it if needed

pkg_utils_tokenize does not duplicate memory

Fixes: #1007