Search
lxdream.org :: lxdream/configure :: diff
lxdream 0.9.1
released Jun 29
Download Now
filename configure
changeset 489:45c8ddcf52cb
prev487:b34abd796f5e
next503:36a668469e37
author nkeynes
date Sun Nov 04 05:07:49 2007 +0000 (12 years ago)
permissions -rw-r--r--
last change Test for presence of linux/cdrom.h at configure time, and only build the
linux driver if it's found successfully
file annotate diff log raw
1.1 --- a/configure Sat Nov 03 12:01:35 2007 +0000
1.2 +++ b/configure Sun Nov 04 05:07:49 2007 +0000
1.3 @@ -693,6 +693,8 @@
1.4 PKG_CONFIG
1.5 PACKAGE_CFLAGS
1.6 PACKAGE_LIBS
1.7 +CDROM_LINUX_TRUE
1.8 +CDROM_LINUX_FALSE
1.9 GETTEXT_PACKAGE
1.10 USE_NLS
1.11 MSGFMT
1.12 @@ -5202,14 +5204,6 @@
1.13 fi
1.14
1.15
1.16 -GETTEXT_PACKAGE=dream
1.17 -
1.18 -cat >>confdefs.h <<_ACEOF
1.19 -#define GETTEXT_PACKAGE "$GETTEXT_PACKAGE"
1.20 -_ACEOF
1.21 -
1.22 -
1.23 -ALL_LINGUAS=""
1.24 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
1.25
1.26
1.27 @@ -5279,6 +5273,158 @@
1.28 done
1.29
1.30
1.31 +if test "${ac_cv_header_linux_cdrom_h+set}" = set; then
1.32 + { echo "$as_me:$LINENO: checking for linux/cdrom.h" >&5
1.33 +echo $ECHO_N "checking for linux/cdrom.h... $ECHO_C" >&6; }
1.34 +if test "${ac_cv_header_linux_cdrom_h+set}" = set; then
1.35 + echo $ECHO_N "(cached) $ECHO_C" >&6
1.36 +fi
1.37 +{ echo "$as_me:$LINENO: result: $ac_cv_header_linux_cdrom_h" >&5
1.38 +echo "${ECHO_T}$ac_cv_header_linux_cdrom_h" >&6; }
1.39 +else
1.40 + # Is the header compilable?
1.41 +{ echo "$as_me:$LINENO: checking linux/cdrom.h usability" >&5
1.42 +echo $ECHO_N "checking linux/cdrom.h usability... $ECHO_C" >&6; }
1.43 +cat >conftest.$ac_ext <<_ACEOF
1.44 +/* confdefs.h. */
1.45 +_ACEOF
1.46 +cat confdefs.h >>conftest.$ac_ext
1.47 +cat >>conftest.$ac_ext <<_ACEOF
1.48 +/* end confdefs.h. */
1.49 +$ac_includes_default
1.50 +#include <linux/cdrom.h>
1.51 +_ACEOF
1.52 +rm -f conftest.$ac_objext
1.53 +if { (ac_try="$ac_compile"
1.54 +case "(($ac_try" in
1.55 + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1.56 + *) ac_try_echo=$ac_try;;
1.57 +esac
1.58 +eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
1.59 + (eval "$ac_compile") 2>conftest.er1
1.60 + ac_status=$?
1.61 + grep -v '^ *+' conftest.er1 >conftest.err
1.62 + rm -f conftest.er1
1.63 + cat conftest.err >&5
1.64 + echo "$as_me:$LINENO: \$? = $ac_status" >&5
1.65 + (exit $ac_status); } && {
1.66 + test -z "$ac_c_werror_flag" ||
1.67 + test ! -s conftest.err
1.68 + } && test -s conftest.$ac_objext; then
1.69 + ac_header_compiler=yes
1.70 +else
1.71 + echo "$as_me: failed program was:" >&5
1.72 +sed 's/^/| /' conftest.$ac_ext >&5
1.73 +
1.74 + ac_header_compiler=no
1.75 +fi
1.76 +
1.77 +rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1.78 +{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
1.79 +echo "${ECHO_T}$ac_header_compiler" >&6; }
1.80 +
1.81 +# Is the header present?
1.82 +{ echo "$as_me:$LINENO: checking linux/cdrom.h presence" >&5
1.83 +echo $ECHO_N "checking linux/cdrom.h presence... $ECHO_C" >&6; }
1.84 +cat >conftest.$ac_ext <<_ACEOF
1.85 +/* confdefs.h. */
1.86 +_ACEOF
1.87 +cat confdefs.h >>conftest.$ac_ext
1.88 +cat >>conftest.$ac_ext <<_ACEOF
1.89 +/* end confdefs.h. */
1.90 +#include <linux/cdrom.h>
1.91 +_ACEOF
1.92 +if { (ac_try="$ac_cpp conftest.$ac_ext"
1.93 +case "(($ac_try" in
1.94 + *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1.95 + *) ac_try_echo=$ac_try;;
1.96 +esac
1.97 +eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
1.98 + (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
1.99 + ac_status=$?
1.100 + grep -v '^ *+' conftest.er1 >conftest.err
1.101 + rm -f conftest.er1
1.102 + cat conftest.err >&5
1.103 + echo "$as_me:$LINENO: \$? = $ac_status" >&5
1.104 + (exit $ac_status); } >/dev/null && {
1.105 + test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
1.106 + test ! -s conftest.err
1.107 + }; then
1.108 + ac_header_preproc=yes
1.109 +else
1.110 + echo "$as_me: failed program was:" >&5
1.111 +sed 's/^/| /' conftest.$ac_ext >&5
1.112 +
1.113 + ac_header_preproc=no
1.114 +fi
1.115 +
1.116 +rm -f conftest.err conftest.$ac_ext
1.117 +{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
1.118 +echo "${ECHO_T}$ac_header_preproc" >&6; }
1.119 +
1.120 +# So? What about this header?
1.121 +case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
1.122 + yes:no: )
1.123 + { echo "$as_me:$LINENO: WARNING: linux/cdrom.h: accepted by the compiler, rejected by the preprocessor!" >&5
1.124 +echo "$as_me: WARNING: linux/cdrom.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
1.125 + { echo "$as_me:$LINENO: WARNING: linux/cdrom.h: proceeding with the compiler's result" >&5
1.126 +echo "$as_me: WARNING: linux/cdrom.h: proceeding with the compiler's result" >&2;}
1.127 + ac_header_preproc=yes
1.128 + ;;
1.129 + no:yes:* )
1.130 + { echo "$as_me:$LINENO: WARNING: linux/cdrom.h: present but cannot be compiled" >&5
1.131 +echo "$as_me: WARNING: linux/cdrom.h: present but cannot be compiled" >&2;}
1.132 + { echo "$as_me:$LINENO: WARNING: linux/cdrom.h: check for missing prerequisite headers?" >&5
1.133 +echo "$as_me: WARNING: linux/cdrom.h: check for missing prerequisite headers?" >&2;}
1.134 + { echo "$as_me:$LINENO: WARNING: linux/cdrom.h: see the Autoconf documentation" >&5
1.135 +echo "$as_me: WARNING: linux/cdrom.h: see the Autoconf documentation" >&2;}
1.136 + { echo "$as_me:$LINENO: WARNING: linux/cdrom.h: section \"Present But Cannot Be Compiled\"" >&5
1.137 +echo "$as_me: WARNING: linux/cdrom.h: section \"Present But Cannot Be Compiled\"" >&2;}
1.138 + { echo "$as_me:$LINENO: WARNING: linux/cdrom.h: proceeding with the preprocessor's result" >&5
1.139 +echo "$as_me: WARNING: linux/cdrom.h: proceeding with the preprocessor's result" >&2;}
1.140 + { echo "$as_me:$LINENO: WARNING: linux/cdrom.h: in the future, the compiler will take precedence" >&5
1.141 +echo "$as_me: WARNING: linux/cdrom.h: in the future, the compiler will take precedence" >&2;}
1.142 +
1.143 + ;;
1.144 +esac
1.145 +{ echo "$as_me:$LINENO: checking for linux/cdrom.h" >&5
1.146 +echo $ECHO_N "checking for linux/cdrom.h... $ECHO_C" >&6; }
1.147 +if test "${ac_cv_header_linux_cdrom_h+set}" = set; then
1.148 + echo $ECHO_N "(cached) $ECHO_C" >&6
1.149 +else
1.150 + ac_cv_header_linux_cdrom_h=$ac_header_preproc
1.151 +fi
1.152 +{ echo "$as_me:$LINENO: result: $ac_cv_header_linux_cdrom_h" >&5
1.153 +echo "${ECHO_T}$ac_cv_header_linux_cdrom_h" >&6; }
1.154 +
1.155 +fi
1.156 +if test $ac_cv_header_linux_cdrom_h = yes; then
1.157 + HAVE_LINUX_CDROM_H=yes
1.158 +else
1.159 +
1.160 + echo "Linux CDROM support not found, building without it."
1.161 +fi
1.162 +
1.163 +
1.164 +
1.165 +
1.166 +if test "$HAVE_LINUX_CDROM_H" = "yes"; then
1.167 + CDROM_LINUX_TRUE=
1.168 + CDROM_LINUX_FALSE='#'
1.169 +else
1.170 + CDROM_LINUX_TRUE='#'
1.171 + CDROM_LINUX_FALSE=
1.172 +fi
1.173 +
1.174 +
1.175 +GETTEXT_PACKAGE=dream
1.176 +
1.177 +cat >>confdefs.h <<_ACEOF
1.178 +#define GETTEXT_PACKAGE "$GETTEXT_PACKAGE"
1.179 +_ACEOF
1.180 +
1.181 +
1.182 +ALL_LINGUAS=""
1.183
1.184
1.185 for ac_header in locale.h
1.186 @@ -6893,6 +7039,13 @@
1.187 Usually this means the macro was only invoked conditionally." >&2;}
1.188 { (exit 1); exit 1; }; }
1.189 fi
1.190 +if test -z "${CDROM_LINUX_TRUE}" && test -z "${CDROM_LINUX_FALSE}"; then
1.191 + { { echo "$as_me:$LINENO: error: conditional \"CDROM_LINUX\" was never defined.
1.192 +Usually this means the macro was only invoked conditionally." >&5
1.193 +echo "$as_me: error: conditional \"CDROM_LINUX\" was never defined.
1.194 +Usually this means the macro was only invoked conditionally." >&2;}
1.195 + { (exit 1); exit 1; }; }
1.196 +fi
1.197
1.198 : ${CONFIG_STATUS=./config.status}
1.199 ac_clean_files_save=$ac_clean_files
1.200 @@ -7508,6 +7661,8 @@
1.201 PKG_CONFIG!$PKG_CONFIG$ac_delim
1.202 PACKAGE_CFLAGS!$PACKAGE_CFLAGS$ac_delim
1.203 PACKAGE_LIBS!$PACKAGE_LIBS$ac_delim
1.204 +CDROM_LINUX_TRUE!$CDROM_LINUX_TRUE$ac_delim
1.205 +CDROM_LINUX_FALSE!$CDROM_LINUX_FALSE$ac_delim
1.206 GETTEXT_PACKAGE!$GETTEXT_PACKAGE$ac_delim
1.207 USE_NLS!$USE_NLS$ac_delim
1.208 MSGFMT!$MSGFMT$ac_delim
1.209 @@ -7523,8 +7678,6 @@
1.210 PO_IN_DATADIR_FALSE!$PO_IN_DATADIR_FALSE$ac_delim
1.211 POFILES!$POFILES$ac_delim
1.212 POSUB!$POSUB$ac_delim
1.213 -MKINSTALLDIRS!$MKINSTALLDIRS$ac_delim
1.214 -LIBOBJS!$LIBOBJS$ac_delim
1.215 _ACEOF
1.216
1.217 if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 97; then
1.218 @@ -7566,10 +7719,12 @@
1.219 ac_delim='%!_!# '
1.220 for ac_last_try in false false false false false :; do
1.221 cat >conf$$subs.sed <<_ACEOF
1.222 +MKINSTALLDIRS!$MKINSTALLDIRS$ac_delim
1.223 +LIBOBJS!$LIBOBJS$ac_delim
1.224 LTLIBOBJS!$LTLIBOBJS$ac_delim
1.225 _ACEOF
1.226
1.227 - if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 1; then
1.228 + if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 3; then
1.229 break
1.230 elif $ac_last_try; then
1.231 { { echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
.