Comment 3 for bug 1872671

Revision history for this message
Albert Damen (albrt) wrote :

Trying to build the focal proposed package, it seems adding the mo files to SOURCES.txt with sed instead of regenerating SOURCES.txt does the job.

I changed debian/rules:
#rm -f horizon.egg-info/SOURCES.txt
sed -i 's/\(.*\)po$$/\1po\n\1mo/' horizon.egg-info/SOURCES.txt

Building the package with the original sources.txt, regenerating sources.txt and changed sources.txt gives:

Counting non .mo files in python3-django-horizon_18.3.2-0ubuntu0.20.04.1_all.deb
Original SOURCES.txt: 4335
Regenerated SOURCES.txt: 4301
Changed SOURCES.txt: 4335

Counting .mo files
Original SOURCES.txt: 0
Regenerated SOURCES.txt: 96
Changed SOURCES.txt: 96

So changing SOURCES.txt adds the same number of .mo files without losing any non .mo file.

Also it doesn't loose any .json files:
Original SOURCES.txt: 21
Regenerated SOURCES.txt: 3
Changed SOURCES.txt: 21

The resulting package works fine and solves the problems for non-admin users.