-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathconfigure.ac
85 lines (68 loc) · 2.23 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
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
AC_INIT([qgames], [2.9.9], [silvioq@gmail.com])
AC_DEFINE([QG_MAJOR_VERSION],[2], Major version)
AC_DEFINE([QG_MINOR_VERSION],[9], Minor version)
AC_DEFINE([QG_REV_VERSION], [9], Revision version)
AM_INIT_AUTOMAKE
AC_PROG_CC
AC_PROG_YACC
AC_PROG_LEX
AC_CONFIG_MACRO_DIR([m4])
LT_INIT([dlopen win32-dll])
AC_PROG_LIBTOOL
AC_CONFIG_SRCDIR([configure.ac])
AC_CONFIG_HEADERS([config.h]) # not even really needed
AC_PROG_CC # or AC_PROG_CXX
AC_CHECK_LIB(readline,readline)
AC_CHECK_LIB(ncurses,initscr,[CURSES_LIBS="-lncurses"])
AC_CHECK_LIB(ncursesw,initscr,[CURSES_LIBS="-lncursesw"])
AC_CHECK_HEADERS([ncurses.h])
AC_CHECK_HEADERS([gd.h])
AC_CHECK_LIB(gd,gdImageCreate,[GD_LIBS="-lgd"],[
echo "--------------------------------------------"
echo " Cuidado! no esta instalado GD"
echo "--------------------------------------------" ]
)
AC_CHECK_HEADERS([png.h])
AC_CHECK_LIB(png,png_read_info,[PNG_LIBS="-lpng"])
gl_VISIBILITY
AC_SUBST([CFLAG_VISIBILITY],[-fvisibility=hidden])
AC_SUBST([CURSES_LIBS])
AC_SUBST([GD_LIBS])
AC_SUBST([PNG_LIBS])
AC_SUBST([gamesdir], ["\$(pkgdatadir)/games"])
AC_SUBST([imagesdir], ["\$(pkgdatadir)/images"])
if test x"${ac_cv_lib_png_png_read_info}" = xyes; then
if test x"${ac_cv_lib_gd_gdImageCreate}" = xyes; then
AC_DEFINE([GRAPH_ENABLED], [1], Graficos habilitados)
fi
fi
#
# if test x"${ac_cv_lib_ncursesw_ncursesw}" = xyes; then
# CURSES_LIBS="-lncursesw"
# else
# if test x"${ac_cv_lib_ncurses_ncurses}" = xyes; then
# CURSES_LIBS="-lncurses"
# fi
# fi
# if test x"${ac_cv_lib_readline_readline}" = xno; then
# AC_MSG_ERROR(libreadline not found)
# fi
AC_DEFINE([QGAMES_SERVERNAME],["qgames.com.ar"], ["Nombre del servidor a usar"])
# AC_SUBST(DEPENDENCIES,["\$(top_builddir)/parser/libqgames-parser.a \
# \$(top_builddir)/lib/libqgames.a \
# \$(top_builddir)/parser/libpgn-parser.a \
# \$(top_builddir)/vm/libqcode.a"])
AC_SUBST(DEPENDENCIES,["\$(top_builddir)/lib/libqgames.la"])
AC_CONFIG_FILES(
[Makefile
vm/Makefile
parser/Makefile
src/Makefile
lib/Makefile
bin/Makefile
test/Makefile
test/bin/Makefile
test/qgtest/Makefile
tools/Makefile
])
AC_OUTPUT