Bug 91666

Summary: build fail with cunit - OK on amd64 - KO for i386
Product: DRI Reporter: Fabio Pedretti <pedretti.fabio>
Component: libdrmAssignee: Default DRI bug account <dri-devel>
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: medium CC: ckoenig.leichtzumerken
Version: DRI git   
Hardware: x86 (IA32)   
OS: Linux (All)   
Whiteboard:
i915 platform: i915 features:

Description Fabio Pedretti 2015-08-17 09:51:51 UTC
amd64 builds OK:
Full build log:
https://launchpadlibrarian.net/214693325/buildlog_ubuntu-vivid-amd64.libdrm_2.4.63%2Bgit1508171138.f05a74~gd~v_BUILDING.txt.gz

Same source package breaks with i386:
In file included from ../../../amdgpu/amdgpu_internal.h:35:0,
                 from ../../../tests/amdgpu/cs_tests.c:32:
../../../libdrm_macros.h: In function 'drm_munmap':
../../../libdrm_macros.h:79:4: error: size of unnamed array is negative
    STATIC_ASSERT(LARGE_OFF_T % 2147483629 == 721 &&
    ^
Full i386 build log:
https://launchpadlibrarian.net/214693090/buildlog_ubuntu-vivid-i386.libdrm_2.4.63%2Bgit1508171138.f05a74~gd~v_BUILDING.txt.gz
Comment 1 Michel Dänzer 2015-08-17 09:57:57 UTC
commit 25784d3af2f37d86fb25ee6cfa4afa6f3448af9b
Author: Michel Dänzer <michel.daenzer@amd.com>
Date:   Mon Aug 17 18:41:11 2015 +0900

    tests/amdgpu: Include config.h first
Comment 2 network723 2017-10-28 10:25:37 UTC
Same error while 32-bit build with git master commit 33dcc29f7ccc554de1fc42f4b95adf056822eabb:

[   62s] libtool: compile:  gcc -std=gnu99 -DHAVE_CONFIG_H -I. -I.. -DAMDGPU_ASIC_ID_TABLE=\"/usr/share/libdrm/amdgpu.ids\" -DAMDGPU_ASIC_ID_TABLE_NUM_ENTRIES=154 -Wall -Wextra -Wsign-compare -Werror-implicit-function-declaration -Wpointer-arith -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -Wmissing-declarations -Wnested-externs -Wpacked -Wswitch-enum -Wmissing-format-attribute -Wstrict-aliasing=2 -Winit-self -Wdeclaration-after-statement -Wold-style-definition -Wno-unused-parameter -Wno-attributes -Wno-long-long -Winline -Wshadow -Wno-missing-field-initializers -I.. -I../include/drm -fomit-frame-pointer -fmessage-length=0 -grecord-gcc-switches -O2 -Wall -D_FORTIFY_SOURCE=2 -fstack-protector -funwind-tables -fasynchronous-unwind-tables -fno-strict-aliasing -c amdgpu_bo.c  -fPIC -DPIC -o .libs/amdgpu_bo.o
[   62s] In file included from amdgpu_internal.h:35:0,
[   62s]                  from amdgpu_vm.c:28:
[   62s] ../libdrm_macros.h: In function 'drm_munmap':
[   62s] ../libdrm_macros.h:79:4: error: size of unnamed array is negative
[   62s]     STATIC_ASSERT(LARGE_OFF_T % 2147483629 == 721 &&
[   62s]     ^
[   62s] Makefile:708: recipe for target 'amdgpu_vm.lo' failed
Comment 3 Michel Dänzer 2017-10-30 09:43:33 UTC
(In reply to network723 from comment #2)
> Same error while 32-bit build with git master commit
> 33dcc29f7ccc554de1fc42f4b95adf056822eabb:

It's not exactly the same, so it would have been better to file your own report than to reopen this one.

Please attach your corresponding config.h and config.log files.
Comment 4 Fabio Pedretti 2017-11-01 08:04:11 UTC
Fixed in 2.4.87.

Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.