source: rtems/doc/configure.ac @ 3fe5d01

4.115
Last change on this file since 3fe5d01 was 94ca070, checked in by Joel Sherrill <joel.sherrill@…>, on 02/22/13 at 01:19:48

doc: Support texi2any and texi2html

This was tested with texi2html-1.82-5.1.el6.noarch and
a locally built texinfo 5.0. These are completely different
implementations and require different invocations.

The Makefile dependencies appear to work but are likely not
perfect at this point. The key point is that the autoconf
probe detects which to use and responds accordingly with
preference given to texi2any.

  • Property mode set to 100644
File size: 3.5 KB
Line 
1dnl Process this file with autoconf to produce a configure script.
2
3AC_PREREQ([2.69])
4
5AC_INIT([rtems-doc],[_RTEMS_VERSION],[http://www.rtems.org/bugzilla])
6AC_CONFIG_SRCDIR([project.am])
7RTEMS_TOP([..])
8
9AM_INIT_AUTOMAKE([no-define foreign 1.12.2])
10AM_MAINTAINER_MODE
11
12RTEMS_ENABLE_RPMPREFIX
13
14AC_ARG_ENABLE(html,
15[  --disable-html          disable html support ],
16[case $enableval in
17yes) ;;
18no) ;;
19*) AC_MSG_ERROR("invalid value");;
20esac],
21[enable_html="yes"]
22)
23
24AC_ARG_ENABLE(dvi,
25[  --disable-dvi           disable dvi support ],
26[case $enableval in
27yes) ;;
28no) ;;
29*) AC_MSG_ERROR("invalid value");;
30esac],
31[enable_dvi="yes"]
32)
33
34AC_ARG_ENABLE(pdf,
35[  --disable-pdf           disable pdf support ],
36[case $enableval in
37yes) ;;
38no) ;;
39*) AC_MSG_ERROR("invalid value");;
40esac],
41[enable_pdf="yes"]
42)
43
44AC_ARG_ENABLE(ps,
45[  --disable-ps            disable ps support ],
46[case $enableval in
47yes) ;;
48no) ;;
49*) AC_MSG_ERROR("invalid value");;
50esac],
51[enable_ps="yes"]
52)
53
54AC_ARG_ENABLE(papersize,
55[  --enable-papersize=[letter|a4|]    set papersize [default:system defaults]],
56[case $enableval in
57a4) papersize=a4 ;;
58letter) papersize=letter ;;
59yes) papersize= ;;
60no) papersize= ;;
61*) AC_MSG_ERROR([Invalid papersize])
62;;
63esac],
64[papersize=]
65)
66
67pkgdocdir="\$(datadir)/rtems"
68AC_SUBST(pkgdocdir)
69
70htmldir="\$(pkgdocdir)/html"
71AC_SUBST(htmldir)
72
73dnl Checks for programs.
74AC_PROG_LN_S
75
76AC_CHECK_PROGS(PERL,perl)
77
78AC_CHECK_PROGS(TEXI2ANY,texi2any)
79AC_SUBST(TEXI2ANY)
80AM_CONDITIONAL(USE_TEXI2ANY,
81  test "$enable_html" = "yes" \
82    && test x"$TEXI2ANY" != x"")
83
84AC_CHECK_PROGS(TEXI2HTML,texi2html)
85AC_SUBST(TEXI2HTML)
86AM_CONDITIONAL(USE_TEXI2HTML,
87  test "$enable_html" = "yes" \
88    && test x"$TEXI2ANY" = x"" \
89    && test x"$TEXI2HTML" != x"")
90
91AC_CHECK_PROGS(GS,gs)
92AM_CONDITIONAL(GS,test x"$GS" != x"")
93
94AC_CHECK_PROGS(TEXI2DVI,texi2dvi)
95AM_CONDITIONAL(TEXI2DVI,test x"$TEXI2DVI" != x"")
96
97AC_CHECK_PROGS(EPSTOPDF,epstopdf)
98AM_CONDITIONAL(EPSTOPDF,
99  test "$enable_pdf" = "yes" \
100    && test x"$EPSTOPDF" != x"" )
101
102AC_CHECK_PROGS(TEXI2PDF,texi2pdf)
103AM_CONDITIONAL(TEXI2PDF,
104  test "$enable_pdf" = "yes" \
105    && test x"$TEXI2PDF" != x"")
106
107AM_CONDITIONAL(USE_HTML,
108  test "$enable_html" = "yes" \
109     && test x"PERL" != x"" )
110
111AM_CONDITIONAL(USE_DVI,
112  test "$enable_dvi" = "yes" \
113    && test x"$TEXI2DVI" != x"" )
114
115AM_CONDITIONAL(USE_PS,
116  test "$enable_ps" = "yes" \
117    && test x"$TEXI2DVI" != x"" )
118
119AM_CONDITIONAL(USE_PDF,
120  test "$enable_pdf" = "yes" \
121    && test x"$TEXI2DVI" != x"" \
122    && test x"$TEXI2PDF" != x"" )
123
124case $papersize in
125a4)
126  TEXI2DVI="${TEXI2DVI} --texinfo=@afourpaper"
127  TEXI2PDF="${TEXI2PDF} --texinfo=@afourpaper"
128  DVIPS="dvips -t a4"
129;;
130letter)
131  DVIPS="dvips -t letter"
132  ;;
133*)
134  DVIPS="dvips"
135;;
136esac
137AC_SUBST(DVIPS)
138
139BMENU2='$(top_builddir)/tools/bmenu/bmenu2'
140AC_SUBST(BMENU2)
141
142dnl Checks for libraries.
143
144dnl Checks for header files.
145
146dnl Checks for typedefs, structures, and compiler characteristics.
147
148dnl Checks for library functions.
149
150AC_CONFIG_SUBDIRS(tools)
151
152AC_CONFIG_FILES([Makefile],[],[
153test -d common || mkdir common
154cat << EOF > common/rtems.sed~
155:t
156s/@RTEMSAPI@/_RTEMS_API/;t t
157s,@RTEMSPREFIX@,$prefix,;t t
158s,@RTEMSRPMPREFIX@,$rpmprefix,;t t
159EOF
160_RTEMS_UPDATE_CONDITIONAL([common/rtems.sed],[common/rtems.sed~])
161])
162
163AC_CONFIG_FILES([
164index.html
165develenv/Makefile
166user/Makefile
167bsp_howto/Makefile])
168
169AC_CONFIG_FILES([
170porting/Makefile
171networking/Makefile
172posix_users/Makefile
173posix1003.1/Makefile
174filesystem/Makefile
175ada_user/Makefile
176started/Makefile
177relnotes/Makefile
178new_chapters/Makefile
179cpu_supplement/Makefile
180shell/Makefile
181texi2html_init
182texi2any_init
183])
184AC_OUTPUT
Note: See TracBrowser for help on using the repository browser.