-
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathconfigure.ac
67 lines (54 loc) · 1.97 KB
/
configure.ac
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
# -*- Autoconf -*-
# Process this file with autoconf to produce a configure script.
AC_PREREQ([2.63])
AC_INIT([hello-emacsy], [0.1.1], [[email protected]])
AC_CONFIG_AUX_DIR([support/build-aux])
# We're going to use GNUMake and we're going to like it.
AM_INIT_AUTOMAKE([-Wall foreign -Wno-portability])
AM_EXTRA_RECURSIVE_TARGETS([run show-doc])
AC_CONFIG_MACRO_DIR([support/m4])
# Checks for programs.
AC_PROG_CC_C_O
# CXX required for OpenGL, GL, and GLUT libraries.
AC_PROG_CXX
AC_PROG_LIBTOOL
AX_CHECK_NOWEB
AC_PATH_PROG([PERL], [perl])
AC_SUBST([PERL])
AC_PATH_PROG([BASH], [bash])
AC_SUBST([BASH])
AC_PATH_PROG([guile_snarf], guile-snarf)
AC_SUBST(guile_snarf)
# Checks for libraries.
PKG_CHECK_MODULES([GUILE], [guile-2.0])
PKG_CHECK_MODULES([EMACSY], [emacsy])
AC_SUBST(EMACSY_MODULE, "`pkg-config emacsy --variable=moduledir || echo $EMACSY_MODULE`")
dnl AX_CHECK_GL* doesn't respect --with-gl=nox argument :(
AC_CANONICAL_HOST
AS_CASE([${host}],
[*-darwin*],
[AC_SUBST(GL_LDFLAGS, ["-framework OpenGL"])
AC_SUBST(GLUT_LDFLAGS, ["-framework GLUT"])
AC_SUBST(GLU_LDFLAGS, [])],
[AX_CHECK_GLUT])
# Checks for header files.
AC_HEADER_STDC
AC_CHECK_HEADERS([stdio.h])
# Checks for typedefs, structures, and compiler characteristics.
# Checks for library functions.
AC_CHECK_FUNCS([puts])
AC_SUBST(ENV, ['${top_builddir}/bin/env'])
AC_SUBST(imagesdir, ['${top_srcdir}/support/images'])
AC_SUBST(automakedir, ['${top_srcdir}/support/automake'])
pdflatex="TEXINPUTS=${imagesdir}: $pdflatex";
# Output files.
AC_CONFIG_HEADERS([src/config.h])
AC_CONFIG_FILES([ Makefile
bin/Makefile
src/Makefile
tests/Makefile
], [])
AC_CONFIG_FILES([ tests/works-without-noweb.sh ], [chmod +x tests/works-without-noweb.sh])
AC_CONFIG_FILES([bin/env], [chmod a+x bin/env])
AC_CONFIG_FILES([bin/warn-notangle], [chmod a+x bin/warn-notangle])
AC_OUTPUT