首页 > 解决方案 > 英特尔的 oneapi C 编译器不生成调试信息

问题描述

我有一些简单的代码

#include <stdio.h>
#include <stdlib.h>

int main()
{
        printf("Hello world\n");
        return EXIT_SUCCESS;
}

我想调试它,所以我像这样编译

icl.exe /Z7 /debug:all /Od main.c -o test.exe

然后我运行调试器

gdb-oneapi

但是当我加载文件时,出现以下错误:

(gdb) file test.exe
Reading symbols from test.exe...
(No debugging symbols found in test.exe)

我错过了一些重要的标志吗?

标签: debugginggdbiccintel-oneapiintel-gdb

解决方案


推荐阅读