]>
Commit | Line | Data |
---|---|---|
26116187 ZJS |
1 | # Try to guess the build directory: |
2 | # we look for subdirectories of ../.. that look like ninja build dirs. | |
3 | ||
4 | ifeq ($(BUILD_DIR),) | |
5 | dirs = $(dir $(wildcard ../../*/.ninja_log)) | |
6 | ifeq ($(dirs),) | |
7 | $(error Cannot guess build dir, set BUILD_DIR) | |
8 | endif | |
9 | ifneq ($(firstword $(dirs)),$(dirs)) | |
10 | $(warning Candidates: $(dirs)) | |
11 | $(error Too many build dirs to pick from, set BUILD_DIR) | |
12 | endif | |
13 | BUILD_DIR=$(dirs) | |
14 | endif |