Skip to content

Commit

Permalink
Merge pull request #4149 from StephenBonikowsky/stebon/master/Fixsvcu…
Browse files Browse the repository at this point in the history
…tilxmlserializertool

Fix for tool command line syntax issue.
  • Loading branch information
StephenBonikowsky committed Feb 4, 2020
2 parents eecebff + b99c6b9 commit d08484b
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/svcutilcore/files/dotnet-svcutil.xmlserializer.targets
Expand Up @@ -5,7 +5,7 @@
<_SerializerDllIntermediateFolder>$(IntermediateOutputPath)$(_SerializationAssemblyName).dll</_SerializerDllIntermediateFolder>
<_SerializerPdbIntermediateFolder>$(IntermediateOutputPath)$(_SerializationAssemblyName).pdb</_SerializerPdbIntermediateFolder>
<_SerializerCsIntermediateFolder>$(IntermediateOutputPath)$(_SerializationAssemblyName).cs</_SerializerCsIntermediateFolder>
<_SvcUtilWarningText>Warning : Fail to generate the serializer for $(AssemblyName)$(TargetExt).</_SvcUtilWarningText>
<_SvcUtilWarningText>Warning : Failed to generate the serializer for $(AssemblyName)$(TargetExt).</_SvcUtilWarningText>
<_SerializationAssemblyDisabledWarnings>$(NoWarn);219;162;$(SerializationAssemblyDisabledWarnings)</_SerializationAssemblyDisabledWarnings>
</PropertyGroup>

Expand Down
Expand Up @@ -414,8 +414,10 @@ private void AddMscorlib(Dictionary<string, Type> foundCollectionTypes)

private void LoadSMReferenceAssembly()
{
ToolConsole.WriteLine("[Logging] Getting list of referenced assemblies.");
string smReferenceArg = _arguments.GetArgument(Options.Cmd.SMReference);
IList<string> referencedAssembliesArgs = smReferenceArg.Split(':').ToList();
ToolConsole.WriteLine("[Logging] The string of reference assemblies before parsing: " + smReferenceArg);
IList<string> referencedAssembliesArgs = smReferenceArg.Split(';').ToList();
if (referencedAssembliesArgs != null && referencedAssembliesArgs.Count > 0)
{
string smassembly = "";
Expand All @@ -435,6 +437,8 @@ private void LoadSMReferenceAssembly()
}
if ((string.IsNullOrEmpty(smassembly)) || (string.IsNullOrEmpty(smpassembly)))
{
ToolConsole.WriteLine("The full path found for System.ServiceModel.Primitives.dll is: " + smassembly);
ToolConsole.WriteLine("The full path found for System.Private.ServiceModel.dll is: " + smpassembly);
ToolConsole.WriteError("Missing one or both of the paths for System.ServiceModel.Primitives and System.Private.ServiceModel");
throw new ArgumentException("Invalid smreference value");
}
Expand Down
Expand Up @@ -85,7 +85,7 @@
<Message Text="$(ServiceModelPrimitivesAssemblyName) exists in $(ServiceModelPrimitivesOutputPath)" Condition="Exists('$(ServiceModelPrimitivesOutputPath)$(ServiceModelPrimitivesAssemblyName)') == 'true'" Importance="high" />
<Error Text="$(ServiceModelPrivateAssemblyName) does not exist in $(ServiceModelPrivateOutputPath)" Condition="Exists('$(ServiceModelPrivateOutputPath)$(ServiceModelPrivateAssemblyName)') != 'true'" />
<Error Text="$(ServiceModelPrimitivesAssemblyName) does not exist in $(ServiceModelPrimitivesOutputPath)" Condition="Exists('$(ServiceModelPrimitivesOutputPath)$(ServiceModelPrimitivesAssemblyName)') != 'true'" />
<Exec Command="$(DotNetExe) $(DotnetSvcutilXmlSerializerAssembly) $(InputTestAssembly) --quiet --out:$(OutputGeneratedSource) --smreference:$(ServiceModelPrimitivesAssembly):$(ServiceModelPrivateAssembly) --reference=$(depRef)" />
<Exec Command="$(DotNetExe) $(DotnetSvcutilXmlSerializerAssembly) $(InputTestAssembly) --quiet --out:$(OutputGeneratedSource) --smreference:&quot;$(ServiceModelPrimitivesAssembly);$(ServiceModelPrivateAssembly)&quot; --reference=$(depRef)" />
<Warning Condition="Exists('$(OutputGeneratedSource)') != 'true'" Text="Failed to generate $(OutputGeneratedSource)"/>
<Csc Condition="Exists('$(OutputGeneratedSource)') == 'true'"
OutputAssembly="$(CscOutputAssembly)"
Expand Down

0 comments on commit d08484b

Please sign in to comment.