summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorjhurst <jhurst@cinecert.com>2020-10-08 09:08:43 -0700
committerjhurst <jhurst@cinecert.com>2020-10-08 09:08:43 -0700
commit25416a414301ddf79f499373c279740a519a27b1 (patch)
treefaa123848a303a038d48ea3027414520e7998a68 /src
parent174a1e30ef431989b0b9b0812bc38c79db8331a4 (diff)
fixed conditional XML parser support
Diffstat (limited to 'src')
-rw-r--r--src/Makefile.am11
-rwxr-xr-xsrc/as-02-wrap.cpp15
-rwxr-xr-xsrc/asdcp-test.cpp4
-rwxr-xr-xsrc/asdcp-wrap.cpp7
4 files changed, 3 insertions, 34 deletions
diff --git a/src/Makefile.am b/src/Makefile.am
index 65ab3e0..dc1cf86 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -54,12 +54,9 @@ include_HEADERS = \
KM_aes.h \
KM_util.h \
KM_tai.h \
+ KM_xml.h \
AS_DCP.h
-if HAVE_XERCESC
-#include_HEADERS += KM_xml.h
-endif
-
if DEV_HEADERS
include_HEADERS += \
S12MTimecode.h \
@@ -107,13 +104,9 @@ endif
# sources for kumu library
libkumu_la_SOURCES = KM_error.h KM_fileio.cpp KM_fileio.h KM_log.cpp KM_log.h \
KM_memio.h KM_mutex.h KM_platform.h KM_prng.cpp KM_prng.h KM_util.cpp \
- KM_util.h KM_tai.h KM_tai.cpp \
+ KM_util.h KM_tai.h KM_tai.cpp KM_xml.cpp KM_xml.h \
KM_sha1.cpp KM_sha1.h KM_aes.h KM_aes.cpp
-if HAVE_XERCESC
-#libkumu_la_SOURCES += KM_xml.cpp KM_xml.h
-endif
-
# linker flags (*not* including libraries to link against) for a library
libkumu_la_LDFLAGS = -release @VERSION@
diff --git a/src/as-02-wrap.cpp b/src/as-02-wrap.cpp
index f512084..ded694d 100755
--- a/src/as-02-wrap.cpp
+++ b/src/as-02-wrap.cpp
@@ -35,17 +35,13 @@ THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
For more information about AS-02, please refer to the header file AS_02.h
For more information about asdcplib, please refer to the header file AS_DCP.h
*/
-
#include <KM_fileio.h>
+#include <KM_xml.h>
#include <AS_02.h>
#include "AS_02_ACES.h"
#include <PCMParserList.h>
#include <Metadata.h>
-#ifdef HAVE_XERCES_C
-#include <KM_xml.h>
-#endif
-
using namespace ASDCP;
const ui32_t FRAME_BUFFER_SIZE = 4 * Kumu::Megabyte;
@@ -1595,8 +1591,6 @@ write_PCM_file(CommandOptions& Options)
}
-
-#ifdef HAVE_XERCES_C
//------------------------------------------------------------------------------------------
// TimedText essence
@@ -1726,7 +1720,6 @@ write_timed_text_file(CommandOptions& Options)
return result;
}
-#endif // HAVE_XERCES_C
//
bool
@@ -1817,7 +1810,6 @@ write_isxd_file(CommandOptions& Options)
if ( ASDCP_SUCCESS(result) )
{
-#ifdef HAVE_XERCES_C
if ( Options.isxd_document_namespace == "auto" )
{
// get ns of first item
@@ -1841,7 +1833,6 @@ write_isxd_file(CommandOptions& Options)
return RESULT_FAIL;
}
}
-#endif
result = Writer.OpenWrite(Options.out_file, Info, Options.isxd_document_namespace, Options.edit_rate);
}
@@ -1913,12 +1904,10 @@ write_isxd_file(CommandOptions& Options)
return RESULT_READFAIL;
global_metadata.Size(read_count);
-#ifdef HAVE_XERCES_C
std::string ns_prefix, type_name;
Kumu::AttributeList doc_attr_list;
result = GetXMLDocType(global_metadata.RoData(), global_metadata.Size(), ns_prefix, type_name,
namespace_name, doc_attr_list) ? RESULT_OK : RESULT_FAIL;
-#endif
}
if ( KM_SUCCESS(result) )
@@ -2001,11 +1990,9 @@ main(int argc, const char** argv)
result = write_PCM_file(Options);
break;
-#ifdef HAVE_XERCES_C
case ESS_TIMED_TEXT:
result = write_timed_text_file(Options);
break;
-#endif //HAVE_XERCES_C
case ESS_DCDATA_UNKNOWN:
if ( ! Options.isxd_document_namespace.empty() )
diff --git a/src/asdcp-test.cpp b/src/asdcp-test.cpp
index 29f8c6e..ecf6f21 100755
--- a/src/asdcp-test.cpp
+++ b/src/asdcp-test.cpp
@@ -1478,7 +1478,6 @@ read_PCM_file(CommandOptions& Options)
}
-#ifdef HAVE_XERCES_C
//------------------------------------------------------------------------------------------
// TimedText essence
@@ -1601,7 +1600,6 @@ write_timed_text_file(CommandOptions& Options)
return result;
}
-#endif //HAVE_XERCES_C
// Read one or more timed text streams from a plaintext ASDCP file
@@ -2079,11 +2077,9 @@ main(int argc, const char** argv)
result = write_PCM_file(Options);
break;
-#ifdef HAVE_XERCES_C
case ESS_TIMED_TEXT:
result = write_timed_text_file(Options);
break;
-#endif //HAVE_XERCES_C
default:
fprintf(stderr, "%s: Unknown file type, not ASDCP-compatible essence.\n",
diff --git a/src/asdcp-wrap.cpp b/src/asdcp-wrap.cpp
index 362ff3b..2028f53 100755
--- a/src/asdcp-wrap.cpp
+++ b/src/asdcp-wrap.cpp
@@ -1306,9 +1306,6 @@ write_PCM_with_ATMOS_sync_file(CommandOptions& Options)
return result;
}
-
-#ifdef HAVE_XERCES_C
-
//------------------------------------------------------------------------------------------
// TimedText essence
@@ -1434,8 +1431,6 @@ write_timed_text_file(CommandOptions& Options)
return result;
}
-#endif //HAVE_XERCES_C
-
// Write one or more plaintext Dolby ATMOS bytestreams to a plaintext ASDCP file
// Write one or more plaintext Dolby ATMOS bytestreams to a ciphertext ASDCP file
//
@@ -1746,11 +1741,9 @@ main(int argc, const char** argv)
}
break;
-#ifdef HAVE_XERCES_C
case ESS_TIMED_TEXT:
result = write_timed_text_file(Options);
break;
-#endif //HAVE_XERCES_C
case ESS_DCDATA_DOLBY_ATMOS:
result = write_dolby_atmos_file(Options);