Pulse-Eight/libcec — Issue #19: #include angle-bracket quoting necessitates adding libcec to include path
Author: Dadeos
Created: 2012-02-05 22:00:41+00:00
State: open

The “cec.h” and “cecc.h” header files currently contain `#include` statements referring to “cectypes.h”. These `#include` statements use angle-bracket notation:

#include

as opposed to double-quote notation:

#include “cectypes.h”

The use of angle-bracket quotation instructs the pre-processor to search the include paths provided to the compiler, which by implication requires the “libcec” include path to be explicitly stated. If these `#include` statements were altered to use double-quote notation then this would instruct the pre-processor to search for “cectypes.h” in the same directory as “cec.h” and “cecc.h”, which is where it resides. It is likely that systems will have arranged for the parent “include” directory, into which the “libcec” subdirectory containing these headers files is installed by default, to be passed to compiler invocations. Therefore it would be possible to compile code containing:

#include

without having to add the “libcec” directory to the compiler’s search path.