NEWS: prepare for new release
[openocd.git] / Makefile.am
blob930a3073388033a4fe2ee31362b2965d3cab86c6
1 # not a GNU package. You can remove this line, if
2 # have all needed files, that a GNU package needs
3 AUTOMAKE_OPTIONS = gnu 1.6
5 # make sure we pass the correct jimtcl flags to distcheck
6 DISTCHECK_CONFIGURE_FLAGS = --disable-install-jim
8 # do not run Jim Tcl tests (esp. during distcheck)
9 check-recursive:
10         @true
12 nobase_dist_pkgdata_DATA = \
13         contrib/libdcc/dcc_stdio.c \
14         contrib/libdcc/dcc_stdio.h \
15         contrib/libdcc/example.c \
16         contrib/libdcc/README \
17         contrib/60-openocd.rules
19 SUBDIRS =
20 DIST_SUBDIRS =
21 bin_PROGRAMS =
22 noinst_LTLIBRARIES =
23 info_TEXINFOS =
24 dist_man_MANS =
25 EXTRA_DIST =
27 if INTERNAL_JIMTCL
28 SUBDIRS += jimtcl
29 DIST_SUBDIRS += jimtcl
30 endif
32 # common flags used in openocd build
33 AM_CFLAGS = $(GCC_WARNINGS)
35 AM_CPPFLAGS = $(HOST_CPPFLAGS)\
36                           -I$(top_srcdir)/src \
37                           -I$(top_builddir)/src \
38                           -I$(top_srcdir)/src/helper \
39                           -DPKGDATADIR=\"$(pkgdatadir)\" \
40                           -DBINDIR=\"$(bindir)\"
42 if INTERNAL_JIMTCL
43 AM_CPPFLAGS += -I$(top_srcdir)/jimtcl \
44                            -I$(top_builddir)/jimtcl
45 endif
46 EXTRA_DIST += \
47         BUGS \
48         HACKING \
49         NEWTAPS \
50         README.Windows \
51         README.OSX \
52         $(wildcard $(srcdir)/NEWS*) \
53         Doxyfile.in \
54         tools/logger.pl \
55         tools/rlink_make_speed_table \
56         tools/st7_dtc_as \
57         contrib
59 libtool: $(LIBTOOL_DEPS)
60         $(SHELL) ./config.status --recheck
62 docs: pdf html doxygen
64 Doxyfile: $(srcdir)/Doxyfile.in
65         @echo "Creating $@ from $<..."
66         @( \
67           echo "### @@@ -= DO NOT EDIT THIS FILE =- @@@ ###" && \
68           echo "### @@@ Make changes to Doxyfile.in @@@ ###" && \
69           sed -e 's,@srcdir\@,$(srcdir),' \
70             -e 's,@builddir\@,$(builddir),' \
71             -e 's,@doxygen_as_html\@,$(doxygen_as_html),' \
72             -e 's,@doxygen_as_pdf\@,$(doxygen_as_pdf),' $< \
73         ) > $@
75 THE_MANUAL = doxygen/latex/refman.pdf
77 doxygen::
78         $(MAKE) Doxyfile
79         doxygen Doxyfile 2>&1 | perl $(srcdir)/tools/logger.pl > doxygen.log
80         @if [ -f doxygen/latex/refman.tex ]; then \
81                 echo "Creating $(THE_MANUAL)..."; \
82                 $(MAKE) $(THE_MANUAL); \
83         else \
84                 echo "Skipping Doxygen PDF..."; \
85         fi
87 $(THE_MANUAL): %.pdf: %.tex
88         -cd $$(dirname $*) && pdflatex $$(basename $*)
89         -cd $$(dirname $*) && pdflatex $$(basename $*)
91 TCL_PATH = tcl
92 # command to find paths of script files, relative to TCL_PATH
93 TCL_FILES = find $(srcdir)/$(TCL_PATH) -name '*.cfg' -o -name '*.tcl' -o -name '*.txt' | \
94                 sed -e 's,^$(srcdir)/$(TCL_PATH),,'
96 dist-hook:
97         if test -d $(srcdir)/.git -a \( ! -e $(distdir)/ChangeLog -o -w $(distdir)/ChangeLog \) ; then \
98                 git --git-dir $(srcdir)/.git log | $(srcdir)/tools/git2cl/git2cl > $(distdir)/ChangeLog ; \
99         fi
100         for i in $$($(TCL_FILES)); do \
101                 j="$(distdir)/$(TCL_PATH)/$$i" && \
102                 mkdir -p "$$(dirname $$j)" && \
103                 $(INSTALL_DATA) $(srcdir)/$(TCL_PATH)/$$i $$j; \
104         done
106 install-data-hook:
107         for i in $$($(TCL_FILES)); do \
108                 j="$(DESTDIR)$(pkgdatadir)/scripts/$$i" && \
109                 mkdir -p "$$(dirname $$j)" && \
110                 $(INSTALL_DATA) $(srcdir)/$(TCL_PATH)/$$i $$j; \
111         done
113 uninstall-hook:
114         rm -rf $(DESTDIR)$(pkgdatadir)/scripts
116 distclean-local:
117         rm -rf Doxyfile doxygen
118         rm -f $(srcdir)/jimtcl/configure.gnu
120 DISTCLEANFILES = doxygen.log
122 METASOURCES = AUTO
124 BUILT_SOURCES =
125 CLEANFILES =
127 MAINTAINERCLEANFILES = \
128         %D%/INSTALL \
129         %D%/configure \
130         %D%/Makefile.in \
131         %D%/depcomp \
132         %D%/config.guess \
133         %D%/config.sub \
134         %D%/config.h.in \
135         %D%/config.h.in~ \
136         %D%/compile \
137         %D%/ltmain.sh \
138         %D%/missing \
139         %D%/aclocal.m4 \
140         %D%/install-sh \
141         %D%/texinfo.tex
143 include src/Makefile.am
144 include doc/Makefile.am