1 # Installing WRF on Cygwin
3 1. Download https://cygwin.com/setup-x86_64.exe
4 2. (Optional) Download https://cygwin.com/setup-x86_64.exe.sig and verify the signature
5 3. Run `setup-x86_64.exe`
6 - Select `Install from Internet`
7 - Pick an installation root (installing directly into `C:\` is not
9 - Pick a directory for a download cache
10 - If installing Cygwin on multiple computers, these files can
11 be re-used, skipping the download step on those computers
12 - `Direct Connection` is nice if it works, but `System Proxy Settings`
13 may fill in useful data from your OS.
14 - Select a mirror near you
15 - Change package view to `Full`
16 - Select for install at least:
17 - gcc-core (OpenMP for smpar)
19 - libnetcdf-fortran-devel
20 - openmpi (MPI for dmpar)
21 - libopenmpi-devel (MPI for dmpar)
22 - libjasper-devel (GRIB)
26 - Accept the packages pulled in as dependencies
27 - Wait for download, install, and postinstall steps. This will
28 take about an hour the first time through
29 - Decide whether you want shortcuts from the Desktop or Start Menu
31 - If you didn't install shortcuts, you can run the `Cygwin.bat`
32 file in the root of the Cygwin install tree
33 5. Follow usual instructions for installing WRF
34 - Download and unpack source
36 - Export variables so WRF can find everything:
37 - `export NETCDF=/usr/ NETCDF4=1 HDF5=/usr`
38 - (Optional) `export JASPER=/usr JASPERLIB=/usr/lib JASPERINC=/usr/include`
39 - (Optional) `export WRFIO_NCD_NO_LARGE_FILE_SUPPORT=0 NETCDF_classic=0`
40 - `./configure`, follow directions
41 - `./compile`, follow directions
45 If the compiler reports problems due to `mpi.mod` or `netcdf.mod`
46 being compiled with a different version of gfortran, subscribe to the
47 [cygwin mailing list](https://cygwin.com/lists.html) and send a
48 message there to remind the maintainer that `openmpi` or
49 `netcdf-fortran` was built with an old version of `gfortran` and to
50 ask them nicely to update it.
52 If the (volunteer) maintainer does not have time, or you want to build
53 this yourself, re-run `setup-x86_64.exe` and check the `Source?` box
54 next to `openmpi` or `libnetcdf-fortran-devel`, install `cygport` and
55 finish the install. Unpack the archives in `/usr/src` (`tar xaf ...`
56 should do the trick), and `cd` into the new directory. There will be
57 a `.cygport` file with the build script. Edit this to add a `.1`
58 after the current release field. Save this file, then run
59 `cygport ${package}.cygport download prep compile test install package`
60 If there are errors, try to fix them, then re-run
61 `cygport ${package}.cygport compile test install package`
62 Once it compiles, you can follow the directions in
63 https://cygwin.com/package-server.html#overlay
64 to set up a local package server and install from that, or you can run
67 for name in /usr/src/${package}-${version}*/${package}-${version}*/dist/**.tar.xz;
72 then re-run setup to make sure everything still works.
73 The first method plays much nicer with other tools.
75 If you feel nice, you can tell the maintainer whether the package
76 compiled, whether the tests passed and what you needed to do to make
77 it do that. The contents of
78 `/usr/src/${package}-${version}*/${package}-${version}*/patch` might