3

My environment: Emacs 24.3.1 with AucTex (11.88) on a Xubuntu 14.04.

I needed a way to draw Nassi-Shneidermann-Diagrams (Struktogramme) direct into my texfile. So i loaded all packages from here: http://www.ctan.org/tex-archive/macros/latex/contrib/struktex and startet the installation via

sonja@Tardis:~$ latex struktex.ins

as described in the manual and put it here:

/usr/share/texlive/texmf-dist/tex/latex/

that is where i expected all style-files.

Here is part of myfile.tex:

\documentclass{article}
%\usepackage[german]{babel}
\usepackage{ngerman}
\usepackage[utf8]{inputenc}
\usepackage{struktex}

This is what i expected:

  • after running LaTeX in my emacs (C-c C-c Latex RET, or by klicking on the Latex-Button) there should be no error.

But the actual output was:

ERROR: LaTeX Error: File `struktex.sty' not found.

--- TeX said ---

Type X to quit or <RETURN> to proceed,
or enter new name. (Default extension: sty)

Enter file name: 
! Emergency stop.
<read *> 

What i did:

I tried to find a solution. So First, i was not sure, if i put the struktex.sty file in the right place. I knew, that at leas ngerman was in the right folder, so i tried

sonja@Tardis:~$ kpsewhich ngerman.sty

The output was:

/usr/share/texlive/texmf-dist/tex/generic/german/ngerman.sty

so i put the struktex folder with the struktex.sty file and its dependencies (struktxf.sty and struktxp.sty) into the generic-folder.

After restarting emacs, i thougt it would work. But it didn't.
So i tried kpsewhich again with struktex.sty as parameter. No output.
I checked the access permissions, but they are alike the others.
So i made this:

sonja@Tardis:~$ pdflatex myfile.tex

directly in the shell.
and it didn't find the style either. but i could insert a path. And after i did this for the three styles, it worked in this session and still not with emacs.

My question is, what can i do, that kpsewich and emacs can find the style-files that i need?

7
  • 2
    When you put files in texmf-dist you must update the file name database (with mktexlsr). But in general it is not a good idea to put local files in texmf-dist, use texmf-local or texmf-home. And don't use the ngerman.sty, use babel with the option ngerman. Commented Dec 23, 2014 at 14:36
  • 1
    Welcome to TeX SX! I don't see why you installed struktex by hand: it is part of TeX Live. You sould have done it through TeX Live Package Manager. Anyway, if installed by hand, shouldn't it have been installed in texmf-local, rather than texmf-dist?
    – Bernard
    Commented Dec 23, 2014 at 14:36
  • 1
    To write LaTeX with Emacs and using the package AUCTeX makes sense. I've never seen a better way. However, Emacs is an editor and AUCTeX simply some code to improve the way of editing files. Emacs just calls pdftex (or LuaTeX or XeTeX). Your issue is completely on the side of your TeX installation. Execpt that Emacs issues a command (pdftex ...), Emacs is not involved in the process.
    – Keks Dose
    Commented Dec 23, 2014 at 14:46
  • @UlrikeFischer I do not have a folder called texfm-local or texfm-home. At least i can not find it. I make sure, that i do have it. For a first try mktexlsr is a good tip. Thank you very much! :)
    – sunjazz
    Commented Dec 23, 2014 at 15:41
  • @Keks Thank you for giving a short insight into writing Latex with Emacs. I Like that!
    – sunjazz
    Commented Dec 23, 2014 at 15:41

0

You must log in to answer this question.

Browse other questions tagged .