jdah / jdh-8

An 8-bit minicomputer with a fully custom architecture
MIT License
1.29k stars 89 forks source link

Make windows compilation successful #4

Closed Kylogias closed 3 years ago

Kylogias commented 3 years ago

NOTE :: This lays the groundwork for windows compilation to be successful but it doesn't ensure that the compiled code will run properly. This PR also cleans up some code to make MinGW-W64 throw less errors and to make time measurements more exact (1024*1024 for megahertz instead of 1000000). Should close #1

Kylogias commented 3 years ago

BUG :: Compilation IS successful but when you try to run in the emulator, it silently fails. In fact, if you try to do anything, it silently fails

Kylogias commented 3 years ago

I suggest putting the Windows build instructions inside the REAdME,along with eeything else.

Done, although I don't know exactly what you mean when you say "everything else"

jdah commented 3 years ago

Wow, nice PR (and thank you for sticking in the style of the existing codebase!) don't have time to merge this in now, but will get to it in the next day or so :)

Kylogias commented 3 years ago

Wow, nice PR (and thank you for sticking in the style of the existing codebase!) don't have time to merge this in now, but will get to it in the next day or so :)

Thanks, I literally didn't touch the codebase, I only touched the includes. I included stdio.h which iirc wasn't in the original code so you may want to check if it compiles

CoolCat467 commented 3 years ago

Nice!

Kylogias commented 3 years ago

I have identified a bug, although I am unsure how to fix it. The bug is that enter doesn't stop the simulation, at least on Windows

jdah commented 3 years ago

This has been merged in with other changes alongside cd6cf42a3e0e333939255c5fdbc5202d122e727e.

jdah commented 3 years ago

If you can fix the enter bug (that's all poll is used for btw) please open another PR :)