自 Mac M1 上的 MacTeX 2021 升级以来,PStricks 不再编译

自 Mac M1 上的 MacTeX 2021 升级以来,PStricks 不再编译

自 MacTeX 2021 升级以来,包含 PStricks 代码的文档不再像以前在配备 M1 芯片的 Mac 上使用以前的 MacTeX 2020 发行版那样进行编译。更准确地说:我确实获得了 pdf 输出,但 pspicture 区域是空白的,以及其后编码的所有内容(所有内容都出现在 pspicture 上方)。

问题是,一旦我隐藏代码(pspicture 部分),文档就会顺利编译。

我尝试恢复到 2020 发行版,没有任何问题......

这是在 2021 升级之前可以使用的代码:

\documentclass[10pt,a4paper]{article}
\usepackage[utf8]{inputenc}
\usepackage[french]{babel}
\usepackage[T1]{fontenc}
\usepackage{amsmath}
\usepackage{amsfonts}
\usepackage{amssymb}
\usepackage{pstricks}
\usepackage[left=2cm,right=2cm,top=2cm,bottom=2cm]{geometry}
\begin{document}
Ceci est un essai.
\medskip

\psset{xunit=1cm,yunit=1cm}
\begin{pspicture}(0,0)(10,5)
\psline(0,0)(10,5)
\end{pspicture}

\end{document}

以下是日志:

This is pdfTeX, Version 3.141592653-2.6-1.40.22 (TeX Live 2021) (preloaded format=latex 2021.4.3)  5 APR 2021 16:48
entering extended mode
 restricted \write18 enabled.
 %&-line parsing enabled.
**essai_encore.tex
(./essai_encore.tex
LaTeX2e <2020-10-01> patch level 4
L3 programming layer <2021-02-18>
(/usr/local/texlive/2021/texmf-dist/tex/latex/base/article.cls
Document Class: article 2020/04/10 v1.4m Standard LaTeX document class
(/usr/local/texlive/2021/texmf-dist/tex/latex/base/size10.clo
File: size10.clo 2020/04/10 v1.4m Standard LaTeX file (size option)
)
\c@part=\count179
\c@section=\count180
\c@subsection=\count181
\c@subsubsection=\count182
\c@paragraph=\count183
\c@subparagraph=\count184
\c@figure=\count185
\c@table=\count186
\abovecaptionskip=\skip47
\belowcaptionskip=\skip48
\bibindent=\dimen138
)
(/usr/local/texlive/2021/texmf-dist/tex/latex/base/inputenc.sty
Package: inputenc 2020/08/01 v1.3d Input encoding file
\inpenc@prehook=\toks15
\inpenc@posthook=\toks16
)
(/usr/local/texlive/2021/texmf-dist/tex/generic/babel/babel.sty
Package: babel 2021/03/24 3.56 The Babel package

(/usr/local/texlive/2021/texmf-dist/tex/generic/babel/babel.def
File: babel.def 2021/03/24 3.56 Babel common definitions
\babel@savecnt=\count187
\U@D=\dimen139
\l@babelnohyphens=\language87

(/usr/local/texlive/2021/texmf-dist/tex/generic/babel/txtbabel.def)
\bbl@readstream=\read2
)
\bbl@dirlevel=\count188

(/usr/local/texlive/2021/texmf-dist/tex/generic/babel-french/french.ldf
Language: french 2020/10/10 v3.5l French support from the babel system
Package babel Info: \l@acadian = using hyphenrules for french
(babel)             (\language29) on input line 91.
Package babel Info: \l@canadien = using hyphenrules for french
(babel)             (\language29) on input line 92.
\FB@nonchar=\count189
Package babel Info: Making : an active character on input line 430.
Package babel Info: Making ; an active character on input line 431.
Package babel Info: Making ! an active character on input line 432.
Package babel Info: Making ? an active character on input line 433.
\FBguill@level=\count190
\FBold@everypar=\toks17
\FB@Mht=\dimen140
\mc@charclass=\count191
\mc@charfam=\count192
\mc@charslot=\count193
\std@mcc=\count194
\dec@mcc=\count195
\listindentFB=\dimen141
\descindentFB=\dimen142
\labelindentFB=\dimen143
\labelwidthFB=\dimen144
\leftmarginFB=\dimen145
\parindentFFN=\dimen146
\FBfnindent=\dimen147
))
(/usr/local/texlive/2021/texmf-dist/tex/latex/carlisle/scalefnt.sty)
(/usr/local/texlive/2021/texmf-dist/tex/latex/graphics/keyval.sty
Package: keyval 2014/10/28 v1.15 key=value parser (DPC)
\KV@toks@=\toks18
)
(/usr/local/texlive/2021/texmf-dist/tex/latex/base/fontenc.sty
Package: fontenc 2020/08/10 v2.0s Standard LaTeX package
)
(/usr/local/texlive/2021/texmf-dist/tex/latex/amsmath/amsmath.sty
Package: amsmath 2020/09/23 v2.17i AMS math features
\@mathmargin=\skip49

For additional information on amsmath, use the `?' option.
(/usr/local/texlive/2021/texmf-dist/tex/latex/amsmath/amstext.sty
Package: amstext 2000/06/29 v2.01 AMS text

(/usr/local/texlive/2021/texmf-dist/tex/latex/amsmath/amsgen.sty
File: amsgen.sty 1999/11/30 v2.0 generic functions
\@emptytoks=\toks19
\ex@=\dimen148
))
(/usr/local/texlive/2021/texmf-dist/tex/latex/amsmath/amsbsy.sty
Package: amsbsy 1999/11/29 v1.2d Bold Symbols
\pmbraise@=\dimen149
)
(/usr/local/texlive/2021/texmf-dist/tex/latex/amsmath/amsopn.sty
Package: amsopn 2016/03/08 v2.02 operator names
)
\inf@bad=\count196
LaTeX Info: Redefining \frac on input line 234.
\uproot@=\count197
\leftroot@=\count198
LaTeX Info: Redefining \overline on input line 399.
\classnum@=\count199
\DOTSCASE@=\count266
LaTeX Info: Redefining \ldots on input line 496.
LaTeX Info: Redefining \dots on input line 499.
LaTeX Info: Redefining \cdots on input line 620.
\Mathstrutbox@=\box47
\strutbox@=\box48
\big@size=\dimen150
LaTeX Font Info:    Redeclaring font encoding OML on input line 743.
LaTeX Font Info:    Redeclaring font encoding OMS on input line 744.
\macc@depth=\count267
\c@MaxMatrixCols=\count268
\dotsspace@=\muskip16
\c@parentequation=\count269
\dspbrk@lvl=\count270
\tag@help=\toks20
\row@=\count271
\column@=\count272
\maxfields@=\count273
\andhelp@=\toks21
\eqnshift@=\dimen151
\alignsep@=\dimen152
\tagshift@=\dimen153
\tagwidth@=\dimen154
\totwidth@=\dimen155
\lineht@=\dimen156
\@envbody=\toks22
\multlinegap=\skip50
\multlinetaggap=\skip51
\mathdisplay@stack=\toks23
LaTeX Info: Redefining \[ on input line 2923.
LaTeX Info: Redefining \] on input line 2924.
)
(/usr/local/texlive/2021/texmf-dist/tex/latex/amsfonts/amsfonts.sty
Package: amsfonts 2013/01/14 v3.01 Basic AMSFonts support
\symAMSa=\mathgroup4
\symAMSb=\mathgroup5
LaTeX Font Info:    Redeclaring math symbol \hbar on input line 98.
LaTeX Font Info:    Overwriting math alphabet `\mathfrak' in version `bold'
(Font)                  U/euf/m/n --> U/euf/b/n on input line 106.
)
(/usr/local/texlive/2021/texmf-dist/tex/latex/amsfonts/amssymb.sty
Package: amssymb 2013/01/14 v3.01 AMS font symbols
)
(/usr/local/texlive/2021/texmf-dist/tex/latex/pstricks/pstricks.sty
Package: pstricks 2020/06/11 v0.70 LaTeX wrapper for `PSTricks' (RN,HV)

(/usr/local/texlive/2021/texmf-dist/tex/generic/iftex/iftex.sty
Package: iftex 2020/03/06 v1.0d TeX engine tests
)
(/usr/local/texlive/2021/texmf-dist/tex/latex/xcolor/xcolor.sty
Package: xcolor 2016/05/11 v2.12 LaTeX color extensions (UK)

(/usr/local/texlive/2021/texmf-dist/tex/latex/graphics-cfg/color.cfg
File: color.cfg 2016/01/02 v1.6 sample color configuration
)
Package xcolor Info: Driver file: dvips.def on input line 225.

(/usr/local/texlive/2021/texmf-dist/tex/latex/graphics-def/dvips.def
File: dvips.def 2017/06/20 v3.1d Graphics/color driver for dvips
)
Package xcolor Info: Model `cmy' substituted by `cmy0' on input line 1348.
Package xcolor Info: Model `RGB' extended on input line 1364.
Package xcolor Info: Model `HTML' substituted by `rgb' on input line 1366.
Package xcolor Info: Model `Hsb' substituted by `hsb' on input line 1367.
Package xcolor Info: Model `tHsb' substituted by `hsb' on input line 1368.
Package xcolor Info: Model `HSB' substituted by `hsb' on input line 1369.
Package xcolor Info: Model `Gray' substituted by `gray' on input line 1370.
Package xcolor Info: Model `wave' substituted by `hsb' on input line 1371.
)
(/usr/local/texlive/2021/texmf-dist/tex/generic/xkeyval/pst-xkey.tex
File: pst-xkey.tex 2005/11/25 v1.6 PSTricks specialization of xkeyval (HA)

(/usr/local/texlive/2021/texmf-dist/tex/latex/xkeyval/xkeyval.sty
Package: xkeyval 2020/11/20 v2.8 package option processing (HA)

(/usr/local/texlive/2021/texmf-dist/tex/generic/xkeyval/xkeyval.tex
(/usr/local/texlive/2021/texmf-dist/tex/generic/xkeyval/xkvutils.tex
\XKV@toks=\toks24
\XKV@tempa@toks=\toks25
)
\XKV@depth=\count274
File: xkeyval.tex 2014/12/03 v2.7a key=value parser (HA)
)))
(/usr/local/texlive/2021/texmf-dist/tex/generic/pstricks/pstricks.tex
(/usr/local/texlive/2021/texmf-dist/tex/generic/pstricks/pst-fp.tex
`pst-fp' v0.06, 2020/11/20 (hv)
\pstFP@xs=\count275
\pstFP@xia=\count276
\pstFP@xib=\count277
\pstFP@xfa=\count278
\pstFP@xfb=\count279
\pstFP@rega=\count280
\pstFP@regb=\count281
\pstFP@regs=\count282
\pstFP@times=\count283
)
(/usr/local/texlive/2021/texmf-dist/tex/generic/pgf/utilities/pgfutil-common.te
x
\pgfutil@everybye=\toks26
\pgfutil@tempdima=\dimen157
\pgfutil@tempdimb=\dimen158

(/usr/local/texlive/2021/texmf-dist/tex/generic/pgf/utilities/pgfutil-common-li
sts.tex))
(/usr/local/texlive/2021/texmf-dist/tex/generic/pgf/utilities/pgfkeys.code.tex
\pgfkeys@pathtoks=\toks27
\pgfkeys@temptoks=\toks28

(/usr/local/texlive/2021/texmf-dist/tex/generic/pgf/utilities/pgfkeysfiltered.c
ode.tex
\pgfkeys@tmptoks=\toks29
))
(/usr/local/texlive/2021/texmf-dist/tex/generic/pgf/utilities/pgffor.code.tex
Loading pgffor.code.tex
(/usr/local/texlive/2021/texmf-dist/tex/generic/pgf/math/pgfmath.code.tex
(/usr/local/texlive/2021/texmf-dist/tex/generic/pgf/math/pgfmathcalc.code.tex
(/usr/local/texlive/2021/texmf-dist/tex/generic/pgf/math/pgfmathutil.code.tex
\pgf@x=\dimen159
\pgf@xa=\dimen160
\pgf@xb=\dimen161
\pgf@xc=\dimen162
\pgf@y=\dimen163
\pgf@ya=\dimen164
\pgf@yb=\dimen165
\pgf@yc=\dimen166
\c@pgf@counta=\count284
\c@pgf@countb=\count285
\c@pgf@countc=\count286
\c@pgf@countd=\count287
\pgfutil@tempcnta=\count288
\pgfutil@tempcntb=\count289
)
(/usr/local/texlive/2021/texmf-dist/tex/generic/pgf/math/pgfmathparser.code.tex
\pgfmath@dimen=\dimen167
\pgfmath@count=\count290
\pgfmath@box=\box49
\pgfmath@toks=\toks30
\pgfmath@stack@operand=\toks31
\pgfmath@stack@operation=\toks32
)
(/usr/local/texlive/2021/texmf-dist/tex/generic/pgf/math/pgfmathfunctions.code.
tex
(/usr/local/texlive/2021/texmf-dist/tex/generic/pgf/math/pgfmathfunctions.basic
.code.tex)
(/usr/local/texlive/2021/texmf-dist/tex/generic/pgf/math/pgfmathfunctions.trigo
nometric.code.tex)
(/usr/local/texlive/2021/texmf-dist/tex/generic/pgf/math/pgfmathfunctions.rando
m.code.tex)
(/usr/local/texlive/2021/texmf-dist/tex/generic/pgf/math/pgfmathfunctions.compa
rison.code.tex)
(/usr/local/texlive/2021/texmf-dist/tex/generic/pgf/math/pgfmathfunctions.base.
code.tex)
(/usr/local/texlive/2021/texmf-dist/tex/generic/pgf/math/pgfmathfunctions.round
.code.tex)
(/usr/local/texlive/2021/texmf-dist/tex/generic/pgf/math/pgfmathfunctions.misc.
code.tex)
(/usr/local/texlive/2021/texmf-dist/tex/generic/pgf/math/pgfmathfunctions.integ
erarithmetics.code.tex)))
(/usr/local/texlive/2021/texmf-dist/tex/generic/pgf/math/pgfmathfloat.code.tex
\c@pgfmathroundto@lastzeros=\count291
))
\pgffor@iter=\dimen168
\pgffor@skip=\dimen169
\pgffor@stack=\toks33
\pgffor@toks=\toks34
)
\psLoopIndex=\count292

`PSTricks' v3.01a  <2021/03/30> (tvz,hv)
\pst@dima=\dimen170
\pst@dimb=\dimen171
\pst@dimc=\dimen172
\pst@dimd=\dimen173
\pst@dimg=\dimen174
\pst@dimh=\dimen175
\pst@dimm=\dimen176
\pst@dimn=\dimen177
\pst@dimo=\dimen178
\pst@dimp=\dimen179
\pst@hbox=\box50
\pst@ibox=\box51
\pst@boxg=\box52
\pst@cnta=\count293
\pst@cntb=\count294
\pst@cntc=\count295
\pst@cntd=\count296
\pst@cntg=\count297
\pst@cnth=\count298
\pst@cntm=\count299
\pst@cntn=\count300
\pst@cnto=\count301
\pst@cntp=\count302
\@zero=\count303
\pst@toks=\toks35
(/usr/local/texlive/2021/texmf-dist/tex/generic/pstricks/pstricks.con)
\psunit=\dimen180
\psxunit=\dimen181
\psyunit=\dimen182
\pst@C@@rType=\count304
\pslinewidth=\dimen183
\psk@startLW=\dimen184
\psk@endLW=\dimen185
\pst@customdefs=\toks36
\pslinearc=\dimen186
\pst@symbolStep=\dimen187
\pst@symbolWidth=\dimen188
\pst@symbolLinewidth=\dimen189
\everypsbox=\toks37
\psframesep=\dimen190
\pslabelsep=\dimen191
\sh@wgridXunit=\dimen192
\sh@wgridYunit=\dimen193
\pst@shift=\dimen194
)
File: pstricks.tex 2021/03/30 v3.01a `PSTricks' (tvz,hv)

(/usr/local/texlive/2021/texmf-dist/tex/generic/pstricks/pst-fp.tex
`pst-fp' v0.06, 2020/11/20 (hv))
File: pst-fp.tex 2020/11/20 v0.06 `PST-fp' (hv)
)
(/usr/local/texlive/2021/texmf-dist/tex/latex/geometry/geometry.sty
Package: geometry 2020/01/02 v5.9 Page Geometry

(/usr/local/texlive/2021/texmf-dist/tex/generic/iftex/ifvtex.sty
Package: ifvtex 2019/10/25 v1.7 ifvtex legacy package. Use iftex instead.
)
\Gm@cnth=\count305
\Gm@cntv=\count306
\c@Gm@tempcnt=\count307
\Gm@bindingoffset=\dimen195
\Gm@wd@mp=\dimen196
\Gm@odd@mp=\dimen197
\Gm@even@mp=\dimen198
\Gm@layoutwidth=\dimen199
\Gm@layoutheight=\dimen256
\Gm@layouthoffset=\dimen257
\Gm@layoutvoffset=\dimen258
\Gm@dimlist=\toks38
)
(/usr/local/texlive/2021/texmf-dist/tex/latex/l3backend/l3backend-dvips.def
File: l3backend-dvips.def 2021-03-18 L3 backend support: dvips
\l__pdf_internal_box=\box53
\g__pdf_backend_object_int=\count308
\l__pdf_backend_content_box=\box54
\l__pdf_backend_model_box=\box55
\g__pdf_backend_annotation_int=\count309
\g__pdf_backend_link_int=\count310
\g__pdf_backend_link_sf_int=\count311
)
(./essai_encore.aux)
\openout1 = `essai_encore.aux'.

LaTeX Font Info:    Checking defaults for OML/cmm/m/it on input line 10.
LaTeX Font Info:    ... okay on input line 10.
LaTeX Font Info:    Checking defaults for OMS/cmsy/m/n on input line 10.
LaTeX Font Info:    ... okay on input line 10.
LaTeX Font Info:    Checking defaults for OT1/cmr/m/n on input line 10.
LaTeX Font Info:    ... okay on input line 10.
LaTeX Font Info:    Checking defaults for T1/cmr/m/n on input line 10.
LaTeX Font Info:    ... okay on input line 10.
LaTeX Font Info:    Checking defaults for TS1/cmr/m/n on input line 10.
LaTeX Font Info:    ... okay on input line 10.
LaTeX Font Info:    Checking defaults for OMX/cmex/m/n on input line 10.
LaTeX Font Info:    ... okay on input line 10.
LaTeX Font Info:    Checking defaults for U/cmr/m/n on input line 10.
LaTeX Font Info:    ... okay on input line 10.
LaTeX Info: Redefining \degres on input line 10.
LaTeX Info: Redefining \dots on input line 10.
LaTeX Info: Redefining \up on input line 10.

*geometry* driver: auto-detecting
*geometry* detected driver: dvips
*geometry* verbose mode - [ preamble ] result:
* driver: dvips
* paper: a4paper
* layout: <same size as paper>
* layoutoffset:(h,v)=(0.0pt,0.0pt)
* modes: 
* h-part:(L,W,R)=(56.9055pt, 483.69687pt, 56.9055pt)
* v-part:(T,H,B)=(56.9055pt, 731.23584pt, 56.9055pt)
* \paperwidth=597.50787pt
* \paperheight=845.04684pt
* \textwidth=483.69687pt
* \textheight=731.23584pt
* \oddsidemargin=-15.36449pt
* \evensidemargin=-15.36449pt
* \topmargin=-52.36449pt
* \headheight=12.0pt
* \headsep=25.0pt
* \topskip=10.0pt
* \footskip=30.0pt
* \marginparwidth=57.0pt
* \marginparsep=11.0pt
* \columnsep=10.0pt
* \skip\footins=9.0pt plus 4.0pt minus 2.0pt
* \hoffset=0.0pt
* \voffset=0.0pt
* \mag=1000
* \@twocolumnfalse
* \@twosidefalse
* \@mparswitchfalse
* \@reversemarginfalse
* (1in=72.27pt=25.4mm, 1cm=28.453pt)

[1

] (./essai_encore.aux) ) 
Here is how much of TeX's memory you used:
 11014 strings out of 478995
 186437 string characters out of 5858211
 497992 words of memory out of 5000000
 28413 multiletter control sequences out of 15000+600000
 404193 words of font info for 28 fonts, out of 8000000 for 9000
 1141 hyphenation exceptions out of 8191
 67i,5n,74p,453b,424s stack positions out of 5000i,500n,10000p,200000b,80000s

Output written on essai_encore.dvi (1 page, 1172 bytes).


我一直在寻找解决方案,但没有成功。我的想法是,由于除了 2021 升级之外我没有做任何更改,所以问题出在新发行版中,它将在下一次更新中很快得到解决。

我希望你们中的一些人能给我一些帮助。那就太好了。

非常感谢并致以最诚挚的问候。

答案1

MacTeX-2021 安装了 Ghostscript 9.53.3,而 pstricks 想要创建透明背景,而 ps2pdf 默认不再允许这样做。您必须将标志添加-dAllOWPSTRANSPARENCY到 ps2pdf 运行中。如果您使用的是 TeXShop,您可以选择允许这样做的引擎:从我的下载网站获取它们GhostscriptTransparencyEngines.zip,<https://herbs.github.io>. 安装说明随发动机一起提供。

相关内容