From 65a5a33c22ca6b68c7b500cbe3829a8dacb4f6df Mon Sep 17 00:00:00 2001 From: Sam Ellicott Date: Fri, 4 Jun 2021 22:14:13 -0400 Subject: [PATCH] Slight update to the build instructions --- README.md | 45 +++++++++++++++++++++++---------------------- 1 file changed, 23 insertions(+), 22 deletions(-) diff --git a/README.md b/README.md index 9587b81..35636b5 100644 --- a/README.md +++ b/README.md @@ -14,9 +14,9 @@ Table of Contents - [Building ColorChord Embedded](#building-colorchord-embedded) - [Building with Linux](#building-with-linux) - [Building with Windows](#building-with-windows) - - [MSYS2](#msys2) - [clang](#clang) - [TCC](#tcc) + - [MSYS2](#msys2) - [Using](#using) - [Additional Videos](#additional-videos) @@ -99,7 +99,28 @@ make Building with Windows ------------------- -There are 3 options available for building on Windows, MSYS2, clang, or TCC. +There are 3 options available for building on Windows, clang, or TCC, MSYS2. +### clang +Start by [downloading](https://clang.llvm.org/) the clang compiler, and installing it. + +Edit the batch script at `colorchord1/windows/compile-clang.bat`: +- Verify that the executable location is correct, on line 0 (`CC`). + +If you have the Windows SDK installed, you should not need to do any additional work. +If you do not, you'll want to either [install it](https://developer.microsoft.com/en-US/windows/downloads/windows-11-sdk/) to get the official headers, or use the unofficial headers instead by adding `-DNO_WIN_HEADERS` to the `CCFLAGS` line in the batch file above. + +Run the batch script, and it should output to `colorchord2/colorchord.exe`. + +### TCC +Start by [downloading TCC](http://savannah.nongnu.org/projects/tinycc/), and extracting it to `C:\tcc`. +You can put it anywhere you like, but the compile script defaults to this location. If you install +to the default location, you can skip the next step. + +Edit the batch script at `colorchord2/windows/compile.bat`: +- Edit line 17 (`CC`) to be the location where you put TCC. If there are spaces in the path, wrap the entire path in quotes. + +Note that TCC is not able to use the Windows SDK, and as such using the unofficial headers is required, and automatically enabled when compiling with TCC. If you encounter issues, try the clang method above instead. + ### MSYS2 With either 64bit or 32bit [MSYS2](https://msys2.github.io/) installed, run the _MSYS2 MSYS_ launcher and use `pacman` to set up a MinGW32 toolchain, if you don't have one already: ``` @@ -114,26 +135,6 @@ To make colorchord, navigate to your working copy and type: mingw32-make colorchord.exe ``` -### clang -Start by [downloading](https://clang.llvm.org/) the clang compiler, and installing it. - -Edit the batch script at `colorchord2/windows/compile-clang.bat`: -- Verify that the executable location is correct, on line 1 (`CC`). - -If you have the Windows SDK installed, you should not need to do any additional work. -If you do not, you'll want to either [install it](https://developer.microsoft.com/en-US/windows/downloads/windows-10-sdk/) to get the official headers, or use the unofficial headers instead by adding `-DNO_WIN_HEADERS` to the `CCFLAGS` line in the batch file above. - -Run the batch script, and it should output to `colorchord2/colorchord.exe`. - -### TCC -Start by [downloading TCC](http://savannah.nongnu.org/projects/tinycc/), and extracting it to a location of your choice. - -Edit the batch script at `colorchord2/windows/compile.bat`: -- Edit line 17 (`CC`) to be the location where you put TCC. If there are spaces in the path, wrap the entire path in quotes. - -Note that TCC is not able to use the Windows SDK, and as such using the unofficial headers is required, and automatically enabled when compiling with TCC. If you encounter issues, try the clang method above instead. - - Using -----