-
Notifications
You must be signed in to change notification settings - Fork 10
Expand file tree
/
Copy pathmakefile
More file actions
35 lines (25 loc) · 821 Bytes
/
Copy pathmakefile
File metadata and controls
35 lines (25 loc) · 821 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
PYTHON ?= python3.13
BUILD_DIR ?= build
ROOT_DIR := $(CURDIR)
PYBIND11_DIR := $(shell $(PYTHON) -m pybind11 --cmakedir)
.PHONY: configure build install quick rebuild editable clean quality
quality:
python -m ruff check PyMieSim tests
python -m mypy PyMieSim/gui/parsing.py PyMieSim/gui/schemas.py
configure:
cmake -S . -B $(BUILD_DIR) \
-Dpybind11_DIR="$(PYBIND11_DIR)" \
-DPython_EXECUTABLE="$$(which $(PYTHON))" \
-DCMAKE_INSTALL_PREFIX="$(ROOT_DIR)"
build:
cmake --build $(BUILD_DIR) -j
install:
cmake --install $(BUILD_DIR)
uninstall:
$(PYTHON) -m pip uninstall -y PyMieSim
quick: configure build install
rebuild: configure build install
editable:
$(PYTHON) -m pip install --no-build-isolation -Cbuild-dir=build -Ceditable.rebuild=false -Ceditable.mode=inplace -e .
clean:
rm -rf $(BUILD_DIR)