User forums > Using Code::Blocks

Adding include directory

(1/3) > >>

Kaz:
Hello,

I want to enable the line 2 in the photo


--- Code: ---#include <glad/gl.h>
--- End code ---

by adding the include directory, rather than writing the full path as in the line 1.
And I think I did so, as in the build log, but when I try to open #include file:  'glad/gl.h', I get this warning "Not found".

So can anyone tell me how to do this corrctly?

gd_on:
I think you should write

--- Code: ---#include "glad/gl.h"
--- End code ---
<> is normally reserved for standard compiler paths.

stahta01:
https://wiki.codeblocks.org/index.php/FAQ-Compiling_(general)#Q:_I_would_like_to_compile_a_project_using_some_non-standard_libraries._How_can_I_indicate_to_CodeBlocks_that_these_libraries_and_include_files_exist.3F

WARNING: Use the "For your project :" section of the directions!

Tim S.

stahta01:

--- Quote from: gd_on on May 11, 2021, 04:16:22 pm ---I think you should write

--- Code: ---#include "glad/gl.h"
--- End code ---
<> is normally reserved for standard compiler paths.

--- End quote ---

The above is likely officially true; but, in practice it tends to mean an Compiler or Third Party include when using angle brackets <>.

Tim S. 

Kaz:

--- Quote from: stahta01 on May 11, 2021, 04:24:35 pm ---https://wiki.codeblocks.org/index.php/FAQ-Compiling_(general)#Q:_I_would_like_to_compile_a_project_using_some_non-standard_libraries._How_can_I_indicate_to_CodeBlocks_that_these_libraries_and_include_files_exist.3F

WARNING: Use the "For your project :" section of the directions!

Tim S.

--- End quote ---

I added the path to both for compiler and linker, but unfortunately still can't open the header file.

I also tried replacing "" with <>, which didn't make a difference either.

Navigation

[0] Message Index

[#] Next page

Go to full version