fdo#52076 remove empty library instead of writing it out empty

Change-Id: Id4fd8c4f34e8ed07044eb428049731c4b9b694ca
Reviewed-on: https://gerrit.libreoffice.org/10508
Reviewed-by: Michael Stahl <mstahl@redhat.com>
Tested-by: Michael Stahl <mstahl@redhat.com>