Opened 3 years ago

Closed 2 years ago

#61 closed enhancement (wontfix)

path names in #include

Reported by: kolya Owned by:
Priority: minor Milestone:
Component: VTM Version: VTM-1.1
Keywords: include, paths Cc: ksuehring, XiangLi, fbossen, jvet@…

Description

Is it possible to refactor source files so that include paths would be relative to every current file? Like "../CommonDef.h" instead of "CommonLib/CommonDef.h". It seems that current cmake-based build system would not be changed much after this, but this _local_ naming relative to current file position in folder structure may simplify alternative builds.

Change history (3)

comment:1 Changed 3 years ago by ksuehring

Have you actually tried doing this?

My expectation would be that you end up in a mess of dependencies that cannot be resolved.

If you include a header a.h from a header b.h and include b.h in a source file aa.cpp with a certain relative path, you can fix the reference to a.h, so that is relative to aa.cpp. But if you have a file bb.cpp in a different location, your reference to a.h will become wrong, because it's used relative to bb.cpp, not b.h. But, you can't change b.h, because aa.cpp wouldn't compile anymore.

comment:2 Changed 3 years ago by ksuehring

  • Milestone BMS-1.2 deleted

comment:3 Changed 2 years ago by ksuehring

  • Resolution set to wontfix
  • Status changed from new to closed

We don't see a strong need to act on this.

Note: See TracTickets for help on using tickets.