Hide Forgot
Description of problem: Hello, When I include <redland.h> in a C++ code, I get the following error: /usr/include/librdf.h:33:20: erreur fatale: rasqal.h : Aucun fichier ou dossier de ce type How reproducible: always Steps to Reproduce: 1. Write in a cpp file #include <redland.h> int main(int char**){return 0;} 2. compile it with gcc Expected results:Compilation should work without any trick Additional info: Workaround : add -I/usr/include/rasqal to the compile line Patch: edit /usr/include/librdf.h replace #include <rasqal.h> with #include <rasqal/rasqal.h> edit /usr/include/rdf_init.h replace #include <rasqal.h> with #include <rasqal/rasqal.h>
$ pkg-config --cflags redland -I/usr/include/rasqal
Exactly, it is not the job of the compiler to guess the include directories of your libraries. There are tools such as pkg-config that does the job. Afaik, most build tools (cmake, scons, waf, autohell, ...) have pkg-config functionality integrated in them for convenience.
The installed packages have to be consistent, therefore I think /usr/include/rdf_init.h and /usr/include/librdf.h should have includes consistent with the folder where librdf.h is stored.
The packages we have in Fedora which use the redland library are quite consistent. Take a look at the output of $ repoquery --whatrequires --alldeps redland to see what packages need redland. If you look at the build systems of these packages, you will see that they use pkg-config to pass the necessary include flags to the compiler. You can also check this through the build logs. For example, here is a list of our ardour builds. You can find the relevant build logs by following the links there. http://koji.fedoraproject.org/koji/packageinfo?packageID=1320