*** empty log message ***
[charm.git] / README.win32
blobd764cc6d61ff81173ee37a5e559812ae68e7b38c
2                           Charm++ for Win32
4        Copyright (C) 1989-2004 Regents of the University of Illinois
6 You can compile charm++ under Windows9x/2000/NT with VC++ plus Cygwin.
7 Cygwin are ports of the popular GNU development tools and utilities for 
8 Windows 9x/2K and NT, which emulates a UNIX environment under Windows.
10 Note that since November 2005, Windows98 is not supported with VC++.
11 Support for WindowsNT/XP is improved to take advantage of the creation of
12 symbolic link under WindowsNT.
13 Please read the FAQ at end of this file.
16                        Setup and Compilation
17                     ===========================
19 To compile charm with VC++:
20 1. install cygwin from: http://sourceware.cygnus.com/cygwin
21    Remember to choose default file type as "unix" at the beginning of 
22    cygwin installation.
24 2. Start a Cygwin's Bash Shell window, type "cl" to make sure VC++ compiler 
25    command line mode is correctly set. If it is not correctly set, you need to 
26    run the VCVARS32.BAT at Windows startup time. VCVARS32.BAT can be located in
27    your VC++ install directory, usually at: 
28    /Program Files/Microsoft Visual Studio/VC98/Bin
29    However VCVARS32.BAT(a DOS Batch) cannot be executed under Bash Shell 
30    , you have to: for Win8x, put it into AUTOEXEC.BAT; for WinNT, 
31    you have to merge call VCVARS32.BAT in cygwin.bat which is the target of the
32    Cygwin icon on desktop. Note that this dos batch is renamed to 
33    vcvarsall.bat for VC++ version 8.
34    For example, if cygwin is installed under c:\cygwin,
35    modify c:\cygwin\cygwin.bat to something like:
37    >>>>>>>>>>>>>>>>>>>
38    @echo off
40    call "C:\Program Files\Microsoft Visual Studio 8\VC\vcvarsall" x86
42    C:
43    chdir D:\cygwin\bin
45    bash --login -i
46    >>>>>>>>>>>>>>>>>>>>
48 3. This step is optional if you have installed Microsoft Visual Studio under 
49    the following (default) location: 
50      /Program Files/Microsoft Visual Studio 8\VC
51    In case it is not at this directory, edit the following (text) files to 
52    modify them to point to your visual studio c++ compiler directory:
53     src\arch\win32\unix2nt_ar
54     src\arch\win32\unix2nt_cc  
56 4. Now you can compile Charm++ like Unix, for example:
58    ./build charm++ net-win32
60    this will build all Charm++ executables under net-win32/bin and all libs
61    under net-win32/lib
65                      Compile and Run Charm++ Programs
66                   ======================================
68 1. After Charm++ compilation is complete, you can try some sample programs under
69    net-win32\pgms. For example, 
70    cd net-win32/pgms/charm++/megatest, and type "make",
71    it will invoke Charm++'s "charmc"(VC++ wrapper) to compile the test 
72    programs and generates an executable "pgm.exe" and a charm++'s parallel
73    run utility program - "charmrun.exe".
74    Now you have two choices of running the executable:
75    (1) locally on your desktop, using:
76        ./charmrun +p1 ./pgm ++local
77        this will fork one copy of node program on your local machine. You can 
78        choose using more than one virtual processors, e.g. using +p3  option.
79        Starting from Charm 5.4R2, You can also run, simply type executable and 
80        command line options:
81        ./pgm 
82        This will run only one copy of program locally.
84    (2) run in parallel across machines:
85        In this case, you need to write a .nodelist file under your home
86        directory(~) in bash terminal, here is an example:
88 group main
89 host hostname1
90 host hostname2 
92        Next, you need to start charmd.exe, which is under net-win32/bin on
93        all the nodes as listed in the .nodelist file.
94        Now run the Charm++ program, for example:
95        ./charmrun +p2 ./pgm
98    For details of Charm++ compilation options and charmrun comman line options
99 explanation, please check the manuals on charm.cs.uiuc.edu web site manual 
100 section.
101    If you have any problem or suggestion, please let me know by sending
102 email to (ppl@cs.uiuc.edu).
106                                     FAQ
107                               ==============
110  1. I don't like Cygwin, can I compile Charm++ without Cygwin?
112    Yes, there is an un-documented way to compile Charm++ under MS-DOS windows 
113    with VC++ and nmake. However, this is only occasionally maintained and not 
114    guarranteed to always work.
115    Follow this steps:
116    1 open a MS-DOS windows, cd to Charm++ directory, and mkdir net-win32\tmp;
117    2 cd to net-win32\tmp, copy Makefile.win32 from 
118      charm\src\Common\scripts\Makefile.win32 to current directory;
119    3 type: nmake /f Makefile.win32
120    4 To compile Charm++ programs, see the Makefile.win32 examples under
121      net-win32\pgms\charm++\megatest\Makefile.win32
122      The command to use is: nmake /f Makefile.win32
123      Basically you need to specify all the charm++ libraries to link against,
124      because shell script charmc is not available,
126  2. I just downloaded Charm++ net-win32 binaries from your website, how to use it?
128    The recommended way to run windows binary is under Cygwin.
129    First, unzip the binary packages to desired location; Set PATH environment
130    varaible to include the charm bin/ directory. That's it, you can now cd 
131    to Charm++ testsuite directory, for example: pgms/charm++/megatest, to 
132    compile your first Charm++ program using "make".
133    If you don't want to use Cygwin, you have to use "nmake" to compile Charm++
134    programs, see the Makefile example under: 
135    pgms/charm++/megatest/Makefile.win32.
137  3. How to compile under Windows98?
139    Compiling Charm++ with cygwin/gnu compiler (net-cygwin) under Windows98 
140    is still supported. However, we don't support VC++ with Windows98 any more.
141    To compile Charm++ under Windows98, one can check out Charm++ version
142    before November 2005.