MEN-Mikro-Elektronik / 13MD05-90

MDIS5 System Package for Linux (including drivers)
Other
4 stars 4 forks source link

Compilation in kernel 6.1 is broken #281

Closed mad-jsanjuan closed 1 year ago

mad-jsanjuan commented 1 year ago

There is something in 6.1 that has changed the way some of the defined guards for VXWORK work. We get this error:

  CC [M]  /home/docker/mdis_test_system/actions-runner/_work/13MD05-90/13MD05-90/mdis_test_system/MDIS_Compilation_Test/OBJ/dbg/men_chameleon/chameleonv2.o
/home/docker/mdis_test_system/actions-runner/_work/13MD05-90/13MD05-90/mdis_test_system/MDIS_Compilation_Test/OBJ/dbg/men_chameleon/chameleonv2.c:270:5: error: "_WRS_VXWORKS_MAJOR" is not defined, evaluates to 0 [-Werror=undef]
  270 | #if _WRS_VXWORKS_MAJOR == 7
      |     ^~~~~~~~~~~~~~~~~~
/home/docker/mdis_test_system/actions-runner/_work/13MD05-90/13MD05-90/mdis_test_system/MDIS_Compilation_Test/OBJ/dbg/men_chameleon/chameleonv2.c: In function 'InitPci':
/home/docker/mdis_test_system/actions-runner/_work/13MD05-90/13MD05-90/mdis_test_system/MDIS_Compilation_Test/OBJ/dbg/men_chameleon/chameleonv2.c:409:5: error: "_WRS_VXWORKS_MAJOR" is not defined, evaluates to 0 [-Werror=undef]
  409 | #if _WRS_VXWORKS_MAJOR == 7
      |     ^~~~~~~~~~~~~~~~~~
/home/docker/mdis_test_system/actions-runner/_work/13MD05-90/13MD05-90/mdis_test_system/MDIS_Compilation_Test/OBJ/dbg/men_chameleon/chameleonv2.c:515:5: error: "_WRS_VXWORKS_MAJOR" is not defined, evaluates to 0 [-Werror=undef]
  515 | #if _WRS_VXWORKS_MAJOR == 7
      |     ^~~~~~~~~~~~~~~~~~

We need to fix this and also find why this only affects 6.1 and not older versions.

mad-jsanjuan commented 1 year ago

The issue is that they have added -Werror in the main Makefile in the kernel: https://github.com/torvalds/linux/commit/3fe617ccafd6f5bb33c2391d6f4eeb41c1fd0151

mad-jsanjuan commented 1 year ago

Almost fixed. Just missing this one bit: https://github.com/MEN-Mikro-Elektronik/13MD05-90/issues/283

mad-jrodriguez commented 1 year ago

Closing the issue. Further discussions should be done in #283 or in a new ticket.