http://bugs.winehq.org/show_bug.cgi?id=22286
--- Comment #12 from John M. Drescher drescherjm@gmail.com 2010-04-06 11:38:19 --- I just tried the example from the first post from a samba share under windows using the same cmake files and it worked as expected for the samba share.
[u:]c:TestSambaShortFileNames.exe U:\jdrescher\TestSambaShort\CMakeTestFortranCompiler.cmake U:\jdrescher\TestSambaShort\CMakeTestFortranCompiler.cmake
[u:]c:TestSambaShortFileNames.exe U:\jdrescher\TestSambaShort\CMakeTestCXXCompiler.cmake U:\jdrescher\TestSambaShort\CMakeTestCXXCompiler.cmake
[u:]c:TestSambaShortFileNames.exe U:\jdrescher\TestSambaShort\CMakeTestForFreeVC.cxx U:\jdrescher\TestSambaShort\CMakeTestForFreeVC.cxx
It looks like samba is doing the correct thing. However they may be storing the short filenames somewhere or I may just be lucky not to hit the hash collision.