Location of includes in C

3

I am programming in the Atmel Studio IDE in C and when I try to include these libraries

#include <stdio.h>
#include <sys/types.h>
#include <sys/socket.h>
#include <netinet/in.h>

when using its methods and then compiling it does not locate them, as if they did not exist. Where can I find them?

    
asked by Sergio Cv 25.04.2016 в 10:21
source

2 answers

1

First, clarify (or clarify) what you are specifically missing.

  

I try to include these libraries

Those are not libraries, those are C headers (includes) that only serve to declare constants and functions (not "methods").

  

their methods and then compile does not locate them, as if they did not exist

It is impossible to understand what happens to you. It throws you an error that you can not find one of the ".h" included (what?)? Or does it throw an error when compiling does not find the declaration of a function that should be in one of the includes? Or do you throw a link error that does not find the implementation of a function in a library? There are three absolutely different things, and your description of the problem is very vague.

If you are not clear about these things, you should first try to make a very simple program (hello world) ...

    
answered by 04.07.2016 в 01:15
-1

Atmel is a compiler to create applications for small devices that are not PC.

You do not have the system libraries since you do not have a system to use.

If you want to compile for PC, better use other compilers and IDE's (there are hundreds: MSVC, CodeBlocks, gcc, mingw, etc etc etc)

If you want to compile for Atmel devices, you will have to find other libraries that do what you want, because the typical ones will not work for you.

    
answered by 23.06.2016 в 19:00