# Can't find pdf_tex from inkscape

I'm experiencing the same issue as here: I want to make use of "tex in inkscape" technology.

Here's a tex:

\documentclass{article}

\usepackage{graphicx}
\usepackage{color}

\begin{document}

\begin{figure}[htb]
\centering
\def\svgwidth{200pt}
\input{drawing.pdf_tex}
\caption{Double pendulum}
\end{figure}
\end{document}

Here's a pdf_tex:

\begingroup
\makeatletter
\providecommand\color[2][]{%
\errmessage{(Inkscape) Color is used for the text in Inkscape, but the package 'color.sty' is not loaded}
\renewcommand\color[2][]{}%
}
\providecommand\transparent[1]{%
\errmessage{(Inkscape) Transparency is used (non-zero) for the text in Inkscape, but the package 'transparent.sty' is not loaded}
\renewcommand\transparent[1]{}%
}
\providecommand\rotatebox[2]{#2}
\ifx\svgwidth\undefined
\setlength{\unitlength}{311.07356567pt}
\else
\setlength{\unitlength}{\svgwidth}
\fi
\global\let\svgwidth\undefined
\makeatother
\begin{picture}(1,0.59438645)%
\put(0,0){\includegraphics[width=\unitlength]{drawing.pdf}}%
\put(0.48568235,0.40805542){\color[rgb]{0,0,0}\makebox(0,0)[lb]{\smash{$\ell_1$}}}%
\put(0.67084755,0.16631196){\color[rgb]{0,0,0}\makebox(0,0)[lb]{\smash{$\ell_2$}}}%
\put(0.71199538,0.04029675){\color[rgb]{0,0,0}\makebox(0,0)[lb]{\smash{$m_2$}}}%
\put(0.55254756,0.27175325){\color[rgb]{0,0,0}\makebox(0,0)[lb]{\smash{$m_1$}}}%
\put(0.52940191,0.0763011){\color[rgb]{0,0,0}\makebox(0,0)[lb]{\smash{$\theta_2$}}}%
\put(0.42138888,0.28204021){\color[rgb]{0,0,0}\makebox(0,0)[lb]{\smash{$\theta_1$}}}%
\end{picture}%
\endgroup

I get the error:

! Unable to load picture or PDF file 'drawing.pdf'.
<to be read again>
}
l.46 ...egraphics[width=\unitlength]{drawing.pdf}}
%
?

so it looks like my tex looks for a drawing.pdf instead of drawing.pdf_tex.

I'm using TeX Live 2012/Debian.

-
\input{drawing.pdf_tex} found drawing.pdf_tex but then as that was processed it got to \includegraphics[width=\unitlength]{drawing.pdf} which requires the file drawing.pdf which is presumably supposed to have been made by inkscape? –  David Carlisle Nov 29 '12 at 17:20
Oh I see -- so I need both files! Make it an answer -- so I can accept it. –  Adobe Nov 29 '12 at 17:24