Skip to content

Commit

Permalink
Move deprecated flag --fat_apk_cpu to the graveyard.
Browse files Browse the repository at this point in the history
PiperOrigin-RevId: 688992744
Change-Id: I3d7f105fef11870c72504513bb8e491adad2909b
  • Loading branch information
katre authored and copybara-github committed Oct 23, 2024
1 parent b3badd3 commit 2f7c461
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 32 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@
import com.google.devtools.build.lib.runtime.Command;
import com.google.devtools.build.lib.runtime.CommandEnvironment;
import com.google.devtools.build.lib.util.ResourceFileLoader;
import com.google.devtools.common.options.Converters;
import com.google.devtools.common.options.Option;
import com.google.devtools.common.options.OptionDocumentationCategory;
import com.google.devtools.common.options.OptionEffectTag;
Expand Down Expand Up @@ -433,6 +434,16 @@ public static final class BazelBuildGraveyardOptions extends BuildGraveyardOptio
help = "No-op",
deprecationWarning = ANDROID_FLAG_DEPRECATION)
public boolean incompatibleUseToolchainResolution;

@Option(
name = "fat_apk_cpu",
converter = Converters.CommaSeparatedOptionSetConverter.class,
defaultValue = "armeabi-v7a",
documentationCategory = OptionDocumentationCategory.UNDOCUMENTED,
effectTags = {OptionEffectTag.NO_OP},
help = "No-op",
deprecationWarning = ANDROID_FLAG_DEPRECATION)
public List<String> fatApkCpus;
}

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -235,25 +235,6 @@ public static class Options extends FragmentOptions {
+ "'off' means that all libraries will be linked in mostly static mode.")
public DynamicMode dynamicMode;

// TODO(bazel-team): Maybe merge this with --android_cpu above.
// TODO(blaze-configurability): Mark this as deprecated in favor of --android_platforms.
@Option(
name = "fat_apk_cpu",
converter = Converters.CommaSeparatedOptionSetConverter.class,
defaultValue = "armeabi-v7a",
documentationCategory = OptionDocumentationCategory.OUTPUT_PARAMETERS,
effectTags = {
OptionEffectTag.AFFECTS_OUTPUTS,
OptionEffectTag.LOADING_AND_ANALYSIS,
OptionEffectTag.LOSES_INCREMENTAL_STATE,
},
help =
"Setting this option enables fat APKs, which contain native binaries for all "
+ "specified target architectures, e.g., --fat_apk_cpu=x86,armeabi-v7a. If this "
+ "flag is specified, then --android_cpu is ignored for dependencies of "
+ "android_binary rules.")
public List<String> fatApkCpus;

@Option(
name = "android_platforms",
converter = LabelOrderedSetConverter.class,
Expand Down Expand Up @@ -714,15 +695,6 @@ public static class Options extends FragmentOptions {
+ " Starlark Android rules from https://github.com/bazelbuild/rules_android")
public boolean disableNativeAndroidRules;

@Option(
name = "android hwasan", // Space is so that this cannot be set on the command line
defaultValue = "false",
documentationCategory = OptionDocumentationCategory.UNDOCUMENTED,
effectTags = {OptionEffectTag.LOADING_AND_ANALYSIS},
metadataTags = {OptionMetadataTag.INTERNAL},
help = "Whether HWASAN is enabled.")
public boolean hwasan;

@Option(
name = "experimental_filter_r_jars_from_android_test",
defaultValue = "false",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -153,13 +153,9 @@ bazel_fragments["AndroidConfiguration.Options"] = fragment(
"//command_line_option:experimental_objc_provider_from_linked",
],
outputs = [
"//command_line_option:android hwasan",
"//command_line_option:fat_apk_cpu",
"//command_line_option:Android configuration distinguisher",
],
func = lambda settings: {
"//command_line_option:android hwasan": False,
"//command_line_option:fat_apk_cpu": [],
"//command_line_option:Android configuration distinguisher": "main",
},
)
Expand Down

0 comments on commit 2f7c461

Please sign in to comment.