configure.in
上传用户:wstnjxml
上传日期:2014-04-03
资源大小:7248k
文件大小:3k
源码类别:

Windows CE

开发平台:

C/C++

  1. dnl Process this file with autoconf to produce a configure script
  2. dnl ------------------------------------------------
  3. dnl Initialization and Versioning
  4. dnl ------------------------------------------------
  5. AC_INIT(mdct.c)
  6. AM_INIT_AUTOMAKE(libvorbisidec,1.2.0)
  7. dnl Library versioning
  8. V_LIB_CURRENT=1
  9. V_LIB_REVISION=2
  10. V_LIB_AGE=0
  11. AC_SUBST(V_LIB_CURRENT)
  12. AC_SUBST(V_LIB_REVISION)
  13. AC_SUBST(V_LIB_AGE)
  14. dnl --------------------------------------------------  
  15. dnl Check for programs
  16. dnl --------------------------------------------------  
  17. dnl save $CFLAGS since AC_PROG_CC likes to insert "-g -O2"
  18. dnl if $CFLAGS is blank
  19. cflags_save="$CFLAGS"
  20. AC_PROG_CC
  21. AC_PROG_CPP
  22. CFLAGS="$cflags_save"
  23. AM_PROG_LIBTOOL
  24. dnl --------------------------------------------------
  25. dnl Set build flags based on environment
  26. dnl --------------------------------------------------
  27. AC_CANONICAL_HOST
  28. dnl Set some target options
  29. cflags_save="$CFLAGS"
  30. ldflags_save="$LDFLAGS"
  31. if test -z "$GCC"; then
  32.         case $host in 
  33.         arm-*-*)
  34.                 DEBUG="-g -D_ARM_ASSEM_" 
  35.                 CFLAGS="-O -D_ARM_ASSEM_"
  36.                 PROFILE="-p -g -O -D_ARM_ASSEM" ;;
  37.         *)
  38.                 DEBUG="-g"
  39.                 CFLAGS="-O"
  40.                 PROFILE="-g -p" ;;
  41.         esac
  42. else
  43.         case $host in 
  44.         arm-*-*)
  45.                 DEBUG="-g -W -D__NO_MATH_INLINES -fsigned-char -D_ARM_ASSEM_"
  46.                 CFLAGS="-O2 -D_ARM_ASSEM_ -fsigned-char"
  47.                 PROFILE="-W -pg -g -O2 -D_ARM_ASSEM_ -fsigned-char -fno-inline-functions";;
  48.         *)
  49.                 DEBUG="-g -W -D__NO_MATH_INLINES -fsigned-char"
  50.                 CFLAGS="-O2 -fsigned-char"
  51.                 PROFILE="-W -pg -g -O2 -fsigned-char -fno-inline-functions";;
  52.         esac
  53. fi
  54. CFLAGS="$CFLAGS $cflags_save -D_REENTRANT"
  55. LDFLAGS="$LDFLAGS $ldflags_save"
  56. dnl --------------------------------------------------
  57. dnl Options 
  58. dnl --------------------------------------------------
  59. AC_ARG_ENABLE(
  60.    low-accuracy,
  61.    [  --enable-low-accuracy   enable 32 bit only multiply operations],
  62.    CFLAGS="$CFLAGS -D_LOW_ACCURACY_"
  63. )
  64. dnl --------------------------------------------------
  65. dnl Check for headers
  66. dnl --------------------------------------------------
  67. AC_CHECK_HEADER(memory.h,CFLAGS="$CFLAGS -DUSE_MEMORY_H",:)
  68. dnl --------------------------------------------------
  69. dnl Check for typedefs, structures, etc
  70. dnl --------------------------------------------------
  71. dnl none
  72. dnl --------------------------------------------------
  73. dnl Check for library functions
  74. dnl --------------------------------------------------
  75. AC_FUNC_ALLOCA
  76. AC_FUNC_MEMCMP
  77. dnl --------------------------------------------------
  78. dnl Do substitutions
  79. dnl --------------------------------------------------
  80. LIBS="$LIBS"
  81. AC_SUBST(LIBS)
  82. AC_SUBST(DEBUG)
  83. AC_SUBST(PROFILE)
  84. AC_OUTPUT(Makefile)