forked from nexusformat/definitions
-
Notifications
You must be signed in to change notification settings - Fork 3
/
Makefile
89 lines (69 loc) · 2.46 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
# File: Makefile
# purpose:
# build resources in NeXus definitions tree
# ref: http://www/gnu.org/software/make/manual/make.html
SUBDIRS = manual impatient-guide
.PHONY: subdirs $(SUBDIRS) builddir all
subdirs: $(SUBDIRS)
#$(SUBDIRS):
# $(MAKE) -C $@
manual :: nxdl2rst
$(MAKE) html -C $@
all ::
$(MAKE) rmbuilddir builddir
$(MAKE) impatient-guide manual -C build
# expect next make (PDF) to fail (thus exit 0) since nexus.ind not found first time
# extra option needed to satisfy "levels nested too deeply" error
($(MAKE) latexpdf LATEXOPTS="--interaction=nonstopmode" -C build/manual || exit 0)
# make that missing file
makeindex build/manual/build/latex/nexus.idx
# build the PDF, still a failure will be noted but we can ignore it without problem
($(MAKE) latexpdf LATEXOPTS="--interaction=nonstopmode" -C build/manual || exit 0)
# finally, report what was built
@echo "HTML built: `ls -lAFgh build/manual/build/html/index.html`"
@echo "PDF built: `ls -lAFgh build/manual/build/latex/nexus.pdf`"
impatient-guide ::
$(MAKE) html -C $@
#pdfdoc ::
# $(MAKE) latexpdf -C $(SUBDIRS)
clean:
$(MAKE) clean -C $(SUBDIRS)
nxdl2rst:
$(MAKE) -C manual/source
builddir ::
mkdir -p build
python utils/build_preparation.py . build
makebuilddir :: builddir
$(MAKE) -C build
remakebuilddir :: makebuilddir
rebuildall :: rmbuilddir makebuilddir
cleanbuilddir ::
$(MAKE) -C build clean
rmbuilddir ::
$(RM) -r build
# for developer's use on local build host
local ::
python utils/test_suite.py
$(RM) -r build
mkdir -p build
python utils/build_preparation.py . build
$(MAKE) -C build
# NeXus - Neutron and X-ray Common Data Format
#
# Copyright (C) 2008-2020 NeXus International Advisory Committee (NIAC)
#
# This library is free software; you can redistribute it and/or
# modify it under the terms of the GNU Lesser General Public
# License as published by the Free Software Foundation; either
# version 3 of the License, or (at your option) any later version.
#
# This library is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
# Lesser General Public License for more details.
#
# You should have received a copy of the GNU Lesser General Public
# License along with this library; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
#
# For further information, see http://www.nexusformat.org