本帖最后由 zyzx 于 2014-1-24 09:50 编辑 / q( P( m+ x+ a0 d, Z' y
+ S2 T' [" p7 L% E* W" a; ~
在texworks里编译一些模版,总是出现“缺少.sty”文件的报错,比如:
6 }3 o) e, J$ F! c x“; { J# o( X1 j/ G4 C$ m1 I
! LaTeX Error: File `booktabs.sty' not found. Type X to quit or <RETURN> to proceed, or enter new name. (Default extension: sty) Enter file name: ”. R" }+ T) ^, {3 K
9 e0 Q6 V+ }# [8 G& u8 C6 A
然后我从ctan上下载了booktabs文件夹,里面有这么几个文件:9 A, Q& U! S4 T3 C; l; Z
booktabs.dtx, booktabs.sty, booktabs.pdf, booktabs.ins, copying, readme; H* O2 L% g5 P) u3 b4 e+ ?9 G
其中readme里面有文件列表和安装方法:+ E! ^, D6 W# _# H
“
0 x/ Q$ f. a: C( t: E! U! i& L. hFILES IN DISTRIBUTION
% Q7 B- ~9 o- l% m. ^=====================) [" F3 B$ j, f8 V7 V; ]2 q
BASE DISTRIBUTION:
% O! ]. ^0 A* e README This file.
# C% o9 C$ }! y$ v booktabs.ins Package installation file.' B$ J% N% a/ L( A2 o( D
booktabs.dtx Package source file.
( T; P z4 s, w) X, T/ B! w COPYING GPL license file.; U6 |8 r: K" \" A" X; u
booktabs.sty Package style file. It was produced by executing "latex booktabs.ins".6 Z2 O t4 k3 a) [
DOCUMENTATION:% n3 }! M. a5 I& Q6 }7 ~
booktabs.pdf User manual for booktabs package. It was produced by executing:2 G5 Y! c6 [9 f
pdflatex booktabs.dtx
2 s. V4 X* i4 K3 {6 n pdflatex booktabs.dtx
/ M; Z5 {- {3 K makeindex -s gglo.ist -o booktabs.gls booktabs.glo# z% {7 n2 A7 k; ?+ V [
makeindex -s gind.ist -o booktabs.ind booktabs.idx
# D! r7 y& i+ f# M pdflatex booktabs.dtx
$ w2 q2 g2 A; b' F! | pdflatex booktabs.dtx
5 c G# a7 i, [7 K1 H/ m8 R6 P/ JBASIC INSTALLATION9 k3 I$ f% w! O( W
====================8 z; m! @1 U* W
The minimum requirement to use the package is the to have booktabs.sty in a directory where TeX can find it.+ n5 X- y) y& X( y
For a basic installation on a TDS compliant system, move the following files to the following directories:
/ m8 i w6 D) j E, | <texmf>/tex/latex/booktabs/
. \/ @/ R; f! [0 I! J booktabs.sty4 y% J! f2 B7 ?
<texmf>/source/latex/booktabs/
/ ~9 e& i* J9 }7 I% Q booktabs.ins- N. M1 `% x/ d5 ^9 t, P3 \
booktabs.dtx
# t. |& ~9 ]: y7 R0 q3 Q q COPY. t7 K2 A" ?3 \
<texmf>/doc/latex/booktabs/" k2 f2 H/ b2 \" |2 Z* i6 P
README
* ~( D' B) b+ d, l. q booktabs.pdf
% D2 F$ V8 a4 Q: q: |3 [* N”
2 i: w0 [2 W4 h
9 Z8 {+ H8 o; S, v- D我按上面的要求把各个文件放在了相应的位置(红字部分没有操作,因为不知道怎么操作),但是运行模版后仍然报错说找不到,怎么办呢?请大家帮忙! |