sample_defs/tables source files won't compile without table header file include
Nobody has claimed this yet.
- Dominant language
- C
- Stars
- 67
- Forks
- 60
- PR merge metrics
- No merged PRs in 30d
Description
Describe the bug
If we want to put all tables source files in global *_defs directory in a tables dir inside *_defs they need to be able to access *_table.h which would be in the respective app's src directory.
To Reproduce
Steps to reproduce the behavior:
- Create directory in sample_defs called "tables"
- Move sample_table.c into sample_defs/tables directory
- Build cFS (make SIMULATION=native prep, make)
- Build will fail because sample_table.c can't find sample_table.h
Expected behavior
Need to be able to provide includes to sample_defs/tables. As a "hack" I add a "include_directories(fsw/src)" in CMakeLists.txt in apps/sample_app which allows sample_table.c to compile from sample_defs/tables.
System observed on:
- Linux Ubuntu 18.04 LTS
- Native linux cFS build
- Versions cFE 6.7.14, OSAL 5.0.13, PSP 1.4.10
Reporter Info
Joe Mahoney - LTA Research
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reproducing the native Linux build after moving sample_table.c into sample_defs/tables, then inspect apps/sample_app/CMakeLists.txt and the locations of sample_table.c and sample_table.h. Done means sample_table.c in sample_defs/tables can find its table header and the cFS build completes without the manual include_directories workaround.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- c, cmake
- Domain
- build-system
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Clearly specified
- Newbie friendliness
- 35/100