Simplify jiri swift build stage names.
Currently the stage names have a redundency in being called build-cgo
and build-framework as you must specify the build command to use them.
This CL simplifies build commands from "jiri swift build build-cgo" to
"jiri swift build cgo".
Change-Id: I4d0c5ef469af4c3c7f764af090f83dccf2a0ace1
diff --git a/jiri-swift/build_test.go b/jiri-swift/build_test.go
index 789685d..af10657 100644
--- a/jiri-swift/build_test.go
+++ b/jiri-swift/build_test.go
@@ -140,7 +140,7 @@
}
// Cgo binary
resetVars()
- if err := parseBuildArgs(jirix, []string{"build-cgo"}); err != nil {
+ if err := parseBuildArgs(jirix, []string{"cgo"}); err != nil {
t.Error(err)
return
}
@@ -150,7 +150,7 @@
}
// Cgo binary + framework
resetVars()
- if err := parseBuildArgs(jirix, []string{"build-cgo", "build-framework"}); err != nil {
+ if err := parseBuildArgs(jirix, []string{"cgo", "framework"}); err != nil {
t.Error(err)
return
}
@@ -161,7 +161,7 @@
// Framework requires universal
resetVars()
flagTargetArch = targetArchAmd64
- if err := parseBuildArgs(jirix, []string{"build-cgo", "build-framework"}); err == nil {
+ if err := parseBuildArgs(jirix, []string{"cgo", "framework"}); err == nil {
t.Error("Expected error building framework for 1 architecture")
return
}
diff --git a/jiri-swift/swift.go b/jiri-swift/swift.go
index a532859..4f26e52 100644
--- a/jiri-swift/swift.go
+++ b/jiri-swift/swift.go
@@ -47,8 +47,8 @@
frameworkName = "VanadiumCore.framework"
frameworkBinaryName = "VanadiumCore"
- stageBuildCgo = "build-cgo"
- stageBuildFramework = "build-framework"
+ stageBuildCgo = "cgo"
+ stageBuildFramework = "framework"
descBuildMode = "The build mode for cgo, either c-archive or c-shared. Defaults to c-archive."
descBuildDirCgo = "The directory for all generated artifacts during the cgo building phase. Defaults to a temp dir."
@@ -87,14 +87,14 @@
Short: "Builds and installs the cgo wrapper, as well as the Swift framework",
Long: `The complete build pipeline from creating the CGO library, manipulating the headers for Swift,
and building the Swift framework using Xcode.`,
- ArgsName: "[stage ...] (build-cgo, build-framework)",
+ ArgsName: "[stage ...] (cgo, framework)",
ArgsLong: `
[stage ...] are the pipelines stage to run and any arguments to pass to that stage. If left empty defaults
to building all stages.
Available stages:
- build-cgo: Builds and installs the cgo library
- build-framework: Builds the Swift Framework using Xcode
+ cgo: Builds and installs the cgo library
+ framework: Builds the Swift Framework using Xcode
`,
}
diff --git a/jiridoc/doc.go b/jiridoc/doc.go
index 4f54ca3..10ba2ac 100644
--- a/jiridoc/doc.go
+++ b/jiridoc/doc.go
@@ -1473,15 +1473,15 @@
and building the Swift framework using Xcode.
Usage:
- jiri swift build [flags] [stage ...] (build-cgo, build-framework)
+ jiri swift build [flags] [stage ...] (cgo, framework)
[stage ...] are the pipelines stage to run and any arguments to pass to that
stage. If left empty defaults
to building all stages.
Available stages:
- build-cgo: Builds and installs the cgo library
- build-framework: Builds the Swift Framework using Xcode
+ cgo: Builds and installs the cgo library
+ framework: Builds the Swift Framework using Xcode
The jiri swift build flags are:
-build-dir-cgo=