@hskoglund I tried specifying the path the way you proposed. I can now build correctly and both lines aren't instantly flagged, but rebuilding the whole project is still giving me the same issue.
I don't know if it's related, but while trying to run the programme, it crashes and tell me that dxl_x64_cpp.dll could not be found.
I accidently put the dll file into the MinGW debug folder rather than in the MSVC folder. I can launch the app now.
It still give me the error mentioned in the title when I rebuild, but I no longer encounter any issue while building.
Thank you all!