Using SeeC on Windows

This page describes some extra steps needed to use SeeC on Windows.


Install MSYS2 and MinGW-w64

SeeC requires some other tools and header files in order to compile your C programs. For Windows, we recommend using MSYS2 to install these files. The MSYS2 website contains an installer and instructions for setting up the basic msys2 environment.

After MSYS2 is installed according to the instructions, open the MSYS2 shell. Run the following command to install the development tools and header files that we need:

pacman -S mingw-w64-x86_64-toolchain

Install Graphviz

SeeC uses Graphviz to produce graph layouts of program memory. You can download Graphviz for Windows here.

Set SeeC preferences

After you have installed MinGW-w64 and Graphviz, we can set their location in SeeC's preferences menu.

  1. Open SeeC from the start menu (the SeeC Trace Viewer welcome window should appear)
  2. Go to the Edit menu, then select Preferences.
  3. Click on Graph in the left-hand menu, then set the location of Graphviz's dot.exe file. If you installed Graphviz to C:\graphviz, then the location of this file will be C:\graphviz\bin\dot.exe
  4. Click on Compiler in the left-hand menu, then set the location of MinGW-w64's gcc.exe file. If you installed MSYS2 to C:\msys64, then the location of this file should be C:\msys64\mingw64\bin\gcc.exe
  5. Close SeeC and re-open it. Everything should be ready to go!

Using SeeC on the command line

The above steps are sufficient to use SeeC's trace viewer. If you edit a source code file with SeeC's trace viewer, you can also compile and run programs (from the Project menu). However, you may want to use seec-cc directly from the Windows Command Prompt. To do that, you must set the PATH environment variable so that Command Prompt knows where to find seec-cc, and so that seec-cc knows where to find MinGW-w64. If you have installed these in the default locations, you can do this by entering the following command into Command Prompt:

set PATH=C:\msys64\mingw64\bin;C:\Program Files (x86)\SeeC\SeeC\bin;%PATH%

If you are doing this often it can be a chore to set the PATH environment variable repeatedly. One approach to mitigate this is to create a batch (.bat) file that will set the PATH for you and leave the Command Prompt open. You can do this by creating a file with the bat extension and the following contents:

cmd /k set PATH=C:\msys64\mingw64\bin;C:\Program Files (x86)\SeeC\SeeC\bin;%PATH%

When you run this file (e.g. by double-clicking it within Windows' GUI), it will open a Command Prompt and set the PATH appropriately, after which you can use seec-cc as you would on any other platform.