PLCnext / PLCnext_CLI

The PLCnext CLI is our tool for programming in high level languages for the PLCnext Technology ecosystem. Build an up-to-date version of the PLCnext CLI that includes the very latest bug fixes, or even build your own customised version. Test the newest features or contribute your ideas.
Apache License 2.0
10 stars 3 forks source link

ERROR: The Target is installed more that once. Please check your installed targets. #4

Closed emuenz closed 3 years ago

emuenz commented 3 years ago

Initial Customer Request:

Dear colleagues,

I have downloaded the SDKs from respected Download areas of the AXC F 1152 and AXC F 2152 products.

After that, I installed the PLCnCLI.

​Following that, I used the following command in the Command Prompt:

cd C:\Program Files\Phoenix Contact\PLCnCLI

And, after that, I used this commad:

plcncli install sdk -p "C:\Users\My_User_Name\Downloads\PLCnCLI_SDK_2020.6.1_Windows_AXC_F_1152\pxc-glibc-x86_64-mingw32-axcf1152-image-mingw-cortexa9t2hf-neon-axcf2152-toolchain-2020.6.tar.xz" -d C:\SDKs\AXCF1152\2020.6\

plcncli install sdk -p "C:\Users\My_User_Name\Downloads\PLCnCLI_SDK_2020.6.1_Windows_AXC_F_2152\pxc-glibc-x86_64-mingw32-axcf2152-image-mingw-cortexa9t2hf-neon-axcf2152-toolchain-2020.6.tar.xz" -d C:\SDKs\AXCF2152\2020.6\

Following this, I installed the new software in the Eclipse, but everytime at the startup I get the following error: "The Target is installed more that once. Please check your installed targets."

​And really, it looks like this target is installed more than once.

I kindly ask if you could suggest a solution.

mluhmann commented 3 years ago

Hi emuenz,

currently there is no check for duplicate SDK installation other than having an empty target folder (-d) or an already used path name. With "plcncli install <...> --force" or the command "plcncli set setting SdkPaths" its possible to add an sdk twice if there is a difference in the way the path is written e.g.

This can easily happen with autocomplete in the different windows shells. A better check of duplicate sdks will be implemented during next year.

If you run into the issue you have to to identify the defective sdk entry and remove it manually. For this do the following:

  1. Check the settings.xml for the duplicate entry (%APPDATA%\plcncli\settings.xml)
  2. Use the command plcncli set setting SdkPaths -r <path/of/the/duplicate/sdk/entry>

This will remove one of the entries and should fix the issue.

emuenz commented 3 years ago

The cause of failure was duplicate Target entry.