Skip to content

Commit

Permalink
Release commit created with Cranko.
Browse files Browse the repository at this point in the history
+++ cranko-release-info-v1
[[projects]]
qnames = ["tectonic_xdv", "cargo"]
version = "0.2.0"
age = 5

[[projects]]
qnames = ["tectonic_errors", "cargo"]
version = "0.2.0"
age = 26

[[projects]]
qnames = ["tectonic_xetex_format", "cargo"]
version = "0.2.0"
age = 0

[[projects]]
qnames = ["tectonic_status_base", "cargo"]
version = "0.2.0"
age = 20

[[projects]]
qnames = ["tectonic_io_base", "cargo"]
version = "0.4.0"
age = 5

[[projects]]
qnames = ["tectonic_geturl", "cargo"]
version = "0.3.1"
age = 5

[[projects]]
qnames = ["tectonic_docmodel", "cargo"]
version = "0.1.2"
age = 5

[[projects]]
qnames = ["tectonic_dep_support", "cargo"]
version = "0.1.0"
age = 30

[[projects]]
qnames = ["tectonic_cfg_support", "cargo"]
version = "0.1.4"
age = 5

[[projects]]
qnames = ["tectonic_bundles", "cargo"]
version = "0.3.0"
age = 0

[[projects]]
qnames = ["tectonic_bridge_icu", "cargo"]
version = "0.2.0"
age = 26

[[projects]]
qnames = ["tectonic_bridge_graphite2", "cargo"]
version = "0.2.1"
age = 8

[[projects]]
qnames = ["tectonic_bridge_harfbuzz", "cargo"]
version = "0.2.5"
age = 0

[[projects]]
qnames = ["tectonic_bridge_freetype2", "cargo"]
version = "0.2.0"
age = 26

[[projects]]
qnames = ["tectonic_bridge_flate", "cargo"]
version = "0.1.5"
age = 14

[[projects]]
qnames = ["tectonic_bridge_core", "cargo"]
version = "0.3.0"
age = 8

[[projects]]
qnames = ["tectonic_xetex_layout", "cargo"]
version = "0.2.0"
age = 0

[[projects]]
qnames = ["tectonic_pdf_io", "cargo"]
version = "0.2.0"
age = 0

[[projects]]
qnames = ["tectonic_engine_xetex", "cargo"]
version = "0.2.0"
age = 4

[[projects]]
qnames = ["tectonic_engine_xdvipdfmx", "cargo"]
version = "0.1.3"
age = 12

[[projects]]
qnames = ["tectonic_engine_spx2html", "cargo"]
version = "0.1.1"
age = 2

[[projects]]
qnames = ["tectonic_engine_bibtex", "cargo"]
version = "0.1.3"
age = 14

[[projects]]
qnames = ["tectonic", "cargo"]
version = "0.8.2"
age = 1

+++
  • Loading branch information
cranko committed Apr 26, 2022
2 parents dc70ec6 + 6234dd9 commit 7533c0b
Show file tree
Hide file tree
Showing 140 changed files with 9,241 additions and 6,913 deletions.
10 changes: 5 additions & 5 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 3 additions & 3 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ serde = { version = "^1.0", features = ["derive"], optional = true }
sha2 = "^0.9"
structopt = "0.3"
tectonic_bridge_core = { path = "crates/bridge_core", version =">=0.3.0,<1"}
tectonic_bundles = { path = "crates/bundles", version =">=0.2.0,<1", default-features = false }
tectonic_bundles = { path = "crates/bundles", version =">=0.3.0,<1", default-features = false }
tectonic_docmodel = { path = "crates/docmodel", version =">=0.1.2,<1", optional = true }
tectonic_engine_bibtex = { path = "crates/engine_bibtex", version =">=0.1.0,<1"}
tectonic_engine_spx2html = { path = "crates/engine_spx2html", version =">=0.1.1,<1"}
Expand Down Expand Up @@ -120,7 +120,7 @@ tokio = "0.1.22"

[package.metadata.vcpkg]
git = "https://github.com/microsoft/vcpkg"
rev = "997cd412fa4dff71bec6c99dea95f0b9a3c2c240"
rev = "6b6a35335c9064fac2ec6684c4f79808dce59b7d"

[package.metadata.vcpkg.target]
x86_64-apple-darwin = { install = ["freetype","harfbuzz[icu,graphite2]"] }
Expand All @@ -134,7 +134,7 @@ tectonic_bridge_flate = "thiscommit:2021-01-01:eer4ahL4"
tectonic_bridge_graphite2 = "2c1ffcd702a662c003bd3d7d0ca4d169784cb6ad"
tectonic_bridge_harfbuzz = "2c1ffcd702a662c003bd3d7d0ca4d169784cb6ad"
tectonic_bridge_icu = "2c1ffcd702a662c003bd3d7d0ca4d169784cb6ad"
tectonic_bundles = "207e6e796b1827330ee03a4c395fe6db059bddd9"
tectonic_bundles = "thiscommit:2022-03-29:SFnXSaL"
tectonic_cfg_support = "thiscommit:aeRoo7oa"
tectonic_dep_support = "5faf4205bdd3d31101b749fc32857dd746f9e5bc"
tectonic_docmodel = "thiscommit:2022-02-20:2SpEl4c"
Expand Down
5 changes: 5 additions & 0 deletions crates/bridge_harfbuzz/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
# tectonic_bridge_harfbuzz 0.2.5 (2022-04-26)

- Update the vendored harfbuzz to 4.1.0.


# tectonic_bridge_harfbuzz 0.2.4 (2022-02-28)

- Update the vendored Harfbuzz to 3.0.0.
Expand Down
2 changes: 1 addition & 1 deletion crates/bridge_harfbuzz/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

[package]
name = "tectonic_bridge_harfbuzz"
version = "0.2.4"
version = "0.2.5"
authors = ["Peter Williams <[email protected]>"]
description = """
Expose the Harfbuzz C/C++ APIs to Rust/Cargo.
Expand Down
2 changes: 1 addition & 1 deletion crates/bridge_harfbuzz/harfbuzz
Submodule harfbuzz updated 649 files
19 changes: 19 additions & 0 deletions crates/bundles/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,22 @@
# tectonic_bundles 0.3.0 (2022-04-26)

This minor bump contains a breaking change!

- The default bundle URL is now parametrized with the "format version", which
captures the internal capabilities of the XeTeX engine. Since the bundle and
the engine are fairly tightly coupled, this allows us to provide bundles that
track the capabilities of newer engine versions, while preserving the behavior
of older engine versions. Anyway, instead of exporting a `FALLBACK_BUNDLE_URL`
const, we now export a `get_fallback_bundle_url()` method that takes the
format version as an argument. This argument should be the value of
`tectonic_engine_xetex::FORMAT_SERIAL` if you have a module that actually
links to the XeTeX engine.
- Make the cache location customizable with the environment variable
`TECTONIC_CACHE_DIR` (#880, #884, @wischi-chr).
- Fix "fetching" of zero-size files to succeed without attempting any I/O (#888,
@pkgw).


# tectonic_bundles 0.2.0 (2021-10-11)

This release contains a major configuration change, updating the URL of the
Expand Down
2 changes: 1 addition & 1 deletion crates/bundles/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

[package]
name = "tectonic_bundles"
version = "0.2.0"
version = "0.3.0"
authors = ["Peter Williams <[email protected]>"]
description = """
Tectonic "bundle" (support file collection) implementations.
Expand Down
20 changes: 17 additions & 3 deletions crates/bundles/src/cache.rs
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@
use fs2::FileExt;
use std::{
collections::HashMap,
env,
fs::{self, File},
io::{BufRead, BufReader, Error as IoError, ErrorKind as IoErrorKind, Read, Write},
path::{Path, PathBuf},
Expand All @@ -43,13 +44,26 @@ pub struct Cache {
impl Cache {
/// Get a handle to a bundle cache, using default per-user settings.
///
/// The cache location defaults to the `AppDataType::UserCache`
/// provided by `app_dirs2` but can be overwritten using the
/// `TECTONIC_CACHE_DIR` environment variable.
///
/// This method may perform I/O to create the user cache directory, so it is
/// fallible. (Due to its `app_dirs2` implementation, it would have to be
/// fallible even if it didn't perform I/O.)
pub fn get_user_default() -> Result<Self> {
Ok(Cache {
root: app_dirs::ensure_user_cache_dir("")?,
})
let env_cache_path = env::var_os("TECTONIC_CACHE_DIR");

let cache_path = match env_cache_path {
Some(env_cache_path) => {
let env_cache_path = env_cache_path.into();
fs::create_dir_all(&env_cache_path)?;
env_cache_path
}
None => app_dirs::ensure_user_cache_dir("")?,
};

Ok(Cache { root: cache_path })
}

/// Get a handle to a bundle cache, using a custom cache directory.
Expand Down
51 changes: 28 additions & 23 deletions crates/bundles/src/itar.rs
Original file line number Diff line number Diff line change
Expand Up @@ -159,35 +159,40 @@ impl CacheBackend for IndexedTarBackend {
let mut overall_failed = true;
let mut any_failed = false;

for _ in 0..MAX_HTTP_ATTEMPTS {
let mut stream = match self.reader.read_range(info.offset, n) {
Ok(r) => r,
Err(e) => {
tt_warning!(status, "failure requesting \"{}\" from network", name; e);
// Our HTTP implementation actually has problems with zero-sized ranged
// reads (Azure gives us a 200 response, which we don't properly
// handle), but when the file is 0-sized we're all set anyway!
if n > 0 {
for _ in 0..MAX_HTTP_ATTEMPTS {
let mut stream = match self.reader.read_range(info.offset, n) {
Ok(r) => r,
Err(e) => {
tt_warning!(status, "failure requesting \"{}\" from network", name; e);
any_failed = true;
continue;
}
};

if let Err(e) = stream.read_to_end(&mut buf) {
tt_warning!(status, "failure downloading \"{}\" from network", name; e.into());
any_failed = true;
continue;
}
};

if let Err(e) = stream.read_to_end(&mut buf) {
tt_warning!(status, "failure downloading \"{}\" from network", name; e.into());
any_failed = true;
continue;
overall_failed = false;
break;
}

overall_failed = false;
break;
}

if overall_failed {
bail!(
"failed to retrieve \"{}\" from the network; \
this most probably is not Tectonic's fault \
-- please check your network connection.",
name
);
} else if any_failed {
tt_note!(status, "download succeeded after retry");
if overall_failed {
bail!(
"failed to retrieve \"{}\" from the network; \
this most probably is not Tectonic's fault \
-- please check your network connection.",
name
);
} else if any_failed {
tt_note!(status, "download succeeded after retry");
}
}

Ok(buf)
Expand Down
38 changes: 28 additions & 10 deletions crates/bundles/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -95,29 +95,47 @@ impl<B: Bundle + ?Sized> Bundle for Box<B> {
}
}

/// The URL of the default bundle.
/// Get the URL of the default bundle.
///
/// This is a hardcoded URL of a default bundle that will provide some
/// This is a mostly-hardcoded URL of a default bundle that will provide some
/// "sensible" set of TeX support files. The higher-level `tectonic` crate
/// provides a configuration mechanism to allow the user to override this
/// setting, so you should use that if you are in a position to do so.
///
/// This URL will be embedded in the binaries that you create, which may be used
/// for years into the future, so it needs to be durable and reliable. We used
/// `archive.org` for a while, but it had low-level reliability problems and was
/// blocked in China. We now use a custom webservice.
pub const FALLBACK_BUNDLE_URL: &str = "https://relay.fullyjustified.net/default_bundle.tar";
/// The URL depends on the format version supported by the engine, since that
/// roughly corresponds to a TeXLive version, and the engine and TeXLive files
/// are fairly closely coupled.
///
/// The URL template used in this function will be embedded in the binaries that
/// you create, which may be used for years into the future, so it needs to be
/// durable and reliable. We used `archive.org` for a while, but it had
/// low-level reliability problems and was blocked in China. We now use a custom
/// webservice.
pub fn get_fallback_bundle_url(format_version: u32) -> String {
// Format version 32 (TeXLive 2021) was when we introduced versioning to the
// URL.
if format_version < 32 {
"https://relay.fullyjustified.net/default_bundle.tar".to_owned()
} else {
format!(
"https://relay.fullyjustified.net/default_bundle_v{}.tar",
format_version
)
}
}

/// Open the fallback bundle.
///
/// This is essentially the default Tectonic bundle, but the higher-level
/// `tectonic` crate provides a configuration mechanism to allow the user to
/// override the [`FALLBACK_BUNDLE_URL`] setting, and that should be preferred
/// if you’re in a position to use it.
/// override the bundle URL setting, and that should be preferred if you’re in a
/// position to use it.
pub fn get_fallback_bundle(
format_version: u32,
only_cached: bool,
status: &mut dyn StatusBackend,
) -> Result<cache::CachingBundle<itar::IndexedTarBackend>> {
let url = get_fallback_bundle_url(format_version);
let mut cache = cache::Cache::get_user_default()?;
cache.open(FALLBACK_BUNDLE_URL, only_cached, status)
cache.open(&url, only_cached, status)
}
4 changes: 2 additions & 2 deletions crates/engine_xdvipdfmx/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -22,12 +22,12 @@ links = "tectonic_engine_xdvipdfmx"
libc = "^0.2"
tectonic_bridge_core = { path = "../bridge_core", version =">=0.1.0,<1"}
tectonic_errors = { path = "../errors", version =">=0.2.0,<1"}
tectonic_pdf_io = { path = "../pdf_io", version =">=0.1.0,<1"}
tectonic_pdf_io = { path = "../pdf_io", version =">=0.2.0,<1"}

[build-dependencies]
cc = "^1.0.66"

[package.metadata.internal_dep_versions]
tectonic_bridge_core = "thiscommit:2021-01-17:fohCh1sh"
tectonic_errors = "5c9ba661edf5ef669f24f9904f99cca369d999e7"
tectonic_pdf_io = "620fe47e87000cede22d5e5eafa0fda81f28b402"
tectonic_pdf_io = "thiscommit:2022-03-29:6nizWic"
Loading

0 comments on commit 7533c0b

Please sign in to comment.