Live data from Hacker News

Rewriting LaTeX in Pure Rust

github.com

21–30 of 148 posts

Re: Rewriting LaTeX in Pure Rust

#21
post #11
post #4

I really love Rust (believe it's the best systems programming language out there), so I've checked out tectonic a while ago. In many ways it represents precisely the direction I think Tex based typesetting should go Sadly I can't use it though as it doesn't support biber which would be needed for Unicode author names: https://github.com/tectonic-typesetting/tectonic/issues/35

I'm no expert to anything typesetting systems, but I've noticed this on the homepage: > Thanks to the power of XeTeX, Tectonic can use modern OpenType fonts and is fully Unicode-enabled. ...which seems to oppose your statement and the linked issue. Can you explain, please?

That refers to including Unicode in the document directly, which is great that it works, but for references, bibtex is part of the pipeline. You create a .bib file containing info about the references, and then do commands like \cite{} to cite to one of them. If you have Unicode in any of your references (author name, paper name, etc), you have a problem. The solution is to replace bibtex with biblatex and biber, but that requires biber support which currently doesn't exist :(.

Example error that bibtex users can run into: https://superuser.com/questions/60432/unicode-characters-in-...

Re: Rewriting LaTeX in Pure Rust

#22

Earlier quoted context omitted.

That fork is quite curious, it seems like they've really gone out and created quite an active little fork, but haven't spent the time to explain what is different and interesting about their fork in the readme.

The about summarizes it: > Experimental Oxidization of Tectonic the TeX/LaTeX engine.

Does "oxidization" mean "a port to the rust language" ?

Re: Rewriting LaTeX in Pure Rust

#23

But what is the license? Checking up the repo, I see the license is MIT, but I'm not quite satisfied with it. I mean does LaTeX permits rewrites like this?

The project appears to be based on XeTeX, which is covered by the MIT license.

I don't know the full history of XeTeX, but if it was indeed a re-write of TeX/LaTeX from the ground up (and not based on the TeX source code), then the original TeX/LaTeX license wouldn't necessarily apply. But if it borrowed actual source code, templates, etc., from other projects under different licenses, then it probably gets more complicated.

Re: Rewriting LaTeX in Pure Rust

#25
I wonder

Does this still depend, even indirectly, at the WEB files written by Knuth?

It has the strange license that says "Copying of this file is authorized only if (1) you are D. E. Knuth, or if % (2) you make absolutely no changes to your copy."

http://mirror.las.iastate.edu/tex-archive/systems/knuth/dist...

Re: Rewriting LaTeX in Pure Rust

#26

Earlier quoted context omitted.

The about summarizes it: > Experimental Oxidization of Tectonic the TeX/LaTeX engine.

Does "oxidization" mean "a port to the rust language" ?

Yes, "oxidation" as in "rusting" as in "converting to rust". It's a bit of fun wordplay. :)

Re: Rewriting LaTeX in Pure Rust

#27
post #17
post #8

Currently using this to build my Master's thesis. It's nice because it detects all the packages used in the tex source and downloads them automatically.

What do you need that isn't there already with TeXLive? I haven't downloaded a package in many years, despite many reinstalls and a lot of varied Latex use.

You are not having any issues because TeXLive is everything. The `full` scheme on `install-sh` or `texlive-full` on Debian takes up around 7 GB last time I looked, 2 to 3 of which are PDFs for package documentation.

That is, by a long shot, the largest install a lot of people have on their system. Nowadays, no biggie, but systems like Miktex allow to install-on-demand and of course, it allows you to shrink your installation significantly.

Full TexLive contains a number of packages average "Western hemisphere scientific authors", arguably the largest LaTeX demographic, will never need: Eastern and other languages, music, humanities.

Re: Rewriting LaTeX in Pure Rust

#28

I think that Rust is a perfect open source language. For the longest time the open source community has shown that it has an issue with innovation, however is great at recreating existing ideas and products. I think that this strength can be combined somehow with the "rewrite in Rust" strength and get great synergy.

> For the longest time the open source community has shown that it has an issue with innovation How so? A bunch of my favorite software has no real closed-source equivalent, sometime precisely because it’s open source.

The vast majority of open source software is a clone of a closed-source alternative. I currently having issues with thinking of a widely adopted, consumer-oriented software that has no closed-source alternative. What is your favorite software that has no real closed-source equivalent?

Re: Rewriting LaTeX in Pure Rust

#29

Really cool to see all those rewrites of existing stuff in Rust. Does anyone know if the Rust community has ever done anything original, though?

> Does anyone know if the Rust community has ever done anything original, though?

Depends on what you call "original". Is the Servo layout engine _not_ original because layout engines already exist? :)

Moving away from the rhetorical question, I think there are several reasons to rewrite something in Rust, the first and foremost being the huge improvement in memory safety/management. The other reasons are typically related to speed: C wasn't built with concurrency in mind, and trying to develop multi-threaded C applications that run in a cross-platform manner is not straightforward. On the other hand, Rust has the following:

1) Memory safety during concurrency [1]. 2) Multi-threading in the standard library [1]. 3) An amazing package ecosystem revolving around "crates". And there are several build specifically to make concurrency safe and easy to implement. [2]

[1] https://doc.rust-lang.org/stable/book/ch16-00-concurrency.ht... [2] https://crates.io/categories/concurrency

Re: Rewriting LaTeX in Pure Rust

#30

Earlier quoted context omitted.

> For the longest time the open source community has shown that it has an issue with innovation How so? A bunch of my favorite software has no real closed-source equivalent, sometime precisely because it’s open source.

The vast majority of open source software is a clone of a closed-source alternative. I currently having issues with thinking of a widely adopted, consumer-oriented software that has no closed-source alternative. What is your favorite software that has no real closed-source equivalent?

QEMU, maybe?
Post reply on HN