[go: up one dir, main page]

File: configure.in

package info (click to toggle)
sabre 0.2.3-3
  • links: PTS
  • area: main
  • in suites: slink
  • size: 4,876 kB
  • ctags: 5,106
  • sloc: cpp: 25,581; ansic: 7,439; sh: 2,063; makefile: 92
file content (81 lines) | stat: -rw-r--r-- 2,027 bytes parent folder | download
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
dnl Process this file with autoconf to produce a configure script.

dnl This is part of Dan Hammer's SABRE Fighter Plane Simulator
dnl portions donated by Antti Barck
dnl
dnl Here are the top level configuration parameters

AC_INIT(Makefile.in)

dnl a quick hack for automake 2.12 to cope automake 1.2 
AUTOMAKE=automake
AUTOCONF=autoconf
AC_SUBST(AUTOMAKE)
AC_SUBST(AUTOCONF)

dnl initialize version and package information to keep automake happy
. VERSION
VERSION=$THE_VERSION
PACKAGE=$PACKAGE_NAME
AC_SUBST(VERSION)
AC_SUBST(PACKAGE)

dnl echo version number to sources
AC_DEFINE_UNQUOTED(VERSION,"$VERSION")

 if test "$CFLAGS" = "";
 then
  AC_CANONICAL_HOST
  AC_MSG_CHECKING(choosing CFLAGS)
  cflaggedcflags=$(./cflags $host_cpu $host_os)
  AC_MSG_RESULT($cflaggedcflags)
 if test "$cflaggedcflags" != "(default)";
   then
    CFLAGS="$cflaggedcflags"
    CXXFLAGS="$cflaggedcflags"
  fi
 fi  

dnl scan various programs
AC_ARG_PROGRAM
AC_PROG_MAKE_SET
AC_PROG_INSTALL
AC_PROG_CC
AC_PROG_CXX
AC_PROG_RANLIB

dnl these libraries are really **needed** so dont pass on failure!

dnl the problem here is that these testes should be configure in source 
dnl subdirs that needs those libs
dnl unfortunately I have not succeeded to use AC_CONFIG_SUBDIRS with
dnl automake 1.2 / autoconf 2.12 combination :-(
dnl meanwhile we produce lots of unnecessary flags...

AC_CHECK_LIB(ncurses, main, ,
   AC_MSG_ERROR(Cannot find Ncurses (-lncurses). please check out your system setup.))
AC_CHECK_LIB(vga, main, ,
   AC_MSG_ERROR(Cannot find SVGAlib (-lvga). please check out your system setup.))
AC_CHECK_LIB(vgagl, main, ,
   AC_MSG_ERROR(Cannot find SVGAlib (-lvgagl). please check out your system setup.))
AC_CHECK_LIB(m, main, ,
   AC_MSG_ERROR(Cannot find mathlib (-lm). please check out your system setup.))

dnl produce these file after configure
AC_OUTPUT(Makefile lib/Makefile lib/tzp/Makefile lib/fonts/Makefile libzip/Makefile gdev/Makefile src/Makefile dialogsrc/Makefile doc/Makefile scenarios/Makefile)