Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Symbol '__start' not found (was: very simple C does not work) #37

Closed
Randrianasulu opened this issue Mar 26, 2023 · 3 comments
Closed

Comments

@Randrianasulu
Copy link

Randrianasulu commented Mar 26, 2023

#include <stdio.h>                                                                                                                       

void main() 
{                                                                        
 putchar(' ');   
}

smlrcc says:

./smlrcc -map mapfile  ../putchar_test.c -I ./v0100/include/       
Symbol '__start' not found       
Failed command 'smlrl -map mapfile -elf ../putchar_test.o -o a.out'
@alexfru
Copy link
Owner

alexfru commented Mar 26, 2023

I understand it, this is on Linux.
You'd need to additionally pass lcl.a (with the appropriate path) to smlrcc.

Alternatively, you could just do the classic

./configure
make
make install

to install the compiler properly and thus avoid passing -I for standard headers or mentioning lcl.a.

@Randrianasulu
Copy link
Author

Thanks, this solved my issue!

@alexfru alexfru changed the title very simple C does not work Symbol '__start' not found (was: very simple C does not work) Mar 26, 2023
@alexfru
Copy link
Owner

alexfru commented Mar 26, 2023

Duplicate of #17 .

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants