3 Building libical on Windows is a different process than building it on the other platforms: Instead of autogenerating makefiles using the autoconf/automake/make tools, Microsoft project files (.dsp) are used.
5 Here are the requirements and steps to build libical on the Win32 platform.
10 The following softwares need to be installed for a standard Windows build:
12 - Microsoft Visual C++ 6.0 or higher (only tested on 6.0 as of today).
14 - GNU Tools for Microsoft Windows (the cygwin toolkit).
15 cygwin is a UNIX-like environment for Windows, free from Red Hat. libical uses a few set of cygwin packages, which must be installed.
16 Go to http://www.cygwin.com and follow the installation instructions. The cygwin installer wizard runs as a Windows program. One page of the wizard presents an outline view of categories and packages. Here is a list of the cygwin packages needed for building libical:
17 . base --> ash : Unix-like command line interpreter shell.
18 . base --> grep: GNU grep, egrep and fgrep
19 . interpreters --> perl: A scripting language used to autogenerate some header files.
24 Visual C++ needs to be able to launch the cygwin tools. To do so, you can either:
25 - add the path to the cygwin tools (by default c:\cygwin\bin) to your global or user Path enviroment variable,
26 - or, in Visual C++ go to Tools --> Options --> Directories --> Show directories for Executable files and add the path to the cygwin tools (by default c:\cygwin\bin).
30 You need to build each subcomponent of libical one by one in the following order:
31 . src/libical/libical.dsp
32 . src/libicalss/libicalss.dsp
33 . src/libicalvcal/libicalvcal.dsp
37 libical comes with 2 regression test programs:
39 . src/test/regression.dsp
41 Building those and running them (from the command line or from VC++) is probably a good idea to check that your build is OK. The results are pretty much self explanatory.
42 Of course, running the regression tests becomes mandatory if you're planning on submitting a change.
47 By default, the library is created as a static library under src/libical/Debug/libical.lib (Debug version). You can also create a Release version which will be put under src/libical/Release/libical.lib.
49 The header file ical.h is autogenerated by the build process and should be located under src/libical/ical.h.
51 The library is created using the (Debug) Multithreaded DLL run-time library option. Be sure that you have the same setting in your application (Project --> Settings --> C/C++ --> Code Generation) or things will start to break.
52 The symptoms of this problem are link time errors like:
53 MSVCRTD.lib(MSVCRTD.dll) : error LNK2005: _malloc already defined in
54 LIBCMTD.lib(dbgheap.obj)
55 MSVCRTD.lib(MSVCRTD.dll) : error LNK2005: _free already defined in
56 LIBCMTD.lib(dbgheap.obj)
57 MSVCRTD.lib(MSVCRTD.dll) : error LNK2005: _strncmp already defined in
58 LIBCMTD.lib(strncmp.obj)
60 Alternatively, you can alter the libical .dsp files and recompile the library.