@@ -129,19 +129,29 @@ GitHub pages serves up https://raytracing.github.io/.
129
129
130
130
Building and Running
131
131
---------------------
132
- Copies of the source are provided for you to check your work and compare against. If you wish to build
133
- the provided source, this project uses CMake. To build, go to the root of the project directory and
134
- run the following commands to create the debug version of every executable:
132
+ Copies of the source are provided for you to check your work and compare against. If you wish to
133
+ build the provided source, this project uses CMake. To build, go to the root of the project
134
+ directory and run the following commands to create the debug version of every executable:
135
135
136
136
$ cmake -B build
137
137
$ cmake --build build
138
138
139
+ You should run ` cmake -B build ` whenever you change your project ` CMakeLists.txt ` file (like when
140
+ adding a new source file).
141
+
139
142
You can specify the target with the ` --target <program> ` option, where the program may be
140
143
` inOneWeekend ` , ` theNextWeek ` , ` theRestOfYourLife ` , or any of the demonstration programs. By default
141
144
(with no ` --target ` option), CMake will build all targets.
142
145
143
- On Windows, you can build either ` debug ` (the default) or ` release ` (the optimized version). To
144
- specify this, use the ` --config <debug|release> ` option.
146
+ $ cmake --build build --target inOneWeekend
147
+
148
+ You can build either ` debug ` (the default) or ` release ` (the optimized version). To specify this,
149
+ use the ` --config <debug|release> ` option.
150
+
151
+ $ cmake --build build --config release
152
+
153
+ We recommend building and running the ` release ` version (especially before the final render) for
154
+ fastest results, unless you need extra debugging information of the (default) debug build.
145
155
146
156
### CMake GUI on Windows
147
157
You may choose to use the CMake GUI when building on windows.
0 commit comments