* Re: [kbd] Bug#558492: kbd_1.15.1-1(ia64/unstable): FTBFS: compile errors @ 2009-11-30 19:05 ` Michael Schutte 2009-12-03 0:58 ` Alexey Gladkov 0 siblings, 1 reply; 4+ messages in thread From: Michael Schutte @ 2009-11-30 19:05 UTC (permalink / raw) To: kbd; +Cc: 558492 [-- Attachment #1: Type: text/plain, Size: 1918 bytes --] Hi Alexey! kbd fails to build on several architectures supported by Debian GNU/Linux, namely Alpha, ARM, PA-RISC, IA-64, MIPS and SPARC. This is the relevant part from the original bug report: On Sun, Nov 29, 2009 at 04:53:49AM -0700, lamont@debian.org wrote: > There was an error while trying to autobuild your package: > > > […] > > gcc -DHAVE_CONFIG_H -I. -I.. -DDATADIR=\"/usr/share\" -DLOCALEDIR=\"/usr/share/locale\" -Wall -Wextra -Wmissing-noreturn -Wdisabled-optimization -Wcast-align -Wshadow -Wmissing-format-attribute -Wmissing-prototypes -Wstrict-prototypes -Wmissing-declarations -Werror -funit-at-a-time -Os -g -MT psffontop.o -MD -MP -MF .deps/psffontop.Tpo -c -o psffontop.o psffontop.c > > cc1: warnings being treated as errors > > psffontop.c: In function 'readpsffont': > > psffontop.c:253: error: cast increases required alignment of target type > > make[1]: *** [psffontop.o] Error 1 > > make[1]: Leaving directory `/build/buildd/kbd-1.15.1/src' > > make: *** [build-stamp] Error 2 > > dpkg-buildpackage: error: debian/rules build gave error exit status 2 (If you wish, you can find the full build logs for all architectures at <https://buildd.debian.org/build.cgi?pkg=kbd>.) As far as I can tell, the affected archs align data structures just like the member with the highest alignment. The cast from (char *) to (struct psf2_header *) fails as inputbuf is byte-aligned while the struct’s alignment matches that of int (likely word-aligned). I guess the most “correct” fix is a memcpy() of the input buffer to the correctly aligned address of psfhdr. Simply allowing unaligned access, as forced by “(struct psf_header2 *) (void *) &inputbuf[0]”, might also work, but I don’t know enough about the situation to say this with certainty. I’d be glad about suggestions from your part :-) Cheers, -- Michael Schutte <michi@uiae.at> [-- Attachment #2: Digital signature --] [-- Type: application/pgp-signature, Size: 490 bytes --] ^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [kbd] Bug#558492: kbd_1.15.1-1(ia64/unstable): FTBFS: compile errors 2009-11-30 19:05 ` [kbd] Bug#558492: kbd_1.15.1-1(ia64/unstable): FTBFS: compile errors Michael Schutte @ 2009-12-03 0:58 ` Alexey Gladkov 2009-12-03 18:26 ` Michael Schutte 0 siblings, 1 reply; 4+ messages in thread From: Alexey Gladkov @ 2009-12-03 0:58 UTC (permalink / raw) To: kbd, 558492 On 30.11.2009 22:05, Michael Schutte wrote: > Hi Alexey! > > kbd fails to build on several architectures supported by Debian > GNU/Linux, namely Alpha, ARM, PA-RISC, IA-64, MIPS and SPARC. This is > the relevant part from the original bug report: Thanks for the report. > (If you wish, you can find the full build logs for all architectures at > <https://buildd.debian.org/build.cgi?pkg=kbd>.) > I guess the most “correct” fix is a memcpy() of the input buffer to the > correctly aligned address of psfhdr. Yes. I think this is the most correct way. http://git.altlinux.org/people/legion/packages/kbd.git?p=kbd.git;a=commitdiff;h=d10c22e120863a4dc2dc6fd82431bdb962327891 This should fix the problem. But I checked the only cross-compilation for ARM. Can you confirm fix for other archs? -- Rgrds, legion ^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [kbd] Bug#558492: kbd_1.15.1-1(ia64/unstable): FTBFS: compile errors 2009-12-03 0:58 ` Alexey Gladkov @ 2009-12-03 18:26 ` Michael Schutte 2009-12-08 17:34 ` Michael Schutte 0 siblings, 1 reply; 4+ messages in thread From: Michael Schutte @ 2009-12-03 18:26 UTC (permalink / raw) To: kbd, 558492 [-- Attachment #1: Type: text/plain, Size: 856 bytes --] tag 558492 pending thanks On Thu, Dec 03, 2009 at 03:58:52AM +0300, Alexey Gladkov wrote: > On 30.11.2009 22:05, Michael Schutte wrote: > > I guess the most “correct” fix is a memcpy() of the input buffer to the > > correctly aligned address of psfhdr. > > Yes. I think this is the most correct way. > > http://git.altlinux.org/people/legion/packages/kbd.git?p=kbd.git;a=commitdiff;h=d10c22e120863a4dc2dc6fd82431bdb962327891 Great. I’m applying this for the next Debian revision as well. > This should fix the problem. But I checked the only cross-compilation > for ARM. > > Can you confirm fix for other archs? I just tried a native build on an ARM machine; everything seems fine. Debian’s autobuilders will soon provide feedback regarding the other architectures :-) Cheers, -- Michael Schutte <michi@uiae.at> [-- Attachment #2: Digital signature --] [-- Type: application/pgp-signature, Size: 490 bytes --] ^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [kbd] Bug#558492: kbd_1.15.1-1(ia64/unstable): FTBFS: compile errors 2009-12-03 18:26 ` Michael Schutte @ 2009-12-08 17:34 ` Michael Schutte 0 siblings, 0 replies; 4+ messages in thread From: Michael Schutte @ 2009-12-08 17:34 UTC (permalink / raw) To: kbd [-- Attachment #1: Type: text/plain, Size: 308 bytes --] On Thu, Dec 03, 2009 at 07:26:53PM +0100, Michael Schutte wrote: > I just tried a native build on an ARM machine; everything seems fine. > Debian’s autobuilders will soon provide feedback regarding the other > architectures :-) For the record, all succeeded. -- Michael Schutte <michi@uiae.at> [-- Attachment #2: Digital signature --] [-- Type: application/pgp-signature, Size: 490 bytes --] ^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2009-12-08 17:34 UTC | newest] Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed) -- links below jump to the message on this page -- 2009-11-30 19:05 ` [kbd] Bug#558492: kbd_1.15.1-1(ia64/unstable): FTBFS: compile errors Michael Schutte 2009-12-03 0:58 ` Alexey Gladkov 2009-12-03 18:26 ` Michael Schutte 2009-12-08 17:34 ` Michael Schutte
Linux console tools development discussion This inbox may be cloned and mirrored by anyone: git clone --mirror http://lore.altlinux.org/kbd/0 kbd/git/0.git # If you have public-inbox 1.1+ installed, you may # initialize and index your mirror using the following commands: public-inbox-init -V2 kbd kbd/ http://lore.altlinux.org/kbd \ kbd@lists.altlinux.org kbd@lists.altlinux.ru kbd@lists.altlinux.com public-inbox-index kbd Example config snippet for mirrors. Newsgroup available over NNTP: nntp://lore.altlinux.org/org.altlinux.lists.kbd AGPL code for this site: git clone https://public-inbox.org/public-inbox.git