Home > Back-end >  Qbs cannot get PWD file on MacOS
Qbs cannot get PWD file on MacOS

Time:08-20

I want to use my script as cpp.compilerWrapper: ["../../script"]

I'm using relative path (from my .qbs file) to point the script. It works OK na linux. but on macOS doesn't.

Also when I'm using var path = Environment.getEnv("PWD") on linux return correct path. but on macOS just /.

Anyone haS idea why it doesn't work on macOS or maybe know to get this path in other way ?

CodePudding user response:

It works only by accident. You should not rely on relative paths in that context. Instead, say: cpp.compilerWrapper: [path "/../../script"]

  • Related