![]() |
|
![]() |
|
|
Thread Tools | Display Modes |
|
|
#11 |
|
Professional Programmer
|
why don't you run it just in windows. why does the assembler need to come in?
if you've made a .exe from a .c file it's already been linked and assembled. |
|
|
|
|
|
#12 |
|
Newbie
Join Date: Aug 2005
Posts: 17
Rep Power: 0
![]() |
no you see, I'm making an operating system, and using assembler to boot it and then it starts a C program
|
|
|
|
|
|
#13 |
|
Professional Programmer
|
That's not how you go about making an operating system. If you actually were making one, that .exe would likely be completely useless. Searche these forums for making an OS if you're really interested in the subject. Also, look into creating shared libraries, that's how OS's get the job done, not .exe's.
__________________
% rc4 hexkey < input > output
#define S ,t=s[i],s[i]=s[j],s[j]=t /* rc4 hexkey <file */
unsigned char k[256],s[256],i,j,t;main(c,v,e)char**v;{++v;while(++i)s[
i]=i;for(c=0;*(*v)++;k[c++]=e)sscanf((*v)++-1,"%2x",&e);while(j+=s[i]
+k[i%c]S,++i);for(j=0;c=~getchar();putchar(~c^s[t+=s[i]]))j+=s[++i]S;} |
|
|
|
|
|
#14 |
|
Expert Programmer
Join Date: Aug 2005
Location: Rotterdam, the Netherlands
Posts: 942
Rep Power: 4
![]() |
you are thinking wrong, m8.. you make the entrypoint for your kernel in assembly, and assemble it. the entrypoint sets up a stack, and calls the function to start the ball rolling, which can also be made in C. after that, you can just link all the files together.
I'd recommend to link to Sun's ELF format, and use GRUB to load your kernel in the memory. You shouldn't start with the bootloader - you will probably stop frustrated before you've even started your kernel itself. |
|
|
|
![]() |
| Bookmarks |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| Display Modes | |
|
|