The build works on your local machine even using Administrator command line. Can you elaborate on what steps you took so that I can reproduce this issue, maybe I'm doing something differently?
The problem occurs when the build is attempted from external automation servers like Jenkins, TeamCity etc. We are looking into this issue and this occurs on PSoC Creator v4.2.
Please use the workaround of creating the projects in PSoC Creator version 4.0 and then building it in TeamCity. That will work.
I will provide you an update once we have the issue resolved with Creator 4.2.
The build doe not work on my machine when using an admin command line.
Here's what I did on a fresh install of Windows 10 build 17134.285:
1) Install PSoC Creator 4.2 under my user account. I did NOT run the installer as administrator.
2) Open up an administrator command line (start->cmd->right click->"Run as Administrator")
3) Execute "C:\Program Files (x86)\Cypress\PSoC Creator\4.2\PSoC Creator\bin\cyprjmgr.exe" with it pointing to my workspace file
cyprjmgr.exe will fail, return error code 3, and output the error message "Error: prj.M0274: Unable to initialize system dependencies. Absolute path is required. 'PSoC Creator\4.2' is not an absolute path."
Also, the workspace cannot be opened or build with PSoC Creator V4.0 because it was originally created with V4.1