From 35f38f973e49cf29bf7afc53ba4c3954bedb865f Mon Sep 17 00:00:00 2001 From: Andrew Belt Date: Wed, 20 Sep 2017 19:17:10 -0400 Subject: [PATCH] Added `make dep` to root Makefile, added Development Environment setup to README --- Makefile | 5 ++++- README.md | 32 ++++++++++++++++++++++++++++---- 2 files changed, 32 insertions(+), 5 deletions(-) diff --git a/Makefile b/Makefile index 2c7e118b..04e40625 100644 --- a/Makefile +++ b/Makefile @@ -42,6 +42,9 @@ endif all: $(TARGET) +dep: + $(MAKE) -C dep + run: $(TARGET) ifeq ($(ARCH), lin) LD_LIBRARY_PATH=dep/lib ./$< @@ -165,4 +168,4 @@ distplugins: plugins: for f in plugins/*; do (cd "$$f" && ${CMD}); done -.PHONY: all run debug clean dist allplugins cleanplugins distplugins plugins +.PHONY: all dep run debug clean dist allplugins cleanplugins distplugins plugins diff --git a/README.md b/README.md index 493b414f..dd30ea69 100644 --- a/README.md +++ b/README.md @@ -4,22 +4,46 @@ ![Rack screenshot](https://vcvrack.com/images/screenshot.png) +This README includes instructions for building Rack from source. For information about the software, go to https://vcvrack.com/. + +## Setting up your development environment + +Rack's dependencies (GLEW, glfw, etc) do not need to be installed on your system, since specific versions are compiled locally during the build process. However, you need proper tools to build these dependencies. + +### Mac + +Install [Xcode](https://developer.apple.com/xcode/) or *command line developer tools* with `xcode-select --install`. +Install [CMake](https://cmake.org/), preferably from [Homebrew](https://brew.sh/). + +If you would like MacOS 10.7+ users to be able to run your binaries and plugins, install the MacOS 10.7 SDK using the [xcodelegacy](https://github.com/devernay/xcodelegacy) script. + +### Windows + +Install [MSYS2](http://www.msys2.org/) and launch the mingw64 shell (not the default msys2 shell). +Install build dependencies with the pacman package manger. + + pacman -S git make tar unzip mingw-w64-x86_64-gcc mingw-w64-x86_64-cmake + +### Linux + +With your distro's package manager, make sure you have installed `gcc`, `make`, `cmake`, `tar`, and `unzip`. + ## Building *If the build fails for you, please report the issue with a detailed error message to help the portability of Rack.* Clone this repository and `cd` into it. -On Windows, use [MSYS2](http://www.msys2.org/) and launch a mingw64 shell. Clone submodules. git submodule update --init --recursive Build dependencies locally. +You may use make's `-j$(nproc)` flag to parallelize builds across all your CPU cores. - cd dep - make - cd .. + make dep + +You should see a message that all dependencies built successfully. Build Rack.