Re: [PATCH] Do not remove UUID file when a scanned directory is empty 1 x

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, Nov 5, 2018 at 6:18 PM Alexander Larsson
<alexander.larsson@xxxxxxxxx> wrote:
> I don't see why we can't just fix the empty-directory regenerating
> uuid case instead?

Because people doesn't want to see creating a file under
/usr/share/fonts say on host. that's the most concerns/complaints I've
ever seen and this way may looks negative approach like returning to
the old behavior where we had created cache files under /usr in the
past I guess.

Hmm, I totally missed the point that flatpaks can have own fonts in
the container under /usr/share/fonts where the host fonts is installed
and could be different. indded mapping font directories may not help
in this case.

For another idea that satisfies not creating a file under /usr, can
flatpak rebuild symlinks at the startup time?
That is to represent mapping between UUID (or the unique value if it
doesn't like) and dir to a symlink.

The directory structure looks like at host:
/path/to/fontconfig/caches/on/host/
  \___<unique value>-le64.cache-7
/path/to/fontconfig/dirs/on/host/:
   \___<unique value>.dir -> /usr/share/fonts/foo

At the container:
/run/host/fonts-cache/
  \___<unique value>-le64.cache-7
/run/host/fonts-dirs/ or somewhere else:
  \___<unique value>.dir -> /run/host/fonts/foo

So fontconfig can knows where it is from symlink instead of the
location of .uuid file. look at the filename of symlink to access
cache. then can open caches against it or update as needed. flatpaks
just needs to create symlinks with the same filename but to the proper
paths. it can be used instead of <dir> elements in config file
perhaps.

Eventually fontconfig should drops the hardcoded paths in cache and
need to change API too to get the real path for current env. this can
be the plan for next major release,  fontconfig 3 in the future, but
anyway.


>
> [1] https://github.com/debarshiray/fedora-toolbox
> _______________________________________________
> Fontconfig mailing list
> Fontconfig@xxxxxxxxxxxxxxxxxxxxx
> https://lists.freedesktop.org/mailman/listinfo/fontconfig



--
Akira TAGOH
_______________________________________________
Fontconfig mailing list
Fontconfig@xxxxxxxxxxxxxxxxxxxxx
https://lists.freedesktop.org/mailman/listinfo/fontconfig




[Index of Archives]     [Fedora Fonts]     [Fedora Users]     [Fedora Cloud]     [Kernel]     [Fedora Packaging]     [Fedora Desktop]     [PAM]     [Gimp Graphics Editor]     [Yosemite News]

  Powered by Linux