summaryrefslogtreecommitdiff
path: root/configure.in
diff options
context:
space:
mode:
authorSebastian Dransfeld <sd@tango.flipp.net>2007-11-10 12:17:07 +0000
committerSebastian Dransfeld <sd@tango.flipp.net>2007-11-10 12:17:07 +0000
commit1ec701e87e56b5574511857ebe86eb7064dd7994 (patch)
tree92f741930e7a9a846b6f407eb0405f152651901d /configure.in
parent57331eae88bcbdaf535a4cd53b4ae2ed5db9cb26 (diff)
Clean build system
SVN revision: 32534
Diffstat (limited to '')
-rw-r--r--configure.in218
1 files changed, 113 insertions, 105 deletions
diff --git a/configure.in b/configure.in
index 1261330..08fced2 100644
--- a/configure.in
+++ b/configure.in
@@ -46,83 +46,120 @@ AC_SUBST(PACKAGE_DATA_DIR)
46 46
47PKG_CHECK_MODULES([EVAS], evas) 47PKG_CHECK_MODULES([EVAS], evas)
48 48
49PCFLAGS=$CFLAGS 49dnl OpenGL GLEW
50CFLAGS="$EVAS_CFLAGS $CFLAGS" 50PKG_CHECK_EXISTS(evas-opengl-glew,
51 51 [
52have_glew_opengl="no" 52 AC_DEFINE(HAVE_EVAS_OPENGL_GLEW, 1, [Evas GL Glew Engine Support])
53AC_CHECK_HEADER(Evas_Engine_GL_Glew.h, 53 have_opengl_glew="yes"
54 [ AC_DEFINE(HAVE_EVAS_GL_GLEW, 1, [Evas GL Glew Engine Support]) 54 glew_libs="-lglew32 -lgdi32"
55 have_glew_opengl="yes" 55 ],
56 glew_libs="-lglew32 -lgdi32" ], 56 [ have_opengl_glew="no" ]
57 [ dummy=no ],
58 [ #include <Evas.h> ]
59) 57)
60 58AM_CONDITIONAL(BUILD_OPENGL_GLEW, test "x$have_opengl_glew" = "xyes")
61have_xlib_opengl="no" 59
62AC_CHECK_HEADER(Evas_Engine_GL_X11.h, 60dnl OpenGL X11
63 [ AC_DEFINE(HAVE_EVAS_GL, 1, [Evas GL Engine Support]) 61PKG_CHECK_EXISTS(evas-opengl-x11,
64 have_xlib_opengl="yes" ], 62 [
65 [ dummy=no ], 63 AC_DEFINE(HAVE_EVAS_OPENGL_X11, 1, [Evas GL X11 Engine Support])
66 [ #include <Evas.h> ] 64 have_opengl_x11="yes"
65 ],
66 [ have_opengl_x11="no" ]
67) 67)
68 68AM_CONDITIONAL(BUILD_OPENGL_X11, test "x$have_opengl_x11" = "xyes")
69have_xlib="no" 69
70AC_CHECK_HEADER(Evas_Engine_Software_X11.h, 70dnl Software X11
71 [ AC_DEFINE(HAVE_SOFTWARE_X11, 1, [Evas Software X11 Engine Support]) 71PKG_CHECK_EXISTS(evas-software-x11,
72 have_xlib="yes" ], 72 [
73 [ dummy=no ], 73 AC_DEFINE(HAVE_EVAS_SOFTWARE_X11, 1, [Evas Software X11 Engine Support])
74 [ #include <Evas.h> ] 74 have_software_x11="yes"
75 ],
76 [ have_software_x11="no" ]
75) 77)
76 78AM_CONDITIONAL(BUILD_SOFTWARE_X11, test "x$have_software_x11" = "xyes")
77have_xlib_render="no" 79
78AC_CHECK_HEADER(Evas_Engine_XRender_X11.h, 80dnl XRender X11
79 [ AC_DEFINE(HAVE_XRENDER_X11, 1, [Evas XRender X11 Engine Support]) 81PKG_CHECK_EXISTS(evas-xrender-x11,
80 have_xlib_render="yes" ], 82 [
81 [ dummy=no ], 83 AC_DEFINE(HAVE_EVAS_XRENDER_X11, 1, [Evas XRender X11 Engine Support])
82 [ #include <Evas.h> ] 84 have_xrender_x11="yes"
85 ],
86 [ have_xrender_x11="no" ]
83) 87)
84 88AM_CONDITIONAL(BUILD_XRENDER_X11, test "x$have_xrender_x11" = "xyes")
85have_xlib_16="no" 89
86AC_CHECK_HEADER(Evas_Engine_Software_16_X11.h, 90dnl Software 16bit X11
87 [ AC_DEFINE(HAVE_SOFTWARE_16_X11, 1, [Evas Software 16bit X11 Engine Support]) 91PKG_CHECK_EXISTS(evas-software-16-x11,
88 have_xlib_16="yes" ], 92 [
89 [ dummy=no ], 93 AC_DEFINE(HAVE_EVAS_SOFTWARE_16_X11, 1, [Evas Software 16bit X11 Engine Support])
90 [ #include <Evas.h> ] 94 have_software_16_x11="yes"
95 ],
96 [ have_software_16_x11="no" ]
91) 97)
92 98AM_CONDITIONAL(BUILD_SOFTWARE_16_X11, test "x$have_software_16_x11" = "xyes")
93have_ddraw="no" 99
94AC_CHECK_HEADER(Evas_Engine_Software_DDraw.h, 100# TODO: Check availability of libs
95 [ AC_DEFINE(HAVE_SOFTWARE_DDRAW, 1, [Evas Software DirectDraw Engine Support]) 101dnl DirectDraw
96 have_ddraw="yes" 102PKG_CHECK_EXISTS(evas-software-ddraw,
97 ddraw_libs="-lddraw -ldxguid" ], 103 [
98 [ dummy=no ], 104 AC_DEFINE(HAVE_EVAS_SOFTWARE_DDRAW, 1, [Evas Software DirectDraw Engine Support])
99 [ #include <Evas.h> ] 105 have_software_ddraw="yes"
106 ddraw_libs="-lddraw -ldxguid"
107 ],
108 [ have_software_ddraw="no" ]
100) 109)
101 110AM_CONDITIONAL(BUILD_SOFTWARE_DDRAW, test "x$have_software_ddraw" = "xyes")
102have_ddraw_16="no" 111
103AC_CHECK_HEADER(Evas_Engine_Software_16_DDraw.h, 112# TODO: Check availability of libs
104 [ AC_DEFINE(HAVE_SOFTWARE_16_DDRAW, 1, [Evas 16bit Software DirectDraw Engine Support]) 113dnl 16bit DirectDraw
105 have_ddraw_16="yes" 114PKG_CHECK_EXISTS(evas-software-16-ddraw,
106 ddraw_16_libs="-lddraw -ldxguid" ], 115 [
107 [ dummy=no ], 116 AC_DEFINE(HAVE_EVAS_SOFTWARE_16_DDRAW, 1, [Evas Software 16bit DirectDraw Engine Support])
108 [ #include <Evas.h> ] 117 have_software_16_ddraw="yes"
118 ddraw_libs="-lddraw -ldxguid"
119 ],
120 [ have_software_16_ddraw="no" ]
109) 121)
110 122AM_CONDITIONAL(BUILD_SOFTWARE_16_DDRAW, test "x$have_software_16_ddraw" = "xyes")
111have_d3d="no" 123
112AC_CHECK_HEADER(Evas_Engine_Direct3D.h, 124# TODO: Check availability of libs
113 [ AC_DEFINE(HAVE_DIRECT3D, 1, [Evas Direct3D Engine Support]) 125dnl Direct3D
114 have_d3d="yes" 126PKG_CHECK_EXISTS(evas-direct3d,
115 d3d_libs="-ld3d9 -ld3dx9d" ], 127 [
116 [ dummy=no ], 128 AC_DEFINE(HAVE_EVAS_DIRECT3D, 1, [Evas Direct3D Engine Support])
117 [ #include <Evas.h> ] 129 have_direct3d="yes"
130 d3d_libs="-ld3d9 -ld3dx9d"
131 ],
132 [ have_direct3d="no" ]
133)
134AM_CONDITIONAL(BUILD_DIRECT3D, test "x$have_direct3d" = "xyes")
135
136dnl Software SDL
137PKG_CHECK_EXISTS(evas-software-sdl,
138 [
139 AC_DEFINE(HAVE_EVAS_SOFTWARE_SDL, 1, [Evas Software SDL Engine Support])
140 have_software_sdl="yes"
141 ],
142 [ have_direct3d="no" ]
118) 143)
144AM_CONDITIONAL(BUILD_SOFTWARE_SDL, test "x$have_software_sdl" = "xyes")
145
146if test "x$have_software_x11" = "xyes" -o "x$have_software_16_x11" = "xyes" -o "x$have_xrender_x11" = "xyes" -o "x$have_opengl_x11" = "xyes"; then
147 AC_PATH_XTRA
148 AC_CHECK_HEADERS(X11/Xlib.h X11/Xutil.h,
149 [ have_x11="yes" ],
150 [ have_x11="no" ])
151 x_dir=${x_dir:-/usr/X11R6}
152 x_cflags=${x_cflags:--I${x_includes:-$x_dir/include}}
153 x_libs="${x_libs:--L${x_libraries:-$x_dir/lib}} -lX11 -lXext"
154fi
155AM_CONDITIONAL(BUILD_X11, test "x$have_x11" = "xyes")
119 156
120if test "x$have_xlib" = "xyes" -o "x$have_xlib_16" = "xyes" -o "x$have_xlib_render" = "xyes" -o "x$have_xlib_opengl" = "xyes" ; then 157if test "x$have_software_sdl" = "xyes"; then
121AC_PATH_XTRA 158 PKG_CHECK_MODULES([SDL], sdl,
122x_dir=${x_dir:-/usr/X11R6} 159 [ have_sdl="yes" ],
123x_cflags=${x_cflags:--I${x_includes:-$x_dir/include}} 160 [ have_sdl="no" ])
124x_libs="${x_libs:--L${x_libraries:-$x_dir/lib}} -lX11 -lXext"
125fi 161fi
162AM_CONDITIONAL(BUILD_SDL, test "x$have_sdl" = "xyes")
126 163
127AC_SUBST(x_cflags) 164AC_SUBST(x_cflags)
128AC_SUBST(x_libs) 165AC_SUBST(x_libs)
@@ -131,35 +168,6 @@ AC_SUBST(ddraw_16_libs)
131AC_SUBST(d3d_libs) 168AC_SUBST(d3d_libs)
132AC_SUBST(glew_libs) 169AC_SUBST(glew_libs)
133 170
134#######################################
135## SDL
136AC_ARG_WITH(sdl-config, [ --with-sdl-config=SDL_CONFIG use sdl-config specified],
137[ SDL_CONFIG=$withval;
138 echo "using "$SDL_CONFIG" for sdl-config"; ],
139[ if test -z "$SDL_CONFIG"; then
140 AC_PATH_PROG(SDL_CONFIG, "sdl-config", "", $PATH)
141 fi
142])
143if test -z "$SDL_CONFIG" ; then SDL_CONFIG="sdl-config"; fi
144
145sdl_cflags=""
146sdl_libs=""
147
148have_sdl="no"
149AC_CHECK_HEADER(Evas_Engine_SDL.h,
150 [ AC_DEFINE(HAVE_SOFTWARE_SDL, 1, [Evas Software SDL Support])
151 have_sdl="yes"
152 sdl_cflags=`$SDL_CONFIG --cflags`
153 sdl_libs=`$SDL_CONFIG --libs` ],
154 [ dummy=no ],
155 [ #include <Evas.h> ]
156)
157
158AC_SUBST(sdl_cflags)
159AC_SUBST(sdl_libs)
160
161CFLAGS=$PCFLAGS
162
163AC_OUTPUT([ 171AC_OUTPUT([
164Makefile 172Makefile
165src/Makefile 173src/Makefile
@@ -171,15 +179,15 @@ echo
171echo " $PACKAGE $VERSION" 179echo " $PACKAGE $VERSION"
172echo 180echo
173echo " Engines:" 181echo " Engines:"
174echo " Software Xlib................: ${have_xlib}" 182echo " Software X11.................: ${have_software_x11}"
175echo " Software Xlib 16 bits........: ${have_xlib_16}" 183echo " Software X11 16 bits.........: ${have_software_16_x11}"
176echo " X Render Xlib................: ${have_xlib_render}" 184echo " X Render X11.................: ${have_xrender_x11}"
177echo " Open GL Glew.................: ${have_glew_opengl}" 185echo " Open GL X11..................: ${have_opengl_x11}"
178echo " Open GL Xlib.................: ${have_xlib_opengl}" 186echo " Open GL Glew.................: ${have_opengl_glew}"
179echo " Software DirectDraw..........: ${have_ddraw}" 187echo " Software DirectDraw..........: ${have_software_ddraw}"
180echo " Software DirectDraw 16 bits..: ${have_ddraw}" 188echo " Software DirectDraw 16 bits..: ${have_software_16_ddraw}"
181echo " Direct3D.....................: ${have_d3d}" 189echo " Direct3D.....................: ${have_direct3d}"
182echo " Software SDL.................: ${have_sdl}" 190echo " Software SDL.................: ${have_software_sdl}"
183echo 191echo
184echo " Installation:" 192echo " Installation:"
185echo " prefix.......................: ${prefix}" 193echo " prefix.......................: ${prefix}"