-4
#include<apis/api1/api.h> 

throws No such file or directory i even tried moving api.h and api.cc to the main project directory and using

#include<api.h> 

does the same thing even though it is in the exact same directory that the other classes use i tried adding /apis/api1 to the compiler search path that just crashes the compiler can someone tell me what to type into the compilers compilation line

jtsfour
  • 5
  • 1
  • 2
  • "throws" is the wrong term. – Yakk - Adam Nevraumont Mar 12 '15 at 20:52
  • *i tried adding /apis/api1 to the compiler search path* - Considering you're using MinGW, that isn't even a valid full path. You might try reading http://stackoverflow.com/questions/21593/what-is-the-difference-between-include-filename-and-include-filename – chris Mar 12 '15 at 20:54
  • actually no i thought it was using mingw im actually using Cygwin ill edit the question – jtsfour Mar 12 '15 at 20:58
  • well it was "throwing" a big problem in my face so technically its the right term – jtsfour Mar 12 '15 at 21:03

1 Answers1

0
#include <api.h>

is the way you include a system header. (That is, the header for a library installed on your system.) It does not search in the directory of the source file or in directories specified in -I command line arguments.

#include "api.h"

is the way you include your own headers. (But it will also search library header locations if it doesn't find the header locally.)

rici
  • 234,347
  • 28
  • 237
  • 341