summaryrefslogtreecommitdiff
path: root/libexpat/libexpat
diff options
context:
space:
mode:
authorKaren Arutyunov <karen@codesynthesis.com>2020-07-29 23:11:56 +0300
committerKaren Arutyunov <karen@codesynthesis.com>2020-07-31 13:28:47 +0300
commitd7ed5335b90175300349669fd102c4d44b05c381 (patch)
tree700e84d023d25c82dd75931eae2b1a1312e96947 /libexpat/libexpat
parent2a98ae9d1b795b398d53996e35ae50b63aba3774 (diff)
Add implementation
Diffstat (limited to 'libexpat/libexpat')
l---------libexpat/libexpat/ascii.h1
l---------libexpat/libexpat/asciitab.h1
-rw-r--r--libexpat/libexpat/buildfile79
l---------libexpat/libexpat/expat.h1
-rw-r--r--libexpat/libexpat/expat_config.h88
l---------libexpat/libexpat/expat_config.h.cmake.orig1
l---------libexpat/libexpat/expat_external.h1
l---------libexpat/libexpat/iasciitab.h1
l---------libexpat/libexpat/internal.h1
l---------libexpat/libexpat/latin1tab.h1
l---------libexpat/libexpat/libexpat.def1
l---------libexpat/libexpat/nametab.h1
l---------libexpat/libexpat/siphash.h1
l---------libexpat/libexpat/utf8tab.h1
l---------libexpat/libexpat/winconfig.h1
l---------libexpat/libexpat/xmlparse.c1
l---------libexpat/libexpat/xmlrole.c1
l---------libexpat/libexpat/xmlrole.h1
l---------libexpat/libexpat/xmltok.c1
l---------libexpat/libexpat/xmltok.h1
l---------libexpat/libexpat/xmltok_impl.c1
l---------libexpat/libexpat/xmltok_impl.h1
l---------libexpat/libexpat/xmltok_ns.c1
23 files changed, 188 insertions, 0 deletions
diff --git a/libexpat/libexpat/ascii.h b/libexpat/libexpat/ascii.h
new file mode 120000
index 0000000..ad11588
--- /dev/null
+++ b/libexpat/libexpat/ascii.h
@@ -0,0 +1 @@
+../../upstream/expat/lib/ascii.h \ No newline at end of file
diff --git a/libexpat/libexpat/asciitab.h b/libexpat/libexpat/asciitab.h
new file mode 120000
index 0000000..1336131
--- /dev/null
+++ b/libexpat/libexpat/asciitab.h
@@ -0,0 +1 @@
+../../upstream/expat/lib/asciitab.h \ No newline at end of file
diff --git a/libexpat/libexpat/buildfile b/libexpat/libexpat/buildfile
new file mode 100644
index 0000000..ef06a2e
--- /dev/null
+++ b/libexpat/libexpat/buildfile
@@ -0,0 +1,79 @@
+# file : libexpat/buildfile
+# license : MIT; see accompanying COPYING file
+
+# xmltok_{impl,nc}.c files are included into xmltok.c, so exclude them from
+# the compilation.
+#
+lib{expat}: h{*} c{* -xmltok_impl -xmltok_ns}
+lib{expat}: c{xmltok_impl xmltok_ns}: include = false
+
+tclass = $c.target.class
+
+msvc_runtime = ($c.target.system == 'win32-msvc')
+
+# Symbol exporting for MSVC and Clang targeting MSVC is done via the .def
+# file.
+#
+# Note that for MinGW it's done the same way as for POSIX via the visibility
+# function attribute.
+#
+libs{expat}: def{libexpat}: include = $msvc_runtime
+
+# Build options.
+#
+c.poptions += -DHAVE_EXPAT_CONFIG_H
+
+if! $msvc_runtime
+ c.poptions += -DXML_ENABLE_VISIBILITY=1
+
+c.poptions =+ "-I$src_base"
+
+if ($c.class == 'gcc')
+{
+ c.coptions += -fexceptions -fno-strict-aliasing
+
+ if! $msvc_runtime
+ c.coptions += -fvisibility=hidden
+
+ # Disable warnings that pop up with -Wall -Wextra.
+ #
+ # Note that -Wno-implicit-fallthrough is only supported starting from GCC 7
+ # and Clang 3.9. However, we don't check for the compiler version since the
+ # earlier compiler versions do not complain about unknown -Wno-* options,
+ # unless some other diagnostics is issued.
+ #
+ # Also note that these warnings can be build2-specific due to the
+ # intermediate translation unit pre-processing phase, which wipes the `fall
+ # through` comments from the macro definitions.
+ #
+ c.coptions += -Wno-implicit-fallthrough
+}
+
+switch $tclass
+{
+ case 'linux' | 'bsd'
+ {
+ # Make sure all symbols are resolvable.
+ #
+ c.loptions += -Wl,--no-undefined
+ }
+}
+
+# Export options.
+#
+lib{expat}: cc.export.poptions = "-I$src_base"
+liba{expat}: cc.export.poptions += -DXML_STATIC
+
+# See bootstrap.build for details.
+#
+if $version.pre_release
+ lib{expat}: bin.lib.version = @"-$version.project_id"
+else
+ lib{expat}: bin.lib.version = @"-$abi_version_major" linux@"$abi_version"
+
+# Install the bare minimum of headers (note: not recreating subdirectories).
+#
+h{*}: install = false
+
+for h: expat expat_external expat_config
+ h{$h}@./: install = include/
diff --git a/libexpat/libexpat/expat.h b/libexpat/libexpat/expat.h
new file mode 120000
index 0000000..d130deb
--- /dev/null
+++ b/libexpat/libexpat/expat.h
@@ -0,0 +1 @@
+../../upstream/expat/lib/expat.h \ No newline at end of file
diff --git a/libexpat/libexpat/expat_config.h b/libexpat/libexpat/expat_config.h
new file mode 100644
index 0000000..38ae39b
--- /dev/null
+++ b/libexpat/libexpat/expat_config.h
@@ -0,0 +1,88 @@
+/* file : libexpat/expat_config.h -*- C -*-
+ * license : MIT; see accompanying COPYING file
+ */
+
+#ifndef LIBEXPAT_EXPAT_CONFIG_H
+#define LIBEXPAT_EXPAT_CONFIG_H
+
+/* Note that on Windows the library source files include winconfig.h that
+ * includes this header, additionally adding the Windows-specific definitions.
+ */
+
+/* Endianess.
+ */
+#ifdef __FreeBSD__
+# include <sys/endian.h> /* BYTE_ORDER */
+#else
+# if defined(_WIN32)
+# ifndef BYTE_ORDER
+# define BIG_ENDIAN 4321
+# define LITTLE_ENDIAN 1234
+# define BYTE_ORDER LITTLE_ENDIAN
+# endif
+# else
+# include <sys/param.h> /* BYTE_ORDER/__BYTE_ORDER */
+# ifndef BYTE_ORDER
+# ifdef __BYTE_ORDER
+# define BYTE_ORDER __BYTE_ORDER
+# define BIG_ENDIAN __BIG_ENDIAN
+# define LITTLE_ENDIAN __LITTLE_ENDIAN
+# else
+# error no BYTE_ORDER/__BYTE_ORDER define
+# endif
+# endif
+# endif
+#endif
+
+#if BYTE_ORDER == BIG_ENDIAN
+# define BYTEORDER 4321
+#else
+# define BYTEORDER 1234
+#endif
+
+#define UNUSED(x) (void)x;
+
+/* Specific for FreeBSD.
+ */
+#if defined(__FreeBSD__)
+
+/* Note that sys/random.h is not available for older versions of glibc. Thus,
+ * we don't define this macro on Linux.
+ */
+# define HAVE_GETRANDOM 1
+
+/* Note that the getrandom system call is not available in older Linux
+ * kernels. Thus, we don't define this macro on Linux.
+ */
+# define HAVE_SYSCALL_GETRANDOM 1
+#endif
+
+/* Specific for FreeBSD and Mac OS.
+ */
+#if defined(__FreeBSD__) || defined(__APPLE__)
+# define HAVE_ARC4RANDOM_BUF 1
+#endif
+
+/* Specific for (non-) VC.
+ */
+#ifndef _MSC_VER
+# define XML_DEV_URANDOM 1
+#endif
+
+/* Common for all supported OSes/compilers.
+ */
+#define XML_NS 1
+#define XML_DTD 1
+#define XML_CONTEXT_BYTES 1024
+
+#undef XML_ATTR_INFO
+#undef HAVE_LIBBSD
+#undef HAVE_ARC4RANDOM
+
+/* We can probably assume that on platforms we build for, these keywords/types
+ * don't require definition.
+
+#undef size_t
+*/
+
+#endif /* LIBEXPAT_EXPAT_CONFIG_H */
diff --git a/libexpat/libexpat/expat_config.h.cmake.orig b/libexpat/libexpat/expat_config.h.cmake.orig
new file mode 120000
index 0000000..64776b5
--- /dev/null
+++ b/libexpat/libexpat/expat_config.h.cmake.orig
@@ -0,0 +1 @@
+../../upstream/expat/expat_config.h.cmake \ No newline at end of file
diff --git a/libexpat/libexpat/expat_external.h b/libexpat/libexpat/expat_external.h
new file mode 120000
index 0000000..04ec915
--- /dev/null
+++ b/libexpat/libexpat/expat_external.h
@@ -0,0 +1 @@
+../../upstream/expat/lib/expat_external.h \ No newline at end of file
diff --git a/libexpat/libexpat/iasciitab.h b/libexpat/libexpat/iasciitab.h
new file mode 120000
index 0000000..0c6ca4a
--- /dev/null
+++ b/libexpat/libexpat/iasciitab.h
@@ -0,0 +1 @@
+../../upstream/expat/lib/iasciitab.h \ No newline at end of file
diff --git a/libexpat/libexpat/internal.h b/libexpat/libexpat/internal.h
new file mode 120000
index 0000000..f24b340
--- /dev/null
+++ b/libexpat/libexpat/internal.h
@@ -0,0 +1 @@
+../../upstream/expat/lib/internal.h \ No newline at end of file
diff --git a/libexpat/libexpat/latin1tab.h b/libexpat/libexpat/latin1tab.h
new file mode 120000
index 0000000..380f82f
--- /dev/null
+++ b/libexpat/libexpat/latin1tab.h
@@ -0,0 +1 @@
+../../upstream/expat/lib/latin1tab.h \ No newline at end of file
diff --git a/libexpat/libexpat/libexpat.def b/libexpat/libexpat/libexpat.def
new file mode 120000
index 0000000..7f3cd3c
--- /dev/null
+++ b/libexpat/libexpat/libexpat.def
@@ -0,0 +1 @@
+../../upstream/expat/lib/libexpat.def \ No newline at end of file
diff --git a/libexpat/libexpat/nametab.h b/libexpat/libexpat/nametab.h
new file mode 120000
index 0000000..da05055
--- /dev/null
+++ b/libexpat/libexpat/nametab.h
@@ -0,0 +1 @@
+../../upstream/expat/lib/nametab.h \ No newline at end of file
diff --git a/libexpat/libexpat/siphash.h b/libexpat/libexpat/siphash.h
new file mode 120000
index 0000000..641ae09
--- /dev/null
+++ b/libexpat/libexpat/siphash.h
@@ -0,0 +1 @@
+../../upstream/expat/lib/siphash.h \ No newline at end of file
diff --git a/libexpat/libexpat/utf8tab.h b/libexpat/libexpat/utf8tab.h
new file mode 120000
index 0000000..ea15fd9
--- /dev/null
+++ b/libexpat/libexpat/utf8tab.h
@@ -0,0 +1 @@
+../../upstream/expat/lib/utf8tab.h \ No newline at end of file
diff --git a/libexpat/libexpat/winconfig.h b/libexpat/libexpat/winconfig.h
new file mode 120000
index 0000000..b043f6b
--- /dev/null
+++ b/libexpat/libexpat/winconfig.h
@@ -0,0 +1 @@
+../../upstream/expat/lib/winconfig.h \ No newline at end of file
diff --git a/libexpat/libexpat/xmlparse.c b/libexpat/libexpat/xmlparse.c
new file mode 120000
index 0000000..2e8e67f
--- /dev/null
+++ b/libexpat/libexpat/xmlparse.c
@@ -0,0 +1 @@
+../../upstream/expat/lib/xmlparse.c \ No newline at end of file
diff --git a/libexpat/libexpat/xmlrole.c b/libexpat/libexpat/xmlrole.c
new file mode 120000
index 0000000..1842f74
--- /dev/null
+++ b/libexpat/libexpat/xmlrole.c
@@ -0,0 +1 @@
+../../upstream/expat/lib/xmlrole.c \ No newline at end of file
diff --git a/libexpat/libexpat/xmlrole.h b/libexpat/libexpat/xmlrole.h
new file mode 120000
index 0000000..d6840a4
--- /dev/null
+++ b/libexpat/libexpat/xmlrole.h
@@ -0,0 +1 @@
+../../upstream/expat/lib/xmlrole.h \ No newline at end of file
diff --git a/libexpat/libexpat/xmltok.c b/libexpat/libexpat/xmltok.c
new file mode 120000
index 0000000..71e09c6
--- /dev/null
+++ b/libexpat/libexpat/xmltok.c
@@ -0,0 +1 @@
+../../upstream/expat/lib/xmltok.c \ No newline at end of file
diff --git a/libexpat/libexpat/xmltok.h b/libexpat/libexpat/xmltok.h
new file mode 120000
index 0000000..7d364ab
--- /dev/null
+++ b/libexpat/libexpat/xmltok.h
@@ -0,0 +1 @@
+../../upstream/expat/lib/xmltok.h \ No newline at end of file
diff --git a/libexpat/libexpat/xmltok_impl.c b/libexpat/libexpat/xmltok_impl.c
new file mode 120000
index 0000000..d43e690
--- /dev/null
+++ b/libexpat/libexpat/xmltok_impl.c
@@ -0,0 +1 @@
+../../upstream/expat/lib/xmltok_impl.c \ No newline at end of file
diff --git a/libexpat/libexpat/xmltok_impl.h b/libexpat/libexpat/xmltok_impl.h
new file mode 120000
index 0000000..62df0da
--- /dev/null
+++ b/libexpat/libexpat/xmltok_impl.h
@@ -0,0 +1 @@
+../../upstream/expat/lib/xmltok_impl.h \ No newline at end of file
diff --git a/libexpat/libexpat/xmltok_ns.c b/libexpat/libexpat/xmltok_ns.c
new file mode 120000
index 0000000..607cbbc
--- /dev/null
+++ b/libexpat/libexpat/xmltok_ns.c
@@ -0,0 +1 @@
+../../upstream/expat/lib/xmltok_ns.c \ No newline at end of file