Program no compile.

I´m trying programming c with dev-c++ in w7.
When I compile the "hello world" I receive this message.

#include <stdio.h>
int main(){
printf("hello world");
// system("PAUSE");
return 0;
i:\gw\lib\crt2.o(.text+0x8) In function `_mingw_CRTStartup':
[Linker error] undefined reference to `__dyn_tls_init_callback'
[Linker error] undefined reference to `__cpu_features_init'
i:\gw\lib\crt2.o(.text+0x8) ld returned 1 exit status
C:\Users\trabajo\Desktop\proyectos tp\ [Build Error] [aaaaaaaa.exe] Error 1
Is your linker trying to link from unavailable/unnecessary directories and files?

Go to your linker's settings, or only link the object files themself manually.

If all fails, just try to reinstall, and maybe any search directories, strange libs or linking objects will return to default.
I had the same issue when I reinstalled that version of Dev-C++ so it's definitely a common thing. Either your installation is corrupt, or you have more than one mingw installation on your system.
closed account (Dy7SLyTq)
dont you have to include <stdio.h>
They did include standard I/O library "stdio.h".

The problem seems to be with linking to non-existant objects.
closed account (Dy7SLyTq)
i for some reason was thinking they included stdlib
Version is pretty antiquated (February 2005).

I'd suggest uninstalling it and downoad the latest version 5.4.0 instead. Note, this is Orwell Dev-C++ which is currently maintained, last update was five days ago:
Last edited on
Topic archived. No new replies allowed.