|
13 | 13 | # limitations under the License.
|
14 | 14 | .PHONY: all cmake build clean debug release unit
|
15 | 15 |
|
| 16 | +SHELL=/bin/bash |
16 | 17 | BUILD_BASE_DIR=_build
|
17 | 18 | BUILD_DIR=release
|
18 | 19 | BUILD_TYPE=Release
|
19 | 20 | BENCHMARKS_BASIC_DIR=$(BUILD_BASE_DIR)/$(BUILD_DIR)/velox/benchmarks/basic/
|
20 | 21 | BENCHMARKS_DUMP_DIR=dumps
|
21 | 22 | TREAT_WARNINGS_AS_ERRORS ?= 1
|
22 | 23 | ENABLE_WALL ?= 1
|
| 24 | +PYTHON_VENV ?= .venv |
23 | 25 |
|
24 | 26 | # Option to make a minimal build. By default set to "OFF"; set to
|
25 | 27 | # "ON" to only build a minimal set of components. This may override
|
@@ -169,17 +171,33 @@ fuzzertest: debug
|
169 | 171 | --minloglevel=0
|
170 | 172 |
|
171 | 173 | format-fix: #: Fix formatting issues in the main branch
|
| 174 | +ifneq ("$(wildcard ${PYTHON_VENV}/pyvenv.cfg)","") |
| 175 | + source ${PYTHON_VENV}/bin/activate; scripts/check.py format main --fix |
| 176 | +else |
172 | 177 | scripts/check.py format main --fix
|
| 178 | +endif |
173 | 179 |
|
174 | 180 | format-check: #: Check for formatting issues on the main branch
|
175 | 181 | clang-format --version
|
| 182 | +ifneq ("$(wildcard ${PYTHON_VENV}/pyvenv.cfg)","") |
| 183 | + source ${PYTHON_VENV}/bin/activate; scripts/check.py format main |
| 184 | +else |
176 | 185 | scripts/check.py format main
|
| 186 | +endif |
177 | 187 |
|
178 |
| -header-fix: #: Fix license header issues in the current branch |
| 188 | +header-fix: #: Fix license header issues in the current branch |
| 189 | +ifneq ("$(wildcard ${PYTHON_VENV}/pyvenv.cfg)","") |
| 190 | + source ${PYTHON_VENV}/bin/activate; scripts/check.py header main --fix |
| 191 | +else |
179 | 192 | scripts/check.py header main --fix
|
| 193 | +endif |
180 | 194 |
|
181 | 195 | header-check: #: Check for license header issues on the main branch
|
| 196 | +ifneq ("$(wildcard ${PYTHON_VENV}/pyvenv.cfg)","") |
| 197 | + source ${PYTHON_VENV}/bin/activate; scripts/check.py header main |
| 198 | +else |
182 | 199 | scripts/check.py header main
|
| 200 | +endif |
183 | 201 |
|
184 | 202 | circleci-container: #: Build the linux container for CircleCi
|
185 | 203 | $(MAKE) linux-container CONTAINER_NAME=circleci
|
|
0 commit comments