Skip to content
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

Complete quoting for parameters of some CMake commands #317

Closed
elfring opened this issue Aug 9, 2014 · 6 comments
Closed

Complete quoting for parameters of some CMake commands #317

elfring opened this issue Aug 9, 2014 · 6 comments

Comments

@elfring
Copy link

elfring commented Aug 9, 2014

Some parameters (like "${DOXYGEN_EXECUTABLE}" and "${CMAKE_BINARY_DIR}/image_test") are passed to CMake commands in your build scripts without enclosing them by quotation marks. I see that these places will result in build difficulties if the contents of the used variables will contain special characters like semicolons.

I would recommend to apply advices from a Wiki article.

@piotrdz
Copy link
Contributor

piotrdz commented Aug 10, 2014

That's a good point, but sadly the very authors of CMake seem to make this mistake. Try for example:
$ mkdir "evil directory with semicolons a;b;c"
$ cd "evil directory with semicolons a;b;c"
$ cmake /path/to/colobot/CMakeLists.txt

Errors start appearing very early on within CMake core modules for checking compiler, platform, etc. They don't seem to quote properly ${CMAKE_BINARY_DIR}.

Hence, I don't think it's an issue, at least for the time being. Fixing this on Colobot side will only make sense if the core CMake modules are written properly. I will create a ticket for that in CMake bugtracker and we'll see what they make of it.

@elfring
Copy link
Author

elfring commented Aug 10, 2014

Would you like to discuss such implementation details a bit more on the CMake mailing list?

@piotrdz
Copy link
Contributor

piotrdz commented Aug 10, 2014

For now, I have created a bug report: http://www.cmake.org/Bug/view.php?id=15076

@piotrdz
Copy link
Contributor

piotrdz commented Apr 2, 2016

I think this old issue can be closed as well. People commenting on my CMake bug report have made it clear that at least for now, this is not a bug, but expected behaviour. In any case, this is clearly a CMake issue, and something that cannot be simply fixed on Colobot side.

@piotrdz piotrdz closed this as completed Apr 2, 2016
@elfring
Copy link
Author

elfring commented Apr 6, 2016

…, this is not a bug, …

I got the impression that your report got insufficient software development attention so far. I hope that affected implementation details can still be improved somehow.

@piotrdz
Copy link
Contributor

piotrdz commented Apr 6, 2016

This is not a high priority issue and I suppose that CMake maintainers have more pressing work. Though it would be nice to see some informative warning or error in the case of this issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants