[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [IMP-users] Windows build



On 3/21/13 3:52 PM, Tovchigrechko, Andrey wrote:
Would you have some pointers on the cross-compilation process, so
that I could do it at home? I would need to use a Windows build at
least for a year or so (to run it on MS Azure Windows instances).

Unfortunately I can't make the actual files available, since they include a copy of MSVS 2010 Express, but in essence I took a MSVS installation from a Windows machine and copied it to a Linux box, installed Wine (so strictly speaking it's not a cross compilation since we're using the real 'cl'), wrote a couple of shell scripts (e.g. /usr/bin/cl fires up the w32 cl.exe through wine, while /usr/bin/w32rc does the same thing for rc.exe), and provided cmake with a toolchain file that looks like:

SET(CMAKE_SYSTEM_NAME Windows)
SET(CMAKE_C_COMPILER cl)
SET(CMAKE_CXX_COMPILER cl)
SET(CMAKE_RC_COMPILER /usr/bin/w32rc)

SET(CMAKE_FIND_ROOT_PATH "/usr/lib/w32comp/Program Files/Microsoft Visual Studio 10.0/VC/" "/usr")
SET(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM BOTH)
SET(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY)
SET(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY)

I don't think it reasonable for everybody to do that though. ;) I'll take a look at making things work on a real Windows system.

Alternatively, I might be able to do away compiling and linking only
against the binary builds that you provide, although from the manual
it looks like a recommended way for creating e.g. a new restraint is
to generate a module within the IMP source tree. However, I noticed
that Windows nightly builds stopped back in January.

Yes, the builds had some trouble with the new RMF and the switch from scons to cmake. I actually just addressed the last few packaging problems a couple of days ago though, so these builds should start working again shortly.

	Ben
--
                      http://salilab.org/~ben/
"It is a capital mistake to theorize before one has data."
	- Sir Arthur Conan Doyle