common: Add an easy to use DER builder.
* common/tlv-builder.c: New. * common/tlv.c: Remove stuff only used by GnuPG 1. (put_tlv_to_membuf, get_tlv_length): Move to ... * common/tlv-builder.c: here. * common/tlv.h (tlv_builder_t): New.
Such code should actually go into libksba and we will eventually do
that. However, for now it is easier to keep it here.
- Signed-off-by: Werner Koch <wk@gnupg.org>