-
Notifications
You must be signed in to change notification settings - Fork 1.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Incorrect header include when built in a syminked directory #1604
Comments
I traced the problematic absolute paths up the dependency chain to <?xml version="1.0" encoding="UTF-8"?>
<!-- =====================================================================
LogPortAi.xml
Generated by fpp-to-xml
====================================================================== -->
<interface namespace="Fw" name="Log">
<comment>
Event log port
</comment>
<import_enum_type>/var/ammos/rps/myint/fprime-hce/Fw/Log/LogSeverityEnumAi.xml</import_enum_type>
<include_header>/var/ammos/rps/myint/fprime-hce/Fw/Log/LogBuffer.hpp</include_header>
<include_header>Fw/Time/Time.hpp</include_header>
<args>
<arg name="id" type="FwEventIdType">
<comment>
Log ID
</comment>
</arg>
<arg name="timeTag" type="Fw::Time" pass_by="reference">
<comment>
Time Tag
</comment>
</arg>
<arg name="severity" type="Fw::LogSeverity">
<comment>
The severity argument
</comment>
</arg>
<arg name="args" type="Fw::LogBuffer" pass_by="reference">
<comment>
Buffer containing serialized log entry
</comment>
</arg>
</args>
</interface> |
@myint this may be an issue in the build system. We try to determine the relative PATHs of files by taking the absolute path and removing a prefix. My guess is that:
Thus to the build system they look to be completely separate path hierarchy and it falls back to using full paths to objects rather than the relative path like you see in Time.hpp. |
The fix is to ensure that all paths either resolve links, or do not resolve links....but not a mixture. |
The build works correctly, today, using To reproduce real errors, build with cmake directly:
This produces an error as the config directory (as loaded from the settings.ini) is resolved and thus cannot be found within the build. Correcting that with:
Reproduces the error here. |
Problem Description
Converted this issue into an epic:
REALPATH
in cmakenormalize_paths
: CMake System UsesREALPATH
innormalize_paths
Incorrectly #2449Incorrect topology includes: Resolution of File Locations Does Not Respect Symbolic Links fpp#370Further description
If I clone/build
fprime
in a symlinked directory, I get the following build error. The error goes away if I clone/build it in a non-symlinked path.The incorrectly autocoded
LogPortAc.hpp
:How to Reproduce
cd
into the above symlink.fprime
.Expected Behavior
I would expect no build error and I would instead expect the autocoder to instead generate the following for
LogPortAc.hpp
. I can make the above autocoding error go away by directlycd
ing into the resolved directory rather than the symlinked path:The text was updated successfully, but these errors were encountered: