How to upgrade MinGW for Code::blocks


The LVGL V9 version has updated many new features, and the Windows platform has also been optimized. If you are using Code::blocks to experience LVGL, it will not pass during compilation; Because if you are using Code::blocks 20.03 and using the built-in MinGW, you will encounter the following problems due to the low version of MinGW:

D:\lv_port_win_codeblocks\lvgl\src\drivers\windows\lv_windows_context.c|141|error: 'CREATE_WAITABLE_TIMER_MANUAL_RESET' undeclared (first use in this function)|

Upgrade steps

  1. Get the updated version of MinGW (recommended version 13.2.0, it has been tested):
  2. Open the MinGW directory installed in Code:: blocks 20.03 (default installation directory is C:\Program Files\CodeBlocks\MinGW) and delete all contents:
  3. Extract the content of the downloaded MinGW compressed file to the C:\Program Files\CodeBlocks\MinGW directory:

  4. Open the project and rebuild it: