<GenerateTargetFrameworkAttribute>false</GenerateTargetFrameworkAttribute>
<SignAssembly>true</SignAssembly>
<DelaySign>true</DelaySign>
- <DefineConstants>$(DefineConstants);CORECLR;_USE_NLS_PLUS_TABLE;RESOURCE_SATELLITE_CONFIG;CODE_ANALYSIS_BASELINE;netcoreapp</DefineConstants>
+ <DefineConstants>$(DefineConstants);CORECLR;_USE_NLS_PLUS_TABLE;CODE_ANALYSIS_BASELINE;netcoreapp</DefineConstants>
<!-- We don't use any of MSBuild's resolution logic for resolving the framework, so just set these two properties to any folder that exists to skip
the GenerateReferenceAssemblyPaths task (not target) and to prevent it from outputting a warning (MSB3644). -->
<_TargetFrameworkDirectories>$(MSBuildThisFileDirectory)/Documentation</_TargetFrameworkDirectories>
private bool UseManifest; // Use Assembly manifest, or grovel disk.
-#if RESOURCE_SATELLITE_CONFIG
- private static volatile Hashtable _installedSatelliteInfo; // Give the user the option
- // to prevent certain satellite assembly probes via a config file.
- // Note that config files are per-appdomain, not per-assembly nor process
- private static volatile bool _checkedConfigFile; // Did we read the app's config file?
-#endif
-
// Whether to fall back to the main assembly or a particular
// satellite for the neutral resources.
private UltimateResourceFallbackLocation _fallbackLoc;
return ums;
}
-#if RESOURCE_SATELLITE_CONFIG
- // Internal helper method - gives an end user the ability to prevent
- // satellite assembly probes for certain cultures via a config file.
- private bool TryLookingForSatellite(CultureInfo lookForCulture)
- {
- if (!_checkedConfigFile)
- {
- lock (this)
- {
- if (!_checkedConfigFile)
- {
- _checkedConfigFile = true;
- _installedSatelliteInfo = GetSatelliteAssembliesFromConfig();
- }
- }
- }
-
- if (_installedSatelliteInfo == null)
- return true;
-
- string[] installedSatellites = (string[])_installedSatelliteInfo[MainAssembly.FullName];
-
- if (installedSatellites == null)
- return true;
-
- // The config file told us what satellites might be installed.
- int pos = Array.IndexOf(installedSatellites, lookForCulture.Name);
-
- return pos >= 0;
- }
-
- // Note: There is one config file per appdomain. This is not
- // per-process nor per-assembly.
- private Hashtable GetSatelliteAssembliesFromConfig()
- {
- return null;
- }
-#endif // RESOURCE_SATELLITE_CONFIG
-
internal class ResourceManagerMediator
{
private ResourceManager _rm;
{
get { return _rm.BaseName; }
}
-
-
-#if RESOURCE_SATELLITE_CONFIG
- internal bool TryLookingForSatellite(CultureInfo lookForCulture)
- {
- return _rm.TryLookingForSatellite(lookForCulture);
- }
-#endif
-
}
}
}