diff --git a/sphinx/texinputs/sphinxhowto.cls b/sphinx/texinputs/sphinxhowto.cls index 6980f10a1..80c563a92 100644 --- a/sphinx/texinputs/sphinxhowto.cls +++ b/sphinx/texinputs/sphinxhowto.cls @@ -90,7 +90,11 @@ % Contents. % For an article document class this environment is a section, % so no page break before it. +% +% Note: \phantomsection is required for TeXLive 2009 +% http://tex.stackexchange.com/questions/44088/when-do-i-need-to-invoke-phantomsection#comment166081_44091 \newenvironment{sphinxthebibliography}[1]{% + \phantomsection \begin{thebibliography}{1}% \addcontentsline{toc}{section}{\bibname}}{\end{thebibliography}} diff --git a/sphinx/texinputs/sphinxmanual.cls b/sphinx/texinputs/sphinxmanual.cls index 2c313ed19..3a200a060 100644 --- a/sphinx/texinputs/sphinxmanual.cls +++ b/sphinx/texinputs/sphinxmanual.cls @@ -107,8 +107,12 @@ % Fix the bibliography environment to add an entry to the Table of % Contents. % For a report document class this environment is a chapter. +% +% Note: \phantomsection is required for TeXLive 2009 +% http://tex.stackexchange.com/questions/44088/when-do-i-need-to-invoke-phantomsection#comment166081_44091 \newenvironment{sphinxthebibliography}[1]{% \if@openright\cleardoublepage\else\clearpage\fi + \phantomsection \begin{thebibliography}{1}% \addcontentsline{toc}{chapter}{\bibname}}{\end{thebibliography}}