qmake语言,如何获取当前文件夹名称?

qmake Language, how to get current folder name?

问题:

How to read file content into a qmake variable and pass it to the compiler?

通过qmake解决读取文本文件的问题。

我不想读取文本文件,而是想获取当前文件夹(此文件所在的文件夹)名称。我该怎么做?

$$PWD做你想做的事吗?

来自文档:

The PWD variable specifies the full path leading to the directory containing the current file being parsed. This can be useful to refer to files within the source tree when writing project files to support shadow builds.