~ubuntu-branches/ubuntu/wily/grass/wily

« back to all changes in this revision

Viewing changes to man/Makefile

Tags: 7.0.0~rc1+ds1-1~exp1
* New upstream release candidate.
* Repack upstream tarball, remove precompiled Python objects.
* Add upstream metadata.
* Update gbp.conf and Vcs-Git URL to use the experimental branch.
* Update watch file for GRASS 7.0.
* Drop build dependencies for Tcl/Tk, add build dependencies:
  python-numpy, libnetcdf-dev, netcdf-bin, libblas-dev, liblapack-dev
* Update Vcs-Browser URL to use cgit instead of gitweb.
* Update paths to use grass70.
* Add configure options: --with-netcdf, --with-blas, --with-lapack,
  remove --with-tcltk-includes.
* Update patches for GRASS 7.
* Update copyright file, changes:
  - Update copyright years
  - Group files by license
  - Remove unused license sections
* Add patches for various typos.
* Fix desktop file with patch instead of d/rules.
* Use minimal dh rules.
* Bump Standards-Version to 3.9.6, no changes.
* Use dpkg-maintscript-helper to replace directories with symlinks.
  (closes: #776349)
* Update my email to use @debian.org address.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
MODULE_TOPDIR = ..
2
2
 
3
 
include $(MODULE_TOPDIR)/include/Make/Dir.make
4
 
 
5
 
# some definitions
6
 
SECT = 1
7
 
MANDIR  = $(GISBASE)/man/man$(SECT)
8
 
HTMLDIR = $(GISBASE)/docs/html
9
 
HTML2MAN = GRASS_PERL=${PERL} VERSION_NUMBER=${GRASS_VERSION_NUMBER} sh $(GRASS_HOME)/tools/g.html2man/g.html2man
10
 
 
11
 
MANPAGES := $(patsubst $(HTMLDIR)/%.html,$(MANDIR)/%.$(SECT),$(wildcard $(HTMLDIR)/*.html))
12
 
 
13
 
ifeq ($(PERL),no)
14
 
default:
15
 
else
16
 
default: $(MANPAGES)
17
 
endif
18
 
 
19
 
$(MANDIR):
20
 
        $(MKDIR) $(MANDIR)
21
 
 
22
 
ifneq ($(BROKEN_MAKE),)
23
 
$(MANDIR)/%.$(SECT): $(HTMLDIR)/%.html $(MANDIR)
24
 
else
25
 
$(MANDIR)/%.$(SECT): $(HTMLDIR)/%.html | $(MANDIR)
26
 
endif
27
 
        $(HTML2MAN) $< $@ $(SECT)
 
3
include $(MODULE_TOPDIR)/include/Make/Other.make
 
4
 
 
5
MANPAGES := $(patsubst $(HTMLDIR)/%.html,$(MANDIR)/%.$(MANSECT),$(wildcard $(HTMLDIR)/*.html))
 
6
 
 
7
DSTFILES := \
 
8
        $(HTMLDIR)/grassdocs.css \
 
9
        $(HTMLDIR)/grass_logo.png \
 
10
        $(HTMLDIR)/grass_icon.png
 
11
 
 
12
categories = \
 
13
        d:display \
 
14
        db:database \
 
15
        g:general \
 
16
        i:imagery \
 
17
        m:misc \
 
18
        ps:postscript \
 
19
        r:raster \
 
20
        r3:raster3d \
 
21
        t:temporal \
 
22
        v:vector
 
23
 
 
24
IDXCATS := $(foreach cat,$(categories),$(lastword $(subst :, ,$(cat))))
 
25
 
 
26
IDXSRC = full_index index topics keywords $(IDXCATS)
 
27
 
 
28
INDICES := $(patsubst %,$(HTMLDIR)/%.html,$(IDXSRC))
 
29
 
 
30
ALL_HTML := $(wildcard $(HTMLDIR)/*.*.html)
 
31
 
 
32
ifneq (@(type sphinx-build2 > /dev/null),)
 
33
SPHINXBUILD   = sphinx-build2
 
34
endif
 
35
ifneq (@(type sphinx-build > /dev/null),)
 
36
SPHINXBUILD   = sphinx-build
 
37
endif
 
38
 
 
39
default: $(DSTFILES)
 
40
        @echo "Generating HTML manual pages index (help system)..."
 
41
        $(MAKE) $(INDICES)
 
42
        $(call build,check)
 
43
        $(MAKE) manpages
 
44
 
 
45
# This must be a separate target so that evaluation of $(MANPAGES)
 
46
# is delayed until the indices have been generated
 
47
manpages:
 
48
        $(MAKE) $(MANPAGES)
 
49
 
 
50
.PHONY: manpages
 
51
 
 
52
define build
 
53
GISBASE="$(RUN_GISBASE)" ARCH="$(ARCH)" ARCH_DISTDIR="$(ARCH_DISTDIR)" \
 
54
        VERSION_NUMBER=$(GRASS_VERSION_NUMBER) VERSION_DATE=$(GRASS_VERSION_DATE) \
 
55
        $(PYTHON) ./build_$(1).py $(2)
 
56
endef
 
57
 
 
58
define build_topics
 
59
GISBASE="$(RUN_GISBASE)" ARCH="$(ARCH)" ARCH_DISTDIR="$(ARCH_DISTDIR)" \
 
60
        VERSION_NUMBER=$(GRASS_VERSION_NUMBER) VERSION_DATE=$(GRASS_VERSION_DATE) \
 
61
        $(PYTHON) ./build_topics.py $(HTMLDIR)
 
62
endef
 
63
 
 
64
define build_keywords
 
65
GISBASE="$(RUN_GISBASE)" ARCH="$(ARCH)" ARCH_DISTDIR="$(ARCH_DISTDIR)" \
 
66
        VERSION_NUMBER=$(GRASS_VERSION_NUMBER) VERSION_DATE=$(GRASS_VERSION_DATE) \
 
67
        $(PYTHON) ./build_keywords.py $(HTMLDIR)
 
68
endef
 
69
 
 
70
$(HTMLDIR)/topics.html: $(ALL_HTML)
 
71
        $(call build_topics)
 
72
        touch $@
 
73
 
 
74
$(HTMLDIR)/full_index.html: $(ALL_HTML) build_full_index.py build_html.py
 
75
        $(call build,full_index)
 
76
        touch $@
 
77
 
 
78
$(HTMLDIR)/index.html: build_index.py build_html.py
 
79
        $(call build,index)
 
80
        touch $@
 
81
 
 
82
$(HTMLDIR)/keywords.html: $(ALL_HTML)
 
83
        $(call build_keywords)
 
84
        touch $@
 
85
 
 
86
define category_rule
 
87
$$(HTMLDIR)/$(2).html: $$(wildcard $$(HTMLDIR)/$(1).*.html) build_class.py build_html.py
 
88
        $$(call build,class,$(1) $(2))
 
89
        touch $$@
 
90
endef
 
91
 
 
92
$(foreach cat,$(categories),$(eval $(call category_rule,$(firstword $(subst :, ,$(cat))),$(lastword $(subst :, ,$(cat))))))
 
93
 
 
94
$(HTMLDIR)/grassdocs.css: grassdocs.css
 
95
        $(INSTALL_DATA) $< $@
 
96
 
 
97
$(HTMLDIR)/grass_logo.png: grass_logo.png
 
98
        $(INSTALL_DATA) $< $@
 
99
 
 
100
$(HTMLDIR)/grass_icon.png: grass_icon.png
 
101
        $(INSTALL_DATA) $< $@
28
102