Skip to content

Commit

Permalink
Merge pull request #848 from pkgw/format-decoding
Browse files Browse the repository at this point in the history
Add `xetex_format` introspection crate
  • Loading branch information
pkgw authored Dec 9, 2021
2 parents fe67a8d + c0938d3 commit 9896567
Show file tree
Hide file tree
Showing 37 changed files with 7,072 additions and 1,134 deletions.
295 changes: 167 additions & 128 deletions Cargo.lock

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,7 @@ members = [
"crates/pdf_io",
"crates/status_base",
"crates/xdv",
"crates/xetex_format",
"crates/xetex_layout",
]

Expand Down
2 changes: 1 addition & 1 deletion crates/docmodel/src/document.rs
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ impl Document {
let outputs = self
.outputs
.values()
.map(|r| syntax::OutputProfile::from_runtime(r))
.map(syntax::OutputProfile::from_runtime)
.collect();

let doc = syntax::Document {
Expand Down
1 change: 1 addition & 0 deletions crates/docmodel/src/workspace.rs
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ use crate::document::Document;
#[derive(Debug)]
pub struct Workspace {
/// The root directory of the workspace.
#[allow(dead_code)] // We expect to use this eventually.
root_dir: PathBuf,

/// This workspace's document. In the future, there might be more than one.
Expand Down
14 changes: 13 additions & 1 deletion crates/engine_xetex/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ This crate provides the following [Cargo features][features]:
the `tectonic_bridge_harfbuzz` dependency.


## Updating the generated header
## Updating the generated headers

This crate exposes Rust functions to C/C++ code using a header file created by
[cbindgen]. To update the header, run:
Expand All @@ -32,3 +32,15 @@ This crate exposes Rust functions to C/C++ code using a header file created by
```sh
cbindgen --output xetex/xetex_bindings.h
```

It also uses definitions generated by the `tectonic_xetex_format` introspection crate. To
update that header, run:

```sh
cargo run -p tectonic_xetex_format --example emit >xetex/xetex_format.h
```

Note that this crate defines the format serial number that it implements (in
`tectonic_engine_xetex::FORMAT_SERIAL`) separately from the maximum serial
number supported by the introspection crate (in
`tectonic_xetex_format::LATEST_VERSION`).
Loading

0 comments on commit 9896567

Please sign in to comment.