Update toolchain and add hive compiler
This commit is contained in:
4
build.sh
4
build.sh
@@ -31,7 +31,7 @@ CMAKEVCS="https://gitlab.kitware.com/cmake/cmake.git"
|
|||||||
|
|
||||||
# LLVM Settings
|
# LLVM Settings
|
||||||
LLVMDIR="${SRCDIR}/llvm"
|
LLVMDIR="${SRCDIR}/llvm"
|
||||||
LLVMTAG="llvmorg-23.1.2"
|
LLVMTAG="llvmorg-23.1.3"
|
||||||
LLVMVCS="https://github.com/llvm/llvm-project.git"
|
LLVMVCS="https://github.com/llvm/llvm-project.git"
|
||||||
|
|
||||||
# Mtools Settings
|
# Mtools Settings
|
||||||
@@ -408,7 +408,7 @@ xtchain_build()
|
|||||||
echo ">>> Building XTchain tools ..."
|
echo ">>> Building XTchain tools ..."
|
||||||
mkdir -p ${BINDIR}/bin
|
mkdir -p ${BINDIR}/bin
|
||||||
mkdir -p ${BINDIR}/lib/xtchain
|
mkdir -p ${BINDIR}/lib/xtchain
|
||||||
for EXEC in bin2c diskimg exetool xtadkgen xtcspecc xtnlsc; do
|
for EXEC in bin2c diskimg exetool mkxthv xtadkgen xtcspecc xtnlsc; do
|
||||||
if [ ! -e ${BINDIR}/bin/${EXEC} ]; then
|
if [ ! -e ${BINDIR}/bin/${EXEC} ]; then
|
||||||
${CCOMPILER} -I${WRKDIR}/tools/includes ${WRKDIR}/tools/${EXEC}.c -o ${BINDIR}/bin/${EXEC}
|
${CCOMPILER} -I${WRKDIR}/tools/includes ${WRKDIR}/tools/${EXEC}.c -o ${BINDIR}/bin/${EXEC}
|
||||||
fi
|
fi
|
||||||
|
|||||||
@@ -45,8 +45,13 @@
|
|||||||
#define SECTOR_SIZE 512
|
#define SECTOR_SIZE 512
|
||||||
#define _T(x) x
|
#define _T(x) x
|
||||||
|
|
||||||
|
#ifndef YAML_MAX_BINARY
|
||||||
#define YAML_MAX_BINARY (64u * 1024u * 1024u)
|
#define YAML_MAX_BINARY (64u * 1024u * 1024u)
|
||||||
|
#endif
|
||||||
#define YAML_MAX_TEXT (512u * 1024u * 1024u)
|
#define YAML_MAX_TEXT (512u * 1024u * 1024u)
|
||||||
|
#ifndef YAML_MAX_DEPTH
|
||||||
|
#define YAML_MAX_DEPTH 32
|
||||||
|
#endif
|
||||||
|
|
||||||
typedef struct MBR_PARTITION {
|
typedef struct MBR_PARTITION {
|
||||||
uint8_t BootFlag; // 0x80 = bootable, 0x00 = non-boot
|
uint8_t BootFlag; // 0x80 = bootable, 0x00 = non-boot
|
||||||
@@ -323,7 +328,7 @@ YamlAppendBuffer(YAML_BUFFER *b,
|
|||||||
{
|
{
|
||||||
if(n > YAML_MAX_BINARY || b->len > YAML_MAX_BINARY - n)
|
if(n > YAML_MAX_BINARY || b->len > YAML_MAX_BINARY - n)
|
||||||
{
|
{
|
||||||
YamlError("binary exceeds 64 MiB");
|
YamlError("binary exceeds %zu bytes", (size_t)YAML_MAX_BINARY);
|
||||||
}
|
}
|
||||||
if(b->len + n > b->cap)
|
if(b->len + n > b->cap)
|
||||||
{
|
{
|
||||||
@@ -385,7 +390,7 @@ inline
|
|||||||
uint32_t
|
uint32_t
|
||||||
ReadUInt32(const unsigned char *p)
|
ReadUInt32(const unsigned char *p)
|
||||||
{
|
{
|
||||||
return ReadUInt16(p) | (ReadUInt16(p + 2) << 16);
|
return ReadUInt16(p) | ((uint32_t)ReadUInt16(p + 2) << 16);
|
||||||
}
|
}
|
||||||
|
|
||||||
static
|
static
|
||||||
@@ -1115,9 +1120,9 @@ inline
|
|||||||
void
|
void
|
||||||
YamlParserDepthCheck(unsigned depth)
|
YamlParserDepthCheck(unsigned depth)
|
||||||
{
|
{
|
||||||
if(depth > 32)
|
if(depth > YAML_MAX_DEPTH)
|
||||||
{
|
{
|
||||||
YamlError("YAML nesting exceeds 32 levels");
|
YamlError("YAML nesting exceeds %u levels", (unsigned)YAML_MAX_DEPTH);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
2069
tools/mkxthv.c
Normal file
2069
tools/mkxthv.c
Normal file
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user