Changeset 2170
- Timestamp:
- Mar 30, 2011, 12:34:02 PM (14 years ago)
- Location:
- branches/blt4
- Files:
-
- 94 added
- 13 deleted
- 45 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/blt4/Makefile.in
r1948 r2170 35 35 36 36 ifneq ($(ENABLE_GUI),) 37 TARGETS += gui lang lib instantexamples37 TARGETS += gui lang lib builder tester examples 38 38 endif 39 39 -
branches/blt4/README
r217 r2170 27 27 ---------------------------------------------------------------------- 28 28 29 Developed by Michael McLennan, Derrick Kearney, and Carol Song. 29 Developed by Michael McLennan, George Howlett, and Derrick Kearney. 30 Special thanks to Ben Rafferty for Java bindings and the Rappture 31 tester, and Ben Haley for Ruby bindings. 30 32 -
branches/blt4/configure.in
r2060 r2170 5 5 AC_CONFIG_HEADER(src/core/config.h) 6 6 7 with_tclsh=yes 8 7 9 #------------------------------------------------------------------------ 8 10 # Handle the --prefix=... option … … 15 17 exec_prefix=$prefix 16 18 fi 19 20 AC_ARG_WITH( 21 [install], 22 [AS_HELP_STRING([--with-install[=DIR]], 23 [location of installation @<:@default=yes@:>@])], 24 [], 25 [with_install=yes]) 26 if test "$with_install" != "yes"; then 27 INSTALL_PREFIX=$with_install 28 else 29 INSTALL_PREFIX=$prefix 30 fi 31 AC_SUBST(INSTALL_PREFIX) 32 17 33 18 34 if test "${libdir}" != "${prefix}/lib"; then … … 115 131 AC_SUBST(ENABLE_GUI) 116 132 117 rp_with_tclsh="yes"118 AC_ARG_WITH(119 [tclsh],120 [AS_HELP_STRING([--with-tclsh[=DIR]],121 [location of tclsh @<:@default=yes@:>@])],122 [],123 [rp_with_tclsh=$withval])124 125 TCLSH=126 if test "${rp_with_tclsh}" != "no" ; then127 AC_MSG_CHECKING([for tclsh])128 if test -x "${rp_with_tclsh}/bin/tclsh"129 then130 TCLSH="${rp_with_tclsh}/bin/tclsh"131 else132 if test -x "${rp_with_tclsh}"133 then134 TCLSH="${rp_with_tclsh}"135 else136 if test -x "${exec_prefix}/bin/tclsh"137 then138 TCLSH="${exec_prefix}/bin/tclsh"139 else140 for v in 8.4 8.5 8.6 ; do141 if test -x "${exec_prefix}/bin/tclsh${v}"142 then143 TCLSH="${exec_prefix}/bin/tclsh${v}"144 break145 fi146 done147 fi148 fi149 fi150 if ! test -x ${TCLSH} ; then151 AC_PATH_PROG(TCLSH, tclsh)152 fi153 fi154 AC_MSG_RESULT([${TCLSH}])155 AC_SUBST(TCLSH)156 157 133 TCL_VERSION="8.4" 158 134 for dir in \ … … 165 141 fi 166 142 done 143 144 145 rp_with_tclsh="yes" 146 AC_ARG_WITH( 147 [tclsh], 148 [AS_HELP_STRING([--with-tclsh[=DIR]], 149 [location of tclsh @<:@default=yes@:>@])], 150 [rp_with_tclsh=$withval], 151 [rp_with_tclsh=yes]) 152 153 TCLSH="" 154 if test "${rp_with_tclsh}" != "no" ; then 155 tclsh="tclsh${TCL_VERSION}" 156 if test "${rp_with_tclsh}" = "yes" ; then 157 AC_PATH_PROG(TCLSH, ${tclsh}, [], [${exec_prefix}/bin:${PATH}]) 158 else 159 AC_PATH_PROG(TCLSH, ${tclsh}, [], [${rp_with_tclsh}/bin:${rp_with_tclsh}]) 160 fi 161 if test "x${TCLSH}" = "x" ; then 162 AC_ERROR([can't find tclsh]) 163 fi 164 fi 165 AC_SUBST(TCLSH) 166 167 167 168 TCL_INC_SPEC="$TCL_INCLUDE_SPEC" 168 169 if test "x$rp_with_tcllib" != "x" ; then170 tclconfig="${rp_with_tcllib}/tclConfig.sh"171 if test -f "$tclconfig" ; then172 . $tclconfig173 fi174 TCL_LIB_SPEC="-L${rp_with_tcllib} -ltcl${TCL_VERSION}"175 fi176 if test "x$rp_with_tclinclude" != "x" ; then177 TCL_INC_SPEC="-I${rp_with_tclinclude}"178 fi179 169 180 170 AC_SUBST(TCL_VERSION) … … 747 737 gui/pkgIndex.tcl 748 738 gui/scripts/Makefile 749 instant/Makefile 750 instant/irappture 739 gui/src/Makefile 740 builder/Makefile 741 builder/pkgIndex.tcl 742 builder/scripts/Makefile 743 tester/Makefile 744 tester/pkgIndex.tcl 745 tester/scripts/Makefile 751 746 lang/Makefile 752 747 lang/java/Makefile -
branches/blt4/gui/Makefile.in
r1948 r2170 28 28 .PHONY: src scripts apps 29 29 30 all:scripts apps30 SUBDIRS = src scripts apps 31 31 32 scripts: 33 $(MAKE) -C scripts all 34 src: 35 $(MAKE) -C all 36 apps: 37 $(MAKE) -C apps all 32 all: 33 for i in $(SUBDIRS) ; do \ 34 $(MAKE) -C $$i all || exit 1 ;\ 35 done 38 36 39 install: install_scripts install_apps37 install: 40 38 $(MKDIR_P) -m 0755 $(destdir) 41 @for i in $(FILES); do \39 for i in $(FILES); do \ 42 40 echo "Installing $$i" ; \ 43 41 $(INSTALL) -m 0444 $$i $(destdir) ; \ 44 42 done 45 $(INSTALL) -m 0444 pkgIndex.tcl $(destdir) 46 47 install_scripts: scripts 48 $(MAKE) -C scripts install 49 install_apps: apps 50 $(MAKE) -C apps install 43 for i in $(SUBDIRS) ; do \ 44 $(MAKE) -C $$i install || exit 1 ;\ 45 done 51 46 52 47 test: … … 54 49 55 50 clean: 56 $(MAKE) -C scripts clean 57 $(MAKE) -C apps clean 51 for i in $(SUBDIRS) ; do \ 52 $(MAKE) -C $$i clean ;\ 53 done 58 54 59 55 distclean: 60 $(MAKE) -C scripts distclean 61 $(MAKE) -C apps distclean 56 for i in $(SUBDIRS) ; do \ 57 $(MAKE) -C $$i distclean ;\ 58 done 62 59 $(RM) Makefile pkgIndex.tcl 63 60 $(RM) config.cache config.log config.status -
branches/blt4/gui/apps/Makefile.in
r1948 r2170 22 22 SCRIPTS = \ 23 23 encodedata \ 24 $(srcdir)/ driver\24 $(srcdir)/launcher.tcl \ 25 25 $(srcdir)/grabdata \ 26 26 $(srcdir)/nanovis-test \ 27 $(srcdir)/vtkcontour-test \ 27 28 $(srcdir)/flowvis-test \ 28 29 rappture \ -
branches/blt4/gui/apps/flowvis-test
r1897 r2170 16 16 # ====================================================================== 17 17 #\ 18 bindir=` basename $0` ; \18 bindir=`dirname $0` ; \ 19 19 . $bindir/rappture.env ; \ 20 20 exec wish "$0" $* -
branches/blt4/gui/apps/rappture-csh.env.in
r1988 r2170 17 17 18 18 # If you install Rappture elsewhere, edit the line below: 19 set exec_prefix=@ exec_prefix@19 set exec_prefix=@INSTALL_PREFIX@ 20 20 21 21 set bindir=@bindir@ … … 52 52 endif 53 53 54 # This depends upon the hacked version of octave that we install on the hubs.55 54 if ( $?OCTAVE_LOADPATH ) then 56 55 setenv OCTAVE_LOADPATH "${libdir}/octave3:$OCTAVE_LOADPATH" -
branches/blt4/gui/apps/rappture.env.in
r1988 r2170 16 16 # 17 17 # If you install Rappture elsewhere, edit the line below: 18 exec_prefix=@ prefix@18 exec_prefix=@INSTALL_PREFIX@ 19 19 20 20 libdir=@libdir@ … … 36 36 37 37 MATLABPATH=${libdir}/matlab:$MATLABPATH 38 # This depends upon the hacked version of octave that we install39 38 OCTAVE_LOADPATH=:${libdir}/octave3:$OCTAVE_LOADPATH 40 39 OCTAVE_PATH=:${libdir}/octave${octave_version}:$OCTAVE_PATH -
branches/blt4/gui/apps/rappture.in
r1980 r2170 9 9 # ====================================================================== 10 10 # AUTHOR: Michael McLennan, Purdue University 11 # Copyright (c) 2004-20 07Purdue Research Foundation11 # Copyright (c) 2004-2011 Purdue Research Foundation 12 12 # 13 13 # See the file "license.terms" for information on usage and … … 16 16 dir=`dirname $0` 17 17 . $dir/rappture.env 18 exec $dir/driver$*18 exec tclsh $dir/launcher.tcl $* -
branches/blt4/gui/apps/rerun.in
r2060 r2170 32 32 dir=`dirname $0` 33 33 . $dir/rappture.env 34 exec $dir/ driver -nosim true -load "$*"34 exec $dir/rappture -nosim true -load $* -
branches/blt4/gui/apps/simsim.in
r1897 r2170 8 8 # ====================================================================== 9 9 #\ 10 . rappture.env \ 11 exec wish "$0" $* 10 dir=`dirname $0` ; \ 11 . $dir/rappture.env ; \ 12 exec $dir/tclsh "$0" $* 12 13 13 14 package require Rappture … … 414 415 -compare <path> - compare the results with the run.xml 415 416 file at <path>. 417 -runfile <path> - move the run file to <path> 416 418 -nosim - no simulation. 417 419 -help - print this help menu. … … 632 634 set params(--driver) [lindex $argv $i] 633 635 # need to check to see if file exists, if not raise error 636 } else { 637 printHelp 638 } 639 } elseif { ("-r" == $opt) || 640 ("-runfile" == $opt) || 641 ("--runfile" == $opt) } { 642 if {[expr {$i + 1}] < $argc} { 643 incr i 644 set params(--runfile) [lindex $argv $i] 634 645 } else { 635 646 printHelp … … 686 697 --nosim false 687 698 --driver "" 699 --runfile "" 688 700 --tool "./tool.xml" 689 701 oParams {} … … 691 703 692 704 parseOptions argv params 693 694 # keep the wish window from popping up695 wm withdraw .696 705 697 706 # parse out path=val combinations from the list of orphaned parameters … … 739 748 } 740 749 750 751 752 741 753 set tool [Rappture::Tool ::#auto $xmlobj $installdir] 742 754 … … 748 760 foreach {status result} [eval $tool run] break 749 761 750 # read back the result from run.xml 762 if {[string compare "" $params(--runfile)] != 0} { 763 set runfilename [$tool getRunFile] 764 set err [catch {file rename $runfilename $params(--runfile)} out] 765 if {$err} { 766 puts stderr $out 767 } 768 } 769 770 # if run was successful, check to see if we should compare 751 771 if {$status == 0 && $result != "ABORT"} { 752 772 if {[Rappture::library isvalid $result]} { -
branches/blt4/gui/configure
r1884 r2170 1 1 #! /bin/sh 2 2 # Guess values for system-dependent variables and create Makefiles. 3 # Generated by GNU Autoconf 2.6 5for RapptureGUI 1.1.3 # Generated by GNU Autoconf 2.68 for RapptureGUI 1.1. 4 4 # 5 5 # Report bugs to <rappture@nanohub.org>. … … 7 7 # 8 8 # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, 9 # 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software Foundation,10 # Inc.9 # 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 Free Software 10 # Foundation, Inc. 11 11 # 12 12 # … … 92 92 93 93 # Find who we are. Look in the path if we contain no directory separator. 94 as_myself= 94 95 case $0 in #(( 95 96 *[\\/]* ) as_myself=$0 ;; … … 173 174 as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO 174 175 eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" && 175 test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1" 176 test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1 177 test \$(( 1 + 1 )) = 2 || exit 1" 176 178 if (eval "$as_required") 2>/dev/null; then : 177 179 as_have_required=yes … … 216 218 # neutralization value for shells without unset; and this also 217 219 # works around shells that cannot unset nonexistent variables. 220 # Preserve -v and -x to the replacement shell. 218 221 BASH_ENV=/dev/null 219 222 ENV=/dev/null 220 223 (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV 221 224 export CONFIG_SHELL 222 exec "$CONFIG_SHELL" "$as_myself" ${1+"$@"} 225 case $- in # (((( 226 *v*x* | *x*v* ) as_opts=-vx ;; 227 *v* ) as_opts=-v ;; 228 *x* ) as_opts=-x ;; 229 * ) as_opts= ;; 230 esac 231 exec "$CONFIG_SHELL" $as_opts "$as_myself" ${1+"$@"} 223 232 fi 224 233 … … 319 328 done 320 329 test -z "$as_dirs" || eval "mkdir $as_dirs" 321 } || test -d "$as_dir" || as_fn_error "cannot create directory $as_dir"330 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" 322 331 323 332 … … 359 368 360 369 361 # as_fn_error ERROR [LINENO LOG_FD]362 # --------------------------------- 370 # as_fn_error STATUS ERROR [LINENO LOG_FD] 371 # ---------------------------------------- 363 372 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are 364 373 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the 365 # script with status $?, using 1 if that was 0.374 # script with STATUS, using 1 if that was 0. 366 375 as_fn_error () 367 376 { 368 as_status=$ ?; test $as_status -eq 0 && as_status=1369 if test "$ 3"; then370 as_lineno=${as_lineno-"$ 2"} as_lineno_stack=as_lineno_stack=$as_lineno_stack371 $as_echo "$as_me:${as_lineno-$LINENO}: error: $ 1" >&$3377 as_status=$1; test $as_status -eq 0 && as_status=1 378 if test "$4"; then 379 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 380 $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 372 381 fi 373 $as_echo "$as_me: error: $ 1" >&2382 $as_echo "$as_me: error: $2" >&2 374 383 as_fn_exit $as_status 375 384 } # as_fn_error … … 533 542 534 543 # Name of the host. 535 # hostname on some systems (SVR3.2, Linux) returns a bogus exit status,544 # hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status, 536 545 # so uname gets run too. 537 546 ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q` … … 557 566 PACKAGE_URL='' 558 567 568 # Factoring default headers for most tests. 569 ac_includes_default="\ 570 #include <stdio.h> 571 #ifdef HAVE_SYS_TYPES_H 572 # include <sys/types.h> 573 #endif 574 #ifdef HAVE_SYS_STAT_H 575 # include <sys/stat.h> 576 #endif 577 #ifdef STDC_HEADERS 578 # include <stdlib.h> 579 # include <stddef.h> 580 #else 581 # ifdef HAVE_STDLIB_H 582 # include <stdlib.h> 583 # endif 584 #endif 585 #ifdef HAVE_STRING_H 586 # if !defined STDC_HEADERS && defined HAVE_MEMORY_H 587 # include <memory.h> 588 # endif 589 # include <string.h> 590 #endif 591 #ifdef HAVE_STRINGS_H 592 # include <strings.h> 593 #endif 594 #ifdef HAVE_INTTYPES_H 595 # include <inttypes.h> 596 #endif 597 #ifdef HAVE_STDINT_H 598 # include <stdint.h> 599 #endif 600 #ifdef HAVE_UNISTD_H 601 # include <unistd.h> 602 #endif" 603 559 604 ac_subst_vars='LTLIBOBJS 560 605 LIBOBJS … … 566 611 ENABLE_GUI 567 612 MAKE 613 SHLIB_LDFLAGS 614 INSTALL_STUB_LIB 615 INSTALL_LIB 616 MAKE_STUB_LIB 617 MAKE_LIB 618 SHLIB_SUFFIX 619 SHLIB_CFLAGS 620 SHLIB_LD_LIBS 621 TK_SHLIB_LD_EXTRAS 622 TCL_SHLIB_LD_EXTRAS 623 SHLIB_LD 624 STLIB_LD 625 LD_SEARCH_FLAGS 626 CC_SEARCH_FLAGS 627 LDFLAGS_OPTIMIZE 628 LDFLAGS_DEBUG 629 CFLAGS_WARNING 630 CFLAGS_OPTIMIZE 631 CFLAGS_DEBUG 632 PLAT_SRCS 633 PLAT_OBJS 634 DL_OBJS 635 DL_LIBS 636 EGREP 637 GREP 638 CPP 639 AR 640 OBJEXT 641 EXEEXT 642 ac_ct_CC 643 CPPFLAGS 644 LDFLAGS 645 CFLAGS 646 CC 568 647 SET_MAKE 569 648 MKDIR_P … … 627 706 ac_user_opts=' 628 707 enable_option_checking 708 enable_64bit 709 enable_64bit_vis 710 enable_corefoundation 711 enable_load 712 enable_shared 629 713 enable_gui 630 714 with_tclsh … … 632 716 ac_precious_vars='build_alias 633 717 host_alias 634 target_alias' 718 target_alias 719 CC 720 CFLAGS 721 LDFLAGS 722 LIBS 723 CPPFLAGS 724 CPP' 635 725 636 726 … … 695 785 696 786 case $ac_option in 697 *=*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;; 698 *) ac_optarg=yes ;; 787 *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;; 788 *=) ac_optarg= ;; 789 *) ac_optarg=yes ;; 699 790 esac 700 791 … … 741 832 # Reject names that are not valid shell variable names. 742 833 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && 743 as_fn_error "invalid feature name: $ac_useropt"834 as_fn_error $? "invalid feature name: $ac_useropt" 744 835 ac_useropt_orig=$ac_useropt 745 836 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` … … 767 858 # Reject names that are not valid shell variable names. 768 859 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && 769 as_fn_error "invalid feature name: $ac_useropt"860 as_fn_error $? "invalid feature name: $ac_useropt" 770 861 ac_useropt_orig=$ac_useropt 771 862 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` … … 971 1062 # Reject names that are not valid shell variable names. 972 1063 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && 973 as_fn_error "invalid package name: $ac_useropt"1064 as_fn_error $? "invalid package name: $ac_useropt" 974 1065 ac_useropt_orig=$ac_useropt 975 1066 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` … … 987 1078 # Reject names that are not valid shell variable names. 988 1079 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && 989 as_fn_error "invalid package name: $ac_useropt"1080 as_fn_error $? "invalid package name: $ac_useropt" 990 1081 ac_useropt_orig=$ac_useropt 991 1082 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` … … 1017 1108 x_libraries=$ac_optarg ;; 1018 1109 1019 -*) as_fn_error "unrecognized option: \`$ac_option'1020 Try \`$0 --help' for more information ."1110 -*) as_fn_error $? "unrecognized option: \`$ac_option' 1111 Try \`$0 --help' for more information" 1021 1112 ;; 1022 1113 … … 1026 1117 case $ac_envvar in #( 1027 1118 '' | [0-9]* | *[!_$as_cr_alnum]* ) 1028 as_fn_error "invalid variable name: \`$ac_envvar'" ;;1119 as_fn_error $? "invalid variable name: \`$ac_envvar'" ;; 1029 1120 esac 1030 1121 eval $ac_envvar=\$ac_optarg … … 1036 1127 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null && 1037 1128 $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2 1038 : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}1129 : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}" 1039 1130 ;; 1040 1131 … … 1044 1135 if test -n "$ac_prev"; then 1045 1136 ac_option=--`echo $ac_prev | sed 's/_/-/g'` 1046 as_fn_error "missing argument to $ac_option"1137 as_fn_error $? "missing argument to $ac_option" 1047 1138 fi 1048 1139 … … 1050 1141 case $enable_option_checking in 1051 1142 no) ;; 1052 fatal) as_fn_error "unrecognized options: $ac_unrecognized_opts" ;;1143 fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;; 1053 1144 *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;; 1054 1145 esac … … 1073 1164 NONE | '' ) case $ac_var in *prefix ) continue;; esac;; 1074 1165 esac 1075 as_fn_error "expected an absolute directory name for --$ac_var: $ac_val"1166 as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val" 1076 1167 done 1077 1168 … … 1087 1178 if test "x$build_alias" = x; then 1088 1179 cross_compiling=maybe 1089 $as_echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.1090 If a cross compiler is detected then cross compile mode will be used ." >&21180 $as_echo "$as_me: WARNING: if you wanted to set the --build type, don't use --host. 1181 If a cross compiler is detected then cross compile mode will be used" >&2 1091 1182 elif test "x$build_alias" != "x$host_alias"; then 1092 1183 cross_compiling=yes … … 1103 1194 ac_ls_di=`ls -di .` && 1104 1195 ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` || 1105 as_fn_error "working directory cannot be determined"1196 as_fn_error $? "working directory cannot be determined" 1106 1197 test "X$ac_ls_di" = "X$ac_pwd_ls_di" || 1107 as_fn_error "pwd does not report name of working directory"1198 as_fn_error $? "pwd does not report name of working directory" 1108 1199 1109 1200 … … 1144 1235 if test ! -r "$srcdir/$ac_unique_file"; then 1145 1236 test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .." 1146 as_fn_error "cannot find sources ($ac_unique_file) in $srcdir"1237 as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir" 1147 1238 fi 1148 1239 ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work" 1149 1240 ac_abs_confdir=`( 1150 cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error "$ac_msg"1241 cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg" 1151 1242 pwd)` 1152 1243 # When building in place, set srcdir=. … … 1188 1279 --help=recursive display the short help of all the included packages 1189 1280 -V, --version display version information and exit 1190 -q, --quiet, --silent do not print \`checking ...' messages1281 -q, --quiet, --silent do not print \`checking ...' messages 1191 1282 --cache-file=FILE cache test results in FILE [disabled] 1192 1283 -C, --config-cache alias for \`--cache-file=config.cache' … … 1248 1339 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) 1249 1340 --enable-FEATURE[=ARG] include FEATURE [ARG=yes] 1341 --enable-64bit enable 64bit support (where applicable) 1342 --enable-64bit-vis enable 64bit Sparc VIS support 1343 --enable-corefoundation use CoreFoundation API --enable-corefoundation 1344 --disable-load disallow dynamic loading and "load" command 1345 --enable-shared build and link with shared libraries --enable-shared 1250 1346 --enable-gui build code related to the graphical user interface 1251 1347 [default=yes] … … 1255 1351 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) 1256 1352 --with-tclsh=DIR location of tclsh [default=yes] 1353 1354 Some influential environment variables: 1355 CC C compiler command 1356 CFLAGS C compiler flags 1357 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a 1358 nonstandard directory <lib dir> 1359 LIBS libraries to pass to the linker, e.g. -l<library> 1360 CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if 1361 you have headers in a nonstandard directory <include dir> 1362 CPP C preprocessor 1363 1364 Use these variables to override the choices made by `configure' or to help 1365 it to find libraries and programs with nonstandard names/locations. 1257 1366 1258 1367 Report bugs to <rappture@nanohub.org>. … … 1320 1429 cat <<\_ACEOF 1321 1430 RapptureGUI configure 1.1 1322 generated by GNU Autoconf 2.6 51323 1324 Copyright (C) 20 09Free Software Foundation, Inc.1431 generated by GNU Autoconf 2.68 1432 1433 Copyright (C) 2010 Free Software Foundation, Inc. 1325 1434 This configure script is free software; the Free Software Foundation 1326 1435 gives unlimited permission to copy, distribute and modify it. … … 1332 1441 ## Autoconf initialization. ## 1333 1442 ## ------------------------ ## 1443 1444 # ac_fn_c_try_compile LINENO 1445 # -------------------------- 1446 # Try to compile conftest.$ac_ext, and return whether this succeeded. 1447 ac_fn_c_try_compile () 1448 { 1449 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 1450 rm -f conftest.$ac_objext 1451 if { { ac_try="$ac_compile" 1452 case "(($ac_try" in 1453 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 1454 *) ac_try_echo=$ac_try;; 1455 esac 1456 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 1457 $as_echo "$ac_try_echo"; } >&5 1458 (eval "$ac_compile") 2>conftest.err 1459 ac_status=$? 1460 if test -s conftest.err; then 1461 grep -v '^ *+' conftest.err >conftest.er1 1462 cat conftest.er1 >&5 1463 mv -f conftest.er1 conftest.err 1464 fi 1465 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 1466 test $ac_status = 0; } && { 1467 test -z "$ac_c_werror_flag" || 1468 test ! -s conftest.err 1469 } && test -s conftest.$ac_objext; then : 1470 ac_retval=0 1471 else 1472 $as_echo "$as_me: failed program was:" >&5 1473 sed 's/^/| /' conftest.$ac_ext >&5 1474 1475 ac_retval=1 1476 fi 1477 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 1478 as_fn_set_status $ac_retval 1479 1480 } # ac_fn_c_try_compile 1481 1482 # ac_fn_c_try_link LINENO 1483 # ----------------------- 1484 # Try to link conftest.$ac_ext, and return whether this succeeded. 1485 ac_fn_c_try_link () 1486 { 1487 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 1488 rm -f conftest.$ac_objext conftest$ac_exeext 1489 if { { ac_try="$ac_link" 1490 case "(($ac_try" in 1491 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 1492 *) ac_try_echo=$ac_try;; 1493 esac 1494 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 1495 $as_echo "$ac_try_echo"; } >&5 1496 (eval "$ac_link") 2>conftest.err 1497 ac_status=$? 1498 if test -s conftest.err; then 1499 grep -v '^ *+' conftest.err >conftest.er1 1500 cat conftest.er1 >&5 1501 mv -f conftest.er1 conftest.err 1502 fi 1503 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 1504 test $ac_status = 0; } && { 1505 test -z "$ac_c_werror_flag" || 1506 test ! -s conftest.err 1507 } && test -s conftest$ac_exeext && { 1508 test "$cross_compiling" = yes || 1509 $as_test_x conftest$ac_exeext 1510 }; then : 1511 ac_retval=0 1512 else 1513 $as_echo "$as_me: failed program was:" >&5 1514 sed 's/^/| /' conftest.$ac_ext >&5 1515 1516 ac_retval=1 1517 fi 1518 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information 1519 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would 1520 # interfere with the next link command; also delete a directory that is 1521 # left behind by Apple's compiler. We do this before executing the actions. 1522 rm -rf conftest.dSYM conftest_ipa8_conftest.oo 1523 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 1524 as_fn_set_status $ac_retval 1525 1526 } # ac_fn_c_try_link 1527 1528 # ac_fn_c_try_cpp LINENO 1529 # ---------------------- 1530 # Try to preprocess conftest.$ac_ext, and return whether this succeeded. 1531 ac_fn_c_try_cpp () 1532 { 1533 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 1534 if { { ac_try="$ac_cpp conftest.$ac_ext" 1535 case "(($ac_try" in 1536 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 1537 *) ac_try_echo=$ac_try;; 1538 esac 1539 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 1540 $as_echo "$ac_try_echo"; } >&5 1541 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err 1542 ac_status=$? 1543 if test -s conftest.err; then 1544 grep -v '^ *+' conftest.err >conftest.er1 1545 cat conftest.er1 >&5 1546 mv -f conftest.er1 conftest.err 1547 fi 1548 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 1549 test $ac_status = 0; } > conftest.i && { 1550 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || 1551 test ! -s conftest.err 1552 }; then : 1553 ac_retval=0 1554 else 1555 $as_echo "$as_me: failed program was:" >&5 1556 sed 's/^/| /' conftest.$ac_ext >&5 1557 1558 ac_retval=1 1559 fi 1560 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 1561 as_fn_set_status $ac_retval 1562 1563 } # ac_fn_c_try_cpp 1564 1565 # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES 1566 # ------------------------------------------------------- 1567 # Tests whether HEADER exists, giving a warning if it cannot be compiled using 1568 # the include files in INCLUDES and setting the cache variable VAR 1569 # accordingly. 1570 ac_fn_c_check_header_mongrel () 1571 { 1572 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 1573 if eval \${$3+:} false; then : 1574 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 1575 $as_echo_n "checking for $2... " >&6; } 1576 if eval \${$3+:} false; then : 1577 $as_echo_n "(cached) " >&6 1578 fi 1579 eval ac_res=\$$3 1580 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 1581 $as_echo "$ac_res" >&6; } 1582 else 1583 # Is the header compilable? 1584 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5 1585 $as_echo_n "checking $2 usability... " >&6; } 1586 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 1587 /* end confdefs.h. */ 1588 $4 1589 #include <$2> 1590 _ACEOF 1591 if ac_fn_c_try_compile "$LINENO"; then : 1592 ac_header_compiler=yes 1593 else 1594 ac_header_compiler=no 1595 fi 1596 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 1597 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5 1598 $as_echo "$ac_header_compiler" >&6; } 1599 1600 # Is the header present? 1601 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5 1602 $as_echo_n "checking $2 presence... " >&6; } 1603 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 1604 /* end confdefs.h. */ 1605 #include <$2> 1606 _ACEOF 1607 if ac_fn_c_try_cpp "$LINENO"; then : 1608 ac_header_preproc=yes 1609 else 1610 ac_header_preproc=no 1611 fi 1612 rm -f conftest.err conftest.i conftest.$ac_ext 1613 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5 1614 $as_echo "$ac_header_preproc" >&6; } 1615 1616 # So? What about this header? 1617 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #(( 1618 yes:no: ) 1619 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5 1620 $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;} 1621 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 1622 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} 1623 ;; 1624 no:yes:* ) 1625 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5 1626 $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;} 1627 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5 1628 $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;} 1629 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5 1630 $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;} 1631 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5 1632 $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;} 1633 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 1634 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} 1635 ( $as_echo "## ----------------------------------- ## 1636 ## Report this to rappture@nanohub.org ## 1637 ## ----------------------------------- ##" 1638 ) | sed "s/^/$as_me: WARNING: /" >&2 1639 ;; 1640 esac 1641 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 1642 $as_echo_n "checking for $2... " >&6; } 1643 if eval \${$3+:} false; then : 1644 $as_echo_n "(cached) " >&6 1645 else 1646 eval "$3=\$ac_header_compiler" 1647 fi 1648 eval ac_res=\$$3 1649 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 1650 $as_echo "$ac_res" >&6; } 1651 fi 1652 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 1653 1654 } # ac_fn_c_check_header_mongrel 1655 1656 # ac_fn_c_try_run LINENO 1657 # ---------------------- 1658 # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes 1659 # that executables *can* be run. 1660 ac_fn_c_try_run () 1661 { 1662 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 1663 if { { ac_try="$ac_link" 1664 case "(($ac_try" in 1665 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 1666 *) ac_try_echo=$ac_try;; 1667 esac 1668 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 1669 $as_echo "$ac_try_echo"; } >&5 1670 (eval "$ac_link") 2>&5 1671 ac_status=$? 1672 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 1673 test $ac_status = 0; } && { ac_try='./conftest$ac_exeext' 1674 { { case "(($ac_try" in 1675 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 1676 *) ac_try_echo=$ac_try;; 1677 esac 1678 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 1679 $as_echo "$ac_try_echo"; } >&5 1680 (eval "$ac_try") 2>&5 1681 ac_status=$? 1682 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 1683 test $ac_status = 0; }; }; then : 1684 ac_retval=0 1685 else 1686 $as_echo "$as_me: program exited with status $ac_status" >&5 1687 $as_echo "$as_me: failed program was:" >&5 1688 sed 's/^/| /' conftest.$ac_ext >&5 1689 1690 ac_retval=$ac_status 1691 fi 1692 rm -rf conftest.dSYM conftest_ipa8_conftest.oo 1693 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 1694 as_fn_set_status $ac_retval 1695 1696 } # ac_fn_c_try_run 1697 1698 # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES 1699 # ------------------------------------------------------- 1700 # Tests whether HEADER exists and can be compiled using the include files in 1701 # INCLUDES, setting the cache variable VAR accordingly. 1702 ac_fn_c_check_header_compile () 1703 { 1704 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 1705 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 1706 $as_echo_n "checking for $2... " >&6; } 1707 if eval \${$3+:} false; then : 1708 $as_echo_n "(cached) " >&6 1709 else 1710 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 1711 /* end confdefs.h. */ 1712 $4 1713 #include <$2> 1714 _ACEOF 1715 if ac_fn_c_try_compile "$LINENO"; then : 1716 eval "$3=yes" 1717 else 1718 eval "$3=no" 1719 fi 1720 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 1721 fi 1722 eval ac_res=\$$3 1723 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 1724 $as_echo "$ac_res" >&6; } 1725 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 1726 1727 } # ac_fn_c_check_header_compile 1334 1728 cat >config.log <<_ACEOF 1335 1729 This file contains any messages produced by compilers while … … 1337 1731 1338 1732 It was created by RapptureGUI $as_me 1.1, which was 1339 generated by GNU Autoconf 2.6 5. Invocation command line was1733 generated by GNU Autoconf 2.68. Invocation command line was 1340 1734 1341 1735 $ $0 $@ … … 1447 1841 echo 1448 1842 1449 cat <<\_ASBOX 1450 ## ---------------- ## 1843 $as_echo "## ---------------- ## 1451 1844 ## Cache variables. ## 1452 ## ---------------- ## 1453 _ASBOX 1845 ## ---------------- ##" 1454 1846 echo 1455 1847 # The following way of writing the cache mishandles newlines in values, … … 1485 1877 echo 1486 1878 1487 cat <<\_ASBOX 1488 ## ----------------- ## 1879 $as_echo "## ----------------- ## 1489 1880 ## Output variables. ## 1490 ## ----------------- ## 1491 _ASBOX 1881 ## ----------------- ##" 1492 1882 echo 1493 1883 for ac_var in $ac_subst_vars … … 1502 1892 1503 1893 if test -n "$ac_subst_files"; then 1504 cat <<\_ASBOX 1505 ## ------------------- ## 1894 $as_echo "## ------------------- ## 1506 1895 ## File substitutions. ## 1507 ## ------------------- ## 1508 _ASBOX 1896 ## ------------------- ##" 1509 1897 echo 1510 1898 for ac_var in $ac_subst_files … … 1520 1908 1521 1909 if test -s confdefs.h; then 1522 cat <<\_ASBOX 1523 ## ----------- ## 1910 $as_echo "## ----------- ## 1524 1911 ## confdefs.h. ## 1525 ## ----------- ## 1526 _ASBOX 1912 ## ----------- ##" 1527 1913 echo 1528 1914 cat confdefs.h … … 1579 1965 ac_site_file2=NONE 1580 1966 if test -n "$CONFIG_SITE"; then 1581 ac_site_file1=$CONFIG_SITE 1967 # We do not want a PATH search for config.site. 1968 case $CONFIG_SITE in #(( 1969 -*) ac_site_file1=./$CONFIG_SITE;; 1970 */*) ac_site_file1=$CONFIG_SITE;; 1971 *) ac_site_file1=./$CONFIG_SITE;; 1972 esac 1582 1973 elif test "x$prefix" != xNONE; then 1583 1974 ac_site_file1=$prefix/share/config.site … … 1594 1985 $as_echo "$as_me: loading site script $ac_site_file" >&6;} 1595 1986 sed 's/^/| /' "$ac_site_file" >&5 1596 . "$ac_site_file" 1987 . "$ac_site_file" \ 1988 || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 1989 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 1990 as_fn_error $? "failed to load site script $ac_site_file 1991 See \`config.log' for more details" "$LINENO" 5; } 1597 1992 fi 1598 1993 done … … 1670 2065 { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5 1671 2066 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;} 1672 as_fn_error "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 52067 as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5 1673 2068 fi 1674 2069 ## -------------------- ## … … 1685 2080 ac_aux_dir= 1686 2081 for ac_dir in cf "$srcdir"/cf; do 1687 for ac_t in install-sh install.sh shtool; do 1688 if test -f "$ac_dir/$ac_t"; then 1689 ac_aux_dir=$ac_dir 1690 ac_install_sh="$ac_aux_dir/$ac_t -c" 1691 break 2 1692 fi 1693 done 2082 if test -f "$ac_dir/install-sh"; then 2083 ac_aux_dir=$ac_dir 2084 ac_install_sh="$ac_aux_dir/install-sh -c" 2085 break 2086 elif test -f "$ac_dir/install.sh"; then 2087 ac_aux_dir=$ac_dir 2088 ac_install_sh="$ac_aux_dir/install.sh -c" 2089 break 2090 elif test -f "$ac_dir/shtool"; then 2091 ac_aux_dir=$ac_dir 2092 ac_install_sh="$ac_aux_dir/shtool install -c" 2093 break 2094 fi 1694 2095 done 1695 2096 if test -z "$ac_aux_dir"; then 1696 as_fn_error "cannot find install-sh, install.sh, or shtool in cf \"$srcdir\"/cf" "$LINENO" 52097 as_fn_error $? "cannot find install-sh, install.sh, or shtool in cf \"$srcdir\"/cf" "$LINENO" 5 1697 2098 fi 1698 2099 … … 1724 2125 # Make sure we can run config.sub. 1725 2126 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 || 1726 as_fn_error "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 52127 as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5 1727 2128 1728 2129 { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5 1729 2130 $as_echo_n "checking build system type... " >&6; } 1730 if test "${ac_cv_build+set}" = set; then :2131 if ${ac_cv_build+:} false; then : 1731 2132 $as_echo_n "(cached) " >&6 1732 2133 else … … 1735 2136 ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"` 1736 2137 test "x$ac_build_alias" = x && 1737 as_fn_error "cannot guess build type; you must specify one" "$LINENO" 52138 as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5 1738 2139 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` || 1739 as_fn_error "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 52140 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5 1740 2141 1741 2142 fi … … 1744 2145 case $ac_cv_build in 1745 2146 *-*-*) ;; 1746 *) as_fn_error "invalid value of canonical build" "$LINENO" 5;;2147 *) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;; 1747 2148 esac 1748 2149 build=$ac_cv_build … … 1762 2163 { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5 1763 2164 $as_echo_n "checking host system type... " >&6; } 1764 if test "${ac_cv_host+set}" = set; then :2165 if ${ac_cv_host+:} false; then : 1765 2166 $as_echo_n "(cached) " >&6 1766 2167 else … … 1769 2170 else 1770 2171 ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` || 1771 as_fn_error "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 52172 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5 1772 2173 fi 1773 2174 … … 1777 2178 case $ac_cv_host in 1778 2179 *-*-*) ;; 1779 *) as_fn_error "invalid value of canonical host" "$LINENO" 5;;2180 *) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;; 1780 2181 esac 1781 2182 host=$ac_cv_host … … 1795 2196 { $as_echo "$as_me:${as_lineno-$LINENO}: checking target system type" >&5 1796 2197 $as_echo_n "checking target system type... " >&6; } 1797 if test "${ac_cv_target+set}" = set; then :2198 if ${ac_cv_target+:} false; then : 1798 2199 $as_echo_n "(cached) " >&6 1799 2200 else … … 1802 2203 else 1803 2204 ac_cv_target=`$SHELL "$ac_aux_dir/config.sub" $target_alias` || 1804 as_fn_error "$SHELL $ac_aux_dir/config.sub $target_alias failed" "$LINENO" 52205 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $target_alias failed" "$LINENO" 5 1805 2206 fi 1806 2207 … … 1810 2211 case $ac_cv_target in 1811 2212 *-*-*) ;; 1812 *) as_fn_error "invalid value of canonical target" "$LINENO" 5;;2213 *) as_fn_error $? "invalid value of canonical target" "$LINENO" 5;; 1813 2214 esac 1814 2215 target=$ac_cv_target … … 1851 2252 $as_echo_n "checking for a BSD-compatible install... " >&6; } 1852 2253 if test -z "$INSTALL"; then 1853 if test "${ac_cv_path_install+set}" = set; then :2254 if ${ac_cv_path_install+:} false; then : 1854 2255 $as_echo_n "(cached) " >&6 1855 2256 else … … 1933 2334 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 1934 2335 $as_echo_n "checking for $ac_word... " >&6; } 1935 if test "${ac_cv_prog_RANLIB+set}" = set; then :2336 if ${ac_cv_prog_RANLIB+:} false; then : 1936 2337 $as_echo_n "(cached) " >&6 1937 2338 else … … 1973 2374 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 1974 2375 $as_echo_n "checking for $ac_word... " >&6; } 1975 if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then :2376 if ${ac_cv_prog_ac_ct_RANLIB+:} false; then : 1976 2377 $as_echo_n "(cached) " >&6 1977 2378 else … … 2034 2435 $as_echo_n "checking for a thread-safe mkdir -p... " >&6; } 2035 2436 if test -z "$MKDIR_P"; then 2036 if test "${ac_cv_path_mkdir+set}" = set; then :2437 if ${ac_cv_path_mkdir+:} false; then : 2037 2438 $as_echo_n "(cached) " >&6 2038 2439 else … … 2077 2478 set x ${MAKE-make} 2078 2479 ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'` 2079 if { as_var=ac_cv_prog_make_${ac_make}_set; eval "test \"\${$as_var+set}\" = set"; }; then :2480 if eval \${ac_cv_prog_make_${ac_make}_set+:} false; then : 2080 2481 $as_echo_n "(cached) " >&6 2081 2482 else … … 2085 2486 @echo '@@@%%%=$(MAKE)=@@@%%%' 2086 2487 _ACEOF 2087 # GNU make sometimes prints "make[1]: Entering ...", which would confuse us.2488 # GNU make sometimes prints "make[1]: Entering ...", which would confuse us. 2088 2489 case `${MAKE-make} -f conftest.make 2>/dev/null` in 2089 2490 *@@@%%%=?*=@@@%%%*) … … 2103 2504 SET_MAKE="MAKE=${MAKE-make}" 2104 2505 fi 2506 2507 ac_ext=c 2508 ac_cpp='$CPP $CPPFLAGS' 2509 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 2510 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 2511 ac_compiler_gnu=$ac_cv_c_compiler_gnu 2512 if test -n "$ac_tool_prefix"; then 2513 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args. 2514 set dummy ${ac_tool_prefix}gcc; ac_word=$2 2515 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 2516 $as_echo_n "checking for $ac_word... " >&6; } 2517 if ${ac_cv_prog_CC+:} false; then : 2518 $as_echo_n "(cached) " >&6 2519 else 2520 if test -n "$CC"; then 2521 ac_cv_prog_CC="$CC" # Let the user override the test. 2522 else 2523 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 2524 for as_dir in $PATH 2525 do 2526 IFS=$as_save_IFS 2527 test -z "$as_dir" && as_dir=. 2528 for ac_exec_ext in '' $ac_executable_extensions; do 2529 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 2530 ac_cv_prog_CC="${ac_tool_prefix}gcc" 2531 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 2532 break 2 2533 fi 2534 done 2535 done 2536 IFS=$as_save_IFS 2537 2538 fi 2539 fi 2540 CC=$ac_cv_prog_CC 2541 if test -n "$CC"; then 2542 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 2543 $as_echo "$CC" >&6; } 2544 else 2545 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 2546 $as_echo "no" >&6; } 2547 fi 2548 2549 2550 fi 2551 if test -z "$ac_cv_prog_CC"; then 2552 ac_ct_CC=$CC 2553 # Extract the first word of "gcc", so it can be a program name with args. 2554 set dummy gcc; ac_word=$2 2555 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 2556 $as_echo_n "checking for $ac_word... " >&6; } 2557 if ${ac_cv_prog_ac_ct_CC+:} false; then : 2558 $as_echo_n "(cached) " >&6 2559 else 2560 if test -n "$ac_ct_CC"; then 2561 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. 2562 else 2563 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 2564 for as_dir in $PATH 2565 do 2566 IFS=$as_save_IFS 2567 test -z "$as_dir" && as_dir=. 2568 for ac_exec_ext in '' $ac_executable_extensions; do 2569 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 2570 ac_cv_prog_ac_ct_CC="gcc" 2571 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 2572 break 2 2573 fi 2574 done 2575 done 2576 IFS=$as_save_IFS 2577 2578 fi 2579 fi 2580 ac_ct_CC=$ac_cv_prog_ac_ct_CC 2581 if test -n "$ac_ct_CC"; then 2582 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 2583 $as_echo "$ac_ct_CC" >&6; } 2584 else 2585 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 2586 $as_echo "no" >&6; } 2587 fi 2588 2589 if test "x$ac_ct_CC" = x; then 2590 CC="" 2591 else 2592 case $cross_compiling:$ac_tool_warned in 2593 yes:) 2594 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 2595 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 2596 ac_tool_warned=yes ;; 2597 esac 2598 CC=$ac_ct_CC 2599 fi 2600 else 2601 CC="$ac_cv_prog_CC" 2602 fi 2603 2604 if test -z "$CC"; then 2605 if test -n "$ac_tool_prefix"; then 2606 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args. 2607 set dummy ${ac_tool_prefix}cc; ac_word=$2 2608 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 2609 $as_echo_n "checking for $ac_word... " >&6; } 2610 if ${ac_cv_prog_CC+:} false; then : 2611 $as_echo_n "(cached) " >&6 2612 else 2613 if test -n "$CC"; then 2614 ac_cv_prog_CC="$CC" # Let the user override the test. 2615 else 2616 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 2617 for as_dir in $PATH 2618 do 2619 IFS=$as_save_IFS 2620 test -z "$as_dir" && as_dir=. 2621 for ac_exec_ext in '' $ac_executable_extensions; do 2622 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 2623 ac_cv_prog_CC="${ac_tool_prefix}cc" 2624 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 2625 break 2 2626 fi 2627 done 2628 done 2629 IFS=$as_save_IFS 2630 2631 fi 2632 fi 2633 CC=$ac_cv_prog_CC 2634 if test -n "$CC"; then 2635 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 2636 $as_echo "$CC" >&6; } 2637 else 2638 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 2639 $as_echo "no" >&6; } 2640 fi 2641 2642 2643 fi 2644 fi 2645 if test -z "$CC"; then 2646 # Extract the first word of "cc", so it can be a program name with args. 2647 set dummy cc; ac_word=$2 2648 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 2649 $as_echo_n "checking for $ac_word... " >&6; } 2650 if ${ac_cv_prog_CC+:} false; then : 2651 $as_echo_n "(cached) " >&6 2652 else 2653 if test -n "$CC"; then 2654 ac_cv_prog_CC="$CC" # Let the user override the test. 2655 else 2656 ac_prog_rejected=no 2657 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 2658 for as_dir in $PATH 2659 do 2660 IFS=$as_save_IFS 2661 test -z "$as_dir" && as_dir=. 2662 for ac_exec_ext in '' $ac_executable_extensions; do 2663 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 2664 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then 2665 ac_prog_rejected=yes 2666 continue 2667 fi 2668 ac_cv_prog_CC="cc" 2669 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 2670 break 2 2671 fi 2672 done 2673 done 2674 IFS=$as_save_IFS 2675 2676 if test $ac_prog_rejected = yes; then 2677 # We found a bogon in the path, so make sure we never use it. 2678 set dummy $ac_cv_prog_CC 2679 shift 2680 if test $# != 0; then 2681 # We chose a different compiler from the bogus one. 2682 # However, it has the same basename, so the bogon will be chosen 2683 # first if we set CC to just the basename; use the full file name. 2684 shift 2685 ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@" 2686 fi 2687 fi 2688 fi 2689 fi 2690 CC=$ac_cv_prog_CC 2691 if test -n "$CC"; then 2692 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 2693 $as_echo "$CC" >&6; } 2694 else 2695 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 2696 $as_echo "no" >&6; } 2697 fi 2698 2699 2700 fi 2701 if test -z "$CC"; then 2702 if test -n "$ac_tool_prefix"; then 2703 for ac_prog in cl.exe 2704 do 2705 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 2706 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 2707 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 2708 $as_echo_n "checking for $ac_word... " >&6; } 2709 if ${ac_cv_prog_CC+:} false; then : 2710 $as_echo_n "(cached) " >&6 2711 else 2712 if test -n "$CC"; then 2713 ac_cv_prog_CC="$CC" # Let the user override the test. 2714 else 2715 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 2716 for as_dir in $PATH 2717 do 2718 IFS=$as_save_IFS 2719 test -z "$as_dir" && as_dir=. 2720 for ac_exec_ext in '' $ac_executable_extensions; do 2721 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 2722 ac_cv_prog_CC="$ac_tool_prefix$ac_prog" 2723 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 2724 break 2 2725 fi 2726 done 2727 done 2728 IFS=$as_save_IFS 2729 2730 fi 2731 fi 2732 CC=$ac_cv_prog_CC 2733 if test -n "$CC"; then 2734 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 2735 $as_echo "$CC" >&6; } 2736 else 2737 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 2738 $as_echo "no" >&6; } 2739 fi 2740 2741 2742 test -n "$CC" && break 2743 done 2744 fi 2745 if test -z "$CC"; then 2746 ac_ct_CC=$CC 2747 for ac_prog in cl.exe 2748 do 2749 # Extract the first word of "$ac_prog", so it can be a program name with args. 2750 set dummy $ac_prog; ac_word=$2 2751 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 2752 $as_echo_n "checking for $ac_word... " >&6; } 2753 if ${ac_cv_prog_ac_ct_CC+:} false; then : 2754 $as_echo_n "(cached) " >&6 2755 else 2756 if test -n "$ac_ct_CC"; then 2757 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. 2758 else 2759 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 2760 for as_dir in $PATH 2761 do 2762 IFS=$as_save_IFS 2763 test -z "$as_dir" && as_dir=. 2764 for ac_exec_ext in '' $ac_executable_extensions; do 2765 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 2766 ac_cv_prog_ac_ct_CC="$ac_prog" 2767 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 2768 break 2 2769 fi 2770 done 2771 done 2772 IFS=$as_save_IFS 2773 2774 fi 2775 fi 2776 ac_ct_CC=$ac_cv_prog_ac_ct_CC 2777 if test -n "$ac_ct_CC"; then 2778 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 2779 $as_echo "$ac_ct_CC" >&6; } 2780 else 2781 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 2782 $as_echo "no" >&6; } 2783 fi 2784 2785 2786 test -n "$ac_ct_CC" && break 2787 done 2788 2789 if test "x$ac_ct_CC" = x; then 2790 CC="" 2791 else 2792 case $cross_compiling:$ac_tool_warned in 2793 yes:) 2794 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 2795 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 2796 ac_tool_warned=yes ;; 2797 esac 2798 CC=$ac_ct_CC 2799 fi 2800 fi 2801 2802 fi 2803 2804 2805 test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 2806 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 2807 as_fn_error $? "no acceptable C compiler found in \$PATH 2808 See \`config.log' for more details" "$LINENO" 5; } 2809 2810 # Provide some information about the compiler. 2811 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5 2812 set X $ac_compile 2813 ac_compiler=$2 2814 for ac_option in --version -v -V -qversion; do 2815 { { ac_try="$ac_compiler $ac_option >&5" 2816 case "(($ac_try" in 2817 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2818 *) ac_try_echo=$ac_try;; 2819 esac 2820 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2821 $as_echo "$ac_try_echo"; } >&5 2822 (eval "$ac_compiler $ac_option >&5") 2>conftest.err 2823 ac_status=$? 2824 if test -s conftest.err; then 2825 sed '10a\ 2826 ... rest of stderr output deleted ... 2827 10q' conftest.err >conftest.er1 2828 cat conftest.er1 >&5 2829 fi 2830 rm -f conftest.er1 conftest.err 2831 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2832 test $ac_status = 0; } 2833 done 2834 2835 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2836 /* end confdefs.h. */ 2837 2838 int 2839 main () 2840 { 2841 2842 ; 2843 return 0; 2844 } 2845 _ACEOF 2846 ac_clean_files_save=$ac_clean_files 2847 ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out" 2848 # Try to create an executable without -o first, disregard a.out. 2849 # It will help us diagnose broken compilers, and finding out an intuition 2850 # of exeext. 2851 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5 2852 $as_echo_n "checking whether the C compiler works... " >&6; } 2853 ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'` 2854 2855 # The possible output files: 2856 ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*" 2857 2858 ac_rmfiles= 2859 for ac_file in $ac_files 2860 do 2861 case $ac_file in 2862 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; 2863 * ) ac_rmfiles="$ac_rmfiles $ac_file";; 2864 esac 2865 done 2866 rm -f $ac_rmfiles 2867 2868 if { { ac_try="$ac_link_default" 2869 case "(($ac_try" in 2870 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2871 *) ac_try_echo=$ac_try;; 2872 esac 2873 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2874 $as_echo "$ac_try_echo"; } >&5 2875 (eval "$ac_link_default") 2>&5 2876 ac_status=$? 2877 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2878 test $ac_status = 0; }; then : 2879 # Autoconf-2.13 could set the ac_cv_exeext variable to `no'. 2880 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no' 2881 # in a Makefile. We should not override ac_cv_exeext if it was cached, 2882 # so that the user can short-circuit this test for compilers unknown to 2883 # Autoconf. 2884 for ac_file in $ac_files '' 2885 do 2886 test -f "$ac_file" || continue 2887 case $ac_file in 2888 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) 2889 ;; 2890 [ab].out ) 2891 # We found the default executable, but exeext='' is most 2892 # certainly right. 2893 break;; 2894 *.* ) 2895 if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no; 2896 then :; else 2897 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` 2898 fi 2899 # We set ac_cv_exeext here because the later test for it is not 2900 # safe: cross compilers may not add the suffix if given an `-o' 2901 # argument, so we may need to know it at that point already. 2902 # Even if this section looks crufty: it has the advantage of 2903 # actually working. 2904 break;; 2905 * ) 2906 break;; 2907 esac 2908 done 2909 test "$ac_cv_exeext" = no && ac_cv_exeext= 2910 2911 else 2912 ac_file='' 2913 fi 2914 if test -z "$ac_file"; then : 2915 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 2916 $as_echo "no" >&6; } 2917 $as_echo "$as_me: failed program was:" >&5 2918 sed 's/^/| /' conftest.$ac_ext >&5 2919 2920 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 2921 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 2922 as_fn_error 77 "C compiler cannot create executables 2923 See \`config.log' for more details" "$LINENO" 5; } 2924 else 2925 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 2926 $as_echo "yes" >&6; } 2927 fi 2928 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5 2929 $as_echo_n "checking for C compiler default output file name... " >&6; } 2930 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5 2931 $as_echo "$ac_file" >&6; } 2932 ac_exeext=$ac_cv_exeext 2933 2934 rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out 2935 ac_clean_files=$ac_clean_files_save 2936 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5 2937 $as_echo_n "checking for suffix of executables... " >&6; } 2938 if { { ac_try="$ac_link" 2939 case "(($ac_try" in 2940 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2941 *) ac_try_echo=$ac_try;; 2942 esac 2943 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2944 $as_echo "$ac_try_echo"; } >&5 2945 (eval "$ac_link") 2>&5 2946 ac_status=$? 2947 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2948 test $ac_status = 0; }; then : 2949 # If both `conftest.exe' and `conftest' are `present' (well, observable) 2950 # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will 2951 # work properly (i.e., refer to `conftest.exe'), while it won't with 2952 # `rm'. 2953 for ac_file in conftest.exe conftest conftest.*; do 2954 test -f "$ac_file" || continue 2955 case $ac_file in 2956 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; 2957 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` 2958 break;; 2959 * ) break;; 2960 esac 2961 done 2962 else 2963 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 2964 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 2965 as_fn_error $? "cannot compute suffix of executables: cannot compile and link 2966 See \`config.log' for more details" "$LINENO" 5; } 2967 fi 2968 rm -f conftest conftest$ac_cv_exeext 2969 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5 2970 $as_echo "$ac_cv_exeext" >&6; } 2971 2972 rm -f conftest.$ac_ext 2973 EXEEXT=$ac_cv_exeext 2974 ac_exeext=$EXEEXT 2975 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2976 /* end confdefs.h. */ 2977 #include <stdio.h> 2978 int 2979 main () 2980 { 2981 FILE *f = fopen ("conftest.out", "w"); 2982 return ferror (f) || fclose (f) != 0; 2983 2984 ; 2985 return 0; 2986 } 2987 _ACEOF 2988 ac_clean_files="$ac_clean_files conftest.out" 2989 # Check that the compiler produces executables we can run. If not, either 2990 # the compiler is broken, or we cross compile. 2991 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5 2992 $as_echo_n "checking whether we are cross compiling... " >&6; } 2993 if test "$cross_compiling" != yes; then 2994 { { ac_try="$ac_link" 2995 case "(($ac_try" in 2996 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2997 *) ac_try_echo=$ac_try;; 2998 esac 2999 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 3000 $as_echo "$ac_try_echo"; } >&5 3001 (eval "$ac_link") 2>&5 3002 ac_status=$? 3003 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 3004 test $ac_status = 0; } 3005 if { ac_try='./conftest$ac_cv_exeext' 3006 { { case "(($ac_try" in 3007 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 3008 *) ac_try_echo=$ac_try;; 3009 esac 3010 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 3011 $as_echo "$ac_try_echo"; } >&5 3012 (eval "$ac_try") 2>&5 3013 ac_status=$? 3014 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 3015 test $ac_status = 0; }; }; then 3016 cross_compiling=no 3017 else 3018 if test "$cross_compiling" = maybe; then 3019 cross_compiling=yes 3020 else 3021 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 3022 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 3023 as_fn_error $? "cannot run C compiled programs. 3024 If you meant to cross compile, use \`--host'. 3025 See \`config.log' for more details" "$LINENO" 5; } 3026 fi 3027 fi 3028 fi 3029 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5 3030 $as_echo "$cross_compiling" >&6; } 3031 3032 rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out 3033 ac_clean_files=$ac_clean_files_save 3034 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5 3035 $as_echo_n "checking for suffix of object files... " >&6; } 3036 if ${ac_cv_objext+:} false; then : 3037 $as_echo_n "(cached) " >&6 3038 else 3039 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 3040 /* end confdefs.h. */ 3041 3042 int 3043 main () 3044 { 3045 3046 ; 3047 return 0; 3048 } 3049 _ACEOF 3050 rm -f conftest.o conftest.obj 3051 if { { ac_try="$ac_compile" 3052 case "(($ac_try" in 3053 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 3054 *) ac_try_echo=$ac_try;; 3055 esac 3056 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 3057 $as_echo "$ac_try_echo"; } >&5 3058 (eval "$ac_compile") 2>&5 3059 ac_status=$? 3060 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 3061 test $ac_status = 0; }; then : 3062 for ac_file in conftest.o conftest.obj conftest.*; do 3063 test -f "$ac_file" || continue; 3064 case $ac_file in 3065 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;; 3066 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'` 3067 break;; 3068 esac 3069 done 3070 else 3071 $as_echo "$as_me: failed program was:" >&5 3072 sed 's/^/| /' conftest.$ac_ext >&5 3073 3074 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 3075 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 3076 as_fn_error $? "cannot compute suffix of object files: cannot compile 3077 See \`config.log' for more details" "$LINENO" 5; } 3078 fi 3079 rm -f conftest.$ac_cv_objext conftest.$ac_ext 3080 fi 3081 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5 3082 $as_echo "$ac_cv_objext" >&6; } 3083 OBJEXT=$ac_cv_objext 3084 ac_objext=$OBJEXT 3085 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5 3086 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; } 3087 if ${ac_cv_c_compiler_gnu+:} false; then : 3088 $as_echo_n "(cached) " >&6 3089 else 3090 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 3091 /* end confdefs.h. */ 3092 3093 int 3094 main () 3095 { 3096 #ifndef __GNUC__ 3097 choke me 3098 #endif 3099 3100 ; 3101 return 0; 3102 } 3103 _ACEOF 3104 if ac_fn_c_try_compile "$LINENO"; then : 3105 ac_compiler_gnu=yes 3106 else 3107 ac_compiler_gnu=no 3108 fi 3109 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 3110 ac_cv_c_compiler_gnu=$ac_compiler_gnu 3111 3112 fi 3113 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5 3114 $as_echo "$ac_cv_c_compiler_gnu" >&6; } 3115 if test $ac_compiler_gnu = yes; then 3116 GCC=yes 3117 else 3118 GCC= 3119 fi 3120 ac_test_CFLAGS=${CFLAGS+set} 3121 ac_save_CFLAGS=$CFLAGS 3122 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5 3123 $as_echo_n "checking whether $CC accepts -g... " >&6; } 3124 if ${ac_cv_prog_cc_g+:} false; then : 3125 $as_echo_n "(cached) " >&6 3126 else 3127 ac_save_c_werror_flag=$ac_c_werror_flag 3128 ac_c_werror_flag=yes 3129 ac_cv_prog_cc_g=no 3130 CFLAGS="-g" 3131 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 3132 /* end confdefs.h. */ 3133 3134 int 3135 main () 3136 { 3137 3138 ; 3139 return 0; 3140 } 3141 _ACEOF 3142 if ac_fn_c_try_compile "$LINENO"; then : 3143 ac_cv_prog_cc_g=yes 3144 else 3145 CFLAGS="" 3146 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 3147 /* end confdefs.h. */ 3148 3149 int 3150 main () 3151 { 3152 3153 ; 3154 return 0; 3155 } 3156 _ACEOF 3157 if ac_fn_c_try_compile "$LINENO"; then : 3158 3159 else 3160 ac_c_werror_flag=$ac_save_c_werror_flag 3161 CFLAGS="-g" 3162 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 3163 /* end confdefs.h. */ 3164 3165 int 3166 main () 3167 { 3168 3169 ; 3170 return 0; 3171 } 3172 _ACEOF 3173 if ac_fn_c_try_compile "$LINENO"; then : 3174 ac_cv_prog_cc_g=yes 3175 fi 3176 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 3177 fi 3178 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 3179 fi 3180 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 3181 ac_c_werror_flag=$ac_save_c_werror_flag 3182 fi 3183 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5 3184 $as_echo "$ac_cv_prog_cc_g" >&6; } 3185 if test "$ac_test_CFLAGS" = set; then 3186 CFLAGS=$ac_save_CFLAGS 3187 elif test $ac_cv_prog_cc_g = yes; then 3188 if test "$GCC" = yes; then 3189 CFLAGS="-g -O2" 3190 else 3191 CFLAGS="-g" 3192 fi 3193 else 3194 if test "$GCC" = yes; then 3195 CFLAGS="-O2" 3196 else 3197 CFLAGS= 3198 fi 3199 fi 3200 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5 3201 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; } 3202 if ${ac_cv_prog_cc_c89+:} false; then : 3203 $as_echo_n "(cached) " >&6 3204 else 3205 ac_cv_prog_cc_c89=no 3206 ac_save_CC=$CC 3207 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 3208 /* end confdefs.h. */ 3209 #include <stdarg.h> 3210 #include <stdio.h> 3211 #include <sys/types.h> 3212 #include <sys/stat.h> 3213 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ 3214 struct buf { int x; }; 3215 FILE * (*rcsopen) (struct buf *, struct stat *, int); 3216 static char *e (p, i) 3217 char **p; 3218 int i; 3219 { 3220 return p[i]; 3221 } 3222 static char *f (char * (*g) (char **, int), char **p, ...) 3223 { 3224 char *s; 3225 va_list v; 3226 va_start (v,p); 3227 s = g (p, va_arg (v,int)); 3228 va_end (v); 3229 return s; 3230 } 3231 3232 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has 3233 function prototypes and stuff, but not '\xHH' hex character constants. 3234 These don't provoke an error unfortunately, instead are silently treated 3235 as 'x'. The following induces an error, until -std is added to get 3236 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an 3237 array size at least. It's necessary to write '\x00'==0 to get something 3238 that's true only with -std. */ 3239 int osf4_cc_array ['\x00' == 0 ? 1 : -1]; 3240 3241 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters 3242 inside strings and character constants. */ 3243 #define FOO(x) 'x' 3244 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1]; 3245 3246 int test (int i, double x); 3247 struct s1 {int (*f) (int a);}; 3248 struct s2 {int (*f) (double a);}; 3249 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int); 3250 int argc; 3251 char **argv; 3252 int 3253 main () 3254 { 3255 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]; 3256 ; 3257 return 0; 3258 } 3259 _ACEOF 3260 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \ 3261 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" 3262 do 3263 CC="$ac_save_CC $ac_arg" 3264 if ac_fn_c_try_compile "$LINENO"; then : 3265 ac_cv_prog_cc_c89=$ac_arg 3266 fi 3267 rm -f core conftest.err conftest.$ac_objext 3268 test "x$ac_cv_prog_cc_c89" != "xno" && break 3269 done 3270 rm -f conftest.$ac_ext 3271 CC=$ac_save_CC 3272 3273 fi 3274 # AC_CACHE_VAL 3275 case "x$ac_cv_prog_cc_c89" in 3276 x) 3277 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 3278 $as_echo "none needed" >&6; } ;; 3279 xno) 3280 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 3281 $as_echo "unsupported" >&6; } ;; 3282 *) 3283 CC="$CC $ac_cv_prog_cc_c89" 3284 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5 3285 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;; 3286 esac 3287 if test "x$ac_cv_prog_cc_c89" != xno; then : 3288 3289 fi 3290 3291 ac_ext=c 3292 ac_cpp='$CPP $CPPFLAGS' 3293 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 3294 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 3295 ac_compiler_gnu=$ac_cv_c_compiler_gnu 3296 3297 3298 3299 ac_ext=c 3300 ac_cpp='$CPP $CPPFLAGS' 3301 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 3302 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 3303 ac_compiler_gnu=$ac_cv_c_compiler_gnu 3304 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5 3305 $as_echo_n "checking how to run the C preprocessor... " >&6; } 3306 # On Suns, sometimes $CPP names a directory. 3307 if test -n "$CPP" && test -d "$CPP"; then 3308 CPP= 3309 fi 3310 if test -z "$CPP"; then 3311 if ${ac_cv_prog_CPP+:} false; then : 3312 $as_echo_n "(cached) " >&6 3313 else 3314 # Double quotes because CPP needs to be expanded 3315 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp" 3316 do 3317 ac_preproc_ok=false 3318 for ac_c_preproc_warn_flag in '' yes 3319 do 3320 # Use a header file that comes with gcc, so configuring glibc 3321 # with a fresh cross-compiler works. 3322 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since 3323 # <limits.h> exists even on freestanding compilers. 3324 # On the NeXT, cc -E runs the code through the compiler's parser, 3325 # not just through cpp. "Syntax error" is here to catch this case. 3326 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 3327 /* end confdefs.h. */ 3328 #ifdef __STDC__ 3329 # include <limits.h> 3330 #else 3331 # include <assert.h> 3332 #endif 3333 Syntax error 3334 _ACEOF 3335 if ac_fn_c_try_cpp "$LINENO"; then : 3336 3337 else 3338 # Broken: fails on valid input. 3339 continue 3340 fi 3341 rm -f conftest.err conftest.i conftest.$ac_ext 3342 3343 # OK, works on sane cases. Now check whether nonexistent headers 3344 # can be detected and how. 3345 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 3346 /* end confdefs.h. */ 3347 #include <ac_nonexistent.h> 3348 _ACEOF 3349 if ac_fn_c_try_cpp "$LINENO"; then : 3350 # Broken: success on invalid input. 3351 continue 3352 else 3353 # Passes both tests. 3354 ac_preproc_ok=: 3355 break 3356 fi 3357 rm -f conftest.err conftest.i conftest.$ac_ext 3358 3359 done 3360 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. 3361 rm -f conftest.i conftest.err conftest.$ac_ext 3362 if $ac_preproc_ok; then : 3363 break 3364 fi 3365 3366 done 3367 ac_cv_prog_CPP=$CPP 3368 3369 fi 3370 CPP=$ac_cv_prog_CPP 3371 else 3372 ac_cv_prog_CPP=$CPP 3373 fi 3374 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5 3375 $as_echo "$CPP" >&6; } 3376 ac_preproc_ok=false 3377 for ac_c_preproc_warn_flag in '' yes 3378 do 3379 # Use a header file that comes with gcc, so configuring glibc 3380 # with a fresh cross-compiler works. 3381 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since 3382 # <limits.h> exists even on freestanding compilers. 3383 # On the NeXT, cc -E runs the code through the compiler's parser, 3384 # not just through cpp. "Syntax error" is here to catch this case. 3385 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 3386 /* end confdefs.h. */ 3387 #ifdef __STDC__ 3388 # include <limits.h> 3389 #else 3390 # include <assert.h> 3391 #endif 3392 Syntax error 3393 _ACEOF 3394 if ac_fn_c_try_cpp "$LINENO"; then : 3395 3396 else 3397 # Broken: fails on valid input. 3398 continue 3399 fi 3400 rm -f conftest.err conftest.i conftest.$ac_ext 3401 3402 # OK, works on sane cases. Now check whether nonexistent headers 3403 # can be detected and how. 3404 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 3405 /* end confdefs.h. */ 3406 #include <ac_nonexistent.h> 3407 _ACEOF 3408 if ac_fn_c_try_cpp "$LINENO"; then : 3409 # Broken: success on invalid input. 3410 continue 3411 else 3412 # Passes both tests. 3413 ac_preproc_ok=: 3414 break 3415 fi 3416 rm -f conftest.err conftest.i conftest.$ac_ext 3417 3418 done 3419 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. 3420 rm -f conftest.i conftest.err conftest.$ac_ext 3421 if $ac_preproc_ok; then : 3422 3423 else 3424 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 3425 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 3426 as_fn_error $? "C preprocessor \"$CPP\" fails sanity check 3427 See \`config.log' for more details" "$LINENO" 5; } 3428 fi 3429 3430 ac_ext=c 3431 ac_cpp='$CPP $CPPFLAGS' 3432 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 3433 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 3434 ac_compiler_gnu=$ac_cv_c_compiler_gnu 3435 3436 3437 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5 3438 $as_echo_n "checking for grep that handles long lines and -e... " >&6; } 3439 if ${ac_cv_path_GREP+:} false; then : 3440 $as_echo_n "(cached) " >&6 3441 else 3442 if test -z "$GREP"; then 3443 ac_path_GREP_found=false 3444 # Loop through the user's path and test for each of PROGNAME-LIST 3445 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 3446 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin 3447 do 3448 IFS=$as_save_IFS 3449 test -z "$as_dir" && as_dir=. 3450 for ac_prog in grep ggrep; do 3451 for ac_exec_ext in '' $ac_executable_extensions; do 3452 ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext" 3453 { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue 3454 # Check for GNU ac_path_GREP and select it if it is found. 3455 # Check for GNU $ac_path_GREP 3456 case `"$ac_path_GREP" --version 2>&1` in 3457 *GNU*) 3458 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;; 3459 *) 3460 ac_count=0 3461 $as_echo_n 0123456789 >"conftest.in" 3462 while : 3463 do 3464 cat "conftest.in" "conftest.in" >"conftest.tmp" 3465 mv "conftest.tmp" "conftest.in" 3466 cp "conftest.in" "conftest.nl" 3467 $as_echo 'GREP' >> "conftest.nl" 3468 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break 3469 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 3470 as_fn_arith $ac_count + 1 && ac_count=$as_val 3471 if test $ac_count -gt ${ac_path_GREP_max-0}; then 3472 # Best one so far, save it but keep looking for a better one 3473 ac_cv_path_GREP="$ac_path_GREP" 3474 ac_path_GREP_max=$ac_count 3475 fi 3476 # 10*(2^10) chars as input seems more than enough 3477 test $ac_count -gt 10 && break 3478 done 3479 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 3480 esac 3481 3482 $ac_path_GREP_found && break 3 3483 done 3484 done 3485 done 3486 IFS=$as_save_IFS 3487 if test -z "$ac_cv_path_GREP"; then 3488 as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 3489 fi 3490 else 3491 ac_cv_path_GREP=$GREP 3492 fi 3493 3494 fi 3495 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5 3496 $as_echo "$ac_cv_path_GREP" >&6; } 3497 GREP="$ac_cv_path_GREP" 3498 3499 3500 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5 3501 $as_echo_n "checking for egrep... " >&6; } 3502 if ${ac_cv_path_EGREP+:} false; then : 3503 $as_echo_n "(cached) " >&6 3504 else 3505 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 3506 then ac_cv_path_EGREP="$GREP -E" 3507 else 3508 if test -z "$EGREP"; then 3509 ac_path_EGREP_found=false 3510 # Loop through the user's path and test for each of PROGNAME-LIST 3511 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 3512 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin 3513 do 3514 IFS=$as_save_IFS 3515 test -z "$as_dir" && as_dir=. 3516 for ac_prog in egrep; do 3517 for ac_exec_ext in '' $ac_executable_extensions; do 3518 ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext" 3519 { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue 3520 # Check for GNU ac_path_EGREP and select it if it is found. 3521 # Check for GNU $ac_path_EGREP 3522 case `"$ac_path_EGREP" --version 2>&1` in 3523 *GNU*) 3524 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;; 3525 *) 3526 ac_count=0 3527 $as_echo_n 0123456789 >"conftest.in" 3528 while : 3529 do 3530 cat "conftest.in" "conftest.in" >"conftest.tmp" 3531 mv "conftest.tmp" "conftest.in" 3532 cp "conftest.in" "conftest.nl" 3533 $as_echo 'EGREP' >> "conftest.nl" 3534 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break 3535 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 3536 as_fn_arith $ac_count + 1 && ac_count=$as_val 3537 if test $ac_count -gt ${ac_path_EGREP_max-0}; then 3538 # Best one so far, save it but keep looking for a better one 3539 ac_cv_path_EGREP="$ac_path_EGREP" 3540 ac_path_EGREP_max=$ac_count 3541 fi 3542 # 10*(2^10) chars as input seems more than enough 3543 test $ac_count -gt 10 && break 3544 done 3545 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 3546 esac 3547 3548 $ac_path_EGREP_found && break 3 3549 done 3550 done 3551 done 3552 IFS=$as_save_IFS 3553 if test -z "$ac_cv_path_EGREP"; then 3554 as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 3555 fi 3556 else 3557 ac_cv_path_EGREP=$EGREP 3558 fi 3559 3560 fi 3561 fi 3562 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5 3563 $as_echo "$ac_cv_path_EGREP" >&6; } 3564 EGREP="$ac_cv_path_EGREP" 3565 3566 3567 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 3568 $as_echo_n "checking for ANSI C header files... " >&6; } 3569 if ${ac_cv_header_stdc+:} false; then : 3570 $as_echo_n "(cached) " >&6 3571 else 3572 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 3573 /* end confdefs.h. */ 3574 #include <stdlib.h> 3575 #include <stdarg.h> 3576 #include <string.h> 3577 #include <float.h> 3578 3579 int 3580 main () 3581 { 3582 3583 ; 3584 return 0; 3585 } 3586 _ACEOF 3587 if ac_fn_c_try_compile "$LINENO"; then : 3588 ac_cv_header_stdc=yes 3589 else 3590 ac_cv_header_stdc=no 3591 fi 3592 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 3593 3594 if test $ac_cv_header_stdc = yes; then 3595 # SunOS 4.x string.h does not declare mem*, contrary to ANSI. 3596 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 3597 /* end confdefs.h. */ 3598 #include <string.h> 3599 3600 _ACEOF 3601 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | 3602 $EGREP "memchr" >/dev/null 2>&1; then : 3603 3604 else 3605 ac_cv_header_stdc=no 3606 fi 3607 rm -f conftest* 3608 3609 fi 3610 3611 if test $ac_cv_header_stdc = yes; then 3612 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. 3613 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 3614 /* end confdefs.h. */ 3615 #include <stdlib.h> 3616 3617 _ACEOF 3618 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | 3619 $EGREP "free" >/dev/null 2>&1; then : 3620 3621 else 3622 ac_cv_header_stdc=no 3623 fi 3624 rm -f conftest* 3625 3626 fi 3627 3628 if test $ac_cv_header_stdc = yes; then 3629 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. 3630 if test "$cross_compiling" = yes; then : 3631 : 3632 else 3633 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 3634 /* end confdefs.h. */ 3635 #include <ctype.h> 3636 #include <stdlib.h> 3637 #if ((' ' & 0x0FF) == 0x020) 3638 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z') 3639 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) 3640 #else 3641 # define ISLOWER(c) \ 3642 (('a' <= (c) && (c) <= 'i') \ 3643 || ('j' <= (c) && (c) <= 'r') \ 3644 || ('s' <= (c) && (c) <= 'z')) 3645 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) 3646 #endif 3647 3648 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) 3649 int 3650 main () 3651 { 3652 int i; 3653 for (i = 0; i < 256; i++) 3654 if (XOR (islower (i), ISLOWER (i)) 3655 || toupper (i) != TOUPPER (i)) 3656 return 2; 3657 return 0; 3658 } 3659 _ACEOF 3660 if ac_fn_c_try_run "$LINENO"; then : 3661 3662 else 3663 ac_cv_header_stdc=no 3664 fi 3665 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 3666 conftest.$ac_objext conftest.beam conftest.$ac_ext 3667 fi 3668 3669 fi 3670 fi 3671 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 3672 $as_echo "$ac_cv_header_stdc" >&6; } 3673 if test $ac_cv_header_stdc = yes; then 3674 3675 $as_echo "#define STDC_HEADERS 1" >>confdefs.h 3676 3677 fi 3678 3679 # On IRIX 5.3, sys/types and inttypes.h are conflicting. 3680 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \ 3681 inttypes.h stdint.h unistd.h 3682 do : 3683 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` 3684 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default 3685 " 3686 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : 3687 cat >>confdefs.h <<_ACEOF 3688 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 3689 _ACEOF 3690 3691 fi 3692 3693 done 3694 3695 3696 3697 3698 # Step 0.a: Enable 64 bit support? 3699 3700 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if 64bit support is requested" >&5 3701 $as_echo_n "checking if 64bit support is requested... " >&6; } 3702 # Check whether --enable-64bit was given. 3703 if test "${enable_64bit+set}" = set; then : 3704 enableval=$enable_64bit; do64bit=$enableval 3705 else 3706 do64bit=no 3707 fi 3708 3709 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $do64bit" >&5 3710 $as_echo "$do64bit" >&6; } 3711 3712 # Step 0.b: Enable Solaris 64 bit VIS support? 3713 3714 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if 64bit Sparc VIS support is requested" >&5 3715 $as_echo_n "checking if 64bit Sparc VIS support is requested... " >&6; } 3716 # Check whether --enable-64bit-vis was given. 3717 if test "${enable_64bit_vis+set}" = set; then : 3718 enableval=$enable_64bit_vis; do64bitVIS=$enableval 3719 else 3720 do64bitVIS=no 3721 fi 3722 3723 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $do64bitVIS" >&5 3724 $as_echo "$do64bitVIS" >&6; } 3725 3726 if test "$do64bitVIS" = "yes"; then 3727 # Force 64bit on with VIS 3728 do64bit=yes 3729 fi 3730 3731 # Step 1: set the variable "system" to hold the name and version number 3732 # for the system. 3733 3734 3735 { $as_echo "$as_me:${as_lineno-$LINENO}: checking system version" >&5 3736 $as_echo_n "checking system version... " >&6; } 3737 if ${tcl_cv_sys_version+:} false; then : 3738 $as_echo_n "(cached) " >&6 3739 else 3740 3741 if test -f /usr/lib/NextStep/software_version; then 3742 tcl_cv_sys_version=NEXTSTEP-`awk '/3/,/3/' /usr/lib/NextStep/software_version` 3743 else 3744 tcl_cv_sys_version=`uname -s`-`uname -r` 3745 if test "$?" -ne 0 ; then 3746 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: can't find uname command" >&5 3747 $as_echo "$as_me: WARNING: can't find uname command" >&2;} 3748 tcl_cv_sys_version=unknown 3749 else 3750 # Special check for weird MP-RAS system (uname returns weird 3751 # results, and the version is kept in special file). 3752 3753 if test -r /etc/.relid -a "X`uname -n`" = "X`uname -s`" ; then 3754 tcl_cv_sys_version=MP-RAS-`awk '{print $3}' /etc/.relid` 3755 fi 3756 if test "`uname -s`" = "AIX" ; then 3757 tcl_cv_sys_version=AIX-`uname -v`.`uname -r` 3758 fi 3759 fi 3760 fi 3761 3762 fi 3763 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tcl_cv_sys_version" >&5 3764 $as_echo "$tcl_cv_sys_version" >&6; } 3765 system=$tcl_cv_sys_version 3766 3767 3768 # Step 2: check for existence of -ldl library. This is needed because 3769 # Linux can use either -ldl or -ldld for dynamic loading. 3770 3771 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 3772 $as_echo_n "checking for dlopen in -ldl... " >&6; } 3773 if ${ac_cv_lib_dl_dlopen+:} false; then : 3774 $as_echo_n "(cached) " >&6 3775 else 3776 ac_check_lib_save_LIBS=$LIBS 3777 LIBS="-ldl $LIBS" 3778 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 3779 /* end confdefs.h. */ 3780 3781 /* Override any GCC internal prototype to avoid an error. 3782 Use char because int might match the return type of a GCC 3783 builtin and then its argument prototype would still apply. */ 3784 #ifdef __cplusplus 3785 extern "C" 3786 #endif 3787 char dlopen (); 3788 int 3789 main () 3790 { 3791 return dlopen (); 3792 ; 3793 return 0; 3794 } 3795 _ACEOF 3796 if ac_fn_c_try_link "$LINENO"; then : 3797 ac_cv_lib_dl_dlopen=yes 3798 else 3799 ac_cv_lib_dl_dlopen=no 3800 fi 3801 rm -f core conftest.err conftest.$ac_objext \ 3802 conftest$ac_exeext conftest.$ac_ext 3803 LIBS=$ac_check_lib_save_LIBS 3804 fi 3805 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 3806 $as_echo "$ac_cv_lib_dl_dlopen" >&6; } 3807 if test "x$ac_cv_lib_dl_dlopen" = xyes; then : 3808 have_dl=yes 3809 else 3810 have_dl=no 3811 fi 3812 3813 3814 # Require ranlib early so we can override it in special cases below. 3815 3816 3817 3818 # Step 3: set configuration options based on system name and version. 3819 3820 do64bit_ok=no 3821 LDFLAGS_ORIG="$LDFLAGS" 3822 TCL_EXPORT_FILE_SUFFIX="" 3823 UNSHARED_LIB_SUFFIX="" 3824 TCL_TRIM_DOTS='`echo ${VERSION} | tr -d .`' 3825 ECHO_VERSION='`echo ${VERSION}`' 3826 TCL_LIB_VERSIONS_OK=ok 3827 CFLAGS_DEBUG=-g 3828 CFLAGS_OPTIMIZE=-O 3829 if test "$GCC" = "yes" ; then 3830 CFLAGS_WARNING="-Wall -Wno-implicit-int -fno-strict-aliasing" 3831 else 3832 CFLAGS_WARNING="" 3833 fi 3834 TCL_NEEDS_EXP_FILE=0 3835 TCL_BUILD_EXP_FILE="" 3836 TCL_EXP_FILE="" 3837 # Extract the first word of "ar", so it can be a program name with args. 3838 set dummy ar; ac_word=$2 3839 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 3840 $as_echo_n "checking for $ac_word... " >&6; } 3841 if ${ac_cv_prog_AR+:} false; then : 3842 $as_echo_n "(cached) " >&6 3843 else 3844 if test -n "$AR"; then 3845 ac_cv_prog_AR="$AR" # Let the user override the test. 3846 else 3847 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 3848 for as_dir in $PATH 3849 do 3850 IFS=$as_save_IFS 3851 test -z "$as_dir" && as_dir=. 3852 for ac_exec_ext in '' $ac_executable_extensions; do 3853 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 3854 ac_cv_prog_AR="ar" 3855 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 3856 break 2 3857 fi 3858 done 3859 done 3860 IFS=$as_save_IFS 3861 3862 fi 3863 fi 3864 AR=$ac_cv_prog_AR 3865 if test -n "$AR"; then 3866 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 3867 $as_echo "$AR" >&6; } 3868 else 3869 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 3870 $as_echo "no" >&6; } 3871 fi 3872 3873 3874 if test "${AR}" = "" ; then 3875 as_fn_error $? "Required archive tool 'ar' not found on PATH." "$LINENO" 5 3876 fi 3877 STLIB_LD='${AR} cr' 3878 LD_LIBRARY_PATH_VAR="LD_LIBRARY_PATH" 3879 PLAT_OBJS="" 3880 PLAT_SRCS="" 3881 case $system in 3882 AIX-*) 3883 if test "${TCL_THREADS}" = "1" -a "$GCC" != "yes" ; then 3884 # AIX requires the _r compiler when gcc isn't being used 3885 case "${CC}" in 3886 *_r) 3887 # ok ... 3888 ;; 3889 *) 3890 CC=${CC}_r 3891 ;; 3892 esac 3893 { $as_echo "$as_me:${as_lineno-$LINENO}: result: Using $CC for compiling with threads" >&5 3894 $as_echo "Using $CC for compiling with threads" >&6; } 3895 fi 3896 LIBS="$LIBS -lc" 3897 SHLIB_CFLAGS="" 3898 # Note: need the LIBS below, otherwise Tk won't find Tcl's 3899 # symbols when dynamically loaded into tclsh. 3900 SHLIB_LD_LIBS='${LIBS}' 3901 SHLIB_SUFFIX=".so" 3902 3903 DL_OBJS="tclLoadDl.o" 3904 LD_LIBRARY_PATH_VAR="LIBPATH" 3905 3906 # Check to enable 64-bit flags for compiler/linker on AIX 4+ 3907 if test "$do64bit" = "yes" -a "`uname -v`" -gt "3" ; then 3908 if test "$GCC" = "yes" ; then 3909 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: 64bit mode not supported with GCC on $system" >&5 3910 $as_echo "$as_me: WARNING: 64bit mode not supported with GCC on $system" >&2;} 3911 else 3912 do64bit_ok=yes 3913 CFLAGS="$CFLAGS -q64" 3914 LDFLAGS="$LDFLAGS -q64" 3915 RANLIB="${RANLIB} -X64" 3916 AR="${AR} -X64" 3917 SHLIB_LD_FLAGS="-b64" 3918 fi 3919 fi 3920 3921 if test "`uname -m`" = "ia64" ; then 3922 # AIX-5 uses ELF style dynamic libraries on IA-64, but not PPC 3923 SHLIB_LD="/usr/ccs/bin/ld -G -z text" 3924 # AIX-5 has dl* in libc.so 3925 DL_LIBS="" 3926 if test "$GCC" = "yes" ; then 3927 CC_SEARCH_FLAGS='-Wl,-R,${LIB_RUNTIME_DIR}' 3928 else 3929 CC_SEARCH_FLAGS='-R${LIB_RUNTIME_DIR}' 3930 fi 3931 LD_SEARCH_FLAGS='-R ${LIB_RUNTIME_DIR}' 3932 else 3933 if test "$GCC" = "yes" ; then 3934 SHLIB_LD="gcc -shared" 3935 else 3936 SHLIB_LD="/bin/ld -bhalt:4 -bM:SRE -bE:lib.exp -H512 -T512 -bnoentry" 3937 fi 3938 SHLIB_LD="${TCL_SRC_DIR}/unix/ldAix ${SHLIB_LD} ${SHLIB_LD_FLAGS}" 3939 DL_LIBS="-ldl" 3940 CC_SEARCH_FLAGS='-L${LIB_RUNTIME_DIR}' 3941 LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS} 3942 TCL_NEEDS_EXP_FILE=1 3943 TCL_EXPORT_FILE_SUFFIX='${VERSION}\$\{DBGX\}.exp' 3944 fi 3945 3946 # AIX v<=4.1 has some different flags than 4.2+ 3947 if test "$system" = "AIX-4.1" -o "`uname -v`" -lt "4" ; then 3948 LIBOBJS="$LIBOBJS tclLoadAix.o" 3949 DL_LIBS="-lld" 3950 fi 3951 3952 # On AIX <=v4 systems, libbsd.a has to be linked in to support 3953 # non-blocking file IO. This library has to be linked in after 3954 # the MATH_LIBS or it breaks the pow() function. The way to 3955 # insure proper sequencing, is to add it to the tail of MATH_LIBS. 3956 # This library also supplies gettimeofday. 3957 # 3958 # AIX does not have a timezone field in struct tm. When the AIX 3959 # bsd library is used, the timezone global and the gettimeofday 3960 # methods are to be avoided for timezone deduction instead, we 3961 # deduce the timezone by comparing the localtime result on a 3962 # known GMT value. 3963 3964 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gettimeofday in -lbsd" >&5 3965 $as_echo_n "checking for gettimeofday in -lbsd... " >&6; } 3966 if ${ac_cv_lib_bsd_gettimeofday+:} false; then : 3967 $as_echo_n "(cached) " >&6 3968 else 3969 ac_check_lib_save_LIBS=$LIBS 3970 LIBS="-lbsd $LIBS" 3971 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 3972 /* end confdefs.h. */ 3973 3974 /* Override any GCC internal prototype to avoid an error. 3975 Use char because int might match the return type of a GCC 3976 builtin and then its argument prototype would still apply. */ 3977 #ifdef __cplusplus 3978 extern "C" 3979 #endif 3980 char gettimeofday (); 3981 int 3982 main () 3983 { 3984 return gettimeofday (); 3985 ; 3986 return 0; 3987 } 3988 _ACEOF 3989 if ac_fn_c_try_link "$LINENO"; then : 3990 ac_cv_lib_bsd_gettimeofday=yes 3991 else 3992 ac_cv_lib_bsd_gettimeofday=no 3993 fi 3994 rm -f core conftest.err conftest.$ac_objext \ 3995 conftest$ac_exeext conftest.$ac_ext 3996 LIBS=$ac_check_lib_save_LIBS 3997 fi 3998 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bsd_gettimeofday" >&5 3999 $as_echo "$ac_cv_lib_bsd_gettimeofday" >&6; } 4000 if test "x$ac_cv_lib_bsd_gettimeofday" = xyes; then : 4001 libbsd=yes 4002 else 4003 libbsd=no 4004 fi 4005 4006 if test $libbsd = yes; then 4007 MATH_LIBS="$MATH_LIBS -lbsd" 4008 $as_echo "#define USE_DELTA_FOR_TZ 1" >>confdefs.h 4009 4010 fi 4011 ;; 4012 BeOS*) 4013 SHLIB_CFLAGS="-fPIC" 4014 SHLIB_LD="${CC} -nostart" 4015 SHLIB_LD_LIBS='${LIBS}' 4016 SHLIB_SUFFIX=".so" 4017 DL_OBJS="tclLoadDl.o" 4018 DL_LIBS="-ldl" 4019 4020 #----------------------------------------------------------- 4021 # Check for inet_ntoa in -lbind, for BeOS (which also needs 4022 # -lsocket, even if the network functions are in -lnet which 4023 # is always linked to, for compatibility. 4024 #----------------------------------------------------------- 4025 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inet_ntoa in -lbind" >&5 4026 $as_echo_n "checking for inet_ntoa in -lbind... " >&6; } 4027 if ${ac_cv_lib_bind_inet_ntoa+:} false; then : 4028 $as_echo_n "(cached) " >&6 4029 else 4030 ac_check_lib_save_LIBS=$LIBS 4031 LIBS="-lbind $LIBS" 4032 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 4033 /* end confdefs.h. */ 4034 4035 /* Override any GCC internal prototype to avoid an error. 4036 Use char because int might match the return type of a GCC 4037 builtin and then its argument prototype would still apply. */ 4038 #ifdef __cplusplus 4039 extern "C" 4040 #endif 4041 char inet_ntoa (); 4042 int 4043 main () 4044 { 4045 return inet_ntoa (); 4046 ; 4047 return 0; 4048 } 4049 _ACEOF 4050 if ac_fn_c_try_link "$LINENO"; then : 4051 ac_cv_lib_bind_inet_ntoa=yes 4052 else 4053 ac_cv_lib_bind_inet_ntoa=no 4054 fi 4055 rm -f core conftest.err conftest.$ac_objext \ 4056 conftest$ac_exeext conftest.$ac_ext 4057 LIBS=$ac_check_lib_save_LIBS 4058 fi 4059 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bind_inet_ntoa" >&5 4060 $as_echo "$ac_cv_lib_bind_inet_ntoa" >&6; } 4061 if test "x$ac_cv_lib_bind_inet_ntoa" = xyes; then : 4062 LIBS="$LIBS -lbind -lsocket" 4063 fi 4064 4065 ;; 4066 BSD/OS-2.1*|BSD/OS-3*) 4067 SHLIB_CFLAGS="" 4068 SHLIB_LD="shlicc -r" 4069 SHLIB_LD_LIBS='${LIBS}' 4070 SHLIB_SUFFIX=".so" 4071 DL_OBJS="tclLoadDl.o" 4072 DL_LIBS="-ldl" 4073 CC_SEARCH_FLAGS="" 4074 LD_SEARCH_FLAGS="" 4075 ;; 4076 BSD/OS-4.*) 4077 SHLIB_CFLAGS="-export-dynamic -fPIC" 4078 SHLIB_LD="cc -shared" 4079 SHLIB_LD_LIBS='${LIBS}' 4080 SHLIB_SUFFIX=".so" 4081 DL_OBJS="tclLoadDl.o" 4082 DL_LIBS="-ldl" 4083 LDFLAGS="$LDFLAGS -export-dynamic" 4084 CC_SEARCH_FLAGS="" 4085 LD_SEARCH_FLAGS="" 4086 ;; 4087 dgux*) 4088 SHLIB_CFLAGS="-K PIC" 4089 SHLIB_LD="cc -G" 4090 SHLIB_LD_LIBS="" 4091 SHLIB_SUFFIX=".so" 4092 DL_OBJS="tclLoadDl.o" 4093 DL_LIBS="-ldl" 4094 CC_SEARCH_FLAGS="" 4095 LD_SEARCH_FLAGS="" 4096 ;; 4097 HP-UX-*.11.*) 4098 # Use updated header definitions where possible 4099 $as_echo "#define _XOPEN_SOURCE 1" >>confdefs.h 4100 # Use the XOPEN network library 4101 $as_echo "#define _XOPEN_SOURCE_EXTENDED 1" >>confdefs.h 4102 # Use the XOPEN network library 4103 LIBS="$LIBS -lxnet" # Use the XOPEN network library 4104 4105 if test "`uname -m`" = "ia64" ; then 4106 SHLIB_SUFFIX=".so" 4107 else 4108 SHLIB_SUFFIX=".sl" 4109 fi 4110 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shl_load in -ldld" >&5 4111 $as_echo_n "checking for shl_load in -ldld... " >&6; } 4112 if ${ac_cv_lib_dld_shl_load+:} false; then : 4113 $as_echo_n "(cached) " >&6 4114 else 4115 ac_check_lib_save_LIBS=$LIBS 4116 LIBS="-ldld $LIBS" 4117 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 4118 /* end confdefs.h. */ 4119 4120 /* Override any GCC internal prototype to avoid an error. 4121 Use char because int might match the return type of a GCC 4122 builtin and then its argument prototype would still apply. */ 4123 #ifdef __cplusplus 4124 extern "C" 4125 #endif 4126 char shl_load (); 4127 int 4128 main () 4129 { 4130 return shl_load (); 4131 ; 4132 return 0; 4133 } 4134 _ACEOF 4135 if ac_fn_c_try_link "$LINENO"; then : 4136 ac_cv_lib_dld_shl_load=yes 4137 else 4138 ac_cv_lib_dld_shl_load=no 4139 fi 4140 rm -f core conftest.err conftest.$ac_objext \ 4141 conftest$ac_exeext conftest.$ac_ext 4142 LIBS=$ac_check_lib_save_LIBS 4143 fi 4144 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_shl_load" >&5 4145 $as_echo "$ac_cv_lib_dld_shl_load" >&6; } 4146 if test "x$ac_cv_lib_dld_shl_load" = xyes; then : 4147 tcl_ok=yes 4148 else 4149 tcl_ok=no 4150 fi 4151 4152 if test "$tcl_ok" = yes; then 4153 SHLIB_CFLAGS="+z" 4154 SHLIB_LD="ld -b" 4155 SHLIB_LD_LIBS='${LIBS}' 4156 DL_OBJS="tclLoadShl.o" 4157 DL_LIBS="-ldld" 4158 LDFLAGS="$LDFLAGS -Wl,-E" 4159 CC_SEARCH_FLAGS='-Wl,+s,+b,${LIB_RUNTIME_DIR}:.' 4160 LD_SEARCH_FLAGS='+s +b ${LIB_RUNTIME_DIR}:.' 4161 LD_LIBRARY_PATH_VAR="SHLIB_PATH" 4162 fi 4163 if test "$GCC" = "yes" ; then 4164 SHLIB_LD="gcc -shared" 4165 SHLIB_LD_LIBS='${LIBS}' 4166 LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS} 4167 fi 4168 4169 # Users may want PA-RISC 1.1/2.0 portable code - needs HP cc 4170 #CFLAGS="$CFLAGS +DAportable" 4171 4172 # Check to enable 64-bit flags for compiler/linker 4173 if test "$do64bit" = "yes" ; then 4174 if test "$GCC" = "yes" ; then 4175 hpux_arch=`${CC} -dumpmachine` 4176 case $hpux_arch in 4177 hppa64*) 4178 # 64-bit gcc in use. Fix flags for GNU ld. 4179 do64bit_ok=yes 4180 SHLIB_LD="${CC} -shared" 4181 SHLIB_LD_LIBS='${LIBS}' 4182 CC_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}' 4183 LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS} 4184 ;; 4185 *) 4186 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: 64bit mode not supported with GCC on $system" >&5 4187 $as_echo "$as_me: WARNING: 64bit mode not supported with GCC on $system" >&2;} 4188 ;; 4189 esac 4190 else 4191 do64bit_ok=yes 4192 CFLAGS="$CFLAGS +DD64" 4193 LDFLAGS="$LDFLAGS +DD64" 4194 fi 4195 fi 4196 ;; 4197 HP-UX-*.08.*|HP-UX-*.09.*|HP-UX-*.10.*) 4198 SHLIB_SUFFIX=".sl" 4199 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shl_load in -ldld" >&5 4200 $as_echo_n "checking for shl_load in -ldld... " >&6; } 4201 if ${ac_cv_lib_dld_shl_load+:} false; then : 4202 $as_echo_n "(cached) " >&6 4203 else 4204 ac_check_lib_save_LIBS=$LIBS 4205 LIBS="-ldld $LIBS" 4206 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 4207 /* end confdefs.h. */ 4208 4209 /* Override any GCC internal prototype to avoid an error. 4210 Use char because int might match the return type of a GCC 4211 builtin and then its argument prototype would still apply. */ 4212 #ifdef __cplusplus 4213 extern "C" 4214 #endif 4215 char shl_load (); 4216 int 4217 main () 4218 { 4219 return shl_load (); 4220 ; 4221 return 0; 4222 } 4223 _ACEOF 4224 if ac_fn_c_try_link "$LINENO"; then : 4225 ac_cv_lib_dld_shl_load=yes 4226 else 4227 ac_cv_lib_dld_shl_load=no 4228 fi 4229 rm -f core conftest.err conftest.$ac_objext \ 4230 conftest$ac_exeext conftest.$ac_ext 4231 LIBS=$ac_check_lib_save_LIBS 4232 fi 4233 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_shl_load" >&5 4234 $as_echo "$ac_cv_lib_dld_shl_load" >&6; } 4235 if test "x$ac_cv_lib_dld_shl_load" = xyes; then : 4236 tcl_ok=yes 4237 else 4238 tcl_ok=no 4239 fi 4240 4241 if test "$tcl_ok" = yes; then 4242 SHLIB_CFLAGS="+z" 4243 SHLIB_LD="ld -b" 4244 SHLIB_LD_LIBS="" 4245 DL_OBJS="tclLoadShl.o" 4246 DL_LIBS="-ldld" 4247 LDFLAGS="$LDFLAGS -Wl,-E" 4248 CC_SEARCH_FLAGS='-Wl,+s,+b,${LIB_RUNTIME_DIR}:.' 4249 LD_SEARCH_FLAGS='+s +b ${LIB_RUNTIME_DIR}:.' 4250 LD_LIBRARY_PATH_VAR="SHLIB_PATH" 4251 fi 4252 ;; 4253 IRIX-4.*) 4254 SHLIB_CFLAGS="-G 0" 4255 SHLIB_SUFFIX=".a" 4256 SHLIB_LD="echo tclLdAout $CC \{$SHLIB_CFLAGS\} | `pwd`/tclsh -r -G 0" 4257 SHLIB_LD_LIBS='${LIBS}' 4258 DL_OBJS="tclLoadAout.o" 4259 DL_LIBS="" 4260 LDFLAGS="$LDFLAGS -Wl,-D,08000000" 4261 CC_SEARCH_FLAGS='-L${LIB_RUNTIME_DIR}' 4262 LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS} 4263 SHARED_LIB_SUFFIX='${VERSION}\$\{DBGX\}.a' 4264 ;; 4265 IRIX-5.*) 4266 SHLIB_CFLAGS="" 4267 SHLIB_LD="ld -shared -rdata_shared" 4268 SHLIB_LD_LIBS='${LIBS}' 4269 SHLIB_SUFFIX=".so" 4270 DL_OBJS="tclLoadDl.o" 4271 DL_LIBS="" 4272 CC_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}' 4273 LD_SEARCH_FLAGS='-rpath ${LIB_RUNTIME_DIR}' 4274 ;; 4275 IRIX-6.*) 4276 SHLIB_CFLAGS="" 4277 SHLIB_LD="ld -n32 -shared -rdata_shared" 4278 SHLIB_LD_LIBS='${LIBS}' 4279 SHLIB_SUFFIX=".so" 4280 DL_OBJS="tclLoadDl.o" 4281 DL_LIBS="" 4282 CC_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}' 4283 LD_SEARCH_FLAGS='-rpath ${LIB_RUNTIME_DIR}' 4284 if test "$GCC" = "yes" ; then 4285 CFLAGS="$CFLAGS -mabi=n32" 4286 LDFLAGS="$LDFLAGS -mabi=n32" 4287 else 4288 case $system in 4289 IRIX-6.3) 4290 # Use to build 6.2 compatible binaries on 6.3. 4291 CFLAGS="$CFLAGS -n32 -D_OLD_TERMIOS" 4292 ;; 4293 *) 4294 CFLAGS="$CFLAGS -n32" 4295 ;; 4296 esac 4297 LDFLAGS="$LDFLAGS -n32" 4298 fi 4299 ;; 4300 IRIX64-6.*) 4301 SHLIB_CFLAGS="" 4302 SHLIB_LD="ld -n32 -shared -rdata_shared" 4303 SHLIB_LD_LIBS='${LIBS}' 4304 SHLIB_SUFFIX=".so" 4305 DL_OBJS="tclLoadDl.o" 4306 DL_LIBS="" 4307 CC_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}' 4308 LD_SEARCH_FLAGS='-rpath ${LIB_RUNTIME_DIR}' 4309 4310 # Check to enable 64-bit flags for compiler/linker 4311 4312 if test "$do64bit" = "yes" ; then 4313 if test "$GCC" = "yes" ; then 4314 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: 64bit mode not supported by gcc" >&5 4315 $as_echo "$as_me: WARNING: 64bit mode not supported by gcc" >&2;} 4316 else 4317 do64bit_ok=yes 4318 SHLIB_LD="ld -64 -shared -rdata_shared" 4319 CFLAGS="$CFLAGS -64" 4320 LDFLAGS="$LDFLAGS -64" 4321 fi 4322 fi 4323 ;; 4324 Linux*) 4325 SHLIB_CFLAGS="-fPIC" 4326 SHLIB_LD_LIBS='${LIBS}' 4327 SHLIB_SUFFIX=".so" 4328 4329 CFLAGS_OPTIMIZE=-O2 4330 # egcs-2.91.66 on Redhat Linux 6.0 generates lots of warnings 4331 # when you inline the string and math operations. Turn this off to 4332 # get rid of the warnings. 4333 #CFLAGS_OPTIMIZE="${CFLAGS_OPTIMIZE} -D__NO_STRING_INLINES -D__NO_MATH_INLINES" 4334 4335 if test "$have_dl" = yes; then 4336 SHLIB_LD='${CC} -shared ${CFLAGS} ${LDFLAGS}' 4337 DL_OBJS="tclLoadDl.o" 4338 DL_LIBS="-ldl" 4339 LDFLAGS="$LDFLAGS -Wl,--export-dynamic" 4340 CC_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}' 4341 LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS} 4342 else 4343 ac_fn_c_check_header_mongrel "$LINENO" "dld.h" "ac_cv_header_dld_h" "$ac_includes_default" 4344 if test "x$ac_cv_header_dld_h" = xyes; then : 4345 4346 SHLIB_LD="ld -shared" 4347 DL_OBJS="tclLoadDld.o" 4348 DL_LIBS="-ldld" 4349 CC_SEARCH_FLAGS="" 4350 LD_SEARCH_FLAGS="" 4351 fi 4352 4353 4354 fi 4355 if test "`uname -m`" = "alpha" ; then 4356 CFLAGS="$CFLAGS -mieee" 4357 fi 4358 if test $do64bit = yes; then 4359 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler accepts -m64 flag" >&5 4360 $as_echo_n "checking if compiler accepts -m64 flag... " >&6; } 4361 if ${tcl_cv_cc_m64+:} false; then : 4362 $as_echo_n "(cached) " >&6 4363 else 4364 4365 hold_cflags=$CFLAGS 4366 CFLAGS="$CFLAGS -m64" 4367 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 4368 /* end confdefs.h. */ 4369 4370 int 4371 main () 4372 { 4373 4374 ; 4375 return 0; 4376 } 4377 _ACEOF 4378 if ac_fn_c_try_link "$LINENO"; then : 4379 tcl_cv_cc_m64=yes 4380 else 4381 tcl_cv_cc_m64=no 4382 fi 4383 rm -f core conftest.err conftest.$ac_objext \ 4384 conftest$ac_exeext conftest.$ac_ext 4385 CFLAGS=$hold_cflags 4386 fi 4387 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tcl_cv_cc_m64" >&5 4388 $as_echo "$tcl_cv_cc_m64" >&6; } 4389 if test $tcl_cv_cc_m64 = yes; then 4390 CFLAGS="$CFLAGS -m64" 4391 do64bit_ok=yes 4392 fi 4393 fi 4394 4395 # The combo of gcc + glibc has a bug related 4396 # to inlining of functions like strtod(). The 4397 # -fno-builtin flag should address this problem 4398 # but it does not work. The -fno-inline flag 4399 # is kind of overkill but it works. 4400 # Disable inlining only when one of the 4401 # files in compat/*.c is being linked in. 4402 if test x"${LIBOBJS}" != x ; then 4403 CFLAGS="$CFLAGS -fno-inline" 4404 fi 4405 4406 # XIM peeking works under XFree86. 4407 $as_echo "#define PEEK_XCLOSEIM 1" >>confdefs.h 4408 4409 4410 ;; 4411 GNU*) 4412 SHLIB_CFLAGS="-fPIC" 4413 SHLIB_LD_LIBS='${LIBS}' 4414 SHLIB_SUFFIX=".so" 4415 4416 if test "$have_dl" = yes; then 4417 SHLIB_LD="${CC} -shared" 4418 DL_OBJS="" 4419 DL_LIBS="-ldl" 4420 LDFLAGS="$LDFLAGS -Wl,--export-dynamic" 4421 CC_SEARCH_FLAGS="" 4422 LD_SEARCH_FLAGS="" 4423 else 4424 ac_fn_c_check_header_mongrel "$LINENO" "dld.h" "ac_cv_header_dld_h" "$ac_includes_default" 4425 if test "x$ac_cv_header_dld_h" = xyes; then : 4426 4427 SHLIB_LD="ld -shared" 4428 DL_OBJS="" 4429 DL_LIBS="-ldld" 4430 CC_SEARCH_FLAGS="" 4431 LD_SEARCH_FLAGS="" 4432 fi 4433 4434 4435 fi 4436 if test "`uname -m`" = "alpha" ; then 4437 CFLAGS="$CFLAGS -mieee" 4438 fi 4439 ;; 4440 Lynx*) 4441 SHLIB_CFLAGS="-fPIC" 4442 SHLIB_LD_LIBS='${LIBS}' 4443 SHLIB_SUFFIX=".so" 4444 CFLAGS_OPTIMIZE=-02 4445 SHLIB_LD="${CC} -shared " 4446 DL_OBJS="tclLoadDl.o" 4447 DL_LIBS="-mshared -ldl" 4448 LD_FLAGS="-Wl,--export-dynamic" 4449 CC_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}' 4450 LD_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}' 4451 ;; 4452 MP-RAS-02*) 4453 SHLIB_CFLAGS="-K PIC" 4454 SHLIB_LD="cc -G" 4455 SHLIB_LD_LIBS="" 4456 SHLIB_SUFFIX=".so" 4457 DL_OBJS="tclLoadDl.o" 4458 DL_LIBS="-ldl" 4459 CC_SEARCH_FLAGS="" 4460 LD_SEARCH_FLAGS="" 4461 ;; 4462 MP-RAS-*) 4463 SHLIB_CFLAGS="-K PIC" 4464 SHLIB_LD="cc -G" 4465 SHLIB_LD_LIBS="" 4466 SHLIB_SUFFIX=".so" 4467 DL_OBJS="tclLoadDl.o" 4468 DL_LIBS="-ldl" 4469 LDFLAGS="$LDFLAGS -Wl,-Bexport" 4470 CC_SEARCH_FLAGS="" 4471 LD_SEARCH_FLAGS="" 4472 ;; 4473 NetBSD-*|FreeBSD-[1-2].*) 4474 # Not available on all versions: check for include file. 4475 ac_fn_c_check_header_mongrel "$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" "$ac_includes_default" 4476 if test "x$ac_cv_header_dlfcn_h" = xyes; then : 4477 4478 # NetBSD/SPARC needs -fPIC, -fpic will not do. 4479 SHLIB_CFLAGS="-fPIC" 4480 SHLIB_LD="ld -Bshareable -x" 4481 SHLIB_LD_LIBS='${LIBS}' 4482 SHLIB_SUFFIX=".so" 4483 DL_OBJS="tclLoadDl.o" 4484 DL_LIBS="" 4485 CC_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}' 4486 LD_SEARCH_FLAGS='-rpath ${LIB_RUNTIME_DIR}' 4487 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ELF" >&5 4488 $as_echo_n "checking for ELF... " >&6; } 4489 if ${tcl_cv_ld_elf+:} false; then : 4490 $as_echo_n "(cached) " >&6 4491 else 4492 4493 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 4494 /* end confdefs.h. */ 4495 4496 #ifdef __ELF__ 4497 yes 4498 #endif 4499 4500 _ACEOF 4501 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | 4502 $EGREP "yes" >/dev/null 2>&1; then : 4503 tcl_cv_ld_elf=yes 4504 else 4505 tcl_cv_ld_elf=no 4506 fi 4507 rm -f conftest* 4508 4509 fi 4510 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tcl_cv_ld_elf" >&5 4511 $as_echo "$tcl_cv_ld_elf" >&6; } 4512 if test $tcl_cv_ld_elf = yes; then 4513 SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.so' 4514 else 4515 SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.so.1.0' 4516 fi 4517 4518 else 4519 4520 SHLIB_CFLAGS="" 4521 SHLIB_LD="echo tclLdAout $CC \{$SHLIB_CFLAGS\} | `pwd`/tclsh -r" 4522 SHLIB_LD_LIBS='${LIBS}' 4523 SHLIB_SUFFIX=".a" 4524 DL_OBJS="tclLoadAout.o" 4525 DL_LIBS="" 4526 CC_SEARCH_FLAGS='-L${LIB_RUNTIME_DIR}' 4527 LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS} 4528 SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.a' 4529 4530 fi 4531 4532 4533 4534 # FreeBSD doesn't handle version numbers with dots. 4535 4536 UNSHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.a' 4537 TCL_LIB_VERSIONS_OK=nodots 4538 ;; 4539 OpenBSD-*) 4540 case `arch -s` in 4541 m88k|vax) 4542 SHLIB_CFLAGS="" 4543 SHLIB_LD="echo tclLdAout $CC \{$SHLIB_CFLAGS\} | `pwd`/tclsh -r" 4544 SHLIB_LD_LIBS='${LIBS}' 4545 SHLIB_SUFFIX=".a" 4546 DL_OBJS="tclLoadAout.o" 4547 DL_LIBS="" 4548 LDFLAGS="" 4549 CC_SEARCH_FLAGS='-L${LIB_RUNTIME_DIR}' 4550 LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS} 4551 SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.a' 4552 ;; 4553 *) 4554 # OpenBSD/SPARC[64] needs -fPIC, -fpic will not do. 4555 case `machine` in 4556 sparc|sparc64) 4557 SHLIB_CFLAGS="-fPIC";; 4558 *) 4559 SHLIB_CFLAGS="-fpic";; 4560 esac 4561 SHLIB_LD="${CC} -shared ${SHLIB_CFLAGS}" 4562 SHLIB_LD_LIBS='${LIBS}' 4563 SHLIB_SUFFIX=".so" 4564 DL_OBJS="tclLoadDl.o" 4565 DL_LIBS="" 4566 CC_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}' 4567 LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS} 4568 SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.so.1.0' 4569 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ELF" >&5 4570 $as_echo_n "checking for ELF... " >&6; } 4571 if ${tcl_cv_ld_elf+:} false; then : 4572 $as_echo_n "(cached) " >&6 4573 else 4574 4575 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 4576 /* end confdefs.h. */ 4577 4578 #ifdef __ELF__ 4579 yes 4580 #endif 4581 4582 _ACEOF 4583 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | 4584 $EGREP "yes" >/dev/null 2>&1; then : 4585 tcl_cv_ld_elf=yes 4586 else 4587 tcl_cv_ld_elf=no 4588 fi 4589 rm -f conftest* 4590 4591 fi 4592 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tcl_cv_ld_elf" >&5 4593 $as_echo "$tcl_cv_ld_elf" >&6; } 4594 if test $tcl_cv_ld_elf = yes; then 4595 LDFLAGS=-Wl,-export-dynamic 4596 else 4597 LDFLAGS="" 4598 fi 4599 ;; 4600 esac 4601 4602 # OpenBSD doesn't do version numbers with dots. 4603 UNSHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.a' 4604 TCL_LIB_VERSIONS_OK=nodots 4605 ;; 4606 FreeBSD-*) 4607 # FreeBSD 3.* and greater have ELF. 4608 SHLIB_CFLAGS="-fPIC" 4609 SHLIB_LD="ld -Bshareable -x" 4610 SHLIB_LD_LIBS='${LIBS}' 4611 SHLIB_SUFFIX=".so" 4612 DL_OBJS="tclLoadDl.o" 4613 DL_LIBS="" 4614 LDFLAGS="$LDFLAGS -export-dynamic" 4615 CC_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}' 4616 LD_SEARCH_FLAGS='-rpath ${LIB_RUNTIME_DIR}' 4617 if test "${TCL_THREADS}" = "1" ; then 4618 # The -pthread needs to go in the CFLAGS, not LIBS 4619 LIBS=`echo $LIBS | sed s/-pthread//` 4620 CFLAGS="$CFLAGS -pthread" 4621 LDFLAGS="$LDFLAGS -pthread" 4622 fi 4623 case $system in 4624 FreeBSD-3.*) 4625 # FreeBSD-3 doesn't handle version numbers with dots. 4626 UNSHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.a' 4627 SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.so' 4628 TCL_LIB_VERSIONS_OK=nodots 4629 ;; 4630 esac 4631 ;; 4632 Darwin-*) 4633 CFLAGS_OPTIMIZE="-Os" 4634 SHLIB_CFLAGS="-fno-common" 4635 # To avoid discrepancies between what headers configure sees during 4636 # preprocessing tests and compiling tests, move any -isysroot and 4637 # -mmacosx-version-min flags from CFLAGS to CPPFLAGS: 4638 CPPFLAGS="${CPPFLAGS} `echo " ${CFLAGS}" | \ 4639 awk 'BEGIN {FS=" +-";ORS=" "}; {for (i=2;i<=NF;i++) \ 4640 if ($i~/^(isysroot|mmacosx-version-min)/) print "-"$i}'`" 4641 CFLAGS="`echo " ${CFLAGS}" | \ 4642 awk 'BEGIN {FS=" +-";ORS=" "}; {for (i=2;i<=NF;i++) \ 4643 if (!($i~/^(isysroot|mmacosx-version-min)/)) print "-"$i}'`" 4644 if test $do64bit = yes; then 4645 case `arch` in 4646 ppc) 4647 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler accepts -arch ppc64 flag" >&5 4648 $as_echo_n "checking if compiler accepts -arch ppc64 flag... " >&6; } 4649 if ${tcl_cv_cc_arch_ppc64+:} false; then : 4650 $as_echo_n "(cached) " >&6 4651 else 4652 4653 hold_cflags=$CFLAGS 4654 CFLAGS="$CFLAGS -arch ppc64 -mpowerpc64 -mcpu=G5" 4655 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 4656 /* end confdefs.h. */ 4657 4658 int 4659 main () 4660 { 4661 4662 ; 4663 return 0; 4664 } 4665 _ACEOF 4666 if ac_fn_c_try_link "$LINENO"; then : 4667 tcl_cv_cc_arch_ppc64=yes 4668 else 4669 tcl_cv_cc_arch_ppc64=no 4670 fi 4671 rm -f core conftest.err conftest.$ac_objext \ 4672 conftest$ac_exeext conftest.$ac_ext 4673 CFLAGS=$hold_cflags 4674 fi 4675 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tcl_cv_cc_arch_ppc64" >&5 4676 $as_echo "$tcl_cv_cc_arch_ppc64" >&6; } 4677 if test $tcl_cv_cc_arch_ppc64 = yes; then 4678 CFLAGS="$CFLAGS -arch ppc64 -mpowerpc64 -mcpu=G5" 4679 do64bit_ok=yes 4680 fi;; 4681 i386) 4682 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler accepts -arch x86_64 flag" >&5 4683 $as_echo_n "checking if compiler accepts -arch x86_64 flag... " >&6; } 4684 if ${tcl_cv_cc_arch_x86_64+:} false; then : 4685 $as_echo_n "(cached) " >&6 4686 else 4687 4688 hold_cflags=$CFLAGS 4689 CFLAGS="$CFLAGS -arch x86_64" 4690 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 4691 /* end confdefs.h. */ 4692 4693 int 4694 main () 4695 { 4696 4697 ; 4698 return 0; 4699 } 4700 _ACEOF 4701 if ac_fn_c_try_link "$LINENO"; then : 4702 tcl_cv_cc_arch_x86_64=yes 4703 else 4704 tcl_cv_cc_arch_x86_64=no 4705 fi 4706 rm -f core conftest.err conftest.$ac_objext \ 4707 conftest$ac_exeext conftest.$ac_ext 4708 CFLAGS=$hold_cflags 4709 fi 4710 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tcl_cv_cc_arch_x86_64" >&5 4711 $as_echo "$tcl_cv_cc_arch_x86_64" >&6; } 4712 if test $tcl_cv_cc_arch_x86_64 = yes; then 4713 CFLAGS="$CFLAGS -arch x86_64" 4714 do64bit_ok=yes 4715 fi;; 4716 *) 4717 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Don't know how enable 64-bit on architecture \`arch\`" >&5 4718 $as_echo "$as_me: WARNING: Don't know how enable 64-bit on architecture \`arch\`" >&2;};; 4719 esac 4720 else 4721 # Check for combined 32-bit and 64-bit fat build 4722 echo "$CFLAGS " | grep -E -q -- '-arch (ppc64|x86_64) ' && \ 4723 echo "$CFLAGS " | grep -E -q -- '-arch (ppc|i386) ' && \ 4724 fat_32_64=yes 4725 fi 4726 SHLIB_LD='${CC} -dynamiclib ${CFLAGS} ${LDFLAGS}' 4727 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if ld accepts -single_module flag" >&5 4728 $as_echo_n "checking if ld accepts -single_module flag... " >&6; } 4729 if ${tcl_cv_ld_single_module+:} false; then : 4730 $as_echo_n "(cached) " >&6 4731 else 4732 4733 hold_ldflags=$LDFLAGS 4734 LDFLAGS="$LDFLAGS -dynamiclib -Wl,-single_module" 4735 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 4736 /* end confdefs.h. */ 4737 4738 int 4739 main () 4740 { 4741 int i; 4742 ; 4743 return 0; 4744 } 4745 _ACEOF 4746 if ac_fn_c_try_link "$LINENO"; then : 4747 tcl_cv_ld_single_module=yes 4748 else 4749 tcl_cv_ld_single_module=no 4750 fi 4751 rm -f core conftest.err conftest.$ac_objext \ 4752 conftest$ac_exeext conftest.$ac_ext 4753 LDFLAGS=$hold_ldflags 4754 fi 4755 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tcl_cv_ld_single_module" >&5 4756 $as_echo "$tcl_cv_ld_single_module" >&6; } 4757 if test $tcl_cv_ld_single_module = yes; then 4758 SHLIB_LD="${SHLIB_LD} -Wl,-single_module" 4759 fi 4760 SHLIB_LD_LIBS='${LIBS}' 4761 SHLIB_SUFFIX=".dylib" 4762 DL_OBJS="tclLoadDyld.o" 4763 DL_LIBS="" 4764 # Don't use -prebind when building for Mac OS X 10.4 or later only: 4765 test "`echo "${MACOSX_DEPLOYMENT_TARGET}" | awk -F '10\\.' '{print int($2)}'`" -lt 4 -a \ 4766 "`echo "${CPPFLAGS}" | awk -F '-mmacosx-version-min=10\\.' '{print int($2)}'`" -lt 4 && \ 4767 LDFLAGS="$LDFLAGS -prebind" 4768 LDFLAGS="$LDFLAGS -headerpad_max_install_names" 4769 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if ld accepts -search_paths_first flag" >&5 4770 $as_echo_n "checking if ld accepts -search_paths_first flag... " >&6; } 4771 if ${tcl_cv_ld_search_paths_first+:} false; then : 4772 $as_echo_n "(cached) " >&6 4773 else 4774 4775 hold_ldflags=$LDFLAGS 4776 LDFLAGS="$LDFLAGS -Wl,-search_paths_first" 4777 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 4778 /* end confdefs.h. */ 4779 4780 int 4781 main () 4782 { 4783 int i; 4784 ; 4785 return 0; 4786 } 4787 _ACEOF 4788 if ac_fn_c_try_link "$LINENO"; then : 4789 tcl_cv_ld_search_paths_first=yes 4790 else 4791 tcl_cv_ld_search_paths_first=no 4792 fi 4793 rm -f core conftest.err conftest.$ac_objext \ 4794 conftest$ac_exeext conftest.$ac_ext 4795 LDFLAGS=$hold_ldflags 4796 fi 4797 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tcl_cv_ld_search_paths_first" >&5 4798 $as_echo "$tcl_cv_ld_search_paths_first" >&6; } 4799 if test $tcl_cv_ld_search_paths_first = yes; then 4800 LDFLAGS="$LDFLAGS -Wl,-search_paths_first" 4801 fi 4802 CC_SEARCH_FLAGS="" 4803 LD_SEARCH_FLAGS="" 4804 LD_LIBRARY_PATH_VAR="DYLD_LIBRARY_PATH" 4805 PLAT_OBJS=\$\(MAC\_OSX_OBJS\) 4806 PLAT_SRCS=\$\(MAC\_OSX_SRCS\) 4807 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use CoreFoundation" >&5 4808 $as_echo_n "checking whether to use CoreFoundation... " >&6; } 4809 # Check whether --enable-corefoundation was given. 4810 if test "${enable_corefoundation+set}" = set; then : 4811 enableval=$enable_corefoundation; tcl_corefoundation=$enableval 4812 else 4813 tcl_corefoundation=yes 4814 fi 4815 4816 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tcl_corefoundation" >&5 4817 $as_echo "$tcl_corefoundation" >&6; } 4818 if test $tcl_corefoundation = yes; then 4819 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CoreFoundation.framework" >&5 4820 $as_echo_n "checking for CoreFoundation.framework... " >&6; } 4821 if ${tcl_cv_lib_corefoundation+:} false; then : 4822 $as_echo_n "(cached) " >&6 4823 else 4824 4825 hold_libs=$LIBS 4826 if test "$fat_32_64" = yes; then for v in CFLAGS CPPFLAGS LDFLAGS; do 4827 # On Tiger there is no 64-bit CF, so remove 64-bit archs 4828 # from CFLAGS et al. while testing for presence of CF. 4829 # 64-bit CF is disabled in tclUnixPort.h if necessary. 4830 eval 'hold_'$v'="$'$v'";'$v'="`echo "$'$v' "|sed -e "s/-arch ppc64 / /g" -e "s/-arch x86_64 / /g"`"' 4831 done; fi 4832 LIBS="$LIBS -framework CoreFoundation" 4833 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 4834 /* end confdefs.h. */ 4835 #include <CoreFoundation/CoreFoundation.h> 4836 int 4837 main () 4838 { 4839 CFBundleRef b = CFBundleGetMainBundle(); 4840 ; 4841 return 0; 4842 } 4843 _ACEOF 4844 if ac_fn_c_try_link "$LINENO"; then : 4845 tcl_cv_lib_corefoundation=yes 4846 else 4847 tcl_cv_lib_corefoundation=no 4848 fi 4849 rm -f core conftest.err conftest.$ac_objext \ 4850 conftest$ac_exeext conftest.$ac_ext 4851 if test "$fat_32_64" = yes; then for v in CFLAGS CPPFLAGS LDFLAGS; do 4852 eval $v'="$hold_'$v'"' 4853 done; fi; LIBS=$hold_libs 4854 fi 4855 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tcl_cv_lib_corefoundation" >&5 4856 $as_echo "$tcl_cv_lib_corefoundation" >&6; } 4857 if test $tcl_cv_lib_corefoundation = yes; then 4858 LIBS="$LIBS -framework CoreFoundation" 4859 $as_echo "#define HAVE_COREFOUNDATION 1" >>confdefs.h 4860 4861 else 4862 tcl_corefoundation=no 4863 fi 4864 if test "$fat_32_64" = yes -a $tcl_corefoundation = yes; then 4865 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for 64-bit CoreFoundation" >&5 4866 $as_echo_n "checking for 64-bit CoreFoundation... " >&6; } 4867 if ${tcl_cv_lib_corefoundation_64+:} false; then : 4868 $as_echo_n "(cached) " >&6 4869 else 4870 4871 for v in CFLAGS CPPFLAGS LDFLAGS; do 4872 eval 'hold_'$v'="$'$v'";'$v'="`echo "$'$v' "|sed -e "s/-arch ppc / /g" -e "s/-arch i386 / /g"`"' 4873 done 4874 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 4875 /* end confdefs.h. */ 4876 #include <CoreFoundation/CoreFoundation.h> 4877 int 4878 main () 4879 { 4880 CFBundleRef b = CFBundleGetMainBundle(); 4881 ; 4882 return 0; 4883 } 4884 _ACEOF 4885 if ac_fn_c_try_link "$LINENO"; then : 4886 tcl_cv_lib_corefoundation_64=yes 4887 else 4888 tcl_cv_lib_corefoundation_64=no 4889 fi 4890 rm -f core conftest.err conftest.$ac_objext \ 4891 conftest$ac_exeext conftest.$ac_ext 4892 for v in CFLAGS CPPFLAGS LDFLAGS; do 4893 eval $v'="$hold_'$v'"' 4894 done 4895 fi 4896 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tcl_cv_lib_corefoundation_64" >&5 4897 $as_echo "$tcl_cv_lib_corefoundation_64" >&6; } 4898 if test $tcl_cv_lib_corefoundation_64 = no; then 4899 $as_echo "#define NO_COREFOUNDATION_64 1" >>confdefs.h 4900 4901 fi 4902 fi 4903 fi 4904 $as_echo "#define MAC_OSX_TCL 1" >>confdefs.h 4905 4906 ;; 4907 NEXTSTEP-*) 4908 SHLIB_CFLAGS="" 4909 SHLIB_LD="cc -nostdlib -r" 4910 SHLIB_LD_LIBS="" 4911 SHLIB_SUFFIX=".so" 4912 DL_OBJS="tclLoadNext.o" 4913 DL_LIBS="" 4914 CC_SEARCH_FLAGS="" 4915 LD_SEARCH_FLAGS="" 4916 ;; 4917 OS/390-*) 4918 CFLAGS_OPTIMIZE="" # Optimizer is buggy 4919 $as_echo "#define _OE_SOCKETS 1" >>confdefs.h 4920 # needed in sys/socket.h 4921 ;; 4922 OSF1-1.0|OSF1-1.1|OSF1-1.2) 4923 # OSF/1 1.[012] from OSF, and derivatives, including Paragon OSF/1 4924 SHLIB_CFLAGS="" 4925 # Hack: make package name same as library name 4926 SHLIB_LD='ld -R -export :' 4927 SHLIB_LD_LIBS="" 4928 SHLIB_SUFFIX=".so" 4929 DL_OBJS="tclLoadOSF.o" 4930 DL_LIBS="" 4931 CC_SEARCH_FLAGS="" 4932 LD_SEARCH_FLAGS="" 4933 ;; 4934 OSF1-1.*) 4935 # OSF/1 1.3 from OSF using ELF, and derivatives, including AD2 4936 SHLIB_CFLAGS="-fPIC" 4937 if test "$SHARED_BUILD" = "1" ; then 4938 SHLIB_LD="ld -shared" 4939 else 4940 SHLIB_LD="ld -non_shared" 4941 fi 4942 SHLIB_LD_LIBS="" 4943 SHLIB_SUFFIX=".so" 4944 DL_OBJS="tclLoadDl.o" 4945 DL_LIBS="" 4946 CC_SEARCH_FLAGS="" 4947 LD_SEARCH_FLAGS="" 4948 ;; 4949 OSF1-V*) 4950 # Digital OSF/1 4951 SHLIB_CFLAGS="" 4952 if test "$SHARED_BUILD" = "1" ; then 4953 SHLIB_LD='ld -shared -expect_unresolved "*"' 4954 else 4955 SHLIB_LD='ld -non_shared -expect_unresolved "*"' 4956 fi 4957 SHLIB_LD_LIBS="" 4958 SHLIB_SUFFIX=".so" 4959 DL_OBJS="tclLoadDl.o" 4960 DL_LIBS="" 4961 CC_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}' 4962 LD_SEARCH_FLAGS='-rpath ${LIB_RUNTIME_DIR}' 4963 if test "$GCC" = "yes" ; then 4964 CFLAGS="$CFLAGS -mieee" 4965 else 4966 CFLAGS="$CFLAGS -DHAVE_TZSET -std1 -ieee" 4967 fi 4968 # see pthread_intro(3) for pthread support on osf1, k.furukawa 4969 if test "${TCL_THREADS}" = "1" ; then 4970 CFLAGS="$CFLAGS -DHAVE_PTHREAD_ATTR_SETSTACKSIZE" 4971 CFLAGS="$CFLAGS -DTCL_THREAD_STACK_MIN=PTHREAD_STACK_MIN*64" 4972 LIBS=`echo $LIBS | sed s/-lpthreads//` 4973 if test "$GCC" = "yes" ; then 4974 LIBS="$LIBS -lpthread -lmach -lexc" 4975 else 4976 CFLAGS="$CFLAGS -pthread" 4977 LDFLAGS="$LDFLAGS -pthread" 4978 fi 4979 fi 4980 4981 ;; 4982 QNX-6*) 4983 # QNX RTP 4984 # This may work for all QNX, but it was only reported for v6. 4985 SHLIB_CFLAGS="-fPIC" 4986 SHLIB_LD="ld -Bshareable -x" 4987 SHLIB_LD_LIBS="" 4988 SHLIB_SUFFIX=".so" 4989 DL_OBJS="tclLoadDl.o" 4990 # dlopen is in -lc on QNX 4991 DL_LIBS="" 4992 CC_SEARCH_FLAGS="" 4993 LD_SEARCH_FLAGS="" 4994 ;; 4995 RISCos-*) 4996 SHLIB_CFLAGS="-G 0" 4997 SHLIB_LD="echo tclLdAout $CC \{$SHLIB_CFLAGS\} | `pwd`/tclsh -r -G 0" 4998 SHLIB_LD_LIBS='${LIBS}' 4999 SHLIB_SUFFIX=".a" 5000 DL_OBJS="tclLoadAout.o" 5001 DL_LIBS="" 5002 LDFLAGS="$LDFLAGS -Wl,-D,08000000" 5003 CC_SEARCH_FLAGS='-L${LIB_RUNTIME_DIR}' 5004 LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS} 5005 ;; 5006 SCO_SV-3.2*) 5007 # Note, dlopen is available only on SCO 3.2.5 and greater. However, 5008 # this test works, since "uname -s" was non-standard in 3.2.4 and 5009 # below. 5010 if test "$GCC" = "yes" ; then 5011 SHLIB_CFLAGS="-fPIC -melf" 5012 LDFLAGS="$LDFLAGS -melf -Wl,-Bexport" 5013 else 5014 SHLIB_CFLAGS="-Kpic -belf" 5015 LDFLAGS="$LDFLAGS -belf -Wl,-Bexport" 5016 fi 5017 SHLIB_LD="ld -G" 5018 SHLIB_LD_LIBS="" 5019 SHLIB_SUFFIX=".so" 5020 DL_OBJS="tclLoadDl.o" 5021 DL_LIBS="" 5022 CC_SEARCH_FLAGS="" 5023 LD_SEARCH_FLAGS="" 5024 ;; 5025 SINIX*5.4*) 5026 SHLIB_CFLAGS="-K PIC" 5027 SHLIB_LD="cc -G" 5028 SHLIB_LD_LIBS="" 5029 SHLIB_SUFFIX=".so" 5030 DL_OBJS="tclLoadDl.o" 5031 DL_LIBS="-ldl" 5032 CC_SEARCH_FLAGS="" 5033 LD_SEARCH_FLAGS="" 5034 ;; 5035 SunOS-4*) 5036 SHLIB_CFLAGS="-PIC" 5037 SHLIB_LD="ld" 5038 SHLIB_LD_LIBS="" 5039 SHLIB_SUFFIX=".so" 5040 DL_OBJS="tclLoadDl.o" 5041 DL_LIBS="-ldl" 5042 CC_SEARCH_FLAGS='-L${LIB_RUNTIME_DIR}' 5043 LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS} 5044 5045 # SunOS can't handle version numbers with dots in them in library 5046 # specs, like -ltcl7.5, so use -ltcl75 instead. Also, it 5047 # requires an extra version number at the end of .so file names. 5048 # So, the library has to have a name like libtcl75.so.1.0 5049 5050 SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.so.1.0' 5051 UNSHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.a' 5052 TCL_LIB_VERSIONS_OK=nodots 5053 ;; 5054 SunOS-5.[0-6]) 5055 # Careful to not let 5.10+ fall into this case 5056 5057 # Note: If _REENTRANT isn't defined, then Solaris 5058 # won't define thread-safe library routines. 5059 5060 $as_echo "#define _REENTRANT 1" >>confdefs.h 5061 5062 $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h 5063 5064 5065 SHLIB_CFLAGS="-KPIC" 5066 5067 # Note: need the LIBS below, otherwise Tk won't find Tcl's 5068 # symbols when dynamically loaded into tclsh. 5069 5070 SHLIB_LD_LIBS='${LIBS}' 5071 SHLIB_SUFFIX=".so" 5072 DL_OBJS="tclLoadDl.o" 5073 DL_LIBS="-ldl" 5074 if test "$GCC" = "yes" ; then 5075 SHLIB_LD="$CC -shared" 5076 CC_SEARCH_FLAGS='-Wl,-R,${LIB_RUNTIME_DIR}' 5077 LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS} 5078 else 5079 SHLIB_LD="/usr/ccs/bin/ld -G -z text" 5080 CC_SEARCH_FLAGS='-R ${LIB_RUNTIME_DIR}' 5081 LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS} 5082 fi 5083 ;; 5084 SunOS-5*) 5085 # Note: If _REENTRANT isn't defined, then Solaris 5086 # won't define thread-safe library routines. 5087 5088 $as_echo "#define _REENTRANT 1" >>confdefs.h 5089 5090 $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h 5091 5092 5093 SHLIB_CFLAGS="-KPIC" 5094 5095 # Check to enable 64-bit flags for compiler/linker 5096 if test "$do64bit" = "yes" ; then 5097 arch=`isainfo` 5098 if test "$arch" = "sparcv9 sparc" ; then 5099 if test "$GCC" = "yes" ; then 5100 if test "`gcc -dumpversion | awk -F. '{print $1}'`" -lt "3" ; then 5101 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: 64bit mode not supported with GCC < 3.2 on $system" >&5 5102 $as_echo "$as_me: WARNING: 64bit mode not supported with GCC < 3.2 on $system" >&2;} 5103 else 5104 do64bit_ok=yes 5105 CFLAGS="$CFLAGS -m64 -mcpu=v9" 5106 LDFLAGS="$LDFLAGS -m64 -mcpu=v9" 5107 SHLIB_CFLAGS="-fPIC" 5108 fi 5109 else 5110 do64bit_ok=yes 5111 if test "$do64bitVIS" = "yes" ; then 5112 CFLAGS="$CFLAGS -xarch=v9a" 5113 LDFLAGS="$LDFLAGS -xarch=v9a" 5114 else 5115 CFLAGS="$CFLAGS -xarch=v9" 5116 LDFLAGS="$LDFLAGS -xarch=v9" 5117 fi 5118 # Solaris 64 uses this as well 5119 #LD_LIBRARY_PATH_VAR="LD_LIBRARY_PATH_64" 5120 fi 5121 elif test "$arch" = "amd64 i386" ; then 5122 if test "$GCC" = "yes" ; then 5123 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: 64bit mode not supported with GCC on $system" >&5 5124 $as_echo "$as_me: WARNING: 64bit mode not supported with GCC on $system" >&2;} 5125 else 5126 do64bit_ok=yes 5127 CFLAGS="$CFLAGS -xarch=amd64" 5128 LDFLAGS="$LDFLAGS -xarch=amd64" 5129 fi 5130 else 5131 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: 64bit mode not supported for $arch" >&5 5132 $as_echo "$as_me: WARNING: 64bit mode not supported for $arch" >&2;} 5133 fi 5134 fi 5135 5136 # Note: need the LIBS below, otherwise Tk won't find Tcl's 5137 # symbols when dynamically loaded into tclsh. 5138 5139 SHLIB_LD_LIBS='${LIBS}' 5140 SHLIB_SUFFIX=".so" 5141 DL_OBJS="tclLoadDl.o" 5142 DL_LIBS="-ldl" 5143 if test "$GCC" = "yes" ; then 5144 SHLIB_LD="$CC -shared" 5145 CC_SEARCH_FLAGS='-Wl,-R,${LIB_RUNTIME_DIR}' 5146 LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS} 5147 if test "$do64bit_ok" = "yes" ; then 5148 # We need to specify -static-libgcc or we need to 5149 # add the path to the sparv9 libgcc. 5150 SHLIB_LD="$SHLIB_LD -m64 -mcpu=v9 -static-libgcc" 5151 # for finding sparcv9 libgcc, get the regular libgcc 5152 # path, remove so name and append 'sparcv9' 5153 #v9gcclibdir="`gcc -print-file-name=libgcc_s.so` | ..." 5154 #CC_SEARCH_FLAGS="${CC_SEARCH_FLAGS},-R,$v9gcclibdir" 5155 fi 5156 else 5157 case $system in 5158 SunOS-5.[1-9][0-9]*) 5159 SHLIB_LD='${CC} -G -z text ${LDFLAGS}';; 5160 *) 5161 SHLIB_LD="/usr/ccs/bin/ld -G -z text";; 5162 esac 5163 CC_SEARCH_FLAGS='-Wl,-R,${LIB_RUNTIME_DIR}' 5164 LD_SEARCH_FLAGS='-R ${LIB_RUNTIME_DIR}' 5165 fi 5166 ;; 5167 ULTRIX-4.*) 5168 SHLIB_CFLAGS="-G 0" 5169 SHLIB_SUFFIX=".a" 5170 SHLIB_LD="echo tclLdAout $CC \{$SHLIB_CFLAGS\} | `pwd`/tclsh -r -G 0" 5171 SHLIB_LD_LIBS='${LIBS}' 5172 DL_OBJS="tclLoadAout.o" 5173 DL_LIBS="" 5174 LDFLAGS="$LDFLAGS -Wl,-D,08000000" 5175 CC_SEARCH_FLAGS='-L${LIB_RUNTIME_DIR}' 5176 LD_SEARCH_FLAGS=${CC_SEARCH_FLAGS} 5177 if test "$GCC" != "yes" ; then 5178 CFLAGS="$CFLAGS -DHAVE_TZSET -std1" 5179 fi 5180 ;; 5181 UNIX_SV* | UnixWare-5*) 5182 SHLIB_CFLAGS="-KPIC" 5183 SHLIB_LD="cc -G" 5184 SHLIB_LD_LIBS="" 5185 SHLIB_SUFFIX=".so" 5186 DL_OBJS="tclLoadDl.o" 5187 DL_LIBS="-ldl" 5188 # Some UNIX_SV* systems (unixware 1.1.2 for example) have linkers 5189 # that don't grok the -Bexport option. Test that it does. 5190 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld accepts -Bexport flag" >&5 5191 $as_echo_n "checking for ld accepts -Bexport flag... " >&6; } 5192 if ${tcl_cv_ld_Bexport+:} false; then : 5193 $as_echo_n "(cached) " >&6 5194 else 5195 5196 hold_ldflags=$LDFLAGS 5197 LDFLAGS="$LDFLAGS -Wl,-Bexport" 5198 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 5199 /* end confdefs.h. */ 5200 5201 int 5202 main () 5203 { 5204 int i; 5205 ; 5206 return 0; 5207 } 5208 _ACEOF 5209 if ac_fn_c_try_link "$LINENO"; then : 5210 tcl_cv_ld_Bexport=yes 5211 else 5212 tcl_cv_ld_Bexport=no 5213 fi 5214 rm -f core conftest.err conftest.$ac_objext \ 5215 conftest$ac_exeext conftest.$ac_ext 5216 LDFLAGS=$hold_ldflags 5217 fi 5218 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tcl_cv_ld_Bexport" >&5 5219 $as_echo "$tcl_cv_ld_Bexport" >&6; } 5220 if test $tcl_cv_ld_Bexport = yes; then 5221 LDFLAGS="$LDFLAGS -Wl,-Bexport" 5222 fi 5223 CC_SEARCH_FLAGS="" 5224 LD_SEARCH_FLAGS="" 5225 ;; 5226 esac 5227 5228 if test "$do64bit" = "yes" -a "$do64bit_ok" = "no" ; then 5229 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: 64bit support being disabled -- don't know magic for this platform" >&5 5230 $as_echo "$as_me: WARNING: 64bit support being disabled -- don't know magic for this platform" >&2;} 5231 fi 5232 5233 5234 5235 5236 # Step 4: If pseudo-static linking is in use (see K. B. Kenny, "Dynamic 5237 # Loading for Tcl -- What Became of It?". Proc. 2nd Tcl/Tk Workshop, 5238 # New Orleans, LA, Computerized Processes Unlimited, 1994), then we need 5239 # to determine which of several header files defines the a.out file 5240 # format (a.out.h, sys/exec.h, or sys/exec_aout.h). At present, we 5241 # support only a file format that is more or less version-7-compatible. 5242 # In particular, 5243 # - a.out files must begin with `struct exec'. 5244 # - the N_TXTOFF on the `struct exec' must compute the seek address 5245 # of the text segment 5246 # - The `struct exec' must contain a_magic, a_text, a_data, a_bss 5247 # and a_entry fields. 5248 # The following compilation should succeed if and only if either sys/exec.h 5249 # or a.out.h is usable for the purpose. 5250 # 5251 # Note that the modified COFF format used on MIPS Ultrix 4.x is usable; the 5252 # `struct exec' includes a second header that contains information that 5253 # duplicates the v7 fields that are needed. 5254 5255 if test "x$DL_OBJS" = "xtclLoadAout.o" ; then 5256 { $as_echo "$as_me:${as_lineno-$LINENO}: checking sys/exec.h" >&5 5257 $as_echo_n "checking sys/exec.h... " >&6; } 5258 if ${tcl_cv_sysexec_h+:} false; then : 5259 $as_echo_n "(cached) " >&6 5260 else 5261 5262 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 5263 /* end confdefs.h. */ 5264 #include <sys/exec.h> 5265 int 5266 main () 5267 { 5268 5269 struct exec foo; 5270 unsigned long seek; 5271 int flag; 5272 #if defined(__mips) || defined(mips) 5273 seek = N_TXTOFF (foo.ex_f, foo.ex_o); 5274 #else 5275 seek = N_TXTOFF (foo); 5276 #endif 5277 flag = (foo.a_magic == OMAGIC); 5278 return foo.a_text + foo.a_data + foo.a_bss + foo.a_entry; 5279 5280 ; 5281 return 0; 5282 } 5283 _ACEOF 5284 if ac_fn_c_try_compile "$LINENO"; then : 5285 tcl_cv_sysexec_h=usable 5286 else 5287 tcl_cv_sysexec_h=unusable 5288 fi 5289 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 5290 fi 5291 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tcl_cv_sysexec_h" >&5 5292 $as_echo "$tcl_cv_sysexec_h" >&6; } 5293 if test $tcl_cv_sysexec_h = usable; then 5294 $as_echo "#define USE_SYS_EXEC_H 1" >>confdefs.h 5295 5296 else 5297 { $as_echo "$as_me:${as_lineno-$LINENO}: checking a.out.h" >&5 5298 $as_echo_n "checking a.out.h... " >&6; } 5299 if ${tcl_cv_aout_h+:} false; then : 5300 $as_echo_n "(cached) " >&6 5301 else 5302 5303 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 5304 /* end confdefs.h. */ 5305 #include <a.out.h> 5306 int 5307 main () 5308 { 5309 5310 struct exec foo; 5311 unsigned long seek; 5312 int flag; 5313 #if defined(__mips) || defined(mips) 5314 seek = N_TXTOFF (foo.ex_f, foo.ex_o); 5315 #else 5316 seek = N_TXTOFF (foo); 5317 #endif 5318 flag = (foo.a_magic == OMAGIC); 5319 return foo.a_text + foo.a_data + foo.a_bss + foo.a_entry; 5320 5321 ; 5322 return 0; 5323 } 5324 _ACEOF 5325 if ac_fn_c_try_compile "$LINENO"; then : 5326 tcl_cv_aout_h=usable 5327 else 5328 tcl_cv_aout_h=unusable 5329 fi 5330 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 5331 fi 5332 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tcl_cv_aout_h" >&5 5333 $as_echo "$tcl_cv_aout_h" >&6; } 5334 if test $tcl_cv_aout_h = usable; then 5335 $as_echo "#define USE_A_OUT_H 1" >>confdefs.h 5336 5337 else 5338 { $as_echo "$as_me:${as_lineno-$LINENO}: checking sys/exec_aout.h" >&5 5339 $as_echo_n "checking sys/exec_aout.h... " >&6; } 5340 if ${tcl_cv_sysexecaout_h+:} false; then : 5341 $as_echo_n "(cached) " >&6 5342 else 5343 5344 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 5345 /* end confdefs.h. */ 5346 #include <sys/exec_aout.h> 5347 int 5348 main () 5349 { 5350 5351 struct exec foo; 5352 unsigned long seek; 5353 int flag; 5354 #if defined(__mips) || defined(mips) 5355 seek = N_TXTOFF (foo.ex_f, foo.ex_o); 5356 #else 5357 seek = N_TXTOFF (foo); 5358 #endif 5359 flag = (foo.a_midmag == OMAGIC); 5360 return foo.a_text + foo.a_data + foo.a_bss + foo.a_entry; 5361 5362 ; 5363 return 0; 5364 } 5365 _ACEOF 5366 if ac_fn_c_try_compile "$LINENO"; then : 5367 tcl_cv_sysexecaout_h=usable 5368 else 5369 tcl_cv_sysexecaout_h=unusable 5370 fi 5371 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 5372 fi 5373 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tcl_cv_sysexecaout_h" >&5 5374 $as_echo "$tcl_cv_sysexecaout_h" >&6; } 5375 if test $tcl_cv_sysexecaout_h = usable; then 5376 $as_echo "#define USE_SYS_EXEC_AOUT_H 1" >>confdefs.h 5377 5378 else 5379 DL_OBJS="" 5380 fi 5381 fi 5382 fi 5383 fi 5384 5385 # Step 5: disable dynamic loading if requested via a command-line switch. 5386 5387 # Check whether --enable-load was given. 5388 if test "${enable_load+set}" = set; then : 5389 enableval=$enable_load; tcl_ok=$enableval 5390 else 5391 tcl_ok=yes 5392 fi 5393 5394 if test "$tcl_ok" = "no"; then 5395 DL_OBJS="" 5396 fi 5397 5398 if test "x$DL_OBJS" != "x" ; then 5399 BUILD_DLTEST="\$(DLTEST_TARGETS)" 5400 else 5401 echo "Can't figure out how to do dynamic loading or shared libraries" 5402 echo "on this system." 5403 SHLIB_CFLAGS="" 5404 SHLIB_LD="" 5405 SHLIB_SUFFIX="" 5406 DL_OBJS="tclLoadNone.o" 5407 DL_LIBS="" 5408 LDFLAGS="$LDFLAGS_ORIG" 5409 CC_SEARCH_FLAGS="" 5410 LD_SEARCH_FLAGS="" 5411 BUILD_DLTEST="" 5412 fi 5413 5414 # If we're running gcc, then change the C flags for compiling shared 5415 # libraries to the right flags for gcc, instead of those for the 5416 # standard manufacturer compiler. 5417 5418 if test "$DL_OBJS" != "tclLoadNone.o" ; then 5419 if test "$GCC" = "yes" ; then 5420 case $system in 5421 AIX-*) 5422 ;; 5423 BSD/OS*) 5424 ;; 5425 IRIX*) 5426 ;; 5427 NetBSD-*|FreeBSD-*|OpenBSD-*) 5428 ;; 5429 Darwin-*) 5430 ;; 5431 RISCos-*) 5432 ;; 5433 SCO_SV-3.2*) 5434 ;; 5435 ULTRIX-4.*) 5436 ;; 5437 *) 5438 SHLIB_CFLAGS="-fPIC" 5439 ;; 5440 esac 5441 fi 5442 fi 5443 5444 if test "$SHARED_LIB_SUFFIX" = "" ; then 5445 SHARED_LIB_SUFFIX='${VERSION}\$\{DBGX\}${SHLIB_SUFFIX}' 5446 fi 5447 if test "$UNSHARED_LIB_SUFFIX" = "" ; then 5448 UNSHARED_LIB_SUFFIX='${VERSION}\$\{DBGX\}.a' 5449 fi 5450 5451 if test "${SHARED_BUILD}" = "1" && test "${SHLIB_SUFFIX}" != "" ; then 5452 LIB_SUFFIX=${SHARED_LIB_SUFFIX} 5453 MAKE_LIB='${SHLIB_LD} -o $@ ${OBJS} ${SHLIB_LD_LIBS} ${TCL_SHLIB_LD_EXTRAS} ${TK_SHLIB_LD_EXTRAS} ${LD_SEARCH_FLAGS}' 5454 INSTALL_LIB='$(INSTALL_LIBRARY) $(LIB_FILE) $(LIB_INSTALL_DIR)/$(LIB_FILE)' 5455 else 5456 LIB_SUFFIX=${UNSHARED_LIB_SUFFIX} 5457 5458 if test "$RANLIB" = "" ; then 5459 MAKE_LIB='$(STLIB_LD) $@ ${OBJS}' 5460 INSTALL_LIB='$(INSTALL_LIBRARY) $(LIB_FILE) $(LIB_INSTALL_DIR)/$(LIB_FILE)' 5461 else 5462 MAKE_LIB='${STLIB_LD} $@ ${OBJS} ; ${RANLIB} $@' 5463 INSTALL_LIB='$(INSTALL_LIBRARY) $(LIB_FILE) $(LIB_INSTALL_DIR)/$(LIB_FILE) ; (cd $(LIB_INSTALL_DIR) ; $(RANLIB) $(LIB_FILE))' 5464 fi 5465 5466 fi 5467 5468 5469 # Stub lib does not depend on shared/static configuration 5470 if test "$RANLIB" = "" ; then 5471 MAKE_STUB_LIB='${STLIB_LD} $@ ${STUB_LIB_OBJS}' 5472 INSTALL_STUB_LIB='$(INSTALL_LIBRARY) $(STUB_LIB_FILE) $(LIB_INSTALL_DIR)/$(STUB_LIB_FILE)' 5473 else 5474 MAKE_STUB_LIB='${STLIB_LD} $@ ${STUB_LIB_OBJS} ; ${RANLIB} $@' 5475 INSTALL_STUB_LIB='$(INSTALL_LIBRARY) $(STUB_LIB_FILE) $(LIB_INSTALL_DIR)/$(STUB_LIB_FILE) ; (cd $(LIB_INSTALL_DIR) ; $(RANLIB) $(STUB_LIB_FILE))' 5476 fi 5477 5478 5479 5480 5481 5482 5483 5484 5485 5486 5487 5488 5489 5490 5491 5492 5493 5494 5495 5496 5497 5498 5499 5500 5501 5502 5503 5504 5505 5506 5507 5508 5509 5510 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to build libraries" >&5 5511 $as_echo_n "checking how to build libraries... " >&6; } 5512 # Check whether --enable-shared was given. 5513 if test "${enable_shared+set}" = set; then : 5514 enableval=$enable_shared; tcl_ok=$enableval 5515 else 5516 tcl_ok=yes 5517 fi 5518 5519 5520 if test "${enable_shared+set}" = set; then 5521 enableval="$enable_shared" 5522 tcl_ok=$enableval 5523 else 5524 tcl_ok=yes 5525 fi 5526 5527 if test "$tcl_ok" = "yes" ; then 5528 { $as_echo "$as_me:${as_lineno-$LINENO}: result: shared" >&5 5529 $as_echo "shared" >&6; } 5530 SHARED_BUILD=1 5531 else 5532 { $as_echo "$as_me:${as_lineno-$LINENO}: result: static" >&5 5533 $as_echo "static" >&6; } 5534 SHARED_BUILD=0 5535 $as_echo "#define STATIC_BUILD 1" >>confdefs.h 5536 5537 fi 5538 5539 5540 5541 5542 5543 5544 5545 2105 5546 2106 5547 … … 2116 5557 done 2117 5558 if test "x${make_command}" = "x" ; then 2118 as_fn_error "Requires GNU make. You can specify a version with \$MAKE" "$LINENO" 55559 as_fn_error $? "Requires GNU make. You can specify a version with \$MAKE" "$LINENO" 5 2119 5560 fi 2120 5561 MAKE=${make_command} … … 2234 5675 2235 5676 2236 ac_config_files="$ac_config_files Makefile pkgIndex.tcl apps/Makefile apps/about apps/encodedata apps/rappture apps/rappture-csh.env apps/rappture.env apps/rappture.use apps/rerun apps/simsim apps/xmldiff scripts/Makefile "5677 ac_config_files="$ac_config_files Makefile pkgIndex.tcl apps/Makefile apps/about apps/encodedata apps/rappture apps/rappture-csh.env apps/rappture.env apps/rappture.use apps/rerun apps/simsim apps/xmldiff scripts/Makefile src/Makefile" 2237 5678 2238 5679 cat >confcache <<\_ACEOF … … 2300 5741 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else 2301 5742 if test -w "$cache_file"; then 2302 test "x$cache_file" != "x/dev/null" &&5743 if test "x$cache_file" != "x/dev/null"; then 2303 5744 { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5 2304 5745 $as_echo "$as_me: updating cache $cache_file" >&6;} 2305 cat confcache >$cache_file 5746 if test ! -f "$cache_file" || test -h "$cache_file"; then 5747 cat confcache >"$cache_file" 5748 else 5749 case $cache_file in #( 5750 */* | ?:*) 5751 mv -f confcache "$cache_file"$$ && 5752 mv -f "$cache_file"$$ "$cache_file" ;; #( 5753 *) 5754 mv -f confcache "$cache_file" ;; 5755 esac 5756 fi 5757 fi 2306 5758 else 2307 5759 { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5 … … 2355 5807 ac_libobjs= 2356 5808 ac_ltlibobjs= 5809 U= 2357 5810 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue 2358 5811 # 1. Remove the extension, and $U if already installed. … … 2370 5823 2371 5824 2372 : ${CONFIG_STATUS=./config.status}5825 : "${CONFIG_STATUS=./config.status}" 2373 5826 ac_write_fail=0 2374 5827 ac_clean_files_save=$ac_clean_files … … 2471 5924 2472 5925 # Find who we are. Look in the path if we contain no directory separator. 5926 as_myself= 2473 5927 case $0 in #(( 2474 5928 *[\\/]* ) as_myself=$0 ;; … … 2516 5970 2517 5971 2518 # as_fn_error ERROR [LINENO LOG_FD]2519 # --------------------------------- 5972 # as_fn_error STATUS ERROR [LINENO LOG_FD] 5973 # ---------------------------------------- 2520 5974 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are 2521 5975 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the 2522 # script with status $?, using 1 if that was 0.5976 # script with STATUS, using 1 if that was 0. 2523 5977 as_fn_error () 2524 5978 { 2525 as_status=$ ?; test $as_status -eq 0 && as_status=12526 if test "$ 3"; then2527 as_lineno=${as_lineno-"$ 2"} as_lineno_stack=as_lineno_stack=$as_lineno_stack2528 $as_echo "$as_me:${as_lineno-$LINENO}: error: $ 1" >&$35979 as_status=$1; test $as_status -eq 0 && as_status=1 5980 if test "$4"; then 5981 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 5982 $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 2529 5983 fi 2530 $as_echo "$as_me: error: $ 1" >&25984 $as_echo "$as_me: error: $2" >&2 2531 5985 as_fn_exit $as_status 2532 5986 } # as_fn_error … … 2724 6178 done 2725 6179 test -z "$as_dirs" || eval "mkdir $as_dirs" 2726 } || test -d "$as_dir" || as_fn_error "cannot create directory $as_dir"6180 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" 2727 6181 2728 6182 … … 2778 6232 ac_log=" 2779 6233 This file was extended by RapptureGUI $as_me 1.1, which was 2780 generated by GNU Autoconf 2.6 5. Invocation command line was6234 generated by GNU Autoconf 2.68. Invocation command line was 2781 6235 2782 6236 CONFIG_FILES = $CONFIG_FILES … … 2831 6285 ac_cs_version="\\ 2832 6286 RapptureGUI config.status 1.1 2833 configured by $0, generated by GNU Autoconf 2.6 5,6287 configured by $0, generated by GNU Autoconf 2.68, 2834 6288 with options \\"\$ac_cs_config\\" 2835 6289 2836 Copyright (C) 20 09Free Software Foundation, Inc.6290 Copyright (C) 2010 Free Software Foundation, Inc. 2837 6291 This config.status script is free software; the Free Software Foundation 2838 6292 gives unlimited permission to copy, distribute and modify it." … … 2851 6305 do 2852 6306 case $1 in 2853 --*= *)6307 --*=?*) 2854 6308 ac_option=`expr "X$1" : 'X\([^=]*\)='` 2855 6309 ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'` 6310 ac_shift=: 6311 ;; 6312 --*=) 6313 ac_option=`expr "X$1" : 'X\([^=]*\)='` 6314 ac_optarg= 2856 6315 ac_shift=: 2857 6316 ;; … … 2877 6336 case $ac_optarg in 2878 6337 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; 6338 '') as_fn_error $? "missing file argument" ;; 2879 6339 esac 2880 6340 as_fn_append CONFIG_FILES " '$ac_optarg'" … … 2887 6347 2888 6348 # This is an error. 2889 -*) as_fn_error "unrecognized option: \`$1'6349 -*) as_fn_error $? "unrecognized option: \`$1' 2890 6350 Try \`$0 --help' for more information." ;; 2891 6351 … … 2949 6409 "apps/xmldiff") CONFIG_FILES="$CONFIG_FILES apps/xmldiff" ;; 2950 6410 "scripts/Makefile") CONFIG_FILES="$CONFIG_FILES scripts/Makefile" ;; 2951 2952 *) as_fn_error "invalid argument: \`$ac_config_target'" "$LINENO" 5;; 6411 "src/Makefile") CONFIG_FILES="$CONFIG_FILES src/Makefile" ;; 6412 6413 *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;; 2953 6414 esac 2954 6415 done … … 2971 6432 $debug || 2972 6433 { 2973 tmp= 6434 tmp= ac_tmp= 2974 6435 trap 'exit_status=$? 2975 { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status 6436 : "${ac_tmp:=$tmp}" 6437 { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status 2976 6438 ' 0 2977 6439 trap 'as_fn_exit 1' 1 2 13 15 … … 2981 6443 { 2982 6444 tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` && 2983 test - n "$tmp" && test -d "$tmp"6445 test -d "$tmp" 2984 6446 } || 2985 6447 { 2986 6448 tmp=./conf$$-$RANDOM 2987 6449 (umask 077 && mkdir "$tmp") 2988 } || as_fn_error "cannot create a temporary directory in ." "$LINENO" 5 6450 } || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5 6451 ac_tmp=$tmp 2989 6452 2990 6453 # Set up the scripts for CONFIG_FILES section. … … 3003 6466 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null` 3004 6467 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then 3005 ac_cs_awk_cr='\ r'6468 ac_cs_awk_cr='\\r' 3006 6469 else 3007 6470 ac_cs_awk_cr=$ac_cr 3008 6471 fi 3009 6472 3010 echo 'BEGIN {' >"$ tmp/subs1.awk" &&6473 echo 'BEGIN {' >"$ac_tmp/subs1.awk" && 3011 6474 _ACEOF 3012 6475 … … 3017 6480 echo "_ACEOF" 3018 6481 } >conf$$subs.sh || 3019 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 53020 ac_delim_num=`echo "$ac_subst_vars" | grep -c ' $'`6482 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 6483 ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'` 3021 6484 ac_delim='%!_!# ' 3022 6485 for ac_last_try in false false false false false :; do 3023 6486 . ./conf$$subs.sh || 3024 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 56487 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 3025 6488 3026 6489 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X` … … 3028 6491 break 3029 6492 elif $ac_last_try; then 3030 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 56493 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 3031 6494 else 3032 6495 ac_delim="$ac_delim!$ac_delim _$ac_delim!! " … … 3036 6499 3037 6500 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 3038 cat >>"\$ tmp/subs1.awk" <<\\_ACAWK &&6501 cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK && 3039 6502 _ACEOF 3040 6503 sed -n ' … … 3084 6547 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 3085 6548 _ACAWK 3086 cat >>"\$ tmp/subs1.awk" <<_ACAWK &&6549 cat >>"\$ac_tmp/subs1.awk" <<_ACAWK && 3087 6550 for (key in S) S_is_set[key] = 1 3088 6551 FS = "" … … 3116 6579 else 3117 6580 cat 3118 fi < "$ tmp/subs1.awk" > "$tmp/subs.awk" \3119 || as_fn_error "could not setup config files machinery" "$LINENO" 56581 fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \ 6582 || as_fn_error $? "could not setup config files machinery" "$LINENO" 5 3120 6583 _ACEOF 3121 6584 3122 # VPATH may cause trouble with some makes, so we remove $(srcdir),3123 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and6585 # VPATH may cause trouble with some makes, so we remove sole $(srcdir), 6586 # ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and 3124 6587 # trailing colons and then remove the whole line if VPATH becomes empty 3125 6588 # (actually we leave an empty line to preserve line numbers). 3126 6589 if test "x$srcdir" = x.; then 3127 ac_vpsub='/^[ ]*VPATH[ ]*=/{ 3128 s/:*\$(srcdir):*/:/ 3129 s/:*\${srcdir}:*/:/ 3130 s/:*@srcdir@:*/:/ 3131 s/^\([^=]*=[ ]*\):*/\1/ 6590 ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{ 6591 h 6592 s/// 6593 s/^/:/ 6594 s/[ ]*$/:/ 6595 s/:\$(srcdir):/:/g 6596 s/:\${srcdir}:/:/g 6597 s/:@srcdir@:/:/g 6598 s/^:*// 3132 6599 s/:*$// 6600 x 6601 s/\(=[ ]*\).*/\1/ 6602 G 6603 s/\n// 3133 6604 s/^[^=]*=[ ]*$// 3134 6605 }' … … 3148 6619 case $ac_mode$ac_tag in 3149 6620 :[FHL]*:*);; 3150 :L* | :C*:*) as_fn_error "invalid tag \`$ac_tag'" "$LINENO" 5;;6621 :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;; 3151 6622 :[FH]-) ac_tag=-:-;; 3152 6623 :[FH]*) ac_tag=$ac_tag:$ac_tag.in;; … … 3167 6638 do 3168 6639 case $ac_f in 3169 -) ac_f="$ tmp/stdin";;6640 -) ac_f="$ac_tmp/stdin";; 3170 6641 *) # Look for the file first in the build tree, then in the source tree 3171 6642 # (if the path is not absolute). The absolute path cannot be DOS-style, … … 3176 6647 *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";; 3177 6648 esac || 3178 as_fn_error "cannot find input file: \`$ac_f'" "$LINENO" 5;;6649 as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;; 3179 6650 esac 3180 6651 case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac … … 3202 6673 3203 6674 case $ac_tag in 3204 *:-:* | *:-) cat >"$ tmp/stdin" \3205 || as_fn_error "could not create $ac_file" "$LINENO" 5 ;;6675 *:-:* | *:-) cat >"$ac_tmp/stdin" \ 6676 || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;; 3206 6677 esac 3207 6678 ;; … … 3339 6810 $ac_datarootdir_hack 3340 6811 " 3341 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ tmp/subs.awk" >$tmp/out\3342 || as_fn_error"could not create $ac_file" "$LINENO" 56812 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \ 6813 >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5 3343 6814 3344 6815 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" && 3345 { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } && 3346 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } && 6816 { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } && 6817 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \ 6818 "$ac_tmp/out"`; test -z "$ac_out"; } && 3347 6819 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir' 3348 which seems to be undefined. Please make sure it is defined ." >&56820 which seems to be undefined. Please make sure it is defined" >&5 3349 6821 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir' 3350 which seems to be undefined. Please make sure it is defined ." >&2;}3351 3352 rm -f "$ tmp/stdin"6822 which seems to be undefined. Please make sure it is defined" >&2;} 6823 6824 rm -f "$ac_tmp/stdin" 3353 6825 case $ac_file in 3354 -) cat "$ tmp/out" && rm -f "$tmp/out";;3355 *) rm -f "$ac_file" && mv "$ tmp/out" "$ac_file";;6826 -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";; 6827 *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";; 3356 6828 esac \ 3357 || as_fn_error "could not create $ac_file" "$LINENO" 56829 || as_fn_error $? "could not create $ac_file" "$LINENO" 5 3358 6830 ;; 3359 6831 … … 3370 6842 3371 6843 test $ac_write_fail = 0 || 3372 as_fn_error "write failure creating $CONFIG_STATUS" "$LINENO" 56844 as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5 3373 6845 3374 6846 … … 3391 6863 # Use ||, not &&, to avoid exiting from the if with $? = 1, which 3392 6864 # would make configure fail if this is the last instruction. 3393 $ac_cs_success || as_fn_exit $?6865 $ac_cs_success || as_fn_exit 1 3394 6866 fi 3395 6867 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then -
branches/blt4/gui/configure.in
r1884 r2170 27 27 AC_PROG_MKDIR_P 28 28 AC_PROG_MAKE_SET 29 AC_PROG_CC 30 31 SC_CONFIG_CFLAGS 32 SC_ENABLE_SHARED 33 34 AC_SUBST(CFLAGS_DEBUG) 35 AC_SUBST(CFLAGS_OPTIMIZE) 36 AC_SUBST(STLIB_LD) 37 AC_SUBST(SHLIB_LD) 38 AC_SUBST(SHLIB_CFLAGS) 39 AC_SUBST(SHLIB_LDFLAGS) 40 AC_SUBST(SHLIB_SUFFIX) 29 41 30 42 gui_with_tcl="" … … 163 175 apps/xmldiff 164 176 scripts/Makefile 177 src/Makefile 165 178 ]) 166 179 AC_OUTPUT -
branches/blt4/gui/pkgIndex.tcl.in
r1884 r2170 8 8 variable library $dir 9 9 } 10 set ext [info sharedlibextension] 11 load [file join $dir "RapptureGUI${version}${ext}"] 10 12 package provide RapptureGUI $version 11 13 } $dir] -
branches/blt4/lang/java/Library.java
r1824 r2170 100 100 } 101 101 102 public String xml(){ 103 return jRpXml(libPtr); 104 } 105 102 106 103 107 // Native Functions---------------------------------------------------------- … … 118 122 119 123 private native void jRpResult(long libPtr, int exitStatus); 124 private native String jRpXml(long libPtr); 120 125 121 126 // Private Attributes-------------------------------------------------------- -
branches/blt4/lang/java/Units.java
r1824 r2170 23 23 } 24 24 25 public static String convert(String fromVal, String to, boolean units){ 25 // Public Methods------------------------------------------------------------ 26 public static double convertDouble(double fromVal, String to){ 27 return Double.parseDouble( 28 jRpUnitsConvert(Double.toString(fromVal), to, false)); 29 } 30 31 public static String convertString(String fromVal, String to, boolean units){ 26 32 return jRpUnitsConvert(fromVal, to, units); 27 33 } 28 34 29 public static String convert (String fromVal, String to){35 public static String convertString(String fromVal, String to){ 30 36 return jRpUnitsConvert(fromVal, to, true); 31 37 } 32 38 33 private static native String jRpUnitsConvert(String fromVal, String to, boolean units); 39 // Native Functions---------------------------------------------------------- 40 private static native String jRpUnitsConvert(String fromVal, String to, 41 boolean units); 34 42 } 35 43 -
branches/blt4/lang/java/Utils.java
r1744 r2170 26 26 } 27 27 28 public static void progress(int percent){ 29 jRpUtilsProgress(percent, ""); 30 } 31 28 32 private static native void jRpUtilsProgress(int percent, String text); 29 33 -
branches/blt4/lang/java/jRpLibrary.cc
r1824 r2170 145 145 } 146 146 147 // xml 148 JNIEXPORT jstring JNICALL Java_rappture_Library_jRpXml 149 (JNIEnv *env, jobject obj, jlong libPtr) { 150 std::string retStr = ((RpLibrary*)libPtr)->xml(); 151 return(env->NewStringUTF(retStr.c_str())); 152 } 153 -
branches/blt4/lang/java/jRpUnits.cc
r1824 r2170 17 17 #include "rappture.h" 18 18 19 // convert 19 // convertString 20 20 JNIEXPORT jstring JNICALL Java_rappture_Units_jRpUnitsConvert 21 21 (JNIEnv *env, jclass cls, jstring javaFromVal, jstring javaTo, jboolean units){ … … 34 34 ex = env->FindClass("java/lang/RuntimeException"); 35 35 if (ex){ 36 errorMsg = "C onnot convert ";36 errorMsg = "Cannot convert "; 37 37 errorMsg += nativeFromVal; 38 38 errorMsg += " to "; -
branches/blt4/lang/tcl/scripts/Makefile.in
r1948 r2170 41 41 $(srcdir)/exec.tcl \ 42 42 $(srcdir)/library.tcl \ 43 $(srcdir)/objects.tcl \ 43 44 $(srcdir)/result.tcl \ 44 45 $(srcdir)/units.tcl 45 46 47 OBJECTS = \ 48 boolean \ 49 choice \ 50 curve \ 51 group \ 52 histogram \ 53 image \ 54 integer \ 55 note \ 56 number \ 57 phase \ 58 string 59 60 TYPEFILES = \ 61 $(srcdir)/types/boolean.tcl \ 62 $(srcdir)/types/choices.tcl \ 63 $(srcdir)/types/color.tcl \ 64 $(srcdir)/types/file.tcl \ 65 $(srcdir)/types/image.tcl \ 66 $(srcdir)/types/language.tcl \ 67 $(srcdir)/types/string.tcl \ 68 $(srcdir)/types/units.tcl 69 70 VALIDATEFILES = \ 71 $(srcdir)/validations/enable.tcl \ 72 $(srcdir)/validations/int.tcl \ 73 $(srcdir)/validations/imformat.tcl \ 74 $(srcdir)/validations/imresize.tcl \ 75 $(srcdir)/validations/number.tcl \ 76 $(srcdir)/validations/size.tcl 77 46 78 all: tclIndex 47 79 48 tclIndex: $(FILES)80 tclIndex: install-objects install-types install-validations $(FILES) 49 81 $(TCLSH) $(srcdir)/../tclconfig/mkindex.tcl --srcdir $(srcdir) \ 50 82 --outfile tclIndex 83 $(TCLSH) $(srcdir)/../tclconfig/mkobjects.tcl --srcdir $(srcdir) \ 84 $(OBJECTS) 51 85 52 86 install: tclIndex … … 57 91 $(INSTALL) -m 0444 tclIndex $(destdir) 58 92 93 install-objects: 94 $(MKDIR_P) -m 0755 $(destdir)/objects 95 $(INSTALL) -m 0444 $(srcdir)/objects/base.rp $(destdir)/objects 96 for i in $(OBJECTS); do \ 97 echo "Installing object definition: $$i" ; \ 98 $(MKDIR_P) -m 0755 $(destdir)/objects/$$i ; \ 99 for j in $(srcdir)/objects/$$i/*; do \ 100 $(INSTALL) -m 0444 $$j $(destdir)/objects/$$i ; \ 101 done \ 102 done 103 104 install-types: $(TYPEFILES) 105 $(MKDIR_P) -m 0755 $(destdir)/types 106 @for i in $(TYPEFILES); do \ 107 echo "Installing $$i" ; \ 108 $(INSTALL) -m 555 $$i $(destdir)/types ; \ 109 done 110 111 install-validations: $(VALIDATEFILES) 112 $(MKDIR_P) -m 0755 $(destdir)/validations 113 @for i in $(VALIDATEFILES); do \ 114 echo "Installing $$i" ; \ 115 $(INSTALL) -m 555 $$i $(destdir)/validations ; \ 116 done 117 59 118 clean: 60 119 $(RM) tclIndex -
branches/blt4/lang/tcl/scripts/library.tcl
r2150 r2170 17 17 variable stdlib "" 18 18 } 19 20 # load the object system along with the XML library code 21 Rappture::objects::init 19 22 20 23 # ---------------------------------------------------------------------- … … 133 136 134 137 foreach cpath [$xmlobj children -as path $path] { 135 switch -- [$xmlobj element -as type $cpath] { 138 set type [$xmlobj element -as type $cpath] 139 switch -- $type { 136 140 group - phase { 137 141 lappend queue $cpath … … 167 171 } 168 172 default { 169 # add this to the return list with the right flavor 170 if {$params(-as) == "component"} { 171 lappend rlist $cpath 172 } else { 173 lappend rlist [$xmlobj element -as $params(-as) $cpath] 173 if {[catch {Rappture::objects::get $type}] == 0} { 174 # add this to the return list with the right flavor 175 if {$params(-as) == "component"} { 176 lappend rlist $cpath 177 } else { 178 lappend rlist [$xmlobj element -as $params(-as) $cpath] 179 } 174 180 } 175 181 … … 200 206 public method copy {path from args} 201 207 public method remove {{path ""}} 202 public method xml { }208 public method xml {{path ""}} 203 209 204 210 public method diff {libobj} … … 651 657 652 658 # ---------------------------------------------------------------------- 653 # USAGE: xml 659 # USAGE: xml ?<path>? 654 660 # 655 661 # Returns a string representing the XML information for the information 656 662 # in this library. 657 663 # ---------------------------------------------------------------------- 658 itcl::body Rappture::LibraryObj::xml {} { 659 return [$_node asXML] 664 itcl::body Rappture::LibraryObj::xml {{path ""}} { 665 if {"" != $path} { 666 set n [find $path] 667 } else { 668 set n $_node 669 } 670 return [$n asXML] 660 671 } 661 672 -
branches/blt4/lang/tcl/src/RpRusage.c
r1018 r2170 35 35 36 36 static RpRusageStats RpRusage_Start; /* time at start of program */ 37 static RpRusageStats RpRusage_MarkStats; /* stats from last "mark" */38 39 37 40 38 static Tcl_ObjCmdProc RpRusageCmd; 39 static Tcl_ObjCmdProc RpRusageForgetOp; 41 40 static Tcl_ObjCmdProc RpRusageMarkOp; 42 41 static Tcl_ObjCmdProc RpRusageMeasureOp; … … 46 45 static double RpRusageTimeDiff _ANSI_ARGS_((struct timeval *currptr, 47 46 struct timeval *prevptr)); 47 static void RpDestroyMarkNames _ANSI_ARGS_((ClientData cdata, 48 Tcl_Interp *interp)); 48 49 49 50 /* … … 51 52 */ 52 53 static Rp_OpSpec rusageOps[] = { 53 {"mark", 2, RpRusageMarkOp, 2, 2, "",}, 54 {"measure", 2, RpRusageMeasureOp, 2, 2, "",}, 54 {"forget", 1, RpRusageForgetOp, 2, 0, "?name...?",}, 55 {"mark", 2, RpRusageMarkOp, 2, 3, "?name?",}, 56 {"measure", 2, RpRusageMeasureOp, 2, 3, "?name?",}, 55 57 }; 56 58 static int nRusageOps = sizeof(rusageOps) / sizeof(Rp_OpSpec); … … 68 70 Tcl_Interp *interp; /* interpreter being initialized */ 69 71 { 72 Tcl_HashTable *markNamesPtr; 73 70 74 Tcl_CreateObjCommand(interp, "::Rappture::rusage", RpRusageCmd, 71 75 NULL, NULL); 72 76 73 /* set an initial mark automatically */ 77 /* set up a hash table for different mark names */ 78 markNamesPtr = (Tcl_HashTable*)ckalloc(sizeof(Tcl_HashTable)); 79 Tcl_InitHashTable(markNamesPtr, TCL_STRING_KEYS); 80 81 Tcl_SetAssocData(interp, "RpRusageMarks", 82 RpDestroyMarkNames, (ClientData)markNamesPtr); 83 84 /* capture the starting time for this program */ 85 if (RpRusageCapture(interp, &RpRusage_Start) != TCL_OK) { 86 return TCL_ERROR; 87 } 88 89 /* set an initial "global" mark automatically */ 74 90 if (RpRusageMarkOp(NULL, interp, 0, (Tcl_Obj**)NULL) != TCL_OK) { 75 91 return TCL_ERROR; 76 92 } 77 78 /* capture the starting time for this program */79 memcpy(&RpRusage_Start, &RpRusage_MarkStats, sizeof(RpRusageStats));80 93 81 94 return TCL_OK; … … 121 134 * the start of an execution. Handles the following syntax: 122 135 * 123 * rusage mark 136 * rusage mark ?name? 124 137 * 125 138 * Returns TCL_OK on success, and TCL_ERROR (along with an error … … 132 145 Tcl_Interp *interp; /* interpreter handling this request */ 133 146 int objc; /* number of command line args */ 134 Tcl_Obj *const *objv; /* strings for command line args */ 135 { 136 return RpRusageCapture(interp, &RpRusage_MarkStats); 147 Tcl_Obj *const *objv; /* strings for command line args */ 148 { 149 char *markName; 150 Tcl_HashTable *markNamesPtr; 151 Tcl_HashEntry *entryPtr; 152 int newEntry; 153 RpRusageStats *markPtr; 154 155 markNamesPtr = (Tcl_HashTable *) 156 Tcl_GetAssocData(interp, "RpRusageMarks", NULL); 157 158 markName = (objc > 2) ? Tcl_GetString(objv[2]): "global"; 159 entryPtr = Tcl_CreateHashEntry(markNamesPtr, markName, &newEntry); 160 if (newEntry) { 161 markPtr = (RpRusageStats*)ckalloc(sizeof(RpRusageStats)); 162 Tcl_SetHashValue(entryPtr, (ClientData)markPtr); 163 } else { 164 markPtr = (RpRusageStats*)Tcl_GetHashValue(entryPtr); 165 } 166 167 return RpRusageCapture(interp, markPtr); 137 168 } 138 169 … … 145 176 * the following syntax: 146 177 * 147 * rusage measure 178 * rusage measure ?name? 148 179 * 149 180 * Returns TCL_OK on success, and TCL_ERROR (along with an error … … 158 189 Tcl_Obj *const *objv; /* strings for command line args */ 159 190 { 191 char *markName; 192 Tcl_HashTable *markNamesPtr; 193 Tcl_HashEntry *entryPtr; 194 RpRusageStats *markPtr; 160 195 double tval; 161 196 RpRusageStats curstats; 162 char buffer[TCL_DOUBLE_SPACE];197 Tcl_Obj *listObjPtr, *objPtr; 163 198 164 199 if (RpRusageCapture(interp, &curstats) != TCL_OK) { … … 166 201 } 167 202 203 markNamesPtr = (Tcl_HashTable *) 204 Tcl_GetAssocData(interp, "RpRusageMarks", NULL); 205 206 markName = (objc > 2) ? Tcl_GetString(objv[2]): "global"; 207 entryPtr = Tcl_FindHashEntry(markNamesPtr, markName); 208 if (entryPtr == NULL) { 209 Tcl_AppendResult(interp, "mark \"", markName, 210 "\" doesn't exist", NULL); 211 return TCL_ERROR; 212 } 213 markPtr = (RpRusageStats*)Tcl_GetHashValue(entryPtr); 214 215 listObjPtr = Tcl_NewListObj(0, (Tcl_Obj **)NULL); 168 216 /* 169 217 * Compute: START TIME 170 218 */ 171 Tcl_AppendElement(interp, "start"); 172 tval = RpRusageTimeDiff(&RpRusage_MarkStats.times, &RpRusage_Start.times); 173 Tcl_PrintDouble(interp, tval, buffer); 174 Tcl_AppendElement(interp, buffer); 219 objPtr = Tcl_NewStringObj("start", 5); 220 Tcl_ListObjAppendElement(interp, listObjPtr, objPtr); 221 tval = RpRusageTimeDiff(&markPtr->times, &RpRusage_Start.times); 222 objPtr = Tcl_NewDoubleObj(tval); 223 Tcl_ListObjAppendElement(interp, listObjPtr, objPtr); 175 224 176 225 /* 177 226 * Compute: WALL TIME 178 227 */ 179 Tcl_AppendElement(interp, "walltime"); 180 tval = RpRusageTimeDiff(&curstats.times, &RpRusage_MarkStats.times); 181 Tcl_PrintDouble(interp, tval, buffer); 182 Tcl_AppendElement(interp, buffer); 228 objPtr = Tcl_NewStringObj("walltime", 8); 229 Tcl_ListObjAppendElement(interp, listObjPtr, objPtr); 230 tval = RpRusageTimeDiff(&curstats.times, &markPtr->times); 231 objPtr = Tcl_NewDoubleObj(tval); 232 Tcl_ListObjAppendElement(interp, listObjPtr, objPtr); 233 183 234 184 235 /* 185 236 * Compute: CPU TIME = user time + system time 186 237 */ 187 Tcl_AppendElement(interp, "cputime"); 238 objPtr = Tcl_NewStringObj("cputime", 7); 239 Tcl_ListObjAppendElement(interp, listObjPtr, objPtr); 188 240 tval = RpRusageTimeDiff(&curstats.resources.ru_utime, 189 & RpRusage_MarkStats.resources.ru_utime)241 &markPtr->resources.ru_utime) 190 242 + RpRusageTimeDiff(&curstats.resources.ru_stime, 191 &RpRusage_MarkStats.resources.ru_stime); 192 Tcl_PrintDouble(interp, tval, buffer); 193 Tcl_AppendElement(interp, buffer); 194 243 &markPtr->resources.ru_stime); 244 objPtr = Tcl_NewDoubleObj(tval); 245 Tcl_ListObjAppendElement(interp, listObjPtr, objPtr); 246 Tcl_SetObjResult(interp, listObjPtr); 247 return TCL_OK; 248 } 249 250 /* 251 * ------------------------------------------------------------------------ 252 * RpRusageForgetOp() 253 * 254 * Invoked whenever someone uses the "rusage forget" command to release 255 * information previous set by "rusage mark". With no args, it releases 256 * all known marks; otherwise, it releases just the specified mark 257 * names. This isn't usually needed, but if a program creates thousands 258 * of marks, this gives a way to avoid a huge memory leak. 259 * Handles the following syntax: 260 * 261 * rusage forget ?name name...? 262 * 263 * Returns TCL_OK on success, and TCL_ERROR (along with an error 264 * message in the interpreter) if anything goes wrong. 265 * ------------------------------------------------------------------------ 266 */ 267 static int 268 RpRusageForgetOp(cdata, interp, objc, objv) 269 ClientData cdata; /* not used */ 270 Tcl_Interp *interp; /* interpreter handling this request */ 271 int objc; /* number of command line args */ 272 Tcl_Obj *const *objv; /* strings for command line args */ 273 { 274 int i; 275 char *markName; 276 Tcl_HashTable *markNamesPtr; 277 Tcl_HashEntry *entryPtr; 278 Tcl_HashSearch search; 279 280 markNamesPtr = (Tcl_HashTable *) 281 Tcl_GetAssocData(interp, "RpRusageMarks", NULL); 282 283 /* 284 * No args? Then clear all entries in the hash table. 285 */ 286 if (objc == 2) { 287 for (entryPtr = Tcl_FirstHashEntry(markNamesPtr, &search); 288 entryPtr != NULL; 289 entryPtr = Tcl_NextHashEntry(&search)) { 290 ckfree((char *)Tcl_GetHashValue(entryPtr)); 291 } 292 Tcl_DeleteHashTable(markNamesPtr); 293 Tcl_InitHashTable(markNamesPtr, TCL_STRING_KEYS); 294 } 295 296 /* 297 * Otherwise, delete only the specified marks. Be forgiving. 298 * If a mark isn't recognized, ignore it. 299 */ 300 else { 301 for (i=2; i < objc; i++) { 302 markName = Tcl_GetString(objv[i]); 303 entryPtr = Tcl_FindHashEntry(markNamesPtr, markName); 304 if (entryPtr) { 305 ckfree((char *)Tcl_GetHashValue(entryPtr)); 306 Tcl_DeleteHashEntry(entryPtr); 307 } 308 } 309 } 195 310 return TCL_OK; 196 311 } … … 256 371 } 257 372 373 /* 374 * ------------------------------------------------------------------------ 375 * RpDestroyMarkNames() 376 * 377 * Used internally to clean up the marker names when the interpreter 378 * that owns them is being destroyed. 379 * ------------------------------------------------------------------------ 380 */ 381 static void 382 RpDestroyMarkNames(cdata, interp) 383 ClientData cdata; /* data being destroyed */ 384 Tcl_Interp *interp; /* interpreter that owned the data */ 385 { 386 Tcl_HashTable *markNamesPtr; 387 Tcl_HashEntry *entryPtr; 388 Tcl_HashSearch search; 389 390 for (entryPtr=Tcl_FirstHashEntry(markNamesPtr, &search); 391 entryPtr != NULL; 392 entryPtr = Tcl_NextHashEntry(&search)) { 393 ckfree( (char*)Tcl_GetHashValue(entryPtr) ); 394 } 395 Tcl_DeleteHashTable(markNamesPtr); 396 ckfree((char*)markNamesPtr); 397 } -
branches/blt4/p2p/client.tcl
r1273 r2170 86 86 public method send {message} 87 87 public method address {} 88 89 protected method handlerType {}90 88 } 91 89 … … 101 99 set _sid "" 102 100 } else { 103 log debug " sending: $message"101 log debug "outgoing message to [address]: $message" 104 102 puts $_sid $message 105 103 } … … 116 114 return $_addr 117 115 } 118 119 # ----------------------------------------------------------------------120 # USAGE: handlerType121 #122 # Returns a descriptive string describing this handler. Derived123 # classes override this method to provide their own string. Used124 # for debug messages.125 # ----------------------------------------------------------------------126 itcl::body Client::handlerType {} {127 return "client"128 } -
branches/blt4/p2p/foreman.tcl
r1273 r2170 119 119 120 120 if {"" != [statedata authoritycnx]} { 121 [statedata authoritycnx] send "identity foreman" 121 122 [statedata authoritycnx] send "workers" 122 123 } else { … … 160 161 161 162 if {"" != [statedata workercnx]} { 163 [statedata workercnx] send "identity foreman" 162 164 [statedata workercnx] send "solicit -job [expr {rand()}]" 163 165 } else { -
branches/blt4/p2p/handler.tcl
r1273 r2170 59 59 protected method finalize {protocol} 60 60 protected method dropped {cid} 61 protected method handlerType {}62 61 } 63 62 … … 196 195 append mesg "exception: $result" 197 196 } 198 log debug " [handlerType]message from [connectionName $cid]: [string trimright $request \n] $mesg"197 log debug "incoming message from [connectionName $cid]: [string trimright $request \n] $mesg" 199 198 } 200 199 } … … 237 236 catch {unset _cname($cid)} 238 237 } 239 240 # ----------------------------------------------------------------------241 # USAGE: handlerType242 #243 # Returns a descriptive string describing this handler. Derived244 # classes override this method to provide their own string. Used245 # for debug messages.246 # ----------------------------------------------------------------------247 itcl::body Handler::handlerType {} {248 return "handler"249 } -
branches/blt4/p2p/protocols.tcl
r1273 r2170 81 81 $obj protocol $name 82 82 $obj define $name exception {message} { 83 log error "ERROR from client: $message" 83 variable cid 84 variable handler 85 log error "ERROR from client [$handler connectionName $cid]: $message" 86 } 87 $obj define $name identity {name} { 88 variable cid 89 variable handler 90 $handler connectionName $cid $name 91 return "" 84 92 } 85 93 -
branches/blt4/p2p/server.tcl
r1273 r2170 106 106 107 107 protected method dropped {cid} 108 protected method handlerType {}109 110 108 private method accept {cid addr port} 111 109 } … … 235 233 chain $cid 236 234 } 237 238 # ----------------------------------------------------------------------239 # USAGE: handlerType240 #241 # Returns a descriptive string describing this handler. Derived242 # classes override this method to provide their own string. Used243 # for debug messages.244 # ----------------------------------------------------------------------245 itcl::body Server::handlerType {} {246 return "server"247 } -
branches/blt4/p2p/test.tcl
r1273 r2170 142 142 # ------------------------------------------------------------------ 143 143 public proc draw {canvas time} { 144 global times 144 145 if {[info exists _shapesOnCanvas($canvas)]} { 146 set y0 5 147 if {[info exists times($time)]} { 148 $canvas create text 5 $y0 -anchor nw -text $times($time) 149 incr y0 15 150 } 151 $canvas create text 5 $y0 -anchor nw -tags entity 152 145 153 foreach obj $_shapesOnCanvas($canvas) { 146 154 if {[$obj exists $time]} { … … 222 230 pack .player.fwd -side left -padx 4 -pady 2 223 231 232 button .player.err -text "0 errors" -command {wm deiconify .errors; raise .errors} 233 pack .player.err -side right -padx 4 -pady 2 234 .player.err configure -state disabled 235 224 236 scale .player.scale -label "Frame" -orient horizontal \ 225 237 -from 0 -to 1 -showvalue 0 -command {test_frame_go 1} … … 242 254 after idle .view.traffic invoke 243 255 256 toplevel .errors 257 wm title .errors "Error Messages" 258 wm withdraw .errors 259 wm protocol .errors WM_DELETE_WINDOW {wm withdraw .errors} 260 scrollbar .errors.ysbar -orient vertical -command {.errors.info yview} 261 pack .errors.ysbar -side right -fill y 262 text .errors.info -yscrollcommand {.errors.ysbar set} -font {Courier 12} 263 pack .errors.info -expand yes -fill both 264 .errors.info tag configure timecode -foreground gray 265 .errors.info tag configure error -foreground red -font {Courier 12 bold} 266 244 267 proc test_stop {} { 245 268 global processes … … 279 302 280 303 proc test_reload {} { 281 global time0 nodes actions nodeRadius304 global time0 nodes actions times nodeRadius 282 305 283 306 array set colors { 284 307 authority blue 285 308 worker gray 309 foreman red 286 310 } 287 311 288 312 Shape::clear .diagram.network 289 313 Shape::clear .diagram.traffic 314 .errors.info configure -state normal 315 .errors.info delete 1.0 end 290 316 set tmax 0 317 set errs 0 291 318 292 319 # … … 298 325 close $fid 299 326 300 if {[regexp -- {foreman<-} $info]} { 301 # skip log file from foreman 327 set lasttime "" 328 set t0val ""; set first "" 329 set t1val ""; set last "" 330 set info [split $info \n] 331 foreach line $info { 332 if {[regexp {^([0-9]+/[0-9]+/[0-9]+ [0-9]+:[0-9]+:[0-9]+)} $line match tval]} { 333 if {"" == $t0val} { 334 set first $line 335 set t0val [expr {([clock scan $tval]-$time0)*100}] 336 } else { 337 set last $line 338 set t1val [expr {([clock scan $tval]-$time0)*100 + 99}] 339 } 340 } 341 } 342 343 if {"" == $t0val || "" == $t1val} { 344 # can't find any log statements -- skip this file! 302 345 continue 303 346 } 304 347 305 348 # get the address for this host 306 regexp {started at port ([0-9]+)} $info match port 307 if {[regexp {options [^\n]+ ip ([^ ]+)} $info match ip]} { 308 set addr $ip:$port 349 if {[regexp {started at port ([0-9]+)} $info match port]} { 350 if {[regexp {options [^\n]+ ip ([^ ]+)} $info match ip]} { 351 set addr $ip:$port 352 } else { 353 set addr 127.0.0.1:$port 354 } 355 set shape oval 356 regexp {^([0-9]+/[0-9]+/[0-9]+ [0-9]+:[0-9]+:[0-9]+) +(authority|worker)} $first match t0 type 357 } elseif {[regexp -- {foreman<-} $info]} { 358 set shape rectangle 359 set addr "foreman" 360 set type "foreman" 309 361 } else { 310 set addr 127.0.0.1:$port 311 } 312 313 set lasttime "" 314 set info [split $info \n] 315 set first [lindex $info 0] 316 regexp {^([0-9]+/[0-9]+/[0-9]+ [0-9]+:[0-9]+:[0-9]+) +(authority|worker)} $first match t0 type 317 set t0val [expr {([clock scan $t0]-$time0)*100}] 318 319 set last [lindex $info end-1] 320 regexp {^([0-9]+/[0-9]+/[0-9]+ [0-9]+:[0-9]+:[0-9]+)} $last match t1 321 set t1val [expr {([clock scan $t1]-$time0)*100 + 99}] 362 # unknown log file -- skip it 363 continue 364 } 322 365 set margin 20 323 366 set r $nodeRadius … … 337 380 foreach canv {.diagram.traffic .diagram.network} { 338 381 set s [Shape ::#auto $canv -command \ 339 [list %c create oval[expr {$x-$r}] [expr {$y-$r}] \382 [list %c create $shape [expr {$x-$r}] [expr {$y-$r}] \ 340 383 [expr {$x+$r}] [expr {$y+$r}] \ 341 384 -outline black -fill $colors($type) \ … … 359 402 puts "\nscanning $fname" 360 403 361 if {[regexp -- {foreman<-} $info]} {362 # skip log file from foreman363 continue364 }365 366 404 catch {unset started} 367 405 set peerlist(addrs) "" … … 380 418 if {$tval > $tmax} { set tmax $tval } 381 419 420 set cid "" 382 421 if {[regexp {accepted: +([^ ]+) +\((.+)\)} $mesg match addr cid]} { 383 422 append actions($tval) $mesg \n … … 386 425 387 426 } elseif {[regexp {dropped: +([^ ]+) +\((.+)\)} $mesg match addr cid] && [info exists started(connect$cid-time)]} { 427 incr tval 99 ;# end of this second 388 428 append actions($tval) $mesg \n 389 429 set from $nodes($fname) … … 399 439 unset started(connect$cid-addr) 400 440 401 } elseif {[regexp {(server|client) message from ([a-zA-Z0-9\.]+:[0-9]+) \(([a-z0-9]+)\): +(.+) => (.*)} $mesg match which addr cid cmd result]} { 402 if {![string match identity* $cmd]} { 403 append actions($tval) $mesg \n 404 set from $nodes($fname) 405 set x0 $nodes($from-x) 406 set y0 $nodes($from-y) 407 set x1 $nodes($addr-x) 408 set y1 $nodes($addr-y) 409 set w [expr {[winfo width .diagram]/2}] 410 411 set s [Shape ::#auto .diagram.traffic -command \ 412 [list %c create line [expr $x0-3] [expr $y0-3] [expr $x1-3] [expr $y1-3] -fill black -arrow first -tags transient]] 413 $s addRange $tval $tval 414 415 set s [Shape ::#auto .diagram.traffic -command \ 416 [list %c create text [expr {0.5*($x0+$x1)}] [expr {0.5*($y0+$y1)-1}] -width $w -fill black -anchor s -text $cmd -tags transient]] 417 $s addRange $tval $tval 418 419 if {"" != [string trim $result]} { 420 if {[regexp {^ok:} $result]} { 421 set color black 422 } else { 423 set color red 424 } 425 set s [Shape ::#auto .diagram.traffic -command \ 426 [list %c create line [expr $x0+3] [expr $y0+3] [expr $x1+3] [expr $y1+3] -fill $color -arrow last -tags transient]] 427 $s addRange $tval $tval 428 429 set s [Shape ::#auto .diagram.traffic -command \ 430 [list %c create text [expr {0.5*($x0+$x1)}] [expr {0.5*($y0+$y1)+1}] -width $w -fill $color -anchor n -text $result -tags transient]] 431 $s addRange $tval $tval 441 } elseif {[regexp {(incoming) message from ([^ ]+) \((sock[0-9]+)\): +(.+) => (.*)} $mesg match which addr cid cmd result] 442 || [regexp {(outgoing) message to ([^ ]+): +(.+)} $mesg match which addr cmd]} { 443 switch -- $which { 444 outgoing { 445 set from $addr 446 set to $nodes($fname) 447 } 448 incoming { 449 set from $nodes($fname) 450 set to $addr 451 # show incoming messages later in time 452 incr tval 50 432 453 } 433 454 } 455 append actions($tval) $mesg \n 456 set x0 $nodes($from-x) 457 set y0 $nodes($from-y) 458 set x1 $nodes($to-x) 459 set y1 $nodes($to-y) 460 set w [expr {[winfo width .diagram]/2}] 461 462 set s [Shape ::#auto .diagram.traffic -command \ 463 [list %c create line [expr $x0-3] [expr $y0-3] [expr $x1-3] [expr $y1-3] -fill black -arrow first -tags transient]] 464 $s addRange $tval $tval 465 466 set s [Shape ::#auto .diagram.traffic -command \ 467 [list %c create text [expr {0.5*($x0+$x1)}] [expr {0.5*($y0+$y1)-1}] -width $w -fill black -anchor s -text $cmd -tags transient]] 468 $s addRange $tval $tval 469 470 if {$which == "incoming" && "" != [string trim $result]} { 471 if {[regexp {^ok:} $result]} { 472 set color black 473 } else { 474 set color red 475 } 476 set s [Shape ::#auto .diagram.traffic -command \ 477 [list %c create line [expr $x0+3] [expr $y0+3] [expr $x1+3] [expr $y1+3] -fill $color -arrow last -tags transient]] 478 $s addRange $tval $tval 479 480 set s [Shape ::#auto .diagram.traffic -command \ 481 [list %c create text [expr {0.5*($x0+$x1)}] [expr {0.5*($y0+$y1)+1}] -width $w -fill $color -anchor n -text $result -tags transient]] 482 $s addRange $tval $tval 483 } 434 484 435 485 # no address for this client yet? then save this info 436 if {[info exists started(connect$cid-addr)] 486 if {"" != $cid 487 && [info exists started(connect$cid-addr)] 437 488 && $started(connect$cid-addr) == "?"} { 438 489 set started(connect$cid-addr) $addr … … 466 517 set peerlist(addrs) $plist 467 518 set peerlist(time) $tval 519 } elseif {[regexp {ERROR} $mesg match addr]} { 520 .errors.info insert end $time timecode $mesg error "\n" 521 incr errs 468 522 } 523 set times($tval) $time 469 524 } 470 525 } … … 497 552 %W itemconfigure $fname-cnx -fill red 498 553 %W raise $fname-cnx 554 %W itemconfigure entity -text {$nodes($fname)} 499 555 " 500 556 .diagram.traffic bind $fname <Leave> " … … 502 558 %W itemconfigure $fname-cnx -fill gray 503 559 %W raise transient 560 %W itemconfigure entity -text {} 504 561 " 505 562 … … 537 594 } 538 595 .player.scale configure -to $tmax 596 .errors.info configure -state disabled 597 if {$errs == 0} { 598 .player.err configure -state normal -text "0 errors" 599 .player.err configure -state disabled 600 } else { 601 .player.err configure -state normal -text "$errs error[expr {($errs == 1) ? {} : {s}}]" 602 } 539 603 540 604 after cancel test_visualize … … 565 629 566 630 proc test_frame_go {dir position} { 567 global actions 631 global actions times 568 632 569 633 set tmax [.player.scale cget -to] -
branches/blt4/p2p/worker.tcl
r1273 r2170 118 118 # ------------------------------------------------------------------ 119 119 define solicit {args} { 120 log debug "SOLICIT from foreman: $args"121 120 variable cid 122 121 log debug "solicitation request from foreman: $args" … … 161 160 # ------------------------------------------------------------------ 162 161 define solicit {args} { 163 log debug "SOLICIT from peer: $args"164 162 variable cid 165 163 log debug "solicitation request from peer: $args" … … 177 175 # ------------------------------------------------------------------ 178 176 define proffer {token details} { 179 log debug "PROFFER from peer: $token $details"180 177 Solicitation::proffer $token $details 181 178 return "" … … 226 223 # ------------------------------------------------------------------ 227 224 define solicit {args} { 228 log debug "SOLICIT from peer: $args"229 225 variable cid 230 226 log debug "solicitation request from peer: $args" … … 242 238 # ------------------------------------------------------------------ 243 239 define proffer {token details} { 244 log debug "PROFFER from peer: $token $details"245 240 Solicitation::proffer $token $details 246 241 return "" … … 636 631 set mesg [list solicit -job $job -path $path -avoid "$avoid @RECIPIENTS" -token $_serial] 637 632 set _waitfor [broadcast_to_peers $mesg $avoid] 638 log debug "WAIT FOR: $_waitfor"639 633 640 634 if {$_waitfor > 0} { … … 643 637 } 644 638 } 645 log debug "TIMEOUT: $delay"646 639 set _timeout [after $delay [itcl::code $this finalize]] 647 640 } … … 656 649 append _response $details "\n" 657 650 if {[incr _waitfor -1] <= 0} { 658 log debug "ALL RESPONSES"659 651 finalize 660 652 } … … 676 668 # add details about this client to the message 677 669 append block "$myaddress -job $job -cost 1 -wonks [p2p::wonks::current]" 678 log debug "FINALIZE {$block}"679 670 680 671 # send the composite results back to the caller -
branches/blt4/packages/vizservers/configure.in
r2120 r2170 315 315 LD_RPATH="$loader_run_path:${CG_DIR}/lib" 316 316 fi 317 AC_SUBST(LIBS) 317 318 318 AC_SUBST(CG_DIR) 319 319 AC_MSG_RESULT([${CG_DIR}]) -
branches/blt4/packages/vizservers/vtkvis/CmdProc.cpp
r2120 r2170 22 22 */ 23 23 static int 24 BinaryOpSearch( 25 Rappture::CmdSpec *specs, 26 int nSpecs, 27 char *string) /* Name of minor operation to search for */ 24 BinaryOpSearch(Rappture::CmdSpec *specs, 25 int nSpecs, 26 char *string) /* Name of minor operation to search for */ 28 27 { 29 28 char c; … … 77 76 */ 78 77 static int 79 LinearOpSearch( 80 Rappture::CmdSpec *specs, 81 int nSpecs, 82 char *string) /* Name of minor operation to search for */ 78 LinearOpSearch(Rappture::CmdSpec *specs, 79 int nSpecs, 80 char *string) /* Name of minor operation to search for */ 83 81 { 84 82 Rappture::CmdSpec *specPtr; … … 93 91 last = -1; 94 92 for (specPtr = specs, i = 0; i < nSpecs; i++, specPtr++) { 95 if ((c == specPtr->name[0]) &&96 (strncmp(string, specPtr->name, length) == 0)) {97 last = i;98 nMatches++;99 if ((int)length == specPtr->minChars) {100 break;101 }102 }93 if ((c == specPtr->name[0]) && 94 (strncmp(string, specPtr->name, length) == 0)) { 95 last = i; 96 nMatches++; 97 if ((int)length == specPtr->minChars) { 98 break; 99 } 100 } 103 101 } 104 102 if (nMatches > 1) { 105 return -2; /* Ambiguous operation name */103 return -2; /* Ambiguous operation name */ 106 104 } 107 105 if (nMatches == 0) { 108 return -1; /* Can't find operation */106 return -1; /* Can't find operation */ 109 107 } 110 108 return last; /* Op found. */ … … 122 120 */ 123 121 Tcl_ObjCmdProc * 124 Rappture::GetOpFromObj( 125 Tcl_Interp *interp, /* Interpreter to report errors to */ 126 int nSpecs, /* Number of specifications in array */ 127 Rappture::CmdSpec *specs, /* Op specification array */ 128 int operPos, /* Position of operation in argument 129 * list. */ 130 int objc, /* Number of arguments in the argument 131 * vector. This includes any prefixed 132 * arguments */ 133 Tcl_Obj *const *objv, /* Argument vector */ 134 int flags) 122 Rappture::GetOpFromObj(Tcl_Interp *interp, /* Interpreter to report errors to */ 123 int nSpecs, /* Number of specifications in array */ 124 Rappture::CmdSpec *specs, /* Op specification array */ 125 int operPos, /* Position of operation in argument 126 * list. */ 127 int objc, /* Number of arguments in the argument 128 * vector. This includes any prefixed 129 * arguments */ 130 Tcl_Obj *const *objv, /* Argument vector */ 131 int flags) 135 132 { 136 133 CmdSpec *specPtr; … … 139 136 140 137 if (objc <= operPos) { /* No operation argument */ 141 Tcl_AppendResult(interp, "wrong # args: ", (char *)NULL);142 143 Tcl_AppendResult(interp, "should be one of...", (char *)NULL);144 for (n = 0; n < nSpecs; n++) {145 int i;146 147 Tcl_AppendResult(interp, "\n ", (char *)NULL);148 for (i = 0; i < operPos; i++) {149 Tcl_AppendResult(interp, Tcl_GetString(objv[i]), " ",150 (char *)NULL);151 }152 specPtr = specs + n;153 Tcl_AppendResult(interp, specPtr->name, " ", specPtr->usage,154 (char *)NULL);155 }156 return NULL;138 Tcl_AppendResult(interp, "wrong # args: ", (char *)NULL); 139 usage: 140 Tcl_AppendResult(interp, "should be one of...", (char *)NULL); 141 for (n = 0; n < nSpecs; n++) { 142 int i; 143 144 Tcl_AppendResult(interp, "\n ", (char *)NULL); 145 for (i = 0; i < operPos; i++) { 146 Tcl_AppendResult(interp, Tcl_GetString(objv[i]), " ", 147 (char *)NULL); 148 } 149 specPtr = specs + n; 150 Tcl_AppendResult(interp, specPtr->name, " ", specPtr->usage, 151 (char *)NULL); 152 } 153 return NULL; 157 154 } 158 155 string = Tcl_GetString(objv[operPos]); 159 156 if (flags & CMDSPEC_LINEAR_SEARCH) { 160 n = LinearOpSearch(specs, nSpecs, string);157 n = LinearOpSearch(specs, nSpecs, string); 161 158 } else { 162 n = BinaryOpSearch(specs, nSpecs, string);159 n = BinaryOpSearch(specs, nSpecs, string); 163 160 } 164 161 if (n == -2) { 165 char c;166 size_t length;167 168 Tcl_AppendResult(interp, "ambiguous", (char *)NULL);169 if (operPos > 2) {170 Tcl_AppendResult(interp, " ", Tcl_GetString(objv[operPos - 1]),171 (char *)NULL);172 }173 Tcl_AppendResult(interp, " operation \"", string, "\" matches: ",174 (char *)NULL);175 176 c = string[0];177 length = strlen(string);178 for (n = 0; n < nSpecs; n++) {179 specPtr = specs + n;180 if ((c == specPtr->name[0]) &&181 (strncmp(string, specPtr->name, length) == 0)) {182 Tcl_AppendResult(interp, " ", specPtr->name, (char *)NULL);183 }184 }185 return NULL;162 char c; 163 size_t length; 164 165 Tcl_AppendResult(interp, "ambiguous", (char *)NULL); 166 if (operPos > 2) { 167 Tcl_AppendResult(interp, " ", Tcl_GetString(objv[operPos - 1]), 168 (char *)NULL); 169 } 170 Tcl_AppendResult(interp, " operation \"", string, "\" matches: ", 171 (char *)NULL); 172 173 c = string[0]; 174 length = strlen(string); 175 for (n = 0; n < nSpecs; n++) { 176 specPtr = specs + n; 177 if ((c == specPtr->name[0]) && 178 (strncmp(string, specPtr->name, length) == 0)) { 179 Tcl_AppendResult(interp, " ", specPtr->name, (char *)NULL); 180 } 181 } 182 return NULL; 186 183 187 184 } else if (n == -1) { /* Can't find operation, display help */ 188 Tcl_AppendResult(interp, "bad", (char *)NULL);189 if (operPos > 2) {190 Tcl_AppendResult(interp, " ", Tcl_GetString(objv[operPos - 1]),191 (char *)NULL);192 }193 Tcl_AppendResult(interp, " operation \"", string, "\": ", (char *)NULL);194 goto usage;185 Tcl_AppendResult(interp, "bad", (char *)NULL); 186 if (operPos > 2) { 187 Tcl_AppendResult(interp, " ", Tcl_GetString(objv[operPos - 1]), 188 (char *)NULL); 189 } 190 Tcl_AppendResult(interp, " operation \"", string, "\": ", (char *)NULL); 191 goto usage; 195 192 } 196 193 specPtr = specs + n; 197 194 if ((objc < specPtr->minArgs) || 198 ((specPtr->maxArgs > 0) && (objc > specPtr->maxArgs))) {199 int i;200 201 Tcl_AppendResult(interp, "wrong # args: should be \"", (char *)NULL);202 for (i = 0; i < operPos; i++) {203 Tcl_AppendResult(interp, Tcl_GetString(objv[i]), " ",204 (char *)NULL);205 }206 Tcl_AppendResult(interp, specPtr->name, " ", specPtr->usage, "\"",207 (char *)NULL);208 return NULL;195 ((specPtr->maxArgs > 0) && (objc > specPtr->maxArgs))) { 196 int i; 197 198 Tcl_AppendResult(interp, "wrong # args: should be \"", (char *)NULL); 199 for (i = 0; i < operPos; i++) { 200 Tcl_AppendResult(interp, Tcl_GetString(objv[i]), " ", 201 (char *)NULL); 202 } 203 Tcl_AppendResult(interp, specPtr->name, " ", specPtr->usage, "\"", 204 (char *)NULL); 205 return NULL; 209 206 } 210 207 return specPtr->proc; -
branches/blt4/packages/vizservers/vtkvis/CmdProc.h
r2120 r2170 20 20 */ 21 21 typedef struct { 22 const char *name; /* Name of operation */23 int minChars; /* Minimum # characters to disambiguate */22 const char *name; /**< Name of operation */ 23 int minChars; /**< Minimum # characters to disambiguate */ 24 24 Tcl_ObjCmdProc *proc; 25 int minArgs; /* Minimum # args required */26 int maxArgs; /* Maximum # args required */27 const char *usage; /* Usage message */25 int minArgs; /**< Minimum # args required */ 26 int maxArgs; /**< Maximum # args required */ 27 const char *usage; /**< Usage message */ 28 28 } CmdSpec; 29 29 30 30 typedef enum { 31 CMDSPEC_ARG0, /* Op is the first argument. */32 CMDSPEC_ARG1, /* Op is the second argument. */33 CMDSPEC_ARG2, /* Op is the third argument. */34 CMDSPEC_ARG3, /* Op is the fourth argument. */35 CMDSPEC_ARG4 /* Op is the fifth argument. */31 CMDSPEC_ARG0, /**< Op is the first argument. */ 32 CMDSPEC_ARG1, /**< Op is the second argument. */ 33 CMDSPEC_ARG2, /**< Op is the third argument. */ 34 CMDSPEC_ARG3, /**< Op is the fourth argument. */ 35 CMDSPEC_ARG4 /**< Op is the fifth argument. */ 36 36 } CmdSpecIndex; 37 37 -
branches/blt4/packages/vizservers/vtkvis/RpContour2D.cpp
r2120 r2170 11 11 12 12 #include "RpContour2D.h" 13 #include "Trace.h" 13 14 14 15 using namespace Rappture::VtkVis; … … 27 28 Contour2D::~Contour2D() 28 29 { 30 #ifdef WANT_TRACE 31 if (_dataSet != NULL) 32 TRACE("Deleting Contour2D for %s", _dataSet->getName().c_str()); 33 else 34 TRACE("Deleting Contour2D with NULL DataSet"); 35 #endif 29 36 } 30 37 … … 38 45 update(); 39 46 } 47 } 48 49 /** 50 * \brief Returns the DataSet this Contour2D renders 51 */ 52 DataSet *Contour2D::getDataSet() 53 { 54 return _dataSet; 40 55 } 41 56 … … 59 74 _contourActor->GetProperty()->SetLineWidth(_edgeWidth); 60 75 _contourActor->GetProperty()->SetOpacity(_opacity); 76 _contourActor->GetProperty()->LightingOff(); 61 77 } 62 78 } … … 76 92 vtkSmartPointer<vtkContourFilter> contourFilter = vtkSmartPointer<vtkContourFilter>::New(); 77 93 contourFilter->SetInput(_dataSet->getVtkDataSet()); 94 95 contourFilter->ComputeNormalsOff(); 96 contourFilter->ComputeGradientsOff(); 78 97 79 98 // Speed up multiple contour computation at cost of extra memory use … … 193 212 { 194 213 if (_contourMapper != NULL) { 195 if (planes == NULL) 196 _contourMapper->RemoveAllClippingPlanes(); 197 else 198 _contourMapper->SetClippingPlanes(planes); 214 _contourMapper->SetClippingPlanes(planes); 199 215 } 200 216 } -
branches/blt4/packages/vizservers/vtkvis/RpContour2D.h
r2120 r2170 30 30 31 31 void setDataSet(DataSet *dataset); 32 33 DataSet *getDataSet(); 32 34 33 35 vtkActor *getActor(); -
branches/blt4/packages/vizservers/vtkvis/RpPolyData.cpp
r2120 r2170 32 32 PolyData::~PolyData() 33 33 { 34 #ifdef WANT_TRACE 35 if (_dataSet != NULL) 36 TRACE("Deleting PolyData for %s", _dataSet->getName().c_str()); 37 else 38 TRACE("Deleting PolyData with NULL DataSet"); 39 #endif 34 40 } 35 41 … … 79 85 80 86 /** 87 * \brief Returns the DataSet this PolyData renders 88 */ 89 DataSet *PolyData::getDataSet() 90 { 91 return _dataSet; 92 } 93 94 /** 81 95 * \brief Internal method to re-compute contours after a state change 82 96 */ … … 201 215 { 202 216 if (_pdMapper != NULL) { 203 if (planes == NULL) 204 _pdMapper->RemoveAllClippingPlanes(); 205 else 206 _pdMapper->SetClippingPlanes(planes); 217 _pdMapper->SetClippingPlanes(planes); 207 218 } 208 219 } -
branches/blt4/packages/vizservers/vtkvis/RpPolyData.h
r2120 r2170 29 29 30 30 void setDataSet(DataSet *dataset); 31 32 DataSet *getDataSet(); 31 33 32 34 vtkActor *getActor(); -
branches/blt4/packages/vizservers/vtkvis/RpPseudoColor.cpp
r2120 r2170 29 29 PseudoColor::~PseudoColor() 30 30 { 31 #ifdef WANT_TRACE 32 if (_dataSet != NULL) 33 TRACE("Deleting PseudoColor for %s", _dataSet->getName().c_str()); 34 else 35 TRACE("Deleting PseudoColor with NULL DataSet"); 36 #endif 31 37 } 32 38 … … 40 46 _dataSet = dataSet; 41 47 update(); 48 } 49 50 /** 51 * \brief Returns the DataSet this PseudoColor renders 52 */ 53 DataSet *PseudoColor::getDataSet() 54 { 55 return _dataSet; 42 56 } 43 57 … … 81 95 _lut->SetRange(dataRange); 82 96 97 _dsMapper->UseLookupTableScalarRangeOn(); 83 98 _dsMapper->SetLookupTable(_lut); 84 _dsMapper->SetScalarRange(dataRange);85 //_dsMapper->GetLookupTable()->SetRange(dataRange);86 99 //_dsMapper->InterpolateScalarsBeforeMappingOn(); 87 100 88 101 initActor(); 89 102 _dsActor->SetMapper(_dsMapper); 90 //_dsActor->GetProperty()->SetRepresentationToWireframe();91 103 } 92 104 … … 149 161 } 150 162 if (_dsMapper != NULL) { 163 _dsMapper->UseLookupTableScalarRangeOn(); 151 164 _dsMapper->SetLookupTable(_lut); 152 if (_dataSet != NULL) {153 _dsMapper->SetScalarRange(dataRange);154 }155 165 } 156 166 } … … 230 240 { 231 241 if (_dsMapper != NULL) { 232 if (planes == NULL) 233 _dsMapper->RemoveAllClippingPlanes(); 234 else 235 _dsMapper->SetClippingPlanes(planes); 242 _dsMapper->SetClippingPlanes(planes); 236 243 } 237 244 } -
branches/blt4/packages/vizservers/vtkvis/RpPseudoColor.h
r2120 r2170 31 31 32 32 void setDataSet(DataSet *dataset); 33 34 DataSet *getDataSet(); 33 35 34 36 vtkActor *getActor(); -
branches/blt4/packages/vizservers/vtkvis/RpVtkDataSet.cpp
r2120 r2170 69 69 70 70 /** 71 * \brief Read dataset using supplied reader 72 */ 73 bool DataSet::setData(vtkDataSet *ds) 74 { 75 _dataSet = ds; 76 _dataSet->Update(); 77 _dataSet->GetScalarRange(_dataRange); 78 79 TRACE("Scalar Range: %.12e, %.12e", _dataRange[0], _dataRange[1]); 80 return true; 81 } 82 83 /** 71 84 * \brief Get the name/id of this dataset 72 85 */ … … 97 110 * 98 111 * Note: no interpolation is performed on data 112 * 113 * \return the value of the nearest point or 0 if no scalar data available 99 114 */ 100 115 double DataSet::getDataValue(double x, double y, double z) … … 102 117 if (_dataSet == NULL) 103 118 return 0; 119 if (_dataSet->GetPointData() == NULL || 120 _dataSet->GetPointData()->GetScalars() == NULL) { 121 return 0.0; 122 } 104 123 vtkIdType pt = _dataSet->FindPoint(x, y, z); 105 124 return _dataSet->GetPointData()->GetScalars()->GetComponent(pt, 0); -
branches/blt4/packages/vizservers/vtkvis/RpVtkDataSet.h
r2120 r2170 29 29 bool setData(char *data, int nbytes); 30 30 31 bool setData(vtkDataSet *ds); 32 33 bool setData(vtkDataSetReader *reader); 34 31 35 bool setDataFile(const char *filename); 32 36 … … 42 46 DataSet(); 43 47 44 bool setData(vtkDataSetReader *reader);45 46 48 std::string _name; 47 49 vtkSmartPointer<vtkDataSet> _dataSet; -
branches/blt4/packages/vizservers/vtkvis/RpVtkRenderer.cpp
r2120 r2170 30 30 31 31 #include "RpVtkRenderer.h" 32 #include "ColorMap.h" 32 33 #include "Trace.h" 33 34 … … 37 38 _needsRedraw(true), 38 39 _windowWidth(320), 39 _windowHeight(320) 40 _windowHeight(320), 41 _useCumulativeRanges(true) 40 42 { 41 43 _bgColor[0] = 0; 42 44 _bgColor[1] = 0; 43 45 _bgColor[2] = 0; 46 _cumulativeDataRange[0] = 0.0; 47 _cumulativeDataRange[1] = 1.0; 44 48 // clipping planes to prevent overdrawing axes 45 49 _clippingPlanes = vtkSmartPointer<vtkPlaneCollection>::New(); 46 50 // bottom 47 vtk Plane *plane0 = vtkPlane::New();51 vtkSmartPointer<vtkPlane> plane0 = vtkSmartPointer<vtkPlane>::New(); 48 52 plane0->SetNormal(0, 1, 0); 49 53 plane0->SetOrigin(0, 0, 0); 50 54 _clippingPlanes->AddItem(plane0); 51 55 // left 52 vtk Plane *plane1 = vtkPlane::New();56 vtkSmartPointer<vtkPlane> plane1 = vtkSmartPointer<vtkPlane>::New(); 53 57 plane1->SetNormal(1, 0, 0); 54 58 plane1->SetOrigin(0, 0, 0); 55 59 _clippingPlanes->AddItem(plane1); 56 60 // top 57 vtk Plane *plane2 = vtkPlane::New();61 vtkSmartPointer<vtkPlane> plane2 = vtkSmartPointer<vtkPlane>::New(); 58 62 plane2->SetNormal(0, -1, 0); 59 63 plane2->SetOrigin(0, 1, 0); 60 64 _clippingPlanes->AddItem(plane2); 61 65 // right 62 vtk Plane *plane3 = vtkPlane::New();66 vtkSmartPointer<vtkPlane> plane3 = vtkSmartPointer<vtkPlane>::New(); 63 67 plane3->SetNormal(-1, 0, 0); 64 68 plane3->SetOrigin(1, 0, 0); … … 86 90 } 87 91 _colorMaps.clear(); 88 for (DataSetHashmap::iterator itr = _dataSets.begin();89 itr != _dataSets.end(); ++itr) {90 delete itr->second;91 }92 _dataSets.clear();93 92 for (PseudoColorHashmap::iterator itr = _pseudoColors.begin(); 94 93 itr != _pseudoColors.end(); ++itr) { … … 106 105 } 107 106 _polyDatas.clear(); 107 for (DataSetHashmap::iterator itr = _dataSets.begin(); 108 itr != _dataSets.end(); ++itr) { 109 delete itr->second; 110 } 111 _dataSets.clear(); 108 112 } 109 113 … … 115 119 * be added to the Renderer. 116 120 */ 117 void Renderer::addDataSet( DataSetIdid)121 void Renderer::addDataSet(const DataSetId& id) 118 122 { 119 123 if (getDataSet(id) != NULL) { … … 129 133 * The underlying PseudoColor object is deleted, freeing its memory 130 134 */ 131 void Renderer::deletePseudoColor(DataSetId id) 132 { 133 PseudoColorHashmap::iterator itr = _pseudoColors.find(id); 135 void Renderer::deletePseudoColor(const DataSetId& id) 136 { 137 PseudoColorHashmap::iterator itr; 138 139 bool doAll = false; 140 141 if (id.compare("all") == 0) { 142 itr = _pseudoColors.begin(); 143 doAll = true; 144 } else { 145 itr = _pseudoColors.find(id); 146 } 134 147 if (itr == _pseudoColors.end()) { 135 148 ERROR("PseudoColor not found: %s", id.c_str()); … … 139 152 TRACE("Deleting PseudoColors for %s", id.c_str()); 140 153 141 PseudoColor *ps = itr->second; 142 if (ps->getActor()) 143 _renderer->RemoveActor(ps->getActor()); 144 delete ps; 145 146 _pseudoColors.erase(itr); 154 do { 155 PseudoColor *ps = itr->second; 156 if (ps->getActor()) 157 _renderer->RemoveActor(ps->getActor()); 158 delete ps; 159 160 _pseudoColors.erase(itr); 161 } while (doAll && ++itr != _pseudoColors.end()); 162 147 163 _needsRedraw = true; 148 164 } … … 153 169 * The underlying Contour2D is deleted, freeing its memory 154 170 */ 155 void Renderer::deleteContour2D(DataSetId id) 156 { 157 Contour2DHashmap::iterator itr = _contours.find(id); 171 void Renderer::deleteContour2D(const DataSetId& id) 172 { 173 Contour2DHashmap::iterator itr; 174 175 bool doAll = false; 176 177 if (id.compare("all") == 0) { 178 itr = _contours.begin(); 179 doAll = true; 180 } else { 181 itr = _contours.find(id); 182 } 158 183 if (itr == _contours.end()) { 159 184 ERROR("Contour2D not found: %s", id.c_str()); … … 163 188 TRACE("Deleting Contour2Ds for %s", id.c_str()); 164 189 165 Contour2D *contour = itr->second; 166 if (contour->getActor()) 167 _renderer->RemoveActor(contour->getActor()); 168 delete contour; 169 170 _contours.erase(itr); 190 do { 191 Contour2D *contour = itr->second; 192 if (contour->getActor()) 193 _renderer->RemoveActor(contour->getActor()); 194 delete contour; 195 196 _contours.erase(itr); 197 } while (doAll && ++itr != _contours.end()); 198 171 199 _needsRedraw = true; 172 200 } … … 177 205 * The underlying PolyData is deleted, freeing its memory 178 206 */ 179 void Renderer::deletePolyData(DataSetId id) 180 { 181 PolyDataHashmap::iterator itr = _polyDatas.find(id); 207 void Renderer::deletePolyData(const DataSetId& id) 208 { 209 PolyDataHashmap::iterator itr; 210 211 bool doAll = false; 212 213 if (id.compare("all") == 0) { 214 itr = _polyDatas.begin(); 215 doAll = true; 216 } else { 217 itr = _polyDatas.find(id); 218 } 182 219 if (itr == _polyDatas.end()) { 183 220 ERROR("PolyData not found: %s", id.c_str()); … … 187 224 TRACE("Deleting PolyDatas for %s", id.c_str()); 188 225 189 PolyData *polyData = itr->second; 190 if (polyData->getActor()) 191 _renderer->RemoveActor(polyData->getActor()); 192 delete polyData; 193 194 _polyDatas.erase(itr); 226 do { 227 PolyData *polyData = itr->second; 228 if (polyData->getActor()) 229 _renderer->RemoveActor(polyData->getActor()); 230 delete polyData; 231 232 _polyDatas.erase(itr); 233 } while (doAll && ++itr != _polyDatas.end()); 234 195 235 _needsRedraw = true; 196 236 } … … 202 242 * objects are deleted, freeing the memory used. 203 243 */ 204 void Renderer::deleteDataSet(DataSetId id) 205 { 206 DataSetHashmap::iterator itr = _dataSets.find(id); 244 void Renderer::deleteDataSet(const DataSetId& id) 245 { 246 DataSetHashmap::iterator itr; 247 248 bool doAll = false; 249 250 if (id.compare("all") == 0) { 251 itr = _dataSets.begin(); 252 doAll = true; 253 } else { 254 itr = _dataSets.find(id); 255 } 207 256 if (itr == _dataSets.end()) { 208 257 ERROR("Unknown dataset %s", id.c_str()); 209 258 return; 210 } else { 211 TRACE("Deleting dataset %s", id.c_str()); 212 213 deletePseudoColor(id); 214 deleteContour2D(id); 215 deletePolyData(id); 216 259 } 260 261 do { 262 TRACE("Deleting dataset %s", itr->second->getName().c_str()); 263 264 deletePseudoColor(itr->second->getName()); 265 deleteContour2D(itr->second->getName()); 266 deletePolyData(itr->second->getName()); 267 217 268 TRACE("After deleting graphics objects"); 269 270 // Update cumulative data range 271 collectDataRanges(_cumulativeDataRange); 218 272 219 273 delete itr->second; 220 274 _dataSets.erase(itr); 221 _needsRedraw = true; 222 } 275 } while (doAll && ++itr != _dataSets.end()); 276 277 _needsRedraw = true; 223 278 } 224 279 … … 228 283 * \return A pointer to the DataSet, or NULL if not found 229 284 */ 230 DataSet *Renderer::getDataSet( DataSetIdid)285 DataSet *Renderer::getDataSet(const DataSetId& id) 231 286 { 232 287 DataSetHashmap::iterator itr = _dataSets.find(id); … … 241 296 * \brief (Re-)load the data for the specified DataSet key from a file 242 297 */ 243 bool Renderer::setDataFile( DataSetIdid, const char *filename)298 bool Renderer::setDataFile(const DataSetId& id, const char *filename) 244 299 { 245 300 DataSet *ds = getDataSet(id); 246 301 if (ds) { 247 302 bool ret = ds->setDataFile(filename); 248 PseudoColor *ps = getPseudoColor(id); 249 if (ps) { 250 ps->setDataSet(ds); 251 } 303 collectDataRanges(_cumulativeDataRange); 304 updateRanges(_useCumulativeRanges); 252 305 _needsRedraw = true; 253 306 return ret; … … 259 312 * \brief (Re-)load the data for the specified DataSet key from a memory buffer 260 313 */ 261 bool Renderer::setData( DataSetIdid, char *data, int nbytes)314 bool Renderer::setData(const DataSetId& id, char *data, int nbytes) 262 315 { 263 316 DataSet *ds = getDataSet(id); 264 317 if (ds) { 318 bool ret = ds->setData(data, nbytes); 319 collectDataRanges(_cumulativeDataRange); 320 updateRanges(_useCumulativeRanges); 265 321 _needsRedraw = true; 266 return ds->setData(data, nbytes);322 return ret; 267 323 } else 268 324 return false; … … 521 577 * \brief Add a color map for use in the Renderer 522 578 */ 523 void Renderer::addColorMap( ColorMapIdid, ColorMap *colorMap)579 void Renderer::addColorMap(const ColorMapId& id, ColorMap *colorMap) 524 580 { 525 581 if (colorMap != NULL) { … … 538 594 * \brief Return the ColorMap associated with the colormap key given 539 595 */ 540 ColorMap *Renderer::getColorMap( ColorMapIdid)596 ColorMap *Renderer::getColorMap(const ColorMapId& id) 541 597 { 542 598 ColorMapHashmap::iterator itr = _colorMaps.find(id); … … 554 610 * by any other objects 555 611 */ 556 void Renderer::deleteColorMap(ColorMapId id) 557 { 558 ColorMapHashmap::iterator itr = _colorMaps.find(id); 559 if (itr == _colorMaps.end()) 560 return; 561 562 // TODO: Check if color map is used in PseudoColors? 563 delete itr->second; 564 _colorMaps.erase(itr); 612 void Renderer::deleteColorMap(const ColorMapId& id) 613 { 614 ColorMapHashmap::iterator itr; 615 616 bool doAll = false; 617 618 if (id.compare("all") == 0) { 619 itr = _colorMaps.begin(); 620 doAll = true; 621 } else { 622 itr = _colorMaps.find(id); 623 } 624 625 if (itr == _colorMaps.end()) { 626 ERROR("Unknown ColorMap %s", id.c_str()); 627 return; 628 } 629 630 do { 631 TRACE("Deleting ColorMap %s", itr->second->getName().c_str()); 632 633 // TODO: Check if color map is used in PseudoColors? 634 delete itr->second; 635 _colorMaps.erase(itr); 636 } while (doAll && ++itr != _colorMaps.end()); 565 637 } 566 638 … … 568 640 * \brief Render a labelled legend image for the given colormap 569 641 * 570 * \return The image is rendered into the supplied array 571 */ 572 void Renderer::renderColorMap(ColorMapId id, const char *title, 642 * \return The image is rendered into the supplied array, false is 643 * returned if the color map is not found 644 */ 645 bool Renderer::renderColorMap(const ColorMapId& id, 646 const DataSetId& dataSetID, 647 const char *title, 573 648 int width, int height, 574 649 vtkUnsignedCharArray *imgData) 575 650 { 651 ColorMap *colorMap = getColorMap(id); 652 if (colorMap == NULL) 653 return false; 654 576 655 if (_legendRenderWindow == NULL) { 577 656 _legendRenderWindow = vtkSmartPointer<vtkRenderWindow>::New(); … … 593 672 _legendRenderer->AddActor(_scalarBarActor); 594 673 } 595 _scalarBarActor->SetLookupTable(getColorMap(id)->getLookupTable()); 674 675 vtkSmartPointer<vtkLookupTable> lut = colorMap->getLookupTable(); 676 if (dataSetID.compare("all") == 0) { 677 lut->SetRange(_cumulativeDataRange); 678 } else { 679 DataSet *dataSet = getDataSet(dataSetID); 680 if (dataSet == NULL) { 681 lut->SetRange(_cumulativeDataRange); 682 } else { 683 double range[2]; 684 dataSet->getDataRange(range); 685 lut->SetRange(range); 686 } 687 } 688 _scalarBarActor->SetLookupTable(lut); 689 596 690 // Set viewport-relative width/height/pos 597 691 if (width > height) { … … 615 709 616 710 _legendRenderWindow->GetPixelData(0, 0, width-1, height-1, 1, imgData); 711 return true; 617 712 } 618 713 … … 620 715 * \brief Create a new PseudoColor rendering for the specified DataSet 621 716 */ 622 void Renderer::addPseudoColor(DataSetId id) 623 { 624 DataSet *ds = getDataSet(id); 625 if (ds == NULL) 626 return; 627 628 if (getPseudoColor(id)) { 629 WARN("Replacing existing pseudocolor %s", id.c_str()); 630 deletePseudoColor(id); 631 } 632 PseudoColor *pc = new PseudoColor(); 633 _pseudoColors[id] = pc; 634 635 pc->setDataSet(ds); 636 637 _renderer->AddActor(pc->getActor()); 717 void Renderer::addPseudoColor(const DataSetId& id) 718 { 719 DataSetHashmap::iterator itr; 720 721 bool doAll = false; 722 723 if (id.compare("all") == 0) { 724 itr = _dataSets.begin(); 725 } else { 726 itr = _dataSets.find(id); 727 } 728 if (itr == _dataSets.end()) { 729 ERROR("Unknown dataset %s", id.c_str()); 730 return; 731 } 732 733 do { 734 DataSet *ds = itr->second; 735 const DataSetId& dsID = ds->getName(); 736 737 if (getPseudoColor(dsID)) { 738 WARN("Replacing existing pseudocolor %s", dsID.c_str()); 739 deletePseudoColor(dsID); 740 } 741 PseudoColor *pc = new PseudoColor(); 742 _pseudoColors[dsID] = pc; 743 744 pc->setDataSet(ds); 745 746 _renderer->AddActor(pc->getActor()); 747 } while (doAll && ++itr != _dataSets.end()); 638 748 639 749 initCamera(); … … 644 754 * \brief Get the PseudoColor associated with the specified DataSet 645 755 */ 646 PseudoColor *Renderer::getPseudoColor( DataSetIdid)756 PseudoColor *Renderer::getPseudoColor(const DataSetId& id) 647 757 { 648 758 PseudoColorHashmap::iterator itr = _pseudoColors.find(id); … … 658 768 * \brief Associate an existing named color map with a DataSet 659 769 */ 660 void Renderer::setPseudoColorColorMap(DataSetId id, ColorMapId colorMapId) 661 { 662 PseudoColor *pc = getPseudoColor(id); 663 if (pc) { 664 ColorMap *cmap = getColorMap(colorMapId); 665 if (cmap) { 666 TRACE("Set color map: %s for dataset %s", colorMapId.c_str(), 667 id.c_str()); 668 pc->setLookupTable(cmap->getLookupTable()); 669 _needsRedraw = true; 670 } else { 671 ERROR("Unknown colormap: %s", colorMapId.c_str()); 672 } 673 } else { 674 ERROR("No pseudocolor for dataset %s", id.c_str()); 675 } 770 void Renderer::setPseudoColorColorMap(const DataSetId& id, const ColorMapId& colorMapId) 771 { 772 PseudoColorHashmap::iterator itr; 773 774 bool doAll = false; 775 776 if (id.compare("all") == 0) { 777 itr = _pseudoColors.begin(); 778 doAll = true; 779 } else { 780 itr = _pseudoColors.find(id); 781 } 782 783 if (itr == _pseudoColors.end()) { 784 ERROR("PseudoColor not found: %s", id.c_str()); 785 return; 786 } 787 788 ColorMap *cmap = getColorMap(colorMapId); 789 if (cmap == NULL) { 790 ERROR("Unknown colormap: %s", colorMapId.c_str()); 791 return; 792 } 793 794 do { 795 TRACE("Set color map: %s for dataset %s", colorMapId.c_str(), 796 itr->second->getDataSet()->getName().c_str()); 797 798 // Make a copy of the generic colormap lookup table, so 799 // data range can be set in the copy table to match the 800 // dataset being plotted 801 vtkSmartPointer<vtkLookupTable> lut = vtkSmartPointer<vtkLookupTable>::New(); 802 lut->DeepCopy(cmap->getLookupTable()); 803 804 itr->second->setLookupTable(lut); 805 } while (doAll && ++itr != _pseudoColors.end()); 806 807 _needsRedraw = true; 676 808 } 677 809 … … 681 813 * \return The associated lookup table or NULL if not found 682 814 */ 683 vtkLookupTable *Renderer::getPseudoColorColorMap( DataSetIdid)815 vtkLookupTable *Renderer::getPseudoColorColorMap(const DataSetId& id) 684 816 { 685 817 PseudoColor *pc = getPseudoColor(id); … … 691 823 692 824 /** 825 * \brief Set opacity of the PseudoColor for the given DataSet 826 */ 827 void Renderer::setPseudoColorOpacity(const DataSetId& id, double opacity) 828 { 829 PseudoColorHashmap::iterator itr; 830 831 bool doAll = false; 832 833 if (id.compare("all") == 0) { 834 itr = _pseudoColors.begin(); 835 doAll = true; 836 } else { 837 itr = _pseudoColors.find(id); 838 } 839 840 if (itr == _pseudoColors.end()) { 841 ERROR("PseudoColor not found: %s", id.c_str()); 842 return; 843 } 844 845 do { 846 itr->second->setOpacity(opacity); 847 } while (doAll && ++itr != _pseudoColors.end()); 848 849 _needsRedraw = true; 850 } 851 852 /** 693 853 * \brief Turn on/off rendering of the PseudoColor mapper for the given DataSet 694 854 */ 695 void Renderer::setPseudoColorVisibility(DataSetId id, bool state) 696 { 697 PseudoColor *pc = getPseudoColor(id); 698 if (pc) { 699 pc->setVisibility(state); 700 _needsRedraw = true; 701 } 855 void Renderer::setPseudoColorVisibility(const DataSetId& id, bool state) 856 { 857 PseudoColorHashmap::iterator itr; 858 859 bool doAll = false; 860 861 if (id.compare("all") == 0) { 862 itr = _pseudoColors.begin(); 863 doAll = true; 864 } else { 865 itr = _pseudoColors.find(id); 866 } 867 868 if (itr == _pseudoColors.end()) { 869 ERROR("PseudoColor not found: %s", id.c_str()); 870 return; 871 } 872 873 do { 874 itr->second->setVisibility(state); 875 } while (doAll && ++itr != _pseudoColors.end()); 876 877 _needsRedraw = true; 702 878 } 703 879 … … 705 881 * \brief Set the visibility of polygon edges for the specified DataSet 706 882 */ 707 void Renderer::setPseudoColorEdgeVisibility(DataSetId id, bool state) 708 { 709 PseudoColor *pc = getPseudoColor(id); 710 if (pc) { 711 pc->setEdgeVisibility(state); 712 _needsRedraw = true; 713 } 883 void Renderer::setPseudoColorEdgeVisibility(const DataSetId& id, bool state) 884 { 885 PseudoColorHashmap::iterator itr; 886 887 bool doAll = false; 888 889 if (id.compare("all") == 0) { 890 itr = _pseudoColors.begin(); 891 doAll = true; 892 } else { 893 itr = _pseudoColors.find(id); 894 } 895 896 if (itr == _pseudoColors.end()) { 897 ERROR("PseudoColor not found: %s", id.c_str()); 898 return; 899 } 900 901 do { 902 itr->second->setEdgeVisibility(state); 903 } while (doAll && ++itr != _pseudoColors.end()); 904 905 _needsRedraw = true; 714 906 } 715 907 … … 717 909 * \brief Set the RGB polygon edge color for the specified DataSet 718 910 */ 719 void Renderer::setPseudoColorEdgeColor(DataSetId id, float color[3]) 720 { 721 PseudoColor *pc = getPseudoColor(id); 722 if (pc) { 723 pc->setEdgeColor(color); 724 _needsRedraw = true; 725 } 911 void Renderer::setPseudoColorEdgeColor(const DataSetId& id, float color[3]) 912 { 913 PseudoColorHashmap::iterator itr; 914 915 bool doAll = false; 916 917 if (id.compare("all") == 0) { 918 itr = _pseudoColors.begin(); 919 doAll = true; 920 } else { 921 itr = _pseudoColors.find(id); 922 } 923 924 if (itr == _pseudoColors.end()) { 925 ERROR("PseudoColor not found: %s", id.c_str()); 926 return; 927 } 928 929 do { 930 itr->second->setEdgeColor(color); 931 } while (doAll && ++itr != _pseudoColors.end()); 932 933 _needsRedraw = true; 726 934 } 727 935 … … 732 940 * this function may not have an effect. 733 941 */ 734 void Renderer::setPseudoColorEdgeWidth(DataSetId id, float edgeWidth) 735 { 736 PseudoColor *pc = getPseudoColor(id); 737 if (pc) { 738 pc->setEdgeWidth(edgeWidth); 739 _needsRedraw = true; 740 } 942 void Renderer::setPseudoColorEdgeWidth(const DataSetId& id, float edgeWidth) 943 { 944 PseudoColorHashmap::iterator itr; 945 946 bool doAll = false; 947 948 if (id.compare("all") == 0) { 949 itr = _pseudoColors.begin(); 950 doAll = true; 951 } else { 952 itr = _pseudoColors.find(id); 953 } 954 955 if (itr == _pseudoColors.end()) { 956 ERROR("PseudoColor not found: %s", id.c_str()); 957 return; 958 } 959 960 do { 961 itr->second->setEdgeWidth(edgeWidth); 962 } while (doAll && ++itr != _pseudoColors.end()); 963 964 _needsRedraw = true; 741 965 } 742 966 … … 744 968 * \brief Turn mesh lighting on/off for the specified DataSet 745 969 */ 746 void Renderer::setPseudoColorLighting(DataSetId id, bool state) 747 { 748 PseudoColor *pc = getPseudoColor(id); 749 if (pc) { 750 pc->setLighting(state); 751 _needsRedraw = true; 752 } 970 void Renderer::setPseudoColorLighting(const DataSetId& id, bool state) 971 { 972 PseudoColorHashmap::iterator itr; 973 974 bool doAll = false; 975 976 if (id.compare("all") == 0) { 977 itr = _pseudoColors.begin(); 978 doAll = true; 979 } else { 980 itr = _pseudoColors.find(id); 981 } 982 983 if (itr == _pseudoColors.end()) { 984 ERROR("PseudoColor not found: %s", id.c_str()); 985 return; 986 } 987 988 do { 989 itr->second->setLighting(state); 990 } while (doAll && ++itr != _pseudoColors.end()); 991 992 _needsRedraw = true; 753 993 } 754 994 … … 756 996 * \brief Create a new Contour2D and associate it with the named DataSet 757 997 */ 758 void Renderer::addContour2D(DataSetId id) 759 { 760 DataSet *ds = getDataSet(id); 761 if (ds == NULL) 762 return; 763 764 if (getContour2D(id)) { 765 WARN("Replacing existing contour2d %s", id.c_str()); 766 deleteContour2D(id); 767 } 768 769 Contour2D *contour = new Contour2D(); 770 _contours[id] = contour; 771 772 contour->setDataSet(ds); 773 774 _renderer->AddActor(contour->getActor()); 998 void Renderer::addContour2D(const DataSetId& id) 999 { 1000 DataSetHashmap::iterator itr; 1001 1002 bool doAll = false; 1003 1004 if (id.compare("all") == 0) { 1005 itr = _dataSets.begin(); 1006 } else { 1007 itr = _dataSets.find(id); 1008 } 1009 if (itr == _dataSets.end()) { 1010 ERROR("Unknown dataset %s", id.c_str()); 1011 return; 1012 } 1013 1014 do { 1015 DataSet *ds = itr->second; 1016 const DataSetId& dsID = ds->getName(); 1017 1018 if (getContour2D(dsID)) { 1019 WARN("Replacing existing contour2d %s", dsID.c_str()); 1020 deleteContour2D(dsID); 1021 } 1022 1023 Contour2D *contour = new Contour2D(); 1024 _contours[dsID] = contour; 1025 1026 contour->setDataSet(ds); 1027 1028 _renderer->AddActor(contour->getActor()); 1029 } while (doAll && ++itr != _dataSets.end()); 775 1030 776 1031 initCamera(); … … 781 1036 * \brief Get the Contour2D associated with a named DataSet 782 1037 */ 783 Contour2D *Renderer::getContour2D( DataSetIdid)1038 Contour2D *Renderer::getContour2D(const DataSetId& id) 784 1039 { 785 1040 Contour2DHashmap::iterator itr = _contours.find(id); … … 795 1050 * \brief Set the number of equally spaced contour isolines for the given DataSet 796 1051 */ 797 void Renderer::setContours(DataSetId id, int numContours) 798 { 799 Contour2D *contour = getContour2D(id); 800 if (contour) { 801 contour->setContours(numContours); 802 _needsRedraw = true; 803 } 1052 void Renderer::setContours(const DataSetId& id, int numContours) 1053 { 1054 Contour2DHashmap::iterator itr; 1055 1056 bool doAll = false; 1057 1058 if (id.compare("all") == 0) { 1059 itr = _contours.begin(); 1060 doAll = true; 1061 } else { 1062 itr = _contours.find(id); 1063 } 1064 if (itr == _contours.end()) { 1065 ERROR("Contour2D not found: %s", id.c_str()); 1066 return; 1067 } 1068 1069 do { 1070 itr->second->setContours(numContours); 1071 } while (doAll && ++itr != _contours.end()); 1072 1073 _needsRedraw = true; 804 1074 } 805 1075 … … 807 1077 * \brief Set a list of isovalues for the given DataSet 808 1078 */ 809 void Renderer::setContourList(DataSetId id, const std::vector<double>& contours) 810 { 811 Contour2D *contour = getContour2D(id); 812 if (contour) { 813 contour->setContourList(contours); 814 _needsRedraw = true; 815 } 1079 void Renderer::setContourList(const DataSetId& id, const std::vector<double>& contours) 1080 { 1081 Contour2DHashmap::iterator itr; 1082 1083 bool doAll = false; 1084 1085 if (id.compare("all") == 0) { 1086 itr = _contours.begin(); 1087 doAll = true; 1088 } else { 1089 itr = _contours.find(id); 1090 } 1091 if (itr == _contours.end()) { 1092 ERROR("Contour2D not found: %s", id.c_str()); 1093 return; 1094 } 1095 1096 do { 1097 itr->second->setContourList(contours); 1098 } while (doAll && ++itr != _contours.end()); 1099 1100 _needsRedraw = true; 1101 } 1102 1103 /** 1104 * \brief Set opacity of contour lines for the given DataSet 1105 */ 1106 void Renderer::setContourOpacity(const DataSetId& id, double opacity) 1107 { 1108 Contour2DHashmap::iterator itr; 1109 1110 bool doAll = false; 1111 1112 if (id.compare("all") == 0) { 1113 itr = _contours.begin(); 1114 doAll = true; 1115 } else { 1116 itr = _contours.find(id); 1117 } 1118 if (itr == _contours.end()) { 1119 ERROR("Contour2D not found: %s", id.c_str()); 1120 return; 1121 } 1122 1123 do { 1124 itr->second->setOpacity(opacity); 1125 } while (doAll && ++itr != _contours.end()); 1126 1127 _needsRedraw = true; 816 1128 } 817 1129 … … 819 1131 * \brief Turn on/off rendering contour lines for the given DataSet 820 1132 */ 821 void Renderer::setContourVisibility(DataSetId id, bool state) 822 { 823 Contour2D *contour = getContour2D(id); 824 if (contour) { 825 contour->setVisibility(state); 826 _needsRedraw = true; 827 } 1133 void Renderer::setContourVisibility(const DataSetId& id, bool state) 1134 { 1135 Contour2DHashmap::iterator itr; 1136 1137 bool doAll = false; 1138 1139 if (id.compare("all") == 0) { 1140 itr = _contours.begin(); 1141 doAll = true; 1142 } else { 1143 itr = _contours.find(id); 1144 } 1145 if (itr == _contours.end()) { 1146 ERROR("Contour2D not found: %s", id.c_str()); 1147 return; 1148 } 1149 1150 do { 1151 itr->second->setVisibility(state); 1152 } while (doAll && ++itr != _contours.end()); 1153 1154 _needsRedraw = true; 828 1155 } 829 1156 … … 831 1158 * \brief Set the RGB isoline color for the specified DataSet 832 1159 */ 833 void Renderer::setContourEdgeColor(DataSetId id, float color[3]) 834 { 835 Contour2D *contour = getContour2D(id); 836 if (contour) { 837 contour->setEdgeColor(color); 838 _needsRedraw = true; 839 } 1160 void Renderer::setContourEdgeColor(const DataSetId& id, float color[3]) 1161 { 1162 Contour2DHashmap::iterator itr; 1163 1164 bool doAll = false; 1165 1166 if (id.compare("all") == 0) { 1167 itr = _contours.begin(); 1168 doAll = true; 1169 } else { 1170 itr = _contours.find(id); 1171 } 1172 if (itr == _contours.end()) { 1173 ERROR("Contour2D not found: %s", id.c_str()); 1174 return; 1175 } 1176 1177 do { 1178 itr->second->setEdgeColor(color); 1179 } while (doAll && ++itr != _contours.end()); 1180 1181 _needsRedraw = true; 840 1182 } 841 1183 … … 846 1188 * this function may not have an effect. 847 1189 */ 848 void Renderer::setContourEdgeWidth(DataSetId id, float edgeWidth) 849 { 850 Contour2D *contour = getContour2D(id); 851 if (contour) { 852 contour->setEdgeWidth(edgeWidth); 853 _needsRedraw = true; 854 } 1190 void Renderer::setContourEdgeWidth(const DataSetId& id, float edgeWidth) 1191 { 1192 Contour2DHashmap::iterator itr; 1193 1194 bool doAll = false; 1195 1196 if (id.compare("all") == 0) { 1197 itr = _contours.begin(); 1198 doAll = true; 1199 } else { 1200 itr = _contours.find(id); 1201 } 1202 if (itr == _contours.end()) { 1203 ERROR("Contour2D not found: %s", id.c_str()); 1204 return; 1205 } 1206 1207 do { 1208 itr->second->setEdgeWidth(edgeWidth); 1209 } while (doAll && ++itr != _contours.end()); 1210 1211 _needsRedraw = true; 855 1212 } 856 1213 … … 858 1215 * \brief Turn contour lighting on/off for the specified DataSet 859 1216 */ 860 void Renderer::setContourLighting(DataSetId id, bool state) 861 { 862 Contour2D *contour = getContour2D(id); 863 if (contour) { 864 contour->setLighting(state); 865 _needsRedraw = true; 866 } 1217 void Renderer::setContourLighting(const DataSetId& id, bool state) 1218 { 1219 Contour2DHashmap::iterator itr; 1220 1221 bool doAll = false; 1222 1223 if (id.compare("all") == 0) { 1224 itr = _contours.begin(); 1225 doAll = true; 1226 } else { 1227 itr = _contours.find(id); 1228 } 1229 if (itr == _contours.end()) { 1230 ERROR("Contour2D not found: %s", id.c_str()); 1231 return; 1232 } 1233 1234 do { 1235 itr->second->setLighting(state); 1236 } while (doAll && ++itr != _contours.end()); 1237 _needsRedraw = true; 867 1238 } 868 1239 … … 870 1241 * \brief Create a new PolyData and associate it with the named DataSet 871 1242 */ 872 void Renderer::addPolyData(DataSetId id) 873 { 874 DataSet *ds = getDataSet(id); 875 if (ds == NULL) 876 return; 877 878 if (getPolyData(id)) { 879 WARN("Replacing existing polydata %s", id.c_str()); 880 deletePolyData(id); 881 } 882 883 PolyData *polyData = new PolyData(); 884 _polyDatas[id] = polyData; 885 886 polyData->setDataSet(ds); 887 888 _renderer->AddActor(polyData->getActor()); 1243 void Renderer::addPolyData(const DataSetId& id) 1244 { 1245 DataSetHashmap::iterator itr; 1246 1247 bool doAll = false; 1248 1249 if (id.compare("all") == 0) { 1250 itr = _dataSets.begin(); 1251 } else { 1252 itr = _dataSets.find(id); 1253 } 1254 if (itr == _dataSets.end()) { 1255 ERROR("Unknown dataset %s", id.c_str()); 1256 return; 1257 } 1258 1259 do { 1260 DataSet *ds = itr->second; 1261 const DataSetId& dsID = ds->getName(); 1262 1263 if (getPolyData(dsID)) { 1264 WARN("Replacing existing polydata %s", dsID.c_str()); 1265 deletePolyData(dsID); 1266 } 1267 1268 PolyData *polyData = new PolyData(); 1269 _polyDatas[dsID] = polyData; 1270 1271 polyData->setDataSet(ds); 1272 1273 _renderer->AddActor(polyData->getActor()); 1274 } while (doAll && ++itr != _dataSets.end()); 889 1275 890 1276 if (_cameraMode == IMAGE) … … 897 1283 * \brief Get the PolyData associated with a named DataSet 898 1284 */ 899 PolyData *Renderer::getPolyData( DataSetIdid)1285 PolyData *Renderer::getPolyData(const DataSetId& id) 900 1286 { 901 1287 PolyDataHashmap::iterator itr = _polyDatas.find(id); … … 909 1295 910 1296 /** 1297 * \brief Set opacity of the PolyData for the given DataSet 1298 */ 1299 void Renderer::setPolyDataOpacity(const DataSetId& id, double opacity) 1300 { 1301 PolyDataHashmap::iterator itr; 1302 1303 bool doAll = false; 1304 1305 if (id.compare("all") == 0) { 1306 itr = _polyDatas.begin(); 1307 doAll = true; 1308 } else { 1309 itr = _polyDatas.find(id); 1310 } 1311 if (itr == _polyDatas.end()) { 1312 ERROR("PolyData not found: %s", id.c_str()); 1313 return; 1314 } 1315 1316 do { 1317 itr->second->setOpacity(opacity); 1318 } while (doAll && ++itr != _polyDatas.end()); 1319 1320 _needsRedraw = true; 1321 } 1322 1323 /** 911 1324 * \brief Turn on/off rendering of the PolyData mapper for the given DataSet 912 1325 */ 913 void Renderer::setPolyDataVisibility(DataSetId id, bool state) 914 { 915 PolyData *polyData = getPolyData(id); 916 if (polyData) { 917 polyData->setVisibility(state); 918 _needsRedraw = true; 919 } 1326 void Renderer::setPolyDataVisibility(const DataSetId& id, bool state) 1327 { 1328 PolyDataHashmap::iterator itr; 1329 1330 bool doAll = false; 1331 1332 if (id.compare("all") == 0) { 1333 itr = _polyDatas.begin(); 1334 doAll = true; 1335 } else { 1336 itr = _polyDatas.find(id); 1337 } 1338 if (itr == _polyDatas.end()) { 1339 ERROR("PolyData not found: %s", id.c_str()); 1340 return; 1341 } 1342 1343 do { 1344 itr->second->setVisibility(state); 1345 } while (doAll && ++itr != _polyDatas.end()); 1346 1347 _needsRedraw = true; 920 1348 } 921 1349 … … 923 1351 * \brief Set the RGB polygon face color for the specified DataSet 924 1352 */ 925 void Renderer::setPolyDataColor(DataSetId id, float color[3]) 926 { 927 PolyData *polyData = getPolyData(id); 928 if (polyData) { 929 polyData->setColor(color); 930 _needsRedraw = true; 931 } 1353 void Renderer::setPolyDataColor(const DataSetId& id, float color[3]) 1354 { 1355 PolyDataHashmap::iterator itr; 1356 1357 bool doAll = false; 1358 1359 if (id.compare("all") == 0) { 1360 itr = _polyDatas.begin(); 1361 doAll = true; 1362 } else { 1363 itr = _polyDatas.find(id); 1364 } 1365 if (itr == _polyDatas.end()) { 1366 ERROR("PolyData not found: %s", id.c_str()); 1367 return; 1368 } 1369 1370 do { 1371 itr->second->setColor(color); 1372 } while (doAll && ++itr != _polyDatas.end()); 1373 _needsRedraw = true; 932 1374 } 933 1375 … … 935 1377 * \brief Set the visibility of polygon edges for the specified DataSet 936 1378 */ 937 void Renderer::setPolyDataEdgeVisibility(DataSetId id, bool state) 938 { 939 PolyData *polyData = getPolyData(id); 940 if (polyData) { 941 polyData->setEdgeVisibility(state); 942 _needsRedraw = true; 943 } 1379 void Renderer::setPolyDataEdgeVisibility(const DataSetId& id, bool state) 1380 { 1381 PolyDataHashmap::iterator itr; 1382 1383 bool doAll = false; 1384 1385 if (id.compare("all") == 0) { 1386 itr = _polyDatas.begin(); 1387 doAll = true; 1388 } else { 1389 itr = _polyDatas.find(id); 1390 } 1391 if (itr == _polyDatas.end()) { 1392 ERROR("PolyData not found: %s", id.c_str()); 1393 return; 1394 } 1395 1396 do { 1397 itr->second->setEdgeVisibility(state); 1398 } while (doAll && ++itr != _polyDatas.end()); 1399 1400 _needsRedraw = true; 944 1401 } 945 1402 … … 947 1404 * \brief Set the RGB polygon edge color for the specified DataSet 948 1405 */ 949 void Renderer::setPolyDataEdgeColor(DataSetId id, float color[3]) 950 { 951 PolyData *polyData = getPolyData(id); 952 if (polyData) { 953 polyData->setEdgeColor(color); 954 _needsRedraw = true; 955 } 1406 void Renderer::setPolyDataEdgeColor(const DataSetId& id, float color[3]) 1407 { 1408 PolyDataHashmap::iterator itr; 1409 1410 bool doAll = false; 1411 1412 if (id.compare("all") == 0) { 1413 itr = _polyDatas.begin(); 1414 doAll = true; 1415 } else { 1416 itr = _polyDatas.find(id); 1417 } 1418 if (itr == _polyDatas.end()) { 1419 ERROR("PolyData not found: %s", id.c_str()); 1420 return; 1421 } 1422 1423 do { 1424 itr->second->setEdgeColor(color); 1425 } while (doAll && ++itr != _polyDatas.end()); 1426 1427 _needsRedraw = true; 956 1428 } 957 1429 … … 962 1434 * this function may not have an effect. 963 1435 */ 964 void Renderer::setPolyDataEdgeWidth(DataSetId id, float edgeWidth) 965 { 966 PolyData *polyData = getPolyData(id); 967 if (polyData) { 968 polyData->setEdgeWidth(edgeWidth); 969 _needsRedraw = true; 970 } 1436 void Renderer::setPolyDataEdgeWidth(const DataSetId& id, float edgeWidth) 1437 { 1438 PolyDataHashmap::iterator itr; 1439 1440 bool doAll = false; 1441 1442 if (id.compare("all") == 0) { 1443 itr = _polyDatas.begin(); 1444 doAll = true; 1445 } else { 1446 itr = _polyDatas.find(id); 1447 } 1448 if (itr == _polyDatas.end()) { 1449 ERROR("PolyData not found: %s", id.c_str()); 1450 return; 1451 } 1452 1453 do { 1454 itr->second->setEdgeWidth(edgeWidth); 1455 } while (doAll && ++itr != _polyDatas.end()); 1456 1457 _needsRedraw = true; 971 1458 } 972 1459 … … 974 1461 * \brief Set wireframe rendering for the specified DataSet 975 1462 */ 976 void Renderer::setPolyDataWireframe(DataSetId id, bool state) 977 { 978 PolyData *polyData = getPolyData(id); 979 if (polyData) { 980 polyData->setWireframe(state); 981 _needsRedraw = true; 982 } 1463 void Renderer::setPolyDataWireframe(const DataSetId& id, bool state) 1464 { 1465 PolyDataHashmap::iterator itr; 1466 1467 bool doAll = false; 1468 1469 if (id.compare("all") == 0) { 1470 itr = _polyDatas.begin(); 1471 doAll = true; 1472 } else { 1473 itr = _polyDatas.find(id); 1474 } 1475 if (itr == _polyDatas.end()) { 1476 ERROR("PolyData not found: %s", id.c_str()); 1477 return; 1478 } 1479 1480 do { 1481 itr->second->setWireframe(state); 1482 } while (doAll && ++itr != _polyDatas.end()); 1483 1484 _needsRedraw = true; 983 1485 } 984 1486 … … 986 1488 * \brief Turn mesh lighting on/off for the specified DataSet 987 1489 */ 988 void Renderer::setPolyDataLighting(DataSetId id, bool state) 989 { 990 PolyData *polyData = getPolyData(id); 991 if (polyData) { 992 polyData->setLighting(state); 993 _needsRedraw = true; 994 } 1490 void Renderer::setPolyDataLighting(const DataSetId& id, bool state) 1491 { 1492 PolyDataHashmap::iterator itr; 1493 1494 bool doAll = false; 1495 1496 if (id.compare("all") == 0) { 1497 itr = _polyDatas.begin(); 1498 doAll = true; 1499 } else { 1500 itr = _polyDatas.find(id); 1501 } 1502 if (itr == _polyDatas.end()) { 1503 ERROR("PolyData not found: %s", id.c_str()); 1504 return; 1505 } 1506 1507 do { 1508 itr->second->setLighting(state); 1509 } while (doAll && ++itr != _polyDatas.end()); 1510 1511 _needsRedraw = true; 995 1512 } 996 1513 … … 1289 1806 } 1290 1807 } 1808 } 1809 1810 /** 1811 * \brief Update data ranges for color-mapping 1812 * 1813 * \param[in] useCumulative Use cumulative range of all DataSets 1814 */ 1815 void Renderer::updateRanges(bool useCumulative) 1816 { 1817 for (PseudoColorHashmap::iterator itr = _pseudoColors.begin(); 1818 itr != _pseudoColors.end(); ++itr) { 1819 vtkLookupTable *lut = itr->second->getLookupTable(); 1820 if (lut) { 1821 if (useCumulative) { 1822 lut->SetRange(_cumulativeDataRange); 1823 } else { 1824 double range[2]; 1825 if (itr->second->getDataSet()) { 1826 itr->second->getDataSet()->getDataRange(range); 1827 lut->SetRange(range); 1828 } 1829 } 1830 } 1831 } 1832 } 1833 1834 /** 1835 * \brief Collect cumulative data range of all DataSets 1836 * 1837 * \param[inout] range Data range of all DataSets 1838 */ 1839 void Renderer::collectDataRanges(double *range) 1840 { 1841 range[0] = DBL_MAX; 1842 range[1] = -DBL_MAX; 1843 1844 for (DataSetHashmap::iterator itr = _dataSets.begin(); 1845 itr != _dataSets.end(); ++itr) { 1846 double r[2]; 1847 itr->second->getDataRange(r); 1848 range[0] = min2(range[0], r[0]); 1849 range[1] = max2(range[1], r[1]); 1850 } 1851 if (range[0] == DBL_MAX) 1852 range[0] = 0; 1853 if (range[1] == -DBL_MAX) 1854 range[1] = 1; 1291 1855 } 1292 1856 … … 1357 1921 * \brief Set the opacity of the specified DataSet's associated graphics objects 1358 1922 */ 1359 void Renderer::setOpacity(DataSetId id, double opacity) 1360 { 1361 PseudoColor *pc = getPseudoColor(id); 1362 if (pc) { 1363 pc->setOpacity(opacity); 1364 _needsRedraw = true; 1365 } 1366 Contour2D *contour = getContour2D(id); 1367 if (contour) { 1368 contour->setOpacity(opacity); 1369 _needsRedraw = true; 1370 } 1371 PolyData *polyData = getPolyData(id); 1372 if (polyData) { 1373 polyData->setOpacity(opacity); 1374 _needsRedraw = true; 1375 } 1923 void Renderer::setOpacity(const DataSetId& id, double opacity) 1924 { 1925 setPseudoColorOpacity(id, opacity); 1926 setContourOpacity(id, opacity); 1927 setPolyDataOpacity(id, opacity); 1376 1928 } 1377 1929 … … 1379 1931 * \brief Turn on/off rendering of the specified DataSet's associated graphics objects 1380 1932 */ 1381 void Renderer::setVisibility( DataSetIdid, bool state)1933 void Renderer::setVisibility(const DataSetId& id, bool state) 1382 1934 { 1383 1935 setPseudoColorVisibility(id, state); … … 1402 1954 for (Contour2DHashmap::iterator itr = _contours.begin(); 1403 1955 itr != _contours.end(); ++itr) { 1956 itr->second->setClippingPlanes(_clippingPlanes); 1957 } 1958 for (PolyDataHashmap::iterator itr = _polyDatas.begin(); 1959 itr != _polyDatas.end(); ++itr) { 1404 1960 itr->second->setClippingPlanes(_clippingPlanes); 1405 1961 } … … 1413 1969 itr->second->setClippingPlanes(NULL); 1414 1970 } 1971 for (PolyDataHashmap::iterator itr = _polyDatas.begin(); 1972 itr != _polyDatas.end(); ++itr) { 1973 itr->second->setClippingPlanes(NULL); 1974 } 1415 1975 } 1416 1976 _renderWindow->Render(); … … 1447 2007 * Note: no interpolation is performed on data 1448 2008 */ 1449 double Renderer::getDataValueAtPixel( DataSetIdid, int x, int y)2009 double Renderer::getDataValueAtPixel(const DataSetId& id, int x, int y) 1450 2010 { 1451 2011 vtkSmartPointer<vtkCoordinate> coord = vtkSmartPointer<vtkCoordinate>::New(); … … 1469 2029 * Note: no interpolation is performed on data 1470 2030 */ 1471 double Renderer::getDataValue( DataSetIdid, double x, double y, double z)2031 double Renderer::getDataValue(const DataSetId& id, double x, double y, double z) 1472 2032 { 1473 2033 DataSet *ds = getDataSet(id); -
branches/blt4/packages/vizservers/vtkvis/RpVtkRenderer.h
r2120 r2170 66 66 // Data sets 67 67 68 void addDataSet( DataSetIdid);69 70 void deleteDataSet( DataSetIdid);71 72 DataSet *getDataSet( DataSetIdid);73 74 bool setData( DataSetIdid, char *data, int nbytes);75 76 bool setDataFile( DataSetIdid, const char *filename);77 78 double getDataValueAtPixel( DataSetIdid, int x, int y);79 80 double getDataValue( DataSetIdid, double x, double y, double z);81 82 void setOpacity( DataSetIdid, double opacity);83 84 void setVisibility( DataSetIdid, bool state);68 void addDataSet(const DataSetId& id); 69 70 void deleteDataSet(const DataSetId& id); 71 72 DataSet *getDataSet(const DataSetId& id); 73 74 bool setData(const DataSetId& id, char *data, int nbytes); 75 76 bool setDataFile(const DataSetId& id, const char *filename); 77 78 double getDataValueAtPixel(const DataSetId& id, int x, int y); 79 80 double getDataValue(const DataSetId& id, double x, double y, double z); 81 82 void setOpacity(const DataSetId& id, double opacity); 83 84 void setVisibility(const DataSetId& id, bool state); 85 85 86 86 // Render window … … 132 132 // Colormaps 133 133 134 void addColorMap(ColorMapId id, ColorMap *colorMap); 135 136 void deleteColorMap(ColorMapId id); 137 138 ColorMap *getColorMap(ColorMapId id); 139 140 void renderColorMap(ColorMapId id, const char *title, 134 void addColorMap(const ColorMapId& id, ColorMap *colorMap); 135 136 void deleteColorMap(const ColorMapId& id); 137 138 ColorMap *getColorMap(const ColorMapId& id); 139 140 bool renderColorMap(const ColorMapId& id, 141 const DataSetId& dataSetID, 142 const char *title, 141 143 int width, int height, 142 144 vtkUnsignedCharArray *imgData); … … 144 146 // Color-mapped surfaces 145 147 146 void addPseudoColor(DataSetId id); 147 148 void deletePseudoColor(DataSetId id); 149 150 PseudoColor *getPseudoColor(DataSetId id); 151 152 void setPseudoColorColorMap(DataSetId id, ColorMapId colorMapId); 153 154 vtkLookupTable *getPseudoColorColorMap(DataSetId id); 155 156 void setPseudoColorVisibility(DataSetId id, bool state); 157 158 void setPseudoColorEdgeVisibility(DataSetId id, bool state); 159 160 void setPseudoColorEdgeColor(DataSetId id, float color[3]); 161 162 void setPseudoColorEdgeWidth(DataSetId id, float edgeWidth); 163 164 void setPseudoColorLighting(DataSetId id, bool state); 148 void addPseudoColor(const DataSetId& id); 149 150 void deletePseudoColor(const DataSetId& id); 151 152 PseudoColor *getPseudoColor(const DataSetId& id); 153 154 void setPseudoColorColorMap(const DataSetId& id, const ColorMapId& colorMapId); 155 156 vtkLookupTable *getPseudoColorColorMap(const DataSetId& id); 157 158 void setPseudoColorOpacity(const DataSetId& id, double opacity); 159 160 void setPseudoColorVisibility(const DataSetId& id, bool state); 161 162 void setPseudoColorEdgeVisibility(const DataSetId& id, bool state); 163 164 void setPseudoColorEdgeColor(const DataSetId& id, float color[3]); 165 166 void setPseudoColorEdgeWidth(const DataSetId& id, float edgeWidth); 167 168 void setPseudoColorLighting(const DataSetId& id, bool state); 165 169 166 170 // Contour plots 167 171 168 void addContour2D(DataSetId id); 169 170 void deleteContour2D(DataSetId id); 171 172 Contour2D *getContour2D(DataSetId id); 173 174 void setContours(DataSetId id, int numContours); 175 176 void setContourList(DataSetId id, const std::vector<double>& contours); 177 178 void setContourVisibility(DataSetId id, bool state); 179 180 void setContourEdgeColor(DataSetId id, float color[3]); 181 182 void setContourEdgeWidth(DataSetId id, float edgeWidth); 183 184 void setContourLighting(DataSetId id, bool state); 172 void addContour2D(const DataSetId& id); 173 174 void deleteContour2D(const DataSetId& id); 175 176 Contour2D *getContour2D(const DataSetId& id); 177 178 void setContours(const DataSetId& id, int numContours); 179 180 void setContourList(const DataSetId& id, const std::vector<double>& contours); 181 182 void setContourOpacity(const DataSetId& id, double opacity); 183 184 void setContourVisibility(const DataSetId& id, bool state); 185 186 void setContourEdgeColor(const DataSetId& id, float color[3]); 187 188 void setContourEdgeWidth(const DataSetId& id, float edgeWidth); 189 190 void setContourLighting(const DataSetId& id, bool state); 185 191 186 192 // Meshes 187 193 188 void addPolyData( DataSetIdid);194 void addPolyData(const DataSetId& id); 189 195 190 void deletePolyData(DataSetId id); 191 192 PolyData *getPolyData(DataSetId id); 193 194 void setPolyDataVisibility(DataSetId id, bool state); 195 196 void setPolyDataColor(DataSetId id, float color[3]); 197 198 void setPolyDataEdgeVisibility(DataSetId id, bool state); 199 200 void setPolyDataEdgeColor(DataSetId id, float color[3]); 201 202 void setPolyDataEdgeWidth(DataSetId id, float edgeWidth); 203 204 void setPolyDataWireframe(DataSetId id, bool state); 205 206 void setPolyDataLighting(DataSetId id, bool state); 196 void deletePolyData(const DataSetId& id); 197 198 PolyData *getPolyData(const DataSetId& id); 199 200 void setPolyDataOpacity(const DataSetId& id, double opacity); 201 202 void setPolyDataVisibility(const DataSetId& id, bool state); 203 204 void setPolyDataColor(const DataSetId& id, float color[3]); 205 206 void setPolyDataEdgeVisibility(const DataSetId& id, bool state); 207 208 void setPolyDataEdgeColor(const DataSetId& id, float color[3]); 209 210 void setPolyDataEdgeWidth(const DataSetId& id, float edgeWidth); 211 212 void setPolyDataWireframe(const DataSetId& id, bool state); 213 214 void setPolyDataLighting(const DataSetId& id, bool state); 207 215 208 216 private: … … 220 228 void collectBounds(double *bounds, bool onlyVisible); 221 229 230 void collectDataRanges(double *range); 231 232 void updateRanges(bool useCumulative); 233 222 234 void storeCameraOrientation(); 223 235 void restoreCameraOrientation(); … … 234 246 double _cameraUp[3]; 235 247 float _bgColor[3]; 248 bool _useCumulativeRanges; 249 double _cumulativeDataRange[2]; 236 250 237 251 ColorMapHashmap _colorMaps; -
branches/blt4/packages/vizservers/vtkvis/RpVtkRendererCmd.cpp
r2120 r2170 172 172 {"name", 1, AxisNameOp, 4, 4, "axis title"}, 173 173 {"units", 1, AxisUnitsOp, 4, 4, "axis units"}, 174 {"visible", 1, AxisVisibleOp, 4, 4, "axis bool"} ,174 {"visible", 1, AxisVisibleOp, 4, 4, "axis bool"} 175 175 }; 176 176 static int nAxisOps = NumCmdSpecs(axisOps); … … 298 298 {"reset", 2, CameraResetOp, 2, 3, "?all?"}, 299 299 {"rotate", 2, CameraRotateOp, 5, 5, "angle angle angle"}, 300 {"zoom", 1, CameraZoomOp, 3, 3, "zoomAmount"} ,300 {"zoom", 1, CameraZoomOp, 3, 3, "zoomAmount"} 301 301 }; 302 302 static int nCameraOps = NumCmdSpecs(cameraOps); … … 400 400 Tcl_Obj *const *objv) 401 401 { 402 const char *name = Tcl_GetString(objv[2]); 403 g_renderer->deleteColorMap(name); 402 if (objc == 3) { 403 const char *name = Tcl_GetString(objv[2]); 404 g_renderer->deleteColorMap(name); 405 } else { 406 g_renderer->deleteColorMap("all"); 407 } 404 408 return TCL_OK; 405 409 } … … 407 411 static Rappture::CmdSpec colorMapOps[] = { 408 412 {"add", 1, ColorMapAddOp, 5, 5, "colorMapName colormap alphamap"}, 409 {"delete", 1, ColorMapDeleteOp, 3, 3, "colorMapName"}413 {"delete", 1, ColorMapDeleteOp, 2, 3, "?colorMapName?"} 410 414 }; 411 415 static int nColorMapOps = NumCmdSpecs(colorMapOps); … … 429 433 Tcl_Obj *const *objv) 430 434 { 431 const char *name = Tcl_GetString(objv[4]);432 g_renderer->addContour2D(name);433 435 std::vector<double> contourList; 434 436 … … 448 450 } 449 451 450 g_renderer->setContourList(name, contourList); 452 if (objc == 5) { 453 const char *name = Tcl_GetString(objv[4]); 454 g_renderer->addContour2D(name); 455 g_renderer->setContourList(name, contourList); 456 } else { 457 g_renderer->addContour2D("all"); 458 g_renderer->setContourList("all", contourList); 459 } 451 460 return TCL_OK; 452 461 } … … 456 465 Tcl_Obj *const *objv) 457 466 { 458 const char *name = Tcl_GetString(objv[4]);459 g_renderer->addContour2D(name);460 467 int numContours; 461 468 if (Tcl_GetIntFromObj(interp, objv[3], &numContours) != TCL_OK) { 462 469 return TCL_ERROR; 463 470 } 464 g_renderer->setContours(name, numContours); 471 if (objc == 5) { 472 const char *name = Tcl_GetString(objv[4]); 473 g_renderer->addContour2D(name); 474 g_renderer->setContours(name, numContours); 475 } else { 476 g_renderer->addContour2D("all"); 477 g_renderer->setContours("all", numContours); 478 } 465 479 return TCL_OK; 466 480 } 467 481 468 482 static Rappture::CmdSpec contour2dAddOps[] = { 469 {"contourlist", 1, Contour2DAddContourListOp, 5, 5, "contourList dataSetName"},470 {"numcontours", 1, Contour2DAddNumContoursOp, 5, 5, "numContours dataSetName"}483 {"contourlist", 1, Contour2DAddContourListOp, 4, 5, "contourList ?dataSetName?"}, 484 {"numcontours", 1, Contour2DAddNumContoursOp, 4, 5, "numContours ?dataSetName?"} 471 485 }; 472 486 static int nContour2dAddOps = NumCmdSpecs(contour2dAddOps); … … 490 504 Tcl_Obj *const *objv) 491 505 { 492 const char *name = Tcl_GetString(objv[2]); 493 g_renderer->deleteContour2D(name); 506 if (objc == 3) { 507 const char *name = Tcl_GetString(objv[2]); 508 g_renderer->deleteContour2D(name); 509 } else { 510 g_renderer->deleteContour2D("all"); 511 } 494 512 return TCL_OK; 495 513 } … … 499 517 Tcl_Obj *const *objv) 500 518 { 501 const char *name = Tcl_GetString(objv[3]);502 519 bool state; 503 520 if (GetBooleanFromObj(interp, objv[2], &state) != TCL_OK) { 504 521 return TCL_ERROR; 505 522 } 506 g_renderer->setContourLighting(name, state); 523 if (objc == 4) { 524 const char *name = Tcl_GetString(objv[3]); 525 g_renderer->setContourLighting(name, state); 526 } else { 527 g_renderer->setContourLighting("all", state); 528 } 507 529 return TCL_OK; 508 530 } … … 512 534 Tcl_Obj *const *objv) 513 535 { 514 const char *name = Tcl_GetString(objv[5]);515 536 float color[3]; 516 537 if (GetFloatFromObj(interp, objv[2], &color[0]) != TCL_OK || … … 519 540 return TCL_ERROR; 520 541 } 521 g_renderer->setContourEdgeColor(name, color); 542 if (objc == 6) { 543 const char *name = Tcl_GetString(objv[5]); 544 g_renderer->setContourEdgeColor(name, color); 545 } else { 546 g_renderer->setContourEdgeColor("all", color); 547 } 522 548 return TCL_OK; 523 549 } … … 527 553 Tcl_Obj *const *objv) 528 554 { 529 const char *name = Tcl_GetString(objv[3]);530 555 float width; 531 556 if (GetFloatFromObj(interp, objv[2], &width) != TCL_OK) { 532 557 return TCL_ERROR; 533 558 } 534 g_renderer->setContourEdgeWidth(name, width); 559 if (objc == 4) { 560 const char *name = Tcl_GetString(objv[3]); 561 g_renderer->setContourEdgeWidth(name, width); 562 } else { 563 g_renderer->setContourEdgeWidth("all", width); 564 } 565 return TCL_OK; 566 } 567 568 static int 569 Contour2DOpacityOp(ClientData clientData, Tcl_Interp *interp, int objc, 570 Tcl_Obj *const *objv) 571 { 572 double opacity; 573 if (Tcl_GetDoubleFromObj(interp, objv[2], &opacity) != TCL_OK) { 574 return TCL_ERROR; 575 } 576 if (objc == 4) { 577 const char *name = Tcl_GetString(objv[3]); 578 g_renderer->setContourOpacity(name, opacity); 579 } else { 580 g_renderer->setContourOpacity("all", opacity); 581 } 535 582 return TCL_OK; 536 583 } … … 540 587 Tcl_Obj *const *objv) 541 588 { 542 const char *name = Tcl_GetString(objv[3]);543 589 bool state; 544 590 if (GetBooleanFromObj(interp, objv[2], &state) != TCL_OK) { 545 591 return TCL_ERROR; 546 592 } 547 g_renderer->setContourVisibility(name, state); 593 if (objc == 4) { 594 const char *name = Tcl_GetString(objv[3]); 595 g_renderer->setContourVisibility(name, state); 596 } else { 597 g_renderer->setContourVisibility("all", state); 598 } 548 599 return TCL_OK; 549 600 } 550 601 551 602 static Rappture::CmdSpec contour2dOps[] = { 552 {"add", 1, Contour2DAddOp, 5, 5, "oper value dataSetName"}, 553 {"delete", 1, Contour2DDeleteOp, 3, 3, "dataSetName"}, 554 {"lighting", 3, Contour2DLightingOp, 4, 4, "bool dataSetName"}, 555 {"linecolor", 5, Contour2DLineColorOp, 6, 6, "r g b dataSetName"}, 556 {"linewidth", 5, Contour2DLineWidthOp, 4, 4, "width dataSetName"}, 557 {"visible", 1, Contour2DVisibleOp, 4, 4, "bool dataSetName"}, 603 {"add", 1, Contour2DAddOp, 4, 5, "oper value ?dataSetName?"}, 604 {"delete", 1, Contour2DDeleteOp, 2, 3, "?dataSetName?"}, 605 {"lighting", 3, Contour2DLightingOp, 3, 4, "bool ?dataSetName?"}, 606 {"linecolor", 5, Contour2DLineColorOp, 5, 6, "r g b ?dataSetName?"}, 607 {"linewidth", 5, Contour2DLineWidthOp, 3, 4, "width ?dataSetName?"}, 608 {"opacity", 1, Contour2DOpacityOp, 3, 4, "value ?dataSetName?"}, 609 {"visible", 1, Contour2DVisibleOp, 3, 4, "bool ?dataSetName?"} 558 610 }; 559 611 static int nContour2dOps = NumCmdSpecs(contour2dOps); … … 627 679 Tcl_Obj *const *objv) 628 680 { 629 const char *name = Tcl_GetString(objv[2]); 630 TRACE("Deleting dataset %s", name); 631 g_renderer->deleteDataSet(name); 681 if (objc == 3) { 682 const char *name = Tcl_GetString(objv[2]); 683 TRACE("Deleting dataset %s", name); 684 g_renderer->deleteDataSet(name); 685 } else { 686 g_renderer->deleteDataSet("all"); 687 } 632 688 return TCL_OK; 633 689 } … … 712 768 Tcl_Obj *const *objv) 713 769 { 714 const char *name = Tcl_GetString(objv[3]);715 770 double opacity; 716 771 if (Tcl_GetDoubleFromObj(interp, objv[2], &opacity) != TCL_OK) { 717 772 return TCL_ERROR; 718 773 } 719 g_renderer->setOpacity(name, opacity); 774 if (objc == 4) { 775 const char *name = Tcl_GetString(objv[3]); 776 g_renderer->setOpacity(name, opacity); 777 } else { 778 g_renderer->setOpacity("all", opacity); 779 } 720 780 return TCL_OK; 721 781 } … … 725 785 Tcl_Obj *const *objv) 726 786 { 727 const char *name = Tcl_GetString(objv[3]);728 787 bool state; 729 788 if (GetBooleanFromObj(interp, objv[2], &state) != TCL_OK) { 730 789 return TCL_ERROR; 731 790 } 732 g_renderer->setVisibility(name, state); 791 if (objc == 4) { 792 const char *name = Tcl_GetString(objv[3]); 793 g_renderer->setVisibility(name, state); 794 } else { 795 g_renderer->setVisibility("all", state); 796 } 733 797 return TCL_OK; 734 798 } … … 736 800 static Rappture::CmdSpec dataSetOps[] = { 737 801 {"add", 1, DataSetAddOp, 6, 6, "name data follows nBytes"}, 738 {"delete", 1, DataSetDeleteOp, 3, 3, "name"},802 {"delete", 1, DataSetDeleteOp, 2, 3, "?name?"}, 739 803 {"getvalue", 1, DataSetGetValueOp, 6, 7, "oper x y ?z? name"}, 740 {"opacity", 1, DataSetOpacityOp, 4, 4, "value name"},741 {"visible", 1, DataSetVisibleOp, 4, 4, "bool name"}804 {"opacity", 1, DataSetOpacityOp, 3, 4, "value ?name?"}, 805 {"visible", 1, DataSetVisibleOp, 3, 4, "bool ?name?"} 742 806 }; 743 807 static int nDataSetOps = NumCmdSpecs(dataSetOps); … … 763 827 if (objc < 4) { 764 828 Tcl_AppendResult(interp, "wrong # args: should be \"", 765 Tcl_GetString(objv[0]), " colormapName title width height \"", (char*)NULL);829 Tcl_GetString(objv[0]), " colormapName title width height ?dataSetName?\"", (char*)NULL); 766 830 return TCL_ERROR; 767 831 } … … 778 842 vtkSmartPointer<vtkUnsignedCharArray>::New(); 779 843 780 g_renderer->renderColorMap(name, title, width, height, imgData); 844 if (objc == 6) { 845 const char *dataSetName = Tcl_GetString(objv[5]); 846 if (!g_renderer->renderColorMap(name, dataSetName, title, width, height, imgData)) { 847 Tcl_AppendResult(interp, "Color map \"", 848 name, "\" was not found", (char*)NULL); 849 return TCL_ERROR; 850 } 851 } else { 852 if (!g_renderer->renderColorMap(name, "all", title, width, height, imgData)) { 853 Tcl_AppendResult(interp, "Color map \"", 854 name, "\" was not found", (char*)NULL); 855 return TCL_ERROR; 856 } 857 } 781 858 782 859 #ifdef DEBUG … … 795 872 Tcl_Obj *const *objv) 796 873 { 797 const char *name = Tcl_GetString(objv[2]); 798 g_renderer->addPseudoColor(name); 874 if (objc == 3) { 875 const char *name = Tcl_GetString(objv[2]); 876 g_renderer->addPseudoColor(name); 877 } else { 878 g_renderer->addPseudoColor("all"); 879 } 799 880 return TCL_OK; 800 881 } … … 805 886 { 806 887 const char *colorMapName = Tcl_GetString(objv[2]); 807 const char *dataSetName = Tcl_GetString(objv[3]); 808 g_renderer->setPseudoColorColorMap(dataSetName, colorMapName); 888 if (objc == 4) { 889 const char *dataSetName = Tcl_GetString(objv[3]); 890 g_renderer->setPseudoColorColorMap(dataSetName, colorMapName); 891 } else { 892 g_renderer->setPseudoColorColorMap("all", colorMapName); 893 } 809 894 return TCL_OK; 810 895 } … … 814 899 Tcl_Obj *const *objv) 815 900 { 816 const char *name = Tcl_GetString(objv[2]); 817 g_renderer->deletePseudoColor(name); 818 return TCL_OK; 819 } 820 821 static int 822 PseudoColorVisibleOp(ClientData clientData, Tcl_Interp *interp, int objc, 823 Tcl_Obj *const *objv) 824 { 825 const char *name = Tcl_GetString(objv[3]); 901 if (objc == 3) { 902 const char *name = Tcl_GetString(objv[2]); 903 g_renderer->deletePseudoColor(name); 904 } else { 905 g_renderer->deletePseudoColor("all"); 906 } 907 return TCL_OK; 908 } 909 910 static int 911 PseudoColorEdgeVisibilityOp(ClientData clientData, Tcl_Interp *interp, int objc, 912 Tcl_Obj *const *objv) 913 { 826 914 bool state; 827 915 if (GetBooleanFromObj(interp, objv[2], &state) != TCL_OK) { 828 916 return TCL_ERROR; 829 917 } 830 g_renderer->setPseudoColorVisibility(name, state); 831 return TCL_OK; 832 } 833 834 static int 835 PseudoColorEdgeVisibilityOp(ClientData clientData, Tcl_Interp *interp, int objc, 836 Tcl_Obj *const *objv) 837 { 838 const char *name = Tcl_GetString(objv[3]); 918 if (objc == 4) { 919 const char *name = Tcl_GetString(objv[3]); 920 g_renderer->setPseudoColorEdgeVisibility(name, state); 921 } else { 922 g_renderer->setPseudoColorEdgeVisibility("all", state); 923 } 924 return TCL_OK; 925 } 926 927 static int 928 PseudoColorLightingOp(ClientData clientData, Tcl_Interp *interp, int objc, 929 Tcl_Obj *const *objv) 930 { 839 931 bool state; 840 932 if (GetBooleanFromObj(interp, objv[2], &state) != TCL_OK) { 841 933 return TCL_ERROR; 842 934 } 843 g_renderer->setPseudoColorEdgeVisibility(name, state); 844 return TCL_OK; 845 } 846 847 static int 848 PseudoColorLightingOp(ClientData clientData, Tcl_Interp *interp, int objc, 849 Tcl_Obj *const *objv) 850 { 851 const char *name = Tcl_GetString(objv[3]); 852 bool state; 853 if (GetBooleanFromObj(interp, objv[2], &state) != TCL_OK) { 854 return TCL_ERROR; 855 } 856 g_renderer->setPseudoColorLighting(name, state); 935 if (objc == 4) { 936 const char *name = Tcl_GetString(objv[3]); 937 g_renderer->setPseudoColorLighting(name, state); 938 } else { 939 g_renderer->setPseudoColorLighting("all", state); 940 } 857 941 return TCL_OK; 858 942 } … … 862 946 Tcl_Obj *const *objv) 863 947 { 864 const char *name = Tcl_GetString(objv[5]);865 948 float color[3]; 866 949 if (GetFloatFromObj(interp, objv[2], &color[0]) != TCL_OK || … … 869 952 return TCL_ERROR; 870 953 } 871 g_renderer->setPseudoColorEdgeColor(name, color); 954 if (objc == 6) { 955 const char *name = Tcl_GetString(objv[5]); 956 g_renderer->setPseudoColorEdgeColor(name, color); 957 } else { 958 g_renderer->setPseudoColorEdgeColor("all", color); 959 } 872 960 return TCL_OK; 873 961 } … … 877 965 Tcl_Obj *const *objv) 878 966 { 879 const char *name = Tcl_GetString(objv[3]);880 967 float width; 881 968 if (GetFloatFromObj(interp, objv[2], &width) != TCL_OK) { 882 969 return TCL_ERROR; 883 970 } 884 g_renderer->setPseudoColorEdgeWidth(name, width); 971 if (objc == 4) { 972 const char *name = Tcl_GetString(objv[3]); 973 g_renderer->setPseudoColorEdgeWidth(name, width); 974 } else { 975 g_renderer->setPseudoColorEdgeWidth("all", width); 976 } 977 return TCL_OK; 978 } 979 980 static int 981 PseudoColorOpacityOp(ClientData clientData, Tcl_Interp *interp, int objc, 982 Tcl_Obj *const *objv) 983 { 984 double opacity; 985 if (Tcl_GetDoubleFromObj(interp, objv[2], &opacity) != TCL_OK) { 986 return TCL_ERROR; 987 } 988 if (objc == 4) { 989 const char *name = Tcl_GetString(objv[3]); 990 g_renderer->setPseudoColorOpacity(name, opacity); 991 } else { 992 g_renderer->setPseudoColorOpacity("all", opacity); 993 } 994 return TCL_OK; 995 } 996 997 static int 998 PseudoColorVisibleOp(ClientData clientData, Tcl_Interp *interp, int objc, 999 Tcl_Obj *const *objv) 1000 { 1001 bool state; 1002 if (GetBooleanFromObj(interp, objv[2], &state) != TCL_OK) { 1003 return TCL_ERROR; 1004 } 1005 if (objc == 4) { 1006 const char *name = Tcl_GetString(objv[3]); 1007 g_renderer->setPseudoColorVisibility(name, state); 1008 } else { 1009 g_renderer->setPseudoColorVisibility("all", state); 1010 } 885 1011 return TCL_OK; 886 1012 } 887 1013 888 1014 static Rappture::CmdSpec pseudoColorOps[] = { 889 {"add", 1, PseudoColorAddOp, 3, 3, "dataSetName"}, 890 {"colormap", 1, PseudoColorColorMapOp, 4, 4, "colorMapName dataSetName"}, 891 {"delete", 1, PseudoColorDeleteOp, 3, 3, "dataSetName"}, 892 {"edges", 1, PseudoColorEdgeVisibilityOp, 4, 4, "bool dataSetName"}, 893 {"lighting", 3, PseudoColorLightingOp, 4, 4, "bool dataSetName"}, 894 {"linecolor", 5, PseudoColorLineColorOp, 6, 6, "r g b dataSetName"}, 895 {"linewidth", 5, PseudoColorLineWidthOp, 4, 4, "width dataSetName"}, 896 {"visible", 1, PseudoColorVisibleOp, 4, 4, "bool dataSetName"} 1015 {"add", 1, PseudoColorAddOp, 2, 3, "?dataSetName?"}, 1016 {"colormap", 1, PseudoColorColorMapOp, 3, 4, "colorMapName ?dataSetName?"}, 1017 {"delete", 1, PseudoColorDeleteOp, 2, 3, "?dataSetName?"}, 1018 {"edges", 1, PseudoColorEdgeVisibilityOp, 3, 4, "bool ?dataSetName?"}, 1019 {"lighting", 3, PseudoColorLightingOp, 3, 4, "bool ?dataSetName?"}, 1020 {"linecolor", 5, PseudoColorLineColorOp, 5, 6, "r g b ?dataSetName?"}, 1021 {"linewidth", 5, PseudoColorLineWidthOp, 3, 4, "width ?dataSetName?"}, 1022 {"opacity", 1, PseudoColorOpacityOp, 3, 4, "value ?dataSetName?"}, 1023 {"visible", 1, PseudoColorVisibleOp, 3, 4, "bool ?dataSetName?"} 897 1024 }; 898 1025 static int nPseudoColorOps = NumCmdSpecs(pseudoColorOps); … … 916 1043 Tcl_Obj *const *objv) 917 1044 { 918 const char *name = Tcl_GetString(objv[2]); 919 g_renderer->addPolyData(name); 1045 if (objc == 3) { 1046 const char *name = Tcl_GetString(objv[2]); 1047 g_renderer->addPolyData(name); 1048 } else { 1049 g_renderer->addPolyData("all"); 1050 } 920 1051 return TCL_OK; 921 1052 } … … 925 1056 Tcl_Obj *const *objv) 926 1057 { 927 const char *name = Tcl_GetString(objv[2]); 928 g_renderer->deletePolyData(name); 1058 if (objc == 3) { 1059 const char *name = Tcl_GetString(objv[2]); 1060 g_renderer->deletePolyData(name); 1061 } else { 1062 g_renderer->deletePolyData("all"); 1063 } 929 1064 return TCL_OK; 930 1065 } … … 934 1069 Tcl_Obj *const *objv) 935 1070 { 936 const char *name = Tcl_GetString(objv[5]);937 1071 float color[3]; 938 1072 if (GetFloatFromObj(interp, objv[2], &color[0]) != TCL_OK || … … 941 1075 return TCL_ERROR; 942 1076 } 943 g_renderer->setPolyDataColor(name, color); 1077 if (objc == 6) { 1078 const char *name = Tcl_GetString(objv[5]); 1079 g_renderer->setPolyDataColor(name, color); 1080 } else { 1081 g_renderer->setPolyDataColor("all", color); 1082 } 944 1083 return TCL_OK; 945 1084 } … … 949 1088 Tcl_Obj *const *objv) 950 1089 { 951 const char *name = Tcl_GetString(objv[3]);952 1090 bool state; 953 1091 if (GetBooleanFromObj(interp, objv[2], &state) != TCL_OK) { 954 1092 return TCL_ERROR; 955 1093 } 956 g_renderer->setPolyDataEdgeVisibility(name, state); 1094 if (objc == 4) { 1095 const char *name = Tcl_GetString(objv[3]); 1096 g_renderer->setPolyDataEdgeVisibility(name, state); 1097 } else { 1098 g_renderer->setPolyDataEdgeVisibility("all", state); 1099 } 957 1100 return TCL_OK; 958 1101 } … … 962 1105 Tcl_Obj *const *objv) 963 1106 { 964 const char *name = Tcl_GetString(objv[3]);965 1107 bool state; 966 1108 if (GetBooleanFromObj(interp, objv[2], &state) != TCL_OK) { 967 1109 return TCL_ERROR; 968 1110 } 969 g_renderer->setPolyDataLighting(name, state); 1111 if (objc == 4) { 1112 const char *name = Tcl_GetString(objv[3]); 1113 g_renderer->setPolyDataLighting(name, state); 1114 } else { 1115 g_renderer->setPolyDataLighting("all", state); 1116 } 970 1117 return TCL_OK; 971 1118 } … … 975 1122 Tcl_Obj *const *objv) 976 1123 { 977 const char *name = Tcl_GetString(objv[5]);978 1124 float color[3]; 979 1125 if (GetFloatFromObj(interp, objv[2], &color[0]) != TCL_OK || … … 982 1128 return TCL_ERROR; 983 1129 } 984 g_renderer->setPolyDataEdgeColor(name, color); 1130 if (objc == 6) { 1131 const char *name = Tcl_GetString(objv[5]); 1132 g_renderer->setPolyDataEdgeColor(name, color); 1133 } else { 1134 g_renderer->setPolyDataEdgeColor("all", color); 1135 } 985 1136 return TCL_OK; 986 1137 } … … 990 1141 Tcl_Obj *const *objv) 991 1142 { 992 const char *name = Tcl_GetString(objv[3]);993 1143 float width; 994 1144 if (GetFloatFromObj(interp, objv[2], &width) != TCL_OK) { 995 1145 return TCL_ERROR; 996 1146 } 997 g_renderer->setPolyDataEdgeWidth(name, width); 1147 if (objc == 4) { 1148 const char *name = Tcl_GetString(objv[3]); 1149 g_renderer->setPolyDataEdgeWidth(name, width); 1150 } else { 1151 g_renderer->setPolyDataEdgeWidth("all", width); 1152 } 1153 return TCL_OK; 1154 } 1155 1156 static int 1157 PolyDataOpacityOp(ClientData clientData, Tcl_Interp *interp, int objc, 1158 Tcl_Obj *const *objv) 1159 { 1160 double opacity; 1161 if (Tcl_GetDoubleFromObj(interp, objv[2], &opacity) != TCL_OK) { 1162 return TCL_ERROR; 1163 } 1164 if (objc == 4) { 1165 const char *name = Tcl_GetString(objv[3]); 1166 g_renderer->setPolyDataOpacity(name, opacity); 1167 } else { 1168 g_renderer->setPolyDataOpacity("all", opacity); 1169 } 998 1170 return TCL_OK; 999 1171 } … … 1003 1175 Tcl_Obj *const *objv) 1004 1176 { 1005 const char *name = Tcl_GetString(objv[3]);1006 1177 bool state; 1007 1178 if (GetBooleanFromObj(interp, objv[2], &state) != TCL_OK) { 1008 1179 return TCL_ERROR; 1009 1180 } 1010 g_renderer->setPolyDataVisibility(name, state); 1181 if (objc == 4) { 1182 const char *name = Tcl_GetString(objv[3]); 1183 g_renderer->setPolyDataVisibility(name, state); 1184 } else { 1185 g_renderer->setPolyDataVisibility("all", state); 1186 } 1011 1187 return TCL_OK; 1012 1188 } … … 1016 1192 Tcl_Obj *const *objv) 1017 1193 { 1018 const char *name = Tcl_GetString(objv[3]);1019 1194 bool state; 1020 1195 if (GetBooleanFromObj(interp, objv[2], &state) != TCL_OK) { 1021 1196 return TCL_ERROR; 1022 1197 } 1023 g_renderer->setPolyDataWireframe(name, state); 1198 if (objc == 4) { 1199 const char *name = Tcl_GetString(objv[3]); 1200 g_renderer->setPolyDataWireframe(name, state); 1201 } else { 1202 g_renderer->setPolyDataWireframe("all", state); 1203 } 1024 1204 return TCL_OK; 1025 1205 } 1026 1206 1027 1207 static Rappture::CmdSpec polyDataOps[] = { 1028 {"add", 1, PolyDataAddOp, 3, 3, "dataSetName"}, 1029 {"color", 1, PolyDataColorOp, 6, 6, "r g b dataSetName"}, 1030 {"delete", 1, PolyDataDeleteOp, 3, 3, "dataSetName"}, 1031 {"edges", 1, PolyDataEdgeVisibilityOp, 4, 4, "bool dataSetName"}, 1032 {"lighting", 3, PolyDataLightingOp, 4, 4, "bool dataSetName"}, 1033 {"linecolor", 5, PolyDataLineColorOp, 6, 6, "r g b dataSetName"}, 1034 {"linewidth", 5, PolyDataLineWidthOp, 4, 4, "width dataSetName"}, 1035 {"visible", 1, PolyDataVisibleOp, 4, 4, "bool dataSetName"}, 1036 {"wireframe", 1, PolyDataWireframeOp, 4, 4, "bool dataSetName"} 1208 {"add", 1, PolyDataAddOp, 2, 3, "?dataSetName?"}, 1209 {"color", 1, PolyDataColorOp, 5, 6, "r g b ?dataSetName?"}, 1210 {"delete", 1, PolyDataDeleteOp, 2, 3, "?dataSetName?"}, 1211 {"edges", 1, PolyDataEdgeVisibilityOp, 3, 4, "bool ?dataSetName?"}, 1212 {"lighting", 3, PolyDataLightingOp, 3, 4, "bool ?dataSetName?"}, 1213 {"linecolor", 5, PolyDataLineColorOp, 5, 6, "r g b ?dataSetName?"}, 1214 {"linewidth", 5, PolyDataLineWidthOp, 3, 4, "width ?dataSetName?"}, 1215 {"opacity", 1, PolyDataOpacityOp, 3, 4, "value ?dataSetName?"}, 1216 {"visible", 1, PolyDataVisibleOp, 3, 4, "bool ?dataSetName?"}, 1217 {"wireframe", 1, PolyDataWireframeOp, 3, 4, "bool ?dataSetName?"} 1037 1218 }; 1038 1219 static int nPolyDataOps = NumCmdSpecs(polyDataOps); -
branches/blt4/packages/vizservers/vtkvis/protocol.txt
r2120 r2170 31 31 Specify zoom ratio 32 32 33 colormap add <colorMapName> <colorMap> <opacityMap> 34 colorMap = Tcl list of {value r g b} control points 35 opacityMap = Tcl list of {value alpha} control points 36 colormap delete <?colorMapName?> 37 38 legend <colormapName> <legendTitle> <width> <height> <?datasetName?> 39 Causes legend to be rendered and written back with labels and title 40 33 41 dataset add <datasetName> data follows <nbytes> 34 dataset delete < datasetName>42 dataset delete <?datasetName?> 35 43 dataset getvalue world <x> <y> <z> <datasetName> 36 44 dataset getvalue pixel <x> <y> <datasetName> 37 45 Use pixel for image camera mode 38 dataset opacity <val> < datasetName>39 dataset visible <bool> < datasetName>46 dataset opacity <val> <?datasetName?> 47 dataset visible <bool> <?datasetName?> 40 48 41 colormap add <colorMapName> <colorMap> <opacityMap> 42 colorMap = Tcl list of {value r g b} control points 43 opacityMap = Tcl list of {value alpha} control points 44 colormap delete <colorMapName> 49 pseudocolor add <?datasetName?> 50 pseudocolor colormap <colormapName> <?datasetName?> 51 pseudocolor delete <?datasetName?> 52 pseudocolor edges <bool> <?datasetName?> 53 pseudocolor lighting <bool> <?datasetName?> 54 pseudocolor linecolor <r> <g> <b> <?datasetName?> 55 pseudocolor linewidth <val> <?datasetName?> 56 pseudocolor opacity <val> <?datasetName?> 57 pseudocolor visible <bool> <?datasetName?> 45 58 46 legend <colormapName> <legendTitle> <width> <height> 47 Causes legend to be rendered and written back with labels and title 59 contour2d add numcontours <n> <?datasetName?> 60 contour2d add contourlist <list> <?datasetName?> 61 list = {isoval1 isoval2 isoval3...} 62 contour2d delete <?datasetName?> 63 contour2d lighting <bool> <?datasetName?> 64 contour2d linecolor <r> <g> <b> <?datasetName?> 65 contour2d linewidth <val> <?datasetName?> 66 contour2d opacity <val> <?datasetName?> 67 contour2d visible <bool> <?datasetName?> 48 68 49 pseudocolor add <datasetName> 50 pseudocolor colormap <colormapName> <datasetName> 51 pseudocolor delete <datasetName> 52 pseudocolor edges <bool> <datasetName> 53 pseudocolor linecolor <r> <g> <b> <datasetName> 54 pseudocolor linewidth <val> <datasetName> 55 pseudocolor visible <bool> <datasetName> 56 57 contour2d add numcontours <n> <datasetName> 58 contour2d add contourlist <list> <datasetName> 59 list = {isoval1 isoval2 isoval3...} 60 contour2d delete <datasetName> 61 contour2d linecolor <r> <g> <b> <datasetName> 62 contour2d linewidth <val> <datasetName> 63 contour2d visible <bool> <datasetName> 64 65 polydata add <datasetName> 66 polydata color <r> <g> <b> <datasetName> 67 polydata delete <datasetName> 68 polydata edges <bool> <datasetName> 69 polydata linecolor <r> <g> <b> <datasetName> 70 polydata linewidth <val> <datasetName> 71 polydata visible <bool> <datasetName> 72 polydata wireframe <bool> <datasetName> 69 polydata add <?datasetName?> 70 polydata color <r> <g> <b> <?datasetName?> 71 polydata delete <?datasetName?> 72 polydata edges <bool> <?datasetName?> 73 polydata lighting <bool> <?datasetName?> 74 polydata linecolor <r> <g> <b> <?datasetName?> 75 polydata linewidth <val> <?datasetName?> 76 polydata opacity <val> <?datasetName?> 77 polydata visible <bool> <?datasetName?> 78 polydata wireframe <bool> <?datasetName?> 73 79 74 80 ================================================================================ -
branches/blt4/src/core/config.h.in
r2122 r2170 1 1 /* src/core/config.h.in. Generated from configure.in by autoheader. */ 2 3 /* Define if building universal (internal helper macro) */ 4 #undef AC_APPLE_UNIVERSAL_BUILD 2 5 3 6 /* Build rappture with ffmpeg widgets */ … … 97 100 #undef HAVE_MEMORY_H 98 101 99 /* Define to 1 if you have the <Python.h> header file. */100 #undef HAVE_PYTHON_H101 102 102 /* Define to 1 if you have the <sstream> header file. */ 103 103 #undef HAVE_SSTREAM … … 157 157 #undef PACKAGE_TARNAME 158 158 159 /* Define to the home page for this package. */ 160 #undef PACKAGE_URL 161 159 162 /* Define to the version of this package. */ 160 163 #undef PACKAGE_VERSION … … 175 178 #undef STDC_HEADERS 176 179 177 /* Define to 1 if your processor stores words with the most significant byte 178 first (like Motorola and SPARC, unlike Intel and VAX). */ 179 #undef WORDS_BIGENDIAN 180 /* Define WORDS_BIGENDIAN to 1 if your processor stores words with the most 181 significant byte first (like Motorola and SPARC, unlike Intel). */ 182 #if defined AC_APPLE_UNIVERSAL_BUILD 183 # if defined __BIG_ENDIAN__ 184 # define WORDS_BIGENDIAN 1 185 # endif 186 #else 187 # ifndef WORDS_BIGENDIAN 188 # undef WORDS_BIGENDIAN 189 # endif 190 #endif
Note: See TracChangeset
for help on using the changeset viewer.