Age | Commit message (Collapse) | Author | Files | Lines |
|
According to https://sourceforge.net/p/predef/wiki/OperatingSystems/
(Pre-defined Compiler Macros) and http://www.faqs.org/docs/Linux-HOWTO/GCC-HOWTO.html
(Porting and compiling:Automatically defined symbols), the __linux__ marcro is the
right way to detect systems based on the Linux kernel and is the POSIX compliant.
Signed-off-by: Geunsik Lim <geunsik.lim@samsung.com>
Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
|
|
The long path support feature modified debug corerun.exe with debug
CRT (msvcrtd.dll). This made it more difficult to use corerun.exe,
since the debug CRT is not always available. It turns out this change
is no longer necessary, so reverting part of the change to link debug
corerun.exe with retail CRT (msvcrt.dll) again.
|
|
|
|
Disable UNW_ARM_METHOD_DWARF, which gets problematic with
assembly-created stacks in ARM systems.
Although previous commits have fixed the compatibility issues
between cpp stacks and libunwind-arm, the assembly part
(asmhelpers.S) had similar problems.
Fix #3462
Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
|
|
[tfs-changeset: 1580615]
|
|
The CoreCLR runtime is updated to support long file paths on Windows.
Pending updates to mscorlib.dll, the following scenarios are supported:
* Run managed apps from a long path.
* Load CoreCLR runtime and framework from a long path.
* Load user assemblies from a long path.
* Run CrossGen from a long path, with its input/output from a long path.
* Generate debug log file at a long path.
The following scenarios are not yet supported, and will be fixed in
future commits:
* Mscorlib.dll and framework assemblies are not yet long path compatible.
Note that until mscorlib.dll is fixed, most of the runtime changes can't
actually be used.
* Support on non-Windows platforms.
* Support for debugging and error reporting.
* Tools such as ilasm or ildasm.
|
|
Although PR#1818 was supposed to implement this for Linux, only the MacOS X
implementation was correct. We are now using `readlink' on Linux to get
the path of the current running executable.
|
|
[tfs-changeset: 1570939]
|
|
|
|
NAME
dlopen, dlclose, dlsym, dlvsym, dladdr, dlctl, dlerror - dynamic link
interface
LIBRARY
(These functions are not in a library. They are included in every
dynamically linked program automatically.)
SYNOPSIS
#include <dlfcn.h>
void *
dlopen(const char *path, int mode);
|
|
Enable the fPIE compiler option for executables in the coreclr repo on Unix platforms
|
|
platforms
|
|
environment variables
|
|
|
|
to use dynamic linking.
|
|
This enables ildasm for cross-platforms.
Unlike Window (where initialization is done when DLL attach), CoreCLR is explciltly hosted/initialized to get the Metadata related APIs.
This also eliminates the need of setting dynamic library path.
Currently, ildasm binary is assumed to be located same as CoreCLR binary.
I added a simple CoreCLRLoader (not meant to run an assembly file) for just direct uses of APIs. Since I expect this library to be used for ilasm work.
Resource string is also handled using a static string table based on my prior check-in.
Other changes are mostly mechanic with regard to wide constant string.
|
|
|
|
Allowing the GC-related flags to be set using properties passed into coreclr_initialize.
|
|
|
|
_get_wpgmptr is not available in WindowsOS CRT. Replace it with GetModuleFileName.
[tfs-changeset: 1538931]
|
|
The first value in argv only contains the string that was used to
launch the process. This means that when the CoreConsole-based
application is on the PATH, some invocations of it (most notably
those done from 'cmd') cause that value to be incomplete.
Changing to use _get_wpgmptr ensures that we always get the full
path to the executable, no matter how it is executed.
Fix #1771
|
|
The property list was broken - the keys list was missing a comma between two entries,
so they got merged into one string. And the values list was missing one value too.
|
|
|
|
This change fixes a problem on Linux when pinvoke loads a shared library and
that library transitively uses pthread locks. In that case, the locks may
not be initialized yet and behave as nops, causing the thread synchronization
to not to work.
Linking corerun / coreconsole with pthreads ensures that the locks are always
properly initialized.
|
|
[tfs-changeset: 1507366]
|
|
Allow coreconsole to be called without extension
|
|
|
|
This change modifies the Unix hosting API so that the hosting app can create
as many managed delegates as it needs and execute them as many times it wants.
The new API contains separate functions to initialize and shutdown CoreCLR
and a function to create a delegate.
The current ExecuteAssembly function behavior stays unmodified for now to
ensure that dnx that uses that API and that pulls the binary libcoreclr
is not broken.
After the dnx is updated to use the new coreclr_create_delegate API, I'll remove
the ExecuteAssembly.
Also done:
1) Added support for comments and skipping empty lines in the mscorwks_unixexports.src.
2) Restructured the mscorwks_unixexports.src
3) Added coreclr_execute_assembly to the unixinterface.cpp / exports
4) Modified coreruncommon.cpp to use the new hosting API
|
|
ExecuteAssembly is initializing exitCode to 0 on entrance to the function. If it then fails prior to exitCode being set when invoking the entry point, the exitCode remains 0 even though there was a failure, and corerun ends up returning a successful exit code.
|
|
|
|
Needed cstdlib to build properly
|
|
Created a Unix version of coreconsole which, like the Windows version,
is similar to corerun but runs the managed binary with the same name as
the executable (but with the DLL extension). Moved code that is common
between corerun and coreconsole to coreruncommon.
Remove the workaround for the XCode 6.3 SDK issue wherein some of the
system headers that we reference try to include a __debug header which
does not exist. The 6.3.1 update fixed that issue so the workaround is no
longer required.
Fix #747
|
|
Remove Mac build workaround for __debug
|
|
Remove the workaround for the issue in XCode 6.3 where __debug was being
included by some system headers but was not present. We were adding our
own include directory with a dummy '__debug' file. The issue has been
fixed by Apple in 6.3.1 so we no longer need this workaround.
|
|
Cleanup signal handling. Make sure the default signal action will happen if no previous handler by restore the signal and returning from the handler restarting the h/w exception.
|
|
Fixes issue #801 which was caused by the CoreCLR and PAL being
dlopened, but pthread not being initialized by the runtime linker yet.
FreeBSD requires that the main executable load pthread, rather than a
downstream dependency. Also fixed a few missing calls to pthread_attr_init
which was causing asserts() on FBSD.
|
|
Test CLR hosting under a debugger (lldb). In order to test the debugger modules and coreclr running together in the same process, add the test command "corerun" to the lldb plugin that uses the CLR hosting apis to run managed code in the lldb process.
Fixed a problem where the dac module was picking up an constructor in the coreclr module instead of using the dac version. This is because the corerun code was dlopen'ing coreclr with RTLD_GLOBAL which exposed all the symbols to the reset of the dynamic modules loaded. Changing it to RTLD_LOCAL (the default) fixes this problem.
Changed from an ASSERT to an ERROR in the hardware exception handler because ASSERT does an SIGTRAP (DebugBreak) that keeps recursively being hit.
Removed all signals that installed a fatal_signal_handler especially SIGINT which was interfering with lldb's. The rest of the signals, the default action should be good enough.
Checked if the EE was started in the VM's hardware exception handler just to make sure everything is ready before the managed exception chain is called.
Cleanup signal thread masking. Only wait for SIGINT/SIGQUIT explicitly instead of trying to mask all the signals we don't want to wait on.
|
|
Thanks to Jan Vorlicek for finding the source of the first linker error. Those
linker options need to be passed to the linker on FreeBSD too.
The second linker error is caused by the fact that FreeBSD has no libdl, the
functionality is instead implemented in libc. Thus do not add the -ldl option
to the linker on FreeBSD. Fixes #739
This is fixes the build on FreeBSD completely!
|
|
Add missing MIT license headers
|
|
.rc and .def files were missing the MIT license headers, so this
change adds them.
|
|
libcoreclr has a dependency on libcoreclrpal, but libcoreclrpal is
usually not on the path the loader probes, since it is SxS with the
runtime itself.
Instead of forcing LD_LIBRARY_PATH to be set just have corerun load the
PAL from the same folder as the runtime before loading libcoreclr.
Fixes #709
|
|
together with other UAP components
[tfs-changeset: 1452859]
|
|
My previous change introduced a new subfolder to unixcorerun, but I forgot to update the .gitmirror file to a .gitmirrrorall file.
[tfs-changeset: 1452317]
|
|
The newest version of XCode and the Command Line tools in OSX has an
issue where including some header files will issue an error because the
__debug header can not be included. See
https://devforums.apple.com/message/1124445 for more context.
While a fix is being developed by apple, simple include a dummy version
of this header file so the build works with the new toolset.
|
|
While root causing some of our test failures on Linux, I found that
quirks were enabled, causing tests expecting new behavior to fail when
they encountered the old behavior. This commit modifies the Unix
corerun to include the "UseLatestBehaviorWhenTFMNotSpecified" AppDomain
compat switch (as the Windows version does) so that execution on Unix
picks up the latest behavior rather than falling back to the old quirked
behavior.
|
|
Unix's corerun tries to parse a path out of argv[0], and blows up
in std::string if no '/' is found. This commit adds a check to make
sure that there was a '/' found, after first expanding argv[0] to an
absolute path.
|
|
A lot of security transparency annotations in corefx is missing or inconsistent. People keep running into MethodAccessExceptions because of that. It is not easy (nor cheap) to fix the annotations to make them consistent, and they are not actually required for any of the .NET Core scenarios.
This change is introducing a hosting flag to disable security transparency checks on CoreCLR, and adds this flag to all .NET Core hosts. The .NET Core hosts outside of the CoreCLR tree (e.g. ASP.NET 5) will need this flag added as well.
[tfs-changeset: 1437325]
|
|
|
|
Hosts like ASP.net don't want to call ExecuteAssembly, because their
entry point is library, not a managed exe. However, forcing cross
platform hosts to actually call CreateAppDomainWithManager and
CreateDelegate themselves requires a bunch of tedious code, since these
hosts don't have access to mscoree.h and the PAL.
This change adds the ability to specificy an assembly, type and method
which can be used as a custom entrypoint. The signiture of the managed
entry point needs to be `static int E(int, char**)`.
|
|
Delete host authentication enforcement
|