mirror of
https://github.com/mruby/mruby
synced 2026-06-08 16:11:16 +00:00
Add CMake Xcode build notes
+10
-5
@@ -21,10 +21,11 @@ toolchain they're most productive with.
|
||||
|
||||
**Prerequisites:**
|
||||
* CMake 2.8.8, Bison, and a build toolchain on `PATH`
|
||||
* CMake configuration and command line builds must be performed _outside_ the project root
|
||||
directory, e.g - the `build` subirectory. If you mistakenly ran `cmake` in the root
|
||||
dir, delete the generated `CMakeFiles/` directory and `CMakeCache.txt` file, `cd` to
|
||||
another dir (hint: the included `build` subdir), and run `cmake` again.
|
||||
* Except when generating Xcode or Visual Studio project files for IDE-based builds, CMake
|
||||
configuration and command line builds must be performed _outside_ mruby's project root
|
||||
directory. If you accidentally ran `cmake` in the root directory, delete the generated
|
||||
`CMakeFiles/` subdirectory and `CMakeCache.txt` file, `cd` to another dir (hint: the included
|
||||
`build` subdir), and re-run `cmake`.
|
||||
|
||||
### Native builds from the command line
|
||||
|
||||
@@ -36,4 +37,8 @@ _in process_, see this [basic cross compiling post](http://jonforums.github.com/
|
||||
|
||||
### Native OS X builds from Xcode IDE
|
||||
|
||||
_in process_, do not edit source that's been copied into the build directory (**TODO** elaborate!)
|
||||
From mruby's root directory, run `cmake -G Xcode .` to generate Xcode project files. Open the
|
||||
`mruby.xcodeproj` file in Xcode and hack away as you would with any other project. **Note:** do not
|
||||
run CMake outside the root directory in another build directory because mruby's source files will
|
||||
be _copied_ to the build directory. Any edits will occur to the _copied_ source files rather than
|
||||
the real mruby source files, resulting in a very awkward, and potentially broken, workflow.
|
||||
Reference in New Issue
Block a user