-
-
Notifications
You must be signed in to change notification settings - Fork 813
/
Copy pathMakefile
204 lines (166 loc) · 4.54 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
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
#/
# @license Apache-2.0
#
# Copyright (c) 2017 The Stdlib Authors.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#/
# VARIABLES #
# Define the path for saving dependency downloads:
DEPS_TMP_DIR ?= $(DEPS_DIR)/tmp
# Define the path for dependency checksums:
DEPS_CHECKSUMS_DIR ?= $(DEPS_DIR)/checksums
# Define the path to an executable for downloading a remote resource:
DEPS_DOWNLOAD_BIN ?= $(TOOLS_DIR)/scripts/download
# Define the path to an executable for verifying a download:
DEPS_CHECKSUM_BIN ?= $(TOOLS_DIR)/scripts/checksum
# DEPENDENCIES #
# Note: keep in alphabetical order...
include $(TOOLS_MAKE_LIB_DIR)/install/boost.mk
include $(TOOLS_MAKE_LIB_DIR)/install/cephes.mk
include $(TOOLS_MAKE_LIB_DIR)/install/cppcheck.mk
include $(TOOLS_MAKE_LIB_DIR)/install/electron.mk
include $(TOOLS_MAKE_LIB_DIR)/install/emsdk.mk
include $(TOOLS_MAKE_LIB_DIR)/install/llvm.mk
include $(TOOLS_MAKE_LIB_DIR)/install/node.mk
include $(TOOLS_MAKE_LIB_DIR)/install/openblas.mk
include $(TOOLS_MAKE_LIB_DIR)/install/python_deps.mk
include $(TOOLS_MAKE_LIB_DIR)/install/r_deps.mk
include $(TOOLS_MAKE_LIB_DIR)/install/shellcheck.mk
include $(TOOLS_MAKE_LIB_DIR)/install/wabt.mk
include $(TOOLS_MAKE_LIB_DIR)/install/wasi_libc.mk
# RULES #
#/
# Creates a directory for storing external library downloads.
#
# @private
#/
$(DEPS_TMP_DIR):
$(QUIET) $(MKDIR_RECURSIVE) $(DEPS_TMP_DIR)
#/
# Creates a directory for storing external libraries.
#
# @private
#/
$(DEPS_BUILD_DIR):
$(QUIET) $(MKDIR_RECURSIVE) $(DEPS_BUILD_DIR)
#/
# Runs the project's (minimal) install sequence.
#
# @example
# make install
#/
install: clean-deps-electron install-node install-deps-electron
.PHONY: install
#/
# Runs the project's full install sequence.
#
# @example
# make install-all
#/
install-all: install install-deps-all
.PHONY: install-all
#/
# Installs external library dependencies and development dependencies.
#
# @example
# make install-deps-all
#/
install-deps-all: install-deps install-deps-dev
.PHONY: install-deps-all
#/
# Removes all external library dependencies.
#
# @example
# make clean-deps-all
#/
clean-deps-all: clean-deps-downloads-all clean-deps-build-all clean-deps-tests-all
.PHONY: clean-deps-all
#/
# Removes all external library installation test artifacts.
#
# @example
# make clean-deps-tests-all
#/
clean-deps-tests-all: clean-deps-tests clean-deps-dev-test
.PHONY: clean-deps-tests-all
#/
# Installs external library dependencies.
#
# ## Notes
#
# - This rule does **not** install dependencies used during development.
#
# @example
# make install-deps
#/
install-deps: install-deps-openblas
.PHONY: install-deps
#/
# Removes external library dependencies.
#
# @example
# make clean-deps
#/
clean-deps: clean-deps-openblas
.PHONY: clean-deps
#/
# Removes external library installation test artifacts.
#
# @example
# make clean-deps-tests
#/
clean-deps-tests: clean-deps-openblas-tests
.PHONY: clean-deps-tests
#/
# Installs all external library dependencies used during development.
#
# @example
# make install-deps-dev
#/
install-deps-dev: install-deps-boost install-deps-cephes install-deps-cppcheck install-deps-python install-deps-r install-deps-shellcheck
.PHONY: install-deps-dev
#/
# Removes external library development dependencies.
#
# @example
# make clean-deps-dev
#/
clean-deps-dev: clean-deps-boost clean-deps-cephes clean-deps-cppcheck clean-deps-python clean-deps-r clean-deps-shellcheck
.PHONY: clean-deps-dev
#/
# Removes all external development library installation test artifacts.
#
# @example
# make clean-deps-dev-tests
#/
clean-deps-dev-tests: clean-deps-boost-tests clean-deps-cephes-tests clean-deps-cppcheck-tests clean-deps-shellcheck-tests
.PHONY: clean-deps-dev-tests
#/
# Removes all external library downloads.
#
# @example
# make clean-deps-downloads-all
#/
clean-deps-downloads-all:
$(QUIET) $(DELETE) $(DELETE_FLAGS) $(DEPS_TMP_DIR)
.PHONY: clean-deps-downloads-all
#/
# Removes all external library build artifacts.
#
# @example
# make clean-deps-build-all
#/
clean-deps-build-all:
$(QUIET) $(DELETE) $(DELETE_FLAGS) $(DEPS_BUILD_DIR)
.PHONY: clean-deps-build-all