-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathMakefile
More file actions
97 lines (87 loc) · 3.77 KB
/
Copy pathMakefile
File metadata and controls
97 lines (87 loc) · 3.77 KB
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
#------------------------------------------------------------------------------
#-- Copyright (c) 2020 TclHdl
#--
#-- Permission is hereby granted, free of charge, to any person obtaining a copy
#-- of this software and associated documentation files (the "Software"), to deal
#-- in the Software without restriction, including without limitation the rights
#-- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
#-- copies of the Software, and to permit persons to whom the Software is
#-- furnished to do so, subject to the following conditions:
#--
#-- The above copyright notice and this permission notice shall be included in all
#-- copies or substantial portions of the Software.
#--
#-- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
#-- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
#-- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
#-- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
#-- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
#-- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
#-- SOFTWARE.
#------------------------------------------------------------------------------
#-- Project : TclHdl - Open HDL hub
#-- Author : Paulo Machado <pffmachado@yahoo.com>
#-- Filename : Makefile
#------------------------------------------------------------------------------
#-- File Description:
#--
#--
#--
#--
#------------------------------------------------------------------------------
#-- ChangeLog:
#--
#--
#--
#--
#------------------------------------------------------------------------------
#------------------------------------------------------------------------------
#-- Setup Environment
#------------------------------------------------------------------------------
PATH_ROOT = $(PWD)
PATH_SRC = $(PATH_ROOT)/src
PATH_TOOL = $(PATH_ROOT)/tool
PATH_CMAKE = $(PATH_ROOT)/cmake
PATH_DOCS = $(PATH_ROOT)/docs
PATH_DOXYGEN = $(PATH_DOCS)/doxygen
PATH_PLANTUML = $(PATH_DOCS)/plantuml
PATH_MARKDOWN = $(PATH_DOCS)/markdown
PATH_DOC = $(PATH_DOCS)/doc
PATH_SPHINX = $(PATH_DOCS)/sphinx
PATH_SPHINX_SOURCE = $(PATH_SPHINX)/source
PATH_SPHINX_BUILD = $(PATH_SPHINX)/build
PATH_SPHINX_BUILD_HTML = $(PATH_SPHINX_BUILD)/html
#------------------------------------------------------------------------------
#-- Generate Documentation
#------------------------------------------------------------------------------
cmakedoc:
mkdir -p $(PATH_SPHINX_SOURCE)/_cmake; \
cat $(PATH_CMAKE)/UseHdl.cmake | sed -n '/\[\.rst/,/#\]/p' | \
sed '1d' | sed '$$d' > $(PATH_SPHINX_SOURCE)/_cmake/UseHdl.rst
doxygen:
mkdir -p $(PATH_SPHINX_SOURCE)/_doxygen; \
cd $(PATH_DOXYGEN); \
cp $(PATH_DOXYGEN)/Doxygen.rst $(PATH_SPHINX_SOURCE)/_doxygen; \
doxygen Doxyfile
plantuml:
mkdir -p $(PATH_SPHINX_SOURCE)/_images; \
plantuml -tpng -o $(PATH_SPHINX_SOURCE)/_images $(PATH_PLANTUML)/*.puml
pandoc:
mkdir -p $(PATH_SPHINX_SOURCE)/_markdown; \
pandoc -s -t rst $(PATH_MARKDOWN)/Introduction.md -o $(PATH_SPHINX_SOURCE)/_markdown/Introduction.rst; \
pandoc -s -t rst $(PATH_MARKDOWN)/TclHdl.md -o $(PATH_SPHINX_SOURCE)/_markdown/TclHdl.rst
doc:
mkdir -p $(PATH_SPHINX_SOURCE)/_doc; \
cp $(PATH_DOC)/*.rst $(PATH_SPHINX_SOURCE)/_doc
sphinx: cmakedoc doxygen plantuml doc
cd $(PATH_SPHINX); \
make html; \
cp -r $(PATH_SPHINX_BUILD_HTML)/* $(PATH_DOCS); \
cp -r $(PATH_SPHINX_SOURCE)/_doxygen/html $(PATH_DOCS)/_doxygen; \
rm -rf $(PATH_SPHINX_BUILD); \
rm -rf $(PATH_SPHINX_SOURCE)/_markdown; \
rm -rf $(PATH_SPHINX_SOURCE)/_images; \
rm -rf $(PATH_SPHINX_SOURCE)/_doc; \
rm -rf $(PATH_SPHINX_SOURCE)/_breathe; \
rm -rf $(PATH_SPHINX_SOURCE)/_doxygen; \
rm -rf $(PATH_SPHINX_SOURCE)/_cmake