-
-
Notifications
You must be signed in to change notification settings - Fork 187
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
Prefix replacement in osx-64 breaks build as it causes null bytes in the middle of paths #1351
Comments
Would move this issue to conda-build since this is an issue with building packages. All conda-smithy does is configure repos with recipes to build on CI and deploy. With that said, could try disabling prefix replacement selectively or generally in packages where it’s cause issues. |
Agreed. If @jjhelmus wants to move the issue, that’s great, otherwise we should close it. |
Seems to be conda/conda-build#1674. Specifically conda/conda-build#1674 (comment). As it's still open there, I'll close it here.
|
AFAIK GitHub does not allow issues to be moved between organization 😢 |
I apologise in advance if this I'm missing something fundamental here, but this has caused a large roadblock for me, and the process of building the package and dependencies is time consuming. I have attempted to reproduce this in a much smaller example, but have been unable to. I must mention that I have very limited experience with clang, which is what I believe is the most likely cause at this point.
Issue
The issue is logged here when debugging our feedstock, where the linux build passes and the osx fails. It shows that prefix replacement is leaving null bytes in replaced prefix paths. When attempting to pass these strings onto a legacy function which I'd prefer not to modify, it is passed on as:
which is interpreted as a null terminated string
Path variable code trace
The linux build passes without this problem however, which is where I feel I'm a little out of my depth due to my lack of experience with clang. I attempted to use the
boost::filesystem::path
type in hopes that it would differ from using strings, as I saw @isuruf mention in an archived gitter log there would be issues when returning the prefix as compile time constant std::strings during prefix replacement. Below is the trace through our code:Tudat_RESOURCE_DIR
is configured during cmake install in theconfig.hpp.in
.RESOURCE_FOLDER
defined as macro ofTudat_RESOURCE_DIR
intudat/resource/resource.h
.boost::filesystem::path
typetudat/paths.hpp
.Attempt to fix (trace step 3)
Attempted to set fixed lengths to each path variable as
char
intudat/resource/resource.h
, in hopes that the strcat would deal with the null terminated string in the concatenation. Still results in failure for only the osx build [full log]:I am aware that they still get converted to strings in
tudat/paths.hpp
. I have not had time to attempt completely removing the std::string type altogether from the tudat project. I apologise if this issue is trivial. It's been a little difficult as I am unable to test the intermediate tudat package, as the prefix path in the test environment exceeds the maximum of 255 chars for our cspice dependency (furnsh_c routine).Initial failure Linux & osx build logs on CircleCI & TravisCI:
The text was updated successfully, but these errors were encountered: