-
Notifications
You must be signed in to change notification settings - Fork 5
/
Makefile
executable file
·101 lines (84 loc) · 2.51 KB
/
Makefile
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
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
###############################################################################
# yang Internal Makefile
#
# Author:
# Jonathan Yang (yuekyang) - CSG Polaris DMI Infra
#
# Support:
#
# Version:
# v2.0.0
#
# Date:
# May 2018
#
# About This File:
# This script will build the dyntopo package for distribution in PyPI server
#
# Requirements:
# 1. Module name is the same as package name.
# 2. setup.py file is stored within the module folder
###############################################################################
# Variables
PKG_NAME = ncdiff
PKG_PATH = ncdiff
BUILDDIR = $(shell pwd)/__build__
PYTHON = python
TESTCMD = cd tests; runAll
DISTDIR = $(BUILDDIR)/dist
.PHONY: clean package develop undevelop populate_dist_dir help \
docs test
help:
@echo "Please use 'make <target>' where <target> is one of"
@echo ""
@echo "package : Build the package"
@echo "test : Test the package"
@echo "clean : Remove build artifacts"
@echo "develop : Build and install development package"
@echo "undevelop : Uninstall development package"
@echo "docs : Build Sphinx documentation for this package"
docs:
@echo ""
@echo "--------------------------------------------------------------------"
@echo "Building $(PKG_NAME) documentation for preview: $@"
@echo ""
@./setup.py docs
@echo "Completed building docs for preview."
@echo ""
test:
@$(TESTCMD)
package:
@echo ""
@echo "--------------------------------------------------------------------"
@echo "Building $(PKG_NAME) distributable: $@"
@echo ""
@./setup.py bdist_wheel --dist-dir=$(DISTDIR)
@echo "Completed building: $@"
@echo ""
develop:
@echo ""
@echo "--------------------------------------------------------------------"
@echo "Building and installing $(PKG_NAME) development distributable: $@"
@echo ""
@./setup.py develop --no-deps -q
@echo "Completed building and installing: $@"
@echo ""
undevelop:
@echo ""
@echo "--------------------------------------------------------------------"
@echo "Uninstalling $(PKG_NAME) development distributable: $@"
@echo ""
@./setup.py develop --no-deps -q --uninstall
@echo "Completed uninstalling: $@"
@echo ""
clean:
@echo ""
@echo "--------------------------------------------------------------------"
@echo "Removing make directory: $(BUILDDIR)"
@rm -rf $(BUILDDIR)
@echo "Removing build artifacts ..."
@./setup.py clean
@echo ""
@echo "Done."
@echo ""