intel / dptf

Other
87 stars 32 forks source link

Error RHEL8.2 compilation ‘__builtin_memcpy’ reading 63 bytes from a region of size 4 #31

Closed GoPerry closed 4 years ago

GoPerry commented 4 years ago

In file included from /usr/include/string.h:495, from ../../ESIF_CM/Sources/esif.h:192, from ../../ESIF_UF/Sources/esif_uf.h:22, from ../../ESIF_UF/Sources/lin/esif_uf_sysfs_enumerate_os_lin.c:20: In function ‘memmove’, inlined from ‘newParticipantCreate.constprop’ at ../../../../Common/esif_ccb_string_lin_user.h:43:3: /usr/include/bits/string_fortified.h:40:10: error: ‘builtin_memcpy’ reading 63 bytes from a region of size 4 [-Werror=stringop-overflow=] return _builtinmemmove_chk (dest, src, len, bos0 (dest)); ^~~~~~~~~~~~~~~ In function ‘memmove’, inlined from ‘SysfsRegisterParticipants’ at ../../../../Common/esif_ccb_string_lin_user.h:43:3: /usr/include/bits/string_fortified.h:40:10: error: ‘__builtin_memcpy’ reading 63 bytes from a region of size 8 [-Werror=stringop-overflow=] return builtin_memmove_chk (dest, src, len, bos0 (dest)); ^~~~~~~~~~~~~~~ In function ‘memmove’, inlined from ‘SysfsRegisterParticipants’ at ../../../../Common/esif_ccb_string_lin_user.h:43:3: /usr/include/bits/string_fortified.h:40:10: error: ‘builtin_memcpy’ reading 63 bytes from a region of size 3 [-Werror=stringop-overflow=] return _builtinmemmove_chk (dest, src, len, bos0 (dest)); ^~~~~~~~~~~~~~~ In function ‘memmove’, inlined from ‘SysfsRegisterParticipants’ at ../../../../Common/esif_ccb_string_lin_user.h:43:3: /usr/include/bits/string_fortified.h:40:10: error: ‘__builtin_memcpy’ reading 63 bytes from a region of size 11 [-Werror=stringop-overflow=] return builtin_memmove_chk (dest, src, len, bos0 (dest)); ^~~~~~~~~~~~~~~ In function ‘memmove’, inlined from ‘SysfsRegisterParticipants’ at ../../../../Common/esif_ccb_string_lin_user.h:43:3: /usr/include/bits/string_fortified.h:40:10: error: ‘builtin_memcpy’ reading 63 bytes from a region of size 10 [-Werror=stringop-overflow=] return _builtinmemmove_chk (dest, src, len, bos0 (__dest)); ^~~~~~~~~~~~~~~ cc1: all warnings being treated as errors make: *** [Makefile:190: ../../ESIF_UF/Sources/lin/esif_uf_sysfs_enumerate_os_lin.o] Error 1

GoPerry commented 4 years ago

@bbian
Could you help to take a look how to fix the build error? It is built under RHEL8.2 kernel.