File: configure.ac

package info (click to toggle)
flatzebra 0.2.0-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 2,368 kB
  • sloc: cpp: 5,164; sh: 4,246; makefile: 182
file content (83 lines) | stat: -rw-r--r-- 2,346 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
82
83
# configure.ac for the FlatZebra library

AC_PREREQ(2.54)

AC_INIT(flatzebra, 0.2.0)
AC_CONFIG_SRCDIR(src/flatzebra/GameEngine.h)
AC_CONFIG_MACRO_DIRS([macros])
AM_INIT_AUTOMAKE
API=`echo $VERSION | cut -d . -f -2`; AC_SUBST(API)
RELEASE=`echo $VERSION | cut -d . -f 3`; AC_SUBST(RELEASE)

PACKAGE_FULL_NAME="FlatZebra"
PACKAGE_SUMMARY_EN="Small engine for 2D video games like BurgerSpace"
PACKAGE_SUMMARY_FR="Petit moteur pour jeux vidéo 2D comme BurgerSpace"
AC_SUBST(PACKAGE_FULL_NAME)
AC_SUBST(PACKAGE_SUMMARY_EN)
AC_SUBST(PACKAGE_SUMMARY_FR)


# Minimal versions of the required libraries.

SDL2_MINVER=2.0.10; AC_SUBST(SDL2_MINVER)
SDL2_IMAGE_MINVER=2.0.5; AC_SUBST(SDL2_IMAGE_MINVER)
SDL2_MIXER_MINVER=2.0.4; AC_SUBST(SDL2_MIXER_MINVER)
SDL2_GFX_MINVER=1.0.2; AC_SUBST(SDL2_GFX_MINVER)
SDL2_TTF_MINVER=2.0.15; AC_SUBST(SDL2_TTF_MINVER)


# Checks for programs.

AC_PROG_CXX
AC_COMPILE_WARNINGS
AC_LANG_CPLUSPLUS

# 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'.
AC_DISABLE_STATIC

# This must come after AC_DISABLE_STATIC.
AM_PROG_LIBTOOL


# Check for SDL2.
PKG_CHECK_MODULES(SDL2, sdl2 >= $SDL2_MINVER SDL2_image >= $SDL2_IMAGE_MINVER SDL2_mixer >= $SDL2_MIXER_MINVER SDL2_gfx >= SDL2_GFX_MINVER SDL2_ttf >= $SDL2_TTF_MINVER)


# Check for getopt_long() but don't fail if it is not available:
GETOPT_LONG


# Try to add -Wsuggest-override. See macros/cxx_suggest_override.m4.
CXX_SUGGEST_OVERRIDE


# Option to disable the sound engine tests.
AC_ARG_ENABLE([sound-engine-test],
[  --enable-sound-engine-test     have the check target test the sound engine (default: no)],
[
    # Option given: $enableval is either yes or no.
    test_sound_engine=$enableval
],
[
    # Option not given. Set the default.
    # The tests are not run by default because conditions of automated operation
    # are not expected to allow reliable sound tests.
    test_sound_engine=no
])

AC_MSG_RESULT([sound engine to be tested by check target: $test_sound_engine])
AM_CONDITIONAL(TEST_SOUND_ENGINE, [test "$test_sound_engine" = yes])


# Generate files.
AC_CONFIG_FILES([
	Makefile
	flatzebra.spec
	flatzebra-0.2.pc
	src/Makefile
	src/flatzebra/Makefile
])
AC_OUTPUT