-
Notifications
You must be signed in to change notification settings - Fork 8
Expand file tree
/
Copy pathMakefile
More file actions
35 lines (26 loc) · 1012 Bytes
/
Makefile
File metadata and controls
35 lines (26 loc) · 1012 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
# SPDX-License-Identifier: BSD-3-Clause
# Copyright (C) 2023 Intel Corporation.
# Copyright (c) 2023 NVIDIA CORPORATION & AFFILIATES
# All rights reserved.
#
SPDK_ROOT_DIR := $(abspath $(CURDIR)/..)
include $(SPDK_ROOT_DIR)/mk/spdk.common.mk
all: spdk/version.py
clean:
$(Q)rm -f spdk/version.py
$(Q)rm -rf $(SPDK_ROOT_DIR)/python/dist
spdk/version.py: $(SPDK_ROOT_DIR)/VERSION
$(Q)printf "__version__ = '%d.%d%s%s'\n" \
$(version_major) $(version_minor) \
$(shell [ $(version_patch) != 0 ] && echo -n ".$(version_patch)") \
$(shell echo -n \"$(version_suffix)\" | sed 's/-pre/rc0/g' | tr -d -) > spdk/version.py
build: spdk/version.py
$(Q)python -m build $(SPDK_ROOT_DIR)/python/
check: build
$(Q)python -m twine check $(SPDK_ROOT_DIR)/python/dist/*
install:
$(Q)uv pip install --prefix=$(CONFIG_PREFIX) $(SPDK_ROOT_DIR)/python
rm -rf $(SPDK_ROOT_DIR)/python/spdk.egg-info
uninstall:
$(Q)uv pip uninstall --prefix=$(CONFIG_PREFIX) spdk
.PHONY: all clean install uninstall build check