Summary: | Defaulting <cachedir> to ~/Library/Caches/org.freedesktop.fontconfig for OSX build | ||
---|---|---|---|
Product: | fontconfig | Reporter: | Clayton Walker <clayton.m.walker> |
Component: | conf | Assignee: | fontconfig-bugs |
Status: | RESOLVED WONTFIX | QA Contact: | Behdad Esfahbod <freedesktop> |
Severity: | normal | ||
Priority: | medium | CC: | akira |
Version: | unspecified | ||
Hardware: | x86-64 (AMD64) | ||
OS: | Mac OS X (All) | ||
Whiteboard: | |||
i915 platform: | i915 features: | ||
Attachments: | Defaulting to ~/Library/Caches/org.freedesktop.fontconfig |
it is supposed to point to the system wide caches though, do you not want to share the cache with users on your box? Even though it was the proposal, you could build fontconfig with --with-cache-dir=/Library/Caches/path/to/fontconfig/cachedir. win32's case is a bit special since they require the virtual path and the code to deal with. I don't want to mess up configure script with default paths for each platforms. we has enough facility to change it for you. please use it. Thanks, The thing about OSX is that using non-global Caches _is_ was OSX expects. As per the documentation [1], ~/Library/Caches should be used for bundled applications, as it is the norm. On OSX, Applications are installed as normal users (installed meaning drag'n'drop dmg or using an installer pkg) and there is no location to write a global cache. Also, each OSX user has their own individual ~/Library/Fonts folder that they install fonts to. This folder should not be visible from another user, hence the reliance on a local cache makes more sense on osx. I agree that for MacPorts, Fink, and Brew users it might make sense to simply use the global location (using the default /var directory), but even so, it would be just as beneficial to them as it is to us to have per-user font caches on OSX. I urge you to reconsider. :) [1] https://developer.apple.com/library/ios/documentation/FileManagement/Conceptual/FileSystemProgrammingGuide/MacOSXDirectories/MacOSXDirectories.html (In reply to comment #2) > The thing about OSX is that using non-global Caches _is_ was OSX expects. As > per the documentation [1], ~/Library/Caches should be used for bundled > applications, as it is the norm. Ask for vendors for those applications to build fontconfig with --with-cache-dir=~/Liberary/Caches/path/to/cache then. again, this option is to change the cache dir location. I don't see any reasons to support the default location for each platforms at all. Another way to specify the user-based cache directory, setting up XDG_CACHE_HOME=~/Library/Caches is an option. (In reply to comment #2) > I agree that for MacPorts, Fink, and Brew users it might make sense to > simply use the global location (using the default /var directory), but even > so, it would be just as beneficial to them as it is to us to have per-user > font caches on OSX. I'm not sure if you are aware there are two cache directory locations by default. one is for the system wide (which is able to determine at the build time with --with-cache-dir) and the user specific where is $HOME/.cache/fontconfig on popular Un*x systems and it could be customized by $XDG_CACHE_HOME as I said in the previous comment. for the user own fonts, the user specific cache directory would be better place to store those caches because it can't be picked up by another user as you said. but not that good for the system wide fonts since it takes some disk spaces and having same cache per users is redundant, waste of the disk spaces and CPU load to create caches. So generally speaking configuring the system-wide cache directory at the user space (at least by default as upstream) makes no sense. Yes I can set XDG_CACHE_HOME=~/Library/Caches but that will result in ~/Library/Caches/fontconfig, when ~/Library/Caches/org.freedesktop.fontconfig would be more correct. Is there a way to configure the directory that us used inside XDG_CACHE_HOME? (In reply to comment #5) > Yes I can set XDG_CACHE_HOME=~/Library/Caches but that will > result in ~/Library/Caches/fontconfig, when > ~/Library/Caches/org.freedesktop.fontconfig would be > more correct. Is there a way to configure the directory > that us used inside XDG_CACHE_HOME? You could modify the following line in fonts.conf if you like then: <cachedir prefix="xdg">fontconfig</cachedir> To: <cachedir prefix="xdg">org.freedesktop.fontconfig</cachedir> I'm not quite sure if it is correct since there are no such applications using that java-like namespace schema in the cache directory. Anyway, hope that helps. |
Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.
Created attachment 89379 [details] Defaulting to ~/Library/Caches/org.freedesktop.fontconfig Hi, I package GIMP on OSX. The fontconfig cachedir default is not set on OSX, and uses the default linux/unix directory, which isn't what osx users expect. This patch enables checking for osx, and changing the cachedir to "~/Library/Caches/org.freedesktop.fontconfig".