Building with MSVC

Jef Driesen jefdriesen at telenet.be
Sat Dec 3 19:10:13 UTC 2011


On 12/03/2011 02:26 PM, Steve Boyd wrote:
> I am trying to build with Visual Studio 2010. I am getting the following error
> in libdivecomputer.rc.
>
> Error 1 error RC1015: cannot open include file 'revision.h'.
>
> If I comment out that line I then get a bunch of unresolved externals:
>
> Error 1 error LNK2001: unresolved external symbol cressi_edy_parser_create
> Error 2 error LNK2001: unresolved external symbol dc_version
> Error 3 error LNK2001: unresolved external symbol dc_version_check
> Error 4 error LNK2001: unresolved external symbol hw_ostc_parser_create
> Error 5 error LNK2001: unresolved external symbol mares_iconhd_device_open
> Error 6 error LNK2001: unresolved external symbol mares_iconhd_extract_dives
> Error 7 error LNK2001: unresolved external symbol mares_iconhd_parser_create
> Error 8 error LNK2001: unresolved external symbol zeagle_n2ition3_device_open
>
> Any help is appreciated.

The msvc project file hasn't been updated since a long time. All files that have 
been added since the last update, will have to added to the msvc project to fix 
the "unresolved external symbol" errors.

The "revision.h" error is caused because this file is automatically generated 
during the autotools build process. But this does not happen during the msvc 
project (because that was added after the last update to the msvc project). 
Since this file only contains a single line:

#define DC_VERSION_REVISION "$REVISION"

with $REVISION substituted with some value (the git SHA1, but an empty value 
will work too), the easiest workaround is to create this file by hand.

Jef




More information about the Devel mailing list