Hello! First of all, a side note:
Jason Heeris wrote > (Not shown: the macros to create the declspec declaration that MSVC needs > to know what to export in the DLL. It's a type in moduleN and some > functions in common.) Do you create declspec declaration by hand? It may worth looking at the GenerateExportHeader <https://cmake.org/cmake/help/v3.7/module/GenerateExportHeader.html> CMake module that provides the function generate_export_header(). If you need to generate some additional macros you can use CUSTOM_CONTENT_FROM_VARIABLE argument that is supported since CMake 3.7. Now, let me clarify something: Jason Heeris wrote > This is already possible with existing build scripts, but these are > becoming unmaintainable. The existing scripts compile each individual > module into an .obj file and finally link them all into a DLL, as in: > > cl.exe [args] common\common.c (creates common.obj) > cl.exe [args] modules\module1\module1.c (creates module1.obj) > ... > cl.exe [args] modules\moduleN\ moduleN.c (creates moduleN.obj) > > link.exe [args] common.obj module1.obj [...] moduleN.obj (creates > moduleN.dll) Is it the code that you use in your CMake build script or just a representation of the general idea? Best regards, Innokentiy Alaytsev -- Sent from: http://cmake.3232098.n2.nabble.com/ -- Powered by www.kitware.com Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Kitware offers various services to support the CMake community. For more information on each offering, please visit: CMake Support: http://cmake.org/cmake/help/support.html CMake Consulting: http://cmake.org/cmake/help/consulting.html CMake Training Courses: http://cmake.org/cmake/help/training.html Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Follow this link to subscribe/unsubscribe: https://cmake.org/mailman/listinfo/cmake