"-I" missing from command line for compilation [message #1770930] |
Fri, 18 August 2017 17:15  |
Eclipse User |
|
|
|
I am attempting to reference an include directory in another project.
Eclipse directory description:
- Sqlite (project 1 - builds with no problems)
- Archives (location of .a file)
- Includes (note capital I)
- ARM Crosscompile include directories (created automatically)
- Sqlite/includes (empty, I did NOT create this folder)
- Debug
- includes (I created this folder)
- sqlite3.h
- sqlite3ext.h
- src
- shell.c
- sqlite3.c
- TestSQLiteDBCreate (project 2 - fails to build)
- Archives (I did not create this folder)
- libSqiite.a
- Includes (note capital I)
- ARM Crosscompile include directories (created automatically)
- Sqlite/includes (empty, I did NOT create this folder)
- Debug
- libSqiite.a
- src
- TestSQLiteDBCreate.cpp
In project 2:
Properties->C/C++ Build->Settings->Cross GCC Compiler->Includes
I added to the include paths(-I) using workspace navigation button
"$(workspace_loc:/Sqlite/includes)"
By The Way I also add
Properties->C/C++ Build->Settings->Cross G++ Linker->Librarys
Libraries (-l) I added
"$(workspace_loc:Sqlite/Debug/libSqlite.a)"
File TestSQLiteDBCreate.cpp
has include reference:
#include <sqlite3.h>
the compilation string is :
arm-linux-gnueabihf-g++ [various command line options - but NO -I referencing for any include directory in project SQLite)
I understand why I get "No such file or directory" on the build of project 2. It is because the "-I" reference to the other project is not specified on the command line of the compilation. What I do not understand is why the specification that I provided in the project settings of the second project did not work. I know the the "-I" reference must be on the command line but why is it not.
As an additional question, am I properly setup for referencing "sqlite.a" with the linking phase?
TIA,
Pat
|
|
|
|
Powered by
FUDForum. Page generated in 0.05819 seconds