Skip to content

Commit 178c050

Browse files
committed
Enable and fix xml module with MSVC
1 parent 2976f17 commit 178c050

4 files changed

Lines changed: 9 additions & 2 deletions

File tree

CMakePresets.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@
3636
"MOD_VIDSTAB": "OFF",
3737
"MOD_VORBIS": "OFF",
3838
"MOD_XINE": "OFF",
39-
"MOD_XML": "OFF"
39+
"MOD_XML": "ON"
4040
}
4141
},
4242
{

src/modules/xml/consumer_xml.c

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,10 @@
2626
#include <stdio.h>
2727
#include <stdlib.h>
2828
#include <string.h>
29+
30+
#ifndef _MSC_VER
2931
#include <unistd.h>
32+
#endif
3033

3134
#define ID_SIZE 128
3235
#define TIME_PROPERTY "_consumer_xml"

src/modules/xml/producer_xml.c

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,10 @@
2727
#include <framework/mlt_log.h>
2828
#include <stdlib.h>
2929
#include <string.h>
30+
31+
#ifndef _MSC_VER
3032
#include <unistd.h>
33+
#endif
3134

3235
#include <libxml/parser.h>
3336
#include <libxml/parserInternals.h> // for xmlCreateFileParserCtxt

vcpkg.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@
1010
"sdl2",
1111
"ffmpeg",
1212
"qtbase",
13-
"qtsvg"
13+
"qtsvg",
14+
"libxml2"
1415
]
1516
}

0 commit comments

Comments
 (0)