summaryrefslogtreecommitdiff
path: root/src/tools
diff options
context:
space:
mode:
Diffstat (limited to 'src/tools')
-rw-r--r--src/tools/crossgen/crossgen.cpp42
-rw-r--r--src/tools/metainfo/mdinfo.cpp9
2 files changed, 5 insertions, 46 deletions
diff --git a/src/tools/crossgen/crossgen.cpp b/src/tools/crossgen/crossgen.cpp
index a3e66e69e2..285714c777 100644
--- a/src/tools/crossgen/crossgen.cpp
+++ b/src/tools/crossgen/crossgen.cpp
@@ -36,9 +36,7 @@ enum ReturnValues
STDAPI CreatePDBWorker(LPCWSTR pwzAssemblyPath, LPCWSTR pwzPlatformAssembliesPaths, LPCWSTR pwzTrustedPlatformAssemblies, LPCWSTR pwzPlatformResourceRoots, LPCWSTR pwzAppPaths, LPCWSTR pwzAppNiPaths, LPCWSTR pwzPdbPath, BOOL fGeneratePDBLinesInfo, LPCWSTR pwzManagedPdbSearchPath, LPCWSTR pwzPlatformWinmdPaths, LPCWSTR pwzDiasymreaderPath);
STDAPI NGenWorker(LPCWSTR pwzFilename, DWORD dwFlags, LPCWSTR pwzPlatformAssembliesPaths, LPCWSTR pwzTrustedPlatformAssemblies, LPCWSTR pwzPlatformResourceRoots, LPCWSTR pwzAppPaths, LPCWSTR pwzOutputFilename=NULL, LPCWSTR pwzPlatformWinmdPaths=NULL, ICorSvcLogger *pLogger = NULL, LPCWSTR pwszCLRJITPath = nullptr);
void SetSvcLogger(ICorSvcLogger *pCorSvcLogger);
-#ifdef FEATURE_CORECLR
void SetMscorlibPath(LPCWSTR wzSystemDirectory);
-#endif
/* --------------------------------------------------------------------------- *
* Console stuff
@@ -94,11 +92,7 @@ void ErrorWin32(DWORD err)
void PrintLogoHelper()
{
-#ifdef FEATURE_CORECLR
Output(W("Microsoft (R) CoreCLR Native Image "));
-#else
- Output(W("Microsoft (R) CLR Native Image "));
-#endif
Outputf(W("Generator - Version %S\n"), VER_FILEVERSION_STR);
Outputf(W("%S\n"), VER_LEGALCOPYRIGHT_LOGO_STR);
Output(W("\n"));
@@ -116,12 +110,9 @@ void PrintUsageHelper()
W(" /nologo - Prevents displaying the logo\n")
W(" @response.rsp - Process command line arguments from specified\n")
W(" response file\n")
-#ifdef FEATURE_CORECLR
W(" /partialtrust - Assembly will be run in a partial trust domain.\n")
-#endif
W(" /in <file> - Specifies input filename (optional)\n")
W(" /out <file> - Specifies output filename (optional)\n")
-#ifdef FEATURE_CORECLR
W(" /Trusted_Platform_Assemblies <path[") PATH_SEPARATOR_STR_W W("path]>\n")
W(" - List of assemblies treated as trusted platform\n")
W(" - Cannot be used with Platform_Assemblies_Paths\n")
@@ -134,15 +125,12 @@ void PrintUsageHelper()
W(" - List of paths containing user-application native images\n")
W(" - Must be used with /CreatePDB switch\n")
#endif // NO_NGENPDB
-#endif // FEATURE_CORECLR
W(" /Platform_Assemblies_Paths <path[") PATH_SEPARATOR_STR_W W("path]>\n")
W(" - List of paths containing target platform assemblies\n")
-#ifdef FEATURE_CORECLR
// If Platform_Assemblies_Paths, we will use it to build the TPA list and thus,
// TPA list cannot be explicitly specified.
W(" - Cannot be used with Trusted_Platform_Assemblies\n")
-#endif // FEATURE_CORECLR
#ifdef FEATURE_COMINTEROP
W(" /Platform_Winmd_Paths <path[") PATH_SEPARATOR_STR_W W("path]>\n")
@@ -156,7 +144,7 @@ void PrintUsageHelper()
W(" /Tuning - Generate an instrumented image to collect\n")
W(" scenario traces, which can be used with ibcmerge.exe\n")
#endif
-#if defined(FEATURE_CORECLR) && !defined(FEATURE_MERGE_JIT_AND_ENGINE)
+#if !defined(FEATURE_MERGE_JIT_AND_ENGINE)
W(" /JITPath <path>\n")
W(" - Specifies the absolute file path to JIT compiler to be used.\n")
#endif // defined(FEATURE_CORECLR) && !defined(FEATURE_MERGE_JIT_AND_ENGINE)
@@ -168,19 +156,15 @@ void PrintUsageHelper()
W(" WinMD Parameters\n")
W(" /WinMDResilient - Generate images resilient to WinMD dependency changes.\n")
#endif
-#ifdef FEATURE_CORECLR
W(" Size on Disk Parameters\n")
W(" /NoMetaData - Do not copy metadata and IL into native image.\n")
-#endif // FEATURE_CORECLR
#ifndef NO_NGENPDB
W(" Debugging Parameters\n")
W(" /CreatePDB <Dir to store PDB> [/lines [<search path for managed PDB>] ]\n")
W(" When specifying /CreatePDB, the native image should be created\n")
W(" first, and <assembly name> should be the path to the NI.\n")
-#ifdef FEATURE_CORECLR
W(" /DiasymreaderPath <Path to diasymreader.dll>\n")
W(" - Specifies the absolute file path to diasymreader.dll to be used.\n")
-#endif // FEATURE_CORECLR
#elif defined(FEATURE_PERFMAP)
W(" Debugging Parameters\n")
W(" /CreatePerfMap <Dir to store perf map>\n")
@@ -265,7 +249,6 @@ bool StringEndsWith(LPCWSTR pwzString, LPCWSTR pwzCandidate)
return !_wcsicmp(pwzStringEnd, pwzCandidate);
}
-#ifdef FEATURE_CORECLR
//
// When using the Phone binding model (TrustedPlatformAssemblies), automatically
// detect which path CoreLib.[ni.]dll lies in.
@@ -429,7 +412,6 @@ void ComputeTPAListFromPlatformAssembliesPath(LPCWSTR pwzPlatformAssembliesPaths
}
}
}
-#endif // FEATURE_CORECLR
extern HMODULE g_hThisInst;
@@ -459,7 +441,7 @@ int _cdecl wmain(int argc, __in_ecount(argc) WCHAR **argv)
LPCWSTR pwzOutputFilename = NULL;
LPCWSTR pwzPublicKeys = nullptr;
-#if defined(FEATURE_CORECLR) && !defined(FEATURE_MERGE_JIT_AND_ENGINE)
+#if !defined(FEATURE_MERGE_JIT_AND_ENGINE)
LPCWSTR pwszCLRJITPath = nullptr;
#endif // defined(FEATURE_CORECLR) && !defined(FEATURE_MERGE_JIT_AND_ENGINE)
@@ -501,10 +483,8 @@ int _cdecl wmain(int argc, __in_ecount(argc) WCHAR **argv)
// By default, Crossgen will assume code-generation for fulltrust domains unless /PartialTrust switch is specified
dwFlags |= NGENWORKER_FLAGS_FULLTRUSTDOMAIN;
-#ifdef FEATURE_CORECLR
// By default, Crossgen will generate readytorun images unless /FragileNonVersionable switch is specified
dwFlags |= NGENWORKER_FLAGS_READYTORUN;
-#endif
while (argc > 0)
{
@@ -526,7 +506,6 @@ int _cdecl wmain(int argc, __in_ecount(argc) WCHAR **argv)
{
dwFlags |= NGENWORKER_FLAGS_MISSINGDEPENDENCIESOK;
}
-#ifdef FEATURE_CORECLR
else if (MatchParameter(*argv, W("PartialTrust")))
{
// Clear the /fulltrust flag
@@ -551,7 +530,6 @@ int _cdecl wmain(int argc, __in_ecount(argc) WCHAR **argv)
argc--;
}
#endif // !defined(FEATURE_MERGE_JIT_AND_ENGINE)
-#endif
#ifdef FEATURE_WINMD_RESILIENT
else if (MatchParameter(*argv, W("WinMDResilient")))
{
@@ -568,12 +546,10 @@ int _cdecl wmain(int argc, __in_ecount(argc) WCHAR **argv)
dwFlags &= ~NGENWORKER_FLAGS_READYTORUN;
}
#endif
-#ifdef FEATURE_CORECLR
else if (MatchParameter(*argv, W("NoMetaData")))
{
dwFlags |= NGENWORKER_FLAGS_NO_METADATA;
}
-#endif
else if (MatchParameter(*argv, W("out")))
{
if (pwzOutputFilename != NULL)
@@ -596,7 +572,6 @@ int _cdecl wmain(int argc, __in_ecount(argc) WCHAR **argv)
argv++;
argc--;
}
-#ifdef FEATURE_CORECLR
else if (MatchParameter(*argv, W("Trusted_Platform_Assemblies")) && (argc > 1))
{
pwzTrustedPlatformAssemblies = argv[1];
@@ -631,7 +606,6 @@ int _cdecl wmain(int argc, __in_ecount(argc) WCHAR **argv)
argc--;
}
#endif // NO_NGENPDB
-#endif // FEATURE_CORECLR
else if (MatchParameter(*argv, W("Platform_Assemblies_Paths")) && (argc > 1))
{
pwzPlatformAssembliesPaths = argv[1];
@@ -708,7 +682,6 @@ int _cdecl wmain(int argc, __in_ecount(argc) WCHAR **argv)
argv--;
argc++;
}
-#ifdef FEATURE_CORECLR
else if (MatchParameter(*argv, W("DiasymreaderPath")) && (argc > 1))
{
pwzDiasymreaderPath = argv[1];
@@ -717,7 +690,6 @@ int _cdecl wmain(int argc, __in_ecount(argc) WCHAR **argv)
argv++;
argc--;
}
-#endif // FEATURE_CORECLR
#endif // NO_NGENPDB
#ifdef FEATURE_PERFMAP
else if (MatchParameter(*argv, W("CreatePerfMap")) && (argc > 1))
@@ -816,7 +788,7 @@ int _cdecl wmain(int argc, __in_ecount(argc) WCHAR **argv)
exit(FAILURE_RESULT);
}
-#if defined(FEATURE_CORECLR) && !defined(FEATURE_MERGE_JIT_AND_ENGINE)
+#if !defined(FEATURE_MERGE_JIT_AND_ENGINE)
if (pwszCLRJITPath != nullptr && fCreatePDB)
{
Output(W("The /JITPath switch can not be used with the /CreatePDB switch.\n"));
@@ -824,7 +796,7 @@ int _cdecl wmain(int argc, __in_ecount(argc) WCHAR **argv)
}
#endif // defined(FEATURE_CORECLR) && !defined(FEATURE_MERGE_JIT_AND_ENGINE)
-#if defined(FEATURE_CORECLR) && !defined(NO_NGENPDB)
+#if !defined(NO_NGENPDB)
if (pwzDiasymreaderPath != nullptr && !fCreatePDB)
{
Output(W("The /DiasymreaderPath switch can only be used with the /CreatePDB switch.\n"));
@@ -832,7 +804,6 @@ int _cdecl wmain(int argc, __in_ecount(argc) WCHAR **argv)
}
#endif // defined(FEATURE_CORECLR) && !defined(NO_NGENPDB)
-#if defined(FEATURE_CORECLR)
if ((pwzTrustedPlatformAssemblies != nullptr) && (pwzPlatformAssembliesPaths != nullptr))
{
Output(W("The /Trusted_Platform_Assemblies and /Platform_Assemblies_Paths switches cannot be both specified.\n"));
@@ -863,7 +834,6 @@ int _cdecl wmain(int argc, __in_ecount(argc) WCHAR **argv)
exit(FAILURE_RESULT);
}
}
-#endif // FEATURE_CORESYSTEM
#ifdef FEATURE_READYTORUN_COMPILER
if (((dwFlags & NGENWORKER_FLAGS_TUNING) != 0) && ((dwFlags & NGENWORKER_FLAGS_READYTORUN) != 0))
@@ -888,7 +858,6 @@ int _cdecl wmain(int argc, __in_ecount(argc) WCHAR **argv)
PathString wzTrustedPathRoot;
-#ifdef FEATURE_CORECLR
SString ssTPAList;
if (fCreatePDB)
@@ -924,7 +893,6 @@ int _cdecl wmain(int argc, __in_ecount(argc) WCHAR **argv)
SetMscorlibPath(pwzPlatformAssembliesPaths);
}
}
-#endif // FEATURE_CORECLR
if (pwzPlatformAssembliesPaths == NULL)
{
@@ -977,7 +945,7 @@ int _cdecl wmain(int argc, __in_ecount(argc) WCHAR **argv)
pwzAppPaths,
pwzOutputFilename,
pwzPlatformWinmdPaths
-#if defined(FEATURE_CORECLR) && !defined(FEATURE_MERGE_JIT_AND_ENGINE)
+#if !defined(FEATURE_MERGE_JIT_AND_ENGINE)
,
NULL, // ICorSvcLogger
pwszCLRJITPath
diff --git a/src/tools/metainfo/mdinfo.cpp b/src/tools/metainfo/mdinfo.cpp
index 70dfa28bcf..143220117e 100644
--- a/src/tools/metainfo/mdinfo.cpp
+++ b/src/tools/metainfo/mdinfo.cpp
@@ -22,9 +22,6 @@
#define LEGACY_ACTIVATION_SHIM_LOAD_LIBRARY WszLoadLibrary
#define LEGACY_ACTIVATION_SHIM_DEFINE_CoInitializeEE
-#ifndef FEATURE_CORECLR
-#include "LegacyActivationShim.h"
-#endif
#define ENUM_BUFFER_SIZE 10
#define TAB_SIZE 8
@@ -760,12 +757,6 @@ void MDInfo::Error(const char* szError, HRESULT hr)
pIErr->Release();
}
-#ifndef FEATURE_CORECLR
- LegacyActivationShim::CoUninitializeCor();
-#ifndef FEATURE_PAL
- CoUninitialize();
-#endif
-#endif
exit(hr);
} // void MDInfo::Error()