Comments (7)
I have just figured out how to build with the v6 ilc by only using dotnet publish for its access to ilc and then manually calling link.exe with link "obj\x64\Release\net5.0\win-x64\native\EfiSharp.obj" /subsystem:EFI_APPLICATION /entry:EfiMain ..\EfiSharp.Native\x64\release\EFiSharp.Native.lib
.
This is to get around ilc v6 introducing its own /subsystem and /entry arguments and also adding in runtime.lib and bootstrapper.lib. It appears I was not the only one to discover this change as at roughly the same time I was trying figuring this out, dotnet/runtimelab#633 was posted.
Ideally, I would be able to use the stock runtime.lib or at least the portable version but current attempts result in quite a few unresolved externals.
I have tried to work around this on the NativeAOT-Test.Corelib-RuntimeFix branch but even fixing all errors just allows the wrong entry point to be used.
from efisharp.
Attempting to join both the v6 and runtime changes does resolve the errors in the previous image but leads instead to over a hundred missing external symbols in low level functions.
At least some of the ones in MathHelpers.obj appear due to no c runtime which could be solved with a freestanding one like mlibc but most appear specific to the dotnet.
from efisharp.
At least some of the ones in MathHelpers.obj appear due to no c runtime which could be solved with a freestanding one like mlibc but most appear specific to the dotnet.
Yep, this is missing C runtime (GSHandlerCheck, fltused, round, etc.), plus missing Win32 APIs (DuplicateHandle, GetCurrentThread, etc.)
Runtime.lib needs to be ported from Windows to UEFI to be usable.
(Cool project, btw! )
from efisharp.
Yep, this is missing C runtime (GSHandlerCheck, fltused, round, etc.), plus missing Win32 APIs (DuplicateHandle, GetCurrentThread, etc.)
Runtime.lib needs to be ported from Windows to UEFI to be usable.
(Cool project, btw! )
I did know about the Runtime.lib issues, I already added part of MathHelpers.cpp so I could cast float to ulong but going much further and adding functions like RhpNewArray proved a bit hard.
Weirdly, at one point I did have libcmt.lib errors so it was being used. I did check and I do not have /NODEFAULTLIB anymore so not sure why it disappeared.
from efisharp.
The updated compiler almost deals with all the errors in the first red image, all that is left is the unresolved floating point operations in MathHelpers.obj. The linker says it is the Runtime.lib version however so I worry that once I fix these errors I will get the grey error list again.
from efisharp.
It turns out I was mistaken and those errors were only shown because I forgot to include my version of MathHelpers.cpp. It would probably a good idea to deal with those functions at some point however as floating point support is still quite limited and even modulus is currently broken.
Also it turns out hyperv is only picky about adding file permissions to images in locations were questionable. Taking full ownership of the project folder before making EfiSharp.vhd means that hyperv will read it without first using icacls to give it access.
from efisharp.
I guess the v6 compiler uses exe now, even for efi binaries.
Changing its extension to efi does result in a useable image so it is fine either way.
from efisharp.
Related Issues (15)
- Pressing backspace during Console.ReadLine allows removing prompt HOT 1
- Console.ReadKey fails to read in lower case a
- Console.ReadLine returns a different string when control chars are used HOT 1
- Add support for writing floats and doubles to the console HOT 4
- Disable Watchdog Boot Timer
- Move virtual machine guids to git ignored config file HOT 3
- Specify custom entry point HOT 16
- Efi Support HOT 1
- Array Support HOT 8
- Exception Support HOT 1
- Improved Console Support HOT 4
- System.Private.CoreLib support HOT 1
- Fix hyperv support HOT 1
- Improving Windows Debugging Experience
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from efisharp.