texpresso icon indicating copy to clipboard operation
texpresso copied to clipboard

bulid error

Open captainshan opened this issue 1 year ago • 5 comments

` Compiling tectonic_xetex_layout v0.2.4 (/Users/captain/texpresso/tectonic/crates/xetex_layout) The following warnings were emitted during compilation:

warning: [email protected]: /opt/homebrew/Cellar/icu4c/74.2/include/unicode/localpointer.h:224:40: error: expected ';' at end of declaration list

warning: [email protected]: /opt/homebrew/Cellar/icu4c/74.2/include/unicode/localpointer.h:399:36: error: expected ';' at end of declaration list

warning: [email protected]: /opt/homebrew/Cellar/icu4c/74.2/include/unicode/ubidi.h:579:1: error: expected ';' at end of declaration list

warning: [email protected]: 7 warnings and 3 errors generated.

error: failed to run custom build command for tectonic_xetex_layout v0.2.4 (/Users/captain/texpresso/tectonic/crates/xetex_layout)

Caused by: process didn't exit successfully: /Users/captain/texpresso/tectonic/target/release/build/tectonic_xetex_layout-b37a63f57be228df/build-script-build (exit status: 1) --- stdout

cargo:warning=/opt/homebrew/Cellar/icu4c/74.2/include/unicode/localpointer.h:224:40: error: expected ';' at end of declaration list

cargo:warning=/opt/homebrew/Cellar/icu4c/74.2/include/unicode/localpointer.h:399:36: error: expected ';' at end of declaration list

cargo:warning=/opt/homebrew/Cellar/icu4c/74.2/include/unicode/ubidi.h:579:1: error: expected ';' at end of declaration list

cargo:warning=

cargo:warning=7 warnings and 3 errors generated.

exit status: 1

--- stderr

error occurred: Command env -u IPHONEOS_DEPLOYMENT_TARGET "c++" "-O3" "-ffunction-sections" "-fdata-sections" "-fPIC" "-arch" "arm64" "-I" "layout" "-I" "/Users/captain/texpresso/tectonic/crates/bridge_core/support" "-I" "/Users/captain/texpresso/tectonic/target/release/build/tectonic_bridge_harfbuzz-9e8707849e7aac32/out" "-I" "/opt/homebrew/Cellar/graphite2/1.3.14/include" "-I" "/opt/homebrew/opt/freetype/include/freetype2" "-I" "/opt/homebrew/opt/libpng/include/libpng16" "-I" "/opt/homebrew/Cellar/graphite2/1.3.14/include" "-I" "/opt/homebrew/Cellar/icu4c/74.2/include" "-Wall" "-Wextra" "-Wall" "-Wall" "-Wdate-time" "-Wendif-labels" "-Wextra" "-Wformat=2" "-Wmissing-declarations" "-Wmissing-include-dirs" "-Wpointer-arith" "-Wredundant-decls" "-Wshadow" "-Wswitch-bool" "-Wundef" "-Wextra-semi" "-Wno-unused-parameter" "-Wno-implicit-fallthrough" "-fno-exceptions" "-fno-rtti" "-DXETEX_MAC=1" "-o" "/Users/captain/texpresso/tectonic/target/release/build/tectonic_xetex_layout-db2d797d0ccb69e2/out/layout/xetex-XeTeXLayoutInterface.o" "-c" "layout/xetex-XeTeXLayoutInterface.cpp" with args "c++" did not execute successfully (status code exit status: 1).

make[1]: *** [tectonic] Error 101 make: *** [texpresso-tonic] Error 2 `

The above error occurs when I make texpresso-tonic

captainshan avatar Jun 06 '24 08:06 captainshan

Commit fbb1c477bd5d3ebc87e1e5238b17df166e4a866e should fix the build issue. Please try again.

let-def avatar Jun 07 '24 06:06 let-def

Commit fbb1c47 should fix the build issue. Please try again.

After your modifications, the command 'make texpresso-tonic' now runs successfully. Thank you very much. However, I have another problem, if it is a Chinese document, the real-time preview is very very slow. Take the following document for example.

\documentclass[12pt]{article} \usepackage{amsmath} \usepackage{ctex} \begin{document} 您好 \end{document}

captainshan avatar Jun 07 '24 14:06 captainshan

I confirm there is an issue with handling of fonts with large character sets on macOS :/. Sorry, I have an idea about what could be done, but I have no time for a fix in the short term.

let-def avatar Jun 07 '24 22:06 let-def

The problem is that with your document, the CJK fonts are loaded from the OS and the OS font loader is broken on macOS. I have had more success by loading xeCJK package:

\documentclass[12pt]{article}
\usepackage{amsmath} 
\usepackage{xeCJK}
\begin{document}
您好
\end{document}

This results in a decent experience. Fixing support for OS fonts would be nice but this will take some time. If you want, you can use this workaround in the meantime.

let-def avatar Jun 07 '24 22:06 let-def

The problem is that with your document, the CJK fonts are loaded from the OS and the OS font loader is broken on macOS. I have had more success by loading xeCJK package:

\documentclass[12pt]{article}
\usepackage{amsmath} 
\usepackage{xeCJK}
\begin{document}
您好
\end{document}

This results in a decent experience. Fixing support for OS fonts would be nice but this will take some time. If you want, you can use this workaround in the meantime.

Your scheme is indeed a good choice at present, thank you very much.

captainshan avatar Jun 08 '24 03:06 captainshan