Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[cpackget] extract license file fails if the location is in a subdirectory of the pack #232

Closed
jkrech opened this issue Dec 11, 2023 · 0 comments
Assignees
Labels
bug Something isn't working fixed

Comments

@jkrech
Copy link
Member

jkrech commented Dec 11, 2023

Describe the bug
cpackget V2.0.0

When the <license> references a file in a sub-directory of the pack, the license is not extracted correctly

To Reproduce
Steps to reproduce the behavior:

  1. Run the cpackget: cpackget add TexasInstruments::MSPM0L11XX_L13XX_DFP
  2. When asked to [A]ccpet [C]ancle or [E]xtract choose E
  3. See error
I: Extracting embedded license to C:\Users\jkrech\AppData\Local\Arm\Packs\.Download\TexasInstruments.MSPM0L11XX_L13XX_DFP.1.2.1.pack.01_Pack\license.txt
E: open C:\Users\jkrech\AppData\Local\Arm\Packs\.Download\TexasInstruments.MSPM0L11XX_L13XX_DFP.1.2.1.pack.01_Pack\license.txt: The system cannot find the path specified.

NOTE: I the user accepts the license, the license file is currently not stored at all and wrong path to the license file is provided to invoking tools (e.g. MDK PackInstaller). While the cpackget CLI installation completes successfully without the license being stored, an integrating tool cannot find nor display the license and the pack cannot be installed successfully.

Expected behavior
The license file shall be stored regardless or pack location in a file named:

C:\Users\jkrech\AppData\Local\Arm\Packs\.Download\TexasInstruments.MSPM0L11XX_L13XX_DFP.1.2.1.pack.lic.txt
$CMSIS_PACK_ROOT/.Download/<vendor>.<name>.<version>.pack.lic.<ext>

Environment:

  • OS: all
  • Version Win10
@jkrech jkrech added the bug Something isn't working label Dec 11, 2023
@jkrech jkrech moved this to Todo in CMSIS-Toolbox 2.3.0 Jan 3, 2024
jkrech pushed a commit that referenced this issue Jan 9, 2024
… file path (#238)

fixed:
golang "path" object has issues handling backslash, changed to filepath
object.

also see: #232
@jkrech jkrech moved this from Todo to In Progress in CMSIS-Toolbox 2.3.0 Jan 9, 2024
@jkrech jkrech closed this as completed Jan 9, 2024
@github-project-automation github-project-automation bot moved this from In Progress to Done in CMSIS-Toolbox 2.3.0 Jan 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working fixed
Projects
No open projects
Development

No branches or pull requests

2 participants