这是我的目录结构:
C:.
│ lodepng.h
│ lodepng.c
│ nim.cfg
│ test.png
│ util.nim
│
└───nimcache
util nim 正在从 lodepng.h 导入 ac 函数,如下所示:
proc loadPNG(image: var ptr[cchar], width, height: var cuint, filename: cstring)
{.importc: "lodepng_decode32_file", header: "lodepng.h".}
但是头文件没有复制到 nimcache 中,编译代码时也找不到。我如何确保 nim 编译器使用它?