Re: i386/conf/ALL compile error

Kamil Rytarowski <[email protected]>
Newsgroups gmane.os.netbsd.ports.i386
Message-ID <[email protected]>
On 29.05.2019 16:10, SAITOH Masanobu wrote:
> Hi.
> 
> While compiling i386/conf/ALL
> 
>> ../../../../arch/i386/i386/trap.c: In function 'trap':
>> ../../../../arch/i386/i386/trap.c:470:61: error: format '%lx' expects argument of type 'long unsigned int', but argument 7 has type 'register_t {aka int}' [-Werror=format=]
>>    printf("pid %d.%d (%s): BUS/SEGV (%#x) at eip %#x addr %#lx\n",
>>                                                           ~~~^
>>                                                           %#x
>>        p->p_pid, l->l_lid, p->p_comm, type, frame->tf_eip, rcr2());
>>                                                            ~~~~~~
>> ../../../../arch/i386/i386/trap.c:511:50: error: format '%lx' expects argument of type 'long unsigned int', but argument 6 has type 'register_t {aka int}' [-Werror=format=]
>>    printf("pid %d.%d (%s): ILL at eip %#x addr %#lx\n",
>>                                                ~~~^
>>                                                %#x
>>        p->p_pid, l->l_lid, p->p_comm, frame->tf_eip, rcr2());
>>                                                      ~~~~~~
>> cc1: all warnings being treated as errors
>> *** [trap.o] Error code 1
> 
> 

Please use PRIxREGISTER.
signature.asc (application/pgp-signature, 833 B)
-----BEGIN PGP SIGNATURE-----

iQIzBAEBCAAdFiEELaxVpweEzw+lMDwuS7MI6bAudmwFAlzuk2YACgkQS7MI6bAu
dmw8Iw//bzc7mTdlJDSDPCzfQZp1XSVzA+i/OJXB3dq+J8XloTJNsZcVSa7uRJXF
Bgqp2aljGqm4dQbkel13CBkq1AtSCz9bT6+4fcAq3iIu6lETdhtb6GR7eOkPrFzq
Hm966wV4o6OYpLBCYLjOB5lpc8qtCX4vFP/oOkQbEEsbXi3RaoJysWloJqZmdMbC
ktBHZM8pvTU+rXDtWLSLqi9OvaUq3AF+mTfGL1lWwslQsSSD4MyHuq4dqTXLcls+
VN21R7fAsDSnUcManXQTiGwu5O1IS6DFkVUaJspPqdE5rNAF/ZdLmQxZfmUmXmLt
DB7kCCTiZpCy4FKlNKW4Yyccm3tXBuUS9vy0cf6tMr4+7q0luEo7dBAQLLRT4Z75
F/0B3H+QU7iSpd3A+yPmWgogk9tmnFSmATDlrJfd0IqNJU02xwc/ddRg1uLAHUT4
i/5qjhqcUuz5+0e38Jt0EgeXf5XI2Iqb/SID4aQXc+VKHRfGoaQaBssDv3pK6v01
k2xatLUp72JIJ83uwnv9tY2hRng+Od8IovphK3XzkliNO88hVd27DYcK/J5Wmhzq
kDf1PmoF7BYq20y5UxuFtGxWGJUinuHraU3q0sec/2dR3biEHzT/MXEYHHZ1h++l
gi5nkGnYlk9ArSRhUuOHreiyaqrLtGMzJm+xqwfJLOurXVDnMjY=
=wZNz
-----END PGP SIGNATURE-----
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.