Arch Linux

Please read this before reporting a bug:
https://wiki.archlinux.org/title/Bug_reporting_guidelines

Do NOT report bugs when a package is just outdated, or it is in the AUR. Use the 'flag out of date' link on the package page, or the Mailing List.

REPEAT: Do NOT report bugs for outdated packages!
Tasklist

FS#11390 - /etc/locale.gen.pacnew doesn't exists

Attached to Project: Arch Linux
Opened by SKOCDOPOLE Tomas (skocdopolet) - Wednesday, 03 September 2008, 14:54 GMT
Last edited by Jan de Groot (JGC) - Monday, 27 October 2008, 09:27 GMT
Task Type Bug Report
Category Packages: Core
Status Closed
Assigned To Jan de Groot (JGC)
Architecture All
Severity Very Low
Priority Normal
Reported Version None
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 0
Private No

Details

Description:

Hello,

Today I have upgrade system (pacman -Syu) and I get this output from Pacman. So I tried to find /etc/locale.gen.pacnew for view, but I wasn't it found.

==> ATTENTION INTERNATIONAL USERS:
==>
==> Locales are no longer included in the glibc package.
==> They are generated by /usr/sbin/locale-gen depending on the contents
==> of /etc/locale.gen.
==> glibc will try to autodetect the required locales now, if you need
==> additional locales, please enable them in /etc/locale.gen and run
==> /usr/sbin/locale-gen
==>
==> Check [b]/etc/locale.gen.pacnew[/b] for new supported locales
==>
This task depends upon

Closed by  Jan de Groot (JGC)
Monday, 27 October 2008, 09:27 GMT
Reason for closing:  Fixed
Additional comments about closing:  Fixed in svn. Will get its way to core on the next toolchain update.
Comment by Gavin Bisesi (Daenyth) - Wednesday, 03 September 2008, 17:42 GMT
A pacnew file only exists if the file has been changed.
Comment by Jens Adam (byte) - Wednesday, 03 September 2008, 17:43 GMT
If it doesn't exist after the glibc upgrade (that's the pkg where the message comes from), it simply means there has nothing changed in /etc/locale.gen between both package versions.
Comment by SKOCDOPOLE Tomas (skocdopolet) - Wednesday, 03 September 2008, 18:00 GMT
But I edited my locale.gen file - I uncommented line for cs_CZ.UTF8 locale.

Regards Tomas
Comment by Jens Adam (byte) - Wednesday, 03 September 2008, 19:39 GMT
That's normal, see the pacman manpage, section "Handling Config Files":
Pacman uses the same logic as rpm to determine action against files that are designated to be backed up. During an upgrade, 3 md5 hashes are used for each backup file to determine the required action: one for the original file installed, one for the new file that's about to be installed, and one for the actual file existing on the filesystem. After comparing these 3 hashes, the follow scenarios can result:
[...snip...]
original=X, current=Y, new=X
Both package versions contain the exact same file, but the one on the filesystem has been modified. Leave the current file in place.
[...snip...]
Comment by SKOCDOPOLE Tomas (skocdopolet) - Thursday, 04 September 2008, 07:01 GMT
OK, so then should not be in Pacmans output this line:
==> Check /etc/locale.gen.pacnew for new supported locales

(if is technically posible).

Regards Tomas
Comment by Gavin Bisesi (Daenyth) - Thursday, 04 September 2008, 13:24 GMT
It would be pretty easy to add a test -f to the post_upgrade function. I think by the time it gets there the pacnew is in place. Anyone know for sure?
Comment by Roman Kyrylych (Romashka) - Saturday, 06 September 2008, 08:03 GMT
@ Jan & Dan: am I correct in my understanding that the only "problem" here is that "==> Check /etc/locale.gen.pacnew for new supported locales" shouldn't be printed when the file doesn't exist?
Comment by Jan de Groot (JGC) - Saturday, 06 September 2008, 08:19 GMT
I think this message should be changed yes. First of all, anyone that has a recent glibc will know that locales should be setup in /etc/locale.gen, no need to notify them about it. Second, Archlinux users are familiar with pacnew files. When pacman upgrades glibc, it will show "Warning: /etc/locale.gen extracted as /etc/locale.gen.pacnew". Isn't that a hint too?

I'd like to move this installation message to post_upgrade and check for the previous version of glibc. If it's old enough, it should print, otherwise not.
Comment by Gavin Bisesi (Daenyth) - Saturday, 06 September 2008, 13:46 GMT
+1, isn't that the entire reason that you have those versions as parameters?
Comment by Dan McGee (toofishes) - Sunday, 07 September 2008, 15:33 GMT
Sounds like you have this taken care of, Jan?

Loading...