[Fontconfig] Is there a way to set the cache directory using environment variables?

Andreas Falkenhahn andreas at falkenhahn.com
Thu Aug 10 14:33:21 UTC 2023


Hi,

on Windows I'm using prebuilt fontconfig binaries provided by the MSYS2 project. I want my app to run on systems without MSYS2, however, so I can't use the default fontconfig directories hard-coded into MSYS2's fontconfig build because they only exist if MSYS2 is installed. Luckily, I can use the environment variables FONTCONFIG_FILE and FONTCONFIG_PATH to override the MSYS2-specific configuration in the prebuilt fontconfig binaries and set my own directories for fontconfig this way.

However, I don't seem to find a way to set the path where fontconfig stores its cache files. It always uses the path hard-coded in the binary but this only exists if MSYS2 is installed. Is there any way to override the MSYS2 cache directory or do I have to build fontconfig myself to do that? 

Thanks!

-- 
Best regards,
 Andreas Falkenhahn                          mailto:andreas at falkenhahn.com



More information about the Fontconfig mailing list