Changeset 2742
- Timestamp:
- Dec 27, 2011 12:41:24 PM (11 years ago)
- Location:
- branches/blt4
- Files:
-
- 16 added
- 47 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/blt4/aclocal.m4
r2279 r2742 8 8 builtin(include,./cf/rpLangJava.m4) 9 9 builtin(include,./cf/rpLangMatlab.m4) 10 builtin(include,./cf/rpLangR.m4) -
branches/blt4/configure
r2714 r2742 609 609 TK_VERSION 610 610 TK_XLIBSW 611 TCL_SHLIB_LDFLAGS612 TCL_SHLIB_LD613 TCL_SHLIB_SUFFIX614 TCL_SHLIB_CFLAGS615 TCL_CFLAGS_DEBUG616 611 TK_LIB_SPEC 617 612 TK_INC_SPEC 618 613 TCL_VERSION 614 TCL_SHLIB_SUFFIX 615 TCL_SHLIB_LDFLAGS 616 TCL_SHLIB_LD 617 TCL_SHLIB_CFLAGS 618 TCL_CFLAGS_OPTIMIZE 619 TCL_CFLAGS_DEBUG 619 620 TCL_LIB_SPEC 620 621 TCL_INC_SPEC … … 673 674 SED 674 675 RUBY 676 R 675 677 JAVAH 676 678 JAVAC … … 785 787 with_tclsh 786 788 with_vtk 787 with_ncurses788 789 with_matlab 789 790 with_octave … … 793 794 with_python 794 795 with_java 796 with_R 795 797 with_ruby 796 798 enable_shared … … 1439 1441 --with-tclsh=DIR location of tclsh [default=yes] 1440 1442 --with-vtk=DIR location of vtk library [default=yes] 1441 --with-ncurses=DIR location of ncurses [default=yes]1442 1443 --with-matlab=DIR location of matlab and mex compiler [default=yes] 1443 1444 --with-octave=DIR path of default octave compiler `mkoctfile' … … 1448 1449 --with-python=DIR location of python [default=yes] 1449 1450 --with-java=DIR location of java [default=yes] 1451 --with-R=DIR location of R interpreter [default=yes] 1450 1452 --with-ruby=DIR location of ruby [default=yes] 1451 1453 … … 7445 7447 $as_echo "$VTKDIR" >&6; } 7446 7448 7447 with_ncurses="yes"7448 7449 # Check whether --with-ncurses was given.7450 if test "${with_ncurses+set}" = set; then :7451 withval=$with_ncurses;7452 else7453 with_ncurses=yes7454 fi7455 7456 7457 if test "$with_vtk" != "no" ; then7458 if test "$with_vtk" = "yes" ; then7459 for path in \7460 $libdir \7461 $prefix/lib \7462 $exec_prefix/lib \7463 /usr/lib7464 do7465 for vtk in $path/vtk-* ; do7466 if test -d "${vtk}" ; then7467 VTKDIR=${vtk}7468 fi7469 done7470 if test "x${VTKDIR}" != "x" ; then7471 break7472 fi7473 done7474 fi7475 fi7476 7477 7449 7478 7450 … … 8643 8615 done 8644 8616 fi 8617 8618 8619 8620 # Check whether --with-R was given. 8621 if test "${with_R+set}" = set; then : 8622 withval=$with_R; 8623 else 8624 with_R=yes 8625 fi 8626 8627 8628 R="" 8629 if test "$with_R" != "no" ; then 8630 if test "$with_R" = "yes" ; then 8631 # Extract the first word of "R", so it can be a program name with args. 8632 set dummy R; ac_word=$2 8633 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8634 $as_echo_n "checking for $ac_word... " >&6; } 8635 if ${ac_cv_path_R+:} false; then : 8636 $as_echo_n "(cached) " >&6 8637 else 8638 case $R in 8639 [\\/]* | ?:[\\/]*) 8640 ac_cv_path_R="$R" # Let the user override the test with a path. 8641 ;; 8642 *) 8643 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8644 for as_dir in $PATH 8645 do 8646 IFS=$as_save_IFS 8647 test -z "$as_dir" && as_dir=. 8648 for ac_exec_ext in '' $ac_executable_extensions; do 8649 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 8650 ac_cv_path_R="$as_dir/$ac_word$ac_exec_ext" 8651 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8652 break 2 8653 fi 8654 done 8655 done 8656 IFS=$as_save_IFS 8657 8658 ;; 8659 esac 8660 fi 8661 R=$ac_cv_path_R 8662 if test -n "$R"; then 8663 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $R" >&5 8664 $as_echo "$R" >&6; } 8665 else 8666 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8667 $as_echo "no" >&6; } 8668 fi 8669 8670 8671 else 8672 # Extract the first word of "R", so it can be a program name with args. 8673 set dummy R; ac_word=$2 8674 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8675 $as_echo_n "checking for $ac_word... " >&6; } 8676 if ${ac_cv_path_R+:} false; then : 8677 $as_echo_n "(cached) " >&6 8678 else 8679 case $R in 8680 [\\/]* | ?:[\\/]*) 8681 ac_cv_path_R="$R" # Let the user override the test with a path. 8682 ;; 8683 *) 8684 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8685 as_dummy="${with_R}/bin:${with_R}" 8686 for as_dir in $as_dummy 8687 do 8688 IFS=$as_save_IFS 8689 test -z "$as_dir" && as_dir=. 8690 for ac_exec_ext in '' $ac_executable_extensions; do 8691 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then 8692 ac_cv_path_R="$as_dir/$ac_word$ac_exec_ext" 8693 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8694 break 2 8695 fi 8696 done 8697 done 8698 IFS=$as_save_IFS 8699 8700 ;; 8701 esac 8702 fi 8703 R=$ac_cv_path_R 8704 if test -n "$R"; then 8705 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $R" >&5 8706 $as_echo "$R" >&6; } 8707 else 8708 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8709 $as_echo "no" >&6; } 8710 fi 8711 8712 8713 fi 8714 fi 8715 8645 8716 8646 8717 … … 9539 9610 #-------------------------------------------------------------------- 9540 9611 9541 for ac_header in ffmpeg/avcodec.h 9612 for ac_header in ffmpeg/avcodec.h libavcodec/avcodec.h ffmpeg/avformat.h libavformat/avformat.h ffmpeg/avutil.h libavutil/avutil.h 9542 9613 do : 9543 ac_fn_cxx_check_header_compile "$LINENO" "ffmpeg/avcodec.h" "ac_cv_header_ffmpeg_avcodec_h" "#define __STDC_CONSTANT_MACROS 1 9544 #ifdef HAVE_FFMPEG_AVCODEC_H 9545 # include <ffmpeg/avcodec.h> 9546 #endif 9614 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` 9615 ac_fn_cxx_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" " 9616 #define __STDC_CONSTANT_MACROS 1 9547 9617 9548 9618 " 9549 if test "x$ac_cv_header_ffmpeg_avcodec_h" = xyes; then :9619 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : 9550 9620 cat >>confdefs.h <<_ACEOF 9551 #define HAVE_FFMPEG_AVCODEC_H 1 9552 _ACEOF 9553 9554 fi 9555 9556 done 9557 9558 9559 for ac_header in libavcodec/avcodec.h 9560 do : 9561 ac_fn_cxx_check_header_compile "$LINENO" "libavcodec/avcodec.h" "ac_cv_header_libavcodec_avcodec_h" "#define __STDC_CONSTANT_MACROS 1 9562 #ifdef HAVE_LIBAVCODEC_AVCODEC_H 9563 # include <libavcodec/avcodec.h> 9564 #endif 9565 9566 " 9567 if test "x$ac_cv_header_libavcodec_avcodec_h" = xyes; then : 9568 cat >>confdefs.h <<_ACEOF 9569 #define HAVE_LIBAVCODEC_AVCODEC_H 1 9570 _ACEOF 9571 9572 fi 9573 9574 done 9575 9576 9577 for ac_header in ffmpeg/avformat.h 9578 do : 9579 ac_fn_cxx_check_header_compile "$LINENO" "ffmpeg/avformat.h" "ac_cv_header_ffmpeg_avformat_h" "#define __STDC_CONSTANT_MACROS 1 9580 #ifdef HAVE_FFMPEG_AVFORMAT_H 9581 # include <ffmpeg/avformat.h> 9582 #endif 9583 9584 " 9585 if test "x$ac_cv_header_ffmpeg_avformat_h" = xyes; then : 9586 cat >>confdefs.h <<_ACEOF 9587 #define HAVE_FFMPEG_AVFORMAT_H 1 9588 _ACEOF 9589 9590 fi 9591 9592 done 9593 9594 9595 for ac_header in libavformat/avformat.h 9596 do : 9597 ac_fn_cxx_check_header_compile "$LINENO" "libavformat/avformat.h" "ac_cv_header_libavformat_avformat_h" "#define __STDC_CONSTANT_MACROS 1 9598 #ifdef HAVE_LIBAVFORMAT_AVFORMAT_H 9599 # include <libavformat/avformat.h> 9600 #endif 9601 9602 " 9603 if test "x$ac_cv_header_libavformat_avformat_h" = xyes; then : 9604 cat >>confdefs.h <<_ACEOF 9605 #define HAVE_LIBAVFORMAT_AVFORMAT_H 1 9606 _ACEOF 9607 9608 fi 9609 9610 done 9611 9612 9613 for ac_header in ffmpeg/avutil.h 9614 do : 9615 ac_fn_cxx_check_header_compile "$LINENO" "ffmpeg/avutil.h" "ac_cv_header_ffmpeg_avutil_h" "#define __STDC_CONSTANT_MACROS 1 9616 #ifdef HAVE_FFMPEG_AVUTIL_H 9617 # include <ffmpeg/avutil.h> 9618 #endif 9619 9620 " 9621 if test "x$ac_cv_header_ffmpeg_avutil_h" = xyes; then : 9622 cat >>confdefs.h <<_ACEOF 9623 #define HAVE_FFMPEG_AVUTIL_H 1 9624 _ACEOF 9625 9626 fi 9627 9628 done 9629 9630 9631 for ac_header in libavutil/avutil.h 9632 do : 9633 ac_fn_cxx_check_header_compile "$LINENO" "libavutil/avutil.h" "ac_cv_header_libavutil_avutil_h" "#define __STDC_CONSTANT_MACROS 1 9634 #ifdef HAVE_LIBAVUTIL_AVUTIL_H 9635 # include <libavutil/avutil.h> 9636 #endif 9637 9638 " 9639 if test "x$ac_cv_header_libavutil_avutil_h" = xyes; then : 9640 cat >>confdefs.h <<_ACEOF 9641 #define HAVE_LIBAVUTIL_AVUTIL_H 1 9642 _ACEOF 9643 9644 fi 9645 9646 done 9647 9648 9649 for ac_header in ffmpeg/swscale.h 9650 do : 9651 ac_fn_cxx_check_header_compile "$LINENO" "ffmpeg/swscale.h" "ac_cv_header_ffmpeg_swscale_h" "#define __STDC_CONSTANT_MACROS 1 9652 #ifdef HAVE_FFMPEG_SWSCALE_H 9653 # include <ffmpeg/swscale.h> 9654 #endif 9655 9656 " 9657 if test "x$ac_cv_header_ffmpeg_swscale_h" = xyes; then : 9658 cat >>confdefs.h <<_ACEOF 9659 #define HAVE_FFMPEG_SWSCALE_H 1 9660 _ACEOF 9661 9662 fi 9663 9664 done 9665 9666 9667 for ac_header in libswscale/swscale.h 9668 do : 9669 ac_fn_cxx_check_header_compile "$LINENO" "libswscale/swscale.h" "ac_cv_header_libswscale_swscale_h" "#define __STDC_CONSTANT_MACROS 1 9670 #ifdef HAVE_LIBSWSCALE_SWSCALE_H 9671 # include <libswscale/swscale.h> 9672 #endif 9673 9674 " 9675 if test "x$ac_cv_header_libswscale_swscale_h" = xyes; then : 9676 cat >>confdefs.h <<_ACEOF 9677 #define HAVE_LIBSWSCALE_SWSCALE_H 1 9621 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 9678 9622 _ACEOF 9679 9623 … … 9698 9642 9699 9643 fi 9700 fi 9701 9702 for ac_func in img_convert 9644 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -lavcodec" >&5 9645 $as_echo_n "checking for main in -lavcodec... " >&6; } 9646 if ${ac_cv_lib_avcodec_main+:} false; then : 9647 $as_echo_n "(cached) " >&6 9648 else 9649 ac_check_lib_save_LIBS=$LIBS 9650 LIBS="-lavcodec $LIBS" 9651 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 9652 /* end confdefs.h. */ 9653 9654 9655 int 9656 main () 9657 { 9658 return main (); 9659 ; 9660 return 0; 9661 } 9662 _ACEOF 9663 if ac_fn_cxx_try_link "$LINENO"; then : 9664 ac_cv_lib_avcodec_main=yes 9665 else 9666 ac_cv_lib_avcodec_main=no 9667 fi 9668 rm -f core conftest.err conftest.$ac_objext \ 9669 conftest$ac_exeext conftest.$ac_ext 9670 LIBS=$ac_check_lib_save_LIBS 9671 fi 9672 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_avcodec_main" >&5 9673 $as_echo "$ac_cv_lib_avcodec_main" >&6; } 9674 if test "x$ac_cv_lib_avcodec_main" = xyes; then : 9675 cat >>confdefs.h <<_ACEOF 9676 #define HAVE_LIBAVCODEC 1 9677 _ACEOF 9678 9679 LIBS="-lavcodec $LIBS" 9680 9681 else 9682 as_fn_error $? "librappture requires libavcodec" "$LINENO" 5 9683 fi 9684 9685 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -lavutil" >&5 9686 $as_echo_n "checking for main in -lavutil... " >&6; } 9687 if ${ac_cv_lib_avutil_main+:} false; then : 9688 $as_echo_n "(cached) " >&6 9689 else 9690 ac_check_lib_save_LIBS=$LIBS 9691 LIBS="-lavutil $LIBS" 9692 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 9693 /* end confdefs.h. */ 9694 9695 9696 int 9697 main () 9698 { 9699 return main (); 9700 ; 9701 return 0; 9702 } 9703 _ACEOF 9704 if ac_fn_cxx_try_link "$LINENO"; then : 9705 ac_cv_lib_avutil_main=yes 9706 else 9707 ac_cv_lib_avutil_main=no 9708 fi 9709 rm -f core conftest.err conftest.$ac_objext \ 9710 conftest$ac_exeext conftest.$ac_ext 9711 LIBS=$ac_check_lib_save_LIBS 9712 fi 9713 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_avutil_main" >&5 9714 $as_echo "$ac_cv_lib_avutil_main" >&6; } 9715 if test "x$ac_cv_lib_avutil_main" = xyes; then : 9716 cat >>confdefs.h <<_ACEOF 9717 #define HAVE_LIBAVUTIL 1 9718 _ACEOF 9719 9720 LIBS="-lavutil $LIBS" 9721 9722 else 9723 as_fn_error $? "librappture requires libavutil" "$LINENO" 5 9724 fi 9725 9726 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -lavformat" >&5 9727 $as_echo_n "checking for main in -lavformat... " >&6; } 9728 if ${ac_cv_lib_avformat_main+:} false; then : 9729 $as_echo_n "(cached) " >&6 9730 else 9731 ac_check_lib_save_LIBS=$LIBS 9732 LIBS="-lavformat $LIBS" 9733 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 9734 /* end confdefs.h. */ 9735 9736 9737 int 9738 main () 9739 { 9740 return main (); 9741 ; 9742 return 0; 9743 } 9744 _ACEOF 9745 if ac_fn_cxx_try_link "$LINENO"; then : 9746 ac_cv_lib_avformat_main=yes 9747 else 9748 ac_cv_lib_avformat_main=no 9749 fi 9750 rm -f core conftest.err conftest.$ac_objext \ 9751 conftest$ac_exeext conftest.$ac_ext 9752 LIBS=$ac_check_lib_save_LIBS 9753 fi 9754 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_avformat_main" >&5 9755 $as_echo "$ac_cv_lib_avformat_main" >&6; } 9756 if test "x$ac_cv_lib_avformat_main" = xyes; then : 9757 cat >>confdefs.h <<_ACEOF 9758 #define HAVE_LIBAVFORMAT 1 9759 _ACEOF 9760 9761 LIBS="-lavformat $LIBS" 9762 9763 else 9764 as_fn_error $? "librappture requires libavformat" "$LINENO" 5 9765 fi 9766 9767 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -lswscale" >&5 9768 $as_echo_n "checking for main in -lswscale... " >&6; } 9769 if ${ac_cv_lib_swscale_main+:} false; then : 9770 $as_echo_n "(cached) " >&6 9771 else 9772 ac_check_lib_save_LIBS=$LIBS 9773 LIBS="-lswscale $LIBS" 9774 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 9775 /* end confdefs.h. */ 9776 9777 9778 int 9779 main () 9780 { 9781 return main (); 9782 ; 9783 return 0; 9784 } 9785 _ACEOF 9786 if ac_fn_cxx_try_link "$LINENO"; then : 9787 ac_cv_lib_swscale_main=yes 9788 else 9789 ac_cv_lib_swscale_main=no 9790 fi 9791 rm -f core conftest.err conftest.$ac_objext \ 9792 conftest$ac_exeext conftest.$ac_ext 9793 LIBS=$ac_check_lib_save_LIBS 9794 fi 9795 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_swscale_main" >&5 9796 $as_echo "$ac_cv_lib_swscale_main" >&6; } 9797 if test "x$ac_cv_lib_swscale_main" = xyes; then : 9798 cat >>confdefs.h <<_ACEOF 9799 #define HAVE_LIBSWSCALE 1 9800 _ACEOF 9801 9802 LIBS="-lswscale $LIBS" 9803 9804 fi 9805 9806 for ac_func in avcodec_decode_video2 9807 do : 9808 ac_fn_cxx_check_func "$LINENO" "avcodec_decode_video2" "ac_cv_func_avcodec_decode_video2" 9809 if test "x$ac_cv_func_avcodec_decode_video2" = xyes; then : 9810 cat >>confdefs.h <<_ACEOF 9811 #define HAVE_AVCODEC_DECODE_VIDEO2 1 9812 _ACEOF 9813 9814 fi 9815 done 9816 9817 for ac_func in avcodec_decode_video 9818 do : 9819 ac_fn_cxx_check_func "$LINENO" "avcodec_decode_video" "ac_cv_func_avcodec_decode_video" 9820 if test "x$ac_cv_func_avcodec_decode_video" = xyes; then : 9821 cat >>confdefs.h <<_ACEOF 9822 #define HAVE_AVCODEC_DECODE_VIDEO 1 9823 _ACEOF 9824 9825 fi 9826 done 9827 9828 for ac_func in avformat_open_input 9829 do : 9830 ac_fn_cxx_check_func "$LINENO" "avformat_open_input" "ac_cv_func_avformat_open_input" 9831 if test "x$ac_cv_func_avformat_open_input" = xyes; then : 9832 cat >>confdefs.h <<_ACEOF 9833 #define HAVE_AVFORMAT_OPEN_INPUT 1 9834 _ACEOF 9835 9836 fi 9837 done 9838 9839 for ac_func in av_open_input_file 9840 do : 9841 ac_fn_cxx_check_func "$LINENO" "av_open_input_file" "ac_cv_func_av_open_input_file" 9842 if test "x$ac_cv_func_av_open_input_file" = xyes; then : 9843 cat >>confdefs.h <<_ACEOF 9844 #define HAVE_AV_OPEN_INPUT_FILE 1 9845 _ACEOF 9846 9847 fi 9848 done 9849 9850 for ac_func in avio_close 9851 do : 9852 ac_fn_cxx_check_func "$LINENO" "avio_close" "ac_cv_func_avio_close" 9853 if test "x$ac_cv_func_avio_close" = xyes; then : 9854 cat >>confdefs.h <<_ACEOF 9855 #define HAVE_AVIO_CLOSE 1 9856 _ACEOF 9857 9858 fi 9859 done 9860 9861 for ac_func in url_close 9862 do : 9863 ac_fn_cxx_check_func "$LINENO" "url_close" "ac_cv_func_url_close" 9864 if test "x$ac_cv_func_url_close" = xyes; then : 9865 cat >>confdefs.h <<_ACEOF 9866 #define HAVE_URL_CLOSE 1 9867 _ACEOF 9868 9869 fi 9870 done 9871 9872 ac_fn_cxx_check_func "$LINENO" "av_find_stream_info" "ac_cv_func_av_find_stream_info" 9873 if test "x$ac_cv_func_av_find_stream_info" = xyes; then : 9874 9875 else 9876 as_fn_error $? "oops! no av_find_stream_info?!?" "$LINENO" 5 9877 fi 9878 9879 ac_fn_cxx_check_func "$LINENO" "avcodec_find_decoder" "ac_cv_func_avcodec_find_decoder" 9880 if test "x$ac_cv_func_avcodec_find_decoder" = xyes; then : 9881 9882 else 9883 as_fn_error $? "oops! no av_codec_find_decoder ?!?" "$LINENO" 5 9884 fi 9885 9886 ac_fn_cxx_check_func "$LINENO" "avcodec_open" "ac_cv_func_avcodec_open" 9887 if test "x$ac_cv_func_avcodec_open" = xyes; then : 9888 9889 else 9890 as_fn_error $? "oops! avcodec_open ?!?" "$LINENO" 5 9891 fi 9892 9893 ac_fn_cxx_check_func "$LINENO" "avcodec_alloc_frame" "ac_cv_func_avcodec_alloc_frame" 9894 if test "x$ac_cv_func_avcodec_alloc_frame" = xyes; then : 9895 9896 else 9897 as_fn_error $? "oops! no avcode_alloc_frame ?!?" "$LINENO" 5 9898 fi 9899 9900 ac_fn_cxx_check_func "$LINENO" "av_rescale_q" "ac_cv_func_av_rescale_q" 9901 if test "x$ac_cv_func_av_rescale_q" = xyes; then : 9902 9903 else 9904 as_fn_error $? "oops! no av_rescale_q ?!?" "$LINENO" 5 9905 fi 9906 9907 ac_fn_cxx_check_func "$LINENO" "av_read_frame" "ac_cv_func_av_read_frame" 9908 if test "x$ac_cv_func_av_read_frame" = xyes; then : 9909 9910 else 9911 as_fn_error $? "oops! av_read_frame ?!?" "$LINENO" 5 9912 fi 9913 9914 ac_fn_cxx_check_func "$LINENO" "av_free" "ac_cv_func_av_free" 9915 if test "x$ac_cv_func_av_free" = xyes; then : 9916 9917 else 9918 as_fn_error $? "oops! no av_frame ?!?" "$LINENO" 5 9919 fi 9920 9921 ac_fn_cxx_check_func "$LINENO" "avcodec_default_release_buffer" "ac_cv_func_avcodec_default_release_buffer" 9922 if test "x$ac_cv_func_avcodec_default_release_buffer" = xyes; then : 9923 9924 else 9925 as_fn_error $? "oops! no avcode_default_release_buffer ?!?" "$LINENO" 5 9926 fi 9927 9928 ac_fn_cxx_check_func "$LINENO" "avpicture_get_size" "ac_cv_func_avpicture_get_size" 9929 if test "x$ac_cv_func_avpicture_get_size" = xyes; then : 9930 9931 else 9932 as_fn_error $? "oops! no avpicture_get_size ?!?" "$LINENO" 5 9933 fi 9934 9935 ac_fn_cxx_check_func "$LINENO" "avpicture_fill" "ac_cv_func_avpicture_fill" 9936 if test "x$ac_cv_func_avpicture_fill" = xyes; then : 9937 9938 else 9939 as_fn_error $? "oops! no avpicture_fill ?!?" "$LINENO" 5 9940 fi 9941 9942 for ac_func in sws_getCachedContext 9943 do : 9944 ac_fn_cxx_check_func "$LINENO" "sws_getCachedContext" "ac_cv_func_sws_getCachedContext" 9945 if test "x$ac_cv_func_sws_getCachedContext" = xyes; then : 9946 cat >>confdefs.h <<_ACEOF 9947 #define HAVE_SWS_GETCACHEDCONTEXT 1 9948 _ACEOF 9949 9950 fi 9951 done 9952 9953 for ac_func in img_convert 9703 9954 do : 9704 9955 ac_fn_cxx_check_func "$LINENO" "img_convert" "ac_cv_func_img_convert" … … 9711 9962 done 9712 9963 9713 for ac_func in sws_scale9964 for ac_func in sws_scale 9714 9965 do : 9715 9966 ac_fn_cxx_check_func "$LINENO" "sws_scale" "ac_cv_func_sws_scale" … … 9722 9973 done 9723 9974 9975 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 9976 /* end confdefs.h. */ 9977 9978 #define __STDC_CONSTANT_MACROS 1 9979 #include <stdlib.h> 9980 #ifdef HAVE_FFMPEG_AVCODEC_H 9981 # include <ffmpeg/avcodec.h> 9982 #endif 9983 #ifdef HAVE_LIBAVCODEC_AVCODEC_H 9984 # include <libavcodec/avcodec.h> 9985 #endif 9986 int x = AVMEDIA_TYPE_VIDEO; 9987 9988 int 9989 main () 9990 { 9991 9992 ; 9993 return 0; 9994 } 9995 _ACEOF 9996 if ac_fn_cxx_try_compile "$LINENO"; then : 9997 ac_avmedia_type_video="yes" 9998 else 9999 ac_avmedia_type_video="no" 10000 fi 10001 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 10002 if test "$ac_avmedia_type_video" == "yes" ; then 10003 10004 $as_echo "#define HAVE_AVMEDIA_TYPE_VIDEO 1" >>confdefs.h 10005 10006 fi 10007 fi 9724 10008 9725 10009 … … 9801 10085 9802 10086 10087 10088 10089 10090 10091 10092 10093 9803 10094 ac_configure_args="--disable-threads --enable-shared" 9804 10095 … … 9807 10098 9808 10099 9809 ac_config_files="$ac_config_files Makefile packages/Makefile src/Makefile src/core/Makefile src/core2/Makefile src/objects/Makefile src/objects/RpHash.h gui/Makefile gui/apps/Makefile gui/apps/about gui/apps/encodedata gui/apps/rappture gui/apps/rappture-csh.env gui/apps/rappture.env gui/apps/rappture.use gui/apps/rerun gui/apps/simsim gui/apps/xmldiff gui/pkgIndex.tcl gui/scripts/Makefile gui/src/Makefile builder/Makefile builder/pkgIndex.tcl builder/scripts/Makefile tester/Makefile tester/pkgIndex.tcl tester/scripts/Makefile lang/Makefile lang/java/Makefile lang/java/rappture/Makefile lang/perl/Makefile lang/perl/Makefile.PL lang/python/Makefile lang/python/setup.py lang/matlab/Makefile lang/octave/Makefile lang/octave/octave2/Makefile lang/octave/octave3/Makefile lang/ ruby/Makefile lang/ruby/build.rb lang/tcl/Makefile lang/tcl/pkgIndex.tcl lang/tcl/src/Makefile lang/tcl/scripts/Makefile lang/tcl/tests/Makefile lib/Makefile examples/3D/Makefile examples/Makefile examples/app-fermi/2.0/Makefile examples/app-fermi/Makefile examples/app-fermi/cee/Makefile examples/app-fermi/fortran/Makefile examples/app-fermi/java/Makefile examples/app-fermi/matlab/Makefile examples/app-fermi/matlab/compiled/Makefile examples/app-fermi/matlab/uncompiled/Makefile examples/app-fermi/octave/octave2/Makefile examples/app-fermi/octave/octave3/Makefile examples/app-fermi/octave/Makefile examples/app-fermi/perl/Makefile examples/app-fermi/python/Makefile examples/app-fermi/ruby/Makefile examples/app-fermi/tcl/Makefile examples/app-fermi/wrapper/Makefile examples/app-fermi/wrapper/cee/Makefile examples/app-fermi/wrapper/perl/Makefile examples/app-fermi/wrapper/python/Makefile examples/app-fermi/wrapper/tcl/Makefile examples/c-example/Makefile examples/canvas/Makefile examples/demo.bash examples/flow/Makefile examples/flow/demo1/Makefile examples/flow/demo2/Makefile examples/flow/demo3/Makefile examples/graph/Makefile examples/objects/Makefile examples/objects/axis/Makefile examples/objects/contour/Makefile examples/objects/curve/Makefile examples/objects/dxWriter/Makefile examples/objects/floatBuffer/Makefile examples/objects/histogram/Makefile examples/objects/library/Makefile examples/objects/number/Makefile examples/objects/path/Makefile examples/objects/plot/Makefile examples/objects/scatter/Makefile examples/objects/string/Makefile examples/objects/tree/Makefile examples/objects/xmlparser/Makefile examples/zoo/Makefile examples/zoo/binary/Makefile examples/zoo/boolean/Makefile examples/zoo/choice/Makefile examples/zoo/cloud/Makefile examples/zoo/cloud/matlab/Makefile examples/zoo/curve/Makefile examples/zoo/datatable/Makefile examples/zoo/datatable/matlab/Makefile examples/zoo/enable/Makefile examples/zoo/field/Makefile examples/zoo/filechoice/Makefile examples/zoo/group/Makefile examples/zoo/histogram/Makefile examples/zoo/image/Makefile examples/zoo/image/docs/Makefile examples/zoo/image/examples/Makefile examples/zoo/integer/Makefile examples/zoo/integer2/Makefile examples/zoo/loader/Makefile examples/zoo/loader/examples/Makefile examples/zoo/loadrun/Makefile examples/zoo/log/Makefile examples/zoo/note/Makefile examples/zoo/note/docs/Makefile examples/zoo/number/Makefile examples/zoo/number2/Makefile examples/zoo/parallelepiped/Makefile examples/zoo/periodicelement/Makefile examples/zoo/phase/Makefile examples/zoo/sequence/Makefile examples/zoo/sequence/examples/Makefile examples/zoo/string/Makefile examples/zoo/structure/Makefile examples/zoo/structure/examples/Makefile examples/zoo/table/Makefile examples/zoo/unirect2d/Makefile oldtest/Makefile oldtest/src/Makefile"10100 ac_config_files="$ac_config_files Makefile packages/Makefile src/Makefile src/core/Makefile src/core2/Makefile src/objects/Makefile src/objects/RpHash.h gui/Makefile gui/apps/Makefile gui/apps/about gui/apps/encodedata gui/apps/rappture gui/apps/rappture-csh.env gui/apps/rappture.env gui/apps/rappture.use gui/apps/rerun gui/apps/simsim gui/apps/xmldiff gui/pkgIndex.tcl gui/scripts/Makefile gui/src/Makefile builder/Makefile builder/pkgIndex.tcl builder/scripts/Makefile tester/Makefile tester/pkgIndex.tcl tester/scripts/Makefile lang/Makefile lang/java/Makefile lang/java/rappture/Makefile lang/perl/Makefile lang/perl/Makefile.PL lang/python/Makefile lang/python/setup.py lang/matlab/Makefile lang/octave/Makefile lang/octave/octave2/Makefile lang/octave/octave3/Makefile lang/R/Makefile lang/ruby/Makefile lang/ruby/build.rb lang/tcl/Makefile lang/tcl/pkgIndex.tcl lang/tcl/src/Makefile lang/tcl/scripts/Makefile lang/tcl/tests/Makefile lib/Makefile examples/3D/Makefile examples/Makefile examples/app-fermi/2.0/Makefile examples/app-fermi/Makefile examples/app-fermi/cee/Makefile examples/app-fermi/fortran/Makefile examples/app-fermi/java/Makefile examples/app-fermi/matlab/Makefile examples/app-fermi/matlab/compiled/Makefile examples/app-fermi/matlab/uncompiled/Makefile examples/app-fermi/octave/octave2/Makefile examples/app-fermi/octave/octave3/Makefile examples/app-fermi/octave/Makefile examples/app-fermi/perl/Makefile examples/app-fermi/python/Makefile examples/app-fermi/ruby/Makefile examples/app-fermi/tcl/Makefile examples/app-fermi/wrapper/Makefile examples/app-fermi/wrapper/cee/Makefile examples/app-fermi/wrapper/perl/Makefile examples/app-fermi/wrapper/python/Makefile examples/app-fermi/wrapper/tcl/Makefile examples/app-fermi/R/Makefile examples/c-example/Makefile examples/canvas/Makefile examples/demo.bash examples/flow/Makefile examples/flow/demo1/Makefile examples/flow/demo2/Makefile examples/flow/demo3/Makefile examples/graph/Makefile examples/objects/Makefile examples/objects/axis/Makefile examples/objects/contour/Makefile examples/objects/curve/Makefile examples/objects/dxWriter/Makefile examples/objects/floatBuffer/Makefile examples/objects/histogram/Makefile examples/objects/library/Makefile examples/objects/number/Makefile examples/objects/path/Makefile examples/objects/plot/Makefile examples/objects/scatter/Makefile examples/objects/string/Makefile examples/objects/tree/Makefile examples/objects/xmlparser/Makefile examples/zoo/Makefile examples/zoo/binary/Makefile examples/zoo/boolean/Makefile examples/zoo/choice/Makefile examples/zoo/cloud/Makefile examples/zoo/cloud/matlab/Makefile examples/zoo/curve/Makefile examples/zoo/datatable/Makefile examples/zoo/datatable/matlab/Makefile examples/zoo/enable/Makefile examples/zoo/field/Makefile examples/zoo/filechoice/Makefile examples/zoo/group/Makefile examples/zoo/histogram/Makefile examples/zoo/image/Makefile examples/zoo/image/docs/Makefile examples/zoo/image/examples/Makefile examples/zoo/integer/Makefile examples/zoo/integer2/Makefile examples/zoo/loader/Makefile examples/zoo/loader/examples/Makefile examples/zoo/loadrun/Makefile examples/zoo/log/Makefile examples/zoo/note/Makefile examples/zoo/note/docs/Makefile examples/zoo/number/Makefile examples/zoo/number2/Makefile examples/zoo/parallelepiped/Makefile examples/zoo/periodicelement/Makefile examples/zoo/phase/Makefile examples/zoo/sequence/Makefile examples/zoo/sequence/examples/Makefile examples/zoo/string/Makefile examples/zoo/structure/Makefile examples/zoo/structure/examples/Makefile examples/zoo/table/Makefile examples/zoo/unirect2d/Makefile oldtest/Makefile oldtest/src/Makefile" 9810 10101 9811 10102 cat >confcache <<\_ACEOF … … 10553 10844 "lang/octave/octave2/Makefile") CONFIG_FILES="$CONFIG_FILES lang/octave/octave2/Makefile" ;; 10554 10845 "lang/octave/octave3/Makefile") CONFIG_FILES="$CONFIG_FILES lang/octave/octave3/Makefile" ;; 10846 "lang/R/Makefile") CONFIG_FILES="$CONFIG_FILES lang/R/Makefile" ;; 10555 10847 "lang/ruby/Makefile") CONFIG_FILES="$CONFIG_FILES lang/ruby/Makefile" ;; 10556 10848 "lang/ruby/build.rb") CONFIG_FILES="$CONFIG_FILES lang/ruby/build.rb" ;; … … 10583 10875 "examples/app-fermi/wrapper/python/Makefile") CONFIG_FILES="$CONFIG_FILES examples/app-fermi/wrapper/python/Makefile" ;; 10584 10876 "examples/app-fermi/wrapper/tcl/Makefile") CONFIG_FILES="$CONFIG_FILES examples/app-fermi/wrapper/tcl/Makefile" ;; 10877 "examples/app-fermi/R/Makefile") CONFIG_FILES="$CONFIG_FILES examples/app-fermi/R/Makefile" ;; 10585 10878 "examples/c-example/Makefile") CONFIG_FILES="$CONFIG_FILES examples/c-example/Makefile" ;; 10586 10879 "examples/canvas/Makefile") CONFIG_FILES="$CONFIG_FILES examples/canvas/Makefile" ;; -
branches/blt4/configure.in
r2716 r2742 166 166 fi 167 167 168 168 169 169 TCL_INC_SPEC="$TCL_INCLUDE_SPEC" 170 170 … … 200 200 AC_MSG_RESULT([$VTKDIR]) 201 201 202 with_ncurses="yes"203 AC_ARG_WITH(204 [ncurses],205 [AS_HELP_STRING([--with-ncurses[=DIR]],206 [location of ncurses @<:@default=yes@:>@])],207 [],208 [with_ncurses=yes])209 210 if test "$with_vtk" != "no" ; then211 if test "$with_vtk" = "yes" ; then212 for path in \213 $libdir \214 $prefix/lib \215 $exec_prefix/lib \216 /usr/lib217 do218 for vtk in $path/vtk-* ; do219 if test -d "${vtk}" ; then220 VTKDIR=${vtk}221 fi222 done223 if test "x${VTKDIR}" != "x" ; then224 break225 fi226 done227 fi228 fi229 230 202 RP_LANG_MATLAB 231 203 RP_LANG_OCTAVE … … 233 205 RP_LANG_PYTHON 234 206 RP_LANG_JAVA 207 RP_LANG_R 235 208 236 209 RUBY="" … … 313 286 #-------------------------------------------------------------------- 314 287 315 AC_CHECK_HEADERS(ffmpeg/avcodec.h,[],[], 316 [[#define __STDC_CONSTANT_MACROS 1 317 #ifdef HAVE_FFMPEG_AVCODEC_H 318 # include <ffmpeg/avcodec.h> 319 #endif 320 ]]) 321 322 AC_CHECK_HEADERS(libavcodec/avcodec.h,[],[], 323 [[#define __STDC_CONSTANT_MACROS 1 324 #ifdef HAVE_LIBAVCODEC_AVCODEC_H 325 # include <libavcodec/avcodec.h> 326 #endif 327 ]]) 328 329 AC_CHECK_HEADERS([ffmpeg/avformat.h],[],[], 330 [[#define __STDC_CONSTANT_MACROS 1 331 #ifdef HAVE_FFMPEG_AVFORMAT_H 332 # include <ffmpeg/avformat.h> 333 #endif 334 ]]) 335 336 AC_CHECK_HEADERS([libavformat/avformat.h],[],[], 337 [[#define __STDC_CONSTANT_MACROS 1 338 #ifdef HAVE_LIBAVFORMAT_AVFORMAT_H 339 # include <libavformat/avformat.h> 340 #endif 341 ]]) 342 343 AC_CHECK_HEADERS([ffmpeg/avutil.h],[],[], 344 [[#define __STDC_CONSTANT_MACROS 1 345 #ifdef HAVE_FFMPEG_AVUTIL_H 346 # include <ffmpeg/avutil.h> 347 #endif 348 ]]) 349 350 AC_CHECK_HEADERS([libavutil/avutil.h],[],[], 351 [[#define __STDC_CONSTANT_MACROS 1 352 #ifdef HAVE_LIBAVUTIL_AVUTIL_H 353 # include <libavutil/avutil.h> 354 #endif 355 ]]) 356 357 AC_CHECK_HEADERS([ffmpeg/swscale.h],[],[], 358 [[#define __STDC_CONSTANT_MACROS 1 359 #ifdef HAVE_FFMPEG_SWSCALE_H 360 # include <ffmpeg/swscale.h> 361 #endif 362 ]]) 363 364 AC_CHECK_HEADERS([libswscale/swscale.h],[],[], 365 [[#define __STDC_CONSTANT_MACROS 1 366 #ifdef HAVE_LIBSWSCALE_SWSCALE_H 367 # include <libswscale/swscale.h> 368 #endif 369 ]]) 288 AC_CHECK_HEADERS([ffmpeg/avcodec.h libavcodec/avcodec.h ffmpeg/avformat.h libavformat/avformat.h ffmpeg/avutil.h libavutil/avutil.h],,,[ 289 #define __STDC_CONSTANT_MACROS 1 290 ]) 370 291 371 292 HAVE_FFMPEG_LIBS="" … … 382 303 AC_DEFINE(BUILD_with_ffmpeg, 1, [Build rappture with ffmpeg widgets]) 383 304 fi 384 fi 385 386 AC_CHECK_FUNCS(img_convert) 387 AC_CHECK_FUNCS(sws_scale) 305 AC_CHECK_LIB(avcodec, main,,AC_MSG_ERROR(librappture requires libavcodec)) 306 AC_CHECK_LIB(avutil, main,,AC_MSG_ERROR(librappture requires libavutil)) 307 AC_CHECK_LIB(avformat, main,,AC_MSG_ERROR(librappture requires libavformat)) 308 AC_CHECK_LIB(swscale, main) 309 AC_CHECK_FUNCS(avcodec_decode_video2) 310 AC_CHECK_FUNCS(avcodec_decode_video) 311 AC_CHECK_FUNCS(avformat_open_input) 312 AC_CHECK_FUNCS(av_open_input_file) 313 AC_CHECK_FUNCS(avio_close) 314 AC_CHECK_FUNCS(url_close) 315 AC_CHECK_FUNC(av_find_stream_info,, 316 AC_MSG_ERROR(oops! no av_find_stream_info?!?)) 317 AC_CHECK_FUNC(avcodec_find_decoder,, 318 AC_MSG_ERROR(oops! no av_codec_find_decoder ?!?)) 319 AC_CHECK_FUNC(avcodec_open,,AC_MSG_ERROR(oops! avcodec_open ?!?)) 320 AC_CHECK_FUNC(avcodec_alloc_frame,, 321 AC_MSG_ERROR(oops! no avcode_alloc_frame ?!?)) 322 AC_CHECK_FUNC(av_rescale_q,,AC_MSG_ERROR(oops! no av_rescale_q ?!?)) 323 AC_CHECK_FUNC(av_read_frame,,AC_MSG_ERROR(oops! av_read_frame ?!?)) 324 AC_CHECK_FUNC(av_free,,AC_MSG_ERROR(oops! no av_frame ?!?)) 325 AC_CHECK_FUNC(avcodec_default_release_buffer,, 326 AC_MSG_ERROR(oops! no avcode_default_release_buffer ?!?)) 327 AC_CHECK_FUNC(avpicture_get_size,, 328 AC_MSG_ERROR(oops! no avpicture_get_size ?!?)) 329 AC_CHECK_FUNC(avpicture_fill,,AC_MSG_ERROR(oops! no avpicture_fill ?!?)) 330 AC_CHECK_FUNCS(sws_getCachedContext) 331 AC_CHECK_FUNCS(img_convert) 332 AC_CHECK_FUNCS(sws_scale) 333 AC_TRY_COMPILE([ 334 #define __STDC_CONSTANT_MACROS 1 335 #include <stdlib.h> 336 #ifdef HAVE_FFMPEG_AVCODEC_H 337 # include <ffmpeg/avcodec.h> 338 #endif 339 #ifdef HAVE_LIBAVCODEC_AVCODEC_H 340 # include <libavcodec/avcodec.h> 341 #endif 342 int x = AVMEDIA_TYPE_VIDEO; 343 ],, ac_avmedia_type_video="yes", ac_avmedia_type_video="no") 344 if test "$ac_avmedia_type_video" == "yes" ; then 345 AC_DEFINE(HAVE_AVMEDIA_TYPE_VIDEO,1,[Define if AVMEDIA_TYPE_VIDEO enum exists. ]) 346 fi 347 fi 388 348 389 349 AC_SUBST(CFLAGS_DEBUG) … … 434 394 AC_SUBST(PYTHON_SITE_PACKAGES) 435 395 AC_SUBST(PYTHON_VERSION) 396 AC_SUBST(R) 436 397 AC_SUBST(RP_BASE) 437 398 AC_SUBST(RUBY) … … 513 474 lang/octave/octave2/Makefile 514 475 lang/octave/octave3/Makefile 476 lang/R/Makefile 515 477 lang/ruby/Makefile 516 478 lang/ruby/build.rb … … 543 505 examples/app-fermi/wrapper/python/Makefile 544 506 examples/app-fermi/wrapper/tcl/Makefile 507 examples/app-fermi/R/Makefile 545 508 examples/c-example/Makefile 546 509 examples/canvas/Makefile -
branches/blt4/examples/app-fermi/Makefile.in
r2541 r2742 14 14 INSTALL_SCRIPT = ${INSTALL} -m 644 15 15 16 F77 = @F77@ 17 CC = @CC@ 18 CXX = @CXX@ 19 RUBY = @RUBY@ 20 PERL = @PERL@ 21 TCLSH = @TCLSH@ 22 PYTHON = @PYTHON@ 23 MEX = @MEX@ 24 MKOCTFILE2 = @MKOCTFILE2@ 25 MKOCTFILE3 = @MKOCTFILE3@ 26 OCTAVE = $(MKOCTFILE2) $(MKOCTFILE3) 27 JAVAC = @JAVAC@ 16 F77 = @F77@ 17 CC = @CC@ 18 CXX = @CXX@ 19 RUBY = @RUBY@ 20 PERL = @PERL@ 21 TCLSH = @TCLSH@ 22 PYTHON = @PYTHON@ 23 MEX = @MEX@ 24 MKOCTFILE2 = @MKOCTFILE2@ 25 MKOCTFILE3 = @MKOCTFILE3@ 26 OCTAVE = $(MKOCTFILE2) $(MKOCTFILE3) 27 JAVAC = @JAVAC@ 28 R = @R@ 28 29 29 30 .PHONY: tcl cee fortran octave matlab perl python ruby java 2.0 wrapper … … 51 52 LANGS += java 52 53 endif 54 ifneq ($(R),) 55 LANGS += R 56 endif 53 57 54 58 all: -
branches/blt4/gui/apps/Makefile.in
r2704 r2742 28 28 $(srcdir)/vtkstreamlines-test \ 29 29 $(srcdir)/vtkviewer-test \ 30 $(srcdir)/vtkvolume-test \ 30 31 $(srcdir)/flowvis-test \ 31 32 $(srcdir)/rpdiff \ … … 56 57 57 58 distclean: clean 58 $(RM) encodedata rappture.env rappture rappture.use rerun rpdiffsimsim xmldiff59 $(RM) encodedata rappture.env rappture rappture.use rerun simsim xmldiff 59 60 $(RM) Makefile *~ 60 61 -
branches/blt4/gui/apps/rappture.use.in
r1988 r2742 35 35 prepend TK_LIBRARY ${libdir}/tk${tcl_version} 36 36 37 prepend R_LIBS ${libdir}/R 38 37 39 tags DEVEL -
branches/blt4/gui/apps/vtkcontour-test
r2536 r2742 244 244 if {"" != $file && [catch { 245 245 set fid [open $file r] 246 fconfigure $fid -translation binary 246 fconfigure $fid -translation binary -encoding binary 247 247 set info [read $fid] 248 248 close $fid -
branches/blt4/gui/apps/vtkstreamlines-test
r2536 r2742 122 122 if {"" != $file && [catch { 123 123 set fid [open $file r] 124 fconfigure $fid -translation binary 124 fconfigure $fid -translation binary -encoding binary 125 125 set info [read $fid] 126 126 close $fid … … 143 143 if {"" != $file && [catch { 144 144 set fid [open $file r] 145 fconfigure $fid -translation binary 145 fconfigure $fid -translation binary -encoding binary 146 146 set info [read $fid] 147 147 close $fid … … 164 164 if {"" != $file && [catch { 165 165 set fid [open $file r] 166 fconfigure $fid -translation binary 166 fconfigure $fid -translation binary -encoding binary 167 167 set info [read $fid] 168 168 close $fid -
branches/blt4/gui/apps/vtkviewer-test
r2536 r2742 90 90 return $_data 91 91 } 92 public method vtkdata {args} { 93 return $_data 94 } 92 95 public method values {args} { 93 96 return $_data … … 116 119 if {"" != $file && [catch { 117 120 set fid [open $file r] 118 fconfigure $fid -translation binary 121 fconfigure $fid -translation binary -encoding binary 119 122 set info [read $fid] 120 123 close $fid … … 137 140 if {"" != $file && [catch { 138 141 set fid [open $file r] 139 fconfigure $fid -translation binary 142 fconfigure $fid -translation binary -encoding binary 140 143 set info [read $fid] 141 144 close $fid -
branches/blt4/gui/cf/config.guess
r2706 r2742 2 2 # Attempt to guess a canonical system name. 3 3 # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 4 # 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 5 # Free Software Foundation, Inc. 6 7 timestamp='2008-04-14' 4 # 2000, 2001, 2002, 2003 Free Software Foundation, Inc. 5 6 timestamp='2003-02-22' 8 7 9 8 # This file is free software; you can redistribute it and/or modify it … … 19 18 # You should have received a copy of the GNU General Public License 20 19 # along with this program; if not, write to the Free Software 21 # Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA 22 # 02110-1301, USA. 20 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. 23 21 # 24 22 # As a special exception to the GNU General Public License, if you … … 26 24 # configuration script generated by Autoconf, you may include it under 27 25 # the same distribution terms that you use for the rest of that program. 28 29 26 30 27 # Originally written by Per Bothner <per@bothner.com>. … … 57 54 58 55 Originally written by Per Bothner. 59 Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001 ,60 2002, 2003, 2004, 2005, 2006, 2007, 2008Free Software Foundation, Inc.56 Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001 57 Free Software Foundation, Inc. 61 58 62 59 This is free software; see the source for copying conditions. There is NO … … 70 67 case $1 in 71 68 --time-stamp | --time* | -t ) 72 echo "$timestamp" ; exit ;;69 echo "$timestamp" ; exit 0 ;; 73 70 --version | -v ) 74 echo "$version" ; exit ;;71 echo "$version" ; exit 0 ;; 75 72 --help | --h* | -h ) 76 echo "$usage"; exit ;;73 echo "$usage"; exit 0 ;; 77 74 -- ) # Stop option processing 78 75 shift; break ;; … … 108 105 trap "rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null; exit 1" 1 2 13 15 ; 109 106 : ${TMPDIR=/tmp} ; 110 { tmp=`(umask 077 && mktemp -d "$TMPDIR/cgXXXXXX") 2>/dev/null` && test -n "$tmp" && test -d "$tmp" ; } ||107 { tmp=`(umask 077 && mktemp -d -q "$TMPDIR/cgXXXXXX") 2>/dev/null` && test -n "$tmp" && test -d "$tmp" ; } || 111 108 { test -n "$RANDOM" && tmp=$TMPDIR/cg$$-$RANDOM && (umask 077 && mkdir $tmp) ; } || 112 { tmp=$TMPDIR/cg-$$ && (umask 077 && mkdir $tmp) && echo "Warning: creating insecure temp directory" >&2 ; } ||113 109 { echo "$me: cannot create a temporary directory in $TMPDIR" >&2 ; exit 1 ; } ; 114 110 dummy=$tmp/dummy ; … … 127 123 ,,*) CC_FOR_BUILD=$CC ;; 128 124 ,*,*) CC_FOR_BUILD=$HOST_CC ;; 129 esac ; set_cc_for_build= ;'125 esac ;' 130 126 131 127 # This is needed to find uname on a Pyramid OSx when run in the BSD universe. … … 162 158 sh3el) machine=shl-unknown ;; 163 159 sh3eb) machine=sh-unknown ;; 164 sh5el) machine=sh5le-unknown ;;165 160 *) machine=${UNAME_MACHINE_ARCH}-unknown ;; 166 161 esac … … 201 196 # CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM is used. 202 197 echo "${machine}-${os}${release}" 203 exit ;; 198 exit 0 ;; 199 amiga:OpenBSD:*:*) 200 echo m68k-unknown-openbsd${UNAME_RELEASE} 201 exit 0 ;; 202 arc:OpenBSD:*:*) 203 echo mipsel-unknown-openbsd${UNAME_RELEASE} 204 exit 0 ;; 205 hp300:OpenBSD:*:*) 206 echo m68k-unknown-openbsd${UNAME_RELEASE} 207 exit 0 ;; 208 mac68k:OpenBSD:*:*) 209 echo m68k-unknown-openbsd${UNAME_RELEASE} 210 exit 0 ;; 211 macppc:OpenBSD:*:*) 212 echo powerpc-unknown-openbsd${UNAME_RELEASE} 213 exit 0 ;; 214 mvme68k:OpenBSD:*:*) 215 echo m68k-unknown-openbsd${UNAME_RELEASE} 216 exit 0 ;; 217 mvme88k:OpenBSD:*:*) 218 echo m88k-unknown-openbsd${UNAME_RELEASE} 219 exit 0 ;; 220 mvmeppc:OpenBSD:*:*) 221 echo powerpc-unknown-openbsd${UNAME_RELEASE} 222 exit 0 ;; 223 pmax:OpenBSD:*:*) 224 echo mipsel-unknown-openbsd${UNAME_RELEASE} 225 exit 0 ;; 226 sgi:OpenBSD:*:*) 227 echo mipseb-unknown-openbsd${UNAME_RELEASE} 228 exit 0 ;; 229 sun3:OpenBSD:*:*) 230 echo m68k-unknown-openbsd${UNAME_RELEASE} 231 exit 0 ;; 232 wgrisc:OpenBSD:*:*) 233 echo mipsel-unknown-openbsd${UNAME_RELEASE} 234 exit 0 ;; 204 235 *:OpenBSD:*:*) 205 UNAME_MACHINE_ARCH=`arch | sed 's/OpenBSD.//'` 206 echo ${UNAME_MACHINE_ARCH}-unknown-openbsd${UNAME_RELEASE} 207 exit ;; 208 *:ekkoBSD:*:*) 209 echo ${UNAME_MACHINE}-unknown-ekkobsd${UNAME_RELEASE} 210 exit ;; 211 *:SolidBSD:*:*) 212 echo ${UNAME_MACHINE}-unknown-solidbsd${UNAME_RELEASE} 213 exit ;; 214 macppc:MirBSD:*:*) 215 echo powerpc-unknown-mirbsd${UNAME_RELEASE} 216 exit ;; 217 *:MirBSD:*:*) 218 echo ${UNAME_MACHINE}-unknown-mirbsd${UNAME_RELEASE} 219 exit ;; 236 echo ${UNAME_MACHINE}-unknown-openbsd${UNAME_RELEASE} 237 exit 0 ;; 220 238 alpha:OSF1:*:*) 221 case $UNAME_RELEASE in 222 *4.0) 239 if test $UNAME_RELEASE = "V4.0"; then 223 240 UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $3}'` 224 ;; 225 *5.*) 226 UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $4}'` 227 ;; 228 esac 241 fi 229 242 # According to Compaq, /usr/sbin/psrinfo has been available on 230 243 # OSF/1 and Tru64 systems produced since 1995. I hope that … … 264 277 UNAME_MACHINE="alphaev79" ;; 265 278 esac 266 # A Pn.n version is a patched version.267 279 # A Vn.n version is a released version. 268 280 # A Tn.n version is a released field test version. 269 281 # A Xn.n version is an unreleased experimental baselevel. 270 282 # 1.2 uses "1.2" for uname -r. 271 echo ${UNAME_MACHINE}-dec-osf`echo ${UNAME_RELEASE} | sed -e 's/^[ PVTX]//' | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`272 exit ;;283 echo ${UNAME_MACHINE}-dec-osf`echo ${UNAME_RELEASE} | sed -e 's/^[VTX]//' | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 284 exit 0 ;; 273 285 Alpha\ *:Windows_NT*:*) 274 286 # How do we know it's Interix rather than the generic POSIX subsystem? … … 276 288 # of the specific Alpha model? 277 289 echo alpha-pc-interix 278 exit ;;290 exit 0 ;; 279 291 21064:Windows_NT:50:3) 280 292 echo alpha-dec-winnt3.5 281 exit ;;293 exit 0 ;; 282 294 Amiga*:UNIX_System_V:4.0:*) 283 295 echo m68k-unknown-sysv4 284 exit ;;296 exit 0;; 285 297 *:[Aa]miga[Oo][Ss]:*:*) 286 298 echo ${UNAME_MACHINE}-unknown-amigaos 287 exit ;;299 exit 0 ;; 288 300 *:[Mm]orph[Oo][Ss]:*:*) 289 301 echo ${UNAME_MACHINE}-unknown-morphos 290 exit ;;302 exit 0 ;; 291 303 *:OS/390:*:*) 292 304 echo i370-ibm-openedition 293 exit ;; 294 *:z/VM:*:*) 295 echo s390-ibm-zvmoe 296 exit ;; 297 *:OS400:*:*) 298 echo powerpc-ibm-os400 299 exit ;; 305 exit 0 ;; 300 306 arm:RISC*:1.[012]*:*|arm:riscix:1.[012]*:*) 301 307 echo arm-acorn-riscix${UNAME_RELEASE} 302 exit ;; 303 arm:riscos:*:*|arm:RISCOS:*:*) 304 echo arm-unknown-riscos 305 exit ;; 308 exit 0;; 306 309 SR2?01:HI-UX/MPP:*:* | SR8000:HI-UX/MPP:*:*) 307 310 echo hppa1.1-hitachi-hiuxmpp 308 exit ;;311 exit 0;; 309 312 Pyramid*:OSx*:*:* | MIS*:OSx*:*:* | MIS*:SMP_DC-OSx*:*:*) 310 313 # akee@wpdis03.wpafb.af.mil (Earle F. Ake) contributed MIS and NILE. … … 314 317 echo pyramid-pyramid-bsd 315 318 fi 316 exit ;;319 exit 0 ;; 317 320 NILE*:*:*:dcosx) 318 321 echo pyramid-pyramid-svr4 319 exit ;; 320 DRS?6000:unix:4.0:6*) 321 echo sparc-icl-nx6 322 exit ;; 323 DRS?6000:UNIX_SV:4.2*:7* | DRS?6000:isis:4.2*:7*) 322 exit 0 ;; 323 DRS?6000:UNIX_SV:4.2*:7*) 324 324 case `/usr/bin/uname -p` in 325 sparc) echo sparc-icl-nx7 ; exit;;325 sparc) echo sparc-icl-nx7 && exit 0 ;; 326 326 esac ;; 327 327 sun4H:SunOS:5.*:*) 328 328 echo sparc-hal-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` 329 exit ;;329 exit 0 ;; 330 330 sun4*:SunOS:5.*:* | tadpole*:SunOS:5.*:*) 331 331 echo sparc-sun-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` 332 exit ;;333 i86pc:SunOS:5.*:* | i86xen:SunOS:5.*:*)332 exit 0 ;; 333 i86pc:SunOS:5.*:*) 334 334 echo i386-pc-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` 335 exit ;;335 exit 0 ;; 336 336 sun4*:SunOS:6*:*) 337 337 # According to config.sub, this is the proper way to canonicalize … … 339 339 # it's likely to be more like Solaris than SunOS4. 340 340 echo sparc-sun-solaris3`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` 341 exit ;;341 exit 0 ;; 342 342 sun4*:SunOS:*:*) 343 343 case "`/usr/bin/arch -k`" in … … 348 348 # Japanese Language versions have a version number like `4.1.3-JL'. 349 349 echo sparc-sun-sunos`echo ${UNAME_RELEASE}|sed -e 's/-/_/'` 350 exit ;;350 exit 0 ;; 351 351 sun3*:SunOS:*:*) 352 352 echo m68k-sun-sunos${UNAME_RELEASE} 353 exit ;;353 exit 0 ;; 354 354 sun*:*:4.2BSD:*) 355 355 UNAME_RELEASE=`(sed 1q /etc/motd | awk '{print substr($5,1,3)}') 2>/dev/null` … … 363 363 ;; 364 364 esac 365 exit ;;365 exit 0 ;; 366 366 aushp:SunOS:*:*) 367 367 echo sparc-auspex-sunos${UNAME_RELEASE} 368 exit ;;368 exit 0 ;; 369 369 # The situation for MiNT is a little confusing. The machine name 370 370 # can be virtually everything (everything which is not … … 377 377 atarist[e]:*MiNT:*:* | atarist[e]:*mint:*:* | atarist[e]:*TOS:*:*) 378 378 echo m68k-atari-mint${UNAME_RELEASE} 379 exit ;;379 exit 0 ;; 380 380 atari*:*MiNT:*:* | atari*:*mint:*:* | atarist[e]:*TOS:*:*) 381 381 echo m68k-atari-mint${UNAME_RELEASE} 382 exit ;;382 exit 0 ;; 383 383 *falcon*:*MiNT:*:* | *falcon*:*mint:*:* | *falcon*:*TOS:*:*) 384 384 echo m68k-atari-mint${UNAME_RELEASE} 385 exit ;;385 exit 0 ;; 386 386 milan*:*MiNT:*:* | milan*:*mint:*:* | *milan*:*TOS:*:*) 387 387 echo m68k-milan-mint${UNAME_RELEASE} 388 exit ;;388 exit 0 ;; 389 389 hades*:*MiNT:*:* | hades*:*mint:*:* | *hades*:*TOS:*:*) 390 390 echo m68k-hades-mint${UNAME_RELEASE} 391 exit ;;391 exit 0 ;; 392 392 *:*MiNT:*:* | *:*mint:*:* | *:*TOS:*:*) 393 393 echo m68k-unknown-mint${UNAME_RELEASE} 394 exit ;; 395 m68k:machten:*:*) 396 echo m68k-apple-machten${UNAME_RELEASE} 397 exit ;; 394 exit 0 ;; 398 395 powerpc:machten:*:*) 399 396 echo powerpc-apple-machten${UNAME_RELEASE} 400 exit ;;397 exit 0 ;; 401 398 RISC*:Mach:*:*) 402 399 echo mips-dec-mach_bsd4.3 403 exit ;;400 exit 0 ;; 404 401 RISC*:ULTRIX:*:*) 405 402 echo mips-dec-ultrix${UNAME_RELEASE} 406 exit ;;403 exit 0 ;; 407 404 VAX*:ULTRIX*:*:*) 408 405 echo vax-dec-ultrix${UNAME_RELEASE} 409 exit ;;406 exit 0 ;; 410 407 2020:CLIX:*:* | 2430:CLIX:*:*) 411 408 echo clipper-intergraph-clix${UNAME_RELEASE} 412 exit ;;409 exit 0 ;; 413 410 mips:*:*:UMIPS | mips:*:*:RISCos) 414 411 eval $set_cc_for_build … … 434 431 } 435 432 EOF 436 $CC_FOR_BUILD -o $dummy $dummy.c && 437 dummyarg=`echo "${UNAME_RELEASE}" | sed -n 's/\([0-9]*\).*/\1/p'` && 438 SYSTEM_NAME=`$dummy $dummyarg` && 439 { echo "$SYSTEM_NAME"; exit; } 433 $CC_FOR_BUILD -o $dummy $dummy.c \ 434 && $dummy `echo "${UNAME_RELEASE}" | sed -n 's/\([0-9]*\).*/\1/p'` \ 435 && exit 0 440 436 echo mips-mips-riscos${UNAME_RELEASE} 441 exit ;;437 exit 0 ;; 442 438 Motorola:PowerMAX_OS:*:*) 443 439 echo powerpc-motorola-powermax 444 exit ;;440 exit 0 ;; 445 441 Motorola:*:4.3:PL8-*) 446 442 echo powerpc-harris-powermax 447 exit ;;443 exit 0 ;; 448 444 Night_Hawk:*:*:PowerMAX_OS | Synergy:PowerMAX_OS:*:*) 449 445 echo powerpc-harris-powermax 450 exit ;;446 exit 0 ;; 451 447 Night_Hawk:Power_UNIX:*:*) 452 448 echo powerpc-harris-powerunix 453 exit ;;449 exit 0 ;; 454 450 m88k:CX/UX:7*:*) 455 451 echo m88k-harris-cxux7 456 exit ;;452 exit 0 ;; 457 453 m88k:*:4*:R4*) 458 454 echo m88k-motorola-sysv4 459 exit ;;455 exit 0 ;; 460 456 m88k:*:3*:R3*) 461 457 echo m88k-motorola-sysv3 462 exit ;;458 exit 0 ;; 463 459 AViiON:dgux:*:*) 464 460 # DG/UX returns AViiON for all architectures … … 476 472 echo i586-dg-dgux${UNAME_RELEASE} 477 473 fi 478 exit ;;474 exit 0 ;; 479 475 M88*:DolphinOS:*:*) # DolphinOS (SVR3) 480 476 echo m88k-dolphin-sysv3 481 exit ;;477 exit 0 ;; 482 478 M88*:*:R3*:*) 483 479 # Delta 88k system running SVR3 484 480 echo m88k-motorola-sysv3 485 exit ;;481 exit 0 ;; 486 482 XD88*:*:*:*) # Tektronix XD88 system running UTekV (SVR3) 487 483 echo m88k-tektronix-sysv3 488 exit ;;484 exit 0 ;; 489 485 Tek43[0-9][0-9]:UTek:*:*) # Tektronix 4300 system running UTek (BSD) 490 486 echo m68k-tektronix-bsd 491 exit ;;487 exit 0 ;; 492 488 *:IRIX*:*:*) 493 489 echo mips-sgi-irix`echo ${UNAME_RELEASE}|sed -e 's/-/_/g'` 494 exit ;;490 exit 0 ;; 495 491 ????????:AIX?:[12].1:2) # AIX 2.2.1 or AIX 2.1.1 is RT/PC AIX. 496 echo romp-ibm-aix # uname -m gives an 8 hex-code CPU id497 exit ;;# Note that: echo "'`uname -s`'" gives 'AIX '492 echo romp-ibm-aix # uname -m gives an 8 hex-code CPU id 493 exit 0 ;; # Note that: echo "'`uname -s`'" gives 'AIX ' 498 494 i*86:AIX:*:*) 499 495 echo i386-ibm-aix 500 exit ;;496 exit 0 ;; 501 497 ia64:AIX:*:*) 502 498 if [ -x /usr/bin/oslevel ] ; then … … 506 502 fi 507 503 echo ${UNAME_MACHINE}-ibm-aix${IBM_REV} 508 exit ;;504 exit 0 ;; 509 505 *:AIX:2:3) 510 506 if grep bos325 /usr/include/stdio.h >/dev/null 2>&1; then … … 521 517 } 522 518 EOF 523 if $CC_FOR_BUILD -o $dummy $dummy.c && SYSTEM_NAME=`$dummy` 524 then 525 echo "$SYSTEM_NAME" 526 else 527 echo rs6000-ibm-aix3.2.5 528 fi 519 $CC_FOR_BUILD -o $dummy $dummy.c && $dummy && exit 0 520 echo rs6000-ibm-aix3.2.5 529 521 elif grep bos324 /usr/include/stdio.h >/dev/null 2>&1; then 530 522 echo rs6000-ibm-aix3.2.4 … … 532 524 echo rs6000-ibm-aix3.2 533 525 fi 534 exit ;;535 *:AIX:*:[45 6])526 exit 0 ;; 527 *:AIX:*:[45]) 536 528 IBM_CPU_ID=`/usr/sbin/lsdev -C -c processor -S available | sed 1q | awk '{ print $1 }'` 537 529 if /usr/sbin/lsattr -El ${IBM_CPU_ID} | grep ' POWER' >/dev/null 2>&1; then … … 546 538 fi 547 539 echo ${IBM_ARCH}-ibm-aix${IBM_REV} 548 exit ;;540 exit 0 ;; 549 541 *:AIX:*:*) 550 542 echo rs6000-ibm-aix 551 exit ;;543 exit 0 ;; 552 544 ibmrt:4.4BSD:*|romp-ibm:BSD:*) 553 545 echo romp-ibm-bsd4.4 554 exit ;;546 exit 0 ;; 555 547 ibmrt:*BSD:*|romp-ibm:BSD:*) # covers RT/PC BSD and 556 548 echo romp-ibm-bsd${UNAME_RELEASE} # 4.3 with uname added to 557 exit ;;# report: romp-ibm BSD 4.3549 exit 0 ;; # report: romp-ibm BSD 4.3 558 550 *:BOSX:*:*) 559 551 echo rs6000-bull-bosx 560 exit ;;552 exit 0 ;; 561 553 DPX/2?00:B.O.S.:*:*) 562 554 echo m68k-bull-sysv3 563 exit ;;555 exit 0 ;; 564 556 9000/[34]??:4.3bsd:1.*:*) 565 557 echo m68k-hp-bsd 566 exit ;;558 exit 0 ;; 567 559 hp300:4.4BSD:*:* | 9000/[34]??:4.3bsd:2.*:*) 568 560 echo m68k-hp-bsd4.4 569 exit ;;561 exit 0 ;; 570 562 9000/[34678]??:HP-UX:*:*) 571 563 HPUX_REV=`echo ${UNAME_RELEASE}|sed -e 's/[^.]*.[0B]*//'` … … 629 621 if [ ${HP_ARCH} = "hppa2.0w" ] 630 622 then 631 eval $set_cc_for_build 632 633 # hppa2.0w-hp-hpux* has a 64-bit kernel and a compiler generating 634 # 32-bit code. hppa64-hp-hpux* has the same kernel and a compiler 635 # generating 64-bit code. GNU and HP use different nomenclature: 636 # 637 # $ CC_FOR_BUILD=cc ./config.guess 638 # => hppa2.0w-hp-hpux11.23 639 # $ CC_FOR_BUILD="cc +DA2.0w" ./config.guess 640 # => hppa64-hp-hpux11.23 641 642 if echo __LP64__ | (CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) | 643 grep __LP64__ >/dev/null 623 # avoid double evaluation of $set_cc_for_build 624 test -n "$CC_FOR_BUILD" || eval $set_cc_for_build 625 if echo __LP64__ | (CCOPTS= $CC_FOR_BUILD -E -) | grep __LP64__ >/dev/null 644 626 then 645 627 HP_ARCH="hppa2.0w" … … 649 631 fi 650 632 echo ${HP_ARCH}-hp-hpux${HPUX_REV} 651 exit ;;633 exit 0 ;; 652 634 ia64:HP-UX:*:*) 653 635 HPUX_REV=`echo ${UNAME_RELEASE}|sed -e 's/[^.]*.[0B]*//'` 654 636 echo ia64-hp-hpux${HPUX_REV} 655 exit ;;637 exit 0 ;; 656 638 3050*:HI-UX:*:*) 657 639 eval $set_cc_for_build … … 681 663 } 682 664 EOF 683 $CC_FOR_BUILD -o $dummy $dummy.c && SYSTEM_NAME=`$dummy` && 684 { echo "$SYSTEM_NAME"; exit; } 665 $CC_FOR_BUILD -o $dummy $dummy.c && $dummy && exit 0 685 666 echo unknown-hitachi-hiuxwe2 686 exit ;;667 exit 0 ;; 687 668 9000/7??:4.3bsd:*:* | 9000/8?[79]:4.3bsd:*:* ) 688 669 echo hppa1.1-hp-bsd 689 exit ;;670 exit 0 ;; 690 671 9000/8??:4.3bsd:*:*) 691 672 echo hppa1.0-hp-bsd 692 exit ;;673 exit 0 ;; 693 674 *9??*:MPE/iX:*:* | *3000*:MPE/iX:*:*) 694 675 echo hppa1.0-hp-mpeix 695 exit ;;676 exit 0 ;; 696 677 hp7??:OSF1:*:* | hp8?[79]:OSF1:*:* ) 697 678 echo hppa1.1-hp-osf 698 exit ;;679 exit 0 ;; 699 680 hp8??:OSF1:*:*) 700 681 echo hppa1.0-hp-osf 701 exit ;;682 exit 0 ;; 702 683 i*86:OSF1:*:*) 703 684 if [ -x /usr/sbin/sysversion ] ; then … … 706 687 echo ${UNAME_MACHINE}-unknown-osf1 707 688 fi 708 exit ;;689 exit 0 ;; 709 690 parisc*:Lites*:*:*) 710 691 echo hppa1.1-hp-lites 711 exit ;;692 exit 0 ;; 712 693 C1*:ConvexOS:*:* | convex:ConvexOS:C1*:*) 713 694 echo c1-convex-bsd 714 exit ;;695 exit 0 ;; 715 696 C2*:ConvexOS:*:* | convex:ConvexOS:C2*:*) 716 697 if getsysinfo -f scalar_acc … … 718 699 else echo c2-convex-bsd 719 700 fi 720 exit ;;701 exit 0 ;; 721 702 C34*:ConvexOS:*:* | convex:ConvexOS:C34*:*) 722 703 echo c34-convex-bsd 723 exit ;;704 exit 0 ;; 724 705 C38*:ConvexOS:*:* | convex:ConvexOS:C38*:*) 725 706 echo c38-convex-bsd 726 exit ;;707 exit 0 ;; 727 708 C4*:ConvexOS:*:* | convex:ConvexOS:C4*:*) 728 709 echo c4-convex-bsd 729 exit ;;710 exit 0 ;; 730 711 CRAY*Y-MP:*:*:*) 731 712 echo ymp-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' 732 exit ;;713 exit 0 ;; 733 714 CRAY*[A-Z]90:*:*:*) 734 715 echo ${UNAME_MACHINE}-cray-unicos${UNAME_RELEASE} \ … … 736 717 -e y/ABCDEFGHIJKLMNOPQRSTUVWXYZ/abcdefghijklmnopqrstuvwxyz/ \ 737 718 -e 's/\.[^.]*$/.X/' 738 exit ;;719 exit 0 ;; 739 720 CRAY*TS:*:*:*) 740 721 echo t90-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' 741 exit ;;722 exit 0 ;; 742 723 CRAY*T3E:*:*:*) 743 724 echo alphaev5-cray-unicosmk${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' 744 exit ;;725 exit 0 ;; 745 726 CRAY*SV1:*:*:*) 746 727 echo sv1-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' 747 exit ;;728 exit 0 ;; 748 729 *:UNICOS/mp:*:*) 749 echo craynv-cray-unicosmp${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/'750 exit ;;730 echo nv1-cray-unicosmp${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' 731 exit 0 ;; 751 732 F30[01]:UNIX_System_V:*:* | F700:UNIX_System_V:*:*) 752 733 FUJITSU_PROC=`uname -m | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` … … 754 735 FUJITSU_REL=`echo ${UNAME_RELEASE} | sed -e 's/ /_/'` 755 736 echo "${FUJITSU_PROC}-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}" 756 exit ;; 757 5000:UNIX_System_V:4.*:*) 758 FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'` 759 FUJITSU_REL=`echo ${UNAME_RELEASE} | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/ /_/'` 760 echo "sparc-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}" 761 exit ;; 737 exit 0 ;; 762 738 i*86:BSD/386:*:* | i*86:BSD/OS:*:* | *:Ascend\ Embedded/OS:*:*) 763 739 echo ${UNAME_MACHINE}-pc-bsdi${UNAME_RELEASE} 764 exit ;;740 exit 0 ;; 765 741 sparc*:BSD/OS:*:*) 766 742 echo sparc-unknown-bsdi${UNAME_RELEASE} 767 exit ;;743 exit 0 ;; 768 744 *:BSD/OS:*:*) 769 745 echo ${UNAME_MACHINE}-unknown-bsdi${UNAME_RELEASE} 770 exit ;;746 exit 0 ;; 771 747 *:FreeBSD:*:*) 772 case ${UNAME_MACHINE} in 773 pc98) 774 echo i386-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;; 775 amd64) 776 echo x86_64-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;; 777 *) 778 echo ${UNAME_MACHINE}-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;; 779 esac 780 exit ;; 748 # Determine whether the default compiler uses glibc. 749 eval $set_cc_for_build 750 sed 's/^ //' << EOF >$dummy.c 751 #include <features.h> 752 #if __GLIBC__ >= 2 753 LIBC=gnu 754 #else 755 LIBC= 756 #endif 757 EOF 758 eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep ^LIBC=` 759 echo ${UNAME_MACHINE}-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`${LIBC:+-$LIBC} 760 exit 0 ;; 781 761 i*:CYGWIN*:*) 782 762 echo ${UNAME_MACHINE}-pc-cygwin 783 exit ;;784 *:MINGW*:*)763 exit 0 ;; 764 i*:MINGW*:*) 785 765 echo ${UNAME_MACHINE}-pc-mingw32 786 exit ;; 787 i*:windows32*:*) 788 # uname -m includes "-pc" on this system. 789 echo ${UNAME_MACHINE}-mingw32 790 exit ;; 766 exit 0 ;; 767 i*:MSYS*:*) 768 echo ${UNAME_MACHINE}-pc-msys 769 exit 0 ;; 791 770 i*:PW*:*) 792 771 echo ${UNAME_MACHINE}-pc-pw32 793 exit ;; 794 *:Interix*:[3456]*) 795 case ${UNAME_MACHINE} in 796 x86) 797 echo i586-pc-interix${UNAME_RELEASE} 798 exit ;; 799 EM64T | authenticamd) 800 echo x86_64-unknown-interix${UNAME_RELEASE} 801 exit ;; 802 IA64) 803 echo ia64-unknown-interix${UNAME_RELEASE} 804 exit ;; 805 esac ;; 772 exit 0 ;; 773 x86:Interix*:3*) 774 echo i586-pc-interix3 775 exit 0 ;; 806 776 [345]86:Windows_95:* | [345]86:Windows_98:* | [345]86:Windows_NT:*) 807 777 echo i${UNAME_MACHINE}-pc-mks 808 exit ;;778 exit 0 ;; 809 779 i*:Windows_NT*:* | Pentium*:Windows_NT*:*) 810 780 # How do we know it's Interix rather than the generic POSIX subsystem? … … 812 782 # UNAME_MACHINE based on the output of uname instead of i386? 813 783 echo i586-pc-interix 814 exit ;;784 exit 0 ;; 815 785 i*:UWIN*:*) 816 786 echo ${UNAME_MACHINE}-pc-uwin 817 exit ;; 818 amd64:CYGWIN*:*:* | x86_64:CYGWIN*:*:*) 819 echo x86_64-unknown-cygwin 820 exit ;; 787 exit 0 ;; 821 788 p*:CYGWIN*:*) 822 789 echo powerpcle-unknown-cygwin 823 exit ;;790 exit 0 ;; 824 791 prep*:SunOS:5.*:*) 825 792 echo powerpcle-unknown-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` 826 exit ;;793 exit 0 ;; 827 794 *:GNU:*:*) 828 # the GNU system829 795 echo `echo ${UNAME_MACHINE}|sed -e 's,[-/].*$,,'`-unknown-gnu`echo ${UNAME_RELEASE}|sed -e 's,/.*$,,'` 830 exit ;; 831 *:GNU/*:*:*) 832 # other systems with GNU libc and userland 833 echo ${UNAME_MACHINE}-unknown-`echo ${UNAME_SYSTEM} | sed 's,^[^/]*/,,' | tr '[A-Z]' '[a-z]'``echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`-gnu 834 exit ;; 796 exit 0 ;; 835 797 i*86:Minix:*:*) 836 798 echo ${UNAME_MACHINE}-pc-minix 837 exit ;;799 exit 0 ;; 838 800 arm*:Linux:*:*) 839 eval $set_cc_for_build840 if echo __ARM_EABI__ | $CC_FOR_BUILD -E - 2>/dev/null \841 | grep -q __ARM_EABI__842 then843 echo ${UNAME_MACHINE}-unknown-linux-gnu844 else845 echo ${UNAME_MACHINE}-unknown-linux-gnueabi846 fi847 exit ;;848 avr32*:Linux:*:*)849 801 echo ${UNAME_MACHINE}-unknown-linux-gnu 850 exit ;; 851 cris:Linux:*:*) 852 echo cris-axis-linux-gnu 853 exit ;; 854 crisv32:Linux:*:*) 855 echo crisv32-axis-linux-gnu 856 exit ;; 857 frv:Linux:*:*) 858 echo frv-unknown-linux-gnu 859 exit ;; 802 exit 0 ;; 860 803 ia64:Linux:*:*) 861 804 echo ${UNAME_MACHINE}-unknown-linux-gnu 862 exit ;; 863 m32r*:Linux:*:*) 864 echo ${UNAME_MACHINE}-unknown-linux-gnu 865 exit ;; 805 exit 0 ;; 866 806 m68*:Linux:*:*) 867 807 echo ${UNAME_MACHINE}-unknown-linux-gnu 868 exit ;;808 exit 0 ;; 869 809 mips:Linux:*:*) 870 810 eval $set_cc_for_build … … 883 823 #endif 884 824 EOF 885 eval "`$CC_FOR_BUILD -E $dummy.c 2>/dev/null | sed -n ' 886 /^CPU/{ 887 s: ::g 888 p 889 }'`" 890 test x"${CPU}" != x && { echo "${CPU}-unknown-linux-gnu"; exit; } 825 eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep ^CPU=` 826 test x"${CPU}" != x && echo "${CPU}-unknown-linux-gnu" && exit 0 891 827 ;; 892 828 mips64:Linux:*:*) … … 906 842 #endif 907 843 EOF 908 eval "`$CC_FOR_BUILD -E $dummy.c 2>/dev/null | sed -n ' 909 /^CPU/{ 910 s: ::g 911 p 912 }'`" 913 test x"${CPU}" != x && { echo "${CPU}-unknown-linux-gnu"; exit; } 844 eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep ^CPU=` 845 test x"${CPU}" != x && echo "${CPU}-unknown-linux-gnu" && exit 0 914 846 ;; 915 or32:Linux:*:*)916 echo or32-unknown-linux-gnu917 exit ;;918 847 ppc:Linux:*:*) 919 848 echo powerpc-unknown-linux-gnu 920 exit ;;849 exit 0 ;; 921 850 ppc64:Linux:*:*) 922 851 echo powerpc64-unknown-linux-gnu 923 exit ;;852 exit 0 ;; 924 853 alpha:Linux:*:*) 925 854 case `sed -n '/^cpu model/s/^.*: \(.*\)/\1/p' < /proc/cpuinfo` in … … 935 864 if test "$?" = 0 ; then LIBC="libc1" ; else LIBC="" ; fi 936 865 echo ${UNAME_MACHINE}-unknown-linux-gnu${LIBC} 937 exit ;;866 exit 0 ;; 938 867 parisc:Linux:*:* | hppa:Linux:*:*) 939 868 # Look for CPU level … … 943 872 *) echo hppa-unknown-linux-gnu ;; 944 873 esac 945 exit ;;874 exit 0 ;; 946 875 parisc64:Linux:*:* | hppa64:Linux:*:*) 947 876 echo hppa64-unknown-linux-gnu 948 exit ;;877 exit 0 ;; 949 878 s390:Linux:*:* | s390x:Linux:*:*) 950 879 echo ${UNAME_MACHINE}-ibm-linux 951 exit ;; 952 sh64*:Linux:*:*) 953 echo ${UNAME_MACHINE}-unknown-linux-gnu 954 exit ;; 880 exit 0 ;; 955 881 sh*:Linux:*:*) 956 882 echo ${UNAME_MACHINE}-unknown-linux-gnu 957 exit ;;883 exit 0 ;; 958 884 sparc:Linux:*:* | sparc64:Linux:*:*) 959 885 echo ${UNAME_MACHINE}-unknown-linux-gnu 960 exit ;; 961 vax:Linux:*:*) 962 echo ${UNAME_MACHINE}-dec-linux-gnu 963 exit ;; 886 exit 0 ;; 964 887 x86_64:Linux:*:*) 965 888 echo x86_64-unknown-linux-gnu 966 exit ;; 967 xtensa*:Linux:*:*) 968 echo ${UNAME_MACHINE}-unknown-linux-gnu 969 exit ;; 889 exit 0 ;; 970 890 i*86:Linux:*:*) 971 891 # The BFD linker knows what the default object file format is, so … … 985 905 a.out-i386-linux) 986 906 echo "${UNAME_MACHINE}-pc-linux-gnuaout" 987 exit ;; 907 exit 0 ;; 908 coff-i386) 909 echo "${UNAME_MACHINE}-pc-linux-gnucoff" 910 exit 0 ;; 988 911 "") 989 912 # Either a pre-BFD a.out linker (linux-gnuoldld) or 990 913 # one that does not give us useful --help. 991 914 echo "${UNAME_MACHINE}-pc-linux-gnuoldld" 992 exit ;;915 exit 0 ;; 993 916 esac 994 917 # Determine whether the default compiler is a.out or elf … … 1007 930 # endif 1008 931 #else 1009 #if defined(__INTEL_COMPILER) || defined(__PGI) || defined(__SUNPRO_C) || defined(__SUNPRO_CC)932 #ifdef __INTEL_COMPILER 1010 933 LIBC=gnu 1011 934 #else … … 1013 936 #endif 1014 937 #endif 1015 #ifdef __dietlibc__1016 LIBC=dietlibc1017 #endif1018 938 EOF 1019 eval "`$CC_FOR_BUILD -E $dummy.c 2>/dev/null | sed -n ' 1020 /^LIBC/{ 1021 s: ::g 1022 p 1023 }'`" 1024 test x"${LIBC}" != x && { 1025 echo "${UNAME_MACHINE}-pc-linux-${LIBC}" 1026 exit 1027 } 1028 test x"${TENTATIVE}" != x && { echo "${TENTATIVE}"; exit; } 939 eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep ^LIBC=` 940 test x"${LIBC}" != x && echo "${UNAME_MACHINE}-pc-linux-${LIBC}" && exit 0 941 test x"${TENTATIVE}" != x && echo "${TENTATIVE}" && exit 0 1029 942 ;; 1030 943 i*86:DYNIX/ptx:4*:*) … … 1033 946 # sysname and nodename. 1034 947 echo i386-sequent-sysv4 1035 exit ;;948 exit 0 ;; 1036 949 i*86:UNIX_SV:4.2MP:2.*) 1037 950 # Unixware is an offshoot of SVR4, but it has its own version … … 1041 954 # Use sysv4.2uw... so that sysv4* matches it. 1042 955 echo ${UNAME_MACHINE}-pc-sysv4.2uw${UNAME_VERSION} 1043 exit ;;956 exit 0 ;; 1044 957 i*86:OS/2:*:*) 1045 958 # If we were able to find `uname', then EMX Unix compatibility 1046 959 # is probably installed. 1047 960 echo ${UNAME_MACHINE}-pc-os2-emx 1048 exit ;;961 exit 0 ;; 1049 962 i*86:XTS-300:*:STOP) 1050 963 echo ${UNAME_MACHINE}-unknown-stop 1051 exit ;;964 exit 0 ;; 1052 965 i*86:atheos:*:*) 1053 966 echo ${UNAME_MACHINE}-unknown-atheos 1054 exit ;; 1055 i*86:syllable:*:*) 1056 echo ${UNAME_MACHINE}-pc-syllable 1057 exit ;; 967 exit 0 ;; 1058 968 i*86:LynxOS:2.*:* | i*86:LynxOS:3.[01]*:* | i*86:LynxOS:4.0*:*) 1059 969 echo i386-unknown-lynxos${UNAME_RELEASE} 1060 exit ;;970 exit 0 ;; 1061 971 i*86:*DOS:*:*) 1062 972 echo ${UNAME_MACHINE}-pc-msdosdjgpp 1063 exit ;;973 exit 0 ;; 1064 974 i*86:*:4.*:* | i*86:SYSTEM_V:4.*:*) 1065 975 UNAME_REL=`echo ${UNAME_RELEASE} | sed 's/\/MP$//'` … … 1069 979 echo ${UNAME_MACHINE}-pc-sysv${UNAME_REL} 1070 980 fi 1071 exit ;; 1072 i*86:*:5:[678]*) 1073 # UnixWare 7.x, OpenUNIX and OpenServer 6. 981 exit 0 ;; 982 i*86:*:5:[78]*) 1074 983 case `/bin/uname -X | grep "^Machine"` in 1075 984 *486*) UNAME_MACHINE=i486 ;; … … 1078 987 esac 1079 988 echo ${UNAME_MACHINE}-unknown-sysv${UNAME_RELEASE}${UNAME_SYSTEM}${UNAME_VERSION} 1080 exit ;;989 exit 0 ;; 1081 990 i*86:*:3.2:*) 1082 991 if test -f /usr/options/cb.name; then … … 1096 1005 echo ${UNAME_MACHINE}-pc-sysv32 1097 1006 fi 1098 exit ;;1007 exit 0 ;; 1099 1008 pc:*:*:*) 1100 1009 # Left here for compatibility: … … 1102 1011 # the processor, so we play safe by assuming i386. 1103 1012 echo i386-pc-msdosdjgpp 1104 exit ;;1013 exit 0 ;; 1105 1014 Intel:Mach:3*:*) 1106 1015 echo i386-pc-mach3 1107 exit ;;1016 exit 0 ;; 1108 1017 paragon:*:*:*) 1109 1018 echo i860-intel-osf1 1110 exit ;;1019 exit 0 ;; 1111 1020 i860:*:4.*:*) # i860-SVR4 1112 1021 if grep Stardent /usr/include/sys/uadmin.h >/dev/null 2>&1 ; then … … 1115 1024 echo i860-unknown-sysv${UNAME_RELEASE} # Unknown i860-SVR4 1116 1025 fi 1117 exit ;;1026 exit 0 ;; 1118 1027 mini*:CTIX:SYS*5:*) 1119 1028 # "miniframe" 1120 1029 echo m68010-convergent-sysv 1121 exit ;;1030 exit 0 ;; 1122 1031 mc68k:UNIX:SYSTEM5:3.51m) 1123 1032 echo m68k-convergent-sysv 1124 exit ;;1033 exit 0 ;; 1125 1034 M680?0:D-NIX:5.3:*) 1126 1035 echo m68k-diab-dnix 1127 exit ;;1128 M68*:*:R3V[567 8]*:*)1129 test -r /sysV68 && { echo 'm68k-motorola-sysv'; exit; };;1130 3[34 5]??:*:4.0:3.0 | 3[34]??A:*:4.0:3.0 | 3[34]??,*:*:4.0:3.0 | 3[34]??/*:*:4.0:3.0 | 4400:*:4.0:3.0 | 4850:*:4.0:3.0 | SKA40:*:4.0:3.0 | SDS2:*:4.0:3.0 | SHG2:*:4.0:3.0 | S7501*:*:4.0:3.0)1036 exit 0 ;; 1037 M68*:*:R3V[567]*:*) 1038 test -r /sysV68 && echo 'm68k-motorola-sysv' && exit 0 ;; 1039 3[34]??:*:4.0:3.0 | 3[34]??A:*:4.0:3.0 | 3[34]??,*:*:4.0:3.0 | 3[34]??/*:*:4.0:3.0 | 4400:*:4.0:3.0 | 4850:*:4.0:3.0 | SKA40:*:4.0:3.0 | SDS2:*:4.0:3.0) 1131 1040 OS_REL='' 1132 1041 test -r /etc/.relid \ 1133 1042 && OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid` 1134 1043 /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ 1135 && { echo i486-ncr-sysv4.3${OS_REL}; exit; }1044 && echo i486-ncr-sysv4.3${OS_REL} && exit 0 1136 1045 /bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \ 1137 && { echo i586-ncr-sysv4.3${OS_REL}; exit; };;1046 && echo i586-ncr-sysv4.3${OS_REL} && exit 0 ;; 1138 1047 3[34]??:*:4.0:* | 3[34]??,*:*:4.0:*) 1139 1048 /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ 1140 && { echo i486-ncr-sysv4; exit; };;1049 && echo i486-ncr-sysv4 && exit 0 ;; 1141 1050 m68*:LynxOS:2.*:* | m68*:LynxOS:3.0*:*) 1142 1051 echo m68k-unknown-lynxos${UNAME_RELEASE} 1143 exit ;;1052 exit 0 ;; 1144 1053 mc68030:UNIX_System_V:4.*:*) 1145 1054 echo m68k-atari-sysv4 1146 exit ;;1055 exit 0 ;; 1147 1056 TSUNAMI:LynxOS:2.*:*) 1148 1057 echo sparc-unknown-lynxos${UNAME_RELEASE} 1149 exit ;;1058 exit 0 ;; 1150 1059 rs6000:LynxOS:2.*:*) 1151 1060 echo rs6000-unknown-lynxos${UNAME_RELEASE} 1152 exit ;;1061 exit 0 ;; 1153 1062 PowerPC:LynxOS:2.*:* | PowerPC:LynxOS:3.[01]*:* | PowerPC:LynxOS:4.0*:*) 1154 1063 echo powerpc-unknown-lynxos${UNAME_RELEASE} 1155 exit ;;1064 exit 0 ;; 1156 1065 SM[BE]S:UNIX_SV:*:*) 1157 1066 echo mips-dde-sysv${UNAME_RELEASE} 1158 exit ;;1067 exit 0 ;; 1159 1068 RM*:ReliantUNIX-*:*:*) 1160 1069 echo mips-sni-sysv4 1161 exit ;;1070 exit 0 ;; 1162 1071 RM*:SINIX-*:*:*) 1163 1072 echo mips-sni-sysv4 1164 exit ;;1073 exit 0 ;; 1165 1074 *:SINIX-*:*:*) 1166 1075 if uname -p 2>/dev/null >/dev/null ; then … … 1170 1079 echo ns32k-sni-sysv 1171 1080 fi 1172 exit ;;1081 exit 0 ;; 1173 1082 PENTIUM:*:4.0*:*) # Unisys `ClearPath HMP IX 4000' SVR4/MP effort 1174 1083 # says <Richard.M.Bartel@ccMail.Census.GOV> 1175 1084 echo i586-unisys-sysv4 1176 exit ;;1085 exit 0 ;; 1177 1086 *:UNIX_System_V:4*:FTX*) 1178 1087 # From Gerald Hewes <hewes@openmarket.com>. 1179 1088 # How about differentiating between stratus architectures? -djm 1180 1089 echo hppa1.1-stratus-sysv4 1181 exit ;;1090 exit 0 ;; 1182 1091 *:*:*:FTX*) 1183 1092 # From seanf@swdc.stratus.com. 1184 1093 echo i860-stratus-sysv4 1185 exit ;; 1186 i*86:VOS:*:*) 1187 # From Paul.Green@stratus.com. 1188 echo ${UNAME_MACHINE}-stratus-vos 1189 exit ;; 1094 exit 0 ;; 1190 1095 *:VOS:*:*) 1191 1096 # From Paul.Green@stratus.com. 1192 1097 echo hppa1.1-stratus-vos 1193 exit ;;1098 exit 0 ;; 1194 1099 mc68*:A/UX:*:*) 1195 1100 echo m68k-apple-aux${UNAME_RELEASE} 1196 exit ;;1101 exit 0 ;; 1197 1102 news*:NEWS-OS:6*:*) 1198 1103 echo mips-sony-newsos6 1199 exit ;;1104 exit 0 ;; 1200 1105 R[34]000:*System_V*:*:* | R4000:UNIX_SYSV:*:* | R*000:UNIX_SV:*:*) 1201 1106 if [ -d /usr/nec ]; then … … 1204 1109 echo mips-unknown-sysv${UNAME_RELEASE} 1205 1110 fi 1206 exit ;;1111 exit 0 ;; 1207 1112 BeBox:BeOS:*:*) # BeOS running on hardware made by Be, PPC only. 1208 1113 echo powerpc-be-beos 1209 exit ;;1114 exit 0 ;; 1210 1115 BeMac:BeOS:*:*) # BeOS running on Mac or Mac clone, PPC only. 1211 1116 echo powerpc-apple-beos 1212 exit ;;1117 exit 0 ;; 1213 1118 BePC:BeOS:*:*) # BeOS running on Intel PC compatible. 1214 1119 echo i586-pc-beos 1215 exit ;; 1216 BePC:Haiku:*:*) # Haiku running on Intel PC compatible. 1217 echo i586-pc-haiku 1218 exit ;; 1120 exit 0 ;; 1219 1121 SX-4:SUPER-UX:*:*) 1220 1122 echo sx4-nec-superux${UNAME_RELEASE} 1221 exit ;;1123 exit 0 ;; 1222 1124 SX-5:SUPER-UX:*:*) 1223 1125 echo sx5-nec-superux${UNAME_RELEASE} 1224 exit ;;1126 exit 0 ;; 1225 1127 SX-6:SUPER-UX:*:*) 1226 1128 echo sx6-nec-superux${UNAME_RELEASE} 1227 exit ;; 1228 SX-7:SUPER-UX:*:*) 1229 echo sx7-nec-superux${UNAME_RELEASE} 1230 exit ;; 1231 SX-8:SUPER-UX:*:*) 1232 echo sx8-nec-superux${UNAME_RELEASE} 1233 exit ;; 1234 SX-8R:SUPER-UX:*:*) 1235 echo sx8r-nec-superux${UNAME_RELEASE} 1236 exit ;; 1129 exit 0 ;; 1237 1130 Power*:Rhapsody:*:*) 1238 1131 echo powerpc-apple-rhapsody${UNAME_RELEASE} 1239 exit ;;1132 exit 0 ;; 1240 1133 *:Rhapsody:*:*) 1241 1134 echo ${UNAME_MACHINE}-apple-rhapsody${UNAME_RELEASE} 1242 exit ;;1135 exit 0 ;; 1243 1136 *:Darwin:*:*) 1244 UNAME_PROCESSOR=`uname -p` || UNAME_PROCESSOR=unknown1245 case $UNAME_PROCESSOR in1246 unknown) UNAME_PROCESSOR=powerpc ;;1137 case `uname -p` in 1138 *86) UNAME_PROCESSOR=i686 ;; 1139 powerpc) UNAME_PROCESSOR=powerpc ;; 1247 1140 esac 1248 1141 echo ${UNAME_PROCESSOR}-apple-darwin${UNAME_RELEASE} 1249 exit ;;1142 exit 0 ;; 1250 1143 *:procnto*:*:* | *:QNX:[0123456789]*:*) 1251 1144 UNAME_PROCESSOR=`uname -p` … … 1255 1148 fi 1256 1149 echo ${UNAME_PROCESSOR}-${UNAME_MACHINE}-nto-qnx${UNAME_RELEASE} 1257 exit ;;1150 exit 0 ;; 1258 1151 *:QNX:*:4*) 1259 1152 echo i386-pc-qnx 1260 exit ;; 1261 NSE-?:NONSTOP_KERNEL:*:*) 1262 echo nse-tandem-nsk${UNAME_RELEASE} 1263 exit ;; 1264 NSR-?:NONSTOP_KERNEL:*:*) 1153 exit 0 ;; 1154 NSR-[DGKLNPTVW]:NONSTOP_KERNEL:*:*) 1265 1155 echo nsr-tandem-nsk${UNAME_RELEASE} 1266 exit ;;1156 exit 0 ;; 1267 1157 *:NonStop-UX:*:*) 1268 1158 echo mips-compaq-nonstopux 1269 exit ;;1159 exit 0 ;; 1270 1160 BS2000:POSIX*:*:*) 1271 1161 echo bs2000-siemens-sysv 1272 exit ;;1162 exit 0 ;; 1273 1163 DS/*:UNIX_System_V:*:*) 1274 1164 echo ${UNAME_MACHINE}-${UNAME_SYSTEM}-${UNAME_RELEASE} 1275 exit ;;1165 exit 0 ;; 1276 1166 *:Plan9:*:*) 1277 1167 # "uname -m" is not consistent, so use $cputype instead. 386 … … 1284 1174 fi 1285 1175 echo ${UNAME_MACHINE}-unknown-plan9 1286 exit ;;1176 exit 0 ;; 1287 1177 *:TOPS-10:*:*) 1288 1178 echo pdp10-unknown-tops10 1289 exit ;;1179 exit 0 ;; 1290 1180 *:TENEX:*:*) 1291 1181 echo pdp10-unknown-tenex 1292 exit ;;1182 exit 0 ;; 1293 1183 KS10:TOPS-20:*:* | KL10:TOPS-20:*:* | TYPE4:TOPS-20:*:*) 1294 1184 echo pdp10-dec-tops20 1295 exit ;;1185 exit 0 ;; 1296 1186 XKL-1:TOPS-20:*:* | TYPE5:TOPS-20:*:*) 1297 1187 echo pdp10-xkl-tops20 1298 exit ;;1188 exit 0 ;; 1299 1189 *:TOPS-20:*:*) 1300 1190 echo pdp10-unknown-tops20 1301 exit ;;1191 exit 0 ;; 1302 1192 *:ITS:*:*) 1303 1193 echo pdp10-unknown-its 1304 exit ;; 1305 SEI:*:*:SEIUX) 1306 echo mips-sei-seiux${UNAME_RELEASE} 1307 exit ;; 1308 *:DragonFly:*:*) 1309 echo ${UNAME_MACHINE}-unknown-dragonfly`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` 1310 exit ;; 1311 *:*VMS:*:*) 1312 UNAME_MACHINE=`(uname -p) 2>/dev/null` 1313 case "${UNAME_MACHINE}" in 1314 A*) echo alpha-dec-vms ; exit ;; 1315 I*) echo ia64-dec-vms ; exit ;; 1316 V*) echo vax-dec-vms ; exit ;; 1317 esac ;; 1318 *:XENIX:*:SysV) 1319 echo i386-pc-xenix 1320 exit ;; 1321 i*86:skyos:*:*) 1322 echo ${UNAME_MACHINE}-pc-skyos`echo ${UNAME_RELEASE}` | sed -e 's/ .*$//' 1323 exit ;; 1324 i*86:rdos:*:*) 1325 echo ${UNAME_MACHINE}-pc-rdos 1326 exit ;; 1194 exit 0 ;; 1327 1195 esac 1328 1196 … … 1356 1224 1357 1225 #if defined (__arm) && defined (__acorn) && defined (__unix) 1358 printf ("arm-acorn-riscix \n"); exit (0);1226 printf ("arm-acorn-riscix"); exit (0); 1359 1227 #endif 1360 1228 … … 1445 1313 EOF 1446 1314 1447 $CC_FOR_BUILD -o $dummy $dummy.c 2>/dev/null && SYSTEM_NAME=`$dummy` && 1448 { echo "$SYSTEM_NAME"; exit; } 1315 $CC_FOR_BUILD -o $dummy $dummy.c 2>/dev/null && $dummy && exit 0 1449 1316 1450 1317 # Apollos put the system type in the environment. 1451 1318 1452 test -d /usr/apollo && { echo ${ISP}-apollo-${SYSTYPE}; exit ; }1319 test -d /usr/apollo && { echo ${ISP}-apollo-${SYSTYPE}; exit 0; } 1453 1320 1454 1321 # Convex versions that predate uname can use getsysinfo(1) … … 1459 1326 c1*) 1460 1327 echo c1-convex-bsd 1461 exit ;;1328 exit 0 ;; 1462 1329 c2*) 1463 1330 if getsysinfo -f scalar_acc … … 1465 1332 else echo c2-convex-bsd 1466 1333 fi 1467 exit ;;1334 exit 0 ;; 1468 1335 c34*) 1469 1336 echo c34-convex-bsd 1470 exit ;;1337 exit 0 ;; 1471 1338 c38*) 1472 1339 echo c38-convex-bsd 1473 exit ;;1340 exit 0 ;; 1474 1341 c4*) 1475 1342 echo c4-convex-bsd 1476 exit ;;1343 exit 0 ;; 1477 1344 esac 1478 1345 fi … … 1485 1352 download the most up to date version of the config scripts from 1486 1353 1487 http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.guess;hb=HEAD 1488 and 1489 http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.sub;hb=HEAD 1354 ftp://ftp.gnu.org/pub/gnu/config/ 1490 1355 1491 1356 If the version you run ($0) is already up to date, please -
branches/blt4/gui/cf/config.sub
r2706 r2742 2 2 # Configuration validation subroutine script. 3 3 # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 4 # 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 5 # Free Software Foundation, Inc. 6 7 timestamp='2008-04-14' 4 # 2000, 2001, 2002, 2003 Free Software Foundation, Inc. 5 6 timestamp='2003-02-22' 8 7 9 8 # This file is (in principle) common to ALL GNU software. … … 23 22 # You should have received a copy of the GNU General Public License 24 23 # along with this program; if not, write to the Free Software 25 # Foundation, Inc., 5 1 Franklin Street - Fifth Floor, Boston, MA26 # 02110-1301, USA.27 # 24 # Foundation, Inc., 59 Temple Place - Suite 330, 25 # Boston, MA 02111-1307, USA. 26 28 27 # As a special exception to the GNU General Public License, if you 29 28 # distribute this file as part of a program that contains a 30 29 # configuration script generated by Autoconf, you may include it under 31 30 # the same distribution terms that you use for the rest of that program. 32 33 31 34 32 # Please send patches to <config-patches@gnu.org>. Submit a context … … 73 71 GNU config.sub ($timestamp) 74 72 75 Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001 ,76 2002, 2003, 2004, 2005, 2006, 2007, 2008Free Software Foundation, Inc.73 Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001 74 Free Software Foundation, Inc. 77 75 78 76 This is free software; see the source for copying conditions. There is NO … … 86 84 case $1 in 87 85 --time-stamp | --time* | -t ) 88 echo "$timestamp" ; exit ;;86 echo "$timestamp" ; exit 0 ;; 89 87 --version | -v ) 90 echo "$version" ; exit ;;88 echo "$version" ; exit 0 ;; 91 89 --help | --h* | -h ) 92 echo "$usage"; exit ;;90 echo "$usage"; exit 0 ;; 93 91 -- ) # Stop option processing 94 92 shift; break ;; … … 102 100 # First pass through any local machine types. 103 101 echo $1 104 exit ;;102 exit 0;; 105 103 106 104 * ) … … 121 119 maybe_os=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\2/'` 122 120 case $maybe_os in 123 nto-qnx* | linux-gnu* | linux-dietlibc | linux-newlib* | linux-uclibc* | \ 124 uclinux-uclibc* | uclinux-gnu* | kfreebsd*-gnu* | knetbsd*-gnu* | netbsd*-gnu* | \ 125 storm-chaos* | os2-emx* | rtmk-nova*) 121 nto-qnx* | linux-gnu* | freebsd*-gnu* | netbsd*-gnu* | storm-chaos* | os2-emx* | rtmk-nova*) 126 122 os=-$maybe_os 127 123 basic_machine=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\1/'` … … 149 145 -c[123]* | -convex* | -sun | -crds | -omron* | -dg | -ultra | -tti* | \ 150 146 -harris | -dolphin | -highlevel | -gould | -cbm | -ns | -masscomp | \ 151 -apple | -axis | -knuth | -cray)147 -apple | -axis) 152 148 os= 153 149 basic_machine=$1 … … 174 170 os=-hiuxwe2 175 171 ;; 176 -sco6)177 os=-sco5v6178 basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`179 ;;180 172 -sco5) 181 173 os=-sco3.2v5 … … 191 183 ;; 192 184 -sco3.2v[4-9]*) 193 # Don't forget version if it is 3.2v4 or newer.194 basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`195 ;;196 -sco5v6*)197 185 # Don't forget version if it is 3.2v4 or newer. 198 186 basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` … … 241 229 | alpha | alphaev[4-8] | alphaev56 | alphaev6[78] | alphapca5[67] \ 242 230 | alpha64 | alpha64ev[4-8] | alpha64ev56 | alpha64ev6[78] | alpha64pca5[67] \ 243 | am33_2.0 \ 244 | arc | arm | arm[bl]e | arme[lb] | armv[2345] | armv[345][lb] | avr | avr32 \ 245 | bfin \ 246 | c4x | clipper \ 231 | arc | arm | arm[bl]e | arme[lb] | armv[2345] | armv[345][lb] | avr \ 232 | clipper \ 247 233 | d10v | d30v | dlx | dsp16xx \ 248 | f ido | fr30 | frv \234 | fr30 | frv \ 249 235 | h8300 | h8500 | hppa | hppa1.[01] | hppa2.0 | hppa2.0[nw] | hppa64 \ 250 236 | i370 | i860 | i960 | ia64 \ 251 | ip2k | iq2000 \ 252 | m32c | m32r | m32rle | m68000 | m68k | m88k \ 253 | maxq | mb | microblaze | mcore | mep | metag \ 237 | ip2k \ 238 | m32r | m68000 | m68k | m88k | mcore \ 254 239 | mips | mipsbe | mipseb | mipsel | mipsle \ 255 240 | mips16 \ 256 241 | mips64 | mips64el \ 257 | mips64 octeon | mips64octeonel \242 | mips64vr | mips64vrel \ 258 243 | mips64orion | mips64orionel \ 259 | mips64r5900 | mips64r5900el \260 | mips64vr | mips64vrel \261 244 | mips64vr4100 | mips64vr4100el \ 262 245 | mips64vr4300 | mips64vr4300el \ 263 246 | mips64vr5000 | mips64vr5000el \ 264 | mips64vr5900 | mips64vr5900el \265 247 | mipsisa32 | mipsisa32el \ 266 248 | mipsisa32r2 | mipsisa32r2el \ 267 249 | mipsisa64 | mipsisa64el \ 268 | mipsisa64r2 | mipsisa64r2el \269 250 | mipsisa64sb1 | mipsisa64sb1el \ 270 251 | mipsisa64sr71k | mipsisa64sr71kel \ 271 252 | mipstx39 | mipstx39el \ 272 253 | mn10200 | mn10300 \ 273 | mt \274 254 | msp430 \ 275 | nios | nios2 \276 255 | ns16k | ns32k \ 277 | o r32 \256 | openrisc | or32 \ 278 257 | pdp10 | pdp11 | pj | pjl \ 279 258 | powerpc | powerpc64 | powerpc64le | powerpcle | ppcbe \ 280 259 | pyramid \ 281 | score \ 282 | sh | sh[1234] | sh[24]a | sh[23]e | sh[34]eb | sheb | shbe | shle | sh[1234]le | sh3ele \ 260 | sh | sh[1234] | sh[23]e | sh[34]eb | shbe | shle | sh[1234]le | sh3ele \ 283 261 | sh64 | sh64le \ 284 | sparc | sparc64 | sparc64b | sparc64v | sparc86x | sparclet | sparclite \ 285 | sparcv8 | sparcv9 | sparcv9b | sparcv9v \ 286 | spu | strongarm \ 287 | tahoe | thumb | tic4x | tic80 | tron \ 262 | sparc | sparc64 | sparc86x | sparclet | sparclite | sparcv9 | sparcv9b \ 263 | strongarm \ 264 | tahoe | thumb | tic80 | tron \ 288 265 | v850 | v850e \ 289 266 | we32k \ 290 | x86 | x c16x | xscale | xscalee[bl]| xstormy16 | xtensa \267 | x86 | xscale | xstormy16 | xtensa \ 291 268 | z8k) 292 269 basic_machine=$basic_machine-unknown … … 298 275 ;; 299 276 m88110 | m680[12346]0 | m683?2 | m68360 | m5200 | v70 | w65 | z8k) 300 ;;301 ms1)302 basic_machine=mt-unknown303 277 ;; 304 278 … … 321 295 | alphapca5[67]-* | alpha64pca5[67]-* | arc-* \ 322 296 | arm-* | armbe-* | armle-* | armeb-* | armv*-* \ 323 | avr-* | avr32-*\324 | b fin-* | bs2000-* \297 | avr-* \ 298 | bs2000-* \ 325 299 | c[123]* | c30-* | [cjt]90-* | c4x-* | c54x-* | c55x-* | c6x-* \ 326 | clipper-* | c raynv-* | cydra-* \300 | clipper-* | cydra-* \ 327 301 | d10v-* | d30v-* | dlx-* \ 328 302 | elxsi-* \ 329 | f30[01]-* | f700-* | f ido-* | fr30-* | frv-* | fx80-* \303 | f30[01]-* | f700-* | fr30-* | frv-* | fx80-* \ 330 304 | h8300-* | h8500-* \ 331 305 | hppa-* | hppa1.[01]-* | hppa2.0-* | hppa2.0[nw]-* | hppa64-* \ 332 306 | i*86-* | i860-* | i960-* | ia64-* \ 333 | ip2k-* | iq2000-*\334 | m32 c-* | m32r-* | m32rle-* \307 | ip2k-* \ 308 | m32r-* \ 335 309 | m68000-* | m680[012346]0-* | m68360-* | m683?2-* | m68k-* \ 336 | m88110-* | m88k-* | m axq-* | mcore-* | metag-* \310 | m88110-* | m88k-* | mcore-* \ 337 311 | mips-* | mipsbe-* | mipseb-* | mipsel-* | mipsle-* \ 338 312 | mips16-* \ 339 313 | mips64-* | mips64el-* \ 340 | mips64 octeon-* | mips64octeonel-* \314 | mips64vr-* | mips64vrel-* \ 341 315 | mips64orion-* | mips64orionel-* \ 342 | mips64r5900-* | mips64r5900el-* \343 | mips64vr-* | mips64vrel-* \344 316 | mips64vr4100-* | mips64vr4100el-* \ 345 317 | mips64vr4300-* | mips64vr4300el-* \ 346 318 | mips64vr5000-* | mips64vr5000el-* \ 347 | mips64vr5900-* | mips64vr5900el-* \348 319 | mipsisa32-* | mipsisa32el-* \ 349 320 | mipsisa32r2-* | mipsisa32r2el-* \ 350 321 | mipsisa64-* | mipsisa64el-* \ 351 | mipsisa64r2-* | mipsisa64r2el-* \352 322 | mipsisa64sb1-* | mipsisa64sb1el-* \ 353 323 | mipsisa64sr71k-* | mipsisa64sr71kel-* \ 354 324 | mipstx39-* | mipstx39el-* \ 355 | mmix-* \356 | mt-* \357 325 | msp430-* \ 358 | nios-* | nios2-* \ 359 | none-* | np1-* | ns16k-* | ns32k-* \ 326 | none-* | np1-* | nv1-* | ns16k-* | ns32k-* \ 360 327 | orion-* \ 361 328 | pdp10-* | pdp11-* | pj-* | pjl-* | pn-* | power-* \ … … 363 330 | pyramid-* \ 364 331 | romp-* | rs6000-* \ 365 | sh-* | sh[1234]-* | sh[2 4]a-* | sh[23]e-* | sh[34]eb-* | sheb-* | shbe-* \332 | sh-* | sh[1234]-* | sh[23]e-* | sh[34]eb-* | shbe-* \ 366 333 | shle-* | sh[1234]le-* | sh3ele-* | sh64-* | sh64le-* \ 367 | sparc-* | sparc64-* | sparc64b-* | sparc64v-* | sparc86x-* | sparclet-* \ 368 | sparclite-* \ 369 | sparcv8-* | sparcv9-* | sparcv9b-* | sparcv9v-* | strongarm-* | sv1-* | sx?-* \ 334 | sparc-* | sparc64-* | sparc86x-* | sparclet-* | sparclite-* \ 335 | sparcv9-* | sparcv9b-* | strongarm-* | sv1-* | sx?-* \ 370 336 | tahoe-* | thumb-* \ 371 | tic30-* | tic4x-* | tic54x-* | tic55x-* | tic6x-* | tic80-* | tile-*\337 | tic30-* | tic4x-* | tic54x-* | tic55x-* | tic6x-* | tic80-* \ 372 338 | tron-* \ 373 339 | v850-* | v850e-* | vax-* \ 374 340 | we32k-* \ 375 | x86-* | x86_64-* | x c16x-* | xps100-* | xscale-* | xscalee[bl]-* \376 | x stormy16-* | xtensa*-* \341 | x86-* | x86_64-* | xps100-* | xscale-* | xstormy16-* \ 342 | xtensa-* \ 377 343 | ymp-* \ 378 344 | z8k-*) 379 ;;380 # Recognize the basic CPU types without company name, with glob match.381 xtensa*)382 basic_machine=$basic_machine-unknown383 345 ;; 384 346 # Recognize the various machine names and aliases which stand … … 398 360 os=-udi 399 361 ;; 400 abacus)401 basic_machine=abacus-unknown402 ;;403 362 adobe68k) 404 363 basic_machine=m68010-adobe … … 415 374 os=-bsd 416 375 ;; 417 amd64)418 basic_machine=x86_64-pc419 ;;420 amd64-*)421 basic_machine=x86_64-`echo $basic_machine | sed 's/^[^-]*-//'`422 ;;423 376 amdahl) 424 377 basic_machine=580-amdahl … … 452 405 os=-dynix 453 406 ;; 454 blackfin)455 basic_machine=bfin-unknown456 os=-linux457 ;;458 blackfin-*)459 basic_machine=bfin-`echo $basic_machine | sed 's/^[^-]*-//'`460 os=-linux461 ;;462 407 c90) 463 408 basic_machine=c90-cray … … 488 433 os=-unicos 489 434 ;; 490 craynv)491 basic_machine=craynv-cray492 os=-unicosmp493 ;;494 cr16)495 basic_machine=cr16-unknown496 os=-elf497 ;;498 435 crds | unos) 499 436 basic_machine=m68k-crds 500 437 ;; 501 crisv32 | crisv32-* | etraxfs*)502 basic_machine=crisv32-axis503 ;;504 438 cris | cris-* | etrax*) 505 439 basic_machine=cris-axis 506 ;;507 crx)508 basic_machine=crx-unknown509 os=-elf510 440 ;; 511 441 da30 | da30-*) … … 530 460 basic_machine=m88k-motorola 531 461 os=-sysv3 532 ;;533 dicos)534 basic_machine=i686-pc535 os=-dicos536 ;;537 djgpp)538 basic_machine=i586-pc539 os=-msdosdjgpp540 462 ;; 541 463 dpx20 | dpx20-*) … … 689 611 os=-sysv 690 612 ;; 691 m68knommu)692 basic_machine=m68k-unknown693 os=-linux694 ;;695 m68knommu-*)696 basic_machine=m68k-`echo $basic_machine | sed 's/^[^-]*-//'`697 os=-linux698 ;;699 613 m88k-omron*) 700 614 basic_machine=m88k-omron … … 709 623 ;; 710 624 mingw32) 711 basic_machine=i 386-pc625 basic_machine=i686-pc 712 626 os=-mingw32 713 627 ;; 714 m ingw32ce)715 basic_machine= arm-unknown716 os=-m ingw32ce628 msys) 629 basic_machine=i686-pc 630 os=-msys 717 631 ;; 718 632 miniframe) … … 729 643 basic_machine=`echo $basic_machine | sed -e 's/mips3/mips64/'`-unknown 730 644 ;; 645 mmix*) 646 basic_machine=mmix-knuth 647 os=-mmixware 648 ;; 731 649 monitor) 732 650 basic_machine=m68k-rom68k … … 740 658 basic_machine=i386-pc 741 659 os=-msdos 742 ;;743 ms1-*)744 basic_machine=`echo $basic_machine | sed -e 's/ms1-/mt-/'`745 660 ;; 746 661 mvs) … … 812 727 basic_machine=np1-gould 813 728 ;; 729 nv1) 730 basic_machine=nv1-cray 731 os=-unicosmp 732 ;; 814 733 nsr-tandem) 815 734 basic_machine=nsr-tandem … … 819 738 os=-proelf 820 739 ;; 821 o penrisc | openrisc-*)740 or32 | or32-*) 822 741 basic_machine=or32-unknown 823 ;; 824 os400) 825 basic_machine=powerpc-ibm 826 os=-os400 742 os=-coff 827 743 ;; 828 744 OSE68000 | ose68000) … … 842 758 os=-osf 843 759 ;; 844 parisc)845 basic_machine=hppa-unknown846 os=-linux847 ;;848 parisc-*)849 basic_machine=hppa-`echo $basic_machine | sed 's/^[^-]*-//'`850 os=-linux851 ;;852 760 pbd) 853 761 basic_machine=sparc-tti … … 859 767 basic_machine=ns32k-pc532 860 768 ;; 861 pc98)862 basic_machine=i386-pc863 ;;864 pc98-*)865 basic_machine=i386-`echo $basic_machine | sed 's/^[^-]*-//'`866 ;;867 769 pentium | p5 | k5 | k6 | nexgen | viac3) 868 770 basic_machine=i586-pc … … 871 773 basic_machine=i686-pc 872 774 ;; 873 pentiumii | pentium2 | pentiumiii | pentium3)775 pentiumii | pentium2) 874 776 basic_machine=i686-pc 875 ;;876 pentium4)877 basic_machine=i786-pc878 777 ;; 879 778 pentium-* | p5-* | k5-* | k6-* | nexgen-* | viac3-*) … … 883 782 basic_machine=i686-`echo $basic_machine | sed 's/^[^-]*-//'` 884 783 ;; 885 pentiumii-* | pentium2-* | pentiumiii-* | pentium3-*)784 pentiumii-* | pentium2-*) 886 785 basic_machine=i686-`echo $basic_machine | sed 's/^[^-]*-//'` 887 ;;888 pentium4-*)889 basic_machine=i786-`echo $basic_machine | sed 's/^[^-]*-//'`890 786 ;; 891 787 pn) … … 921 817 os=-pw32 922 818 ;; 923 rdos)924 basic_machine=i386-pc925 os=-rdos926 ;;927 819 rom68k) 928 820 basic_machine=m68k-rom68k … … 951 843 basic_machine=mipsisa64sb1el-unknown 952 844 ;; 953 sde)954 basic_machine=mipsisa32-sde955 os=-elf956 ;;957 sei)958 basic_machine=mips-sei959 os=-seiux960 ;;961 845 sequent) 962 846 basic_machine=i386-sequent … … 966 850 os=-hms 967 851 ;; 968 sh5el)969 basic_machine=sh5le-unknown970 ;;971 sh64)972 basic_machine=sh64-unknown973 ;;974 852 sparclite-wrs | simso-wrs) 975 853 basic_machine=sparclite-wrs … … 1046 924 os=-unicos 1047 925 ;; 926 tic4x | c4x*) 927 basic_machine=tic4x-unknown 928 os=-coff 929 ;; 1048 930 tic54x | c54x*) 1049 931 basic_machine=tic54x-unknown … … 1058 940 os=-coff 1059 941 ;; 1060 tile*)1061 basic_machine=tile-unknown1062 os=-linux-gnu1063 ;;1064 942 tx39) 1065 943 basic_machine=mipstx39-unknown … … 1075 953 basic_machine=m68k-ncr 1076 954 ;; 1077 tpf)1078 basic_machine=s390x-ibm1079 os=-tpf1080 ;;1081 955 udi29k) 1082 956 basic_machine=a29k-amd … … 1121 995 basic_machine=hppa1.1-winbond 1122 996 os=-proelf 1123 ;;1124 xbox)1125 basic_machine=i686-pc1126 os=-mingw321127 997 ;; 1128 998 xps | xps100) … … 1156 1026 basic_machine=romp-ibm 1157 1027 ;; 1158 mmix)1159 basic_machine=mmix-knuth1160 ;;1161 1028 rs6000) 1162 1029 basic_machine=rs6000-ibm … … 1175 1042 basic_machine=we32k-att 1176 1043 ;; 1177 sh [1234] | sh[24]a| sh[34]eb | sh[1234]le | sh[23]ele)1044 sh3 | sh4 | sh[34]eb | sh[1234]le | sh[23]ele) 1178 1045 basic_machine=sh-unknown 1179 1046 ;; 1180 sparc | sparcv8 | sparcv9 | sparcv9b | sparcv9v) 1047 sh64) 1048 basic_machine=sh64-unknown 1049 ;; 1050 sparc | sparcv9 | sparcv9b) 1181 1051 basic_machine=sparc-sun 1182 1052 ;; … … 1251 1121 | -nindy* | -vxsim* | -vxworks* | -ebmon* | -hms* | -mvs* \ 1252 1122 | -clix* | -riscos* | -uniplus* | -iris* | -rtu* | -xenix* \ 1253 | -hiux* | -386bsd* | -knetbsd* | -mirbsd* | -netbsd* \ 1254 | -openbsd* | -solidbsd* \ 1255 | -ekkobsd* | -kfreebsd* | -freebsd* | -riscix* | -lynxos* \ 1256 | -bosx* | -nextstep* | -cxux* | -aout* | -elf* | -oabi* \ 1123 | -hiux* | -386bsd* | -netbsd* | -openbsd* | -freebsd* | -riscix* \ 1124 | -lynxos* | -bosx* | -nextstep* | -cxux* | -aout* | -elf* | -oabi* \ 1257 1125 | -ptx* | -coff* | -ecoff* | -winnt* | -domain* | -vsta* \ 1258 1126 | -udi* | -eabi* | -lites* | -ieee* | -go32* | -aux* \ 1259 1127 | -chorusos* | -chorusrdb* \ 1260 1128 | -cygwin* | -pe* | -psos* | -moss* | -proelf* | -rtems* \ 1261 | -mingw32* | -linux-gnu* | -linux-newlib* | -linux-uclibc* \ 1262 | -uxpv* | -beos* | -mpeix* | -udk* \ 1129 | -mingw32* | -msys* | -linux-gnu* | -uxpv* | -beos* | -mpeix* | -udk* \ 1263 1130 | -interix* | -uwin* | -mks* | -rhapsody* | -darwin* | -opened* \ 1264 1131 | -openstep* | -oskit* | -conix* | -pw32* | -nonstopux* \ … … 1266 1133 | -os2* | -vos* | -palmos* | -uclinux* | -nucleus* \ 1267 1134 | -morphos* | -superux* | -rtmk* | -rtmk-nova* | -windiss* \ 1268 | -powermax* | -dnix* | -nx6 | -nx7 | -sei* | -dragonfly* \ 1269 | -skyos* | -haiku* | -rdos* | -toppers* | -drops*) 1135 | -powermax* | -dnix*) 1270 1136 # Remember, each alternative MUST END IN *, to match a version number. 1271 1137 ;; … … 1285 1151 ;; 1286 1152 -sim | -es1800* | -hms* | -xray | -os68k* | -none* | -v88r* \ 1287 | -windows* | -osx | -abug | -netware* | -os9* | -beos* | -haiku*\1153 | -windows* | -osx | -abug | -netware* | -os9* | -beos* \ 1288 1154 | -macos* | -mpw* | -magic* | -mmixware* | -mon960* | -lnews*) 1289 1155 ;; … … 1291 1157 os=`echo $os | sed -e 's|mac|macos|'` 1292 1158 ;; 1293 -linux-dietlibc)1294 os=-linux-dietlibc1295 ;;1296 1159 -linux*) 1297 1160 os=`echo $os | sed -e 's|linux|linux-gnu|'` … … 1306 1169 os=-openedition 1307 1170 ;; 1308 -os400*)1309 os=-os4001310 ;;1311 1171 -wince*) 1312 1172 os=-wince … … 1329 1189 -atheos*) 1330 1190 os=-atheos 1331 ;;1332 -syllable*)1333 os=-syllable1334 1191 ;; 1335 1192 -386bsd) … … 1355 1212 os=-sysv4 1356 1213 ;; 1357 -tpf*)1358 os=-tpf1359 ;;1360 1214 -triton*) 1361 1215 os=-sysv3 … … 1393 1247 -kaos*) 1394 1248 os=-kaos 1395 ;;1396 -zvmoe)1397 os=-zvmoe1398 ;;1399 -dicos*)1400 os=-dicos1401 1249 ;; 1402 1250 -none) … … 1422 1270 1423 1271 case $basic_machine in 1424 score-*)1425 os=-elf1426 ;;1427 spu-*)1428 os=-elf1429 ;;1430 1272 *-acorn) 1431 1273 os=-riscix1.2 … … 1436 1278 arm*-semi) 1437 1279 os=-aout 1438 ;;1439 c4x-* | tic4x-*)1440 os=-coff1441 1280 ;; 1442 1281 # This must come before the *-dec entry. … … 1465 1304 os=-aout 1466 1305 ;; 1467 mep-*)1468 os=-elf1469 ;;1470 1306 mips*-cisco) 1471 1307 os=-elf … … 1486 1322 os=-beos 1487 1323 ;; 1488 *-haiku)1489 os=-haiku1490 ;;1491 1324 *-ibm) 1492 1325 os=-aix 1493 ;;1494 *-knuth)1495 os=-mmixware1496 1326 ;; 1497 1327 *-wec) … … 1627 1457 vendor=ibm 1628 1458 ;; 1629 -os400*)1630 vendor=ibm1631 ;;1632 1459 -ptx*) 1633 1460 vendor=sequent 1634 1461 ;; 1635 -tpf*)1636 vendor=ibm1637 ;;1638 1462 -vxsim* | -vxworks* | -windiss*) 1639 1463 vendor=wrs … … 1660 1484 1661 1485 echo $basic_machine$os 1662 exit 1486 exit 0 1663 1487 1664 1488 # Local variables: -
branches/blt4/gui/scripts/Makefile.in
r2690 r2742 131 131 $(srcdir)/vtkcontourviewer.tcl \ 132 132 $(srcdir)/vtkstreamlinesviewer.tcl \ 133 $(srcdir)/vtkvolumeviewer.tcl \ 134 $(srcdir)/vtkheightmapviewer.tcl \ 133 135 $(srcdir)/xylegend.tcl \ 134 136 $(srcdir)/xyprint.tcl \ -
branches/blt4/gui/scripts/field.tcl
r2690 r2742 35 35 public method flowhints { cname } 36 36 public method type {} 37 public method vtkdata {{what -overall}} 37 38 38 39 protected method _build {} … … 50 51 private variable _comp2vtk ;# maps component name => vtkFloatArray 51 52 private variable _comp2vtkstreamlines ;# maps component name => vtkFloatArray 53 private variable _comp2vtkvolume ;# maps component name => vtkFloatArray 54 private variable _comp2volume ;# maps component name => vtkFloatArray 52 55 private variable _comp2dx ;# maps component name => OpenDX data 53 56 private variable _comp2unirect2d ;# maps component name => unirect2d obj … … 201 204 return "" ;# no mesh -- it's embedded in the value data 202 205 } 206 if {[info exists _comp2vtkvolume($what)]} { 207 return "" ;# no mesh -- it's embedded in the value data 208 } 203 209 if {[info exists _comp2unirect2d($what)]} { 204 210 set mobj [lindex $_comp2unirect2d($what) 0] … … 261 267 if { [info exists _comp2vtk($what)] } { 262 268 return "" 269 } 270 if { [info exists _comp2vtkvolume($what)] } { 271 return $_comp2vtkvolume($what) 263 272 } 264 273 if { [info exists _comp2vtkstreamlines($what)] } { … … 578 587 catch {unset _comp2dims} 579 588 catch {unset _comp2style} 589 array unset _comp2volume 580 590 array unset _comp2vtkstreamlines 581 591 array unset _comp2unirect2d … … 603 613 } 604 614 } elseif {[$_field element $cname.opendx] != ""} { 605 set type "opendx" 615 global env 616 if { [info exists env(VTKVOLUME)] } { 617 set type "vtkvolume" 618 } else { 619 set type "dx" 620 } 606 621 } elseif {[$_field element $cname.dx] != ""} { 607 set type "dx" 622 global env 623 if { [info exists env(VTKVOLUME)] } { 624 set type "vtkvolume" 625 } else { 626 set type "dx" 627 } 608 628 } 609 629 set _comp2style($cname) "" … … 796 816 set _comp2style($cname) [$_field get $cname.style] 797 817 incr _counter 818 } elseif {$type == "vtkvolume"} { 819 set _comp2dims($cname) "3D" 820 # Allow redirects to another element. 821 set data [$_field get -decode no $cname.dx] 822 set data [Rappture::encoding::decode -as zb64 $data] 823 if 1 { 824 set file "/tmp/$cname.dx" 825 set f [open $file "w"] 826 puts $f $data 827 close $f 828 } 829 set data [Rappture::ConvertDxToVtk $data] 830 if 1 { 831 set file "/tmp/$cname.vtk" 832 set f [open $file "w"] 833 puts $f $data 834 close $f 835 } 836 set _comp2vtkvolume($cname) $data 837 set _comp2style($cname) [$_field get $cname.style] 838 incr _counter 798 839 } elseif {$type == "vtkstreamlines2"} { 799 840 set _comp2dims($cname) "3D" … … 801 842 set _comp2style($cname) [$_field get $cname.style] 802 843 incr _counter 803 } elseif {$type == "dx" } {844 } elseif {$type == "dx" } { 804 845 # 805 846 # HACK ALERT! Extract gzipped, base64-encoded OpenDX … … 809 850 set _comp2dims($cname) "3D" 810 851 set _comp2dx($cname) [$_field get -decode no $cname.dx] 852 if 1 { 853 set data [$_field get -decode yes $cname.dx] 854 set file "/tmp/junk.dx" 855 set f [open $file "w"] 856 puts $f $data 857 close $f 858 if { [string match "<ODX>*" $data] } { 859 set data [string range $data 5 end] 860 set _comp2dx($cname) \ 861 [Rappture::encoding::encode -as zb64 $data] 862 } 863 } 811 864 set _comp2style($cname) [$_field get $cname.style] 812 865 if {[$_field element $cname.flow] != ""} { … … 955 1008 return $_comp2extents($what) 956 1009 } 1010 1011 # ---------------------------------------------------------------------- 1012 # USAGE: blob ?<name>? 1013 # 1014 # Returns a string representing the blob of data for the mesh and values. 1015 # ---------------------------------------------------------------------- 1016 itcl::body Rappture::Field::vtkdata {{what -overall}} { 1017 if {$what == "component0"} { 1018 set what "component" 1019 } 1020 if {[info exists _comp2xy($what)]} { 1021 return "" 1022 } 1023 if { [info exists _comp2vtk($what)] } { 1024 return "" 1025 } 1026 if { [info exists _comp2vtkstreamlines($what)] } { 1027 # Return the contents of the vtk file. 1028 return $_comp2vtkstreamlines($what) 1029 } 1030 if { [info exists _comp2vtkvolume($what)] } { 1031 # Return the contents of the vtk file. 1032 return $_comp2vtkvolume($what) 1033 } 1034 if {[info exists _comp2dx($what)]} { 1035 return $_comp2dx($what) 1036 } 1037 if {[info exists _comp2unirect2d($what)]} { 1038 return [$_comp2unirect2d($what) blob] 1039 } 1040 if {[info exists _comp2unirect3d($what)]} { 1041 return [$_comp2unirect3d($what) blob] 1042 } 1043 error "bad option \"$what\": should be [join [lsort [array names _comp2dims]] {, }]" 1044 } -
branches/blt4/gui/scripts/field2dresult.tcl
r2208 r2742 61 61 set servers [Rappture::VisViewer::GetServerList "nanovis"] 62 62 } 63 "vtkcontour" {63 "vtkcontour" - "vtkheightmap" { 64 64 set servers [Rappture::VisViewer::GetServerList "vtkvis"] 65 65 } … … 76 76 itk_component add renderer { 77 77 Rappture::HeightmapViewer $itk_interior.ren $servers 78 } 79 } 80 "vtkheightmap" { 81 itk_component add renderer { 82 Rappture::VtkHeightmapViewer $itk_interior.ren $servers 78 83 } 79 84 } -
branches/blt4/gui/scripts/field3dresult.tcl
r2534 r2742 59 59 set servers [Rappture::VisViewer::GetServerList "nanovis"] 60 60 } 61 "vtkcontour" - "vtkstreamlines" {61 "vtkcontour" - "vtkstreamlines" - "vtkvolume" - "vtkviewer" { 62 62 set servers [Rappture::VisViewer::GetServerList "vtkvis"] 63 63 } … … 81 81 Rappture::FlowvisViewer $itk_interior.ren $servers 82 82 } 83 } 84 "vtkvolume" { 85 catch { 86 itk_component add renderer { 87 Rappture::VtkVolumeViewer $itk_interior.ren $servers 88 } 89 } errs 90 puts stderr errs=$errs 83 91 } 84 92 "vtkstreamlines" { -
branches/blt4/gui/scripts/molvisviewer.tcl
r2692 r2742 601 601 0,1 $f.cancel 602 602 blt::table $inner \ 603 0,0 $inner.pdb -anchor w \ 604 1,0 $inner.image -anchor w \ 605 2,0 $f -fill x -pady 4 603 0,0 $inner.summary -anchor w \ 604 1,0 $inner.pdb -anchor w \ 605 2,0 $inner.image -anchor w \ 606 3,0 $f -fill x -pady 4 606 607 $inner.pdb select 607 608 } else { … … 1209 1210 set _view(c) $c 1210 1211 if { !$_rotatePending } { 1211 $_dispatcher event -after 50 !rotate1212 $_dispatcher event -after 100 !rotate 1212 1213 set _rotatePending 1 1213 1214 } -
branches/blt4/gui/scripts/nanovisviewer.tcl
r2048 r2742 156 156 private variable _first "" ;# This is the topmost volume. 157 157 private variable _buffering 0 158 158 159 159 # This 160 160 # indicates which isomarkers and transfer … … 181 181 # ---------------------------------------------------------------------- 182 182 itcl::body Rappture::NanovisViewer::constructor {hostlist args} { 183 set _serverType "nanovis" 183 184 184 185 # Draw legend event … … 237 238 238 239 itk_component add 3dview { 239 label $itk_component(plotarea).v ol-image $_image(plot) \240 label $itk_component(plotarea).view -image $_image(plot) \ 240 241 -highlightthickness 0 -borderwidth 0 241 242 } { … … 749 750 if { ![info exists _vol2style($vol)] } { 750 751 puts stderr "unknown volume $vol" 751 continue; 752 continue; # How does this happen? 752 753 } 753 754 set tf $_vol2style($vol) … … 843 844 } 844 845 } 846 847 # The colormap may have changed. Resync the slicers with the colormap. 848 set vols [CurrentVolumes -cutplanes] 849 SendCmd "volume data state $_settings($this-volume) $vols" 850 851 # Adjust the cutplane for only the first component in the topmost volume 852 # (i.e. the first volume designated in the field). 853 set vol [lindex $vols 0] 854 foreach axis {x y z} { 855 # Turn off cutplanes for all volumes 856 SendCmd "cutplane state 0 $axis" 857 if { $_settings($this-${axis}cutplane) } { 858 # Turn on cutplane for this particular volume and set the position 859 SendCmd "cutplane state 1 $axis $vol" 860 set pos [expr {0.01*$_settings($this-${axis}cutposition)}] 861 SendCmd "cutplane position $pos $axis $vol" 862 } 863 } 845 864 } 846 865 … … 985 1004 updatetransferfuncs 986 1005 } 987 988 # Sync the state of slicers989 set vols [CurrentVolumes -cutplanes]990 1006 foreach axis {x y z} { 991 SendCmd "cutplane state $_settings($this-${axis}cutplane) $axis $vols" 992 set pos [expr {0.01*$_settings($this-${axis}cutposition)}] 993 SendCmd "cutplane position $pos $axis $vols" 994 } 995 SendCmd "volume data state $_settings($this-volume) $vols" 996 set _buffering 0; # Turn off buffering. 1007 # Turn off cutplanes for all volumes 1008 SendCmd "cutplane state 0 $axis" 1009 } 1010 set _buffering 0; # Turn off buffering. 997 1011 # Actually write the commands to the server socket. If it fails, we don't 998 1012 # care. We're finished here. 999 1013 blt::busy hold $itk_component(hull) 1000 SendBytes $_outbuf; 1014 SendBytes $_outbuf; 1001 1015 blt::busy release $itk_component(hull) 1002 set _outbuf ""; # Clear the buffer.1016 set _outbuf ""; # Clear the buffer. 1003 1017 } 1004 1018 … … 1022 1036 } 1023 1037 array set style [lindex [$_first components -style $comp] 0] 1024 if { $what != "-cutplanes" || $style(-cutplanes)} {1038 if { $what != "-cutplanes" || $style(-cutplanes) } { 1025 1039 lappend rlist $vol 1026 1040 } … … 1300 1314 if { [isconnected] } { 1301 1315 set vols [CurrentVolumes -cutplanes] 1302 SendCmd "cutplane state $bool $axis $vols" 1316 set vol [lindex $vols 0] 1317 SendCmd "cutplane state $bool $axis $vol" 1303 1318 } 1304 1319 if { $bool } { … … 1992 2007 set newpos [expr {0.01*$newval}] 1993 2008 set vols [CurrentVolumes -cutplanes] 1994 SendCmd "cutplane position $newpos $axis $vols" 2009 set vol [lindex $vols 0] 2010 SendCmd "cutplane position $newpos $axis $vol" 1995 2011 } 1996 2012 default { -
branches/blt4/gui/scripts/numberresult.tcl
r2716 r2742 875 875 set g $itk_component(plot) 876 876 set elem "" 877 877 878 878 # Peek inside of Blt_ZoomStack package to see if we're currently in the 879 879 # middle of a zoom selection. … … 889 889 # for dealing with xy line plots 890 890 set elem $info(name) 891 892 891 # Some elements are generated dynamically and therefore will 893 # not have a data objobject associated with them.892 # not have a data object associated with them. 894 893 set mapx [$g element cget $elem -mapx] 895 894 set mapy [$g element cget $elem -mapy] -
branches/blt4/gui/scripts/resultset.tcl
r2048 r2742 1095 1095 } 1096 1096 if { $_active == "" } { 1097 return 1097 return; # Nothing active. Don't do anything. 1098 1098 } 1099 1099 eval lappend params [_getValues $_active all] … … 1527 1527 if {$col == "xmlobj"} { 1528 1528 set val "#[expr {$which+1}]" 1529 } else { 1530 set val [lindex [$_results get -format $col $which] 0] 1529 } else { 1530 # Be careful giving singleton elements as the "columns" 1531 # argument to "Tuples::get". It is expecting a list. 1532 set val [lindex [$_results get -format [list $col] $which] 0] 1531 1533 } 1532 1534 if {[info exists label2val($val)]} { … … 1620 1622 foreach col $_cntlInfo($this-all) { 1621 1623 set quantity $_cntlInfo($this-$col-label) 1622 set val [lindex [$_results get -format $col $index] 0] 1624 # Be careful giving singleton elements as the "columns" 1625 # argument to "Tuples::get". It is expecting a list. 1626 set val [lindex [$_results get -format [list $col] $index] 0] 1623 1627 if {$col == "xmlobj"} { 1624 1628 set num [lindex [$_results find -format xmlobj $val] 0] -
branches/blt4/gui/scripts/resultviewer.tcl
r2561 r2742 220 220 set servers [Rappture::VisViewer::GetServerList "vtkvis"] 221 221 set w $itk_interior.vtkviewer 222 catch { Rappture::VtkViewer $w $servers } errs 223 puts stderr errs=$errs 222 Rappture::VtkViewer $w $servers 224 223 set _mode2widget($mode) $w 225 224 } … … 267 266 if { [$dataobj hints type] == "contour" } { 268 267 set resultMode "vtkcontour" 268 } elseif { [info exists env(VTKHEIGHTMAP)] } { 269 set resultMode "vtkheightmap" 269 270 } else { 270 271 set resultMode "heightmap" … … 298 299 } 299 300 } 301 "vtkvolume" { 302 set fmt "vtkvolume" 303 } 300 304 "vtkstreamlines" { 301 305 set fmt "vtkstreamlines" -
branches/blt4/gui/scripts/sequenceresult.tcl
r2201 r2742 397 397 global readyForNextFrame 398 398 set readyForNextFrame 1; # By default, always ready 399 400 # toggle the button to "play" mode 401 $itk_component(play) configure \ 402 -bitmap [Rappture::icon play] \ 403 -command [itcl::code $this play] 399 400 # Check if the play button still exists. We may be in the process 401 # of destroying the widget. 402 if { [info exists itk_component(play)] } { 403 # toggle the button to "play" mode 404 $itk_component(play) configure \ 405 -bitmap [Rappture::icon play] \ 406 -command [itcl::code $this play] 407 } 404 408 } 405 409 -
branches/blt4/gui/scripts/sidebarframe.tcl
r2559 r2742 310 310 # argument can be a panel index, name, or title. 311 311 # ---------------------------------------------------------------------- 312 itcl::body Rappture::SidebarFrame::select { 312 itcl::body Rappture::SidebarFrame::select {which} { 313 313 set pname "" 314 314 switch -glob -- $which { -
branches/blt4/gui/scripts/tool.tcl
r2646 r2742 206 206 207 207 if { $status != 0 } { 208 foreach { pstatuspid mesg} $::Rappture::Tool::job(control) break209 if { $ pstatus!= "EXITED" } {210 set result "Abnormal program termination \"$ pstatus\": $mesg"208 foreach {code pid mesg} $::Rappture::Tool::job(control) break 209 if { $code != "EXITED" } { 210 set result "Abnormal program termination \"$code\": $mesg" 211 211 return [list $status $result] 212 212 } 213 213 } 214 214 } 215 215 # ...job is finished 216 216 array set times [Rappture::rusage measure] 217 217 218 if {[resources -jobprotocol] != "submit"} { 218 219 set id [$_xmlobj get tool.id] -
branches/blt4/gui/scripts/visviewer.tcl
r2537 r2742 25 25 set _servers(vtkvis) "localhost:2010" 26 26 27 protected variable _sid "" ;# socket connection to server 28 private common _done ;# Used to indicate status of send. 29 private variable _buffer ;# buffer for incoming/outgoing commands 27 protected variable _serverType "???";# Type of server. 28 protected variable _sid "" ; # socket connection to server 29 private common _done ; # Used to indicate status of send. 30 private variable _buffer ; # buffer for incoming/outgoing commands 30 31 private variable _initialized 31 32 private variable _isOpen 0 33 private variable _afterId -1 34 private variable _icon 0 35 32 36 # Number of milliseconds to wait before idle timeout. 33 37 # If greater than 0, automatically disconnect from the visualization … … 37 41 #private variable _idleTimeout 0; # No timeout 38 42 39 protected variable _dispatcher "" ;# dispatcher for !events40 protected variable _hosts "" ; # list of hosts for server41 protected variable _parser "" ; # interpreter for incoming commands43 protected variable _dispatcher ""; # dispatcher for !events 44 protected variable _hosts "" ; # list of hosts for server 45 protected variable _parser "" ; # interpreter for incoming commands 42 46 protected variable _image 43 47 protected variable _hostname … … 56 60 private method SendHelper.old {} 57 61 private method CheckConnection {} 62 private method SplashScreen { state } 58 63 59 64 protected method SendEcho { channel {data ""} } … … 67 72 protected method Color2RGB { color } 68 73 protected method Euler2XYZ { theta phi psi } 74 protected method StartWaiting {} 75 protected method StopWaiting {} 76 77 private method Waiting { option widget } 69 78 70 79 private proc CheckNameList { namelist } { 71 set pattern {^[a-zA-Z0-9\.]+:[0-9]+(,[a-zA-Z0-9\.]+:[0-9]+)*$} 72 if { ![regexp $pattern $namelist match] } { 73 error "bad visualization server address \"$namelist\": should be host:port,host:port,..." 80 foreach host $namelist { 81 set pattern {^[a-zA-Z0-9\.]+:[0-9]} 82 if { ![regexp $pattern $host match] } { 83 error "bad visualization server address \"$host\": should be host:port,host:port,..." 84 } 74 85 } 75 86 } 76 public proc GetServerList { tag } { 77 return $_servers($tag) 78 } 79 public proc SetServerList { tag namelist } { 87 public proc GetServerList { type } { 88 return $_servers($type) 89 } 90 public proc SetServerList { type namelist } { 91 # Convert the comma separated list into a Tcl list. OGRE also adds 92 # a trailing comma that we want to ignore. 93 regsub -all "," $namelist " " namelist 80 94 CheckNameList $namelist 81 set _servers($tag) $namelist 95 set _servers($type) $namelist 96 } 97 public proc RemoveServerFromList { type server } { 98 if { ![info exists _servers($type)] } { 99 error "unknown server type \"$type\"" 100 } 101 set i [lsearch $_servers($type) $server] 102 if { $i < 0 } { 103 return 104 } 105 set _servers($type) [lreplace $_servers($type) $i $i] 82 106 } 83 107 public proc SetPymolServerList { namelist } { … … 106 130 $_dispatcher register !timeout 107 131 $_dispatcher dispatch $this !timeout "[itcl::code $this Disconnect]; list" 132 133 $_dispatcher register !waiting 108 134 109 135 CheckNameList $hostlist … … 118 144 $_parser hide $cmd 119 145 } 120 121 146 # 122 147 # Set up the widgets in the main body … … 155 180 # Shuffle the list of server hosts. 156 181 # 157 itcl::body Rappture::VisViewer::Shuffle { hostlist } { 158 set hosts [split $hostlist ,] 182 itcl::body Rappture::VisViewer::Shuffle { hosts } { 159 183 set randomHosts {} 160 184 set ticks [clock clicks] … … 200 224 itcl::body Rappture::VisViewer::Connect { hostlist } { 201 225 blt::busy hold $itk_component(hull) -cursor watch 202 # Can't call update because of all the pending stuff going on 203 #update 204 205 # Shuffle the list of servers so as to pick random 206 set servers [Shuffle $hostlist] 207 208 # Get the first server 209 foreach {hostname port} [split [lindex $servers 0] :] break 210 set servers [lrange $servers 1 end] 211 212 while {1} { 213 puts stderr "connecting to $hostname:$port..." 226 227 puts stderr "server type is $_serverType" 228 foreach server [Shuffle $hostlist] { 229 puts stderr "connecting to $server..." 230 foreach {hostname port} [split $server ":"] break 214 231 if { [catch {socket $hostname $port} _sid] != 0 } { 215 232 set _sid "" 216 if {[llength $servers] == 0} { 217 blt::busy release $itk_component(hull) 218 return 0 219 } 220 # Get the next server 221 foreach {hostname port} [split [lindex $servers 0] :] break 222 set servers [lrange $servers 1 end] 223 continue 224 } 225 set _hostname $hostname:$port 233 RemoveServerFromList $_serverType $server 234 continue 235 } 236 set _hostname $server 226 237 fconfigure $_sid -translation binary -encoding binary 227 238 228 # Read back a reconnection order239 # Read back the server identification string. 229 240 if { [gets $_sid data] <= 0 } { 230 error "reading from server" 241 set _sid "" 242 puts stderr "reading from server" 243 RemoveServerFromList $_serverType $server 244 continue 231 245 } 232 246 puts stderr "render server is $data" … … 242 256 return 1 243 257 } 244 #NOTREACHED245 258 blt::busy release $itk_component(hull) 259 set x [expr {[winfo rootx $itk_component(hull)]+10}] 260 set y [expr {[winfo rooty $itk_component(hull)]+10}] 261 Rappture::Tooltip::cue @$x,$y "Can't connect to any $_serverType visualization server. This may be a network problem. Wait a few moments and try resetting the view." 246 262 return 0 247 263 } … … 254 270 # 255 271 itcl::body Rappture::VisViewer::Disconnect {} { 272 after cancel $_afterId 256 273 $_dispatcher cancel !timeout 257 274 catch {close $_sid} … … 307 324 Rappture::Tooltip::cue hide 308 325 } else { 309 Rappture::Tooltip::cue @$x,$y "Can't connect to visualization server. This may be a network problem. Wait a few moments and try resetting the view."326 Rappture::Tooltip::cue @$x,$y "Can't connect to any $_serverType visualization server. This may be a network problem. Wait a few moments and try resetting the view." 310 327 return 0 311 328 } … … 400 417 flush $_sid 401 418 } 402 if 0 {403 if { ![CheckConnection] } {404 puts stderr "connection is now down"405 return 0406 }407 }408 419 return $_done($this) 420 } 421 422 # 423 # ReceiveBytes -- 424 # 425 # Read some number of bytes from the visualization server. 426 # 427 itcl::body Rappture::VisViewer::StartWaiting {} { 428 after cancel $_afterId 429 set _afterId [after 500 [itcl::code $this SplashScreen on]] 430 } 431 432 itcl::body Rappture::VisViewer::StopWaiting {} { 433 SplashScreen off 409 434 } 410 435 … … 539 564 } 540 565 } 566 567 itcl::body Rappture::VisViewer::SplashScreen { state } { 568 after cancel $_afterId 569 set _afterId -1 570 if { $state } { 571 if { [winfo exists $itk_component(plotarea).view.splash] } { 572 return 573 } 574 set inner [frame $itk_component(plotarea).view.splash] 575 $inner configure -relief raised -bd 2 576 label $inner.text1 -text "Rendering, please wait." \ 577 -font "Arial 10" 578 label $inner.icon 579 pack $inner -expand yes -anchor c 580 blt::table $inner \ 581 0,0 $inner.text1 -anchor w \ 582 0,1 $inner.icon 583 Waiting start $inner.icon 584 } else { 585 if { ![winfo exists $itk_component(plotarea).view.splash] } { 586 return 587 } 588 Waiting stop $itk_component(plotarea).view.splash 589 destroy $itk_component(plotarea).view.splash 590 } 591 } 592 593 itcl::body Rappture::VisViewer::Waiting { option widget } { 594 switch -- $option { 595 "start" { 596 $_dispatcher dispatch $this !waiting \ 597 "[itcl::code $this Waiting "next" $widget] ; list" 598 set _icon 0 599 $widget configure -image [Rappture::icon bigroller${_icon}] 600 $_dispatcher event -after 150 !waiting 601 } 602 "next" { 603 incr _icon 604 if { $_icon >= 8 } { 605 set _icon 0 606 } 607 $widget configure -image [Rappture::icon bigroller${_icon}] 608 $_dispatcher event -after 150 !waiting 609 } 610 "stop" { 611 $_dispatcher cancel !waiting 612 } 613 } 614 } -
branches/blt4/gui/scripts/vtkcontourviewer.tcl
r2591 r2742 144 144 # ---------------------------------------------------------------------- 145 145 itcl::body Rappture::VtkContourViewer::constructor {hostlist args} { 146 set _serverType "vtkvis" 146 147 package require vtk 147 148 # Draw legend event … … 790 791 set _image(legend) [image create picture] 791 792 } 793 $_image(legend) configure -data $bytes 792 794 puts stderr "read $size bytes for [image width $_image(legend)]x[image height $_image(legend)] legend>" 793 set src [image create picture -data $bytes]794 blt::winop image rotate $src $_image(legend) 90795 set dst $_image(legend)796 795 DrawLegend 797 796 } -
branches/blt4/gui/scripts/vtkstreamlinesviewer.tcl
r2591 r2742 68 68 protected method Disconnect {} 69 69 protected method DoResize {} 70 protected method DoReseed {} 70 71 protected method DoRotate {} 71 72 protected method AdjustSetting {what {value ""}} 72 protected method FixSettings { args }73 protected method InitSettings { args } 73 74 protected method Pan {option x y} 74 75 protected method Pick {x y} … … 79 80 protected method Rotate {option x y} 80 81 protected method SendCmd {string} 82 protected method SendCmdNoWait {string} 81 83 protected method Zoom {option} 82 84 … … 84 86 private method BuildAxisTab {} 85 87 private method BuildCameraTab {} 86 private method BuildColormap { colormap dataobj comp}87 private method BuildCut awayTab {}88 private method BuildColormap { name colors } 89 private method BuildCutplaneTab {} 88 90 private method BuildDownloadPopup { widget command } 89 91 private method BuildStreamsTab {} 90 92 private method BuildVolumeTab {} 91 93 private method ConvertToVtkData { dataobj comp } 92 private method DrawLegend {} 94 private method DrawLegend { title } 95 private method Combo { option } 93 96 private method EnterLegend { x y } 94 97 private method EventuallyResize { w h } 98 private method EventuallyReseed { numPoints } 95 99 private method EventuallyRotate { q } 100 private method EventuallySetCutplane { axis args } 96 101 private method GetImage { args } 97 102 private method GetVtkData { args } … … 102 107 private method RequestLegend {} 103 108 private method SetColormap { dataobj comp } 109 private method ChangeColormap { dataobj comp color } 110 private method ColorsToColormap { color } 104 111 private method SetLegendTip { x y } 105 112 private method SetObjectStyle { dataobj comp } … … 107 114 108 115 private variable _arcball "" 109 private variable _outbuf ;# buffer for outgoing commands 110 111 private variable _dlist "" ;# list of data objects 112 private variable _allDataObjs 116 private variable _outbuf ; # buffer for outgoing commands 117 118 private variable _dlist "" ; # list of data objects 113 119 private variable _obj2datasets 114 private variable _obj2ovride ; # maps dataobj => style override115 private variable _datasets ; # contains all the dataobj-component116 ; # datasets in the server117 private variable _colormaps ; # contains all the colormaps118 ; # in the server.120 private variable _obj2ovride ; # maps dataobj => style override 121 private variable _datasets ; # contains all the dataobj-component 122 ; # datasets in the server 123 private variable _colormaps ; # contains all the colormaps 124 ; # in the server. 119 125 private variable _dataset2style ;# maps dataobj-component to transfunc 120 private variable _style2datasets ;# maps tf back to list of 121 # dataobj-components using the tf. 122 123 private variable _click ;# info used for rotate operations 124 private variable _limits ;# autoscale min/max for all axes 125 private variable _view ;# view params for 3D view 126 127 private variable _click ; # info used for rotate operations 128 private variable _limits ; # autoscale min/max for all axes 129 private variable _view ; # view params for 3D view 126 130 private variable _settings 127 private variable _volume 128 private variable _axis 129 private variable _streamlines 130 private variable _reset 1 ;# indicates if camera needs to be reset 131 # to starting position. 132 133 private variable _first "" ;# This is the topmost dataset. 131 private variable _style; # Array of current component styles. 132 private variable _initialStyle; # Array of initial component styles. 133 private variable _reset 1; # indicates if camera needs to be reset 134 # to starting position. 135 136 private variable _first "" ; # This is the topmost dataset. 134 137 private variable _start 0 135 138 private variable _buffering 0 … … 137 140 private variable _seeds 138 141 139 common _downloadPopup ;# download options from popup142 common _downloadPopup; # download options from popup 140 143 private common _hardcopy 141 144 private variable _width 0 142 145 private variable _height 0 143 146 private variable _resizePending 0 147 private variable _reseedPending 0 144 148 private variable _rotatePending 0 149 private variable _cutplanePending 0 150 private variable _legendPending 0 145 151 private variable _outline 152 private variable _vectorFields 153 private variable _scalarFields 154 private variable _fields 155 private variable _currentField "" 156 private variable _field "" 157 private variable _numSeeds 200 158 private variable _colorMode "vmag";# Mode of colormap (vmag or scalar) 146 159 } 147 160 … … 155 168 # ---------------------------------------------------------------------- 156 169 itcl::body Rappture::VtkStreamlinesViewer::constructor {hostlist args} { 170 set _serverType "vtkvis" 157 171 package require vtk 172 158 173 # Rebuild event 159 174 $_dispatcher register !rebuild … … 164 179 $_dispatcher dispatch $this !resize "[itcl::code $this DoResize]; list" 165 180 181 # Reseed event 182 $_dispatcher register !reseed 183 $_dispatcher dispatch $this !reseed "[itcl::code $this DoReseed]; list" 184 166 185 # Rotate event 167 186 $_dispatcher register !rotate 168 187 $_dispatcher dispatch $this !rotate "[itcl::code $this DoRotate]; list" 169 188 170 set _outbuf "" 189 # Legend event 190 $_dispatcher register !legend 191 $_dispatcher dispatch $this !legend "[itcl::code $this RequestLegend]; list" 192 193 # X-Cutplane event 194 $_dispatcher register !xcutplane 195 $_dispatcher dispatch $this !xcutplane \ 196 "[itcl::code $this AdjustSetting cutplane-xposition]; list" 197 198 # Y-Cutplane event 199 $_dispatcher register !ycutplane 200 $_dispatcher dispatch $this !ycutplane \ 201 "[itcl::code $this AdjustSetting cutplane-yposition]; list" 202 203 # Z-Cutplane event 204 $_dispatcher register !zcutplane 205 $_dispatcher dispatch $this !zcutplane \ 206 "[itcl::code $this AdjustSetting cutplane-zposition]; list" 171 207 172 208 # … … 203 239 set _limits(zmax) 1.0 204 240 205 array set _axis [subst {206 xgrid 0207 ygrid 0208 zgrid 0209 xcutaway 0210 ycutaway 0211 zcutaway 0212 xposition 0213 yposition 0214 zposition 0215 xdirection -1216 ydirection -1217 zdirection -1218 visible 1219 labels 1220 }]221 array set _volume [subst {222 edges 0223 lighting 1224 opacity 40225 visible 1226 wireframe 0227 }]228 array set _streamlines [subst {229 seeds 0230 visible 1231 opacity 100232 }]233 241 array set _settings [subst { 234 legend 1 242 axis-xgrid 0 243 axis-ygrid 0 244 axis-zgrid 0 245 axis-xcutplane 0 246 axis-ycutplane 0 247 axis-zcutplane 0 248 axis-xposition 0 249 axis-yposition 0 250 axis-zposition 0 251 axis-visible 1 252 axis-labels 1 253 cutplane-edges 0 254 cutplane-xvisible 0 255 cutplane-yvisible 0 256 cutplane-zvisible 0 257 cutplane-xposition 50 258 cutplane-yposition 50 259 cutplane-zposition 50 260 cutplane-visible 1 261 cutplane-wireframe 0 262 cutplane-opacity 100 263 volume-edges 0 264 volume-lighting 1 265 volume-opacity 40 266 volume-visible 1 267 volume-wireframe 0 268 streamlines-seeds 0 269 streamlines-visible 1 270 streamlines-opacity 100 271 streamlines-numpoints 200 272 streamlines-lighting 1 273 streamlines-scale 1 274 legend-visible 1 235 275 }] 236 276 … … 243 283 } 244 284 285 itk_component add fieldmenu { 286 menu $itk_component(plotarea).menu -bg black -fg white -relief flat \ 287 -tearoff no 288 } { 289 usual 290 ignore -background -foreground -relief -tearoff 291 } 245 292 set c $itk_component(view) 246 293 bind $c <Configure> [itcl::code $this EventuallyResize %w %h] … … 299 346 Rappture::Tooltip::for $itk_component(zoomout) "Zoom out" 300 347 348 itk_component add volume { 349 Rappture::PushButton $f.volume \ 350 -onimage [Rappture::icon volume-on] \ 351 -offimage [Rappture::icon volume-off] \ 352 -variable [itcl::scope _settings(volume-visible)] \ 353 -command [itcl::code $this AdjustSetting volume-visible] 354 } 355 $itk_component(volume) select 356 Rappture::Tooltip::for $itk_component(volume) \ 357 "Don't display the volume" 358 pack $itk_component(volume) -padx 2 -pady 2 359 360 itk_component add streamlines { 361 Rappture::PushButton $f.streamlines \ 362 -onimage [Rappture::icon streamlines-on] \ 363 -offimage [Rappture::icon streamlines-off] \ 364 -variable [itcl::scope _settings(streamlines-visible)] \ 365 -command [itcl::code $this AdjustSetting streamlines-visible] \ 366 } 367 $itk_component(streamlines) select 368 Rappture::Tooltip::for $itk_component(streamlines) \ 369 "Toggle the streamlines on/off" 370 pack $itk_component(streamlines) -padx 2 -pady 2 371 372 itk_component add cutplane { 373 Rappture::PushButton $f.cutplane \ 374 -onimage [Rappture::icon cutbutton] \ 375 -offimage [Rappture::icon cutbutton] \ 376 -variable [itcl::scope _settings(cutplane-visible)] \ 377 -command [itcl::code $this AdjustSetting cutplane-visible] 378 } 379 $itk_component(cutplane) select 380 Rappture::Tooltip::for $itk_component(cutplane) \ 381 "Show/Hide cutplanes" 382 pack $itk_component(cutplane) -padx 2 -pady 2 383 384 301 385 if { [catch { 302 386 BuildVolumeTab 303 387 BuildStreamsTab 388 BuildCutplaneTab 304 389 BuildAxisTab 305 BuildCutawayTab306 390 BuildCameraTab 307 391 } errs] != 0 } { … … 389 473 eval itk_initialize $args 390 474 Connect 475 update 391 476 } 392 477 … … 396 481 itcl::body Rappture::VtkStreamlinesViewer::destructor {} { 397 482 Disconnect 398 $_dispatcher cancel !rebuild399 $_dispatcher cancel !resize400 $_dispatcher cancel !rotate401 483 image delete $_image(plot) 402 484 image delete $_image(download) … … 411 493 set _height 500 412 494 } 413 #puts stderr "DoResize screen size $_width $_height"414 495 set _start [clock clicks -milliseconds] 415 #puts stderr "screen size request width=$_width height=$_height"416 496 SendCmd "screen size $_width $_height" 417 RequestLegend497 set _legendPending 1 418 498 419 499 #SendCmd "imgflush" … … 431 511 } 432 512 513 itcl::body Rappture::VtkStreamlinesViewer::DoReseed {} { 514 foreach dataset [CurrentDatasets -visible] { 515 foreach {dataobj comp} [split $dataset -] break 516 # This command works for either random or fmesh seeds 517 SendCmd "streamlines seed numpts $_numSeeds $dataset" 518 } 519 set _reseedPending 0 520 } 521 433 522 itcl::body Rappture::VtkStreamlinesViewer::EventuallyResize { w h } { 434 #puts stderr "EventuallyResize $w $h"435 523 set _width $w 436 524 set _height $h … … 438 526 if { !$_resizePending } { 439 527 set _resizePending 1 440 $_dispatcher event -after 200 !resize 528 $_dispatcher event -after 400 !resize 529 } 530 } 531 532 itcl::body Rappture::VtkStreamlinesViewer::EventuallyReseed { numPoints } { 533 set _numSeeds $numPoints 534 if { !$_reseedPending } { 535 set _reseedPending 1 536 $_dispatcher event -after 600 !reseed 441 537 } 442 538 } … … 445 541 446 542 itcl::body Rappture::VtkStreamlinesViewer::EventuallyRotate { q } { 447 #puts stderr "EventuallyRotate $w $h"448 543 foreach { _view(qw) _view(qx) _view(qy) _view(qz) } $q break 449 544 if { !$_rotatePending } { … … 451 546 global rotate_delay 452 547 $_dispatcher event -after $rotate_delay !rotate 548 } 549 } 550 551 itcl::body Rappture::VtkStreamlinesViewer::EventuallySetCutplane { axis args } { 552 if { !$_cutplanePending } { 553 set _cutplanePending 1 554 $_dispatcher event -after 100 !${axis}cutplane 453 555 } 454 556 } … … 489 591 lappend _dlist $dataobj 490 592 } 491 set _allDataObjs($dataobj) 1492 593 set _obj2ovride($dataobj-color) $params(-color) 493 594 set _obj2ovride($dataobj-width) $params(-width) … … 518 619 # Remove it from the dataobj list. 519 620 set _dlist [lreplace $_dlist $pos $pos] 520 foreach comp [$dataobj components] { 521 SendCmd "dataset visible 0 $dataobj-$comp" 522 } 621 SendCmd "dataset visible 0" 523 622 array unset _obj2ovride $dataobj-* 623 array unset _settings $dataobj-* 524 624 # Append to the end of the dataobj list. 525 625 lappend _dlist $dataobj … … 571 671 } 572 672 if { ![info exists _obj2ovride($dataobj-raise)] } { 573 # No setting indicates that the object isn't invisible.673 # No setting indicates that the object isn't visible. 574 674 continue 575 675 } … … 707 807 # ---------------------------------------------------------------------- 708 808 itcl::body Rappture::VtkStreamlinesViewer::Connect {} { 709 #puts stderr "Enter Connect: [info level -1]"710 809 set _hosts [GetServerList "vtkvis"] 711 810 if { "" == $_hosts } { … … 714 813 set result [VisViewer::Connect $_hosts] 715 814 if { $result } { 716 #puts stderr "Connected to $_hostname sid=$_sid"717 815 set w [winfo width $itk_component(view)] 718 816 set h [winfo height $itk_component(view)] … … 748 846 VisViewer::Disconnect 749 847 848 $_dispatcher cancel !rebuild 849 $_dispatcher cancel !resize 850 $_dispatcher cancel !reseed 851 $_dispatcher cancel !rotate 852 $_dispatcher cancel !xcutplane 853 $_dispatcher cancel !ycutplane 854 $_dispatcher cancel !zcutplane 855 $_dispatcher cancel !legend 750 856 # disconnected -- no more data sitting on server 751 857 set _outbuf "" … … 753 859 array unset _data 754 860 array unset _colormaps 861 array unset _seeds 862 array unset _dataset2style 863 array unset _obj2datasets 755 864 } 756 865 … … 760 869 itcl::body Rappture::VtkStreamlinesViewer::sendto { bytes } { 761 870 SendBytes "$bytes\n" 871 StartWaiting 762 872 } 763 873 … … 774 884 } else { 775 885 SendBytes "$string\n" 886 StartWaiting 887 } 888 } 889 890 # 891 # SendCmdNoWait 892 # 893 # Send commands off to the rendering server. If we're currently 894 # sending data objects to the server, buffer the commands to be 895 # sent later. 896 # 897 itcl::body Rappture::VtkStreamlinesViewer::SendCmdNoWait {string} { 898 if { $_buffering } { 899 append _outbuf $string "\n" 900 } else { 901 SendBytes "$string\n" 776 902 } 777 903 } … … 792 918 array set info $args 793 919 set bytes [ReceiveBytes $info(-bytes)] 920 StopWaiting 794 921 if { $info(-type) == "image" } { 795 922 if 0 { … … 810 937 set tag $this-print-$info(-token) 811 938 set _hardcopy($tag) $bytes 939 } 940 if { $_legendPending } { 941 RequestLegend 812 942 } 813 943 } … … 863 993 # ---------------------------------------------------------------------- 864 994 itcl::body Rappture::VtkStreamlinesViewer::Rebuild {} { 865 995 update 866 996 set w [winfo width $itk_component(view)] 867 997 set h [winfo height $itk_component(view)] … … 871 1001 } 872 1002 1003 set _buffering 1 1004 set _legendPending 1 873 1005 # Turn on buffering of commands to the server. We don't want to 874 1006 # be preempted by a server disconnect/reconnect (which automatically 875 1007 # generates a new call to Rebuild). 876 set _buffering 1877 878 1008 set _width $w 879 1009 set _height $h … … 892 1022 DoRotate 893 1023 PanCamera 894 set _first [lindex [get -objects] 0] 895 if { $_reset || $_first == "" } { 896 Zoom reset 897 set _reset 0 898 } 899 FixSettings axis-xgrid axis-ygrid axis-zgrid axis-mode \ 900 axis-visible axis-labels \ 901 streamlines-seeds streamlines-visible streamlines-opacity \ 902 volume-edges volume-lighting volume-opacity volume-visible \ 903 volume-wireframe 904 905 #SendCmd "imgflush" 1024 set _first "" 1025 InitSettings axis-xgrid axis-ygrid axis-zgrid axis-mode \ 1026 axis-visible axis-labels cutplane-visible \ 1027 cutplane-xposition cutplane-yposition cutplane-zposition \ 1028 cutplane-xvisible cutplane-yvisible cutplane-zvisible 1029 1030 SendCmd "imgflush" 906 1031 907 1032 set _limits(zmin) "" … … 921 1046 append _outbuf $bytes 922 1047 set _datasets($tag) 1 1048 SetObjectStyle $dataobj $comp 923 1049 } 924 1050 lappend _obj2datasets($dataobj) $tag … … 928 1054 SendCmd "dataset visible 0 $tag" 929 1055 } 930 SetObjectStyle $dataobj $comp931 1056 } 932 1057 } … … 936 1061 array set view $location 937 1062 } 938 } 939 foreach axis { x y z } { 940 set label [$_first hints ${axis}label] 941 if { $label != "" } { 942 SendCmd "axis name $axis $label" 943 } 944 set units [$_first hints ${axis}units] 945 if { $units != "" } { 946 SendCmd "axis units $axis $units" 947 } 948 } 949 1063 1064 if 0 { 1065 # Tell the server the name of the tool, the version, and dataset 1066 # that we are rendering. Have to do it here because we don't know 1067 # what data objects are using the renderer until be get here. 1068 set args "" 1069 lappend args tool [$_first hints toolId] 1070 lappend args version [$_first hints toolRevision] 1071 lappend args dataset [$_first hints label] 1072 SendCmd "clientinfo $args" 1073 } 1074 1075 foreach axis { x y z } { 1076 set label [$_first hints ${axis}label] 1077 if { $label != "" } { 1078 SendCmd "axis name $axis $label" 1079 } 1080 set units [$_first hints ${axis}units] 1081 if { $units != "" } { 1082 SendCmd "axis units $axis $units" 1083 } 1084 } 1085 array unset _scalarFields 1086 array unset _vectorFields 1087 set _currentField [$_first hints default] 1088 $itk_component(field) choices delete 0 end 1089 $itk_component(fieldmenu) delete 0 end 1090 array unset _fields 1091 foreach { name title units } [$_first hints vectors] { 1092 set _vectorFields($title) $name 1093 $itk_component(field) choices insert end "$name" "$title" 1094 $itk_component(fieldmenu) add radiobutton -label "$title" \ 1095 -value $title -variable [itcl::scope _currentField] \ 1096 -selectcolor red \ 1097 -activebackground black \ 1098 -activeforeground white \ 1099 -font "Arial 8" \ 1100 -command [itcl::code $this Combo invoke] 1101 set _fields($name) [list $title $units] 1102 } 1103 foreach { name title units } [$_first hints scalars] { 1104 set _scalarFields($title) $name 1105 $itk_component(field) choices insert end "$name" "$title" 1106 $itk_component(fieldmenu) add radiobutton -label "$title" \ 1107 -value $title -variable [itcl::scope _currentField] \ 1108 -selectcolor red \ 1109 -activebackground black \ 1110 -activeforeground white \ 1111 -font "Arial 8" \ 1112 -command [itcl::code $this Combo invoke] 1113 set _fields($name) [list $title $units] 1114 } 1115 $itk_component(field) value $_currentField 1116 } 1117 1118 InitSettings streamlines-visible streamlines-palette volume-visible 1119 1120 if { $_reset } { 1121 InitSettings streamlines-seeds streamlines-opacity \ 1122 streamlines-numpoints streamlines-lighting \ 1123 streamlines-palette streamlines-field \ 1124 volume-edges volume-lighting volume-opacity volume-wireframe 1125 Zoom reset 1126 set _reset 0 1127 } 950 1128 set _buffering 0; # Turn off buffering. 951 1129 … … 953 1131 # care. We're finished here. 954 1132 blt::busy hold $itk_component(hull) 955 SendBytes$_outbuf;1133 sendto $_outbuf; 956 1134 blt::busy release $itk_component(hull) 957 1135 set _outbuf ""; # Clear the buffer. … … 1163 1341 1164 1342 # ---------------------------------------------------------------------- 1165 # USAGE: FixSettings <what> ?<value>?1343 # USAGE: InitSettings <what> ?<value>? 1166 1344 # 1167 1345 # Used internally to update rendering settings whenever parameters … … 1169 1347 # to the back end. 1170 1348 # ---------------------------------------------------------------------- 1171 itcl::body Rappture::VtkStreamlinesViewer::FixSettings { args } { 1172 foreach setting $args { 1173 AdjustSetting $setting 1349 itcl::body Rappture::VtkStreamlinesViewer::InitSettings { args } { 1350 foreach spec $args { 1351 if { [info exists _settings($_first-$spec)] } { 1352 # Reset global setting with dataobj specific setting 1353 set _settings($spec) $_settings($_first-$spec) 1354 } 1355 AdjustSetting $spec 1174 1356 } 1175 1357 } … … 1188 1370 switch -- $what { 1189 1371 "volume-opacity" { 1190 set val $_ volume(opacity)1372 set val $_settings(volume-opacity) 1191 1373 set sval [expr { 0.01 * double($val) }] 1192 foreach dataset [CurrentDatasets -visible $_first] {1374 foreach dataset [CurrentDatasets -visible] { 1193 1375 SendCmd "polydata opacity $sval $dataset" 1194 1376 } 1195 1377 } 1196 1378 "volume-wireframe" { 1197 set bool $_ volume(wireframe)1198 foreach dataset [CurrentDatasets -visible $_first] {1379 set bool $_settings(volume-wireframe) 1380 foreach dataset [CurrentDatasets -visible] { 1199 1381 SendCmd "polydata wireframe $bool $dataset" 1200 1382 } 1201 1383 } 1202 1384 "volume-visible" { 1203 set bool $_ volume(visible)1204 foreach dataset [CurrentDatasets -visible $_first] {1385 set bool $_settings(volume-visible) 1386 foreach dataset [CurrentDatasets -visible] { 1205 1387 SendCmd "polydata visible $bool $dataset" 1206 1388 } 1389 if { $bool } { 1390 Rappture::Tooltip::for $itk_component(volume) \ 1391 "Hide the volume" 1392 } else { 1393 Rappture::Tooltip::for $itk_component(volume) \ 1394 "Show the volume" 1395 } 1207 1396 } 1208 1397 "volume-lighting" { 1209 set bool $_ volume(lighting)1210 foreach dataset [CurrentDatasets -visible $_first] {1398 set bool $_settings(volume-lighting) 1399 foreach dataset [CurrentDatasets -visible] { 1211 1400 SendCmd "polydata lighting $bool $dataset" 1212 1401 } 1213 1402 } 1214 1403 "volume-edges" { 1215 set bool $_ volume(edges)1216 foreach dataset [CurrentDatasets -visible $_first] {1404 set bool $_settings(volume-edges) 1405 foreach dataset [CurrentDatasets -visible] { 1217 1406 SendCmd "polydata edges $bool $dataset" 1218 1407 } 1219 1408 } 1220 1409 "axis-visible" { 1221 set bool $_ axis(visible)1410 set bool $_settings(axis-visible) 1222 1411 SendCmd "axis visible all $bool" 1223 1412 } 1224 1413 "axis-labels" { 1225 set bool $_ axis(labels)1414 set bool $_settings(axis-labels) 1226 1415 SendCmd "axis labels all $bool" 1227 1416 } 1228 "axis-xgrid" { 1229 set bool $_axis(xgrid) 1230 SendCmd "axis grid x $bool" 1231 } 1232 "axis-ygrid" { 1233 set bool $_axis(ygrid) 1234 SendCmd "axis grid y $bool" 1235 } 1236 "axis-zgrid" { 1237 set bool $_axis(zgrid) 1238 SendCmd "axis grid z $bool" 1417 "axis-xgrid" - "axis-ygrid" - "axis-zgrid" { 1418 set axis [string range $what 5 5] 1419 set bool $_settings($what) 1420 SendCmd "axis grid $axis $bool" 1239 1421 } 1240 1422 "axis-mode" { 1241 1423 set mode [$itk_component(axismode) value] 1242 1424 set mode [$itk_component(axismode) translate $mode] 1425 set _settings($what) $mode 1243 1426 SendCmd "axis flymode $mode" 1244 1427 } 1245 "axis-xcutaway" - "axis-ycutaway" - "axis-zcutaway" { 1246 set axis [string range $what 5 5] 1247 set bool $_axis(${axis}cutaway) 1428 "cutplane-edges" { 1429 set bool $_settings($what) 1430 foreach dataset [CurrentDatasets -visible] { 1431 SendCmd "cutplane edges $bool $dataset" 1432 } 1433 } 1434 "cutplane-visible" { 1435 set bool $_settings($what) 1436 foreach dataset [CurrentDatasets -visible] { 1437 SendCmd "cutplane visible $bool $dataset" 1438 } 1439 } 1440 "cutplane-wireframe" { 1441 set bool $_settings($what) 1442 foreach dataset [CurrentDatasets -visible] { 1443 SendCmd "cutplane wireframe $bool $dataset" 1444 } 1445 } 1446 "cutplane-lighting" { 1447 set bool $_settings($what) 1448 foreach dataset [CurrentDatasets -visible] { 1449 SendCmd "cutplane lighting $bool $dataset" 1450 } 1451 } 1452 "cutplane-opacity" { 1453 set val $_settings($what) 1454 set sval [expr { 0.01 * double($val) }] 1455 foreach dataset [CurrentDatasets -visible] { 1456 SendCmd "cutplane opacity $sval $dataset" 1457 } 1458 } 1459 "cutplane-xvisible" - "cutplane-yvisible" - "cutplane-zvisible" { 1460 set axis [string range $what 9 9] 1461 set bool $_settings($what) 1248 1462 if { $bool } { 1249 set pos [expr $_axis(${axis}position) * 0.01]1250 set dir $_axis(${axis}direction)1251 1463 $itk_component(${axis}CutScale) configure -state normal \ 1252 1464 -troughcolor white 1253 SendCmd "renderer clipplane $axis $pos $dir"1254 1465 } else { 1255 1466 $itk_component(${axis}CutScale) configure -state disabled \ 1256 1467 -troughcolor grey82 1257 SendCmd "renderer clipplane $axis 1 -1"1258 1468 } 1259 }1260 "axis-xposition" - "axis-yposition" - "axis-zposition" -1261 " axis-xdirection" - "axis-ydirection" - "axis-zdirection" {1262 set axis [string range $what 5 5]1263 #set dir $_axis(${axis}direction)1264 set pos [expr $_axis(${axis}position) * 0.01]1265 SendCmd "renderer clipplane ${axis} $pos -1"1469 SendCmd "cutplane axis $axis $bool" 1470 } 1471 "cutplane-xposition" - "cutplane-yposition" - "cutplane-zposition" { 1472 set axis [string range $what 9 9] 1473 set pos [expr $_settings($what) * 0.01] 1474 SendCmd "cutplane slice ${axis} ${pos}" 1475 set _cutplanePending 0 1266 1476 } 1267 1477 "streamlines-seeds" { 1268 set bool $_s treamlines(seeds)1269 foreach dataset [CurrentDatasets -visible $_first] {1478 set bool $_settings($what) 1479 foreach dataset [CurrentDatasets -visible] { 1270 1480 SendCmd "streamlines seed visible $bool $dataset" 1271 1481 } 1272 1482 } 1483 "streamlines-numpoints" { 1484 set density $_settings($what) 1485 EventuallyReseed $density 1486 } 1273 1487 "streamlines-visible" { 1274 set bool $_s treamlines(visible)1275 foreach dataset [CurrentDatasets -visible $_first] {1488 set bool $_settings($what) 1489 foreach dataset [CurrentDatasets -visible] { 1276 1490 SendCmd "streamlines visible $bool $dataset" 1277 1491 } 1492 if { $bool } { 1493 Rappture::Tooltip::for $itk_component(streamlines) \ 1494 "Hide the streamlines" 1495 } else { 1496 Rappture::Tooltip::for $itk_component(streamlines) \ 1497 "Show the streamlines" 1498 } 1278 1499 } 1279 1500 "streamlines-mode" { 1280 1501 set mode [$itk_component(streammode) value] 1281 foreach dataset [CurrentDatasets -visible $_first] { 1502 set _settings(streamlines-mode) $mode 1503 foreach dataset [CurrentDatasets -visible] { 1282 1504 switch -- $mode { 1283 1505 "lines" { … … 1285 1507 } 1286 1508 "ribbons" { 1287 SendCmd "streamlines ribbons 10 $dataset"1509 SendCmd "streamlines ribbons 3 0 $dataset" 1288 1510 } 1289 1511 "tubes" { 1290 SendCmd "streamlines tubes 5 1$dataset"1512 SendCmd "streamlines tubes 5 3 $dataset" 1291 1513 } 1292 1514 } 1293 1515 } 1294 1516 } 1517 "streamlines-palette" { 1518 set palette [$itk_component(palette) value] 1519 set _settings(streamlines-palette) $palette 1520 foreach dataset [CurrentDatasets -visible $_first] { 1521 foreach {dataobj comp} [split $dataset -] break 1522 ChangeColormap $dataobj $comp $palette 1523 } 1524 set _legendPending 1 1525 } 1295 1526 "streamlines-opacity" { 1296 set val $_s treamlines(opacity)1527 set val $_settings(streamlines-opacity) 1297 1528 set sval [expr { 0.01 * double($val) }] 1298 1529 foreach dataset [CurrentDatasets -visible $_first] { … … 1300 1531 } 1301 1532 } 1533 "streamlines-scale" { 1534 set val $_settings(streamlines-scale) 1535 set sval [expr { 0.01 * double($val) }] 1536 foreach dataset [CurrentDatasets -visible $_first] { 1537 SendCmd "streamlines scale $sval $sval $sval $dataset" 1538 } 1539 } 1540 "streamlines-lighting" { 1541 set bool $_settings(streamlines-lighting) 1542 foreach dataset [CurrentDatasets -visible $_first] { 1543 SendCmd "streamlines lighting $bool $dataset" 1544 } 1545 } 1546 "streamlines-field" { 1547 set new [$itk_component(field) value] 1548 set value [$itk_component(field) translate $new] 1549 set _settings(streamlines-field) $value 1550 if { [info exists _scalarFields($new)] } { 1551 set name $_scalarFields($new) 1552 set _colorMode scalar 1553 set _currentField $new 1554 } elseif { [info exists _vectorFields($new)] } { 1555 set name $_vectorFields($new) 1556 set _colorMode vmag 1557 set _currentField $new 1558 } else { 1559 puts stderr "unknown field \"$new\"" 1560 return 1561 } 1562 foreach dataset [CurrentDatasets -visible] { 1563 puts stderr "streamlines colormode $_colorMode ${name} $dataset" 1564 puts stderr "cutplane colormode $_colorMode ${name} $dataset" 1565 SendCmd "streamlines colormode $_colorMode ${name} $dataset" 1566 SendCmd "cutplane colormode $_colorMode ${name} $dataset" 1567 } 1568 set _legendPending 1 1569 } 1302 1570 default { 1303 1571 error "don't know how to fix $what" … … 1314 1582 # 1315 1583 itcl::body Rappture::VtkStreamlinesViewer::RequestLegend {} { 1316 #puts stderr "RequestLegend _first=$_first"1317 #puts stderr "RequestLegend width=$_width height=$_height"1318 1584 set font "Arial 8" 1319 1585 set lineht [font metrics $font -linespace] 1320 1586 set c $itk_component(legend) 1321 1587 set w 12 1322 set h [expr {$_height - 2* ($lineht + 2)}]1588 set h [expr {$_height - 3 * ($lineht + 2)}] 1323 1589 if { $h < 1} { 1324 1590 return 1325 1591 } 1592 if { [info exists _scalarFields($_currentField)] } { 1593 set name $_scalarFields($_currentField) 1594 } elseif { [info exists _vectorFields($_currentField)] } { 1595 set name $_vectorFields($_currentField) 1596 } else { 1597 return 1598 } 1326 1599 # Set the legend on the first streamlines dataset. 1327 foreach dataset [CurrentDatasets -visible ] {1600 foreach dataset [CurrentDatasets -visible $_first] { 1328 1601 foreach {dataobj comp} [split $dataset -] break 1329 1602 if { [info exists _dataset2style($dataset)] } { 1330 #puts stderr "RequestLegend w=$w h=$h" 1331 SendCmd "legend $_dataset2style($dataset) vmag{} $w $h 0"1603 SendCmdNoWait \ 1604 "legend $_dataset2style($dataset) $_colorMode $name {} $w $h 0" 1332 1605 break; 1333 1606 } 1334 1607 } 1608 } 1609 1610 # 1611 # ChangeColormap -- 1612 # 1613 itcl::body Rappture::VtkStreamlinesViewer::ChangeColormap {dataobj comp color} { 1614 set tag $dataobj-$comp 1615 if { ![info exist _style($tag)] } { 1616 error "no initial colormap" 1617 } 1618 array set style $_style($tag) 1619 set style(-color) $color 1620 set _style($tag) [array get style] 1621 SetColormap $dataobj $comp 1335 1622 } 1336 1623 … … 1340 1627 itcl::body Rappture::VtkStreamlinesViewer::SetColormap { dataobj comp } { 1341 1628 array set style { 1342 -color rainbow1629 -color BGYOR 1343 1630 -levels 6 1344 1631 -opacity 1.0 1345 1632 } 1346 1633 set tag $dataobj-$comp 1347 array set style [$dataobj style $comp] 1348 set colormap "$style(-color):$style(-levels):$style(-opacity)" 1349 if { [info exists _colormaps($colormap)] } { 1350 puts stderr "Colormap $colormap already built" 1351 return $colormap 1352 } 1353 if { ![info exists _dataset2style($tag)] } { 1354 set _dataset2style($tag) $colormap 1355 lappend _style2datasets($colormap) $tag 1356 } 1357 if { ![info exists _colormaps($colormap)] } { 1358 # Build the pseudo colormap if it doesn't exist. 1359 BuildColormap $colormap $dataobj $comp 1360 set _colormaps($colormap) 1 1361 } 1362 SendCmd "streamlines colormap $colormap $tag" 1363 return $colormap 1364 } 1365 1366 # 1367 # BuildColormap -- 1368 # 1369 itcl::body Rappture::VtkStreamlinesViewer::BuildColormap { colormap dataobj comp } { 1370 array set style { 1371 -color rainbow 1372 -levels 6 1373 -opacity 1.0 1374 } 1375 array set style [$dataobj style $comp] 1376 if {$style(-color) == "rainbow"} { 1377 set style(-color) "white:yellow:green:cyan:blue:magenta" 1378 } 1379 set clist [split $style(-color) :] 1634 if { ![info exists _initialStyle($tag)] } { 1635 # Save the initial component style. 1636 set _initialStyle($tag) [$dataobj style $comp] 1637 } 1638 1639 # Override defaults with initial style defined in xml. 1640 array set style $_initialStyle($tag) 1641 1642 if { ![info exists _style($tag)] } { 1643 set _style($tag) [array get style] 1644 } 1645 # Override initial style with current style. 1646 array set style $_style($tag) 1647 1648 set name "$style(-color):$style(-levels):$style(-opacity)" 1649 if { ![info exists _colormaps($name)] } { 1650 BuildColormap $name [array get style] 1651 set _colormaps($name) 1 1652 } 1653 if { ![info exists _dataset2style($tag)] || 1654 $_dataset2style($tag) != $name } { 1655 SendCmd "streamlines colormap $name $tag" 1656 SendCmd "cutplane colormap $name $tag" 1657 set _dataset2style($tag) $name 1658 } 1659 } 1660 1661 itcl::body Rappture::VtkStreamlinesViewer::ColorsToColormap { colors } { 1662 switch -- $colors { 1663 "grey-to-blue" { 1664 return { 1665 0.0 0.200 0.200 0.200 1666 0.14285714285714285 0.400 0.400 0.400 1667 0.2857142857142857 0.600 0.600 0.600 1668 0.42857142857142855 0.900 0.900 0.900 1669 0.5714285714285714 0.800 1.000 1.000 1670 0.7142857142857143 0.600 1.000 1.000 1671 0.8571428571428571 0.400 0.900 1.000 1672 1.0 0.000 0.600 0.800 1673 } 1674 } 1675 "blue-to-grey" { 1676 return { 1677 0.0 0.000 0.600 0.800 1678 0.14285714285714285 0.400 0.900 1.000 1679 0.2857142857142857 0.600 1.000 1.000 1680 0.42857142857142855 0.800 1.000 1.000 1681 0.5714285714285714 0.900 0.900 0.900 1682 0.7142857142857143 0.600 0.600 0.600 1683 0.8571428571428571 0.400 0.400 0.400 1684 1.0 0.200 0.200 0.200 1685 } 1686 } 1687 "blue" { 1688 return { 1689 0.0 0.900 1.000 1.000 1690 0.1111111111111111 0.800 0.983 1.000 1691 0.2222222222222222 0.700 0.950 1.000 1692 0.3333333333333333 0.600 0.900 1.000 1693 0.4444444444444444 0.500 0.833 1.000 1694 0.5555555555555556 0.400 0.750 1.000 1695 0.6666666666666666 0.300 0.650 1.000 1696 0.7777777777777778 0.200 0.533 1.000 1697 0.8888888888888888 0.100 0.400 1.000 1698 1.0 0.000 0.250 1.000 1699 } 1700 } 1701 "brown-to-blue" { 1702 return { 1703 0.0 0.200 0.100 0.000 1704 0.09090909090909091 0.400 0.187 0.000 1705 0.18181818181818182 0.600 0.379 0.210 1706 0.2727272727272727 0.800 0.608 0.480 1707 0.36363636363636365 0.850 0.688 0.595 1708 0.45454545454545453 0.950 0.855 0.808 1709 0.5454545454545454 0.800 0.993 1.000 1710 0.6363636363636364 0.600 0.973 1.000 1711 0.7272727272727273 0.400 0.940 1.000 1712 0.8181818181818182 0.200 0.893 1.000 1713 0.9090909090909091 0.000 0.667 0.800 1714 1.0 0.000 0.480 0.600 1715 } 1716 } 1717 "blue-to-brown" { 1718 return { 1719 0.0 0.000 0.480 0.600 1720 0.09090909090909091 0.000 0.667 0.800 1721 0.18181818181818182 0.200 0.893 1.000 1722 0.2727272727272727 0.400 0.940 1.000 1723 0.36363636363636365 0.600 0.973 1.000 1724 0.45454545454545453 0.800 0.993 1.000 1725 0.5454545454545454 0.950 0.855 0.808 1726 0.6363636363636364 0.850 0.688 0.595 1727 0.7272727272727273 0.800 0.608 0.480 1728 0.8181818181818182 0.600 0.379 0.210 1729 0.9090909090909091 0.400 0.187 0.000 1730 1.0 0.200 0.100 0.000 1731 } 1732 } 1733 "blue-to-orange" { 1734 return { 1735 0.0 0.000 0.167 1.000 1736 0.09090909090909091 0.100 0.400 1.000 1737 0.18181818181818182 0.200 0.600 1.000 1738 0.2727272727272727 0.400 0.800 1.000 1739 0.36363636363636365 0.600 0.933 1.000 1740 0.45454545454545453 0.800 1.000 1.000 1741 0.5454545454545454 1.000 1.000 0.800 1742 0.6363636363636364 1.000 0.933 0.600 1743 0.7272727272727273 1.000 0.800 0.400 1744 0.8181818181818182 1.000 0.600 0.200 1745 0.9090909090909091 1.000 0.400 0.100 1746 1.0 1.000 0.167 0.000 1747 } 1748 } 1749 "orange-to-blue" { 1750 return { 1751 0.0 1.000 0.167 0.000 1752 0.09090909090909091 1.000 0.400 0.100 1753 0.18181818181818182 1.000 0.600 0.200 1754 0.2727272727272727 1.000 0.800 0.400 1755 0.36363636363636365 1.000 0.933 0.600 1756 0.45454545454545453 1.000 1.000 0.800 1757 0.5454545454545454 0.800 1.000 1.000 1758 0.6363636363636364 0.600 0.933 1.000 1759 0.7272727272727273 0.400 0.800 1.000 1760 0.8181818181818182 0.200 0.600 1.000 1761 0.9090909090909091 0.100 0.400 1.000 1762 1.0 0.000 0.167 1.000 1763 } 1764 } 1765 "rainbow" { 1766 set clist { 1767 "#EE82EE" 1768 "#4B0082" 1769 "blue" 1770 "#008000" 1771 "yellow" 1772 "#FFA500" 1773 "red" 1774 } 1775 } 1776 "BGYOR" { 1777 set clist { 1778 "blue" 1779 "#008000" 1780 "yellow" 1781 "#FFA500" 1782 "red" 1783 } 1784 } 1785 "ROYGB" { 1786 set clist { 1787 "red" 1788 "#FFA500" 1789 "yellow" 1790 "#008000" 1791 "blue" 1792 } 1793 } 1794 "RYGCB" { 1795 set clist { 1796 "red" 1797 "yellow" 1798 "green" 1799 "cyan" 1800 "blue" 1801 } 1802 } 1803 "BCGYR" { 1804 set clist { 1805 "blue" 1806 "cyan" 1807 "green" 1808 "yellow" 1809 "red" 1810 } 1811 } 1812 "spectral" { 1813 return { 1814 0.0 0.150 0.300 1.000 1815 0.1 0.250 0.630 1.000 1816 0.2 0.450 0.850 1.000 1817 0.3 0.670 0.970 1.000 1818 0.4 0.880 1.000 1.000 1819 0.5 1.000 1.000 0.750 1820 0.6 1.000 0.880 0.600 1821 0.7 1.000 0.680 0.450 1822 0.8 0.970 0.430 0.370 1823 0.9 0.850 0.150 0.196 1824 1.0 0.650 0.000 0.130 1825 } 1826 } 1827 "green-to-magenta" { 1828 return { 1829 0.0 0.000 0.316 0.000 1830 0.06666666666666667 0.000 0.526 0.000 1831 0.13333333333333333 0.000 0.737 0.000 1832 0.2 0.000 0.947 0.000 1833 0.26666666666666666 0.316 1.000 0.316 1834 0.3333333333333333 0.526 1.000 0.526 1835 0.4 0.737 1.000 0.737 1836 0.4666666666666667 1.000 1.000 1.000 1837 0.5333333333333333 1.000 0.947 1.000 1838 0.6 1.000 0.737 1.000 1839 0.6666666666666666 1.000 0.526 1.000 1840 0.7333333333333333 1.000 0.316 1.000 1841 0.8 0.947 0.000 0.947 1842 0.8666666666666667 0.737 0.000 0.737 1843 0.9333333333333333 0.526 0.000 0.526 1844 1.0 0.316 0.000 0.316 1845 } 1846 } 1847 "greyscale" { 1848 return { 1849 0.0 0.0 0.0 0.0 1.0 1.0 1.0 1.0 1850 } 1851 } 1852 "nanohub" { 1853 set clist "white yellow green cyan blue magenta" 1854 } 1855 default { 1856 set clist $colors 1857 } 1858 } 1380 1859 set cmap {} 1381 1860 for {set i 0} {$i < [llength $clist]} {incr i} { … … 1384 1863 append cmap "$x [Color2RGB $color] " 1385 1864 } 1865 return $cmap 1866 } 1867 1868 # 1869 # BuildColormap -- 1870 # 1871 itcl::body Rappture::VtkStreamlinesViewer::BuildColormap { name styles } { 1872 array set style $styles 1873 set cmap [ColorsToColormap $style(-color)] 1386 1874 if { [llength $cmap] == 0 } { 1387 1875 set cmap "0.0 0.0 0.0 0.0 1.0 1.0 1.0 1.0" 1388 1876 } 1389 if { ![info exists _ volume(opacity)] } {1390 set _ volume(opacity) $style(-opacity)1391 } 1392 set max $_ volume(opacity)1877 if { ![info exists _settings(volume-opacity)] } { 1878 set _settings(volume-opacity) $style(-opacity) 1879 } 1880 set max $_settings(volume-opacity) 1393 1881 1394 1882 set wmap "0.0 1.0 1.0 1.0" 1395 SendCmd "colormap add $ colormap{ $cmap } { $wmap }"1883 SendCmd "colormap add $name { $cmap } { $wmap }" 1396 1884 } 1397 1885 … … 1418 1906 1419 1907 itcl::body Rappture::VtkStreamlinesViewer::limits { dataobj } { 1420 1908 return 1421 1909 array unset _limits $dataobj-* 1422 1910 foreach comp [$dataobj components] { … … 1426 1914 set tmpfile file[pid].vtk 1427 1915 set f [open "$tmpfile" "w"] 1916 fconfigure $f -translation binary -encoding binary 1428 1917 puts $f $data 1429 1918 close $f 1430 1919 set reader [vtkDataSetReader $tag-xvtkDataSetReader] 1431 1920 $reader SetFileName $tmpfile 1432 $reader ReadAllNormalsOn1433 1921 $reader ReadAllScalarsOn 1434 1922 $reader ReadAllVectorsOn … … 1439 1927 set pointData [$output GetPointData] 1440 1928 puts stderr "\#scalars=[$reader GetNumberOfScalarsInFile]" 1441 puts stderr "\#vectors=[$reader GetNumberOfVectorsInFile]"1442 puts stderr "\#tensors=[$reader GetNumberOfTensorsInFile]"1443 puts stderr "\#normals=[$reader GetNumberOfNormalsInFile]"1444 1929 puts stderr "\#fielddata=[$reader GetNumberOfFieldDataInFile]" 1445 1930 puts stderr "fielddataname=[$reader GetFieldDataNameInFile 0]" … … 1447 1932 set pointData [$output GetPointData] 1448 1933 puts stderr "field \#arrays=[$fieldData GetNumberOfArrays]" 1934 for { set i 0 } { $i < [$fieldData GetNumberOfArrays] } { incr i } { 1935 puts stderr [$fieldData GetArrayName $i] 1936 } 1449 1937 puts stderr "point \#arrays=[$pointData GetNumberOfArrays]" 1938 for { set i 0 } { $i < [$pointData GetNumberOfArrays] } { incr i } { 1939 set name [$pointData GetArrayName $i] 1940 if { ![info exists _fields($name)] } { 1941 $itk_component(field) choices insert end "$name" "$name" 1942 set _fields($name) 1 1943 } 1944 } 1450 1945 puts stderr "field \#components=[$fieldData GetNumberOfComponents]" 1451 1946 puts stderr "point \#components=[$pointData GetNumberOfComponents]" … … 1493 1988 checkbutton $inner.volume \ 1494 1989 -text "Show Volume" \ 1495 -variable [itcl::scope _ volume(visible)] \1990 -variable [itcl::scope _settings(volume-visible)] \ 1496 1991 -command [itcl::code $this AdjustSetting volume-visible] \ 1497 1992 -font "Arial 9" … … 1499 1994 checkbutton $inner.wireframe \ 1500 1995 -text "Show Wireframe" \ 1501 -variable [itcl::scope _ volume(wireframe)] \1996 -variable [itcl::scope _settings(volume-wireframe)] \ 1502 1997 -command [itcl::code $this AdjustSetting volume-wireframe] \ 1503 1998 -font "Arial 9" … … 1505 2000 checkbutton $inner.lighting \ 1506 2001 -text "Enable Lighting" \ 1507 -variable [itcl::scope _ volume(lighting)] \2002 -variable [itcl::scope _settings(volume-lighting)] \ 1508 2003 -command [itcl::code $this AdjustSetting volume-lighting] \ 1509 2004 -font "Arial 9" … … 1511 2006 checkbutton $inner.edges \ 1512 2007 -text "Show Edges" \ 1513 -variable [itcl::scope _ volume(edges)] \2008 -variable [itcl::scope _settings(volume-edges)] \ 1514 2009 -command [itcl::code $this AdjustSetting volume-edges] \ 1515 2010 -font "Arial 9" … … 1517 2012 label $inner.opacity_l -text "Opacity" -font "Arial 9" 1518 2013 ::scale $inner.opacity -from 0 -to 100 -orient horizontal \ 1519 -variable [itcl::scope _ volume(opacity)] \2014 -variable [itcl::scope _settings(volume-opacity)] \ 1520 2015 -width 10 \ 1521 2016 -showvalue off \ … … 1542 2037 set inner [$itk_component(main) insert end \ 1543 2038 -title "Streams Settings" \ 1544 -icon [Rappture::icon stream ]]2039 -icon [Rappture::icon streamlines-on]] 1545 2040 $inner configure -borderwidth 4 1546 2041 1547 2042 checkbutton $inner.streamlines \ 1548 2043 -text "Show Streamlines" \ 1549 -variable [itcl::scope _s treamlines(visible)] \2044 -variable [itcl::scope _settings(streamlines-visible)] \ 1550 2045 -command [itcl::code $this AdjustSetting streamlines-visible] \ 1551 2046 -font "Arial 9" 2047 2048 checkbutton $inner.lighting \ 2049 -text "Enable Lighting" \ 2050 -variable [itcl::scope _settings(streamlines-lighting)] \ 2051 -command [itcl::code $this AdjustSetting streamlines-lighting] \ 2052 -font "Arial 9" 1552 2053 1553 2054 checkbutton $inner.seeds \ 1554 2055 -text "Show Seeds" \ 1555 -variable [itcl::scope _s treamlines(seeds)] \2056 -variable [itcl::scope _settings(streamlines-seeds)] \ 1556 2057 -command [itcl::code $this AdjustSetting streamlines-seeds] \ 1557 2058 -font "Arial 9" … … 1570 2071 label $inner.opacity_l -text "Opacity" -font "Arial 9" 1571 2072 ::scale $inner.opacity -from 0 -to 100 -orient horizontal \ 1572 -variable [itcl::scope _s treamlines(opacity)] \2073 -variable [itcl::scope _settings(streamlines-opacity)] \ 1573 2074 -width 10 \ 1574 2075 -showvalue off \ 1575 2076 -command [itcl::code $this AdjustSetting streamlines-opacity] 1576 2077 2078 label $inner.density_l -text "Number of Seeds" -font "Arial 9" 2079 ::scale $inner.density -from 1 -to 1000 -orient horizontal \ 2080 -variable [itcl::scope _settings(streamlines-numpoints)] \ 2081 -width 10 \ 2082 -showvalue on \ 2083 -command [itcl::code $this AdjustSetting streamlines-numpoints] 2084 2085 label $inner.scale_l -text "Scale" -font "Arial 9" 2086 ::scale $inner.scale -from 1 -to 100 -orient horizontal \ 2087 -variable [itcl::scope _settings(streamlines-scale)] \ 2088 -width 10 \ 2089 -showvalue off \ 2090 -command [itcl::code $this AdjustSetting streamlines-scale] 2091 2092 label $inner.field_l -text "Field" -font "Arial 9" 2093 itk_component add field { 2094 Rappture::Combobox $inner.field -width 10 -editable no 2095 } 2096 bind $inner.field <<Value>> \ 2097 [itcl::code $this AdjustSetting streamlines-field] 2098 2099 label $inner.palette_l -text "Palette" -font "Arial 9" 2100 itk_component add palette { 2101 Rappture::Combobox $inner.palette -width 10 -editable no 2102 } 2103 $inner.palette choices insert end \ 2104 "BCGYR" "BCGYR" \ 2105 "BGYOR" "BGYOR" \ 2106 "blue" "blue" \ 2107 "blue-to-brown" "blue-to-brown" \ 2108 "blue-to-orange" "blue-to-orange" \ 2109 "blue-to-grey" "blue-to-grey" \ 2110 "green-to-magenta" "green-to-magenta" \ 2111 "greyscale" "greyscale" \ 2112 "nanohub" "nanohub" \ 2113 "rainbow" "rainbow" \ 2114 "spectral" "spectral" \ 2115 "ROYGB" "ROYGB" \ 2116 "RYGCB" "RYGCB" \ 2117 "brown-to-blue" "brown-to-blue" \ 2118 "grey-to-blue" "grey-to-blue" \ 2119 "orange-to-blue" "orange-to-blue" 2120 2121 $itk_component(palette) value "BCGYR" 2122 bind $inner.palette <<Value>> \ 2123 [itcl::code $this AdjustSetting streamlines-palette] 2124 1577 2125 blt::table $inner \ 1578 2126 0,0 $inner.streamlines -anchor w -pady 2 -cspan 2 \ 1579 1,0 $inner.seeds -anchor w -pady 2 -cspan 2 \ 1580 2,0 $inner.mode_l -anchor w -pady 2 \ 1581 2,1 $inner.mode -anchor w -pady 2 \ 1582 3,0 $inner.opacity_l -anchor w -pady 2 \ 1583 4,0 $inner.opacity -fill x -pady 2 -cspan 2 2127 1,0 $inner.lighting -anchor w -pady 2 -cspan 2 \ 2128 2,0 $inner.seeds -anchor w -pady 2 -cspan 2 \ 2129 3,0 $inner.density_l -anchor w -pady 2 -cspan 2 \ 2130 4,0 $inner.density -fill x -pady 2 -cspan 2 \ 2131 5,0 $inner.mode_l -anchor w -pady 2 \ 2132 5,1 $inner.mode -anchor w -pady 2 \ 2133 6,0 $inner.opacity_l -anchor w -pady 2 -cspan 2 \ 2134 7,0 $inner.opacity -fill x -pady 2 -cspan 2 \ 2135 8,0 $inner.field_l -anchor w -pady 2 \ 2136 8,1 $inner.field -anchor w -pady 2 \ 2137 9,0 $inner.palette_l -anchor w -pady 2 \ 2138 9,1 $inner.palette -anchor w -pady 2 \ 2139 1584 2140 1585 2141 blt::table configure $inner r* c* -resize none 1586 blt::table configure $inner r 5c1 c2 -resize expand2142 blt::table configure $inner r10 c1 c2 -resize expand 1587 2143 } 1588 2144 … … 1599 2155 checkbutton $inner.visible \ 1600 2156 -text "Show Axes" \ 1601 -variable [itcl::scope _ axis(visible)] \2157 -variable [itcl::scope _settings(axis-visible)] \ 1602 2158 -command [itcl::code $this AdjustSetting axis-visible] \ 1603 2159 -font "Arial 9" … … 1605 2161 checkbutton $inner.labels \ 1606 2162 -text "Show Axis Labels" \ 1607 -variable [itcl::scope _ axis(labels)] \2163 -variable [itcl::scope _settings(axis-labels)] \ 1608 2164 -command [itcl::code $this AdjustSetting axis-labels] \ 1609 2165 -font "Arial 9" … … 1611 2167 checkbutton $inner.gridx \ 1612 2168 -text "Show X Grid" \ 1613 -variable [itcl::scope _ axis(xgrid)] \2169 -variable [itcl::scope _settings(axis-xgrid)] \ 1614 2170 -command [itcl::code $this AdjustSetting axis-xgrid] \