Use toybox md5sum instead of md5 on macOS.
Test: builds locally Change-Id: I04aa52de96e0525a44331cb0c057a8e18a95891d
This commit is contained in:
11
java/sdk.go
11
java/sdk.go
@@ -19,7 +19,6 @@ import (
|
|||||||
"android/soong/java/config"
|
"android/soong/java/config"
|
||||||
"fmt"
|
"fmt"
|
||||||
"path/filepath"
|
"path/filepath"
|
||||||
"runtime"
|
|
||||||
"sort"
|
"sort"
|
||||||
"strconv"
|
"strconv"
|
||||||
"strings"
|
"strings"
|
||||||
@@ -349,15 +348,7 @@ func createAPIFingerprint(ctx android.SingletonContext) {
|
|||||||
|
|
||||||
cmd.Text("cat").
|
cmd.Text("cat").
|
||||||
Inputs(android.PathsForSource(ctx, in)).
|
Inputs(android.PathsForSource(ctx, in)).
|
||||||
Text("|")
|
Text("| md5sum | cut -d' ' -f1 >").
|
||||||
|
|
||||||
if runtime.GOOS == "darwin" {
|
|
||||||
cmd.Text("md5")
|
|
||||||
} else {
|
|
||||||
cmd.Text("md5sum")
|
|
||||||
}
|
|
||||||
|
|
||||||
cmd.Text("| cut -d' ' -f1 >").
|
|
||||||
Output(out)
|
Output(out)
|
||||||
} else {
|
} else {
|
||||||
// Unbundled build
|
// Unbundled build
|
||||||
|
@@ -129,12 +129,10 @@ var Configuration = map[string]PathConfig{
|
|||||||
|
|
||||||
func init() {
|
func init() {
|
||||||
if runtime.GOOS == "darwin" {
|
if runtime.GOOS == "darwin" {
|
||||||
// TODO: move Darwin off md5 and onto our md5sum prebuilt.
|
|
||||||
Configuration["md5"] = Allowed
|
|
||||||
Configuration["sw_vers"] = Allowed
|
Configuration["sw_vers"] = Allowed
|
||||||
Configuration["xcrun"] = Allowed
|
Configuration["xcrun"] = Allowed
|
||||||
|
|
||||||
// We don't have darwin prebuilts for some tools (like toybox),
|
// We don't have darwin prebuilts for some tools,
|
||||||
// so allow the host versions.
|
// so allow the host versions.
|
||||||
for name, config := range Configuration {
|
for name, config := range Configuration {
|
||||||
if config.LinuxOnlyPrebuilt {
|
if config.LinuxOnlyPrebuilt {
|
||||||
|
Reference in New Issue
Block a user