Skip to content

Commit

Permalink
Removed support for compile --vid-pid
Browse files Browse the repository at this point in the history
  • Loading branch information
cmaglie committed Mar 24, 2023
1 parent 18c2618 commit f6f4a34
Show file tree
Hide file tree
Showing 7 changed files with 5 additions and 160 deletions.
5 changes: 5 additions & 0 deletions docs/UPGRADING.md
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,11 @@ $ arduino-cli outdated --format json
}
```

### Command `compile` does not support `--vid-pid` flag anymore

It was a legacy and undocumented feature that is now useless. The correspondin field in gRPC `CompileRequest.vid_pid`
has been removed as well.

### golang API: method `github.com/arduino/arduino-cli/arduino/libraries/Library.LocationPriorityFor` removed

That method was outdated and must not be used.
Expand Down
3 changes: 0 additions & 3 deletions internal/cli/compile/compile.go
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,6 @@ var (
warnings string // Used to tell gcc which warning level to use.
verbose bool // Turns on verbose mode.
quiet bool // Suppresses almost every output.
vidPid string // VID/PID specific build properties.
uploadAfterCompile bool // Upload the binary after the compilation.
portArgs arguments.Port // Upload port, e.g.: COM10 or /dev/ttyACM0.
verify bool // Upload, verify uploaded binary after the upload.
Expand Down Expand Up @@ -145,7 +144,6 @@ func NewCommand() *cobra.Command {
compileCommand.Flags().BoolVarP(&uploadAfterCompile, "upload", "u", false, tr("Upload the binary after the compilation."))
portArgs.AddToCommand(compileCommand)
compileCommand.Flags().BoolVarP(&verify, "verify", "t", false, tr("Verify uploaded binary after the upload."))
compileCommand.Flags().StringVar(&vidPid, "vid-pid", "", tr("When specified, VID/PID specific build properties are used, if board supports them."))
compileCommand.Flags().StringSliceVar(&library, "library", []string{},
tr("Path to a single library’s root folder. Can be used multiple times or entries can be comma separated."))
compileCommand.Flags().StringSliceVar(&libraries, "libraries", []string{},
Expand Down Expand Up @@ -240,7 +238,6 @@ func runCompileCommand(cmd *cobra.Command, args []string) {
Warnings: warnings,
Verbose: verbose,
Quiet: quiet,
VidPid: vidPid,
ExportDir: exportDir,
Libraries: libraries,
OptimizeForDebug: optimizeForDebug,
Expand Down
2 changes: 0 additions & 2 deletions legacy/builder/constants/constants.go
Original file line number Diff line number Diff line change
Expand Up @@ -32,12 +32,10 @@ const BUILD_PROPERTIES_FQBN = "build.fqbn"
const BUILD_PROPERTIES_INCLUDES = "includes"
const BUILD_PROPERTIES_OBJECT_FILE = "object_file"
const BUILD_PROPERTIES_PATTERN = "pattern"
const BUILD_PROPERTIES_PID = "pid"
const BUILD_PROPERTIES_PREPROCESSED_FILE_PATH = "preprocessed_file_path"
const BUILD_PROPERTIES_RUNTIME_PLATFORM_PATH = "runtime.platform.path"
const BUILD_PROPERTIES_SOURCE_FILE = "source_file"
const BUILD_PROPERTIES_TOOLS_KEY = "tools"
const BUILD_PROPERTIES_VID = "vid"
const CTAGS = "ctags"
const EMPTY_STRING = ""
const FILE_CTAGS_TARGET_FOR_GCC_MINUS_E = "ctags_target_for_gcc_minus_e.cpp"
Expand Down
1 change: 0 additions & 1 deletion legacy/builder/container_setup.go
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,6 @@ func (s *ContainerSetupHardwareToolsLibsSketchAndProps) Run(ctx *types.Context)

commands = []types.Command{
&SetupBuildProperties{},
&LoadVIDPIDSpecificProperties{},
&SetCustomBuildProperties{},
&AddMissingBuildPropertiesFromParentPlatformTxtFiles{},
}
Expand Down
66 changes: 0 additions & 66 deletions legacy/builder/load_vid_pid_specific_properties.go

This file was deleted.

87 changes: 0 additions & 87 deletions legacy/builder/test/load_vid_pid_specific_properties_test.go

This file was deleted.

1 change: 0 additions & 1 deletion legacy/builder/types/context.go
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,6 @@ type Context struct {
TargetPackage *cores.Package
TargetPlatform *cores.PlatformRelease
ActualPlatform *cores.PlatformRelease
USBVidPid string

PlatformKeyRewrites PlatforKeysRewrite
HardwareRewriteResults map[*cores.PlatformRelease][]PlatforKeyRewrite
Expand Down

0 comments on commit f6f4a34

Please sign in to comment.