File: configure.in

package info (click to toggle)
gengameng 4.1-7
  • links: PTS
  • area: main
  • in suites: etch, etch-m68k
  • size: 1,468 kB
  • ctags: 177
  • sloc: sh: 8,342; cpp: 935; makefile: 110
file content (95 lines) | stat: -rw-r--r-- 2,231 bytes parent folder | download | duplicates (2)
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
# $Id: configure.in,v 1.7 2002/03/31 21:57:19 sarrazip Exp $
# configure.in for the gengameng library

AC_INIT(src/gengameng/GameEngine.h)

INTERFACE_NO=4
RELEASE_NO=1
INTERFACE_AGE=0

AC_SUBST(INTERFACE_NO)
AC_SUBST(RELEASE_NO)
AC_SUBST(INTERFACE_AGE)

# 3.1: Full screen capability with GENGAMENG_FULL_SCREEN environment variable
# 4.0: Ability to specify other SDL_Surface objects in which to draw;
#      support for side scrolling; must now #include <gengameng/*.h>.
# 4.1: gengameng.m4 removes -rpath directive from $SDL_LIBS

AC_CANONICAL_TARGET
# This line added before AM_INIT_AUTOMAKE to avoid this warning:
# AC_ARG_PROGRAM was called before AC_CANONICAL_TARGET
# @sarrazip 20020330

AM_INIT_AUTOMAKE(gengameng, $INTERFACE_NO.$RELEASE_NO)

# Checks for programs.
AC_PROG_CXX
AC_LANG_CPLUSPLUS

AC_DISABLE_STATIC
# This macro changes the default behavior of AC_PROG_LIBTOOL so
# that static libraries will not be built by default.
# This avoids compiling every file twice.
# The user can still override this new default by using `--enable-static'.

AM_PROG_LIBTOOL
# This must come after AC_DISABLE_STATIC.



# Checks for libraries.

# Use C mode for SDL tests:
AC_LANG_C

AM_PATH_SDL(1.2.0)  # typically found in /usr/share/aclocal/sdl.m4

# Remove any -rpath option from SDL_LIBS, so as not to hardcode
# the library path into the executable file:
#

SDL_LIBS=`echo $SDL_LIBS | sed ['s:-Wl,-rpath,[^ ]*: :g]'`

# AM_PATH_SDL does not stop if SDL is not found; therefore:
if test "_$SDL_LIBS" = _; then
	AC_MSG_ERROR([SDL not found])
fi

# We also need the SDL_image library:
AM_TRY_LINK_SDL_IMAGE

# Back to C++ mode after SDL tests.
AC_LANG_CPLUSPLUS


GENGAMENG_CFLAGS=""
GENGAMENG_LIBS="-lgengameng"
if test "$prefix" = NONE; then
	GENGAMENG_CFLAGS="-I/usr/local/include"
	GENGAMENG_LIBS="-L/usr/local/lib $GENGAMENG_LIBS"
else
	GENGAMENG_CFLAGS="-I$prefix/include"
	GENGAMENG_LIBS="-L$prefix/lib $GENGAMENG_LIBS"
fi

AC_SUBST(GENGAMENG_CFLAGS)
AC_SUBST(GENGAMENG_LIBS)


pkgincludedir=$includedir/$package
AC_SUBST(pkgincludedir)


AC_OUTPUT([
	Makefile
	gengameng.spec
	gengameng-config
	macros/Makefile
	src/Makefile
	src/gengameng/Makefile
	src/images/Makefile
	examples/Makefile
])

chmod 755 gengameng-config