[CMake] Win: Dependency for def file missing
Martin Apel
martin.apel at simpack.de
Tue Dec 9 10:35:11 EST 2008
Bill Hoffman wrote:
> Martin Apel wrote:
>> Hi all,
>>
>> I am generating a DLL under Windows using a def file. The def file
>> itself is generated. It seems that CMake (2.6.3rc5) does not generate a
>> dependency between the generated def file and the DLL. When I change the
>> input, from which the def file is generated, the def file is rebuilt,
>> but not the DLL itself. The code looks as follows:
>>
>> SET(DefFile ${CMAKE_CURRENT_BINARY_DIR}/FortranInterface.def)
>> ADD_CUSTOM_COMMAND(OUTPUT ${DefFile}
>> COMMAND ${PERL_EXECUTABLE}
>> ${CMAKE_SOURCE_DIR}/scripts/create_dll_exports_file.pl
>> --export-file=${DefFile} --so-name=FortranInterface
>>
>> ${CMAKE_CURRENT_SOURCE_DIR}/FortranInterfaceExport.txt
>> DEPENDS
>> ${CMAKE_CURRENT_SOURCE_DIR}/FortranInterfaceExport.txt
>> )
>>
>> ADD_LIBRARY(FortranInterface SHARED ${DefFile} ${FortranSrc})
>> TARGET_LINK_LIBRARIES(FortranInterface ${MY_LIBS})
>> SET_TARGET_PROPERTIES(FortranInterface PROPERTIES
>> LINK_INTERFACE_LIBRARIES "")
>>
>> SET_SOURCE_FILES_PROPERTIES(${DefFile} PROPERTIES GENERATED 1)
>>
>> To me this looks like a bug in CMake. Can somebody confirm, that this is
>> a bug or am I doing something wrong?
>>
> What version of VS are you using? Also, nmake or VS IDE?
>
Hi Bill and all the rest,
sorry, I forgot to state this: VS version is 2005 and I am using nmake.
Best Regards,
Martin
--
Martin Apel Tel: 0049 8153 9288-47
Software Architect E-Mail: martin.apel at simpack.de
INTEC GmbH Tel: 0049 8153 9288-0
Argelsrieder Feld 13 Fax: 0049 8153 9288-11
82234 Wessling E-Mail: intec at simpack.de
Germany URL: http://www.simpack.com
____________
Virus checked by G DATA AntiVirus
Version: AVF 19.178 from 08.12.2008
More information about the CMake
mailing list