| View Issue Details [ Jump to Notes ] | [ Print ] | ||||||||
| ID | Project | Category | View Status | Date Submitted | Last Update | ||||
| 0014059 | CMake | (No Category) | public | 2013-04-03 11:09 | 2013-10-07 10:04 | ||||
| Reporter | ashuang | ||||||||
| Assigned To | |||||||||
| Priority | normal | Severity | major | Reproducibility | always | ||||
| Status | closed | Resolution | not fixable | ||||||
| Platform | OS | Ubuntu | OS Version | 10.04 i386 | |||||
| Product Version | CMake 2.8.9 | ||||||||
| Target Version | Fixed in Version | ||||||||
| Summary | 0014059: CMake double executes a custom command when multiple custom target depend on it | ||||||||
| Description | CMakeLists.txt: cmake_minimum_required(VERSION 2.8) add_custom_command(OUTPUT a.txt COMMAND touch a.txt COMMENT "Making a") add_custom_target(b ALL COMMENT "Making b" DEPENDS a.txt) add_custom_target(c ALL COMMENT "Making c" DEPENDS a.txt) add_custom_target(d ALL COMMENT "Making d" DEPENDS a.txt) | ||||||||
| Steps To Reproduce | Run: $ cmake . $ make -j 3 [ 16%] [ 33%] [ 50%] Making a Making a Making a [ 66%] [ 83%] [100%] Making b Making d Making c [100%] [100%] Built target b Built target d [100%] Built target c | ||||||||
| Additional Information | I would expect to see only one instance of "Making a". When I use this pattern with a more complex add_custom_command(), the output file gets corrupted because multiple processes are writing to the file at the same time. | ||||||||
| Tags | No tags attached. | ||||||||
| Attached Files | |||||||||
| Relationships | |
| Relationships |
| Notes | |
|
(0032749) Brad King (manager) 2013-04-03 11:25 |
http://www.cmake.org/Wiki/CMake_FAQ#How_can_I_generate_a_file_used_in_more_than_one_target_in_the_same_directory.3F [^] |
|
(0034024) Robert Maynard (manager) 2013-10-07 10:04 |
Closing resolved issues that have not been updated in more than 4 months. |
| Notes |
| Issue History | |||
| Date Modified | Username | Field | Change |
| 2013-04-03 11:09 | ashuang | New Issue | |
| 2013-04-03 11:25 | Brad King | Note Added: 0032749 | |
| 2013-04-03 11:25 | Brad King | Status | new => resolved |
| 2013-04-03 11:25 | Brad King | Resolution | open => not fixable |
| 2013-10-07 10:04 | Robert Maynard | Note Added: 0034024 | |
| 2013-10-07 10:04 | Robert Maynard | Status | resolved => closed |
| Issue History |
| Copyright © 2000 - 2018 MantisBT Team |