[CMake] Undefined symbol _MAIN_ in shared library creation
Mario Rodríguez
shiv4k at gmail.com
Thu Oct 14 12:28:09 EDT 2010
Hi,
I`m having this linking error compiling a Fortran project on a Visual studio
2008 solution with cmake 2.8.2. The project contains several files, but w/o
any entry point... only a bunch of subroutines packed on a library...
----------------
/OUT:......dll
/VERSION:2.0
/LIBPATH:...
/LIBPATH:....
/MANIFEST
/MANIFESTFILE:.....manifest
/SUBSYSTEM:CONSOLE
/IMPLIB:........lib
----------------------------
4>libifcoremd.lib(for_main.obj) : error LNK2019: símbolo externo _MAIN__ sin
resolver al que se hace referencia en la función _main
My ifort configuration:
Intel(R) Visual Fortran Compiler Professional for applications running on
IA-32, Version 11.1 Build 20100806 Package ID: w_cprof_p_11.1.067
My library doesn`t need a main or program entry point, but cmake seems to
not create it like a "Fortran dynamic-link library"... or msvc++ -> Intel
compiler project converter is doing it wrong. My questions are:
1) How to automatize the conversion from msvc++ project to Intel compiler
only running cmake (C++)?
2) How to "say" cmake that I want a "Fortran dynamic-link library"? In c++
projects this works fine!
Thanks in advance!
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.cmake.org/pipermail/cmake/attachments/20101014/477936e9/attachment.htm>
More information about the CMake
mailing list