XuvTools is developed in a cooperative effort from:
  • Chair of Pattern Recognition and Image Processing [www]
  • Friedrich Miescher Institute for Biomedical Research [www]
  • Center for Biological Systems Analysis [www]
 

Compiling XuvTools Sources on Windows

Prerequisites

  • Visual Studio:
  • Cygwin:
    • An installation of Cygwin is required in order to run the build scripts. There are also certain package requirements for Cygwin:
    • required Cygwin packages: coreutils bash grep sed tar bzip2 gzip unzip make findutils wget
    • recommended Cygwin packages: subversion perl rxvt
    • disallowed Cygwin packages: cmake qt3 qt3-devel-tools qt4 qt4-devel-tools
  • A subversion client:
    • Any subversion client should do, and you can absolutely use the client that comes with Cygwin (see above). However, if you plan to commit often, we recommend using a nicer SVN client like SmartSVN.

Testing your Build Environment

This step is still in an early stage. While the automatic testing can already help find several issues, it is not able to detect all possible problems.

To test if you should have a working Build environment, you can use the script xuvprepare.sh. The script will inspect your setup and warn about problems and errors. Here is a sample run on Cygwin:

emmenlau@fattie /m/emmenlau/XuvTools/trunk/xuvtools/scripts
$ ./xuvprepare.sh --verbose
[xuvprepare.sh]: Detected cygwin environment.
[xuvprepare.sh]: Passed all cygwin-related checks.

Sources, Directory Layout and Environment

Directory Layout

The next steps should be getting the sources and installing them in the correct directories. It is highly recommended to stick to the following directory layout, where USER is the username of the active Windows user (Call 'whoami' on Cygwin to find your user name).

Sources: "D:\Data\${USER}\XuvTools\trunk\"
Binaries: "D:\Data\${USER}\lmbsoft\"

If you can't use this directory layout or drive letters, please check the script “XuvTools/trunk/xuvtools/scripts/env-lmb.sh” to reflect your directory layout.

Getting the Sources

You can now check out the sources from the LMB Freiburg Subversion server. For getting the sources, you need to have an Subversion account, which you can request from admin@xuvtools.org. Please make sure you check out the sources in the Sources directory set above.

Subversion Server: svn://tim.informatik.uni-freiburg.de/lmbsoft/trunk
User Name: <The user name you have received via email>
Password: <The password you have received via email>
Path Variable

XuvTools brings its own Ant, Cmake, and Boost. Some users had problems because their PATH variable contained paths to Windows installations of Perl, Subversion, Ant, Cmake, Make and Boost other than the ones from Cygwin or XuvTools.

Starting a Compile

To enter the new build environment, you first have to start a Cygwin terminal, and then setup the corresponding variables. Starting a Cygwin Shell can be done directly from the XuvTools sources. There are four shortcuts for starting Cygwin shells in the directory “XuvTools\trunk\xuvtools\scripts\”.

Starting the Terminal
rxvt-x Intel32 BuildEnv.lnk             - For Intel Compiler 32bit environment
rxvt-x Intel64 BuildEnv.lnk             - For Intel Compiler 64bit environment
rxvt-x MinGW64 BuildEnv.lnk             - (Currently unusable) MinGW test shell
rxvt-x VisualStudio2008 32 BuildEnv.lnk - For Microsoft Visual Studio 2008 32bit environment
rxvt-x VisualStudio2008 64 BuildEnv.lnk - For Microsoft Visual Studio 2008 64bit environment
rxvt-x VisualStudio2010 32 BuildEnv.lnk - For Microsoft Visual Studio 2010 32bit environment
rxvt-x VisualStudio2010 64 BuildEnv.lnk - For Microsoft Visual Studio 2010 64bit environment
Setting the environment Variables

Once you have started the Terminal via one of the above shortcuts, a new shell window should open. You can now set the environment variables for this shell by sourcing the environment script:

source XuvTools/trunk/xuvtools/scripts/env-lmb.sh
Starting the XuvTools Compile

Finally, you can now use the “xuvbuild.sh” script to compile the sources. When compiling the sources for the first time, you need to use the parameter “–qmake” to generate the Visual Studio Project files. For a first run it also recommended to use the parameter “–genfirst”. Compiling the thirdparty prerequisites is required only the first time (or whenever there are updates). Thirdparty compilation is activated with the “–thirdparty” switch. Here is a sample run for compiling the first time:

emmenlau@fattie#> xuvbuild.sh --help
usage: xuvbuild.sh
        [--verbose|-v]                        -  be more verbose (default=0)
        [--qmake|-q]                          -  reconfigure (run qmake) first (default=no)
        [--thirdparty|-t]                     -  extract thirdparty libs (default=no)
        [--nobuild|-nb]                       -  do not build solution (default=build)
        [--rebuild|-c]                        -  rebuild solution (default=no)
        [--debug|-d]                          -  build debug configuration (default=no)
        [--release|-r]                        -  build release configuration (default=yes)
        [--cleantree]                         -  clean temporary and destination build-dirs-tree (default=no)
        [--cleanproj]                         -  clean up VisualStudio project-/solution-files (default=no)
        [--genfirst]                          -  first generate all genXXX-targets (default=no)
        [--intel|-i]                          -  use Intel compiler (default=autodetect)
        [--nointel|-ni]                       -  dont use Intel compiler (default=autodetect)
        [--showbuild|-sb]                     -  show BuildLog in an extra rxvt terminal

emmenlau@fattie#> xuvbuild.sh --verbose --qmake --tools --thirdparty

Here is a sample run for compiling all future times:

emmenlau@fattie#> xuvbuild.sh --verbose

XuvTools Releases

XuvTools releases are packaged with the freeware software “Advanced Installer” (from http://www.advancedinstaller.com/). We provide shell scripts to package the XuvTools release automatically, and include the Java runtime environment and other dependencies.

Packaging a XuvTools Release

Depending on the platform, you can use one of currently three packaging scripts: xuvpackage-win.sh, xuvpackage-mac.sh or xuvpackage-lin.sh. Here we demonstrate xuvpackage-win.sh:

emmenlau@fattie#> xuvpackage-win.sh --verbose --version=<versionnr>

This will create a new packaged release in your XuvTools/trunk/releases/ directory.

Putting it all together - a new XuvTools Release

Here is the full, non-beautified truth on what shell invocations had to be done to create the XuvTools 1.8.0-beta11 download.

# On Windows, we have to open the correct shell for the compiler we want
source /d/Data/emmenlau/XuvTools/trunk/xuvtools/scripts/env-lmb.sh
xuvbuild.sh --qmake --verbose --tools --thirdparty --version="1.8.0.11"
# package the new release
xuvpackage-win.sh --verbose --version="1.8.0" --beta="11"
# upload it for the Download page to catch up
rsync --verbose --progress $LMBSOFTSRC/releases/XuvStitch-1.8.0-beta11-* aldebaran:/home/www/org.xuvtools/pages/data/releases/
devel/compile-win-xuvbuild.txt · Last modified: 2010/10/14 20:38 by mario
Contact: admin(a)xuvtools.org