Is there a way of adding a glossary using the glossaries package in Texlipse?




\section{Section Header}
Text Text Text


(I have installed Perl as I am on a windows system (as per the documentation) but that doesn't seem to have changed anything...unless I missed some key part!)

  • You have to run the makeglossaries script after the LaTeX run and run LaTeX again. This can be conveniently done via latexmk or simply by a shell command.
    – egreg
    Mar 4, 2012 at 16:27

2 Answers 2


I spent some time fiddling with this, and finally made it work. The instructions should be platform-independent, but for reference, this is on Eclipse 3.7.2/Texlipse 1.5.0/Win7 x64/MikTeX 2.9. I opted out of using the makeglossaries script since Perl is not usually found on Windows systems, and I had some issues with the script when the directories of the input and output files were not the same. makeindex should work well enough.

  1. Specify a place for the temporary/auxiliary files created by glossaries

    • In Eclipse, go to Window->Preferences->Texlipse->Builder Settings->Latex Temp Files

    • Add the following glossaries-specific extensions: .ist, .gls, .glg and .glo

    This will move the temp files to the tmp directory after each build so they don't get in the way. This is kind of optional and you can make do without it, but it keeps your source directory clean.

  2. Create a new make glossaries external tool configuration:

    • Go to Run->External Tools->External Tools Configurations... and create a new configuration. Name it any way you want.

    • In "Location" field, use the path to the makeindex command.

    • In "Working directory", use ${project_loc}\tmp. This is project-independent, so you won't have to update it for each new project.

    • In "Arguments", use the following:

      -q -s ${project_name}.ist -t ${project_name}.glg -o ${project_name}.gls ${project_name}.glo

    Add any relevant makeindex customizations as necessary. I used the -q flag to suppress printing the log messages to the console in Eclipse, but you can take it out for debugging purposes.

  3. Run the glossaries after every build:

    • Open your project and go to Project->Properties->Builders

    • Choose Import... and select the builder we just made.

    • Go to Edit... for the builder and then go to Build Options.

    • Check Launch in background, During manual builds and During auto builds.

    • Uncheck After a "Clean" and During a "Clean".

    • Leave the rest as they are.

    If your main .tex file is named differently from your project, then replace all references to ${project_name} in the "Arguments" section appropriately (do this for the imported builder, not for the external tool, naturally). Don't bother creating a new variables, this will only apply to your current project anyway so just hard-code them and call it a day.

You might have to build twice for the references to appear, since the tool is only executed after each build, and you'd need another one for them to appear. This is similar to the way you do this manually -- you'd need another call to {pdf}latex after you have executed makeindex.

  • There's a possibility that I might have missed a step since I tried a lot of things until I made it work. If so, please let me know and I'll edit in what's missing. Apr 19, 2012 at 10:28
  • Perhaps you can add a comment about running multiple times the pdflatex command.
    – CSchulz
    Aug 27, 2012 at 8:51
  • Did you find a way to make this building automatic while maintaining auto-refresh of the PDF using PDF4Eclipse?
    – Trefex
    Mar 9, 2014 at 22:08
  • Worked great for me but ${project_loc}\tmp as a working directory did not work for me. I'm using Ubuntu. Had to change it by clicking on "Browse workplace". Is there a better way?
    – mtanti
    Mar 26, 2014 at 6:36
  • This worked for me after much fiddling. Future readers, keep in mind an extremely toxic bug with absolute paths when you are trying to create a small variation of this builder rule; the gist is to only ever use relative paths. This becomes especially relevant when you want to work with the tmp-folder while the idx file is in the project folder.
    – MicroVirus
    Oct 13, 2015 at 12:37

I found a solution using makeglossaries and keeping the PDF synced with PDF4Eclipse.

This solution is based on this post

  1. Install Perl
  2. Make sure you have the makeglossaries.exe in your your tex distribution bin folder
  3. Make sure that you can call makeglossaries from the command line directly.

    $> makeglossaries    
    makeglossaries: Need exactly one file argument.   
    Use `makeglossaries --help' for help.
  4. Next create a .bat file (gloss.bat) in your project folder in Eclipse and put the following content

    @echo off 
    cd "%~dp1"
    set texSource=%~n1
    pdflatex  -synctex=1 -interaction=nonstopmode --src-specials "%texSource%.tex"
    makeglossaries "%texSource%"
    pdflatex  -synctex=1 -interaction=nonstopmode --src-specials "%texSource%.tex"
    pdflatex  -synctex=1 -interaction=nonstopmode --src-specials "%texSource%.tex"
    pdflatex  -synctex=1 -interaction=nonstopmode --src-specials "%texSource%.tex"
  5. Now in Eclipse, under Window --> Preferences --> Texlipse --> Builder Settings you should edit the Pdflatex command to the following:

    Program File: <pathtoprojectfolder>\gloss.bat
    Arguments: %input
  6. Add the following extensions to the list of temporary files in Window-->Preferences-->Texlipse-->Builder Settings-->Latex Temp Files:

    • .ist, .glo, .gls, .glg, .acn, .acr, .alg
  • 1
    I upped the answer because it worked. However, this method makes incremental builds very slow (especially when there were no changes to the glossaries.
    – Shailen
    Sep 8, 2014 at 9:17

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .