notmuch-new: use talloc_asprintf instead of asprintf

asprintf itself is not available on Solaris 10 FCS
lib/database.cc: fix declaration and definition discrepancy (Solaris Studio support)

lib/notmuch.h defines all the function in extern "C" { ... } block,
while lib/database.cc does not. This causes problems during linking
because notmuch_database_upgrade is exported in "C" linkage while
notmuch-new.o expects it in "C++" linkage
lib/gen-version-script.sh: standard compliance
lib/Makefile.local: solaris linker has -z defs
lib/gen-version-script.sh: Do not list "FILE" type symbols

Solaris binaries may contain symbols like those:

[1]     |         0|       0|FILE |LOCL |0    |ABS    |getdelim.c

gen-version-script.sh included them into notmuch.sym and the symbols
were then missing during linking.
lib/Makefile.local: missing object files during libnotmuch.a construction

The missing symbols were _internal_error and parse_time_string
lib/Makefile.local: Building static and dynamic library broken

Symlink creation
Makefile.local: Use compat helpers when linking notmuch client
lib/Makefile.local: solaris linker fixes
configure: add /usr/ucb/install as an alternative to install and ginstall
lib/Makefile.local: Use util modules when building static library