MantisBT - CMake | |||||
| View Issue Details | |||||
| ID | Project | Category | View Status | Date Submitted | Last Update |
| 0015549 | CMake | CMake | public | 2015-04-30 08:01 | 2016-06-10 14:31 |
| Reporter | Micha Renner | ||||
| Assigned To | Kitware Robot | ||||
| Priority | normal | Severity | minor | Reproducibility | always |
| Status | closed | Resolution | moved | ||
| Platform | Windows | OS | OS Version | ||
| Product Version | CMake 3.2.1 | ||||
| Target Version | Fixed in Version | ||||
| Summary | 0015549: GenerateExportHeader: The extern keyword and data symbols | ||||
| Description | It seems that the "extern" keyword is much more important than previously thought, at least for the MSVC in connection with static libraries. The example in the appendix demonstrates this. | ||||
| Steps To Reproduce | - build this project - run the program => wrong output - open the tlib_export.h file in the CMAKE_BINARY_DIR: - change: #ifdef TLIB_STATIC_DEFINE # define TLIB_EXPORT to #ifdef TLIB_STATIC_DEFINE # define TLIB_EXPORT extern - build the project again - run the program => correct results. | ||||
| Additional Information | May be one can change the GENERATE_EXPORT_HEADER macro to add the extern keyword automaticlly . (example is taken from the ffi library) | ||||
| Tags | No tags attached. | ||||
| Relationships | |||||
| Attached Files | https://public.kitware.com/Bug/file/5445/example.zip | ||||
| Issue History | |||||
| Date Modified | Username | Field | Change | ||
| 2015-04-30 08:01 | Micha Renner | New Issue | |||
| 2015-04-30 08:01 | Micha Renner | File Added: example.zip | |||
| 2015-04-30 09:50 | Brad King | Summary | The extern keyword => GenerateExportHeader: The extern keyword and data symbols | ||
| 2015-04-30 09:52 | Brad King | Note Added: 0038655 | |||
| 2016-06-10 14:29 | Kitware Robot | Note Added: 0042770 | |||
| 2016-06-10 14:29 | Kitware Robot | Status | new => resolved | ||
| 2016-06-10 14:29 | Kitware Robot | Resolution | open => moved | ||
| 2016-06-10 14:29 | Kitware Robot | Assigned To | => Kitware Robot | ||
| 2016-06-10 14:31 | Kitware Robot | Status | resolved => closed | ||
| Notes | |||||
|
|
|||||
|
|
||||
|
|
|||||
|
|
||||