Clone of mesa.
Vous ne pouvez pas sélectionner plus de 25 sujets Les noms de sujets doivent commencer par une lettre ou un nombre, peuvent contenir des tirets ('-') et peuvent comporter jusqu'à 35 caractères.

configure.ac 1.7KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071
  1. # -*- Autoconf -*-
  2. # Process this file with autoconf to produce a configure script.
  3. AC_PREREQ(2.61)
  4. AC_INIT(glsl, XXXXX, idr@freedesktop.org, glsl)
  5. AC_CONFIG_SRCDIR([Makefile.am])
  6. AM_CONFIG_HEADER([config.h])
  7. AM_INIT_AUTOMAKE
  8. AM_MAINTAINER_MODE
  9. # Checks for programs.
  10. AC_PROG_CXX
  11. AC_PROG_CC
  12. AC_PROG_MAKE_SET
  13. AC_PROG_YACC
  14. AC_PROG_LEX
  15. # Checks for libraries.
  16. # Checks for header files.
  17. # Checks for typedefs, structures, and compiler characteristics.
  18. # Checks for library functions.
  19. AC_HEADER_STDC
  20. AC_ARG_ENABLE([debug],
  21. [AS_HELP_STRING([--enable-debug],
  22. [use debug compiler flags and macros @<:@default=disabled@:>@])],
  23. [enable_debug="$enableval"],
  24. [enable_debug=no]
  25. )
  26. if test "x$enable_debug" = xyes; then
  27. DEFINES="$DEFINES -DDEBUG"
  28. if test "x$GCC" = xyes; then
  29. # Remove any -g or -O flags from the command line
  30. CFLAGS=[`echo $CFLAGS | sed 's/-g[^ \t]*[ \t]*//g;s/-O[^ \t]*[ \t]*//g'`]
  31. CFLAGS="$CFLAGS -O0 -ggdb3 -fstack-protector -D_FORTIFY_SOURCE=2"
  32. fi
  33. if test "x$GXX" = xyes; then
  34. # Remove any -g flags from the command line
  35. CXXFLAGS=[`echo $CXXFLAGS | sed 's/-g[^ \t]*[ \t]*//g;s/-O[^ \t]*[ \t]*//g'`]
  36. CXXFLAGS="$CXXFLAGS -O0 -ggdb3 -fstack-protector -D_FORTIFY_SOURCE=2"
  37. fi
  38. fi
  39. if test "x$GCC" = xyes ; then
  40. WARN="-Wall -Wextra -Wunsafe-loop-optimizations -Wstack-protector -Wunreadchable-code"
  41. else
  42. WARN=""
  43. fi
  44. if test "x$GXX" = xyes ; then
  45. WARN="-Wall -Wextra -Wunsafe-loop-optimizations -Wstack-protector"
  46. else
  47. WARN=""
  48. fi
  49. if test "x$GCC" = xyes ; then
  50. CFLAGS="$CFLAGS -std=c89 -ansi -pedantic"
  51. fi
  52. CFLAGS="$CFLAGS $WARN"
  53. CXXFLAGS="$CXXFLAGS $WARN"
  54. YFLAGS="-d -v"
  55. AC_OUTPUT([Makefile])