diff --git a/modules/libxml2/2.13.3/MODULE.bazel b/modules/libxml2/2.13.3/MODULE.bazel new file mode 100644 index 00000000000..bb9e0e31df6 --- /dev/null +++ b/modules/libxml2/2.13.3/MODULE.bazel @@ -0,0 +1,6 @@ +module( + name = "libxml2", + version = "2.13.3", + compatibility_level = 1, +) +bazel_dep(name = "rules_foreign_cc", version = "0.11.1") diff --git a/modules/libxml2/2.13.3/patches/add_build_file.patch b/modules/libxml2/2.13.3/patches/add_build_file.patch new file mode 100644 index 00000000000..47f82aaa35c --- /dev/null +++ b/modules/libxml2/2.13.3/patches/add_build_file.patch @@ -0,0 +1,31 @@ +--- /dev/null ++++ BUILD.bazel +@@ -0,0 +1,28 @@ ++""" Builds libxml2. ++""" ++ ++load("@rules_foreign_cc//foreign_cc:defs.bzl", "cmake") ++ ++filegroup( ++ name = "srcs", ++ srcs = glob(["**"]), ++) ++ ++cache_entries = { ++ "CMAKE_POSITION_INDEPENDENT_CODE": "ON", ++ "BUILD_SHARED_LIBS": "OFF", ++ #libxml2 specific options. ++ "LIBXML2_WITH_PYTHON": "OFF", ++ "LIBXML2_WITH_LZMA": "OFF", ++ "LIBXML2_WITH_TESTS": "OFF", ++ "LIBXML2_WITH_PROGRAMS": "OFF", ++} ++ ++cmake( ++ name = "libxml2", ++ env = {"CMAKE_BUILD_TYPE": "Release"}, ++ lib_source = ":srcs", ++ cache_entries = cache_entries, ++ out_include_dir = "include/libxml2", ++ visibility = ["//visibility:public"], ++) diff --git a/modules/libxml2/2.13.3/patches/module_dot_bazel.patch b/modules/libxml2/2.13.3/patches/module_dot_bazel.patch new file mode 100644 index 00000000000..8fd488088fb --- /dev/null +++ b/modules/libxml2/2.13.3/patches/module_dot_bazel.patch @@ -0,0 +1,9 @@ +--- MODULE.bazel ++++ MODULE.bazel +@@ -0,0 +1,6 @@ ++module( ++ name = "libxml2", ++ version = "2.13.3", ++ compatibility_level = 1, ++) ++bazel_dep(name = "rules_foreign_cc", version = "0.11.1") diff --git a/modules/libxml2/2.13.3/presubmit.yml b/modules/libxml2/2.13.3/presubmit.yml new file mode 100644 index 00000000000..060f93eb58a --- /dev/null +++ b/modules/libxml2/2.13.3/presubmit.yml @@ -0,0 +1,17 @@ +matrix: + platform: + - debian10 + - ubuntu2004 + - macos + - macos_arm64 + - windows + bazel: + - 7.x + - 6.x +tasks: + verify_targets: + name: Verify build targets + platform: ${{ platform }} + bazel: ${{ bazel }} + build_targets: + - '@libxml2//:libxml2' diff --git a/modules/libxml2/2.13.3/source.json b/modules/libxml2/2.13.3/source.json new file mode 100644 index 00000000000..d64f50d106b --- /dev/null +++ b/modules/libxml2/2.13.3/source.json @@ -0,0 +1,10 @@ +{ + "url": "https://download.gnome.org/sources/libxml2/2.13/libxml2-2.13.3.tar.xz", + "integrity": "sha256-CAXXwYDPCcqtcWZsekWKdPBBVhpTKQJFTaUEfYOUgTg=", + "strip_prefix": "libxml2-2.13.3", + "patches": { + "add_build_file.patch": "sha256-BKxB6UXkAJ9GD0pAzHUWYHQh9hSNI6qRsrA+8/PI5eE=", + "module_dot_bazel.patch": "sha256-B5F+5RPZdW0ZjGBy2Ps42Y/YSfKjWWUodvcJxOGCZIc=" + }, + "patch_strip": 0 +} diff --git a/modules/libxml2/metadata.json b/modules/libxml2/metadata.json new file mode 100644 index 00000000000..ef0c152032b --- /dev/null +++ b/modules/libxml2/metadata.json @@ -0,0 +1,15 @@ +{ + "homepage": "https://gitlab.gnome.org/GNOME/libxml2/-/wikis/home", + "maintainers": [ + { + "email": "tectep@gmail.com", + "github": "dmitry-j-mikhin", + "name": "Dmitry Mikhin" + } + ], + "repository": [], + "versions": [ + "2.13.3" + ], + "yanked_versions": {} +}