Chapter 34 make
: special considerations for Windows
2015-11-17 NOTE: This year we made R packages before we used make
The hope is, therefore, that the make
that ships with Rtools is all we need. So hopefully we can ignore this?
34.1 Install make
on Microsoft Windows
We are still working out the best way to install make
on Windows. Our current best recommendation is to install msysGit, which includes make
as well as git
and bash
.
Download and install msysGit. The two software packages msysGit and Git for Windows are related. Both install git
and bash
, but only msysGit installs make
. The programs installed by msysGit are found by default in C:\msysGit\bin
. Here is the complete list of programs included with msysGit. For this activity, RStudio needs to be able to find in your PATH
environment variable the program make
, the shell bash
, other utilities like rm
and cp
, and Rscript
.
Here is another alternative for installing make
alone:
- Go to the Make for Windows web site.
- Download the Setup program.
- Install the file you just downloaded and copy to your clipboard the directory in which it is being installed.
- FYI: The default directory is
C:\Program Files (x86)\GnuWin32\
- FYI: The default directory is
- You now have
make
installed, but you need to tell Windows where to find the program. This is called updating yourPATH
. You will want to update thePATH
to include thebin
directory of the newly installed program.
34.2 Update your PATH
If you installed Make for Windows (as opposed to the make
that comes with Git for Windows), you still need to update your PATH
.
These are the steps on Windows 7 (we don’t have such a write-up yet for Windows 8 – feel free to send one!):
- Click on the Windows logo.
- Right click on Computer.
- Select Properties.
- Select Advanced System Settings.
- Select Environment variables.
- Select the line that has the
PATH
variable. You may have to scroll down to find it. - Select Edit.
- Go to the end of the line and add a semicolon
;
, followed by the path where the program was installed, followed by\bin
.- Typical example of what one might add:
;C:\Program Files (x86)\GnuWin32\bin
- Typical example of what one might add:
- Click Okay and close all the windows that you opened.
- Quit RStudio and open it again.
- You should now be able to use
make
from RStudio and the command line.
34.3 Issues we are still clarifying
See issue 58 for what seems to be the most comprehensive statement of the Windows situation.
What are the tricky bits?