-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.mk
49 lines (39 loc) · 1.47 KB
/
build.mk
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
# DannyNiu/NJF, 2024-07-27. Public Domain.
include common.mk
include objects.mk
include inc-config.mk
.PHONY: all
all: build/${ProductName}.${FILE_EXT} build/include build/${ProductName}.pc
build/${ProductName}.${FILE_EXT}: ${INPUT_OBJECTS}
${LD} ${DLLFLAGS} ${LDFLAGS} ${INPUT_OBJECTS} -o $@
build/include:
mkdir -p build/include
cd src ; find . -name \*.h ! -name \*.c.h ! -name \*largeint\* | \
while read e ; do \
mkdir -p "../build/include/$$(dirname "$$e")" ; \
cp "$$PWD/$$e" "../build/include/$$e" ; \
done
build/${ProductName}.pc:
printf '%s\n' \
"prefix=${prefix}" "exec_prefix=${exec_prefix}" \
"libdir=${libdir}" "includedir=${includedir}" \
"Name: MySuiteA Dynamic Library" \
"Version: ${ProductRev}" \
"Description: The MySuiteA Cryptography Library." \
"URL: https://github.com/dannyniu/MySuiteA" \
"URL: https://gitee.com/dannyniu/MySuiteA" \
'Cflags: -I$${includedir} '"${CFLAGS_GROUP_WITH}" \
'Libs: -L$${libdir} -lMySuiteA' \
> $@
# 2024-03-08:
# This file is created whenever "inc-dep.mk" ought to be re-made for
# inclusion, and is asynchronously removed after about 3 seconds.
auto/meta-phony.tmp:
date -u "+%Y-%m-%d T %T %Z" > auto/meta-phony.tmp
inc-dep.mk: auto/meta-phony.tmp
utils/gen-inc-dep.sh src > inc-dep.mk
{ sleep 3 ; rm auto/meta-phony.tmp ; } &
# 2024-03-08:
# the include file contains target rules, so it
# must not come before the first rule of this file.
include inc-dep.mk