I didn't understand why the visual studio target used the target's AddExplicitObjectName so that the visual studio global class could use it. It seems roundabout.
The Green Hills MULTI IDE has a few different quirks from visual studio. 1. It counts the extension as a difference in the filename 2. It ignores the '/' Attached is a patch that handles duplicate filenames by prepending collided filepaths with the absolute paths. The full path uses '_' instead of ":/" and '/', since MULTI ignores that. There's also a test that should work with the other generators. Geoff -----Original Message----- From: Brad King [mailto:brad.k...@kitware.com] Sent: Monday, April 18, 2016 9:28 AM To: Geoffrey Viola <geoffrey.vi...@asirobots.com> Cc: cmake-developers@cmake.org Subject: Re: [cmake-developers] 0016046: GHS Multi Generator: duplicate object file names On 04/17/2016 04:22 PM, Geoffrey Viola wrote: > Attached is a patch to fix the bug tracked at > https://cmake.org/Bug/view.php?id=16046. > It adds a special source property to set the obj filename for the GHS MULTI > generator. > It is necessary, because GHS MULTI has a bug where it can't compile > two source files with the same filenames. Thanks. However, I do not think it should be the project's responsibility to set the OBJECT_FILE property for this. CMake's VS IDE generator has the same problem so we generate specific object file names automatically when the defaults will not be unique. See logic here: cmLocalVisualStudioGenerator::ComputeObjectFilenames https://cmake.org/gitweb?p=cmake.git;a=blob;f=Source/cmLocalVisualStudioGenerator.cxx;hb=v3.5.2#l41 and use of AddExplicitObjectName in particular. -Brad This message contains confidential information and is intended only for the recipient. If you are not the named addressee you should not disseminate, distribute or copy this e-mail. Please notify the sender immediately if you have received this e-mail by mistake and delete this e-mail from your system. Finally, the recipient should check this email and any attachments for the presence of viruses. The company accepts no liability for any damage caused by any virus transmitted by this email.
0001-Green-Hills-MULTI-handles-duplicate-source-filenames.patch
Description: 0001-Green-Hills-MULTI-handles-duplicate-source-filenames.patch
-- 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: http://public.kitware.com/mailman/listinfo/cmake-developers