From 3416705b766209339766bc3a8308e06975a8858b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jonatan=20K=C5=82osko?= Date: Mon, 8 Jan 2024 05:36:08 +0100 Subject: [PATCH] Remove Windows instructions (#70) --- Makefile.win | 62 ---------------------------------------------------- README.md | 9 +++----- 2 files changed, 3 insertions(+), 68 deletions(-) delete mode 100644 Makefile.win diff --git a/Makefile.win b/Makefile.win deleted file mode 100644 index f39550e..0000000 --- a/Makefile.win +++ /dev/null @@ -1,62 +0,0 @@ -# Environment variables passed via elixir_make -# ROOT_DIR -# BUILD_ARCHIVE -# BUILD_ARCHIVE_DIR -# BUILD_INTERNAL_FLAGS - -# System vars -TEMP=$(HOME)/.cache - -# Public configuration -!IFNDEF BUILD_MODE -BUILD_MODE=opt # can also be dbg -!ENDIF - -!IFNDEF BUILD_CACHE -BUILD_CACHE=$(TEMP)/xla_extension -!ENDIF - -!IFNDEF TENSORFLOW_GIT_REPO -TENSORFLOW_GIT_REPO=https://github.com/tensorflow/tensorflow.git -!ENDIF - -!IFNDEF TENSORFLOW_GIT_REV -# Tensorflow 2.8.0 -TENSORFLOW_GIT_REV=3f878cff5b698b82eea85db2b60d65a2e320850e -!ENDIF - -# Private configuration -BAZEL_FLAGS=--define "framework_shared_object=false" -c $(BUILD_MODE) - -TENSORFLOW_NS=tf-$(TENSORFLOW_GIT_REV) -TENSORFLOW_DIR=$(BUILD_CACHE)/$(TENSORFLOW_NS) -TENSORFLOW_XLA_EXTENSION_NS=tensorflow/compiler/xla/extension -TENSORFLOW_XLA_EXTENSION_DIR=$(TENSORFLOW_DIR)/$(TENSORFLOW_XLA_EXTENSION_NS) -TENSORFLOW_XLA_BUILD_ARCHIVE=$(TENSORFLOW_DIR)/bazel-bin/$(TENSORFLOW_XLA_EXTENSION_NS)/xla_extension.tar.gz - -$(BUILD_ARCHIVE): $(TENSORFLOW_DIR) extension/BUILD - rm -rf "$(TENSORFLOW_XLA_EXTENSION_DIR)" && \ - ln -s "$(ROOT_DIR)/extension" "$(TENSORFLOW_XLA_EXTENSION_DIR)" && \ - cd "$(TENSORFLOW_DIR)" && \ - bazel build $(BAZEL_FLAGS) $(BUILD_FLAGS) $(BUILD_INTERNAL_FLAGS) //$(TENSORFLOW_XLA_EXTENSION_NS):xla_extension && \ - mkdir -f "$(BUILD_ARCHIVE_DIR)" && \ - cp -f "$(TENSORFLOW_XLA_BUILD_ARCHIVE)" "$(BUILD_ARCHIVE)" - -# Clones tensorflow -$(TENSORFLOW_DIR): - mkdir "$(TENSORFLOW_DIR)" && \ - cd "$(TENSORFLOW_DIR)" && \ - git init && \ - git remote add origin $(TENSORFLOW_GIT_REPO) && \ - git fetch --depth 1 origin $(TENSORFLOW_GIT_REV) && \ - git checkout FETCH_HEAD - -# Print Tensorflow Dir -PTD: - @ echo "$(TENSORFLOW_DIR)" - -clean: - cd "$(TENSORFLOW_DIR)" && bazel clean --expunge - rm -rf "$(TENSORFLOW_XLA_EXTENSION_DIR)" - rm -rf "$(TENSORFLOW_DIR)" - rm -rf "$(TARGET_DIR)" diff --git a/README.md b/README.md index 3bde460..f8f38e0 100644 --- a/README.md +++ b/README.md @@ -82,6 +82,9 @@ should be a list following this format: `Key1: Value1; Key2: value2`. ## Building from source +> Note: currently only macOS and Linux is supported. When on Windows, the best option +> to use XLA and EXLA is by running inside WSL. + To build the XLA binaries locally you need to set `XLA_BUILD=true` and possibly `XLA_TARGET`. Keep in mind that the compilation usually takes a very long time. @@ -91,12 +94,6 @@ You will need the following installed in your system for the compilation: * [Bazel v6.1.2](https://bazel.build/) for compiling XLA * [Python3](https://python.org) with NumPy installed for compiling XLA -If running on Windows, you will also need: - - * [MSYS2](https://www.msys2.org/) - * [Microsoft Build Tools 2019](https://visualstudio.microsoft.com/downloads/) - * [Microsoft Visual C++ 2019 Redistributable](https://visualstudio.microsoft.com/downloads/) - ### Common issues #### Bazel version