diff --git a/modules/lz4/1.9.4/MODULE.bazel b/modules/lz4/1.9.4/MODULE.bazel new file mode 100644 index 00000000000..7991ce5a9a1 --- /dev/null +++ b/modules/lz4/1.9.4/MODULE.bazel @@ -0,0 +1,6 @@ +module( + name = "lz4", + version = "1.9.4", + compatibility_level = 1, +) +bazel_dep(name = "rules_cc", version = "0.0.1") diff --git a/modules/lz4/1.9.4/patches/add_build_file.patch b/modules/lz4/1.9.4/patches/add_build_file.patch new file mode 100644 index 00000000000..aa2f415744a --- /dev/null +++ b/modules/lz4/1.9.4/patches/add_build_file.patch @@ -0,0 +1,62 @@ +--- /dev/null ++++ BUILD.bazel +@@ -0,0 +1,59 @@ ++""" Builds lz4. ++""" ++ ++load("@rules_cc//cc:defs.bzl", "cc_library") ++ ++cc_library( ++ name = "lz4", ++ srcs = [ ++ "lib/lz4.c", ++ "lib/xxhash.c", ++ "lib/xxhash.h", ++ ], ++ hdrs = [ ++ "lib/lz4.h", ++ ], ++ strip_include_prefix = "lib/", ++ visibility = ["//visibility:public"], ++) ++ ++cc_library( ++ name = "lz4_lz4c_include", ++ hdrs = [ ++ "lib/lz4.c", ++ ], ++ strip_include_prefix = "lib/", ++) ++ ++cc_library( ++ name = "lz4_hc", ++ srcs = [ ++ "lib/lz4hc.c", ++ ], ++ hdrs = [ ++ "lib/lz4hc.h", ++ ], ++ strip_include_prefix = "lib/", ++ visibility = ["//visibility:public"], ++ deps = [ ++ ":lz4", ++ ":lz4_lz4c_include", ++ ], ++) ++ ++cc_library( ++ name = "lz4_frame", ++ srcs = [ ++ "lib/lz4frame.c", ++ "lib/lz4frame_static.h", ++ ], ++ hdrs = [ ++ "lib/lz4frame.h", ++ ], ++ strip_include_prefix = "lib/", ++ visibility = ["//visibility:public"], ++ deps = [ ++ ":lz4", ++ ":lz4_hc", ++ ], ++) diff --git a/modules/lz4/1.9.4/patches/module_dot_bazel.patch b/modules/lz4/1.9.4/patches/module_dot_bazel.patch new file mode 100644 index 00000000000..62e6f849d65 --- /dev/null +++ b/modules/lz4/1.9.4/patches/module_dot_bazel.patch @@ -0,0 +1,9 @@ +--- MODULE.bazel ++++ MODULE.bazel +@@ -0,0 +1,6 @@ ++module( ++ name = "lz4", ++ version = "1.9.4", ++ compatibility_level = 1, ++) ++bazel_dep(name = "rules_cc", version = "0.0.1") diff --git a/modules/lz4/1.9.4/presubmit.yml b/modules/lz4/1.9.4/presubmit.yml new file mode 100644 index 00000000000..d313d1f3695 --- /dev/null +++ b/modules/lz4/1.9.4/presubmit.yml @@ -0,0 +1,13 @@ +matrix: + platform: + - debian10 + - ubuntu2004 + - macos + - macos_arm64 + - windows +tasks: + verify_targets: + name: Verify build targets + platform: ${{ platform }} + build_targets: + - "@lz4//:lz4" diff --git a/modules/lz4/1.9.4/source.json b/modules/lz4/1.9.4/source.json new file mode 100644 index 00000000000..ca8c2d58efc --- /dev/null +++ b/modules/lz4/1.9.4/source.json @@ -0,0 +1,10 @@ +{ + "url": "https://github.com/lz4/lz4/releases/download/v1.9.4/lz4-1.9.4.tar.gz", + "integrity": "sha256-Cw46oHyMBj3fQLCCvffjehVivaQKD/UnKVfz6Yfg5Us=", + "strip_prefix": "lz4-1.9.4", + "patches": { + "add_build_file.patch": "sha256-v1zbuA4Ya6cX2rDv54qh/8kwM7dimnWuyg40vCik4FM=", + "module_dot_bazel.patch": "sha256-V8GT+T9/zjsD3c67mJ4qVJoOkR4VZlXnpXl6b/FKI/Y=" + }, + "patch_strip": 0 +} \ No newline at end of file diff --git a/modules/lz4/metadata.json b/modules/lz4/metadata.json new file mode 100644 index 00000000000..c3c575e91dc --- /dev/null +++ b/modules/lz4/metadata.json @@ -0,0 +1,11 @@ +{ + "homepage": "https://github.com/lz4/lz4", + "maintainers": [], + "repository": [ + "github:lz4/lz4" + ], + "versions": [ + "1.9.4" + ], + "yanked_versions": {} +} \ No newline at end of file