2

I've configured Texmaker to send the output files to a "build" subdirectory to try and keep the folder organized. Within the main folder is my .tex and .bib files accompanied by the "build" folder. Now when I run my .tex file it typesets correctly but when I run BibTeX it can't find the .aux file. I assume this is because it lies within that "build" folder. Is there a way I can tell BibTeX to search for it in the "build" folder irrespective of what main folder I'm working in.

I'm using Texmaker 5.0.3 on a Windows machine.

  • Do yourself a favour and don't use a build subdirectory. This will cause more problems than it solves. If your only reason is to keep your main folder clean, use the automation tool ltx2any to compile your document: https://github.com/reitzig/ltx2any See https://tex.stackexchange.com/a/439345/36296 for a short example – samcarter_is_at_topanswers.xyz Mar 07 '19 at 09:05

2 Answers2

5

I do not know if this will solve your problem on Windows, but on Linux (Ubuntu) it does: (sorry if the options are not exactly like I write them, I am translating from a different language)

  1. In Texmaker go to Options -> Texmaker Configuration -> Commands (this is the first option on the left side)
  2. Look for the text field right to "Bib(la)tex"
  3. At the moment there should be something like this: bibtex %.aux
  4. Replace it by: bibtex "build/%".aux
  5. Click on "Fast Translation" on the left side
  6. Use the option "PdfLaTex + Bib(la)tex + PdfLaTex (x2)+ show PDF"
  7. Confirm the change by clicking on OK

The "%"- symbol is a placeholder here, it will be replaced by the name of your .tex file. Maybe on Windows this is a different symbol, lets say "#". If so, just do the same thing as above but keep the Windows placeholder symbol instead of "%".

pbit24
  • 418
  • 4
  • 12
  • 1
    I have the same problem with TexMaker 5.0.4. This worked for me except that the command is not **bibtex %.aux** but **bibtex %** and needs to be changed to **bibtex build/%** – bel_dbo Apr 17 '20 at 10:10
-1

My setup:

  • Windows 10
  • TexMaker 5.15.2
  • Using "build" directory to put al the auxiliary files
  • Using biber

as shown in the image, you need to add at the end of the path to biber "build/%.bcf" In my case, the whole line is:

"C:/Program Files/MiKTeX/miktex/bin/x64/biber.exe" build/%.bcf

double-beep
  • 5,031
  • 17
  • 33
  • 41