- Put the color profile
eciRGB_v2.icc
in the working directory.
- Add the flowing code to your preamble:
\usepackage{hyperxmp}
\usepackage[pdfa, linktoc=none]{hyperref}
% ===============================
% Embedding the color profile.
% Requires eciRGB_v2.icc in the working directory
% http://www.eci.org/_media/downloads/icc_profiles_from_eci/ecirgbv20.zip
\immediate\pdfobj stream attr{/N 3} file{eciRGB_v2.icc}
\pdfcatalog{%
/OutputIntents [ <<
/Type /OutputIntent
/S/GTS_PDFA1
/DestOutputProfile \the\pdflastobj\space 0 R
/OutputConditionIdentifier (eciRGB v2)
/Info(eciRGB v2)
>> ]
}
Add metadata with hyperxmp
and \hypersetup
:
\title{Title}
\author{First Author, Last Author}
\hypersetup{%
pdfauthortitle={Title of the Author},
pdfcopyright={Copyright (C) 20xx, Copyrightholder},
pdfsubject={Something},
pdfkeywords={Keyword1, Keyword2},
pdflicenseurl={http://creativecommons.org/licenses/by-nc-nd/3.0/},
pdfcaptionwriter={Scott Pakin},
pdfcontactaddress={Street},
pdfcontactcity={City},
pdfcontactpostcode={101},
pdfcontactcountry={Country},
pdfcontactemail={[email protected]},
pdfcontacturl={http://www.institute.edu},
pdflang={en},
bookmarksopen=true,
bookmarksopenlevel=3,
hypertexnames=false,
linktocpage=true,
plainpages=false,
breaklinks
}
Everything put together results in a document like this:
% ===============================
% Filename: test.tex
\documentclass{article}
\usepackage{hyperxmp}
\usepackage[pdfa, linktoc=none]{hyperref}
% ===============================
% Embedding the color profile.
% Requires eciRGB_v2.icc in the working directory
% http://www.eci.org/_media/downloads/icc_profiles_from_eci/ecirgbv20.zip
\immediate\pdfobj stream attr{/N 3} file{eciRGB_v2.icc}
\pdfcatalog{%
/OutputIntents [ <<
/Type /OutputIntent
/S/GTS_PDFA1
/DestOutputProfile \the\pdflastobj\space 0 R
/OutputConditionIdentifier (eciRGB v2)
/Info(eciRGB v2)
>> ]
}
% ----------------------------------------------
% Add metadata
\title{Title}
\author{First Author, Last Author}
\hypersetup{%
pdfauthortitle={Title of the Author},
pdfcopyright={Copyright (C) 20xx, Copyrightholder},
pdfsubject={Something},
pdfkeywords={Keyword1, Keyword2},
pdflicenseurl={http://creativecommons.org/licenses/by-nc-nd/3.0/},
pdfcaptionwriter={Scott Pakin},
pdfcontactaddress={Street},
pdfcontactcity={City},
pdfcontactpostcode={101},
pdfcontactcountry={Country},
pdfcontactemail={[email protected]},
pdfcontacturl={http://www.institute.edu},
pdflang={en},
bookmarksopen=true,
bookmarksopenlevel=3,
hypertexnames=false,
linktocpage=true,
plainpages=false,
breaklinks
}
\begin{document}
What cat says? \label{meow}
See question on page \pageref{meow}.
\end{document}
Which is PDF/A-1b compliant:

Update: Since the original answer, things have changed several times. For a while luatex85
had to be loaded but today it would break compilation. But it's also not needed anymore. The packages have to be loaded before setting the OutputIntent today.
This works only with pdfLaTeX
, LuaHBTeX
and LuaLaTeX
.
pdflatex
? Usingpdflatex
I got no error.pdflatex
.pdfx
, but didn't figure out how to make it work. Some kind on Hello world -example would be nice.