Skip to content

Commit

Permalink
Added information about finding lib tool - #44
Browse files Browse the repository at this point in the history
  • Loading branch information
3F committed Aug 11, 2017
1 parent 3f421cd commit da0b72c
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -906,7 +906,7 @@ private bool ValidateLibToolPath()
}
else
{
this._ActualTask.Log.LogMessage(MessageImportance.Normal, Resources.Cannot_find_lib_exe_in_0_, (object)this.LibToolPath);
this._ActualTask.Log.LogMessage(MessageImportance.Low, Resources.Cannot_find_lib_exe_in_0_, (object)this.LibToolPath);
this.LibToolPath = (string)null;
return false;
}
Expand Down
11 changes: 8 additions & 3 deletions RGiesecke.DllExport/Parsing/ILAsm.cs
Original file line number Diff line number Diff line change
Expand Up @@ -198,7 +198,8 @@ private int RunLibTool(CpuPlatform cpu, string fileName, string directory)
$"/C \"\"{InputValues.VsDevCmd}\" -no_logo -arch={(cpu == CpuPlatform.X64 ? "amd64" : "x86")} && lib.exe {cfg}\""
);

if(code != -1) {
Notifier.Notify(-1, DllExportLogginCodes.LibToolLooging, $"lib tool via VsDevCmd: {code}");
if(code == 0) {
return code;
}
}
Expand All @@ -207,7 +208,9 @@ private int RunLibTool(CpuPlatform cpu, string fileName, string directory)
{
string reqPath = (String.IsNullOrEmpty(InputValues.LibToolDllPath) || !Directory.Exists(InputValues.LibToolDllPath)) ? null : InputValues.LibToolDllPath;
int code = RunLibToolCore("Lib.exe", cfg, InputValues.LibToolPath, reqPath);
if(code != -1) {

Notifier.Notify(-1, DllExportLogginCodes.LibToolLooging, $"lib tool via LibToolPath: {code}");
if(code == 0) {
return code;
}
}
Expand All @@ -219,12 +222,14 @@ private int RunLibTool(CpuPlatform cpu, string fileName, string directory)
$"/C \"\"{InputValues.VcVarsAll}\" {(cpu == CpuPlatform.X64 ? "x64" : "x86")} && lib.exe {cfg}\""
);

if(code != -1) {
Notifier.Notify(-1, DllExportLogginCodes.LibToolLooging, $"lib tool via VcVarsAll: {code}");
if(code == 0) {
return code;
}
}

int ret = RunLibToolCore("lib.exe", cfg, String.Empty, InputValues.LibToolDllPath);
Notifier.Notify(0, DllExportLogginCodes.LibToolLooging, $"lib tool via LibToolDllPath: {ret}");
if(ret != -1) {
return ret;
}
Expand Down

0 comments on commit da0b72c

Please sign in to comment.