LaTeX forum ⇒ GeneralPackcage "glossaries" with TeXnicCenter - No glossary!

General information and discussion about TeXnicCenter
User avatar
nlct
Posts: 275
Joined: Thu Nov 06, 2008 11:15 am

Re: Packcage "glossaries" with TeXnicCenter - No glossary!

Postby nlct » Fri Nov 07, 2008 12:21 pm

Mikerada6 wrote:i tried doing as you said but i get an error:
" 'perl' is not recognized as an internal or external command, operable program or batch file."

That means that you don't have Perl installed on your system. If you don't have Perl installed, then you can't use makeglossaries, however you can use makeindex directly. The documentation contains a section called Generating the Associated Glossary Files which gives details.

There is some confusion regarding makeglossaries, so I'll try to explain it in more detail:

The file makeglossaries is a Perl script. When you run it, you need to specify the name of the document without any extension:
  1. makeglossaries filename

This reads in filename.aux and looks for all occurrences of \@newglossary. The glossaries package always creates the main (default) glossary, so you will always have the line
  1. \@newglossary{main}{glg}{gls}{glo}

This specifies the extensions required by makeindex:
glg - log file (check this file if something goes wrong with your glossary)
gls - typeset glossary file
glo - list of glossary entries to be sorted by makeindex

Once it has this information, makeglossaries can then run makeindex:
  1. makeindex -s filename.ist -t filename.glg -o filename.gls filename.glo

It does this for each instance of \@newglossary that it finds in the aux file.

If you don't have Perl installed, you can forget about makeglossaries and just use makeindex directly, but if you can install Perl, I recommend using makeglossaries, especially if you plan on using secondary glossaries (this includes the list of acronyms, if you use the acronym option). That way, you can just add a single makeglossaries entry to your build profile, rather than multiple makeindex lines.

A note on the difference between the files "makeglossaries" and "makeglossaries.bat":

On some systems (such as Unix) you can run a Perl script by typing the name of the Perl script at the terminal (assuming appropriate permissions and paths have been set). For example:
  1. makeglossaries filename

On other systems (such as Windows) you have to explicitly load the script into Perl. However in this case you will usually need to specify the full pathname to the makeglossaries script. The file makeglossaries.bat will do this for you, so if you type the following at the MSDOS Prompt:
  1. makeglossaries filename

This is equivalent to
  1. perl -S "%~dp0makeglossaries" filename

where %~dp0 is the full pathname to the makeglossaries script.

Hope this makes things a bit clearer.

Regards
Nicola Talbot


Return to “General”

Who is online

Users browsing this forum: No registered users and 1 guest