Skip to content

[mathtext] isolate from ROOT and sync with upstream#22476

Open
ferdymercury wants to merge 10 commits into
root-project:masterfrom
ferdymercury:submathup
Open

[mathtext] isolate from ROOT and sync with upstream#22476
ferdymercury wants to merge 10 commits into
root-project:masterfrom
ferdymercury:submathup

Conversation

@ferdymercury

@ferdymercury ferdymercury commented Jun 4, 2026

Copy link
Copy Markdown
Collaborator

Variant of #22462 but upgrading to latest version (2016) and decoupling from ROOT libs

It's basically the version of @yslai at https://github.com/yslai/mathtext/tree/master/src/libmathtext with just a few patches on top to solve compilation errors.

PDF output might be potentially achievable since newer version of which has fontembedpdf.cc file

Comment thread builtins/mathtext/inc/mathrender.h Outdated
Comment thread builtins/mathtext/inc/fontembed.h Outdated
Comment thread builtins/mathtext/src/fontembedps.cc
Comment thread builtins/mathtext/src/fontembedpdf.cc
Comment thread builtins/mathtext/src/fontembed.cc
@github-actions

github-actions Bot commented Jun 4, 2026

Copy link
Copy Markdown

Test Results

    22 files      22 suites   3d 15h 6m 4s ⏱️
 3 862 tests  3 854 ✅   0 💤  8 ❌
77 198 runs  76 968 ✅ 217 💤 13 ❌

For more details on these failures, see this check.

Results for commit 1369aed.

♻️ This comment has been updated with latest results.

@ferdymercury ferdymercury changed the title [mathtext] sync with upstream [mathtext] mv to bultin subdir, isolate from ROOT and sync with upstream Jun 4, 2026
@ferdymercury ferdymercury marked this pull request as ready for review June 4, 2026 09:48
@ferdymercury ferdymercury requested a review from linev June 4, 2026 10:04
@ferdymercury

Copy link
Copy Markdown
Collaborator Author

@bellenot does the Windows memmem backup implementation make sense to you? I am not sure if that is the reason for the CI failure

@bellenot

bellenot commented Jun 5, 2026

Copy link
Copy Markdown
Member

@bellenot does the Windows memmem backup implementation make sense to you? I am not sure if that is the reason for the CI failure

I'll have to check carefully to see what it does. BTW, did you also check this one ? https://github.com/git/git/blob/master/compat/memmem.c

@bellenot

bellenot commented Jun 5, 2026

Copy link
Copy Markdown
Member

@ferdymercury here are the errors:

  C:\ROOT-CI\src\builtins\libmathtext\fontembed.cc:644: error: access out of bound in table directory
  C:\ROOT-CI\src\builtins\libmathtext\fontembed.cc:1688: error: OTF CFF font is missing required tables
  C:\ROOT-CI\src\builtins\libmathtext\fontembedps.cc:401:
  C:\ROOT-CI\src\graf2d\postscript\src\TPostScript.cxx:1523:
  ...

and:

  Processing C:/ROOT-CI/src/tutorials/visualisation/graphics/tmathtext.C...
  Info in <TCanvas::Print>: png file c1.png has been created
  C:\ROOT-CI\src\builtins\libmathtext\fontembed.cc:644: error: access out of bound in table directory
  C:\ROOT-CI\src\builtins\libmathtext\fontembed.cc:1688: error: OTF CFF font is missing required tables
  C:\ROOT-CI\src\builtins\libmathtext\fontembedps.cc:401:
  C:\ROOT-CI\src\graf2d\postscript\src\TPostScript.cxx:1523:
  Error in <TPostScript::FontEmbed>: failed to embed font 4 (filename 'C:\ROOT-CI\build\fonts\FreeSans.otf')
  C:\ROOT-CI\src\builtins\libmathtext\fontembed.cc:644: error: access out of bound in table directory
  C:\ROOT-CI\src\builtins\libmathtext\fontembed.cc:1688: error: OTF CFF font is missing required tables
  C:\ROOT-CI\src\builtins\libmathtext\fontembedps.cc:401:
  C:\ROOT-CI\src\graf2d\postscript\src\TPostScript.cxx:1523:
  ...

Co-authored-by: ferdymercury <ferdymercury@users.noreply.github.com>
use upstream incpath style
avoid uninitalized warnings

more fixes

fix warning

avoid uninitalized warnings
@ferdymercury ferdymercury changed the title [mathtext] mv to bultin subdir, isolate from ROOT and sync with upstream [mathtext] isolate from ROOT and sync with upstream Jun 8, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants