diff --git a/src/main/java/com/google/devtools/build/lib/packages/semantics/BuildLanguageOptions.java b/src/main/java/com/google/devtools/build/lib/packages/semantics/BuildLanguageOptions.java index 8f3d8d738a2b0b..128aa1bfbb7e16 100644 --- a/src/main/java/com/google/devtools/build/lib/packages/semantics/BuildLanguageOptions.java +++ b/src/main/java/com/google/devtools/build/lib/packages/semantics/BuildLanguageOptions.java @@ -651,7 +651,7 @@ public final class BuildLanguageOptions extends OptionsBase { @Option( name = "incompatible_disable_objc_library_transition", - defaultValue = "false", + defaultValue = "true", documentationCategory = OptionDocumentationCategory.STARLARK_SEMANTICS, effectTags = {OptionEffectTag.BUILD_FILE_SEMANTICS}, metadataTags = {OptionMetadataTag.INCOMPATIBLE_CHANGE}, @@ -879,7 +879,7 @@ public StarlarkSemantics toStarlarkSemantics() { public static final String INCOMPATIBLE_OBJC_PROVIDER_REMOVE_LINKING_INFO = "-incompatible_objc_provider_remove_linking_info"; public static final String INCOMPATIBLE_DISABLE_OBJC_LIBRARY_TRANSITION = - "-incompatible_disable_objc_library_transition"; + "+incompatible_disable_objc_library_transition"; public static final String INCOMPATIBLE_FAIL_ON_UNKNOWN_ATTRIBUTES = "+incompatible_fail_on_unknown_attributes"; public static final String INCOMPATIBLE_ENABLE_PROTO_TOOLCHAIN_RESOLUTION = diff --git a/src/test/java/com/google/devtools/build/lib/rules/objc/ObjcRuleTestCase.java b/src/test/java/com/google/devtools/build/lib/rules/objc/ObjcRuleTestCase.java index 7c65ab0cecf3d9..a1466b420128df 100644 --- a/src/test/java/com/google/devtools/build/lib/rules/objc/ObjcRuleTestCase.java +++ b/src/test/java/com/google/devtools/build/lib/rules/objc/ObjcRuleTestCase.java @@ -69,6 +69,7 @@ import java.util.Map; import java.util.regex.Pattern; import javax.annotation.Nullable; +import org.junit.Before; /** * Superclass for all Obj-C rule tests. @@ -89,6 +90,11 @@ public abstract class ObjcRuleTestCase extends BuildViewTestCase { protected static final String OUTPUTDIR = TestConstants.PRODUCT_NAME + "-out//bin"; + @Before + public void setUp() throws Exception { + setBuildLanguageOptions("--noincompatible_disable_objc_library_transition"); + } + /** Specification of code coverage behavior. */ public enum CodeCoverageMode { // No code coverage information.