After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 651252 - Touching po file triggers rebuild of all languages
Touching po file triggers rebuild of all languages
Status: RESOLVED FIXED
Product: yelp-tools
Classification: Core
Component: yelp.m4
git master
Other Linux
: Normal minor
: ---
Assigned To: Yelp maintainers
Yelp maintainers
Depends on:
Blocks:
 
 
Reported: 2011-05-27 13:46 UTC by Luc Pi
Modified: 2011-11-21 14:59 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Use stamp files to reduce rebuilds (2.37 KB, patch)
2011-09-15 14:14 UTC, Shaun McCance
committed Details | Review

Description Luc Pi 2011-05-27 13:46:08 UTC
touching one .po triggers regeneration of all pages for all languages.

make fails on its essential feature: rebuilding only what needs to be.

(Possibly valid for others documents using mallard)
Comment 1 Shaun McCance 2011-09-15 14:14:32 UTC
Created attachment 196630 [details] [review]
Use stamp files to reduce rebuilds

make's patterns are just very limiting. The only way I can think to solve this is with stamp files, and I'm not sure I want to go that route. I'm attaching a patch I just cooked up so others can play with it. With this patch, this does what you'd expect:

$ touch de/de.po
$ make

The stamps are what make believes are actually built. For convenience, the LC files and directories depend on the stamps, so you can just type "make de" or "make de/index.page". It's not all perfect, though. Due to make's limiting patterns, this will still result in everything being rebuilt:

$ rm */*.stamp
$ make de

You'd expect for just the de docs to be rebuilt, but the lc directories just depend on all the stamps, and I can't map the dependencies correctly with make's patterns. This does work though:

$ rm */*.stamp
$ make de/de.stamp

So it's just the convenience targets that aren't perfect.
Comment 2 Luc Pi 2011-09-16 11:59:17 UTC
I can't really review as I did not write Makefiles and such for many years, but I will try it. Thanks!
Comment 3 Shaun McCance 2011-09-18 22:50:03 UTC
This patch also fixes bug #659421. I'll probably apply it or something similar for 3.3.x.
Comment 4 Shaun McCance 2011-11-21 14:59:44 UTC
Pushed the patch to master.