Say I have a program called a.c and a header and library files named header.h and header.c
In a subdir avr there are three subdir to avr named code, where a.c resides and include where header.h resides and lib where header.c resides.
avr --- code/a.c
In a.c there is a line
#include "/home/avr/code/header.h" // I'm using ubuntu
In makefile the source file list is
SRC = $(TARGET).c /
When the header file is in a subdir below the code subdir this works.
What I would like to know how to do is place header.h and header.c in individual subdirs and a.c in yet another and have it all work. Is this the proper way to setup my library? If not, how? My brain is kind of dense, please give both an explanation and an example.