psp-gcc -I. -IC:/pspsdk/psp/sdk/include -O2 -G0 -Wall -D_PSP_FW_VERSION=150 -L. -LC:/pspsdk/psp/sdk/lib main.o -lpspdebug -lpspdisplay -lpspge -lpspctrl -lpspsdk -lc -lpspnet -lpspnet_inet -lpspnet_apctl -lpspnet_resolver -lpsputility -lpspuser -lpspkernel -o controller_basic.elf它使用-I。
它还使用-L。
请注意它们后面的点,那不是语法点,而是命令本身中的一个点,我不知道它是干什么的,我怀疑在不花几天时间阅读它的情况下,我不会在正式文档上找到任何东西。
发布于 2020-01-21 02:11:44
. (点)是指当前目录。因此,这些选项指定在当前目录中搜索任何必需的头文件(-I.)和任何所需的库(-L.)。
GCC手册上的:
-Idir
Add the directory dir to the head of the list of directories to be searched for header files.
-Ldir
Add directory dir to the list of directories to be searched for -l.
-l library
Search the library named library when linking.来自POSIX规范:
The special filename dot shall refer to the directory specified by its predecessor.https://stackoverflow.com/questions/59833274
复制相似问题