diff --git a/.github/scripts/macos-check-static-linkage.sh b/.github/scripts/macos-check-static-linkage.sh new file mode 100755 index 00000000..91db8701 --- /dev/null +++ b/.github/scripts/macos-check-static-linkage.sh @@ -0,0 +1,7 @@ +#!/bin/bash + +otool -L target/debug/examples/quickstart_dense-* | grep tiledb +if [ "$?" -eq "0" ]; then + echo "Detected dynamic linkage to libtiledb.dylib" + exit 1 +fi diff --git a/.github/scripts/ubuntu-check-static-linkage.sh b/.github/scripts/ubuntu-check-static-linkage.sh new file mode 100755 index 00000000..291da746 --- /dev/null +++ b/.github/scripts/ubuntu-check-static-linkage.sh @@ -0,0 +1,7 @@ +#!/bin/bash + +ldd target/debug/examples/quickstart_dense-* | grep tiledb +if [ "$?" -eq "0" ]; then + echo "Detected dynamic linkage to libtiledb.so" + exit 1 +fi diff --git a/.github/workflows/nightly-static-ci.yml b/.github/workflows/nightly-static-ci.yml new file mode 100644 index 00000000..54ce5a16 --- /dev/null +++ b/.github/workflows/nightly-static-ci.yml @@ -0,0 +1,50 @@ +name: Static Nightlies +on: + schedule: + # runs every day at 1:45 UTC + - cron: "45 01 * * *" + workflow_dispatch: + +jobs: + test: + name: Test Static Build + strategy: + matrix: + os: ["ubuntu-latest", "macos-latest"] + runs-on: ${{ matrix.os }} + steps: + - name: Checkout tiledb-rs + uses: actions/checkout@v4 + - name: Install Rust + uses: dtolnay/rust-toolchain@master + with: + toolchain: stable + - name: Test + run: cargo test --all-targets --all-features + env: + # Building against a static version of libtiledb + TILEDB_SYS_STATIC: true + # Limit parallel compilation jobs to avoid exhausting RAM + TILEDB_SYS_JOBS: 4 + - name: Assert Static Linkage + if: ${{ startsWith(matrix.os, 'ubuntu-') }} + run: .github/scripts/ubuntu-check-static-linkage.sh + - name: Assert Static Linkage + if: ${{ startsWith(matrix.os, 'macos-') }} + run: .github/scripts/macos-check-static-linkage.sh + + create_issue_on_fail: + name: Create Issue on Fail + permissions: + issues: write + runs-on: ubuntu-latest + needs: test + if: failure() || cancelled() + steps: + - uses: actions/checkout@v3 + - name: Create Issue on Failure + uses: TileDB-Inc/github-actions/open-issue@main + with: + name: Nightly Build Failure + label: nightly-failure + assignee: davisp,rroelke diff --git a/Cargo.lock b/Cargo.lock index 4ddaae19..5fd979e9 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -2,6 +2,21 @@ # It is not intended for manual editing. version = 3 +[[package]] +name = "addr2line" +version = "0.24.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "dfbe277e56a376000877090da837660b4427aad530e3028d44e0bffe4f89a1c1" +dependencies = [ + "gimli", +] + +[[package]] +name = "adler2" +version = "2.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "512761e0bb2578dd7380c6baaa0f4ce03e84f95e960231d1dec8bf4d7d6e2627" + [[package]] name = "ahash" version = "0.8.11" @@ -18,9 +33,9 @@ dependencies = [ [[package]] name = "aho-corasick" -version = "1.1.2" +version = "1.1.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b2969dcb958b36655471fc61f7e416fa76033bdd4bfed0678d8fee1e2d07a1f0" +checksum = "8e60d3430d3a69478ad0993f19238d2df97c507009a52b3c10addcd7f6bcb916" dependencies = [ "memchr", ] @@ -40,81 +55,121 @@ dependencies = [ "libc", ] +[[package]] +name = "ansi_term" +version = "0.12.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d52a9bb7ec0cf484c551830a7ce27bd20d67eac647e1befb56b0be4ee39a55d2" +dependencies = [ + "winapi", +] + [[package]] name = "anstream" -version = "0.6.13" +version = "0.6.15" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d96bd03f33fe50a863e394ee9718a706f988b9079b20c3784fb726e7678b62fb" +checksum = "64e15c1ab1f89faffbf04a634d5e1962e9074f2741eef6d97f3c4e322426d526" dependencies = [ "anstyle", "anstyle-parse", "anstyle-query", "anstyle-wincon", "colorchoice", + "is_terminal_polyfill", "utf8parse", ] [[package]] name = "anstyle" -version = "1.0.6" +version = "1.0.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8901269c6307e8d93993578286ac0edf7f195079ffff5ebdeea6a59ffb7e36bc" +checksum = "1bec1de6f59aedf83baf9ff929c98f2ad654b97c9510f4e70cf6f661d49fd5b1" [[package]] name = "anstyle-parse" -version = "0.2.3" +version = "0.2.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c75ac65da39e5fe5ab759307499ddad880d724eed2f6ce5b5e8a26f4f387928c" +checksum = "eb47de1e80c2b463c735db5b217a0ddc39d612e7ac9e2e96a5aed1f57616c1cb" dependencies = [ "utf8parse", ] [[package]] name = "anstyle-query" -version = "1.0.2" +version = "1.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e28923312444cdd728e4738b3f9c9cac739500909bb3d3c94b43551b16517648" +checksum = "6d36fc52c7f6c869915e99412912f22093507da8d9e942ceaf66fe4b7c14422a" dependencies = [ - "windows-sys", + "windows-sys 0.52.0", ] [[package]] name = "anstyle-wincon" -version = "3.0.2" +version = "3.0.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1cd54b81ec8d6180e24654d0b371ad22fc3dd083b6ff8ba325b72e00c87660a7" +checksum = "5bf74e1b6e971609db8ca7a9ce79fd5768ab6ae46441c572e46cf596f59e57f8" dependencies = [ "anstyle", - "windows-sys", + "windows-sys 0.52.0", ] [[package]] name = "anyhow" -version = "1.0.89" +version = "1.0.91" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "86fdf8605db99b54d3cd748a44c6d04df638eb5dafb219b135d0149bd0db01f6" +checksum = "c042108f3ed77fd83760a5fd79b53be043192bb3b9dba91d8c574c0ada7850c8" +dependencies = [ + "backtrace", +] [[package]] name = "api-coverage" version = "0.1.0" dependencies = [ "anyhow", - "bindgen", - "clap", + "bindgen 0.69.5", + "clap 4.5.20", "pkg-config", "prettyplease", "proc-macro2", "quote", "regex", - "syn", + "syn 2.0.82", "walkdir", ] +[[package]] +name = "ar" +version = "0.9.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d67af77d68a931ecd5cbd8a3b5987d63a1d1d1278f7f6a60ae33db485cdebb69" + +[[package]] +name = "armerge" +version = "2.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ed1ea68b6701356e281d3205cbae93ab693643790ebf2a844305fc85f488509a" +dependencies = [ + "ar", + "goblin", + "object 0.29.0", + "objpoke", + "rand", + "rayon", + "regex", + "structopt", + "tempfile", + "thiserror", + "time", + "tracing", + "tracing-subscriber", +] + [[package]] name = "arrow" -version = "52.0.0" +version = "52.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7ae9728f104939be6d8d9b368a354b4929b0569160ea1641f0721b55a861ce38" +checksum = "05048a8932648b63f21c37d88b552ccc8a65afb6dfe9fc9f30ce79174c2e7a85" dependencies = [ "arrow-arith", "arrow-array", @@ -133,9 +188,9 @@ dependencies = [ [[package]] name = "arrow-arith" -version = "52.0.0" +version = "52.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a7029a5b3efbeafbf4a12d12dc16b8f9e9bff20a410b8c25c5d28acc089e1043" +checksum = "1d8a57966e43bfe9a3277984a14c24ec617ad874e4c0e1d2a1b083a39cfbf22c" dependencies = [ "arrow-array", "arrow-buffer", @@ -148,9 +203,9 @@ dependencies = [ [[package]] name = "arrow-array" -version = "52.0.0" +version = "52.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d33238427c60271710695f17742f45b1a5dc5bcfc5c15331c25ddfe7abf70d97" +checksum = "16f4a9468c882dc66862cef4e1fd8423d47e67972377d85d80e022786427768c" dependencies = [ "ahash", "arrow-buffer", @@ -158,15 +213,15 @@ dependencies = [ "arrow-schema", "chrono", "half", - "hashbrown", + "hashbrown 0.14.5", "num", ] [[package]] name = "arrow-buffer" -version = "52.0.0" +version = "52.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fe9b95e825ae838efaf77e366c00d3fc8cca78134c9db497d6bda425f2e7b7c1" +checksum = "c975484888fc95ec4a632cdc98be39c085b1bb518531b0c80c5d462063e5daa1" dependencies = [ "bytes", "half", @@ -175,9 +230,9 @@ dependencies = [ [[package]] name = "arrow-cast" -version = "52.0.0" +version = "52.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "87cf8385a9d5b5fcde771661dd07652b79b9139fea66193eda6a88664400ccab" +checksum = "da26719e76b81d8bc3faad1d4dbdc1bcc10d14704e63dc17fc9f3e7e1e567c8e" dependencies = [ "arrow-array", "arrow-buffer", @@ -196,9 +251,9 @@ dependencies = [ [[package]] name = "arrow-csv" -version = "52.0.0" +version = "52.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cea5068bef430a86690059665e40034625ec323ffa4dd21972048eebb0127adc" +checksum = "c13c36dc5ddf8c128df19bab27898eea64bf9da2b555ec1cd17a8ff57fba9ec2" dependencies = [ "arrow-array", "arrow-buffer", @@ -215,9 +270,9 @@ dependencies = [ [[package]] name = "arrow-data" -version = "52.0.0" +version = "52.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cb29be98f987bcf217b070512bb7afba2f65180858bca462edf4a39d84a23e10" +checksum = "dd9d6f18c65ef7a2573ab498c374d8ae364b4a4edf67105357491c031f716ca5" dependencies = [ "arrow-buffer", "arrow-schema", @@ -227,9 +282,9 @@ dependencies = [ [[package]] name = "arrow-ipc" -version = "52.0.0" +version = "52.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ffc68f6523970aa6f7ce1dc9a33a7d9284cfb9af77d4ad3e617dbe5d79cc6ec8" +checksum = "e786e1cdd952205d9a8afc69397b317cfbb6e0095e445c69cda7e8da5c1eeb0f" dependencies = [ "arrow-array", "arrow-buffer", @@ -241,9 +296,9 @@ dependencies = [ [[package]] name = "arrow-json" -version = "52.0.0" +version = "52.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2041380f94bd6437ab648e6c2085a045e45a0c44f91a1b9a4fe3fed3d379bfb1" +checksum = "fb22284c5a2a01d73cebfd88a33511a3234ab45d66086b2ca2d1228c3498e445" dependencies = [ "arrow-array", "arrow-buffer", @@ -261,9 +316,9 @@ dependencies = [ [[package]] name = "arrow-ord" -version = "52.0.0" +version = "52.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fcb56ed1547004e12203652f12fe12e824161ff9d1e5cf2a7dc4ff02ba94f413" +checksum = "42745f86b1ab99ef96d1c0bcf49180848a64fe2c7a7a0d945bc64fa2b21ba9bc" dependencies = [ "arrow-array", "arrow-buffer", @@ -276,9 +331,9 @@ dependencies = [ [[package]] name = "arrow-row" -version = "52.0.0" +version = "52.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "575b42f1fc588f2da6977b94a5ca565459f5ab07b60545e17243fb9a7ed6d43e" +checksum = "4cd09a518c602a55bd406bcc291a967b284cfa7a63edfbf8b897ea4748aad23c" dependencies = [ "ahash", "arrow-array", @@ -286,20 +341,19 @@ dependencies = [ "arrow-data", "arrow-schema", "half", - "hashbrown", ] [[package]] name = "arrow-schema" -version = "52.0.0" +version = "52.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "32aae6a60458a2389c0da89c9de0b7932427776127da1a738e2efc21d32f3393" +checksum = "9e972cd1ff4a4ccd22f86d3e53e835c2ed92e0eea6a3e8eadb72b4f1ac802cf8" [[package]] name = "arrow-select" -version = "52.0.0" +version = "52.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "de36abaef8767b4220d7b4a8c2fe5ffc78b47db81b03d77e2136091c3ba39102" +checksum = "600bae05d43483d216fb3494f8c32fdbefd8aa4e1de237e790dbb3d9f44690a3" dependencies = [ "ahash", "arrow-array", @@ -311,9 +365,9 @@ dependencies = [ [[package]] name = "arrow-string" -version = "52.0.0" +version = "52.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e435ada8409bcafc910bc3e0077f532a4daa20e99060a496685c0e3e53cc2597" +checksum = "f0dc1985b67cb45f6606a248ac2b4a288849f196bab8c657ea5589f47cdd55e6" dependencies = [ "arrow-array", "arrow-buffer", @@ -323,7 +377,7 @@ dependencies = [ "memchr", "num", "regex", - "regex-syntax", + "regex-syntax 0.8.5", ] [[package]] @@ -335,11 +389,37 @@ dependencies = [ "num-traits", ] +[[package]] +name = "atty" +version = "0.2.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d9b39be18770d11421cdb1b9947a45dd3f37e93092cbf377614828a319d5fee8" +dependencies = [ + "hermit-abi", + "libc", + "winapi", +] + [[package]] name = "autocfg" -version = "1.1.0" +version = "1.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" +checksum = "ace50bade8e6234aa140d9a2f552bbee1db4d353f69b8217bc503490fc1a9f26" + +[[package]] +name = "backtrace" +version = "0.3.74" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8d82cb332cdfaed17ae235a638438ac4d4839913cc2af585c3c6746e8f8bee1a" +dependencies = [ + "addr2line", + "cfg-if", + "libc", + "miniz_oxide", + "object 0.36.5", + "rustc-demangle", + "windows-targets", +] [[package]] name = "base64" @@ -349,14 +429,14 @@ checksum = "72b3254f16251a8381aa12e40e3c4d2f0199f8c6508fbecb9d91f575e0fbb8c6" [[package]] name = "bindgen" -version = "0.69.4" +version = "0.69.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a00dc851838a2120612785d195287475a3ac45514741da670b735818822129a0" +checksum = "271383c67ccabffb7381723dea0672a673f292304fcb45c01cc648c7a8d58088" dependencies = [ - "bitflags 2.5.0", + "bitflags 2.6.0", "cexpr", "clang-sys", - "itertools", + "itertools 0.12.1", "lazy_static", "lazycell", "log", @@ -366,10 +446,30 @@ dependencies = [ "regex", "rustc-hash", "shlex", - "syn", + "syn 2.0.82", "which", ] +[[package]] +name = "bindgen" +version = "0.70.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f49d8fed880d473ea71efb9bf597651e77201bdd4893efe54c9e5d65ae04ce6f" +dependencies = [ + "bitflags 2.6.0", + "cexpr", + "clang-sys", + "itertools 0.13.0", + "log", + "prettyplease", + "proc-macro2", + "quote", + "regex", + "rustc-hash", + "shlex", + "syn 2.0.82", +] + [[package]] name = "bit-set" version = "0.5.3" @@ -393,27 +493,36 @@ checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a" [[package]] name = "bitflags" -version = "2.5.0" +version = "2.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf4b9d6a944f767f8e5e0db018570623c85f3d925ac718db4e06d0187adb21c1" +checksum = "b048fb63fd8b5923fc5aa7b340d8e156aec7ec02f0c78fa8a6ddc2613f6f71de" [[package]] name = "bumpalo" -version = "3.15.4" +version = "3.16.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7ff69b9dd49fd426c69a0db9fc04dd934cdb6645ff000864d98f7e2af8830eaa" +checksum = "79296716171880943b8470b5f8d03aa55eb2e645a4874bdbb28adb49162e012c" [[package]] -name = "bytes" +name = "byteorder" version = "1.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a2bd12c1caf447e69cd4528f47f94d203fd2582878ecb9e9465484c4148a8223" +checksum = "1fd0f2584146f6f2ef48085050886acf353beff7305ebd1ae69500e27c67f64b" + +[[package]] +name = "bytes" +version = "1.8.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "9ac0150caa2ae65ca5bd83f25c7de183dea78d4d366469f148435e2acfbad0da" [[package]] name = "cc" -version = "1.0.90" +version = "1.1.31" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8cd6604a82acf3039f1144f54b8eb34e91ffba622051189e71b781822d5ee1f5" +checksum = "c2e7962b54006dcfcc61cb72735f4d89bb97061dd6a7ed882ec6b8ee53714c6f" +dependencies = [ + "shlex", +] [[package]] name = "cells" @@ -444,15 +553,15 @@ checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd" [[package]] name = "cfg_aliases" -version = "0.1.1" +version = "0.2.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fd16c4719339c4530435d38e511904438d07cce7950afa3718a84ac36c10e89e" +checksum = "613afe47fcd5fac7ccf1db93babcb082c5994d996f20b8b159f2ad1658eb5724" [[package]] name = "chrono" -version = "0.4.35" +version = "0.4.38" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8eaf5903dcbc0a39312feb77df2ff4c76387d591b9fc7b04a238dcf8bb62639a" +checksum = "a21f936df1771bf62b77f047b726c4625ff2e8aa607c01ec06e5a05bd8463401" dependencies = [ "android-tzdata", "iana-time-zone", @@ -462,9 +571,9 @@ dependencies = [ [[package]] name = "clang-sys" -version = "1.7.0" +version = "1.8.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "67523a3b4be3ce1989d607a828d036249522dd9c1c8de7f4dd2dae43a37369d1" +checksum = "0b023947811758c97c59bf9d1c188fd619ad4718dcaa767947df1cadb14f39f4" dependencies = [ "glob", "libc", @@ -473,9 +582,24 @@ dependencies = [ [[package]] name = "clap" -version = "4.5.4" +version = "2.34.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "90bc066a67923782aa8515dbaea16946c5bcc5addbd668bb80af688e53e548a0" +checksum = "a0610544180c38b88101fecf2dd634b174a62eef6946f84dfc6a7127512b381c" +dependencies = [ + "ansi_term", + "atty", + "bitflags 1.3.2", + "strsim 0.8.0", + "textwrap", + "unicode-width", + "vec_map", +] + +[[package]] +name = "clap" +version = "4.5.20" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b97f376d85a664d5837dbae44bf546e6477a679ff6610010f17276f686d867e8" dependencies = [ "clap_builder", "clap_derive", @@ -483,45 +607,54 @@ dependencies = [ [[package]] name = "clap_builder" -version = "4.5.2" +version = "4.5.20" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ae129e2e766ae0ec03484e609954119f123cc1fe650337e155d03b022f24f7b4" +checksum = "19bc80abd44e4bed93ca373a0704ccbd1b710dc5749406201bb018272808dc54" dependencies = [ "anstream", "anstyle", "clap_lex", - "strsim", + "strsim 0.11.1", ] [[package]] name = "clap_derive" -version = "4.5.4" +version = "4.5.18" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "528131438037fd55894f62d6e9f068b8f45ac57ffa77517819645d10aed04f64" +checksum = "4ac6a0c7b1a9e9a5186361f67dfa1b88213572f427fb9ab038efb2bd8c582dab" dependencies = [ "heck 0.5.0", "proc-macro2", "quote", - "syn", + "syn 2.0.82", ] [[package]] name = "clap_lex" -version = "0.7.0" +version = "0.7.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "98cc8fbded0c607b7ba9dd60cd98df59af97e84d24e49c8557331cfc26d301ce" +checksum = "1462739cb27611015575c0c11df5df7601141071f07518d56fcc1be504cbec97" + +[[package]] +name = "cmake" +version = "0.1.51" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fb1e43aa7fd152b1f968787f7dbcdeb306d1867ff373c69955211876c053f91a" +dependencies = [ + "cc", +] [[package]] name = "colorchoice" -version = "1.0.0" +version = "1.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "acbf1af155f9b9ef647e42cdc158db4b64a1b61f743629225fde6f3e0be2a7c7" +checksum = "d3fd119d74b830634cea2a0f58bbd0d54540518a14397557951e79340abc28c0" [[package]] name = "comfy-table" -version = "7.1.0" +version = "7.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7c64043d6c7b7a4c58e39e7efccfdea7b93d885a795d0c054a69dbbf4dd52686" +checksum = "b34115915337defe99b2aff5c2ce6771e5fbc4079f4b506301f5cf394c8452f7" dependencies = [ "strum", "strum_macros", @@ -550,9 +683,43 @@ dependencies = [ [[package]] name = "core-foundation-sys" -version = "0.8.6" +version = "0.8.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "773648b94d0e5d620f64f280777445740e61fe701025087ec8b57f45c791888b" + +[[package]] +name = "crc32fast" +version = "1.4.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a97769d94ddab943e4510d138150169a2758b5ef3eb191a9ee688de3e23ef7b3" +dependencies = [ + "cfg-if", +] + +[[package]] +name = "crossbeam-deque" +version = "0.8.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "613f8cc01fe9cf1a3eb3d7f488fd2fa8388403e97039e2f73692932e291a770d" +dependencies = [ + "crossbeam-epoch", + "crossbeam-utils", +] + +[[package]] +name = "crossbeam-epoch" +version = "0.9.18" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "06ea2b9bc92be3c2baa9334a323ebca2d6f074ff852cd1d7b11064035cd3868f" +checksum = "5b82ac4a3c2ca9c3460964f020e1402edd5753411d7737aa39c3714ad1b5420e" +dependencies = [ + "crossbeam-utils", +] + +[[package]] +name = "crossbeam-utils" +version = "0.8.20" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "22ec99545bb0ed0ea7bb9b8e1e9122ea386ff8a48c0922e43f36d45ab09e0e80" [[package]] name = "crunchy" @@ -581,11 +748,20 @@ dependencies = [ "memchr", ] +[[package]] +name = "deranged" +version = "0.3.11" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b42b6fa04a440b495c8b04d0e71b707c585f83cb9cb28cf8cd0d976c315e31b4" +dependencies = [ + "powerfmt", +] + [[package]] name = "either" -version = "1.10.0" +version = "1.13.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "11157ac094ffbdde99aa67b23417ebdd801842852b500e395a45a9c0aac03e4a" +checksum = "60b1af1c220855b6ceac025d3f6ecdd2b7c4894bfe9cd9bda4fbb4bc7c0d4cf0" [[package]] name = "equivalent" @@ -595,19 +771,19 @@ checksum = "5443807d6dff69373d433ab9ef5378ad8df50ca6298caf15de6e52e24aaf54d5" [[package]] name = "errno" -version = "0.3.8" +version = "0.3.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a258e46cdc063eb8519c00b9fc845fc47bcfca4130e2f08e88665ceda8474245" +checksum = "534c5cf6194dfab3db3242765c03bbe257cf92f22b38f6bc0c58d59108a820ba" dependencies = [ "libc", - "windows-sys", + "windows-sys 0.52.0", ] [[package]] name = "fastrand" -version = "2.0.1" +version = "2.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "25cbce373ec4653f1a01a31e8a5e5ec0c622dc27ff9c4e6606eefef5cbbed4a5" +checksum = "e8c02a5121d4ea3eb16a80748c74f5549a5665e4c21333c6098f283870fbdea6" [[package]] name = "flatbuffers" @@ -619,6 +795,16 @@ dependencies = [ "rustc_version", ] +[[package]] +name = "flate2" +version = "1.0.34" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a1b589b4dc103969ad3cf85c950899926ec64300a1a46d76c03a6072957036f0" +dependencies = [ + "crc32fast", + "miniz_oxide", +] + [[package]] name = "float_next_after" version = "1.0.0" @@ -633,26 +819,43 @@ checksum = "3f9eec918d3f24069decb9af1554cad7c880e2da24a9afd88aca000531ab82c1" [[package]] name = "getrandom" -version = "0.2.12" +version = "0.2.15" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "190092ea657667030ac6a35e305e62fc4dd69fd98ac98631e5d3a2b1575a12b5" +checksum = "c4567c8db10ae91089c99af84c68c38da3ec2f087c3f82960bcdbf3656b6f4d7" dependencies = [ "cfg-if", "libc", "wasi", ] +[[package]] +name = "gimli" +version = "0.31.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "07e28edb80900c19c28f1072f2e8aeca7fa06b23cd4169cefe1af5aa3260783f" + [[package]] name = "glob" version = "0.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d2fabcfbdc87f4758337ca535fb41a6d701b65693ce38287d856d1674551ec9b" +[[package]] +name = "goblin" +version = "0.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ee05c709047abe5eb0571880d2887ac77299c5f0835f8e6b7f4d5404f8962921" +dependencies = [ + "log", + "plain", + "scroll", +] + [[package]] name = "half" -version = "2.4.0" +version = "2.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b5eceaaeec696539ddaf7b333340f1af35a5aa87ae3e4f3ead0532f72affab2e" +checksum = "6dd08c532ae367adf81c312a4580bc67f1d0fe8bc9c460520283f4c0ff277888" dependencies = [ "cfg-if", "crunchy", @@ -661,15 +864,24 @@ dependencies = [ [[package]] name = "hashbrown" -version = "0.14.4" +version = "0.14.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e57fa0ae458eb99874f54c09f4f9174f8b45fb87e854536a4e608696247f0c23" +checksum = "e5274423e17b7c9fc20b6e7e208532f9b19825d82dfd615708b70edd83df41f1" + +[[package]] +name = "hashbrown" +version = "0.15.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1e087f84d4f86bf4b218b927129862374b72199ae7d8657835f1e89000eea4fb" [[package]] name = "heck" -version = "0.4.1" +version = "0.3.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95505c38b4572b2d910cecb0281560f54b440a19336cbbcb27bf6ce6adc6f5a8" +checksum = "6d621efb26863f0e9924c6ac577e8275e5e6b77455db64ffa6c65c904e9e132c" +dependencies = [ + "unicode-segmentation", +] [[package]] name = "heck" @@ -677,20 +889,29 @@ version = "0.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "2304e00983f87ffb38b55b444b5e3b60a884b5d30c0fca7d82fe33449bbe55ea" +[[package]] +name = "hermit-abi" +version = "0.1.19" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "62b467343b94ba476dcb2500d242dadbb39557df889310ac77c5d99100aaac33" +dependencies = [ + "libc", +] + [[package]] name = "home" version = "0.5.9" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e3d1354bf6b7235cb4a0576c2619fd4ed18183f689b12b006a0ee7329eeff9a5" dependencies = [ - "windows-sys", + "windows-sys 0.52.0", ] [[package]] name = "iana-time-zone" -version = "0.1.60" +version = "0.1.61" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e7ffbb5a1b541ea2561f8c41c087286cc091e21e556a4f09a8f6cbf17b69b141" +checksum = "235e081f3925a06703c2d0117ea8b91f042756fd6e7a6e5d901e8ca1a996b220" dependencies = [ "android_system_properties", "core-foundation-sys", @@ -711,14 +932,20 @@ dependencies = [ [[package]] name = "indexmap" -version = "2.2.5" +version = "2.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7b0b929d511467233429c45a44ac1dcaa21ba0f5ba11e4879e6ed28ddb4f9df4" +checksum = "707907fe3c25f5424cce2cb7e1cbcafee6bdbe735ca90ef77c29e84591e5b9da" dependencies = [ "equivalent", - "hashbrown", + "hashbrown 0.15.0", ] +[[package]] +name = "is_terminal_polyfill" +version = "1.70.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7943c866cc5cd64cbc25b2e01621d07fa8eb2a1a23160ee81ce38704e97b8ecf" + [[package]] name = "itertools" version = "0.12.1" @@ -728,26 +955,35 @@ dependencies = [ "either", ] +[[package]] +name = "itertools" +version = "0.13.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "413ee7dfc52ee1a4949ceeb7dbc8a33f2d6c088194d9f922fb8318faf1f01186" +dependencies = [ + "either", +] + [[package]] name = "itoa" -version = "1.0.10" +version = "1.0.11" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b1a46d1a171d865aa5f83f92695765caa047a9b4cbae2cbf37dbd613a793fd4c" +checksum = "49f1f14873335454500d59611f1cf4a4b0f786f9ac11f4312a78e4cf2566695b" [[package]] name = "js-sys" -version = "0.3.69" +version = "0.3.72" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "29c15563dc2726973df627357ce0c9ddddbea194836909d655df6a75d2cf296d" +checksum = "6a88f1bda2bd75b0452a14784937d796722fdebfe50df998aeb3f0b7603019a9" dependencies = [ "wasm-bindgen", ] [[package]] name = "lazy_static" -version = "1.4.0" +version = "1.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e2abad23fbc42b3700f2f279844dc832adb2b2eb069b2df918f455c4e18cc646" +checksum = "bbd2bcb4c963f2ddae06a2efc7e9f3591312473c50c6685e1f298068316e66fe" [[package]] name = "lazycell" @@ -821,15 +1057,15 @@ dependencies = [ [[package]] name = "libc" -version = "0.2.153" +version = "0.2.161" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9c198f91728a82281a64e1f4f9eeb25d82cb32a5de251c6bd1b5154d63a8e7bd" +checksum = "8e9489c2807c139ffd9c1794f4af0ebe86a828db53ecdc7fea2111d0fed085d1" [[package]] name = "libloading" -version = "0.8.3" +version = "0.8.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0c2a198fb6b0eada2a8df47933734e6d35d350665a33a3593d7164fa52c75c19" +checksum = "4979f22fdb869068da03c9f7528f8297c6fd2606bc3a4affe42e6a823fdb8da4" dependencies = [ "cfg-if", "windows-targets", @@ -841,30 +1077,32 @@ version = "0.2.8" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "4ec2a862134d2a7d32d7983ddcdd1c4923530833c9f2ea1a44fc5fa473989058" -[[package]] -name = "libtiledb" -version = "0.1.0" -dependencies = [ - "pkg-config", -] - [[package]] name = "linux-raw-sys" -version = "0.4.13" +version = "0.4.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "01cda141df6706de531b6c46c3a33ecca755538219bd484262fa09410c13539c" +checksum = "78b3ae25bc7c8c38cec158d1f2757ee79e9b3740fbc7ccf0e59e4b08d793fa89" [[package]] name = "log" -version = "0.4.21" +version = "0.4.22" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a7a70ba024b9dc04c27ea2f0c0548feb474ec5c54bba33a7f72f873a39d07b24" + +[[package]] +name = "matchers" +version = "0.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "90ed8c1e510134f979dbc4f070f87d4313098b704861a105fe34231c70a3901c" +checksum = "8263075bb86c5a1b1427b5ae862e8889656f126e9f77c484496e8b47cf5c5558" +dependencies = [ + "regex-automata 0.1.10", +] [[package]] name = "memchr" -version = "2.7.1" +version = "2.7.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "523dc4f511e55ab87b694dc30d0f820d60906ef06413f93d4d7a1385599cc149" +checksum = "78ca9ab1a0babb1e7d5695e3530886289c18cf2f87ec19a575a0abdce112e3a3" [[package]] name = "minimal-lexical" @@ -872,13 +1110,22 @@ version = "0.2.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "68354c5c6bd36d73ff3feceb05efa59b6acb7626617f4962be322a825e61f79a" +[[package]] +name = "miniz_oxide" +version = "0.8.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e2d80299ef12ff69b16a84bb182e3b9df68b5a91574d3d4fa6e41b65deec4df1" +dependencies = [ + "adler2", +] + [[package]] name = "nix" -version = "0.28.0" +version = "0.29.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ab2156c4fce2f8df6c499cc1c763e4394b7482525bf2a9701c9d79d215f519e4" +checksum = "71e2746dc3a24dd78b3cfcb7be93368c6de9963d30f43a6a73998a9cf4b17b46" dependencies = [ - "bitflags 2.5.0", + "bitflags 2.6.0", "cfg-if", "cfg_aliases", "libc", @@ -894,11 +1141,21 @@ dependencies = [ "minimal-lexical", ] +[[package]] +name = "nu-ansi-term" +version = "0.46.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "77a8165726e8236064dbb45459242600304b42a5ea24ee2948e18e023bf7ba84" +dependencies = [ + "overload", + "winapi", +] + [[package]] name = "num" -version = "0.4.1" +version = "0.4.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b05180d69e3da0e530ba2a1dae5110317e49e3b7f3d41be227dc5f92e49ee7af" +checksum = "35bd024e8b2ff75562e5f34e7f4905839deb4b22955ef5e73d2fea1b9813cb23" dependencies = [ "num-bigint", "num-complex", @@ -910,24 +1167,29 @@ dependencies = [ [[package]] name = "num-bigint" -version = "0.4.4" +version = "0.4.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "608e7659b5c3d7cba262d894801b9ec9d00de989e8a82bd4bef91d08da45cdc0" +checksum = "a5e44f723f1133c9deac646763579fdb3ac745e418f2a7af9cd0c431da1f20b9" dependencies = [ - "autocfg", "num-integer", "num-traits", ] [[package]] name = "num-complex" -version = "0.4.5" +version = "0.4.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "23c6602fda94a57c990fe0df199a035d83576b496aa29f4e634a8ac6004e68a6" +checksum = "73f88a1307638156682bada9d7604135552957b7818057dcef22705b4d509495" dependencies = [ "num-traits", ] +[[package]] +name = "num-conv" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "51d515d32fb182ee37cda2ccdcb92950d6a3c2893aa280e540671c2cd0f3b1d9" + [[package]] name = "num-integer" version = "0.1.46" @@ -939,9 +1201,9 @@ dependencies = [ [[package]] name = "num-iter" -version = "0.1.44" +version = "0.1.45" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d869c01cc0c455284163fd0092f1f93835385ccab5a98a0dcc497b2f8bf055a9" +checksum = "1429034a0490724d0075ebb2bc9e875d6503c3cf69e235a8941aa757d83ef5bf" dependencies = [ "autocfg", "num-integer", @@ -950,11 +1212,10 @@ dependencies = [ [[package]] name = "num-rational" -version = "0.4.1" +version = "0.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0638a1c9d0a3c0914158145bc76cff373a75a627e6ecbfb71cbe6f453a5a19b0" +checksum = "f83d14da390562dca69fc84082e73e548e1ad308d24accdedd2720017cb37824" dependencies = [ - "autocfg", "num-bigint", "num-integer", "num-traits", @@ -962,72 +1223,164 @@ dependencies = [ [[package]] name = "num-traits" -version = "0.2.18" +version = "0.2.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "da0df0e5185db44f69b44f26786fe401b6c293d1907744beaa7fa62b2e5a517a" +checksum = "071dfc062690e90b734c0b2273ce72ad0ffa95f0c74596bc250dcfd960262841" dependencies = [ "autocfg", "libm", ] +[[package]] +name = "num_threads" +version = "0.1.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5c7398b9c8b70908f6371f47ed36737907c87c52af34c268fed0bf0ceb92ead9" +dependencies = [ + "libc", +] + +[[package]] +name = "object" +version = "0.29.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "21158b2c33aa6d4561f1c0a6ea283ca92bc54802a93b263e910746d679a7eb53" +dependencies = [ + "flate2", + "memchr", +] + +[[package]] +name = "object" +version = "0.36.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "aedf0a2d09c573ed1d8d85b30c119153926a2b36dce0ab28322c09a117a4683e" +dependencies = [ + "memchr", +] + +[[package]] +name = "objpoke" +version = "0.3.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f226d2911ce4e28bc72827065e0e2a1fe4f4c8eda83ec919cd724720a5500c30" +dependencies = [ + "anyhow", + "goblin", + "regex", + "scroll", + "structopt", +] + [[package]] name = "once_cell" -version = "1.19.0" +version = "1.20.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1261fe7e33c73b354eab43b1273a57c8f967d0391e80353e51f764ac02cf6775" + +[[package]] +name = "overload" +version = "0.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3fdb12b2476b595f9358c5161aa467c2438859caa136dec86c26fdd2efe17b92" +checksum = "b15813163c1d831bf4a13c3610c05c0d03b39feb07f7e09fa234dac9b15aaf39" [[package]] name = "paste" -version = "1.0.14" +version = "1.0.15" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "de3145af08024dea9fa9914f381a17b8fc6034dfb00f3a84013f7ff43f29ed4c" +checksum = "57c0d7b74b563b49d38dae00a0c37d4d6de9b432382b2892f0574ddcae73fd0a" + +[[package]] +name = "pin-project-lite" +version = "0.2.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bda66fc9667c18cb2758a2ac84d1167245054bcf85d5d1aaa6923f45801bdd02" [[package]] name = "pkg-config" -version = "0.3.30" +version = "0.3.31" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "953ec861398dccce10c670dfeaf3ec4911ca479e9c02154b3a215178c5f566f2" + +[[package]] +name = "plain" +version = "0.2.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d231b230927b5e4ad203db57bbcbee2802f6bce620b1e4a9024a07d94e2907ec" +checksum = "b4596b6d070b27117e987119b4dac604f3c58cfb0b191112e24771b2faeac1a6" + +[[package]] +name = "powerfmt" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "439ee305def115ba05938db6eb1644ff94165c5ab5e9420d1c1bcedbba909391" [[package]] name = "ppv-lite86" -version = "0.2.17" +version = "0.2.20" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5b40af805b3121feab8a3c29f04d8ad262fa8e0561883e7653e024ae4479e6de" +checksum = "77957b295656769bb8ad2b6a6b09d897d94f05c41b069aede1fcdaa675eaea04" +dependencies = [ + "zerocopy", +] [[package]] name = "prettyplease" -version = "0.2.17" +version = "0.2.24" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8d3928fb5db768cb86f891ff014f0144589297e3c6a1aba6ed7cecfdace270c7" +checksum = "910d41a655dac3b764f1ade94821093d3610248694320cd072303a8eedcf221d" dependencies = [ "proc-macro2", - "syn", + "syn 2.0.82", +] + +[[package]] +name = "proc-macro-error" +version = "1.0.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "da25490ff9892aab3fcf7c36f08cfb902dd3e71ca0f9f9517bea02a73a5ce38c" +dependencies = [ + "proc-macro-error-attr", + "proc-macro2", + "quote", + "syn 1.0.109", + "version_check", +] + +[[package]] +name = "proc-macro-error-attr" +version = "1.0.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a1be40180e52ecc98ad80b184934baf3d0d29f979574e439af5a55274b35f869" +dependencies = [ + "proc-macro2", + "quote", + "version_check", ] [[package]] name = "proc-macro2" -version = "1.0.79" +version = "1.0.89" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e835ff2298f5721608eb1a980ecaee1aef2c132bf95ecc026a11b7bf3c01c02e" +checksum = "f139b0662de085916d1fb67d2b4169d1addddda1919e696f3252b740b629986e" dependencies = [ "unicode-ident", ] [[package]] name = "proptest" -version = "1.4.0" +version = "1.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "31b476131c3c86cb68032fdc5cb6d5a1045e3e42d96b69fa599fd77701e1f5bf" +checksum = "b4c2511913b88df1637da85cc8d96ec8e43a3f8bb8ccb71ee1ac240d6f3df58d" dependencies = [ "bit-set", "bit-vec", - "bitflags 2.5.0", + "bitflags 2.6.0", "lazy_static", "num-traits", "rand", "rand_chacha", "rand_xorshift", - "regex-syntax", + "regex-syntax 0.8.5", "rusty-fork", "tempfile", "unarray", @@ -1041,9 +1394,9 @@ checksum = "a1d01941d82fa2ab50be1e79e6714289dd7cde78eba4c074bc5a4374f650dfe0" [[package]] name = "quote" -version = "1.0.35" +version = "1.0.37" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "291ec9ab5efd934aaf503a6466c5d5251535d108ee747472c3977cc5acc868ef" +checksum = "b5b9d34b8991d19d98081b46eacdd8eb58c6f2b201139f7c5f643cc155a633af" dependencies = [ "proc-macro2", ] @@ -1087,34 +1440,75 @@ dependencies = [ "rand_core", ] +[[package]] +name = "rayon" +version = "1.10.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b418a60154510ca1a002a752ca9714984e21e4241e804d32555251faf8b78ffa" +dependencies = [ + "either", + "rayon-core", +] + +[[package]] +name = "rayon-core" +version = "1.12.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1465873a3dfdaa8ae7cb14b4383657caab0b3e8a0aa9ae8e04b044854c8dfce2" +dependencies = [ + "crossbeam-deque", + "crossbeam-utils", +] + [[package]] name = "regex" -version = "1.10.4" +version = "1.11.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c117dbdfde9c8308975b6a18d71f3f385c89461f7b3fb054288ecf2a2058ba4c" +checksum = "38200e5ee88914975b69f657f0801b6f6dccafd44fd9326302a4aaeecfacb1d8" dependencies = [ "aho-corasick", "memchr", - "regex-automata", - "regex-syntax", + "regex-automata 0.4.8", + "regex-syntax 0.8.5", ] [[package]] name = "regex-automata" -version = "0.4.6" +version = "0.1.10" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "6c230d73fb8d8c1b9c0b3135c5142a8acee3a0558fb8db5cf1cb65f8d7862132" +dependencies = [ + "regex-syntax 0.6.29", +] + +[[package]] +name = "regex-automata" +version = "0.4.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "86b83b8b9847f9bf95ef68afb0b8e6cdb80f498442f5179a29fad448fcc1eaea" +checksum = "368758f23274712b504848e9d5a6f010445cc8b87a7cdb4d7cbee666c1288da3" dependencies = [ "aho-corasick", "memchr", - "regex-syntax", + "regex-syntax 0.8.5", ] [[package]] name = "regex-syntax" -version = "0.8.2" +version = "0.6.29" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f162c6dd7b008981e4d40210aca20b4bd0f9b60ca9271061b07f78537722f2e1" + +[[package]] +name = "regex-syntax" +version = "0.8.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c08c74e62047bb2de4ff487b251e4a92e24f48745648451635cec7d591162d9f" +checksum = "2b15c43186be67a4fd63bee50d0303afffcef381492ebe2c5d87f324e1b8815c" + +[[package]] +name = "rustc-demangle" +version = "0.1.24" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "719b953e2095829ee67db738b3bfa9fa368c94900df327b3f07fe6e794d2fe1f" [[package]] name = "rustc-hash" @@ -1124,31 +1518,31 @@ checksum = "08d43f7aa6b08d49f382cde6a7982047c3426db949b1424bc4b7ec9ae12c6ce2" [[package]] name = "rustc_version" -version = "0.4.0" +version = "0.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bfa0f585226d2e68097d4f95d113b15b83a82e819ab25717ec0590d9584ef366" +checksum = "cfcb3a22ef46e85b45de6ee7e79d063319ebb6594faafcf1c225ea92ab6e9b92" dependencies = [ "semver", ] [[package]] name = "rustix" -version = "0.38.31" +version = "0.38.37" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6ea3e1a662af26cd7a3ba09c0297a31af215563ecf42817c98df621387f4e949" +checksum = "8acb788b847c24f28525660c4d7758620a7210875711f79e7f663cc152726811" dependencies = [ - "bitflags 2.5.0", + "bitflags 2.6.0", "errno", "libc", "linux-raw-sys", - "windows-sys", + "windows-sys 0.52.0", ] [[package]] name = "rustversion" -version = "1.0.14" +version = "1.0.18" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7ffc183a10b4478d04cbbbfc96d0873219d962dd5accaff2ffbd4ceb7df837f4" +checksum = "0e819f2bc632f285be6d7cd36e25940d45b2391dd6d9b939e79de557f7014248" [[package]] name = "rusty-fork" @@ -1164,9 +1558,9 @@ dependencies = [ [[package]] name = "ryu" -version = "1.0.17" +version = "1.0.18" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e86697c916019a8588c99b5fac3cead74ec0b4b819707a682fd4d23fa0ce1ba1" +checksum = "f3cb5ba0dc43242ce17de99c180e96db90b235b8a9fdc9543c96d2209116bd9f" [[package]] name = "same-file" @@ -1177,43 +1571,73 @@ dependencies = [ "winapi-util", ] +[[package]] +name = "scroll" +version = "0.10.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fda28d4b4830b807a8b43f7b0e6b5df875311b3e7621d84577188c175b6ec1ec" +dependencies = [ + "scroll_derive", +] + +[[package]] +name = "scroll_derive" +version = "0.10.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "aaaae8f38bb311444cfb7f1979af0bc9240d95795f75f9ceddf6a59b79ceffa0" +dependencies = [ + "proc-macro2", + "quote", + "syn 1.0.109", +] + [[package]] name = "semver" -version = "1.0.22" +version = "1.0.23" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "92d43fe69e652f3df9bdc2b85b2854a0825b86e4fb76bc44d945137d053639ca" +checksum = "61697e0a1c7e512e84a621326239844a24d8207b4669b41bc18b32ea5cbf988b" [[package]] name = "serde" -version = "1.0.197" +version = "1.0.213" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3fb1c873e1b9b056a4dc4c0c198b24c3ffa059243875552b2bd0933b1aee4ce2" +checksum = "3ea7893ff5e2466df8d720bb615088341b295f849602c6956047f8f80f0e9bc1" dependencies = [ "serde_derive", ] [[package]] name = "serde_derive" -version = "1.0.197" +version = "1.0.213" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7eb0b34b42edc17f6b7cac84a52a1c5f0e1bb2227e997ca9011ea3dd34e8610b" +checksum = "7e85ad2009c50b58e87caa8cd6dac16bdf511bbfb7af6c33df902396aa480fa5" dependencies = [ "proc-macro2", "quote", - "syn", + "syn 2.0.82", ] [[package]] name = "serde_json" -version = "1.0.114" +version = "1.0.132" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c5f09b1bd632ef549eaa9f60a1f8de742bdbc698e6cee2095fc84dde5f549ae0" +checksum = "d726bfaff4b320266d395898905d0eba0345aae23b54aee3a737e260fd46db03" dependencies = [ "itoa", + "memchr", "ryu", "serde", ] +[[package]] +name = "sharded-slab" +version = "0.1.7" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f40ca3c46823713e0d4209592e8d6e826aa57e928f09752619fc696c499637f6" +dependencies = [ + "lazy_static", +] + [[package]] name = "shlex" version = "1.3.0" @@ -1227,6 +1651,12 @@ dependencies = [ "nix", ] +[[package]] +name = "smallvec" +version = "1.13.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3c5e1a9a646d36c3599cd173a41282daf47c44583ad367b8e6837255952e5c67" + [[package]] name = "static_assertions" version = "1.1.0" @@ -1240,36 +1670,77 @@ dependencies = [ "proptest", ] +[[package]] +name = "strsim" +version = "0.8.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8ea5119cdb4c55b55d432abb513a0429384878c15dde60cc77b1c99de1a95a6a" + [[package]] name = "strsim" version = "0.11.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7da8b5736845d9f2fcb837ea5d9e2628564b3b043a70948a3f0b778838c5fb4f" +[[package]] +name = "structopt" +version = "0.3.26" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0c6b5c64445ba8094a6ab0c3cd2ad323e07171012d9c98b0b15651daf1787a10" +dependencies = [ + "clap 2.34.0", + "lazy_static", + "structopt-derive", +] + +[[package]] +name = "structopt-derive" +version = "0.4.18" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "dcb5ae327f9cc13b68763b5749770cb9e048a99bd9dfdfa58d0cf05d5f64afe0" +dependencies = [ + "heck 0.3.3", + "proc-macro-error", + "proc-macro2", + "quote", + "syn 1.0.109", +] + [[package]] name = "strum" -version = "0.25.0" +version = "0.26.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "290d54ea6f91c969195bdbcd7442c8c2a2ba87da8bf60a7ee86a235d4bc1e125" +checksum = "8fec0f0aef304996cf250b31b5a10dee7980c85da9d759361292b8bca5a18f06" [[package]] name = "strum_macros" -version = "0.25.3" +version = "0.26.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "23dc1fa9ac9c169a78ba62f0b841814b7abae11bdd047b9c58f893439e309ea0" +checksum = "4c6bee85a5a24955dc440386795aa378cd9cf82acd5f764469152d2270e581be" dependencies = [ - "heck 0.4.1", + "heck 0.5.0", "proc-macro2", "quote", "rustversion", - "syn", + "syn 2.0.82", ] [[package]] name = "syn" -version = "2.0.58" +version = "1.0.109" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "44cfb93f38070beee36b3fef7d4f5a16f27751d94b187b666a5cc5e9b0d30687" +checksum = "72b64191b275b66ffe2469e8af2c1cfe3bafa67b529ead792a6d0160888b4237" +dependencies = [ + "proc-macro2", + "quote", + "unicode-ident", +] + +[[package]] +name = "syn" +version = "2.0.82" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "83540f837a8afc019423a8edb95b52a8effe46957ee402287f4292fae35be021" dependencies = [ "proc-macro2", "quote", @@ -1278,34 +1749,54 @@ dependencies = [ [[package]] name = "tempfile" -version = "3.10.1" +version = "3.13.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "85b77fafb263dd9d05cbeac119526425676db3784113aa9295c88498cbf8bff1" +checksum = "f0f2c9fc62d0beef6951ccffd757e241266a2c833136efbe35af6cd2567dca5b" dependencies = [ "cfg-if", "fastrand", + "once_cell", "rustix", - "windows-sys", + "windows-sys 0.59.0", +] + +[[package]] +name = "textwrap" +version = "0.11.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d326610f408c7a4eb6f51c37c330e496b08506c9457c9d34287ecc38809fb060" +dependencies = [ + "unicode-width", ] [[package]] name = "thiserror" -version = "1.0.58" +version = "1.0.65" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "03468839009160513471e86a034bb2c5c0e4baae3b43f79ffc55c4a5427b3297" +checksum = "5d11abd9594d9b38965ef50805c5e469ca9cc6f197f883f717e0269a3057b3d5" dependencies = [ "thiserror-impl", ] [[package]] name = "thiserror-impl" -version = "1.0.58" +version = "1.0.65" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c61f3ba182994efc43764a46c018c347bc492c79f024e705f46567b418f6d4f7" +checksum = "ae71770322cbd277e69d762a16c444af02aa0575ac0d174f0b9562d3b37f8602" dependencies = [ "proc-macro2", "quote", - "syn", + "syn 2.0.82", +] + +[[package]] +name = "thread_local" +version = "1.1.8" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8b9ef9bad013ada3808854ceac7b46812a6465ba368859a37e2100283d2d719c" +dependencies = [ + "cfg-if", + "once_cell", ] [[package]] @@ -1315,8 +1806,7 @@ dependencies = [ "anyhow", "arrow", "cells", - "itertools", - "libtiledb", + "itertools 0.13.0", "num-traits", "paste", "proptest", @@ -1326,6 +1816,7 @@ dependencies = [ "tiledb-common", "tiledb-pod", "tiledb-sys", + "tiledb-sys-cfg", "tiledb-utils", "uri", ] @@ -1350,7 +1841,7 @@ dependencies = [ name = "tiledb-pod" version = "0.1.0" dependencies = [ - "itertools", + "itertools 0.13.0", "num-traits", "proptest", "serde", @@ -1370,7 +1861,7 @@ version = "0.1.0" dependencies = [ "proc-macro2", "quote", - "syn", + "syn 2.0.82", ] [[package]] @@ -1381,17 +1872,30 @@ version = "0.1.0" name = "tiledb-query-adapters" version = "0.1.0" dependencies = [ - "libtiledb", "tiledb-api", "tiledb-common", + "tiledb-sys-cfg", ] [[package]] name = "tiledb-sys" version = "0.1.0" dependencies = [ - "libtiledb", + "armerge", + "bindgen 0.70.1", + "cmake", + "pkg-config", + "regex", + "thiserror", "tiledb-sys-defs", + "tiledb-utils", +] + +[[package]] +name = "tiledb-sys-cfg" +version = "0.1.0" +dependencies = [ + "tiledb-sys", ] [[package]] @@ -1408,6 +1912,39 @@ dependencies = [ "tiledb-proc-macro", ] +[[package]] +name = "time" +version = "0.3.36" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5dfd88e563464686c916c7e46e623e520ddc6d79fa6641390f2e3fa86e83e885" +dependencies = [ + "deranged", + "itoa", + "libc", + "num-conv", + "num_threads", + "powerfmt", + "serde", + "time-core", + "time-macros", +] + +[[package]] +name = "time-core" +version = "0.1.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ef927ca75afb808a4d64dd374f00a2adf8d0fcff8e7b184af886c3c87ec4a3f3" + +[[package]] +name = "time-macros" +version = "0.2.18" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3f252a68540fde3a3877aeea552b832b40ab9a69e318efd078774a01ddee1ccf" +dependencies = [ + "num-conv", + "time-core", +] + [[package]] name = "tiny-keccak" version = "2.0.2" @@ -1417,6 +1954,68 @@ dependencies = [ "crunchy", ] +[[package]] +name = "tracing" +version = "0.1.40" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c3523ab5a71916ccf420eebdf5521fcef02141234bbc0b8a49f2fdc4544364ef" +dependencies = [ + "pin-project-lite", + "tracing-attributes", + "tracing-core", +] + +[[package]] +name = "tracing-attributes" +version = "0.1.27" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "34704c8d6ebcbc939824180af020566b01a7c01f80641264eba0999f6c2b6be7" +dependencies = [ + "proc-macro2", + "quote", + "syn 2.0.82", +] + +[[package]] +name = "tracing-core" +version = "0.1.32" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c06d3da6113f116aaee68e4d601191614c9053067f9ab7f6edbcb161237daa54" +dependencies = [ + "once_cell", + "valuable", +] + +[[package]] +name = "tracing-log" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ee855f1f400bd0e5c02d150ae5de3840039a3f54b025156404e34c23c03f47c3" +dependencies = [ + "log", + "once_cell", + "tracing-core", +] + +[[package]] +name = "tracing-subscriber" +version = "0.3.18" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ad0f048c97dbd9faa9b7df56362b8ebcaa52adb06b498c050d2f4e32f90a7a8b" +dependencies = [ + "matchers", + "nu-ansi-term", + "once_cell", + "regex", + "sharded-slab", + "smallvec", + "thread_local", + "time", + "tracing", + "tracing-core", + "tracing-log", +] + [[package]] name = "unarray" version = "0.1.4" @@ -1425,15 +2024,21 @@ checksum = "eaea85b334db583fe3274d12b4cd1880032beab409c0d774be044d4480ab9a94" [[package]] name = "unicode-ident" -version = "1.0.12" +version = "1.0.13" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e91b56cd4cadaeb79bbf1a5645f6b4f8dc5bde8834ad5894a8db35fda9efa1fe" + +[[package]] +name = "unicode-segmentation" +version = "1.12.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3354b9ac3fae1ff6755cb6db53683adb661634f67557942dea4facebec0fee4b" +checksum = "f6ccf251212114b54433ec949fd6a7841275f9ada20dddd2f29e9ceea4501493" [[package]] name = "unicode-width" -version = "0.1.11" +version = "0.1.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e51733f11c9c4f72aa0c160008246859e340b00807569a0da0e7a1079b27ba85" +checksum = "7dd6e30e90baa6f72411720665d41d89b9a3d039dc45b8faea1ddd07f617f6af" [[package]] name = "uri" @@ -1445,15 +2050,27 @@ dependencies = [ [[package]] name = "utf8parse" -version = "0.2.1" +version = "0.2.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "711b9620af191e0cdc7468a8d14e709c3dcdb115b36f838e601583af800a370a" +checksum = "06abde3611657adf66d383f00b093d7faecc7fa57071cce2578660c9f1010821" + +[[package]] +name = "valuable" +version = "0.1.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "830b7e5d4d90034032940e4ace0d9a9a057e7a45cd94e6c007832e39edb82f6d" + +[[package]] +name = "vec_map" +version = "0.8.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f1bddf1187be692e79c5ffeab891132dfb0f236ed36a43c7ed39f1165ee20191" [[package]] name = "version_check" -version = "0.9.4" +version = "0.9.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "49874b5167b65d7193b8aba1567f5c7d93d001cafc34600cee003eda787e483f" +checksum = "0b928f33d975fc6ad9f86c8f283853ad26bdd5b10b7f1542aa2fa15e2289105a" [[package]] name = "wait-timeout" @@ -1482,34 +2099,35 @@ checksum = "9c8d87e72b64a3b4db28d11ce29237c246188f4f51057d65a7eab63b7987e423" [[package]] name = "wasm-bindgen" -version = "0.2.92" +version = "0.2.95" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4be2531df63900aeb2bca0daaaddec08491ee64ceecbee5076636a3b026795a8" +checksum = "128d1e363af62632b8eb57219c8fd7877144af57558fb2ef0368d0087bddeb2e" dependencies = [ "cfg-if", + "once_cell", "wasm-bindgen-macro", ] [[package]] name = "wasm-bindgen-backend" -version = "0.2.92" +version = "0.2.95" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "614d787b966d3989fa7bb98a654e369c762374fd3213d212cfc0251257e747da" +checksum = "cb6dd4d3ca0ddffd1dd1c9c04f94b868c37ff5fac97c30b97cff2d74fce3a358" dependencies = [ "bumpalo", "log", "once_cell", "proc-macro2", "quote", - "syn", + "syn 2.0.82", "wasm-bindgen-shared", ] [[package]] name = "wasm-bindgen-macro" -version = "0.2.92" +version = "0.2.95" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a1f8823de937b71b9460c0c34e25f3da88250760bec0ebac694b49997550d726" +checksum = "e79384be7f8f5a9dd5d7167216f022090cf1f9ec128e6e6a482a2cb5c5422c56" dependencies = [ "quote", "wasm-bindgen-macro-support", @@ -1517,22 +2135,22 @@ dependencies = [ [[package]] name = "wasm-bindgen-macro-support" -version = "0.2.92" +version = "0.2.95" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e94f17b526d0a461a191c78ea52bbce64071ed5c04c9ffe424dcb38f74171bb7" +checksum = "26c6ab57572f7a24a4985830b120de1594465e5d500f24afe89e16b4e833ef68" dependencies = [ "proc-macro2", "quote", - "syn", + "syn 2.0.82", "wasm-bindgen-backend", "wasm-bindgen-shared", ] [[package]] name = "wasm-bindgen-shared" -version = "0.2.92" +version = "0.2.95" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "af190c94f2773fdb3729c55b007a722abb5384da03bc0986df4c289bf5567e96" +checksum = "65fc09f10666a9f147042251e0dda9c18f166ff7de300607007e96bdebc1068d" [[package]] name = "which" @@ -1564,11 +2182,11 @@ checksum = "ac3b87c63620426dd9b991e5ce0329eff545bccbbb34f3be09ff6fb6ab51b7b6" [[package]] name = "winapi-util" -version = "0.1.6" +version = "0.1.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f29e6f9198ba0d26b4c9f07dbe6f9ed633e1f3d5b8b414090084349e46a52596" +checksum = "cf221c93e13a30d793f7645a0e7762c55d169dbb0a49671918a2319d289b10bb" dependencies = [ - "winapi", + "windows-sys 0.59.0", ] [[package]] @@ -1595,15 +2213,25 @@ dependencies = [ "windows-targets", ] +[[package]] +name = "windows-sys" +version = "0.59.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1e38bc4d79ed67fd075bcc251a1c39b32a1776bbe92e5bef1f0bf1f8c531853b" +dependencies = [ + "windows-targets", +] + [[package]] name = "windows-targets" -version = "0.52.4" +version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7dd37b7e5ab9018759f893a1952c9420d060016fc19a472b4bb20d1bdd694d1b" +checksum = "9b724f72796e036ab90c1021d4780d4d3d648aca59e491e6b98e725b84e99973" dependencies = [ "windows_aarch64_gnullvm", "windows_aarch64_msvc", "windows_i686_gnu", + "windows_i686_gnullvm", "windows_i686_msvc", "windows_x86_64_gnu", "windows_x86_64_gnullvm", @@ -1612,62 +2240,69 @@ dependencies = [ [[package]] name = "windows_aarch64_gnullvm" -version = "0.52.4" +version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bcf46cf4c365c6f2d1cc93ce535f2c8b244591df96ceee75d8e83deb70a9cac9" +checksum = "32a4622180e7a0ec044bb555404c800bc9fd9ec262ec147edd5989ccd0c02cd3" [[package]] name = "windows_aarch64_msvc" -version = "0.52.4" +version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "da9f259dd3bcf6990b55bffd094c4f7235817ba4ceebde8e6d11cd0c5633b675" +checksum = "09ec2a7bb152e2252b53fa7803150007879548bc709c039df7627cabbd05d469" [[package]] name = "windows_i686_gnu" -version = "0.52.4" +version = "0.52.6" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8e9b5ad5ab802e97eb8e295ac6720e509ee4c243f69d781394014ebfe8bbfa0b" + +[[package]] +name = "windows_i686_gnullvm" +version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b474d8268f99e0995f25b9f095bc7434632601028cf86590aea5c8a5cb7801d3" +checksum = "0eee52d38c090b3caa76c563b86c3a4bd71ef1a819287c19d586d7334ae8ed66" [[package]] name = "windows_i686_msvc" -version = "0.52.4" +version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1515e9a29e5bed743cb4415a9ecf5dfca648ce85ee42e15873c3cd8610ff8e02" +checksum = "240948bc05c5e7c6dabba28bf89d89ffce3e303022809e73deaefe4f6ec56c66" [[package]] name = "windows_x86_64_gnu" -version = "0.52.4" +version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5eee091590e89cc02ad514ffe3ead9eb6b660aedca2183455434b93546371a03" +checksum = "147a5c80aabfbf0c7d901cb5895d1de30ef2907eb21fbbab29ca94c5b08b1a78" [[package]] name = "windows_x86_64_gnullvm" -version = "0.52.4" +version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "77ca79f2451b49fa9e2af39f0747fe999fcda4f5e241b2898624dca97a1f2177" +checksum = "24d5b23dc417412679681396f2b49f3de8c1473deb516bd34410872eff51ed0d" [[package]] name = "windows_x86_64_msvc" -version = "0.52.4" +version = "0.52.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "32b752e52a2da0ddfbdbcc6fceadfeede4c939ed16d13e648833a61dfb611ed8" +checksum = "589f6da84c646204747d1270a2a5661ea66ed1cced2631d546fdfb155959f9ec" [[package]] name = "zerocopy" -version = "0.7.32" +version = "0.7.35" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "74d4d3961e53fa4c9a25a8637fc2bfaf2595b3d3ae34875568a5cf64787716be" +checksum = "1b9b4fd18abc82b8136838da5d50bae7bdea537c574d8dc1a34ed098d6c166f0" dependencies = [ + "byteorder", "zerocopy-derive", ] [[package]] name = "zerocopy-derive" -version = "0.7.32" +version = "0.7.35" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9ce1b18ccd8e73a9321186f97e46f9f04b778851177567b1975109d26a08d2a6" +checksum = "fa4f8080344d4671fb4e831a13ad1e68092748387dfc4f55e356242fae12ce3e" dependencies = [ "proc-macro2", "quote", - "syn", + "syn 2.0.82", ] diff --git a/Cargo.toml b/Cargo.toml index ed59f05c..9da06854 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -3,11 +3,11 @@ resolver = "2" members = [ "tiledb/api", "tiledb/common", - "tiledb/libtiledb", "tiledb/pod", "tiledb/proc-macro", "tiledb/queries", "tiledb/sys", + "tiledb/sys-cfg", "tiledb/sys-defs", "tiledb/utils", "test-utils/cells", @@ -33,14 +33,17 @@ version = "0.1.0" [workspace.dependencies] anyhow = "1.0" +armerge = "2" arrow = { version = "52.0.0", features = ["prettyprint"] } arrow-schema = { version = "52.0.0" } +bindgen = "0.70" cells = { path = "test-utils/cells", version = "0.1.0" } +cmake = "0.1" itertools = "0" -libtiledb = { path = "tiledb/libtiledb", version = "0.1.0" } num-traits = "0.2" paste = "1.0" proptest = { version = "1.0.0" } +regex = "1" serde = { version = "1", features = ["derive"] } serde_json = { version = "1", features = ["float_roundtrip"] } signal = { path = "test-utils/signal", version = "0.1.0" } @@ -53,6 +56,7 @@ tiledb-pod = { path = "tiledb/pod", version = "0.1.0" } tiledb-proc-macro = { path = "tiledb/proc-macro", version = "0.1.0" } tiledb-proptest-config = { path = "test-utils/proptest-config", version = "0.1.0" } tiledb-sys = { path = "tiledb/sys", version = "0.1.0" } +tiledb-sys-cfg = { path = "tiledb/sys-cfg", version = "0.1.0" } tiledb-sys-defs = { path = "tiledb/sys-defs", version = "0.1.0" } tiledb-test-utils = { path = "tiledb/test-utils", version = "0.1.0" } tiledb-utils = { path = "tiledb/utils", version = "0.1.0" } diff --git a/README.md b/README.md index dbc9a98d..623da214 100644 --- a/README.md +++ b/README.md @@ -1,28 +1,110 @@ TileDB - Rust Bindings === -Rust bindings for TileDB. (currently covering ~45% of the TileDB C API). +Rust bindings for TileDB. (currently covering ~56% of the TileDB C API). Getting Started --- -For the time being, these bindings require that libtiledb be installed into -`/opt/tiledb`. Eventually we'll fix the linking issues to not require this -but for now it was the easiest to get working with Cargo. +Using these bindings requires having a copy of libtiledb installed on your +system where `pkg-config` can find it. There are many different ways this +can be accomplished. Building from source is shown below for clarity. For other +installation methods, see the TileDB documentation. -On macOS and Linux, these quick instructions should be enough to get -`cargo test` running: +In this example, I'm using `/opt/tiledb` for the installation location. You are +free to use any path you so desire. ```sh -$ cd ~/wherever/you/keep/code -$ git clone https://github.com/TileDB-Inc/TileDB -$ cd TileDB +$ sudo mkdir -p /opt/tiledb +$ sudo chown your_username /opt/tiledb +$ git clone https://github.com/TileDB-Inc/TileDB tiledb +$ cd ~/tiledb/ $ mkdir build $ cd build -$ ../bootstrap --enable=ccache,serialization,debug --prefix=/opt/tiledb -$ make -j$(nproc) && make -C tiledb -j$(nproc) install -$ cd ~/wherever/you/keep/code -$ git clone https://github.com/TileDB-Inc/tiledb-rs -$ cd tiled-rs -$ cargo test +$ ../bootstrap --enable=s3,serialization,debug --prefix=/opt/tiledb +$ make -j$(nproc) +$ make -j$(nproc) install ``` + +Once built, make sure that your `PKG_CONFIG_PATH` includes the path where +libtiledb was installed: + +```sh +if [[ ":$PKG_CONFIG_PATH:" != *":/opt/tiledb/lib/pkgconfig:"* ]]; then + export "PKG_CONFIG_PATH=${PKG_CONFIG_PATH:+${PKG_CONFIG_PATH}:}/opt/tiledb/lib/pkgconfig" +fi +``` + +> [!NOTE] +> The snippet above likely looks overly complicated for setting an environment +> variable. The reason for this is that `cargo` will invalidate cached builds +> if any of the inputs change, including the value of `PKG_CONFIG_PATH`. The +> shell weirdness above just ensures that we don't add duplicates to the path +> which can cause unnecessary rebuilds of anything that transitively depends +> on `tiledb-sys`. +> +> An easy way to check if your Rust environment is causing a bunch of +> unnecessary build churn is by using sub-shells: +> +> ```sh +> $ cargo build +> $ zsh # or whatever your shell happens to be +> $ cargo build +> ``` +> +> If that second `cargo build` command causes anything at all to be built, you +> likely have something in your environment that's being mutated on every +> invocation. + +Finally, we can check that everything compiled and can be discovered by +`pkg-config`: + +```sh +$ pkg-config tiledb --libs +-L/opt/tiledb/lib -ltiledb +``` + +Creating Static Binaries +--- + +> [!WARNING] +> It is highly recommended to use the dynamic linking as described above unless +> you are specifically working on creating statically linked release builds +> for distribution. Building statically can take on the order of thirty minutes +> and these builds are easily invalidated requiring complete rebuilds. This ends +> up leading to an extremely poor developer experience. + +To build libtiledb statically, simply set the `TILEDB_SYS_STATIC` environment +variable to anything. + +```sh +$ export TILEDB_SYS_STATIC=true +$ cargo build +``` + +> [!NOTE] +> If you are encountering "weird" failures in CI where the libtiledb build +> appears to error out for no reason, it is likely that `cmake` is being too +> aggressive in parallelizing compilation jobs. See the `TILEDB_SYS_JOBS` +> environment variable below. + +Controlling Static Builds +--- + +There are a few environment variables you can use to attempt to speed up static +builds. + +* `TILEDB_SYS_JOBS` - If this environment variable is set, it is passed as + `-j${TILEDB_SYS_JOBS}` to `cmake`. This can also be useful to limit + parallelization in CI where the compiler can end up starving the CI runner + of RAM which can result in mysteriously failed builds. +* `TILEDB_SYS_CCACHE` - You can set this to anything to tell libtiledb to search + for either `sccache` or `ccache` while building. Consult documentation for + either of those tools if you wish to install them. You'll likely want to use + `sccache`. +* `VCPKG_ROOT` - Setting up an external installation of `vcpkg` will ensure that + libtiledb dependencies are cached which speeds up builds tremendously. Consult + the `vcpkg` documentation for specifics. Though the gist of it is to clone the + vcpkg repository, run the bootstrap script to download binaries, then export + the `VCPKG_ROOT` environment variable to point at that directory. + diff --git a/tiledb/api/Cargo.toml b/tiledb/api/Cargo.toml index 64a21dca..a517ac21 100644 --- a/tiledb/api/Cargo.toml +++ b/tiledb/api/Cargo.toml @@ -32,7 +32,7 @@ tiledb-utils = { workspace = true } uri = { workspace = true } [build-dependencies] -libtiledb = { workspace = true } +tiledb-sys-cfg = { workspace = true } [features] default = [] diff --git a/tiledb/api/build.rs b/tiledb/api/build.rs index 8decd6d7..82ad8ae6 100644 --- a/tiledb/api/build.rs +++ b/tiledb/api/build.rs @@ -1,3 +1,3 @@ fn main() { - libtiledb::rpath(); + tiledb_sys_cfg::rpath(); } diff --git a/tiledb/api/src/query/read/aggregate/mod.rs b/tiledb/api/src/query/read/aggregate/mod.rs index 312b3749..64bfe71d 100644 --- a/tiledb/api/src/query/read/aggregate/mod.rs +++ b/tiledb/api/src/query/read/aggregate/mod.rs @@ -349,7 +349,7 @@ pub trait AggregateQueryBuilder: QueryBuilder { ) })?; } else { - let c_field_name: *const i8 = + let c_field_name = handle.field_name.as_ref().unwrap().as_c_str().as_ptr(); match handle.function { AggregateFunction::Count => unreachable!( diff --git a/tiledb/api/src/string.rs b/tiledb/api/src/string.rs index e5231e85..9c6d65f5 100644 --- a/tiledb/api/src/string.rs +++ b/tiledb/api/src/string.rs @@ -34,15 +34,11 @@ impl TDBString { } pub fn to_string(&self) -> TileDBResult { - let mut c_str: *const i8 = out_ptr!(); + let mut c_str = out_ptr!(); let mut c_len: usize = 0; let res = unsafe { - ffi::tiledb_string_view( - *self.raw, - &mut c_str as *mut *const i8, - &mut c_len, - ) + ffi::tiledb_string_view(*self.raw, &mut c_str, &mut c_len) }; if res == ffi::TILEDB_OK { diff --git a/tiledb/libtiledb/src/lib.rs b/tiledb/libtiledb/src/lib.rs deleted file mode 100644 index 847d481c..00000000 --- a/tiledb/libtiledb/src/lib.rs +++ /dev/null @@ -1,30 +0,0 @@ -//! Build dependency for crates using tiledb. -//! -//! Provides functions which can be used in a crate's build script -//! to add `tiledb` as a dynamically linked and loaded library. - -/// Emits the cargo build command `cargo:rustc-link-lib=tiledb`. -/// -/// This should be called only from the lowest-level crate which depdends -/// on symbols from `libtiledb`. Crates which depend on the `tiledb-api` -/// do not need to call this. -pub fn link() { - pkg_config::Config::new() - .atleast_version("2.20.0") - .probe("tiledb") - .expect("Build-time TileDB library missing, version >= 2.4 not found."); - println!("cargo:rustc-link-lib=tiledb"); -} - -/// Emits cargo build commands to add `libtiledb.so` to a compiled executable's rpath. -/// -/// This should be called from the build script of any library or executable which -/// depends on `tiledb-api`, whether directly or indirectly. -pub fn rpath() { - let libdir = pkg_config::get_variable("tiledb", "libdir") - .expect("Missing tiledb dependency."); - println!( - "cargo:rustc-link-arg=-Wl,-rpath,@loader_path,-rpath,$ORIGIN,-rpath,{}", - libdir - ); -} diff --git a/tiledb/queries/Cargo.toml b/tiledb/queries/Cargo.toml index 7bee4fea..852c27ad 100644 --- a/tiledb/queries/Cargo.toml +++ b/tiledb/queries/Cargo.toml @@ -9,4 +9,4 @@ tiledb-api = { workspace = true } tiledb-common = { workspace = true } [build-dependencies] -libtiledb = { workspace = true } +tiledb-sys-cfg = { workspace = true } diff --git a/tiledb/queries/build.rs b/tiledb/queries/build.rs index 4f6eff99..82ad8ae6 100644 --- a/tiledb/queries/build.rs +++ b/tiledb/queries/build.rs @@ -1,3 +1,3 @@ fn main() { - libtiledb::rpath() + tiledb_sys_cfg::rpath(); } diff --git a/tiledb/libtiledb/Cargo.toml b/tiledb/sys-cfg/Cargo.toml similarity index 64% rename from tiledb/libtiledb/Cargo.toml rename to tiledb/sys-cfg/Cargo.toml index c07f7c96..b6d2a54a 100644 --- a/tiledb/libtiledb/Cargo.toml +++ b/tiledb/sys-cfg/Cargo.toml @@ -1,8 +1,8 @@ [package] -name = "libtiledb" +name = "tiledb-sys-cfg" edition.workspace = true rust-version.workspace = true version.workspace = true [dependencies] -pkg-config = { workspace = true } +tiledb-sys = { workspace = true } diff --git a/tiledb/sys-cfg/build.rs b/tiledb/sys-cfg/build.rs new file mode 100644 index 00000000..0c714def --- /dev/null +++ b/tiledb/sys-cfg/build.rs @@ -0,0 +1,13 @@ +fn main() { + let linkage = + std::env::var("DEP_TILEDB_LINKAGE").expect("Missing DEP_TILEDB_LIKAGE"); + if linkage == "dynamic" { + let libdir = std::env::var("DEP_TILEDB_LIBDIR") + .expect("Missing DEP_TILEDB_LIBDIR"); + println!("cargo::rustc-env=TILEDB_RPATH={}", libdir); + } else if linkage == "static" { + println!("cargo::rustc-env=TILEDB_RPATH="); + } else { + panic!("Unknown linkage of tiledb-sys: {linkage}") + } +} diff --git a/tiledb/sys-cfg/src/lib.rs b/tiledb/sys-cfg/src/lib.rs new file mode 100644 index 00000000..03c63183 --- /dev/null +++ b/tiledb/sys-cfg/src/lib.rs @@ -0,0 +1,23 @@ +/// Configure rpath for crates that depend on tiledb-sys +/// +/// Any crate that depends on tiledb-sys should call this function in its +/// build.rs so that it rustc is correctly configured. Note that for anyone +/// building static binaries, this is a no-op when tiledb-sys was built +/// statically. +pub fn rpath() { + let libdir = env!("TILEDB_RPATH"); + if libdir.is_empty() { + return; + } + + let parts = [ + "cargo::rustc-link-arg=", + "-Wl,", + "-rpath,@loader_path,", + "-rpath,$ORIGIN,", + "-rpath,", + libdir, + ]; + + println!("{}", parts.join("")); +} diff --git a/tiledb/sys/Cargo.toml b/tiledb/sys/Cargo.toml index d69f0ae8..51c73062 100644 --- a/tiledb/sys/Cargo.toml +++ b/tiledb/sys/Cargo.toml @@ -2,9 +2,17 @@ name = "tiledb-sys" version = { workspace = true } edition = { workspace = true } +build = "build/main.rs" +links = "tiledb" [dependencies] tiledb-sys-defs = { workspace = true } [build-dependencies] -libtiledb = { workspace = true } +armerge = { workspace = true } +bindgen = { workspace = true } +cmake = { workspace = true } +pkg-config = { workspace = true } +regex = { workspace = true } +tiledb-utils = { workspace = true } +thiserror = { workspace = true } diff --git a/tiledb/sys/build.rs b/tiledb/sys/build.rs deleted file mode 100644 index 9b259164..00000000 --- a/tiledb/sys/build.rs +++ /dev/null @@ -1,4 +0,0 @@ -fn main() { - libtiledb::link(); - libtiledb::rpath(); -} diff --git a/tiledb/sys/build/compile.rs b/tiledb/sys/build/compile.rs new file mode 100644 index 00000000..c366f76c --- /dev/null +++ b/tiledb/sys/build/compile.rs @@ -0,0 +1,41 @@ +use crate::current_os; +use crate::error::Result; +use crate::utils; + +pub fn libtiledb() -> Result { + let build_dir = utils::build_dir(); + if build_dir.is_dir() { + let mut bundled = build_dir.clone(); + bundled.push("libtiledb_bundled.a"); + if bundled.is_file() { + return Ok(build_dir.display().to_string()); + } + } + + // N.B., you might think this should be `utils::build_dir()`, but the cmake + // crate appends `build` unconditionally so we have to go one directory up. + let out_dir = utils::out_dir(); + let git_dir = utils::git_dir(); + let mut builder = cmake::Config::new(&git_dir); + builder + .out_dir(out_dir) + .build_target("all") + .define("BUILD_SHARED_LIBS", "OFF") + .define("TILEDB_WERROR", "OFF") + .define("TILEDB_S3", "ON") + .define("TILEDB_SERIALIZATION", "ON"); + + if std::env::var("TILEDB_SYS_CCACHE").is_ok() { + builder.define("TILEDB_CCACHE", "ON"); + } + + if let Ok(num_jobs) = std::env::var("TILEDB_SYS_JOBS") { + builder.build_arg(format!("-j{}", num_jobs)); + } + + let mut dst = builder.build(); + dst.push("build"); + + current_os::merge_libraries(&dst)?; + Ok(dst.display().to_string()) +} diff --git a/tiledb/sys/build/current_os/linux.rs b/tiledb/sys/build/current_os/linux.rs new file mode 100644 index 00000000..b73b9339 --- /dev/null +++ b/tiledb/sys/build/current_os/linux.rs @@ -0,0 +1,116 @@ +#![cfg(target_os = "linux")] + +use std::io::Write; +use std::process::{Command, Stdio}; + +use crate::error::{Error, Result}; + +pub fn configure_rustc(_out: &str) -> Result<()> { + println!("cargo::rustc-link-lib=dylib=stdc++"); + + Ok(()) +} + +pub fn merge_libraries(build_dir: &std::path::Path) -> Result<()> { + let mut tdb = std::path::PathBuf::from(build_dir); + tdb.extend(["tiledb", "libtiledb.a"]); + if !tdb.is_file() { + panic!("Missing static library: {}", tdb.display()); + } + + let mut vcpkg_installed = std::path::PathBuf::from(build_dir); + vcpkg_installed.push("vcpkg_installed"); + if !vcpkg_installed.is_dir() { + panic!("Missing vcpkg_installed directory."); + } + + let paths = std::fs::read_dir(vcpkg_installed) + .expect("Error reading vcpkg_installed"); + + // Filter out the `vcpkg/` subdirectory and hopefully only one directory + // remains for us to care about. + let mut not_vcpkg_paths = Vec::new(); + for path in paths.flatten() { + if !path.path().is_dir() { + continue; + } + + let path = path.path(); + if path.file_name() == Some(std::ffi::OsStr::new("vcpkg")) { + continue; + } + + not_vcpkg_paths.push(path.display().to_string()); + } + + if not_vcpkg_paths.len() > 1 { + let paths = not_vcpkg_paths.join(", "); + panic!( + "Too many target triplet directories to choose from: {}", + paths + ); + } + + let path = if let Some(path) = not_vcpkg_paths.first() { + path.to_string() + } else { + panic!("Error locating `vcpkg_installed/${{triplet}}` directory."); + }; + + let mut lib_dir = std::path::PathBuf::from(build_dir); + assert!(lib_dir.is_dir()); + lib_dir.extend(["vcpkg_installed", &path, "lib"]); + if !lib_dir.is_dir() { + panic!( + "Missing directory vcpkg_installed/${{triplet}}/lib: {}", + lib_dir.display() + ); + } + + let paths = + std::fs::read_dir(lib_dir).expect("Error reading vcpkg lib directory."); + let mut libs = vec![tdb.display().to_string()]; + for path in paths.flatten() { + let path = path.path().display().to_string(); + if !path.ends_with(".a") { + continue; + } + libs.push(path); + } + + let mut output = std::path::PathBuf::from(build_dir); + output.extend(["libtiledb_bundled.a"]); + + // Generate our MRI script + let mut lines = Vec::new(); + lines.push(format!("create {}", output.display())); + for path in libs { + lines.push(format!("addlib {}", path)); + } + lines.push("save".to_string()); + lines.push("end".to_string()); + let lines = lines.join("\n"); + + let mut child = Command::new("ar") + .arg("-M") + .stdin(Stdio::piped()) + .stderr(Stdio::inherit()) + .stdout(Stdio::inherit()) + .spawn() + .map_err(|e| Error::IO("Error executing ar".to_string(), e))?; + + let stdin = child.stdin.as_mut().unwrap(); + stdin + .write_all(lines.as_bytes()) + .map_err(|e| Error::IO("Error writing stdin to ar".to_string(), e))?; + + let status = child + .wait() + .map_err(|e| Error::IO("Ar merge failed".to_string(), e))?; + + if !status.success() { + panic!("Error merging static libraries: {}", status); + } + + Ok(()) +} diff --git a/tiledb/sys/build/current_os/macos.rs b/tiledb/sys/build/current_os/macos.rs new file mode 100644 index 00000000..fdec7690 --- /dev/null +++ b/tiledb/sys/build/current_os/macos.rs @@ -0,0 +1,91 @@ +#![cfg(target_os = "macos")] + +use crate::error::Result; + +pub fn configure_rustc(_out: &str) -> Result<()> { + println!("cargo::rustc-link-lib=dylib=c++"); + println!("cargo::rustc-link-lib=framework=CoreFoundation"); + println!("cargo::rustc-link-lib=framework=Security"); + println!("cargo::rustc-link-lib=framework=SystemConfiguration"); + + Ok(()) +} + +pub fn merge_libraries(build_dir: &std::path::Path) -> Result<()> { + let mut tdb = std::path::PathBuf::from(build_dir); + tdb.extend(["tiledb", "libtiledb.a"]); + if !tdb.is_file() { + panic!("Missing libtiled: {}", tdb.display()); + } + + let mut vcpkg_installed = std::path::PathBuf::from(build_dir); + vcpkg_installed.push("vcpkg_installed"); + if !vcpkg_installed.is_dir() { + panic!("Missing vcpkg_installed directory."); + } + + let paths = std::fs::read_dir(vcpkg_installed) + .expect("Error reading vcpkg_installed"); + + // Filter out the `vcpkg/` subdirectory and hopefully only one directory + // remains for us to care about. + let mut not_vcpkg_paths = Vec::new(); + for path in paths.flatten() { + if !path.path().is_dir() { + continue; + } + + let path = path.path(); + if path.file_name() == Some(std::ffi::OsStr::new("vcpkg")) { + continue; + } + + not_vcpkg_paths.push(path.display().to_string()); + } + + if not_vcpkg_paths.len() > 1 { + let paths = not_vcpkg_paths.join(", "); + panic!( + "Too many target triplet directories to choose from: {}", + paths + ); + } + + let path = if let Some(path) = not_vcpkg_paths.first() { + path.to_string() + } else { + panic!("Error locating `vcpkg_installed/${{triplet}}` directory."); + }; + + let mut lib_dir = std::path::PathBuf::from(build_dir); + assert!(lib_dir.is_dir()); + lib_dir.extend(["vcpkg_installed", &path, "lib"]); + if !lib_dir.is_dir() { + panic!( + "Missing directory vcpkg_installed/${{triplet}}/lib: {}", + lib_dir.display() + ); + } + + let paths = + std::fs::read_dir(lib_dir).expect("Error reading vcpkg lib directory."); + let mut libs = vec![tdb.display().to_string()]; + for path in paths.flatten() { + let path = path.path().display().to_string(); + if !path.ends_with(".a") { + continue; + } + libs.push(path); + } + + let mut output = std::path::PathBuf::from(build_dir); + output.extend(["libtiledb_bundled.a"]); + + let merge = armerge::ArMerger::new_from_paths(&libs, &output) + .expect("Error creating library merger."); + merge + .merge_simple() + .expect("Error merging static libraries."); + + Ok(()) +} diff --git a/tiledb/sys/build/current_os/mod.rs b/tiledb/sys/build/current_os/mod.rs new file mode 100644 index 00000000..a717cde8 --- /dev/null +++ b/tiledb/sys/build/current_os/mod.rs @@ -0,0 +1,20 @@ +mod linux; +mod macos; +mod unsupported; +mod windows; + +#[cfg(target_os = "linux")] +pub use linux::*; + +#[cfg(target_os = "macos")] +pub use macos::*; + +#[cfg(target_os = "windows")] +pub use windows::*; + +#[cfg(not(any( + target_os = "linux", + target_os = "macos", + target_os = "windows" +)))] +pub use unsupported::*; diff --git a/tiledb/sys/build/current_os/unsupported.rs b/tiledb/sys/build/current_os/unsupported.rs new file mode 100644 index 00000000..a290db47 --- /dev/null +++ b/tiledb/sys/build/current_os/unsupported.rs @@ -0,0 +1,15 @@ +#![cfg(not(any( + target_os = "linux", + target_os = "macos", + target_os = "windows" +)))] + +use crate::error::Result; + +pub fn configure_rustc(_out: &str) -> Result<()> { + panic!("This operating system is not supported."); +} + +pub fn merge_libraries(build_dir: &std::path::Path) -> Result<()> { + panic!("This operating system is not supported."); +} diff --git a/tiledb/sys/build/current_os/windows.rs b/tiledb/sys/build/current_os/windows.rs new file mode 100644 index 00000000..14cf59a7 --- /dev/null +++ b/tiledb/sys/build/current_os/windows.rs @@ -0,0 +1,11 @@ +#![cfg(target_os = "windows")] + +use crate::error::Result; + +pub fn configure_rustc(_out: &str) -> Result<()> { + todo!("Add windows support."); +} + +pub fn merge_libraries(build_dir: &std::path::Path) -> Result<()> { + todo!("Add windows support."); +} diff --git a/tiledb/sys/build/error.rs b/tiledb/sys/build/error.rs new file mode 100644 index 00000000..d81410d3 --- /dev/null +++ b/tiledb/sys/build/error.rs @@ -0,0 +1,11 @@ +use thiserror::Error; + +#[derive(Debug, Error)] +pub enum Error { + #[error("Error accessing envrionment: {0}")] + Env(#[from] std::env::VarError), + #[error("IO Error: {0} failed due to: {1}")] + IO(String, std::io::Error), +} + +pub type Result = std::result::Result; diff --git a/tiledb/sys/build/main.rs b/tiledb/sys/build/main.rs new file mode 100644 index 00000000..e6d7598b --- /dev/null +++ b/tiledb/sys/build/main.rs @@ -0,0 +1,48 @@ +mod compile; +mod current_os; +mod error; +mod repo; +mod utils; + +fn configure_static() -> error::Result<()> { + repo::update()?; + let libdir = compile::libtiledb()?; + + // Configure linking + println!("cargo::metadata=LINKAGE=static"); + println!("cargo::rustc-link-search=native={}", libdir); + println!("cargo::rustc-link-lib=static=tiledb_bundled"); + + // Add any extra OS specific config + current_os::configure_rustc(&libdir).expect("Error configuring rustc"); + + Ok(()) +} + +fn configure_dynamic() -> error::Result<()> { + pkg_config::Config::new() + .atleast_version("2.20.0") + .probe("tiledb") + .expect("Build-time TileDB library missing, version >= 2.4 not found."); + + let libdir = pkg_config::get_variable("tiledb", "libdir") + .expect("Missing tiledb dependency."); + + println!("cargo::metadata=LINKAGE=dynamic"); + println!("cargo::rustc-link-lib=tiledb"); + println!("cargo::metadata=LIBDIR={libdir}"); + + Ok(()) +} + +fn main() { + // Ensure that we rebuild things if either of our environment vairables + // have changed. + println!("cargo::rerun-if-env-changed=TILEDB_SYS_STATIC"); + + if std::env::var("TILEDB_SYS_STATIC").is_ok() { + configure_static().unwrap(); + } else { + configure_dynamic().unwrap(); + } +} diff --git a/tiledb/sys/build/repo.rs b/tiledb/sys/build/repo.rs new file mode 100644 index 00000000..31dc41d8 --- /dev/null +++ b/tiledb/sys/build/repo.rs @@ -0,0 +1,28 @@ +use std::process::{Command, Stdio}; + +use crate::error::{Error, Result}; +use crate::utils; + +/// Clone TileDB-Inc/TileDB into `target/repos/tiledb`. +pub fn update() -> Result<()> { + if utils::git_dir().is_dir() { + return Ok(()); + } + + let out_dir = utils::out_dir().display().to_string(); + let output = Command::new("git") + .arg("clone") + .arg("https://github.com/TileDB-Inc/TileDB") + .arg("git") + .current_dir(out_dir) + .stderr(Stdio::inherit()) + .stdout(Stdio::inherit()) + .output() + .map_err(|e| Error::IO("Error executing git".to_string(), e))?; + + if !output.status.success() { + panic!("Error cloning TileDB repository: {}", output.status); + } + + Ok(()) +} diff --git a/tiledb/sys/build/utils.rs b/tiledb/sys/build/utils.rs new file mode 100644 index 00000000..3387f029 --- /dev/null +++ b/tiledb/sys/build/utils.rs @@ -0,0 +1,16 @@ +pub fn out_dir() -> std::path::PathBuf { + let out_dir = std::env::var("OUT_DIR").expect("Cargo didn't set OUT_DIR"); + std::path::PathBuf::from(out_dir) +} + +pub fn git_dir() -> std::path::PathBuf { + let mut pbuf = out_dir(); + pbuf.push("git"); + pbuf +} + +pub fn build_dir() -> std::path::PathBuf { + let mut pbuf = out_dir(); + pbuf.push("build"); + pbuf +} diff --git a/tools/api-coverage/src/main.rs b/tools/api-coverage/src/main.rs index 3a41e9df..1fd95a30 100644 --- a/tools/api-coverage/src/main.rs +++ b/tools/api-coverage/src/main.rs @@ -34,7 +34,7 @@ struct Args { remapped: String, /// Path to the sys-defs crate - #[arg(short, long, default_value_t = String::from("tiledb/sys/defs"))] + #[arg(short, long, default_value_t = String::from("tiledb/sys-defs/src"))] defs: String, /// Path to the sys crate