I've been writing small snippets or single projects for quite long time, but this time I came across a 'solution', which requires more than one project to be attached.
So, why does this needed? Because my project stands up the following way:
The core is in a static library
There's an executable which requires functions from the core
There's a DLL which requires functions from the core
Some other minor projects
Okay, it's not even hard, it's logical. I don't want to compile the core each time, so I put it in a lib. The only problem started to occur, when I started to compile.
A simple #pragma comment(lib,"mylibrary.lib") wasn't enough, the solution couldn't find this file. I had to do the following trick, to compile my solution: #pragma comment(lib,"..\\Release\\mylib.lib").
Of course it's not the best solution, since what if I'm compiling it in debug mode? Maybe I could write a define, but it doesn't feel quite professional. Even a problem occurs after compilation. I'm getting tons of warnings:
2>Lib32Anticheat.lib(disasm.obj) : warning LNK4204: 'C:\Users\Unknown User\Desktop\Lib32Anticheat\Release\Lib32Anticheat.pdb' is missing debugging information for referencing module; linking object as if no debug info
2>Lib32Anticheat.lib(disasm_x86.obj) : warning LNK4204: 'C:\Users\Unknown User\Desktop\Lib32Anticheat\Release\Lib32Anticheat.pdb' is missing debugging information for referencing module; linking object as if no debug info
2>Lib32Anticheat.lib(cpu.obj) : warning LNK4204: 'C:\Users\Unknown User\Desktop\Lib32Anticheat\Release\Lib32Anticheat.pdb' is missing debugging information for referencing module; linking object as if no debug info
2>LIBCMT.lib(dyn_tls_dtor.obj) : warning LNK4099: PDB 'libcmt.pdb' was not found with 'LIBCMT.lib(dyn_tls_dtor.obj)' or at 'C:\Users\Unknown User\Desktop\Lib32Anticheat\Release\libcmt.pdb'; linking object as if no debug info
2>LIBCMT.lib(dyn_tls_init.obj) : warning LNK4099: PDB 'libcmt.pdb' was not found with 'LIBCMT.lib(dyn_tls_init.obj)' or at 'C:\Users\Unknown User\Desktop\Lib32Anticheat\Release\libcmt.pdb'; linking object as if no debug info
2>LIBCMT.lib(matherr_detection.obj) : warning LNK4099: PDB 'libcmt.pdb' was not found with 'LIBCMT.lib(matherr_detection.obj)' or at 'C:\Users\Unknown User\Desktop\Lib32Anticheat\Release\libcmt.pdb'; linking object as if no debug info
2>LIBCMT.lib(guard_support.obj) : warning LNK4099: PDB 'libcmt.pdb' was not found with 'LIBCMT.lib(guard_support.obj)' or at 'C:\Users\Unknown User\Desktop\Lib32Anticheat\Release\libcmt.pdb'; linking object as if no debug info
2>LIBCMT.lib(gs_cookie.obj) : warning LNK4099: PDB 'libcmt.pdb' was not found with 'LIBCMT.lib(gs_cookie.obj)' or at 'C:\Users\Unknown User\Desktop\Lib32Anticheat\Release\libcmt.pdb'; linking object as if no debug info
2>LIBCMT.lib(gs_report.obj) : warning LNK4099: PDB 'libcmt.pdb' was not found with 'LIBCMT.lib(gs_report.obj)' or at 'C:\Users\Unknown User\Desktop\Lib32Anticheat\Release\libcmt.pdb'; linking object as if no debug info
2>LIBCMT.lib(gs_support.obj) : warning LNK4099: PDB 'libcmt.pdb' was not found with 'LIBCMT.lib(gs_support.obj)' or at 'C:\Users\Unknown User\Desktop\Lib32Anticheat\Release\libcmt.pdb'; linking object as if no debug info
2>LIBCMT.lib(pesect.obj) : warning LNK4099: PDB 'libcmt.pdb' was not found with 'LIBCMT.lib(pesect.obj)' or at 'C:\Users\Unknown User\Desktop\Lib32Anticheat\Release\libcmt.pdb'; linking object as if no debug info
2>LIBCMT.lib(cpu_disp.obj) : warning LNK4099: PDB 'libcmt.pdb' was not found with 'LIBCMT.lib(cpu_disp.obj)' or at 'C:\Users\Unknown User\Desktop\Lib32Anticheat\Release\libcmt.pdb'; linking object as if no debug info
2>LIBCMT.lib(ehprolg3.obj) : warning LNK4099: PDB 'libcmt.pdb' was not found with 'LIBCMT.lib(ehprolg3.obj)' or at 'C:\Users\Unknown User\Desktop\Lib32Anticheat\Release\libcmt.pdb'; linking object as if no debug info
2>LIBCMT.lib(secchk.obj) : warning LNK4099: PDB 'libcmt.pdb' was not found with 'LIBCMT.lib(secchk.obj)' or at 'C:\Users\Unknown User\Desktop\Lib32Anticheat\Release\libcmt.pdb'; linking object as if no debug info
2>LIBCMT.lib(loadcfg.obj) : warning LNK4099: PDB 'libcmt.pdb' was not found with 'LIBCMT.lib(loadcfg.obj)' or at 'C:\Users\Unknown User\Desktop\Lib32Anticheat\Release\libcmt.pdb'; linking object as if no debug info
2>LIBCMT.lib(argv_mode.obj) : warning LNK4099: PDB 'libcmt.pdb' was not found with 'LIBCMT.lib(argv_mode.obj)' or at 'C:\Users\Unknown User\Desktop\Lib32Anticheat\Release\libcmt.pdb'; linking object as if no debug info
2>LIBCMT.lib(commit_mode.obj) : warning LNK4099: PDB 'libcmt.pdb' was not found with 'LIBCMT.lib(commit_mode.obj)' or at 'C:\Users\Unknown User\Desktop\Lib32Anticheat\Release\libcmt.pdb'; linking object as if no debug info
2>LIBCMT.lib(denormal_control.obj) : warning LNK4099: PDB 'libcmt.pdb' was not found with 'LIBCMT.lib(denormal_control.obj)' or at 'C:\Users\Unknown User\Desktop\Lib32Anticheat\Release\libcmt.pdb'; linking object as if no debug info
2>LIBCMT.lib(file_mode.obj) : warning LNK4099: PDB 'libcmt.pdb' was not found with 'LIBCMT.lib(file_mode.obj)' or at 'C:\Users\Unknown User\Desktop\Lib32Anticheat\Release\libcmt.pdb'; linking object as if no debug info
2>LIBCMT.lib(fltused.obj) : warning LNK4099: PDB 'libcmt.pdb' was not found with 'LIBCMT.lib(fltused.obj)' or at 'C:\Users\Unknown User\Desktop\Lib32Anticheat\Release\libcmt.pdb'; linking object as if no debug info
2>LIBCMT.lib(invalid_parameter_handler.obj) : warning LNK4099: PDB 'libcmt.pdb' was not found with 'LIBCMT.lib(invalid_parameter_handler.obj)' or at 'C:\Users\Unknown User\Desktop\Lib32Anticheat\Release\libcmt.pdb'; linking object as if no debug info
2>LIBCMT.lib(matherr.obj) : warning LNK4099: PDB 'libcmt.pdb' was not found with 'LIBCMT.lib(matherr.obj)' or at 'C:\Users\Unknown User\Desktop\Lib32Anticheat\Release\libcmt.pdb'; linking object as if no debug info
2>LIBCMT.lib(new_mode.obj) : warning LNK4099: PDB 'libcmt.pdb' was not found with 'LIBCMT.lib(new_mode.obj)' or at 'C:\Users\Unknown User\Desktop\Lib32Anticheat\Release\libcmt.pdb'; linking object as if no debug info
2>LIBCMT.lib(thread_locale.obj) : warning LNK4099: PDB 'libcmt.pdb' was not found with 'LIBCMT.lib(thread_locale.obj)' or at 'C:\Users\Unknown User\Desktop\Lib32Anticheat\Release\libcmt.pdb'; linking object as if no debug info
2>LIBCMT.lib(ehvecdtr.obj) : warning LNK4099: PDB 'libcmt.pdb' was not found with 'LIBCMT.lib(ehvecdtr.obj)' or at 'C:\Users\Unknown User\Desktop\Lib32Anticheat\Release\libcmt.pdb'; linking object as if no debug info
2>LIBCMT.lib(std_type_info_static.obj) : warning LNK4099: PDB 'libcmt.pdb' was not found with 'LIBCMT.lib(std_type_info_static.obj)' or at 'C:\Users\Unknown User\Desktop\Lib32Anticheat\Release\libcmt.pdb'; linking object as if no debug info
2>LIBCMT.lib(tncleanup.obj) : warning LNK4099: PDB 'libcmt.pdb' was not found with 'LIBCMT.lib(tncleanup.obj)' or at 'C:\Users\Unknown User\Desktop\Lib32Anticheat\Release\libcmt.pdb'; linking object as if no debug info
2>LIBCMT.lib(delete_array.obj) : warning LNK4099: PDB 'libcmt.pdb' was not found with 'LIBCMT.lib(delete_array.obj)' or at 'C:\Users\Unknown User\Desktop\Lib32Anticheat\Release\libcmt.pdb'; linking object as if no debug info
2>LIBCMT.lib(delete_scalar.obj) : warning LNK4099: PDB 'libcmt.pdb' was not found with 'LIBCMT.lib(delete_scalar.obj)' or at 'C:\Users\Unknown User\Desktop\Lib32Anticheat\Release\libcmt.pdb'; linking object as if no debug info
2>LIBCMT.lib(new_array.obj) : warning LNK4099: PDB 'libcmt.pdb' was not found with 'LIBCMT.lib(new_array.obj)' or at 'C:\Users\Unknown User\Desktop\Lib32Anticheat\Release\libcmt.pdb'; linking object as if no debug info
2>LIBCMT.lib(new_scalar.obj) : warning LNK4099: PDB 'libcmt.pdb' was not found with 'LIBCMT.lib(new_scalar.obj)' or at 'C:\Users\Unknown User\Desktop\Lib32Anticheat\Release\libcmt.pdb'; linking object as if no debug info
2>LIBCMT.lib(throw_bad_alloc.obj) : warning LNK4099: PDB 'libcmt.pdb' was not found with 'LIBCMT.lib(throw_bad_alloc.obj)' or at 'C:\Users\Unknown User\Desktop\Lib32Anticheat\Release\libcmt.pdb'; linking object as if no debug info
2>LIBCMT.lib(thread_safe_statics.obj) : warning LNK4099: PDB 'libcmt.pdb' was not found with 'LIBCMT.lib(thread_safe_statics.obj)' or at 'C:\Users\Unknown User\Desktop\Lib32Anticheat\Release\libcmt.pdb'; linking object as if no debug info
2>LIBCMT.lib(exe_main.obj) : warning LNK4099: PDB 'libcmt.pdb' was not found with 'LIBCMT.lib(exe_main.obj)' or at 'C:\Users\Unknown User\Desktop\Lib32Anticheat\Release\libcmt.pdb'; linking object as if no debug info
2>LIBCMT.lib(tlssup.obj) : warning LNK4099: PDB 'libcmt.pdb' was not found with 'LIBCMT.lib(tlssup.obj)' or at 'C:\Users\Unknown User\Desktop\Lib32Anticheat\Release\libcmt.pdb'; linking object as if no debug info
2>LIBCMT.lib(initializers.obj) : warning LNK4099: PDB 'libcmt.pdb' was not found with 'LIBCMT.lib(initializers.obj)' or at 'C:\Users\Unknown User\Desktop\Lib32Anticheat\Release\libcmt.pdb'; linking object as if no debug info
2>LIBCMT.lib(utility.obj) : warning LNK4099: PDB 'libcmt.pdb' was not found with 'LIBCMT.lib(utility.obj)' or at 'C:\Users\Unknown User\Desktop\Lib32Anticheat\Release\libcmt.pdb'; linking object as if no debug info
2>LIBCMT.lib(default_precision.obj) : warning LNK4099: PDB 'libcmt.pdb' was not found with 'LIBCMT.lib(default_precision.obj)' or at 'C:\Users\Unknown User\Desktop\Lib32Anticheat\Release\libcmt.pdb'; linking object as if no debug info
2>LIBCMT.lib(utility_desktop.obj) : warning LNK4099: PDB 'libcmt.pdb' was not found with 'LIBCMT.lib(utility_desktop.obj)' or at 'C:\Users\Unknown User\Desktop\Lib32Anticheat\Release\libcmt.pdb'; linking object as if no debug info
2>LIBCMT.lib(utility_static.obj) : warning LNK4099: PDB 'libcmt.pdb' was not found with 'LIBCMT.lib(utility_static.obj)' or at 'C:\Users\Unknown User\Desktop\Lib32Anticheat\Release\libcmt.pdb'; linking object as if no debug info
2>LIBCMT.lib(initsect.obj) : warning LNK4099: PDB 'libcmt.pdb' was not found with 'LIBCMT.lib(initsect.obj)' or at 'C:\Users\Unknown User\Desktop\Lib32Anticheat\Release\libcmt.pdb'; linking object as if no debug info
2> Win32Anticheat.vcxproj -> C:\Users\Unknown User\Desktop\Lib32Anticheat\Release\Win32Anticheat.exe
So, after that log, I assume that it's missing debug information, which can make bug finding harder. In Debug mode I'm not getting such warnings, but I think that I should adjust something or make something different just to make sure that Release mode isn't giving such warnings.
Personally I would not make the core of your product a static library. Your DLL and your EXE will each get their own copy of it, which will be two distinct and separate entities. Anything that is supposed to be static and single, will instead be doubled up. And your program may not behave as expected.
Second, I think that LNK4099 warnings cannot be suppressed. If your getting them, it's probably because you are linking in a release lib when you are building debug, or vice versa.
I would personally not use #pragma statements to do your linking. I've seen it done in the past, and those projects were always poorly built. Specify your library linkage in the project or make files: that is what they are there for.
Related
I have set up a service to use SLF4J and Log4j2 but I am unable to get the specified logs in the pattern layout specified. My dependencies are:
log4j-slf4j-impl: 2.17.2
slf4j-api: 1.7.36
When I boot my service with -Dlog4j2.debug, I see the following:
DEBUG StatusLogger PluginManager 'Lookup' found 16 plugins
DEBUG StatusLogger null null initializing configuration org.apache.logging.log4j.core.config.properties.PropertiesConfiguration#2f5ac102
DEBUG StatusLogger PluginManager 'Core' found 128 plugins
DEBUG StatusLogger PluginManager 'Level' found 0 plugins
DEBUG StatusLogger PluginManager 'Lookup' found 16 plugins
DEBUG StatusLogger Building Plugin[name=AppenderRef, class=org.apache.logging.log4j.core.config.AppenderRef].
TRACE StatusLogger TypeConverterRegistry initializing.
DEBUG StatusLogger PluginManager 'TypeConverter' found 26 plugins
DEBUG StatusLogger createAppenderRef(ref="STDOUT", level="null", Filter=null)
DEBUG StatusLogger Building Plugin[name=root, class=org.apache.logging.log4j.core.config.LoggerConfig$RootLogger].
DEBUG StatusLogger LoggerConfig$RootLogger$Builder(additivity="null", level="INFO", levelAndRefs="null", includeLocation="null", ={STDOUT}, ={}, Configuration(PropertiesConfig), Filter=null)
DEBUG StatusLogger Building Plugin[name=loggers, class=org.apache.logging.log4j.core.config.LoggersPlugin].
DEBUG StatusLogger createLoggers(={root})
DEBUG StatusLogger Building Plugin[name=layout, class=org.apache.logging.log4j.core.layout.PatternLayout].
DEBUG StatusLogger PatternLayout$Builder(pattern="[%p] %d [%t] %c %M - %m%n", PatternSelector=null, Configuration(PropertiesConfig), Replace=null, charset="null", alwaysWriteExceptions="null", disableAnsi="null", noConsoleNoAnsi="null", header="null", footer="null")
DEBUG StatusLogger PluginManager 'Converter' found 45 plugins
DEBUG StatusLogger Building Plugin[name=appender, class=org.apache.logging.log4j.core.appender.ConsoleAppender].
DEBUG StatusLogger ConsoleAppender$Builder(target="SYSTEM_OUT", follow="null", direct="null", bufferedIo="null", bufferSize="null", immediateFlush="null", ignoreExceptions="null", PatternLayout([%p] %d [%t] %c %M - %m%n), name="STDOUT", Configuration(PropertiesConfig), Filter=null, ={})
DEBUG StatusLogger Starting OutputStreamManager SYSTEM_OUT.false.false
DEBUG StatusLogger Building Plugin[name=appenders, class=org.apache.logging.log4j.core.config.AppendersPlugin].
DEBUG StatusLogger createAppenders(={STDOUT})
DEBUG StatusLogger Configuration org.apache.logging.log4j.core.config.properties.PropertiesConfiguration#2f5ac102 initialized
DEBUG StatusLogger Starting configuration org.apache.logging.log4j.core.config.properties.PropertiesConfiguration#2f5ac102
DEBUG StatusLogger Started configuration org.apache.logging.log4j.core.config.properties.PropertiesConfiguration#2f5ac102 OK.
TRACE StatusLogger Stopping org.apache.logging.log4j.core.config.DefaultConfiguration#3c69362a...
TRACE StatusLogger DefaultConfiguration notified 1 ReliabilityStrategies that config will be stopped.
TRACE StatusLogger DefaultConfiguration stopping root LoggerConfig.
TRACE StatusLogger DefaultConfiguration notifying ReliabilityStrategies that appenders will be stopped.
TRACE StatusLogger DefaultConfiguration stopping remaining Appenders.
DEBUG StatusLogger Shutting down OutputStreamManager SYSTEM_OUT.false.false-1
DEBUG StatusLogger OutputStream closed
DEBUG StatusLogger Shut down OutputStreamManager SYSTEM_OUT.false.false-1, all resources released: true
DEBUG StatusLogger Appender DefaultConsole-1 stopped with status true
TRACE StatusLogger DefaultConfiguration stopped 1 remaining Appenders.
TRACE StatusLogger DefaultConfiguration cleaning Appenders from 1 LoggerConfigs.
DEBUG StatusLogger Stopped org.apache.logging.log4j.core.config.DefaultConfiguration#3c69362a OK
TRACE StatusLogger Reregistering MBeans after reconfigure. Selector=org.apache.logging.log4j.core.selector.ClassLoaderContextSelector#5a1c3cb4
TRACE StatusLogger Using default SystemClock for timestamps.
DEBUG StatusLogger org.apache.logging.log4j.core.util.SystemClock does not support precise timestamps.
TRACE StatusLogger Using DummyNanoClock for nanosecond timestamps.
DEBUG StatusLogger Reconfiguration complete for context[name=Default] at URI jar:file:[redacted]/log4j2.properties (org.apache.logging.log4j.core.LoggerContext#78e22d35) with optional ClassLoader: null
DEBUG StatusLogger Shutdown hook enabled. Registering a new one.
DEBUG StatusLogger LoggerContext[name=Default, org.apache.logging.log4j.core.LoggerContext#78e22d35] started OK.
It looks like my file is picked with pattern: [%p] %d [%t] %c %M - %m%n
My Log4j2 Config:
# properties file metadata
status=error
dest=err
name=PropertiesConfig
# console appender will log to stdout
appender.consoleAppender.type=Console
appender.consoleAppender.name=STDOUT
appender.consoleAppender.target=SYSTEM_OUT
appender.consoleAppender.layout.type=PatternLayout
appender.consoleAppender.layout.pattern=[%p] %d [%t] %c %M - %m%n
# log level information
rootLogger.level=info
rootLogger.appenderRef.consoleAppender.ref=STDOUT
But all my logs are coming as:
22:10:55,360 INFO org.eclipse.jetty.server.Server - Started #2187ms
I saw your log4j config, and then I observed that your log4j config file may be the incorrect way.
log4j. must be included for each key, according to the documentation.
your log4j Config:
# properties file metadata
status=error
dest=err
name=PropertiesConfig
# console appender will log to stdout
appender.consoleAppender.type=Console
appender.consoleAppender.name=STDOUT
appender.consoleAppender.target=SYSTEM_OUT
appender.consoleAppender.layout.type=PatternLayout
appender.consoleAppender.layout.pattern=[%p] %d [%t] %c %M - %m%n
# log level information
rootLogger.level=info
rootLogger.appenderRef.consoleAppender.ref=STDOUT
Updated log4j.properties Config:
# properties file metadata
status=error
dest=err
name=PropertiesConfig
# console appender will log to stdout
log4j.appender.console=org.apache.log4j.ConsoleAppender
log4j.appender.console.target=System.out
log4j.appender.console.layout=org.apache.log4j.PatternLayout
log4j.appender.console.layout.ConversionPattern=[%p] %d [%t] %c %M - %m%n
# log level information
log4j.rootLogger=info,console
Note: If you are using SYSTEM_OUT in target then the warning message came on the console.
log4j:WARN [SYSTEM_OUT] should be System.out or System.err.
log4j:WARN Using previously set target, System.out by default.
in my case Pom.xml:
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-log4j12</artifactId>
<version>1.7.5</version>
</dependency>
Thanks.
I am building my first release version of Xamarin Android with MvvmCross. Just like most other people who have similar issue, the app run ok in debug mode but not release with linking. I have been stuck and searched for days but still could not resolve it. Please kindly help.
I have the latest Visual Studio 2017 v15.7.2, .net 4.7.03056, Xamarin 4.10.0.48 & Android SDK 8.1 installed.
To resolve the issue, I start running in Debug mode with linking “Sdk Assemblies Only” and not using Shared Runtime. The following errors occur:
05-24 02:21:52.490 D/Mono( 9114) : Assembly Loader probing location: '/usr/local/lib/mono/gac/System.Runtime/4.0.0.0__b03f5f7f11d50a3a/System.Runtime.dll'.
05-24 02:21:52.490 D/Mono( 9114) : Assembly Loader probing location: '/usr/local/lib/System.Runtime.dll'.
05-24 02:21:52.490 D/Mono( 9114) : Assembly Loader probing location: '/usr/local/lib/mono/gac/System.Runtime/4.0.0.0__b03f5f7f11d50a3a/System.Runtime.exe'.
05-24 02:21:52.491 D/Mono( 9114) : Assembly Loader probing location: '/usr/local/lib/System.Runtime.exe'.
05-24 02:21:52.491 D/Mono( 9114) : Assembly Loader probing location: '/usr/local/lib/mono/gac/System.Runtime/4.0.0.0__b03f5f7f11d50a3a/System.Runtime.dll'.
05-24 02:21:52.491 D/Mono( 9114) : Assembly Loader probing location: '/storage/emulated/0/Android/data/.../files/.__override__/System.Runtime.dll'.
05-24 02:21:52.491 D/Mono( 9114) : Assembly Loader probing location: '/usr/local/lib/System.Runtime.dll'.
05-24 02:21:52.491 D/Mono( 9114) : Assembly Loader probing location: '/usr/local/lib/mono/gac/System.Runtime/4.0.0.0__b03f5f7f11d50a3a/System.Runtime.exe'.
05-24 02:21:52.491 D/Mono( 9114) : Assembly Loader probing location: '/storage/emulated/0/Android/data/xxx.Droid/files/.__override__/System.Runtime.exe'.
05-24 02:21:52.493 D/Mono( 9114) : Assembly Loader probing location: '/usr/local/lib/System.Runtime.exe'.
05-24 02:21:52.493 W/Mono( 9114) : The following assembly referenced from /storage/emulated/0/Android/data/xxx.Droid/files/.__override__/MvvmCross.Platform.dll could not be loaded:
05-24 02:21:52.493 W/Mono( 9114) : Assembly: System.Runtime(assemblyref_index=0)
05-24 02:21:52.493 W/Mono( 9114) : Version: 4.0.0.0
05-24 02:21:52.493 W/Mono( 9114) : Public Key: b03f5f7f11d50a3a
05-24 02:21:52.493 W/Mono( 9114) : The assembly was not found in the Global Assembly Cache, a path listed in the MONO_PATH environment variable, or in the location of the executing assembly(/storage/emulated/0/Android/data/xxx.Droid/files/.__override__/).
05-24 02:21:52.493 D/Mono( 9114) : Failed to load assembly MvvmCross.Platform[0xe7ec5ea0].
05-24 02:21:52.493 W/ ( 9114): Could not load signature of MvvmCross.Platform.Droid.Views.MvxEventSourceActivity:add_CreateWillBeCalled due to: Could not load file or assembly 'System.Runtime, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies.assembly:System.Runtime, Version= 4.0.0.0, Culture= neutral, PublicKeyToken= b03f5f7f11d50a3a type:<unknown type> member:(null) signature:<none>
Unhandled Exception:
System.TypeLoadException: Could not resolve the signature of a virtual method
05-24 02:24:36.309 D/Mono( 9114) : Assembly Ref addref xxx.Droid[0xe7ec5240] -> MvvmCross.Plugins.ResxLocalization[0xe7ec6260]: 2
05-24 02:24:36.310 D/Mono ( 9114): Assembly Loader probing location: '/usr/local/lib/mono/gac/System.Runtime/4.0.0.0__b03f5f7f11d50a3a/System.Runtime.dll'.
05-24 02:24:36.310 D/Mono( 9114) : Assembly Loader probing location: '/usr/local/lib/System.Runtime.dll'.
05-24 02:24:36.310 D/Mono( 9114) : Assembly Loader probing location: '/usr/local/lib/mono/gac/System.Runtime/4.0.0.0__b03f5f7f11d50a3a/System.Runtime.exe'.
05-24 02:24:36.310 D/Mono( 9114) : Assembly Loader probing location: '/usr/local/lib/System.Runtime.exe'.
05-24 02:24:36.311 D/Mono( 9114) : Assembly Loader probing location: '/usr/local/lib/mono/gac/System.Runtime/4.0.0.0__b03f5f7f11d50a3a/System.Runtime.dll'.
05-24 02:24:36.311 D/Mono( 9114) : Assembly Loader probing location: '/storage/emulated/0/Android/data/xxx.Droid/files/.__override__/System.Runtime.dll'.
It seems that it is trying to locate an older version of System.Runtime. I added bindingRedirect to the app.conig. No luck with it: Removing all dependentAssembly does not help too. My System.Runtime version is 4.3.0
<configuration>
<runtime>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly>
<assemblyIdentity name="System.Collections.Immutable" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-1.2.2.0" newVersion="1.2.2.0" />
<assemblyIdentity name="System.Runtime" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-4.1.1.0" newVersion="4.3.0" />
</dependentAssembly>
</assemblyBinding>
</runtime>
</configuration>
When running in Release mode with “Sdk Assemblies Only”, I got the following message in log (sorry for not able to copy it as text but screen shot only):
This looks more like related to linking. I have the standard LinkerPleaseInclude with all property & method that were bound in my xml specified. However, the app crash at the splash screen before reaching my own code. This is the code of my splashscreen, just the untouched one clone from the sample.
namespace xxx.Droid
{
[Activity(
Label = "xxx.Droid"
, MainLauncher = true
, Icon = "#drawable/icon"
, Theme = "#style/Theme.Splash"
, NoHistory = true
, ScreenOrientation = ScreenOrientation.Portrait)]
public class SplashScreen : MvxSplashScreenActivity
{
public SplashScreen()
: base(Resource.Layout.splash_screen)
{
}
}
}
In summary,
I have 3 questions right now:
BindingRedirect in debug mode does not work. Cannot run with linking in debug mode made problem solving much harder
In release mode, crash at splash screen. However, I cannot see what is missing from the log
Is there any rule / hint from log to find out what should be included in the linkerpleaseinclude?
Thank you very much for any help
Nick
My solution consists of 3 projects:
My backend project with assembly My_Test_App (portable)
My_Test_App.Android
My_Test_App.iOS
I develop using VS2015 and use mac to build and deploy. It works fine in iOS simulator. My iOS project do not use linker. Also i have LLVM and incremental build already unchecked.
But when i tried to debug to iPhone device, i got this error:
Severity Code Description Project File Line Suppression State
Error Could not AOT the assembly/Users/myMacName/Library/Caches/Xamarin/mtbs/builds/My_Test_App.iOS/c7eaf4168fcb1f8aaecd3a6cbb0f37ee/obj/iPhone/Release/mtouch-cache/64/Build/My_Test_App.dll' My_Test_App.iOS
My question is:
How do you disable the AOT in the Xamarin.iOS project? When i check the csproj file of the iOS project, it does not have like in the droid project.
Is disabling the AOT the correct way to solve it?
Thank you for answering!
My build log:
1>------ Build started: Project: My_Test_App.Droid, Configuration: Debug Any CPU ------
2>------ Build started: Project: My_Test_App.iOS, Configuration: Debug iPhone ------
1> Consider app.config remapping of assembly "System.Runtime, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" from Version "4.0.0.0" [] to Version "4.1.0.0" [C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\MonoAndroid\v1.0\Facades\System.Runtime.dll] to solve conflict and get rid of warning.
1>C:\Program Files (x86)\MSBuild\14.0\bin\Microsoft.Common.CurrentVersion.targets(1820,5): warning MSB3247: Found conflicts between different versions of the same dependent assembly. In Visual Studio, double-click this warning (or select it and press Enter) to fix the conflicts; otherwise, add the following binding redirects to the "runtime" node in the application configuration file: <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1"><dependentAssembly><assemblyIdentity name="System.Runtime" culture="neutral" publicKeyToken="b03f5f7f11d50a3a" /><bindingRedirect oldVersion="0.0.0.0-4.1.0.0" newVersion="4.1.0.0" /></dependentAssembly></assemblyBinding>
1>C:\Program Files (x86)\MSBuild\14.0\bin\Microsoft.Common.CurrentVersion.targets(1820,5): warning MSB3277: Found conflicts between different versions of the same dependent assembly that could not be resolved. These reference conflicts are listed in the build log when log verbosity is set to detailed.
1> My_Test_App.Droid -> D:\Project\2017\Xamarin Test\test-mobile\My Test App\My_Test_App.Droid\bin\Debug\My_Test_App.Droid.dll
2> Generated session id: c7eaf4168fcb1f8aaecd3a6cbb0f37ee
2> Generated build app name: My_Test_App.iOS
2> Connecting to Mac server MTMAC22s-Mac-mini.local...
2> No way to resolve conflict between "System.Runtime.Serialization, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" and "System.Runtime.Serialization, Version=2.0.5.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e". Choosing "System.Runtime.Serialization, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" arbitrarily.
2> Consider app.config remapping of assembly "System.Numerics, Culture=neutral, PublicKeyToken=b77a5c561934e089" from Version "2.0.5.0" [C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\Xamarin.iOS\v1.0\System.Numerics.dll] to Version "4.0.0.0" [C:\Windows\Microsoft.Net\assembly\GAC_MSIL\System.Numerics\v4.0_4.0.0.0__b77a5c561934e089\System.Numerics.dll] to solve conflict and get rid of warning.
2> Consider app.config remapping of assembly "System.Net.Http, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" from Version "1.5.0.0" [] to Version "4.0.0.0" [C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\Xamarin.iOS\v1.0\System.Net.Http.dll] to solve conflict and get rid of warning.
2>C:\Program Files (x86)\MSBuild\14.0\bin\Microsoft.Common.CurrentVersion.targets(1820,5): warning MSB3276: Found conflicts between different versions of the same dependent assembly. Please set the "AutoGenerateBindingRedirects" property to true in the project file. For more information, see http://go.microsoft.com/fwlink/?LinkId=294190.
2>C:\Program Files (x86)\MSBuild\14.0\bin\Microsoft.Common.CurrentVersion.targets(1820,5): warning MSB3277: Found conflicts between different versions of the same dependent assembly that could not be resolved. These reference conflicts are listed in the build log when log verbosity is set to detailed.
2>D:\Project\2017\Xamarin Test\test-mobile\My Test App\My_Test_App.iOS\Renderers\CustomLabelRenderer.cs(143,53,143,69): warning CS0618: 'Label.Font' is obsolete: 'Please use the Font attributes which are on the class itself. Obsoleted in v1.3.0'
2> My_Test_App.iOS -> D:\Project\2017\Xamarin Test\test-mobile\My Test App\My_Test_App.iOS\bin\iPhone\Debug\My_Test_AppiOS.exe
2> Detected signing identity:
2> Code Signing Key: "iPhone Developer: myemail#mycompany.com (HDZY35YSCS)" (6E0C54049FD692EBF4A54BBD72889DC336388268)
2> Provisioning Profile: "iOS Team Provisioning Profile: com.yourcompany.MyTestApp" (8f408fd0-90e0-4031-92e8-a6a56530778a)
2> Bundle Id: com.yourcompany.MyTestApp
2> App Id: F8AZP5FC9H.com.yourcompany.MyTestApp
2> Mono Ahead of Time compiler - compiling assembly /Users/mtmac22/Library/Caches/Xamarin/mtbs/builds/My_Test_App.iOS/c7eaf4168fcb1f8aaecd3a6cbb0f37ee/obj/iPhone/Debug/mtouch-cache/64/Build/System.Net.Primitives.dll
2> AOTID BE85C9F7-62C4-0559-D329-FA98D6ECDAF2
2> Code: 0(0%) Info: 0(0%) Ex Info: 0(0%) Unwind Info: 0(0%) Class Info: 7(2%) PLT: 1(0%) GOT Info: 236(71%) Offsets: 86(26%) GOT: 120
2> Compiled: 0/0 (100%), No GOT slots: 0 (100%), Direct calls: 0 (100%)
2> Output file: '/Users/mtmac22/Library/Caches/Xamarin/mtbs/builds/My_Test_App.iOS/c7eaf4168fcb1f8aaecd3a6cbb0f37ee/obj/iPhone/Debug/mtouch-cache/System.Net.Primitives.dll.arm64.s'.
2> Linking symbol: '_mono_aot_module_System_Net_Primitives_info'.
2> JIT time: 0 ms, Generation time: 0 ms, Assembly+Link time: 0 ms.
2> /Users/builder/data/lanes/3969/7beaef43/source/xamarin-macios/external/mono/eglib/src/ghashtable.c:549: assertion 'hash != NULL' failed
2> Mono Ahead of Time compiler - compiling assembly /Users/mtmac22/Library/Caches/Xamarin/mtbs/builds/My_Test_App.iOS/c7eaf4168fcb1f8aaecd3a6cbb0f37ee/obj/iPhone/Debug/mtouch-cache/64/Build/System.Xml.ReaderWriter.dll
2> AOTID 77D080C4-2116-2E71-9BA1-0FB994D16E87
2> Code: 0(0%) Info: 0(0%) Ex Info: 0(0%) Unwind Info: 0(0%) Class Info: 7(2%) PLT: 1(0%) GOT Info: 236(71%) Offsets: 86(26%) GOT: 120
2> Compiled: 0/0 (100%), No GOT slots: 0 (100%), Direct calls: 0 (100%)
2> Output file: '/Users/mtmac22/Library/Caches/Xamarin/mtbs/builds/My_Test_App.iOS/c7eaf4168fcb1f8aaecd3a6cbb0f37ee/obj/iPhone/Debug/mtouch-cache/System.Xml.ReaderWriter.dll.arm64.s'.
2> Linking symbol: '_mono_aot_module_System_Xml_ReaderWriter_info'.
2> JIT time: 0 ms, Generation time: 0 ms, Assembly+Link time: 0 ms.
2> /Users/builder/data/lanes/3969/7beaef43/source/xamarin-macios/external/mono/eglib/src/ghashtable.c:549: assertion 'hash != NULL' failed
2> Mono Ahead of Time compiler - compiling assembly /Users/mtmac22/Library/Caches/Xamarin/mtbs/builds/My_Test_App.iOS/c7eaf4168fcb1f8aaecd3a6cbb0f37ee/obj/iPhone/Debug/mtouch-cache/64/Build/My_Test_AppiOS.exe
2> AOTID 298562A7-A350-2A44-1D0B-2E4FC728F9D1
2> Code: 54748(65%) Info: 456(0%) Ex Info: 19951(23%) Unwind Info: 1136(1%) Class Info: 4700(5%) PLT: 190(0%) GOT Info: 2018(2%) Offsets: 626(0%) GOT: 2872
2> Compiled: 97/97 (100%), No GOT slots: 0 (0%), Direct calls: 15 (37%)
2> Output file: '/Users/mtmac22/Library/Caches/Xamarin/mtbs/builds/My_Test_App.iOS/c7eaf4168fcb1f8aaecd3a6cbb0f37ee/obj/iPhone/Debug/mtouch-cache/My_Test_AppiOS.exe.arm64.s'.
2> Linking symbol: '_mono_aot_module_My_Test_AppiOS_info'.
2> JIT time: 21 ms, Generation time: 25 ms, Assembly+Link time: 0 ms.
2> AOT Compilation exited with code 139, command:
2> MONO_PATH=/Users/mtmac22/Library/Caches/Xamarin/mtbs/builds/My_Test_App.iOS/c7eaf4168fcb1f8aaecd3a6cbb0f37ee/obj/iPhone/Debug/mtouch-cache/64/Build /Library/Frameworks/Xamarin.iOS.framework/Versions/10.3.1.8/bin/arm64-darwin-mono-sgen --debug -O=gsharedvt --aot=mtriple=arm64-ios,data-outfile=/Users/mtmac22/Library/Caches/Xamarin/mtbs/builds/My_Test_App.iOS/c7eaf4168fcb1f8aaecd3a6cbb0f37ee/obj/iPhone/Debug/mtouch-cache/My_Test_App.arm64.aotdata,static,asmonly,direct-icalls,full,soft-debug,dwarfdebug,no-direct-calls,outfile=/Users/mtmac22/Library/Caches/Xamarin/mtbs/builds/My_Test_App.iOS/c7eaf4168fcb1f8aaecd3a6cbb0f37ee/obj/iPhone/Debug/mtouch-cache/My_Test_App.dll.arm64.s "/Users/mtmac22/Library/Caches/Xamarin/mtbs/builds/My_Test_App.iOS/c7eaf4168fcb1f8aaecd3a6cbb0f37ee/obj/iPhone/Debug/mtouch-cache/64/Build/My_Test_App.dll"
2>C:\Program Files (x86)\MSBuild\Xamarin\iOS\Xamarin.iOS.Common.targets(696,3): error : Could not AOT the assembly '/Users/mtmac22/Library/Caches/Xamarin/mtbs/builds/My_Test_App.iOS/c7eaf4168fcb1f8aaecd3a6cbb0f37ee/obj/iPhone/Debug/mtouch-cache/64/Build/My_Test_App.dll'
2> at Xamarin.Bundler.AOTTask.Build () [0x00117] in <e61e7c7e12a34f76bb60aae297cbc79c>:0
2> at Xamarin.Bundler.BuildTask.Execute () [0x00000] in <e61e7c7e12a34f76bb60aae297cbc79c>:0
2> at Xamarin.Bundler.BuildTasks.Execute (Xamarin.Bundler.BuildTask v) [0x00000] in <e61e7c7e12a34f76bb60aae297cbc79c>:0
2> at System.Threading.Tasks.Parallel+<ForEachWorker>c__AnonStorey6`2[TSource,TLocal].<>m__0 (System.Int32 i) [0x00012] in <8f2c484307284b51944a1a13a14c0266>:0
2> at System.Threading.Tasks.Parallel+<ForWorker>c__AnonStorey3`1[TLocal].<>m__1 () [0x000ed] in <8f2c484307284b51944a1a13a14c0266>:0
========== Build: 1 succeeded, 1 failed, 1 up-to-date, 0 skipped ==========
You cannot disable AOT on iOS, your project won't work as iDevices do not allow JIT'ing
No unfortunately no.
We'd need a longer build log (add '-v -v -v' as 'mtouch' arguments), but it can happen because the assembly is too big. you might want to enable Linking All Assemblies in the iOS project settings.
See this for additional references: https://forums.xamarin.com/discussion/457/error-could-not-aot-the-assembly-servicestack-text-monotouch-dll
EDIT:
I used process Monitor to check, which executable gets invoked. it Looks like it really invokes the vs2008 executables...
https://skydrive.live.com/redir?resid=5062EFE7E0C8ECCC!2722&authkey=!AMdRW6t5aMB3u10&v=3&ithint=photo%2c.PNG
msbuild.exe executes [(12.0)tracker.exe], but gives it [(9.0)cl.exe] as command line Argument...
Any idea, how to solve this?
original
on my work computer, The VS Default templates for c++ produce build Errors. (VS2010, VS2012, VS2013)
It Kind of Looks like it invokes an old Version of the Compiler (unknown Option '/sdl', where sdl probably stands for security development LifeCycle, which has been added with vs2012, if i remember correctly)
OS: Windows 8 (x64)
Installed VS Versions: 2008, 2010, 2012, 2013 (in this order)
i already tried reinstalling vs2013 and resetting the Settings.
VS2010
Visual C++ -> Win32 -> Win32 Console Application (Finish on the first page of the wizard)
1>------ Build started: Project: asd, Configuration: Debug Win32 ------
1>Build started 11.12.2013 00:22:53.
1>PrepareForBuild:
1> Creating directory "c:\users\myusername\documents\visual studio 2010\Projects\asd\Debug\".
1>InitializeBuildStatus:
1> Creating "Debug\asd.unsuccessfulbuild" because "AlwaysCreate" was specified.
1>ClCompile:
1> stdafx.cpp
1> asd.cpp
1>RC : fatal error RC1106: invalid option: -ologo
1>
1>
1>Build FAILED.
1>
1>Time Elapsed 00:00:00.56
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========
VS2013
Visual C++ -> Win32 -> Win32 Console Application (Finish on the first page of the wizard)
1>------ Rebuild All started: Project: ConsoleApplication1, Configuration: Debug Win32 ------
1>cl : Command line warning D9002: ignoring unknown option '/sdl'
1> stdafx.cpp
1>cl : Command line warning D9002: ignoring unknown option '/sdl'
1> ConsoleApplication1.cpp
1>LINK : fatal error LNK1117: syntax error in option 'manifest:embed'
========== Rebuild All: 0 succeeded, 1 failed, 0 skipped ==========
If i go to Properties -> Manifest Tool -> Input and Output and Change Embed Manifest from Yes to No, it works (and the warning disappears too)
Visual C++ -> MFC -> MFC Application (Finish on the first page of the wizard)
1>------ Build started: Project: MFCApplication4, Configuration: Debug Win32 ------
1>cl : Command line warning D9002: ignoring unknown option '/sdl'
1> stdafx.cpp
1>cl : Command line warning D9002: ignoring unknown option '/sdl'
1> ViewTree.cpp
1> PropertiesWnd.cpp
1> OutputWnd.cpp
1> MFCApplication4View.cpp
1> MFCApplication4Doc.cpp
1> MFCApplication4.cpp
1>c:\users\myusername\documents\visual studio 2013\projects\mfcapplication4\mfcapplication4\mfcapplication4.cpp(39): error C2065: 'm_dwRestartManagerSupportFlags' : undeclared identifier
1>c:\users\myusername\documents\visual studio 2013\projects\mfcapplication4\mfcapplication4\mfcapplication4.cpp(39): error C2065: 'AFX_RESTART_MANAGER_SUPPORT_ALL_ASPECTS' : undeclared identifier
1>c:\users\myusername\documents\visual studio 2013\projects\mfcapplication4\mfcapplication4\mfcapplication4.cpp(49): error C3861: 'SetAppID': identifier not found
1>c:\users\myusername\documents\visual studio 2013\projects\mfcapplication4\mfcapplication4\mfcapplication4.cpp(86): error C3861: 'EnableTaskbarInteraction': identifier not found
1> MainFrm.cpp
1>c:\users\myusername\documents\visual studio 2013\projects\mfcapplication4\mfcapplication4\mainfrm.cpp(351): error C2653: 'CMFCVisualManagerVS2008' : is not a class or namespace name
1>c:\users\myusername\documents\visual studio 2013\projects\mfcapplication4\mfcapplication4\mainfrm.cpp(356): error C2653: 'CMFCVisualManagerWindows7' : is not a class or namespace name
1> FileView.cpp
1> ClassView.cpp
1> ChildFrm.cpp
1> Generating Code...
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========
If i configure a MFC-Dialog based Application (which was my original goal), i get the following error:
1>------ Build started: Project: MFCApplication3, Configuration: Debug Win32 ------
1> stdafx.cpp
1> MFCApplication3Dlg.cpp
1> MFCApplication3.cpp
1> Generating Code...
1>RC : fatal error RC1106: invalid option: -ologo
1>
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========
No idea if it helps, but here is a list with all installed MS Software:
https://skydrive.live.com/redir?resid=5062EFE7E0C8ECCC!2721&authkey=!APk3skYPRCffPWQ&ithint=folder%2c
Ok, i found the solution myself.
similar to this (http://social.msdn.microsoft.com/Forums/de-DE/baf613fc-3b24-4f47-9800-38499965e9dc/vs2010-is-using-a-wrong-compiler-Version) question, my "Microsoft.Cpp.Win32.user" property sheet contained references to the vs2008 directories. i have no clue how they got there, but removing them solved my problem.
open View -> Other Windows -> Property Manager
double click on Microsoft.Cpp.Win32.user
go to VC++ Directories
rows which have been changed are bold. on all bold rows, click inside the text field, then on the Dropdown menu select inherit from parent or Project Defaults
I verified that it now uses the correct Compiler by compiling the following snippet:
auto asd = std::make_unique<int>();
make_unique has been added with VS2013.
Anyone have a clue, what changed These values?
The difference between libwinutils.vcxproj and winutils.vcxproj shows the problem.
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" /> appears before Release|Win32 PropertyGroup.
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<UseDebugLibraries>false</UseDebugLibraries>
<WholeProgramOptimization>true</WholeProgramOptimization>
<CharacterSet>Unicode</CharacterSet>
<PlatformToolset>v110</PlatformToolset>
</PropertyGroup>
Open winutils.vcxproj, and move <Import ...> after Release|Win32 PropertyGroup, like the following quote:
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<UseDebugLibraries>false</UseDebugLibraries>
<WholeProgramOptimization>true</WholeProgramOptimization>
<CharacterSet>Unicode</CharacterSet>
<PlatformToolset>v110</PlatformToolset>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
I have successfully built winutils of hadoop-2.7.0-src with VS2012 toolset.
I upgraded (clean install) from Win7+VS2012 to Win8+VS2012.
I ran into a problem just after that: When I try to run any project with the processor target AnyCPU or x86, vshost.exe crashes immediately after building and starting the project with an Access Violation. This behavior is not affected by changing the type of the project (console, winforms, wpf).
When I change the architecture to x64 however, debugging works just fine.
This is the output I get in the Debug output window if I start a new created console application:
'ConsoleApplication2.vshost.exe' (Managed (v4.0.30319)): Loaded 'C:\Windows\Microsoft.Net\assembly\GAC_32\mscorlib\v4.0_4.0.0.0__b77a5c561934e089\mscorlib.dll', Symbols loaded.
'ConsoleApplication2.vshost.exe' (Managed (v4.0.30319)): Loaded 'C:\Windows\assembly\GAC_MSIL\Microsoft.VisualStudio.HostingProcess.Utilities\11.0.0.0__b03f5f7f11d50a3a\Microsoft.VisualStudio.HostingProcess.Utilities.dll', Symbols loaded.
'ConsoleApplication2.vshost.exe' (Managed (v4.0.30319)): Loaded 'C:\Windows\Microsoft.Net\assembly\GAC_MSIL\System.Windows.Forms\v4.0_4.0.0.0__b77a5c561934e089\System.Windows.Forms.dll', Symbols loaded.
'ConsoleApplication2.vshost.exe' (Managed (v4.0.30319)): Loaded 'C:\Windows\Microsoft.Net\assembly\GAC_MSIL\System.Drawing\v4.0_4.0.0.0__b03f5f7f11d50a3a\System.Drawing.dll', Symbols loaded.
'ConsoleApplication2.vshost.exe' (Managed (v4.0.30319)): Loaded 'C:\Windows\Microsoft.Net\assembly\GAC_MSIL\System\v4.0_4.0.0.0__b77a5c561934e089\System.dll', Symbols loaded.
'ConsoleApplication2.vshost.exe' (Managed (v4.0.30319)): Loaded 'C:\Windows\assembly\GAC_MSIL\Microsoft.VisualStudio.HostingProcess.Utilities.Sync\11.0.0.0__b03f5f7f11d50a3a\Microsoft.VisualStudio.HostingProcess.Utilities.Sync.dll', Symbols loaded.
'ConsoleApplication2.vshost.exe' (Managed (v4.0.30319)): Loaded 'C:\Windows\assembly\GAC_MSIL\Microsoft.VisualStudio.Debugger.Runtime\11.0.0.0__b03f5f7f11d50a3a\Microsoft.VisualStudio.Debugger.Runtime.dll'
'ConsoleApplication2.vshost.exe' (Managed (v4.0.30319)): Loaded 'e:\Users\SeriTools\Documents\Visual Studio 2012\Projects\ConsoleApplication2\ConsoleApplication2\bin\Debug\ConsoleApplication2.vshost.exe', Symbols loaded.
'ConsoleApplication2.vshost.exe' (Managed (v4.0.30319)): Loaded 'C:\Windows\Microsoft.Net\assembly\GAC_MSIL\System.Core\v4.0_4.0.0.0__b77a5c561934e089\System.Core.dll', Symbols loaded.
'ConsoleApplication2.vshost.exe' (Managed (v4.0.30319)): Loaded 'C:\Windows\Microsoft.Net\assembly\GAC_MSIL\System.Xml.Linq\v4.0_4.0.0.0__b77a5c561934e089\System.Xml.Linq.dll', Symbols loaded.
'ConsoleApplication2.vshost.exe' (Managed (v4.0.30319)): Loaded 'C:\Windows\Microsoft.Net\assembly\GAC_MSIL\System.Data.DataSetExtensions\v4.0_4.0.0.0__b77a5c561934e089\System.Data.DataSetExtensions.dll', Symbols loaded.
'ConsoleApplication2.vshost.exe' (Managed (v4.0.30319)): Loaded 'C:\Windows\Microsoft.Net\assembly\GAC_MSIL\Microsoft.CSharp\v4.0_4.0.0.0__b03f5f7f11d50a3a\Microsoft.CSharp.dll', Symbols loaded.
'ConsoleApplication2.vshost.exe' (Managed (v4.0.30319)): Loaded 'C:\Windows\Microsoft.Net\assembly\GAC_32\System.Data\v4.0_4.0.0.0__b77a5c561934e089\System.Data.dll', Symbols loaded.
'ConsoleApplication2.vshost.exe' (Managed (v4.0.30319)): Loaded 'C:\Windows\Microsoft.Net\assembly\GAC_MSIL\System.Xml\v4.0_4.0.0.0__b77a5c561934e089\System.Xml.dll', Symbols loaded.
The thread 'vshost.NotifyLoad' (0x1068) has exited with code 0 (0x0).
The thread '<No Name>' (0x16c8) has exited with code 0 (0x0).
The thread '<No Name>' (0x1688) has exited with code 0 (0x0).
The thread 'vshost.LoadReference' (0x233c) has exited with code 0 (0x0).
'ConsoleApplication2.vshost.exe' (Managed (v4.0.30319)): Loaded 'e:\users\seritools\documents\visual studio 2012\Projects\ConsoleApplication2\ConsoleApplication2\bin\Debug\ConsoleApplication2.exe', Symbols loaded.
The program '[5088] ConsoleApplication2.vshost.exe: Program Trace' has exited with code 0 (0x0).
The program '[5088] ConsoleApplication2.vshost.exe: Managed (v4.0.30319)' has exited with code -1073741819 (0xc0000005) 'Access violation'.
What I tried to fix that:
Completely removed and reinstalled VS, checking if not applying Update 1 changes anything
devenv.exe /ResetSettings and uninstalling all plugins/add-ins
running VS as admin
Can someone help me with this problem?