Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

R** move cmake installation into env_create.sh #2393

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion BUILDING.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ This page describes how to build Core ML Tools (coremltools) from the source rep

To build coremltools from source, you need the following:

* [CMake](https://cmake.org/)
* [Miniconda](https://docs.conda.io/en/latest/miniconda.html) (or [Anaconda](https://www.anaconda.com/))
* [Zsh shell](http://zsh.sourceforge.net/) (the default shell for macOS 10.16+) installed in /usr/bin
* A C++17 compatible compiler (if using GCC, need GCC 9.0 or later)
Expand Down
2 changes: 0 additions & 2 deletions docs-guides/source/installing-coremltools.md
Original file line number Diff line number Diff line change
Expand Up @@ -126,8 +126,6 @@ pip install coremltools-4.0-cp38-none-macosx_10_12_intel.whl

## Build From Source

To build Core ML Tools and its dependent libraries from source, you need to install [CMake](https://cmake.org/) to configure the project.

To perform the build, fork and clone the [`coremltools` repository](https://github.com/apple/coremltools) and run the [`build.sh`](https://github.com/apple/coremltools/blob/master/scripts/build.sh) script:

```shell
Expand Down
3 changes: 0 additions & 3 deletions scripts/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -107,9 +107,6 @@ CMAKE_COMMAND=""
if [[ $OSTYPE == darwin* ]]; then
CMAKE_COMMAND="xcrun --sdk ${sdk} "
fi
if [ -z "`which cmake`" ] || [ "`which cmake`" = "cmake not found" ]; then
conda install cmake -y
fi
CMAKE_COMMAND+="cmake $ADDITIONAL_CMAKE_OPTIONS \
-DCMAKE_BUILD_TYPE=$BUILD_MODE \
-DPYTHON_EXECUTABLE:FILEPATH=$PYTHON_EXECUTABLE \
Expand Down
1 change: 1 addition & 0 deletions scripts/env_create.sh
Original file line number Diff line number Diff line change
Expand Up @@ -110,6 +110,7 @@ if [[ $DEV == 1 ]]; then
python -m pip install -e "$COREMLTOOLS_HOME/../coremltools" --upgrade
fi

conda install -y cmake
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please add the deleted if-statement from build.sh here.

conda deactivate

echo
Expand Down