Changeset 2983 in orxonox.OLD for orxonox/branches/osX/configure.ac
- Timestamp:
- Nov 25, 2004, 1:39:02 PM (19 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
orxonox/branches/osX/configure.ac
r2978 r2983 2 2 # Process this file with autoconf to produce a configure script. 3 3 4 AC_PREREQ(2.56)4 #AC_PREREQ(2.56) 5 5 AC_INIT(orxonox, 0.1-pre-alpha, orxonox-dev@mail.datacore.ch) 6 7 # Detect the canonical host and target build environment. 8 AC_CANONICAL_BUILD 9 AC_CANONICAL_HOST 10 AC_CANONICAL_TARGET 11 12 6 13 AM_INIT_AUTOMAKE 7 14 … … 12 19 # Checks for programs. 13 20 AC_PROG_CXX 14 AC_PROG_CC15 16 17 18 21 AC_HEADER_STDC 19 22 … … 21 24 22 25 AC_MSG_CHECKING([for System]) 23 case `uname` in 26 ## checking for openGL-environment and other sys-specific parameters 27 case "$target" in 24 28 ### WINDOWS ### 25 * MINGW*)29 *-*-mingw32*) 26 30 echo "mingw-WINDOWS detected" 27 31 … … 64 68 fi 65 69 66 67 70 # checking for mingw32 68 71 AC_CHECK_LIB([mingw32], [main], FOUND_mingw32=yes) … … 77 80 AC_CHECK_LIB([sdlmain], [main], FOUND_sdlmain=yes) 78 81 if test "$FOUND_sdlmain" = "yes" ; then 79 80 else 81 82 83 84 85 82 LIBS="$LIBS -lsdlmain" 83 else 84 echo "------------------" 85 echo "SDL library not found." 86 echo "please install the SDL library, which can be found at http://www.libsdl.org" 87 echo "------------------" 88 exit 1 86 89 fi 87 90 AC_CHECK_LIB([sdl], [main], FOUND_sdl=yes) 88 91 if test "$FOUND_sdl" = "yes" ; then 89 LIBS="$LIBS -lsdl" 90 else 91 echo "------------------" 92 echo "SDL library not found." 93 echo "please install the SDL library, which can be found at http://www.libsdl.org" 94 echo "------------------" 95 exit -1 96 fi 92 LIBS="$LIBS -lsdl" 93 else 94 echo "------------------" 95 echo "SDL library not found." 96 echo "please install the SDL library, which can be found at http://www.libsdl.org" 97 echo "------------------" 98 exit -1 99 fi 100 97 101 98 102 ;; 99 103 100 104 ### LINUX ### 101 * Linux*)105 *-*-linux*) 102 106 echo "Linux detected" 103 107 … … 135 139 fi 136 140 141 ## checking for SDL 142 SDL_VERSION=1.2.7 143 AM_PATH_SDL($SDL_VERSION, 144 :, 145 AC_MSG_ERROR([*** SDL version $SDL_VERSION not found!]) 146 ) 147 CXXFLAGS="$CXXFLAGS $SDL_CFLAGS" 148 LIBS="$LIBS $SDL_LIBS" 149 ;; 150 151 ### OS X ### 152 *Darwin*) 153 echo "OS X detected" 154 155 osX="yes" 156 157 # checking gl header 158 AC_CHECK_HEADERS(OpenGL/gl.h ,, 159 [AC_MSG_ERROR([cannot find opengl headers]) ]) 160 # cheking for GLU-header 161 AC_CHECK_HEADERS(OpenGL/glu.h ,, 162 [AC_MSG_ERROR([cannot find opengl headers]) ]) 163 164 LIBS="$LIBS -framework OpenGL" 165 137 166 # checking for SDL-headers 138 167 AC_CHECK_HEADERS(SDL/SDL.h ,, 139 168 [AC_MSG_ERROR([cannot find SDL headers]) ]) 140 169 141 AC_CHECK_LIB([SDL], [main], FOUND_SDL=yes) 142 if test "$FOUND_SDL" = "yes" ; then 143 LIBS="$LIBS -lSDL" 144 else 145 echo "------------------" 146 echo "SDL library not found." 147 echo "please install the SDL library, which can be found at http://www.libsdl.org" 148 echo "------------------" 149 exit -1 150 fi 151 152 # FIXME: Replace `main' with a function in `-lOSMesa': 153 AC_CHECK_LIB([OSMesa], [main]) 154 # FIXME: Replace `main' with a function in `-lX11': 155 AC_CHECK_LIB([X11], [main]) 156 # FIXME: Replace `main' with a function in `-lXt': 157 AC_CHECK_LIB([Xt], [main]) 158 ;; 159 160 ### OS X ### 161 *Darwin*) 162 echo "OS X detected" 163 164 osX="yes" 165 166 # checking gl header 167 AC_CHECK_HEADERS(OpenGL/gl.h ,, 168 [AC_MSG_ERROR([cannot find opengl headers]) ]) 169 # cheking for GLU-header 170 AC_CHECK_HEADERS(OpenGL/glu.h ,, 171 [AC_MSG_ERROR([cannot find opengl headers]) ]) 172 173 LIBS="$LIBS -framework OpenGL" 174 175 # checking for SDL-headers 176 AC_CHECK_HEADERS(SDL/SDL.h ,, 177 [AC_MSG_ERROR([cannot find SDL headers]) ]) 178 179 LIBS="$LIBS -L/sw/lib -lSDLmain -lSDL -framework Cocoa" 180 170 ## checking for SDL 171 SDL_VERSION=1.2.7 172 AM_PATH_SDL($SDL_VERSION, 173 :, 174 AC_MSG_ERROR([*** SDL version $SDL_VERSION not found!]) 175 ) 176 CXXFLAGS="$CXXFLAGS $SDL_CFLAGS" 177 LIBS="$LIBS $SDL_LIBS" 181 178 ;; 182 179 … … 188 185 AC_SUBST(MSBITFIELDS) 189 186 187 188 189 190 ## checking for GTK 191 PKG_CHECK_MODULES(GTK2, gtk+-2.0 >= 2.0.3 gthread-2.0 >= 2.0.3, have_gtk2=yes, have_gtk2=no) 192 AC_SUBST(GTK2_LIBS) 193 AC_SUBST(GTK2_CFLAGS) 194 AM_CONDITIONAL(HAVE_GTK2, test "x$have_gtk2" = xyes) 190 195 191 196 … … 197 202 198 203 199 200 201 204 # FIXME: Replace `main' with a function in `-lm': 202 205 AC_CHECK_LIB([m], [main]) 203 204 LIBS="$LIBS `pkg-config --libs gtk+-2.0`"205 206 206 207
Note: See TracChangeset
for help on using the changeset viewer.