File: configure.in

package info (click to toggle)
gnuplot 4.0.0-5
  • links: PTS
  • area: main
  • in suites: etch, etch-m68k
  • size: 9,396 kB
  • ctags: 6,623
  • sloc: ansic: 63,562; lisp: 5,011; cpp: 970; sh: 900; makefile: 756; objc: 647; asm: 539; csh: 297; awk: 235; pascal: 192; perl: 44
file content (103 lines) | stat: -rw-r--r-- 2,711 bytes parent folder | download | duplicates (5)
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
97
98
99
100
101
102
103
# $HEader$

AC_INIT(dot.el)
AC_PREREQ(2.52)

PACKAGE=gnuplot-mode
GPM_MAJOR=0
GPM_MINOR=6
GPM_REVISION=0
AM_INIT_AUTOMAKE([$PACKAGE], [$GPM_MAJOR.$GPM_MINOR.$GPM_REVISION])

AC_SET_MAKE
AC_PROG_INSTALL
AM_PATH_LISPDIR

EMACS=`basename $EMACS`

AC_CHECK_PROGS(DVIPS, dvips, no)
AC_CHECK_PROGS(LATEX, latex latex2e, no)
AC_PATH_PROG(MAKEINFO, makeinfo, no)

dnl for pdf format docs
AC_CHECK_PROGS(PDFLATEX, pdflatex, no)

if test "$EMACS" = no; then
  LISPFILES=noelcs
  INSTALL_LISP=install-nolisp
else
  LISPFILES=elcs
  INSTALL_LISP=install-lisp
fi

AC_ARG_WITH(lisp-files,dnl
[  --without-lisp-files    do not build emacs lisp files],
  [if test "$with_lisp_files" = no; then
     LISPFILES=noelcs
     INSTALL_LISP=install-nolisp
   fi])

# need to copy some stuff if we compile outside the source disrectory
if test ! -f ./gnuplot.el ; then
  # all except dot.el
  AC_MSG_RESULT([Compiling outside source directory - copying needed .el files])
  cp ${srcdir}/gnuplot.el ${srcdir}/gnuplot-gui.el ${srcdir}/info-look.20.2.el \
     ${srcdir}/info-look.20.3.el .
  cp ${srcdir}/gpelcard.tex .
fi

INFO_LOOK_ELC=info-look.elc
dnl
dnl There are many possibilities for info-look:
dnl
dnl     EMACS version            use
dnl  -----------------------------------------
dnl   Emacs or XEmacs 19    info-look.20.2.el
dnl   Emacs 20.2 or less    info-look.20.2.el
dnl   Emacs 20.3            nothing
dnl   XEmacs 20+            info-look.20.3.el
dnl
dnl want to use my modified version even if 20.2 is installed because a
dnl bug is fixed
dnl
dnl the first 6 lines attempt to ascertain the version number of
dnl $(EMACS), then multiply by 100 to convert it to an integer for the
dnl sake of the integer comparisons in the following lines.  Is this a
dnl hassle, or what?!
dnl
AC_MSG_CHECKING([for emacs version])
if test "$EMACS" = no; then
  emacs_version="none found"
else
  emacs_version=`$EMACS --version |sed 's/^GNU //' |awk '/Emacs [[12]]/{print $2}'`
fi
AC_MSG_RESULT([$emacs_version])
vnum=`echo $emacs_version |awk -F\. '{print 100*$1+$2}'`

AC_MSG_CHECKING([whether info-look.el is needed])
if test "$EMACS" = emacs ; then
  if test "$vnum" -ge 2030 ; then
    info_look="not needed with emacs $emacs_version"
    INFO_LOOK_ELC=
  else
    info_look="using info-look.20.2.el"
    cp info-look.20.2.el info-look.el
  fi
elif test "$EMACS" = xemacs ; then
  if test "$vnum" -ge 2000 ; then
    info_look="using info-look.20.3.el"
    cp info-look.20.3.el info-look.el
  else
    info_look="using info-look.20.2.el"
    cp info-look.20.2.el info-look.el
  fi
else
  info_look="using none"
fi
AC_MSG_RESULT([$info_look])

AC_SUBST(INFO_LOOK_ELC)
AC_SUBST(LISPFILES)
AC_SUBST(INSTALL_LISP)

AC_OUTPUT(Makefile)