Choosing Your Programming Environment

Steven Zeil

Last modified: Jan 7, 2024
Contents:

You are going to be doing a lot of C++ programming in this course.

Now is the time, before you actually get involved with the details of an assignment, to decide how you are going to do that and to get everything set up that you need.

This is also a good time to review material from CS252 that you may have skipped over, forgotten, or, if you took CS252 many semester ago or have transfer credit for a CS252 “equivalent” from elsewhere, may never have seen:

1 What You Need

You will need an environment that includes

Most students entering this course will have used Code::Blocks in earlier C++ courses. Code::Blocks is a fine IDE for beginners, but Code::Blocks will not be sufficient in this course.

2 Where Do You Want to Work?

When it comes to planning the development environment that you want to run from your own PC, you have choices.

There are three major styles of development environment to consider.

2.1 Local Development

Having the IDE and all of the development environment components on your own PC is called local development.

Advantages:

Disadvantages:

2.2 Remote Display

In remote display development, we run the IDE (Eclipse), compiler, & debugger on a remote machine (e.g. the CS Linux servers) and have the results displayed on our local PC’s screen.

Advantages:

Disadvantages:

This mode of development was a major theme of CS252, so you should already be prepared to work this way.

2.3 Remote Development

Remote development strikes a middle point between the extremes of running everything on your PC or running everything on the remote machine.

The compiler and debugger are run on the remote machine and do not need to be installed on your own PC.

The IDE (VSCode), however, is installed and run on your own PC. It communicates with the remote machine via a combination of SSH and SFTP to show you your files on the remote machine, to let you edit them, and to issue commands to the compiler and debugger on the remote machine.

Advantages:

Disadvantages:

This mode of development is also covered in CS252, so you should already be prepared to work this way.

3 My Recommendations…

The ordering of my recommendations is based on the fact that a significant number of students seem to have slow Internet connections that make remote viewing frustrating. Some students have PCs with underpowered CPUs that make local development slow.

So I recommend trying the remote development option first.

Then, if you decide you would prefer to local development, you can still use VSCode as your IDE but just add the compiler and related tools on your PC. You can even switch back and forth between remote and local modes, provided that you transfer your source code first. (Using git makes that natural: get in the habit of pulling at the start of each work session, and committing and pushing at the end of the work session.)

3.1 …for Students with Windows PCs

For this course, my recommended choices for students with Windows PCs are:

  1. Remote Development
  2. Local Development (Windows & Linux)
    • Windows Subsystem for Linux (WSL) is a Linux virtual machine that runs, pretty much seamlessly, on a Windows 10 machine.
    • Toolset: Linux g++, gdb, java, javac, make, git in WSL
    • IDE: VSCode (in Windows)
      • Installation instructions are here.
  3. Remote Viewing
    • X2Go
      • Installation instructions are here.
    • Toolset: already on the remote Linux servers
    • IDE: Eclipse

3.2 …for Students with macOS PCs

My recommendations for students with macOS PCs are

  1. Remote Development
  2. Local Development
    • Toolset: clang c++, ilb, make, javac, java, git, coreutils
    • IDE: VSCode
      • Installation instructions are here
  3. Remote Viewing
    • X2Go
      • Installation instructions are here.
    • Toolset: already on the remote Linux servers
    • IDE: Eclipse