Do not export executable targets if the list is empty

Since the command "EXPORT(TARGETS ..." is invoked two times in a row, in
case no application are exported, when included, the associated
'DCMTKTargets.cmake' file will never allow import the associated library
target because if exit because the code protecting against multiple
inclusion will always exit.
Add option to enable DCMTK application and build as shared library

If application are built using Emscripten:
 * they will be built as shared library.
 * main function is renamed into "<appname>_main"
 * a header named "<appname>_app.h" is configured to export
the <appname>_main symbol
Change xml2dcm main signature to fix compilation when libxml is not found.