AI prompts
base on Read-only mirror of https://gitlab.gnome.org/GNOME/libxml2 # libxml2
libxml2 is an XML toolkit implemented in C, originally developed for
the GNOME Project.
Official releases can be downloaded from
<https://download.gnome.org/sources/libxml2/>
The git repository is hosted on GNOME's GitLab server:
<https://gitlab.gnome.org/GNOME/libxml2>
Bugs should be reported at
<https://gitlab.gnome.org/GNOME/libxml2/-/issues>
Documentation is available at
<https://gitlab.gnome.org/GNOME/libxml2/-/wikis>
## License
This code is released under the MIT License, see the Copyright file.
## Build instructions
libxml2 can be built with GNU Autotools, CMake, meson or several other
build systems in platform-specific subdirectories.
### Autotools (for POSIX systems like Linux, BSD, macOS)
If you build from a Git tree, you have to install Autotools and start
by generating the configuration files with:
./autogen.sh [configuration options]
If you build from a source tarball, extract the archive with:
tar xf libxml2-xxx.tar.gz
cd libxml2-xxx
Then you can configure and build the library:
./configure [configuration options]
make
The following options disable or enable code modules and relevant symbols:
--with-c14n Canonical XML 1.0 support (on)
--with-catalog XML Catalogs support (on)
--with-debug debugging module (on)
--with-history history support for xmllint shell (off)
--with-readline[=DIR] use readline in DIR for shell (off)
--with-html HTML parser (on)
--with-http HTTP support (off)
--with-iconv[=DIR] iconv support (on)
--with-icu ICU support (off)
--with-iso8859x ISO-8859-X support if no iconv (on)
--with-lzma[=DIR] use liblzma in DIR (off)
--with-modules dynamic modules support (on)
--with-output serialization support (on)
--with-pattern xmlPattern selection interface (on)
--with-push push parser interfaces (on)
--with-python Python bindings (on)
--with-reader xmlReader parsing interface (on)
--with-regexps regular expressions support (on)
--with-sax1 older SAX1 interface (on)
--with-schemas XML Schemas 1.0 and RELAX NG support (on)
--with-schematron Schematron support (on)
--with-threads multithreading support (on)
--with-thread-alloc per-thread malloc hooks (off)
--with-valid DTD validation support (on)
--with-writer xmlWriter serialization interface (on)
--with-xinclude XInclude 1.0 support (on)
--with-xpath XPath 1.0 support (on)
--with-xptr XPointer support (on)
--with-zlib[=DIR] use libz in DIR (off)
Other options:
--with-minimum build a minimally sized library (off)
--with-legacy maximum ABI compatibility (off)
Note that by default, no optimization options are used. You have to
enable them manually, for example with:
CFLAGS='-O2 -fno-semantic-interposition' ./configure
Now you can run the test suite with:
make check
Please report test failures to the bug tracker.
Then you can install the library:
make install
At that point you may have to rerun ldconfig or a similar utility to
update your list of installed shared libs.
### CMake (mainly for Windows)
Another option for compiling libxml is using CMake:
cmake -E tar xf libxml2-xxx.tar.gz
cmake -S libxml2-xxx -B libxml2-xxx-build [possible options]
cmake --build libxml2-xxx-build
cmake --install libxml2-xxx-build
Common CMake options include:
-D BUILD_SHARED_LIBS=OFF # build static libraries
-D CMAKE_BUILD_TYPE=Release # specify build type
-D CMAKE_INSTALL_PREFIX=/usr/local # specify the install path
-D LIBXML2_WITH_ICONV=OFF # disable iconv
-D LIBXML2_WITH_LZMA=OFF # disable liblzma
-D LIBXML2_WITH_PYTHON=OFF # disable Python
-D LIBXML2_WITH_ZLIB=OFF # disable libz
You can also open the libxml source directory with its CMakeLists.txt
directly in various IDEs such as CLion, QtCreator, or Visual Studio.
### Meson
Still somewhat experimental, see
[issue 743](https://gitlab.gnome.org/GNOME/libxml2/-/issues/743).
Libxml can also be built with meson. Without option, simply call
meson setup builddir
ninja -C builddir
To add options, see the meson_options.txt file. For example:
meson setup \
-Dprefix=$prefix \
-Dhistory=enabled \
-Dhttp=enabled \
-Dschematron=disabled \
-Dzlib=enabled \
builddir
To install libxml:
ninja -C builddir install
To launch tests:
meson test -C builddir
## Dependencies
libxml2 supports POSIX and Windows operating systems.
The iconv function is required for conversion of character encodings.
This function is part of POSIX.1-2001. If your platform doesn't provide
iconv, you need an external libiconv library, for example
[GNU libiconv](https://www.gnu.org/software/libiconv/). Using
[ICU](https://icu.unicode.org/) is also supported but discouraged.
If enabled, libxml uses [libz](https://zlib.net/) or
[liblzma](https://tukaani.org/xz/) to support reading compressed files.
Use of this feature is discouraged.
The xmllint executable uses libreadline and libhistory if enabled.
## Contributing
The current version of the code can be found in GNOME's GitLab at
<https://gitlab.gnome.org/GNOME/libxml2>. The best way to get involved
is by creating issues and merge requests on GitLab.
All code must conform to C89 and pass the GitLab CI tests. Add regression
tests if possible.
## Authors
- Daniel Veillard
- Bjorn Reese
- William Brack
- Igor Zlatkovic for the Windows port
- Aleksey Sanin
- Nick Wellnhofer
", Assign "at most 3 tags" to the expected json: {"id":"2128","tags":[]} "only from the tags list I provide: [{"id":77,"name":"3d"},{"id":89,"name":"agent"},{"id":17,"name":"ai"},{"id":54,"name":"algorithm"},{"id":24,"name":"api"},{"id":44,"name":"authentication"},{"id":3,"name":"aws"},{"id":27,"name":"backend"},{"id":60,"name":"benchmark"},{"id":72,"name":"best-practices"},{"id":39,"name":"bitcoin"},{"id":37,"name":"blockchain"},{"id":1,"name":"blog"},{"id":45,"name":"bundler"},{"id":58,"name":"cache"},{"id":21,"name":"chat"},{"id":49,"name":"cicd"},{"id":4,"name":"cli"},{"id":64,"name":"cloud-native"},{"id":48,"name":"cms"},{"id":61,"name":"compiler"},{"id":68,"name":"containerization"},{"id":92,"name":"crm"},{"id":34,"name":"data"},{"id":47,"name":"database"},{"id":8,"name":"declarative-gui "},{"id":9,"name":"deploy-tool"},{"id":53,"name":"desktop-app"},{"id":6,"name":"dev-exp-lib"},{"id":59,"name":"dev-tool"},{"id":13,"name":"ecommerce"},{"id":26,"name":"editor"},{"id":66,"name":"emulator"},{"id":62,"name":"filesystem"},{"id":80,"name":"finance"},{"id":15,"name":"firmware"},{"id":73,"name":"for-fun"},{"id":2,"name":"framework"},{"id":11,"name":"frontend"},{"id":22,"name":"game"},{"id":81,"name":"game-engine "},{"id":23,"name":"graphql"},{"id":84,"name":"gui"},{"id":91,"name":"http"},{"id":5,"name":"http-client"},{"id":51,"name":"iac"},{"id":30,"name":"ide"},{"id":78,"name":"iot"},{"id":40,"name":"json"},{"id":83,"name":"julian"},{"id":38,"name":"k8s"},{"id":31,"name":"language"},{"id":10,"name":"learning-resource"},{"id":33,"name":"lib"},{"id":41,"name":"linter"},{"id":28,"name":"lms"},{"id":16,"name":"logging"},{"id":76,"name":"low-code"},{"id":90,"name":"message-queue"},{"id":42,"name":"mobile-app"},{"id":18,"name":"monitoring"},{"id":36,"name":"networking"},{"id":7,"name":"node-version"},{"id":55,"name":"nosql"},{"id":57,"name":"observability"},{"id":46,"name":"orm"},{"id":52,"name":"os"},{"id":14,"name":"parser"},{"id":74,"name":"react"},{"id":82,"name":"real-time"},{"id":56,"name":"robot"},{"id":65,"name":"runtime"},{"id":32,"name":"sdk"},{"id":71,"name":"search"},{"id":63,"name":"secrets"},{"id":25,"name":"security"},{"id":85,"name":"server"},{"id":86,"name":"serverless"},{"id":70,"name":"storage"},{"id":75,"name":"system-design"},{"id":79,"name":"terminal"},{"id":29,"name":"testing"},{"id":12,"name":"ui"},{"id":50,"name":"ux"},{"id":88,"name":"video"},{"id":20,"name":"web-app"},{"id":35,"name":"web-server"},{"id":43,"name":"webassembly"},{"id":69,"name":"workflow"},{"id":87,"name":"yaml"}]" returns me the "expected json"