I'm having a hard time figuring this out. Using a very simple document, compiling with the auxdir option results in an undefined reference (latexmk report --pdf -auxdir=export). Without the auxdir argument it works just fine (latexmk report --pdf). I've also tried this without the --pdf option, and the results are the same. Any ideas to determine what's causing this would be appreciated.
Document used:
\documentclass[11pt]{article}
\begin{document}
\section{Section}\label{sec:one}
Section \ref{sec:one} is broken...
\end{document}
I've done some searching, and the auxdir option seems to cause trouble with glossaries and bibliographies (e.g. Latexmk with makeglossaries and auxdir and outdir?), but nothing on references.
edit: Partial compiler output
Latexmk: This is Latexmk, John Collins, 1 January 2015, version: 4.41.
Latexmk: making auxiliary directory 'test2'
Latexmk: applying rule 'pdflatex'...
Rule 'pdflatex': Rules & subrules not known to be previously run:
pdflatex
Rule 'pdflatex': The following rules & subrules became out-of-date:
'pdflatex'
------------
Run number 1 of rule 'pdflatex'
------------
------------
Running 'pdflatex -recorder -aux-directory="test2" "report.tex"'
------------
pdflatex: unrecognized option '-aux-directory=test2'
This is pdfTeX, Version 3.14159265-2.6-1.40.19 (TeX Live 2019/dev/Debian) (preloaded format=pdflatex)
restricted \write18 enabled.
entering extended mode
auxdir! – Snobbish Hi-rep users Apr 25 '19 at 19:03