Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
Delphi GetIt Dependency Compile Build Error Fix


When setting GetIt dependencies on a project, Emarcadero Delphi 10.2 Tokyo will fail the build with this error:

Project [...] (Make target(s)):
Target _CheckGetItPackageDependencies:
    Target _ExecGetItCmd:
        c:\program files (x86)\embarcadero\studio\19.0\bin\CodeGear.Common.Targets : warning : Checking GetIt package dependencies
        c:\program files (x86)\embarcadero\studio\19.0\bin\CodeGear.Common.Targets(305,5): error MSB4018: The "GetItCmd" task failed unexpectedly.
        c:\program files (x86)\embarcadero\studio\19.0\bin\CodeGear.Common.Targets(305,5): error MSB4018: System.NullReferenceException: Object reference not set to an instance of an object.
        c:\program files (x86)\embarcadero\studio\19.0\bin\CodeGear.Common.Targets(305,5): error MSB4018:    at Borland.Build.Tasks.Common.CommandLineTask.Execute()
        c:\program files (x86)\embarcadero\studio\19.0\bin\CodeGear.Common.Targets(305,5): error MSB4018:    at Borland.Build.Tasks.Shared.GetItCmd.Execute()
        c:\program files (x86)\embarcadero\studio\19.0\bin\CodeGear.Common.Targets(305,5): error MSB4018:    at Microsoft.Build.BuildEngine.TaskEngine.ExecuteInstantiatedTask(EngineProxy engineProxy, ItemBucket bucket, TaskExecutionMode howToExecuteTask, ITask task, Boolean& taskResult)
    Done building target "_ExecGetItCmd" in project [...] -- FAILED.
Done building target "_CheckGetItPackageDependencies" in project [...] -- FAILED.


Set the BDSHost environment variable to true in the Delphi IDE settings:

  1. Go to Tools > Options.
  2. Go to Environment Options > Environment Variables.
  3. Under User overrides, click New.
  4. Variable name: BDSHost, Variable value: true.

This comment has been minimized.

Copy link

commented Jun 25, 2019


Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.