[CMake] how to use CMAKE_LINK_DEF_FILE_FLAG
Cees Wesseling
cwesseling at esri.com
Thu Oct 25 12:35:57 EDT 2007
I am trying to build a C++ Windows dll that must use a linker definition
file with the exports using cmake version 2.4-patch 7 for Visual Studio
2005 in nmake Makefile mode.
What I have tried is the following bare CMakeLists.txt:
SET (CMAKE_LINK_DEF_FILE_FLAG "/DEF:dll.def")
ADD_LIBRARY(Test
SHARED
InProcServer.cc
)
The dll builds fine, but has no entry points. In the resulting Makefile
I do not find any mentioning of the DEF linker flag. And from inspecting
Modules/Platform/Windows-cl.cmake of the cmake distro I am getting
suspicious if the CMAKE_LINK_DEF_FILE_FLAG is ever rolled into the link
options.
Am I overlooking something obvious? Is there another way to push this
flag into the link options?
Thanks, Cees
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://public.kitware.com/pipermail/cmake/attachments/20071025/4881d3d8/attachment.htm
More information about the CMake
mailing list