Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/corert.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/BuildIntegration/Microsoft.NETCore.Native.Unix.props3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/BuildIntegration/Microsoft.NETCore.Native.Unix.props b/src/BuildIntegration/Microsoft.NETCore.Native.Unix.props
index c5b397b3f..a8c8bafdb 100644
--- a/src/BuildIntegration/Microsoft.NETCore.Native.Unix.props
+++ b/src/BuildIntegration/Microsoft.NETCore.Native.Unix.props
@@ -81,6 +81,7 @@ See the LICENSE file in the project root for more information.
<LinkerArg Include="@(NativeLibrary)" />
<LinkerArg Include="-g" />
<LinkerArg Include="-Wl,-rpath,'$ORIGIN'" />
+ <LinkerArg Include="-Wl,--as-needed" Condition="'$(TargetOS)' != 'OSX'" />
<LinkerArg Include="-pthread" />
<LinkerArg Include="-lstdc++" />
<LinkerArg Include="-ldl" />
@@ -94,7 +95,7 @@ See the LICENSE file in the project root for more information.
<LinkerArg Include="-shared" Condition="'$(TargetOS)' != 'OSX' and '$(NativeLib)' == 'Shared'" />
<LinkerArg Include="@(NativeFramework->'-framework %(Identity)')" Condition="'$(TargetOS)' == 'OSX'" />
</ItemGroup>
-
+
<Exec Command="command -v $(CppLinker)" IgnoreExitCode="true">
<Output TaskParameter="ExitCode" PropertyName="_WhereLinker"/>
</Exec>