[Bug 501593] Re: rpm build bad magic is caused by locale dependance

Elan Ruusamäe glen at delfi.ee
Wed Dec 30 14:44:49 CET 2009


in other words, (so jbj can't read rpm is blamed again), both
rpmbuild(1) and file(1) fail under utf8 locale, both "succeed" on C
locale.

and imho either rpm or limagic should iconv the result before printing
out with vasprintf(2).

-- 
rpm build bad magic is caused by locale dependance
https://bugs.launchpad.net/bugs/501593
You received this bug notification because you are subscribed to PLD
Linux.

Status in PLD Linux Distribution: New

Bug description:
asterisk-sounds-core package building fails, as rpmbuild finds bad magic:

error: magic_file(ms, ".../usr/share/asterisk/sounds/vm-onefor.sln16") failed: mode 37777700644 DOS executable (device driver)vasprintf failed (Invalid or incomplete multibyte or wide character)
rpmbuild: rpmfc.c:1366: rpmfcClassify: Assertion `ftype != ((void *)0)' failed.

however, file(1) seems NOT to fail if invoked in non-utf8 locale:

$ LC_ALL=en_US.utf8 file vm-onefor.sln16
vm-onefor.sln16: ERROR: DOS executable (device driver)vasprintf failed (Invalid or incomplete multibyte or wide character)

$ LC_ALL=C file vm-onefor.sln16
vm-onefor.sln16: DOS executable (device driver), name: \377\001\377\377\375\375\375\377\377\261




More information about the pld-bugs mailing list