comparison configure.in @ 8:4b173ad71786 r19-15b5

Import from CVS: tag r19-15b5
author cvs
date Mon, 13 Aug 2007 08:47:35 +0200
parents 27bc7f280385
children 49a24b4fd526
comparison
equal deleted inserted replaced
7:c153ca296910 8:4b173ad71786
108 cflags='NO_CFLAGS_DEFINED' 108 cflags='NO_CFLAGS_DEFINED'
109 dynamic='' 109 dynamic=''
110 with_x11='' 110 with_x11=''
111 rel_alloc='default' 111 rel_alloc='default'
112 use_system_malloc='default' 112 use_system_malloc='default'
113 internal_makefile_list='Makefile lib-src/Makefile.in man/Makefile.in src/Makefile.in lwlib/Makefile.in dynodump/Makefile.in' 113 internal_makefile_list='Makefile lib-src/Makefile.in src/Makefile.in lwlib/Makefile.in dynodump/Makefile.in'
114 energize_version='no' 114 energize_version='no'
115 native_sound_lib='' 115 native_sound_lib=''
116 # make normal error-checking be the default in alpha and beta versions, so 116 # make normal error-checking be the default in alpha and beta versions, so
117 # that bugs get noticed. Change this for released versions. 117 # that bugs get noticed. Change this for released versions.
118 error_check_default='yes' 118 error_check_default='yes'
1535 ### matter, be sure /etc/MACHINES says something about it. 1535 ### matter, be sure /etc/MACHINES says something about it.
1536 ### 1536 ###
1537 ### Eric Raymond says we should accept strings like "sysvr4" to mean 1537 ### Eric Raymond says we should accept strings like "sysvr4" to mean
1538 ### "System V Release 4"; he writes, "The old convention encouraged 1538 ### "System V Release 4"; he writes, "The old convention encouraged
1539 ### confusion between `system' and `release' levels'." 1539 ### confusion between `system' and `release' levels'."
1540 ###
1541 ### We rely on cpp to generate makefiles from Makefile.in.in templates.
1542 ### There is at least one drawback to that. Since cpp generally has
1543 ### built-in macro definitions like `#define unix' or `#define i386',
1544 ### we must be careful to prevent it from substituting these occurences
1545 ### in certain places in the makefiles. Pathnames for architecture-
1546 ### specific files come to mind.
1547 ### This is where CPPFLAGS_MAKEFILEGEN comes in. We try to selectively
1548 ### disable (potentially) predefined macros that we find to be part of
1549 ### the configuration string.
1550 ### This is but a poor method to help us fight off cpp, but it covers
1551 ### those cases that used to bite me. <mdiers@logware.de>
1552
1553 CPPFLAGS_MAKEFILEGEN="" # we normally do not need any extra flags
1540 1554
1541 machine='' opsys='' unported=no need_dynodump=no 1555 machine='' opsys='' unported=no need_dynodump=no
1542 case "${canonical}" in 1556 case "${canonical}" in
1543 1557
1544 ## NetBSD ports 1558 ## NetBSD ports
2263 ;; 2277 ;;
2264 2278
2265 ## Intel 386 machines where we don't care about the manufacturer 2279 ## Intel 386 machines where we don't care about the manufacturer
2266 i[3-9]86-*-* ) 2280 i[3-9]86-*-* )
2267 machine=intel386 2281 machine=intel386
2282 CPPFLAGS_MAKEFILEGEN="${CPPFLAGS_MAKEFILEGEN} -Ui386"
2268 case "${canonical}" in 2283 case "${canonical}" in
2269 *-isc1.* | *-isc2.[01]* ) opsys=386-ix ;; 2284 *-isc1.* | *-isc2.[01]* ) opsys=386-ix ;;
2270 *-isc2.2* ) opsys=isc2-2 ;; 2285 *-isc2.2* ) opsys=isc2-2 ;;
2271 *-isc4.0* ) opsys=isc4-0 ;; 2286 *-isc4.0* ) opsys=isc4-0 ;;
2272 *-isc4.* ) opsys=isc4-1 2287 *-isc4.* ) opsys=isc4-1
2293 if [ "${dynamic}" = "yes" ]; then 2308 if [ "${dynamic}" = "yes" ]; then
2294 NON_GNU_CPP="/lib/cpp -D_XOPEN_SOURCE -D_SCO_ELF" ; 2309 NON_GNU_CPP="/lib/cpp -D_XOPEN_SOURCE -D_SCO_ELF" ;
2295 else 2310 else
2296 NON_GNU_CPP="/lib/cpp -D_XOPEN_SOURCE" ; 2311 NON_GNU_CPP="/lib/cpp -D_XOPEN_SOURCE" ;
2297 fi ;; 2312 fi ;;
2298 *-386bsd* ) opsys=386bsd ;; 2313 *-386bsd* ) opsys=386bsd ;;
2299 *-freebsd* ) opsys=freebsd ;; 2314 *-freebsd* ) opsys=freebsd ;;
2300 *-nextstep* ) opsys=nextstep ;; 2315 *-nextstep* ) opsys=nextstep ;;
2301 ## Otherwise, we'll fall through to the generic opsys code at the bottom. 2316 ## Otherwise, we'll fall through to the generic opsys code at the bottom.
2302 esac 2317 esac
2303 ;; 2318 ;;
2304 2319
2538 2553
2539 #### Some systems specify a CPP to use unless we are using GCC. 2554 #### Some systems specify a CPP to use unless we are using GCC.
2540 #### Now that we know whether we are using GCC, we can decide whether 2555 #### Now that we know whether we are using GCC, we can decide whether
2541 #### to use that one. 2556 #### to use that one.
2542 2557
2543 #### Also, GNU CPP by default defines certain add'l macros that could 2558 if [ "x$GCC" = x1 ] || [ "x$NON_GNU_CPP" = x ] ; then
2544 #### hurt us when generating makefiles. We want to switch off these
2545 #### add'l macros for the purpose of generating makefiles.
2546
2547 CPPFLAGS_MAKEFILEGEN=""
2548 if [ "x$GCC" = x1 ] ; then
2549 CPPFLAGS_MAKEFILEGEN=" -undef "
2550 elif [ "x$NON_GNU_CPP" = x ] ; then
2551 true 2559 true
2552 else 2560 else
2553 if [ "x$CPP" = x ]; then 2561 if [ "x$CPP" = x ]; then
2554 if [ "${with_lcc}" = "yes" ] && [ "${NON_GNU_CPP}" = "yes" ] ; then 2562 if [ "${with_lcc}" = "yes" ] && [ "${NON_GNU_CPP}" = "yes" ] ; then
2555 CPP='gcc -E -traditional' # cross fingers and hope it's there.... 2563 CPP='gcc -E -traditional' # cross fingers and hope it's there....
4440 AC_OUTPUT($internal_makefile_list) [ 4448 AC_OUTPUT($internal_makefile_list) [
4441 # Build: 4449 # Build:
4442 # src/Makefile from ${srcdir}/src/Makefile.in 4450 # src/Makefile from ${srcdir}/src/Makefile.in
4443 # lwlib/Makefile from ${srcdir}/lwlib/Makefile.in 4451 # lwlib/Makefile from ${srcdir}/lwlib/Makefile.in
4444 # lib-src/Makefile from ${srcdir}/lib-src/Makefile.in 4452 # lib-src/Makefile from ${srcdir}/lib-src/Makefile.in
4445 # man/Makefile from ${srcdir}/man/Makefile.in
4446 # man/*/Makefile from ${srcdir}/man/*/Makefile.in 4453 # man/*/Makefile from ${srcdir}/man/*/Makefile.in
4447 # dynodump/Makefile from ${srcdir}/dynodump/Makefile.in 4454 # dynodump/Makefile from ${srcdir}/dynodump/Makefile.in
4448 # and possibly 4455 # and possibly
4449 # lwlib/energize/Makefile from ${srcdir}/lwlib/energize/Makefile.in. 4456 # lwlib/energize/Makefile from ${srcdir}/lwlib/energize/Makefile.in.
4450 # This must be done after src/config.h is built, since we rely on that 4457 # This must be done after src/config.h is built, since we rely on that
4525 chmod 444 Makefile.new; 4532 chmod 444 Makefile.new;
4526 mv -f Makefile.new Makefile; 4533 mv -f Makefile.new Makefile;
4527 rm -f junk.c junk.cpp; 4534 rm -f junk.c junk.cpp;
4528 )' 4535 )'
4529 eval `echo $dynodump_makefile_command` 4536 eval `echo $dynodump_makefile_command`
4530 man_makefile_command='echo "creating man/Makefile";
4531 topsrcdir='"${topsrcdir}"';
4532 ( cd ./man;
4533 rm -f junk.c;
4534 sed -e '\''s/^# Generated.*//'\'' -e '\''s%/\*\*/#.*%%'\'' < Makefile.in > junk.c;
4535 eval `echo ${CPP} ${CPPFLAGS_MAKEFILEGEN} -I. -I${topsrcdir}/src ${CPPFLAGS} junk.c \>junk.cpp`;
4536 < junk.cpp '\
4537 ' sed -e '\''s/^#.*//'\'' '\
4538 ' -e '\''s/^[ \f\t][ \f\t]*$//'\'' '\
4539 ' -e '\''s/^ / /'\'' '\
4540 ' | sed -n -e '\''/^..*$/p'\'' '\
4541 ' > Makefile.new;
4542 chmod 444 Makefile.new;
4543 mv -f Makefile.new Makefile;
4544 rm -f junk.c junk.cpp;
4545 )'
4546 eval `echo $man_makefile_command`
4547 if [ "${with_energize}" = "yes" ]; then 4537 if [ "${with_energize}" = "yes" ]; then
4548 energize_makefile_command='echo "creating lwlib/energize/Makefile"; 4538 energize_makefile_command='echo "creating lwlib/energize/Makefile";
4549 topsrcdir='"${topsrcdir}"'; 4539 topsrcdir='"${topsrcdir}"';
4550 ( cd ./lwlib/energize; 4540 ( cd ./lwlib/energize;
4551 rm -f junk.c; 4541 rm -f junk.c;
4563 )' 4553 )'
4564 eval `echo $energize_makefile_command` 4554 eval `echo $energize_makefile_command`
4565 fi 4555 fi
4566 # AC-OUTPUT has created `config.status' already. We need to add the 4556 # AC-OUTPUT has created `config.status' already. We need to add the
4567 # above commands to re-create `src/Makefile', `lwlib/Makefile', 4557 # above commands to re-create `src/Makefile', `lwlib/Makefile',
4568 # `lib-src/Makefile', `dynodump/Makefile', `man/Makefile', and possibly 4558 # `lib-src/Makefile', `dynodump/Makefile', and possibly
4569 # `lwlib/energize/Makefile', and we need to insert them before the final 4559 # `lwlib/energize/Makefile', and we need to insert them before the final
4570 # "exit 0" which appears at the end of `config.status'. 4560 # "exit 0" which appears at the end of `config.status'.
4571 <config.status sed -e 's/^exit 0$//' >config.new 4561 <config.status sed -e 's/^exit 0$//' >config.new
4572 echo $makefile_command >>config.new 4562 echo $makefile_command >>config.new
4573 echo $lwlib_makefile_command >>config.new 4563 echo $lwlib_makefile_command >>config.new
4580 echo exit 0 >>config.new 4570 echo exit 0 >>config.new
4581 mv -f config.new config.status 4571 mv -f config.new config.status
4582 chmod +x config.status 4572 chmod +x config.status
4583 # Don't let the fact that we just rewrote config.status make Makefile think 4573 # Don't let the fact that we just rewrote config.status make Makefile think
4584 # that it is now newer. We have just rewritten all of the Makefiles as well. 4574 # that it is now newer. We have just rewritten all of the Makefiles as well.
4585 MFS="Makefile src/Makefile src/Makefile.in lib-src/Makefile lib-src/Makefile.in dynodump/Makefile dynodump/Makefile.in lwlib/Makefile lwlib/Makefile.in man/Makefile man/Makefile.in" 4575 MFS="Makefile src/Makefile src/Makefile.in lib-src/Makefile lib-src/Makefile.in dynodump/Makefile dynodump/Makefile.in lwlib/Makefile lwlib/Makefile.in"
4586 for file in $MFS; do 4576 for file in $MFS; do
4587 chmod a+w $file; touch $file; chmod 444 $file 4577 chmod a+w $file; touch $file; chmod 444 $file
4588 done 4578 done
4589 4579
4590 if test ! -f src/gdbinit && test -f $topsrcdir/src/gdbinit; then 4580 if test ! -f src/gdbinit && test -f $topsrcdir/src/gdbinit; then