Installation
To compile documents using fduthesis, you need a complete and modern TeX distribution. Because the template relies on recent LaTeX3 features and Unicode math fonts, legacy distributions (older than TeX Live 2020) are not supported.
We strongly recommend installing the latest version of TeX Live (Windows/Linux) or MacTeX (macOS).
⚠️ Engine Restriction: The template strictly requires XeLaTeX or LuaLaTeX. The older
pdfTeXengine is explicitly disabled as it cannot natively handle modern UTF-8 Chinese typesetting and OpenType fonts.
Method 1: TeX Package Manager (Recommended)
fduthesis is officially published on CTAN (The Comprehensive TeX Archive Network). If you have installed a standard, up-to-date TeX Live or MiKTeX distribution, fduthesis is likely already available on your machine.
Verifying Installation
Open your terminal or command prompt and run:
kpsewhich fduthesis.cls
If this command returns a file path, the template is installed. If it returns nothing, you need to install or update it.
Installing via TeX Live Manager (tlmgr)
Run the following command in your terminal (you may need sudo on macOS/Linux or an Administrator prompt on Windows):
tlmgr install fduthesis
To avoid compilation errors caused by outdated dependencies (like l3kernel or biblatex-gb7714-2015), we highly recommend updating your entire distribution before starting your thesis:
tlmgr update --all
Method 2: Cloud Environment (Overleaf)
If you prefer not to manage a local TeX environment, or if you need to collaborate with your supervisor in real-time, Overleaf is the best option. We maintain an official, up-to-date template on the Overleaf gallery.
Best Practices for Overleaf:
- Engine Check: Click the "Menu" button in the top-left corner of Overleaf and ensure the "Compiler" is set to XeLaTeX.
- Compilation Timeouts: Free Overleaf accounts have a 1-minute compilation timeout. Large theses with high-resolution images may exceed this. If you hit timeouts, consider using
draftmode (explained in the Configuration guide) or migrating to a local installation.
Method 3: Manual Installation from CTAN
If you are on a restricted network or prefer manual package management, you can install the pre-compiled TDS (TeX Directory Structure) archive.
- Download the
fduthesis.tds.ziparchive from the CTAN package page. - Locate your local
texmfdirectory: - Linux / macOS:
~/texmf/ - Windows:
C:\Users\<YourUsername>\texmf\ - Extract the contents of the ZIP file directly into the
texmfdirectory. - Update the TeX filename database so the compiler can index the new files:
mktexlsr
Method 4: Development Version (From GitHub)
If you want to test unreleased features, contribute to the project, or fix a bug, you can build the template directly from the source code using the l3build system.
Prerequisites
Ensure git and a full TeX Live installation are available in your system path.
Build Steps
-
Clone the repository:
git clone https://github.com/stone-zeng/fduthesis.git cd fduthesis -
Run the automated installation script for your OS:
-
Linux / macOS:
./install-unix.sh -
Windows:
install-win.bat
What the script does:
These scripts run l3build unpack to extract the .cls, .def, and .sty files from the documented source (.dtx). It then generates a blank thesis/ directory populated with a starter template. You can begin writing immediately inside this newly created folder.
Troubleshooting Installation
Error: ! LaTeX Error: File 'fduthesis.cls' not found.
- Cause: The package is not installed, or
mktexlsrwas not run after manual installation. - Fix: Use
tlmgr install fduthesisor check your localtexmfpaths.
Error: Font missing errors (e.g., Fandol, XITS, Libertinus).
- Cause:
fduthesisrelies on specific open-source fonts depending on your OS. If your TeX distribution is a "basic" or "minimal" install, these fonts are missing. - Fix: Run
tlmgr install fandol xits libertinus-fonts.