2 # :vim: filetype=make : -*- makefile; coding: utf-8; -*-
5 # Part of Bugs Everywhere, a distributed bug tracking system.
7 # Copyright (C) 2008-2012 Anton Batenev <abbat@abbat>
8 # Ben Finney <benf@cybersource.com.au>
9 # Chris Ball <cjb@laptop.org>
10 # Eric Kow <eric.kow@gmail.com>
11 # Gianluca Montecchi <gian@grys.it>
12 # Matěj Cepl <mcepl@redhat.com>
13 # W. Trevor King <wking@tremily.us>
15 # This file is part of Bugs Everywhere.
17 # Bugs Everywhere is free software: you can redistribute it and/or modify it
18 # under the terms of the GNU General Public License as published by the Free
19 # Software Foundation, either version 2 of the License, or (at your option) any
22 # Bugs Everywhere is distributed in the hope that it will be useful, but
23 # WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
24 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
27 # You should have received a copy of the GNU General Public License along with
28 # Bugs Everywhere. If not, see <http://www.gnu.org/licenses/>.
32 RST2MAN = /usr/bin/rst2man
33 RST2HTML = /usr/bin/rst2html
35 #PATH = /usr/bin:/bin # must include sphinx-build for 'sphinx' target.
37 #INSTALL_OPTIONS = "--prefix=/usr/local"
38 INSTALL_OPTIONS = "--user"
40 # Select the documentation you wish to build
43 # Directories with semantic meaning
45 MAN_DIR := ${DOC_DIR}/man
48 LIBBE_VERSION := libbe/_version.py
49 GENERATED_FILES := build $(LIBBE_VERSION)
51 MANPAGE_FILES = $(patsubst %,${MAN_DIR}/%,${MANPAGES})
52 MANPAGE_HTML = $(patsubst %,${MAN_DIR}/%.html,${MANPAGES})
53 GENERATED_FILES += ${MANPAGE_FILES} ${MANPAGE_HTML}
61 build: $(LIBBE_VERSION)
69 python setup.py install ${INSTALL_OPTIONS}
76 $(RM) -rf ${GENERATED_FILES}
77 $(MAKE) -C ${DOC_DIR} clean
80 .PHONY: libbe/_version.py
82 echo "# -*- coding: utf-8 -*-" > $@
83 git log -1 --encoding=UTF-8 --date=short --pretty='format:"Autogenerated by make libbe/_version.py"%nversion_info = {%n "date":"%cd",%n "revision":"%H",%n "committer":"%cn"}%n' >> $@
95 $(MAKE) -C ${DOC_DIR} html