Imported Upstream version 3.3.26
أحمد المحمودي (Ahmed El-Mahmoudy)
12 years ago
1037 | 1037 | Added custom filters to GtkFileChooser dialogue. |
1038 | 1038 | Fix in lxt2_read.c/.h for negative msb/lsb indices. |
1039 | 1039 | Fix in vzt_read.c/.h for negative msb/lsb indices. |
1040 | 3.3.26 25sep11 Mac OSX fixes: removed restrictions for twinwave on OSX, | |
1041 | OSX compile fixes for Tcl detection, printf warning | |
1042 | fixes (xcode gcc uses stricter warnings). | |
1043 | More generic warning fixes from recent feature adds. |
100 | 100 | -140409ajb bybell@nc.rr.com |
101 | 101 | |
102 | 102 | =============================================================================== |
103 | ||
104 | Note for Mac OSX users: | |
105 | ||
106 | ./configure --prefix=/opt/local --enable-judy --enable-struct-pack CFLAGS=-I/opt/local/include -O2 -g LDFLAGS=-L/opt/local/lib --no-create --no-recursion | |
107 | ||
108 | Install the Judy and lzma/xz packages in MacPorts. | |
109 | Tcl works on OSX as of 3.3.26. At this point all features working on Linux | |
110 | should be functional on the Mac. | |
111 | ||
112 | -260911ajb bybell@nc.rr.com | |
113 | ||
114 | =============================================================================== |
0 | 0 | ########################################################################## |
1 | 1 | |
2 | GTKWave 3.3.25 Wave Viewer is Copyright (C) 1999-2011 Tony Bybell. | |
2 | GTKWave 3.3.26 Wave Viewer is Copyright (C) 1999-2011 Tony Bybell. | |
3 | 3 | Portions of GTKWave are Copyright (C) 1999-2011 Udi Finkelstein. |
4 | 4 | Context support is Copyright (C) 2007-2011 Kermin Elliott Fleming. |
5 | 5 | Trace group support is Copyright (C) 2009-2011 Donald Baltus. |
0 | 0 | #! /bin/sh |
1 | 1 | # Guess values for system-dependent variables and create Makefiles. |
2 | # Generated by GNU Autoconf 2.59 for gtkwave 3.3.25. | |
2 | # Generated by GNU Autoconf 2.59 for gtkwave 3.3.26. | |
3 | 3 | # |
4 | 4 | # Report bugs to <bybell@nc.rr.com>. |
5 | 5 | # |
268 | 268 | # Identity of this package. |
269 | 269 | PACKAGE_NAME='gtkwave' |
270 | 270 | PACKAGE_TARNAME='gtkwave' |
271 | PACKAGE_VERSION='3.3.25' | |
272 | PACKAGE_STRING='gtkwave 3.3.25' | |
271 | PACKAGE_VERSION='3.3.26' | |
272 | PACKAGE_STRING='gtkwave 3.3.26' | |
273 | 273 | PACKAGE_BUGREPORT='bybell@nc.rr.com' |
274 | 274 | |
275 | 275 | ac_unique_file="src/vcd.c" |
791 | 791 | # Omit some internal or obsolete options to make the list less imposing. |
792 | 792 | # This message is too long to be a string in the A/UX 3.1 sh. |
793 | 793 | cat <<_ACEOF |
794 | \`configure' configures gtkwave 3.3.25 to adapt to many kinds of systems. | |
794 | \`configure' configures gtkwave 3.3.26 to adapt to many kinds of systems. | |
795 | 795 | |
796 | 796 | Usage: $0 [OPTION]... [VAR=VALUE]... |
797 | 797 | |
853 | 853 | |
854 | 854 | if test -n "$ac_init_help"; then |
855 | 855 | case $ac_init_help in |
856 | short | recursive ) echo "Configuration of gtkwave 3.3.25:";; | |
856 | short | recursive ) echo "Configuration of gtkwave 3.3.26:";; | |
857 | 857 | esac |
858 | 858 | cat <<\_ACEOF |
859 | 859 | |
1007 | 1007 | test -n "$ac_init_help" && exit 0 |
1008 | 1008 | if $ac_init_version; then |
1009 | 1009 | cat <<\_ACEOF |
1010 | gtkwave configure 3.3.25 | |
1010 | gtkwave configure 3.3.26 | |
1011 | 1011 | generated by GNU Autoconf 2.59 |
1012 | 1012 | |
1013 | 1013 | Copyright (C) 2003 Free Software Foundation, Inc. |
1021 | 1021 | This file contains any messages produced by compilers while |
1022 | 1022 | running configure, to aid debugging if configure makes a mistake. |
1023 | 1023 | |
1024 | It was created by gtkwave $as_me 3.3.25, which was | |
1024 | It was created by gtkwave $as_me 3.3.26, which was | |
1025 | 1025 | generated by GNU Autoconf 2.59. Invocation command line was |
1026 | 1026 | |
1027 | 1027 | $ $0 $@ |
1665 | 1665 | |
1666 | 1666 | # Define the identity of the package. |
1667 | 1667 | PACKAGE='gtkwave' |
1668 | VERSION='3.3.25' | |
1668 | VERSION='3.3.26' | |
1669 | 1669 | |
1670 | 1670 | |
1671 | 1671 | cat >>confdefs.h <<_ACEOF |
12272 | 12272 | fi |
12273 | 12273 | fi |
12274 | 12274 | else |
12275 | if test "X$OSTYPE" = "Xdarwin" ; then | |
12276 | # skip Tcl_CreateInterp check on darwin (until we figure out)... | |
12277 | if test "X$STUBIFY" = "Xyes" ; then | |
12278 | TCL_DEFADD="-DHAVE_LIBTCL -DWAVE_TCL_STUBIFY -DUSE_TCL_STUBS -DUSE_TK_STUBS" | |
12279 | TCL_LDADD="${TCL_STUB_LIB_SPEC}" | |
12280 | TK_LDADD="${TK_STUB_LIB_SPEC}" | |
12281 | else | |
12282 | TCL_DEFADD="-DHAVE_LIBTCL" | |
12283 | TCL_LDADD="${TCL_LIB_SPEC}" | |
12284 | TK_LDADD="${TK_LIB_SPEC}" | |
12285 | fi | |
12286 | else | |
12275 | 12287 | if test "X$OSTYPE" = "Xmsys" ; then |
12276 | # skip Tcl_CreateInterp check on MingW (until we figure out)... | |
12288 | # skip Tcl_CreateInterp check on mingw (until we figure out)... | |
12277 | 12289 | if test "X$STUBIFY" = "Xyes" ; then |
12278 | 12290 | TCL_DEFADD="-DHAVE_LIBTCL -DWAVE_TCL_STUBIFY -DUSE_TCL_STUBS -DUSE_TK_STUBS" |
12279 | 12291 | TCL_LDADD="${TCL_STUB_LIB_SPEC}" |
12376 | 12388 | fi |
12377 | 12389 | fi |
12378 | 12390 | LDFLAGS="${OLD_LDFLAGS}" |
12391 | fi | |
12379 | 12392 | fi |
12380 | 12393 | fi |
12381 | 12394 | fi |
12861 | 12874 | } >&5 |
12862 | 12875 | cat >&5 <<_CSEOF |
12863 | 12876 | |
12864 | This file was extended by gtkwave $as_me 3.3.25, which was | |
12877 | This file was extended by gtkwave $as_me 3.3.26, which was | |
12865 | 12878 | generated by GNU Autoconf 2.59. Invocation command line was |
12866 | 12879 | |
12867 | 12880 | CONFIG_FILES = $CONFIG_FILES |
12924 | 12937 | |
12925 | 12938 | cat >>$CONFIG_STATUS <<_ACEOF |
12926 | 12939 | ac_cs_version="\\ |
12927 | gtkwave config.status 3.3.25 | |
12940 | gtkwave config.status 3.3.26 | |
12928 | 12941 | configured by $0, generated by GNU Autoconf 2.59, |
12929 | 12942 | with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\" |
12930 | 12943 |
1 | 1 | # Process this file with autoconf to produce a configure script. |
2 | 2 | |
3 | 3 | AC_PREREQ(2.59) |
4 | AC_INIT(gtkwave, 3.3.25, bybell@nc.rr.com) | |
4 | AC_INIT(gtkwave, 3.3.26, bybell@nc.rr.com) | |
5 | 5 | AC_CONFIG_SRCDIR([src/vcd.c]) |
6 | 6 | AM_INIT_AUTOMAKE |
7 | 7 | AC_CONFIG_HEADER([config.h]) |
593 | 593 | fi |
594 | 594 | fi |
595 | 595 | else |
596 | if test "X$OSTYPE" = "Xdarwin" ; then | |
597 | # skip Tcl_CreateInterp check on darwin (until we figure out)... | |
598 | if test "X$STUBIFY" = "Xyes" ; then | |
599 | TCL_DEFADD="-DHAVE_LIBTCL -DWAVE_TCL_STUBIFY -DUSE_TCL_STUBS -DUSE_TK_STUBS" | |
600 | TCL_LDADD="${TCL_STUB_LIB_SPEC}" | |
601 | TK_LDADD="${TK_STUB_LIB_SPEC}" | |
602 | else | |
603 | TCL_DEFADD="-DHAVE_LIBTCL" | |
604 | TCL_LDADD="${TCL_LIB_SPEC}" | |
605 | TK_LDADD="${TK_LIB_SPEC}" | |
606 | fi | |
607 | else | |
596 | 608 | if test "X$OSTYPE" = "Xmsys" ; then |
597 | # skip Tcl_CreateInterp check on MingW (until we figure out)... | |
609 | # skip Tcl_CreateInterp check on mingw (until we figure out)... | |
598 | 610 | if test "X$STUBIFY" = "Xyes" ; then |
599 | 611 | TCL_DEFADD="-DHAVE_LIBTCL -DWAVE_TCL_STUBIFY -DUSE_TCL_STUBS -DUSE_TK_STUBS" |
600 | 612 | TCL_LDADD="${TCL_STUB_LIB_SPEC}" |
625 | 637 | fi |
626 | 638 | fi |
627 | 639 | LDFLAGS="${OLD_LDFLAGS}" |
640 | fi | |
628 | 641 | fi |
629 | 642 | fi |
630 | 643 | fi |
37 | 37 | #include "generic.h" |
38 | 38 | #include "dlgdef.h" |
39 | 39 | |
40 | /* OSX warning fix */ | |
41 | #define GR_INT int | |
42 | ||
40 | 43 | /* char is only thing that is pretty much always known == 8 bits |
41 | 44 | * This allows output of antlr (set stuff, anyway) to be androgynous (portable) |
42 | 45 | */ |
575 | 578 | fprintf(ErrFile, "SetWordType %s%s[%d] = {", |
576 | 579 | name, |
577 | 580 | suffix, |
578 | NumWords(TokenNum-1)*sizeof(unsigned)); | |
581 | (GR_INT)(NumWords(TokenNum-1)*sizeof(unsigned))); | |
579 | 582 | } |
580 | 583 | else { |
581 | 584 | fprintf(ErrFile, "SetWordType zzerr%d[%d] = {", |
582 | 585 | esetnum, |
583 | NumWords(TokenNum-1)*sizeof(unsigned)); | |
586 | (GR_INT)(NumWords(TokenNum-1)*sizeof(unsigned))); | |
584 | 587 | } |
585 | 588 | while ( p < endp ) |
586 | 589 | { |
641 | 644 | |
642 | 645 | if ( name!=NULL ) { |
643 | 646 | fprintf(Parser_h, "\tstatic SetWordType %s%s[%d];\n", name, suffix, |
644 | NumWords(TokenNum-1)*sizeof(unsigned)); | |
647 | (GR_INT)(NumWords(TokenNum-1)*sizeof(unsigned))); | |
645 | 648 | fprintf(Parser_c, "SetWordType %s::%s%s[%d] = {", |
646 | 649 | CurrentClassName, |
647 | 650 | name, |
648 | 651 | suffix, |
649 | NumWords(TokenNum-1)*sizeof(unsigned)); | |
652 | (GR_INT)(NumWords(TokenNum-1)*sizeof(unsigned))); | |
650 | 653 | } |
651 | 654 | else { |
652 | 655 | fprintf(Parser_c, "SetWordType %s::err%d[%d] = {", |
653 | 656 | CurrentClassName, |
654 | 657 | esetnum, |
655 | NumWords(TokenNum-1)*sizeof(unsigned)); | |
658 | (GR_INT)(NumWords(TokenNum-1)*sizeof(unsigned))); | |
656 | 659 | fprintf(Parser_h, "\tstatic SetWordType err%d[%d];\n", esetnum, |
657 | NumWords(TokenNum-1)*sizeof(unsigned)); | |
660 | (GR_INT)(NumWords(TokenNum-1)*sizeof(unsigned))); | |
658 | 661 | } |
659 | 662 | |
660 | 663 | while ( p < endp ) |
792 | 795 | OutputLL_k, |
793 | 796 | FoundGuessBlk, |
794 | 797 | DemandLookahead, |
795 | NumWords(TokenNum-1)*sizeof(unsigned)); | |
798 | (GR_INT)(NumWords(TokenNum-1)*sizeof(unsigned))); | |
796 | 799 | fprintf(Parser_c, "{\n"); |
797 | 800 | fprintf(Parser_c, "\ttoken_tbl = _token_tbl;\n"); |
798 | 801 | if (TraceGen) { |
911 | 914 | #ifdef DUM |
912 | 915 | if ( LexGen ) fprintf(ErrFile, "#define zzEOF_TOKEN %d\n", (TokenInd!=NULL?TokenInd[EofToken]:EofToken)); |
913 | 916 | #endif |
914 | fprintf(ErrFile, "#define zzSET_SIZE %d\n", NumWords(TokenNum-1)*sizeof(unsigned)); | |
917 | fprintf(ErrFile, "#define zzSET_SIZE %d\n", (GR_INT)(NumWords(TokenNum-1)*sizeof(unsigned))); | |
915 | 918 | if ( DemandLookahead ) fprintf(ErrFile, "#define DEMAND_LOOK\n"); |
916 | 919 | fprintf(ErrFile, "#include \"antlr.h\"\n"); |
917 | 920 | if ( GenAST ) fprintf(ErrFile, "#include \"ast.h\"\n"); |
38 | 38 | #include "hash.h" |
39 | 39 | #include "generic.h" |
40 | 40 | #include "dlgdef.h" |
41 | ||
42 | /* OSX warning fix */ | |
43 | #define GR_INT int | |
41 | 44 | |
42 | 45 | #define NumExprPerLine 4 |
43 | 46 | static int on1line=0; |
3910 | 3913 | } |
3911 | 3914 | #endif |
3912 | 3915 | /* ###WARNING: This will have to change when SetWordSize changes */ |
3913 | if ( !GenCC ) _gen1("#define zzSET_SIZE %d\n", NumWords(TokenNum-1)*sizeof(unsigned)); | |
3916 | if ( !GenCC ) _gen1("#define zzSET_SIZE %d\n", (GR_INT)(NumWords(TokenNum-1)*sizeof(unsigned))); | |
3914 | 3917 | if (TraceGen) { |
3915 | 3918 | _gen("#ifndef zzTRACE_RULES\n"); /* MR20 */ |
3916 | 3919 | _gen("#define zzTRACE_RULES\n"); /* MR20 */ |
4124 | 4127 | if ( LexGen ) fprintf(f, "#define zzEOF_TOKEN %d\n", (TokenInd!=NULL?TokenInd[EofToken]:EofToken)); |
4125 | 4128 | #endif |
4126 | 4129 | /* ###WARNING: This will have to change when SetWordSize changes */ |
4127 | fprintf(f, "#define zzSET_SIZE %d\n", NumWords(TokenNum-1)*sizeof(unsigned)); | |
4130 | fprintf(f, "#define zzSET_SIZE %d\n", (GR_INT)(NumWords(TokenNum-1)*sizeof(unsigned))); | |
4128 | 4131 | if (TraceGen) { |
4129 | 4132 | fprintf(f,"#ifndef zzTRACE_RULES\n"); /* MR20 */ |
4130 | 4133 | fprintf(f,"#define zzTRACE_RULES\n"); /* MR20 */ |
41 | 41 | #endif |
42 | 42 | #include <string.h> |
43 | 43 | |
44 | /* OSX warning fix */ | |
45 | #define GR_INT int | |
44 | 46 | |
45 | 47 | #define StrSame 0 |
46 | 48 | #define fatal(err) \ |
140 | 142 | |
141 | 143 | if ( q != NULL && low==0 ) low = p-table; |
142 | 144 | len = 0; |
143 | if ( q != NULL ) fprintf(stderr, "[%d]", p-table); | |
145 | if ( q != NULL ) fprintf(stderr, "[%d]", (GR_INT)(p-table)); | |
144 | 146 | while ( q != NULL ) |
145 | 147 | { |
146 | 148 | len++; |
54 | 54 | /* make arg1 a set big enough to hold max elem # of arg2 */ |
55 | 55 | #define set_new(a,_max) \ |
56 | 56 | if (((a).setword=(unsigned *)calloc(NumWords(_max),BytesPerWord))==NULL) \ |
57 | fprintf(stderr, "set_new: Cannot allocate set with max of %d\n", _max); \ | |
57 | fprintf(stderr, "set_new: Cannot allocate set with max of %d\n", (int)(_max)); \ | |
58 | 58 | (a).n = NumWords(_max); |
59 | 59 | |
60 | 60 | #define set_free(a) \ |
51 | 51 | |
52 | 52 | |
53 | 53 | static |
54 | gboolean filter_edit_cb (GtkWidget *widget, GdkEventKey *ev, gpointer *data) | |
54 | void filter_edit_cb (GtkWidget *widget, GdkEventKey *ev, gpointer *data) | |
55 | 55 | { |
56 | 56 | const char *t; |
57 | 57 | gchar *folder_filename; |
644 | 644 | if (n->extvals) |
645 | 645 | printf (" ext: %d - %d\n", n->msi, n->lsi); |
646 | 646 | for (h = &n->head; h; h = h->next) |
647 | printf (" time:"GHWLLD" flags:%02x vect:%p\n", | |
647 | printf (" time:"TTFormat" flags:%02x vect:%p\n", | |
648 | 648 | h->time, h->flags, h->v.h_vector); |
649 | 649 | } |
650 | 650 | } |
1148 | 1148 | |
1149 | 1149 | GLOBALS->is_ghw = 1; |
1150 | 1150 | |
1151 | fprintf(stderr, "["GHWLLD"] start time.\n["GHWLLD"] end time.\n", GLOBALS->min_time*GLOBALS->time_scale, GLOBALS->max_time*GLOBALS->time_scale); | |
1151 | fprintf(stderr, "["TTFormat"] start time.\n["TTFormat"] end time.\n", GLOBALS->min_time*GLOBALS->time_scale, GLOBALS->max_time*GLOBALS->time_scale); | |
1152 | 1152 | if(GLOBALS->num_glitches_ghw_c_1) fprintf(stderr, "Warning: encountered %d glitch%s across %d glitch region%s.\n", |
1153 | 1153 | GLOBALS->num_glitches_ghw_c_1, (GLOBALS->num_glitches_ghw_c_1!=1)?"es":"", |
1154 | 1154 | GLOBALS->num_glitch_regions_ghw_c_1, (GLOBALS->num_glitch_regions_ghw_c_1!=1)?"s":""); |
31 | 31 | #ifdef HAVE_CONFIG_H |
32 | 32 | # include <config.h> |
33 | 33 | #endif |
34 | ||
35 | /* fix for 64-bit OSX compiles */ | |
36 | #define GR_INT int | |
34 | 37 | |
35 | 38 | #ifndef PARAMS |
36 | 39 | # if defined __GNUC__ || (defined __STDC__ && __STDC__) |
685 | 688 | /* Loop over pattern commands. */ |
686 | 689 | while (p < pend) |
687 | 690 | { |
688 | printf ("%d:\t", p - start); | |
691 | printf ("%d:\t", (GR_INT)(p - start)); | |
689 | 692 | |
690 | 693 | switch ((re_opcode_t) *p++) |
691 | 694 | { |
775 | 778 | |
776 | 779 | case on_failure_jump: |
777 | 780 | extract_number_and_incr (&mcnt, &p); |
778 | printf ("/on_failure_jump to %d", p + mcnt - start); | |
781 | printf ("/on_failure_jump to %d", (GR_INT)(p + mcnt - start)); | |
779 | 782 | break; |
780 | 783 | |
781 | 784 | case on_failure_keep_string_jump: |
782 | 785 | extract_number_and_incr (&mcnt, &p); |
783 | printf ("/on_failure_keep_string_jump to %d", p + mcnt - start); | |
786 | printf ("/on_failure_keep_string_jump to %d", (GR_INT)(p + mcnt - start)); | |
784 | 787 | break; |
785 | 788 | |
786 | 789 | case dummy_failure_jump: |
787 | 790 | extract_number_and_incr (&mcnt, &p); |
788 | printf ("/dummy_failure_jump to %d", p + mcnt - start); | |
791 | printf ("/dummy_failure_jump to %d", (GR_INT)(p + mcnt - start)); | |
789 | 792 | break; |
790 | 793 | |
791 | 794 | case push_dummy_failure: |
794 | 797 | |
795 | 798 | case maybe_pop_jump: |
796 | 799 | extract_number_and_incr (&mcnt, &p); |
797 | printf ("/maybe_pop_jump to %d", p + mcnt - start); | |
800 | printf ("/maybe_pop_jump to %d", (GR_INT)(p + mcnt - start)); | |
798 | 801 | break; |
799 | 802 | |
800 | 803 | case pop_failure_jump: |
801 | 804 | extract_number_and_incr (&mcnt, &p); |
802 | printf ("/pop_failure_jump to %d", p + mcnt - start); | |
805 | printf ("/pop_failure_jump to %d", (GR_INT)(p + mcnt - start)); | |
803 | 806 | break; |
804 | 807 | |
805 | 808 | case jump_past_alt: |
806 | 809 | extract_number_and_incr (&mcnt, &p); |
807 | printf ("/jump_past_alt to %d", p + mcnt - start); | |
810 | printf ("/jump_past_alt to %d", (GR_INT)(p + mcnt - start)); | |
808 | 811 | break; |
809 | 812 | |
810 | 813 | case jump: |
811 | 814 | extract_number_and_incr (&mcnt, &p); |
812 | printf ("/jump to %d", p + mcnt - start); | |
815 | printf ("/jump to %d", (GR_INT)(p + mcnt - start)); | |
813 | 816 | break; |
814 | 817 | |
815 | 818 | case succeed_n: |
816 | 819 | extract_number_and_incr (&mcnt, &p); |
817 | 820 | p1 = p + mcnt; |
818 | 821 | extract_number_and_incr (&mcnt2, &p); |
819 | printf ("/succeed_n to %d, %d times", p1 - start, mcnt2); | |
822 | printf ("/succeed_n to %d, %d times", (GR_INT)(p1 - start), mcnt2); | |
820 | 823 | break; |
821 | 824 | |
822 | 825 | case jump_n: |
823 | 826 | extract_number_and_incr (&mcnt, &p); |
824 | 827 | p1 = p + mcnt; |
825 | 828 | extract_number_and_incr (&mcnt2, &p); |
826 | printf ("/jump_n to %d, %d times", p1 - start, mcnt2); | |
829 | printf ("/jump_n to %d, %d times", (GR_INT)(p1 - start), mcnt2); | |
827 | 830 | break; |
828 | 831 | |
829 | 832 | case set_number_at: |
830 | 833 | extract_number_and_incr (&mcnt, &p); |
831 | 834 | p1 = p + mcnt; |
832 | 835 | extract_number_and_incr (&mcnt2, &p); |
833 | printf ("/set_number_at location %d to %d", p1 - start, mcnt2); | |
836 | printf ("/set_number_at location %d to %d", (GR_INT)(p1 - start), mcnt2); | |
834 | 837 | break; |
835 | 838 | |
836 | 839 | case wordbound: |
897 | 900 | putchar ('\n'); |
898 | 901 | } |
899 | 902 | |
900 | printf ("%d:\tend of pattern.\n", p - start); | |
903 | printf ("%d:\tend of pattern.\n", (GR_INT)(p - start)); | |
901 | 904 | } |
902 | 905 | |
903 | 906 | |
917 | 920 | print_fastmap (bufp->fastmap); |
918 | 921 | } |
919 | 922 | |
920 | printf ("re_nsub: %d\t", bufp->re_nsub); | |
923 | printf ("re_nsub: %d\t", (GR_INT)(bufp->re_nsub)); | |
921 | 924 | printf ("regs_alloc: %d\t", bufp->regs_allocated); |
922 | 925 | printf ("can_be_null: %d\t", bufp->can_be_null); |
923 | 926 | printf ("newline_anchor: %d\n", bufp->newline_anchor); |
4100 | 4103 | fails at this starting point in the input data. */ |
4101 | 4104 | for (;;) |
4102 | 4105 | { |
4103 | #ifdef _LIBC | |
4104 | 4106 | DEBUG_PRINT2 ("\n%p: ", p); |
4105 | #else | |
4106 | DEBUG_PRINT2 ("\n0x%x: ", p); | |
4107 | #endif | |
4108 | 4107 | |
4109 | 4108 | if (p == pend) |
4110 | 4109 | { /* End of pattern means we might have succeeded. */ |
4683 | 4682 | DEBUG_PRINT1 ("EXECUTING on_failure_keep_string_jump"); |
4684 | 4683 | |
4685 | 4684 | EXTRACT_NUMBER_AND_INCR (mcnt, p); |
4686 | #ifdef _LIBC | |
4687 | 4685 | DEBUG_PRINT3 (" %d (to %p):\n", mcnt, p + mcnt); |
4688 | #else | |
4689 | DEBUG_PRINT3 (" %d (to 0x%x):\n", mcnt, p + mcnt); | |
4690 | #endif | |
4691 | 4686 | |
4692 | 4687 | PUSH_FAILURE_POINT (p + mcnt, NULL, -2); |
4693 | 4688 | break; |
4710 | 4705 | DEBUG_PRINT1 ("EXECUTING on_failure_jump"); |
4711 | 4706 | |
4712 | 4707 | EXTRACT_NUMBER_AND_INCR (mcnt, p); |
4713 | #ifdef _LIBC | |
4714 | 4708 | DEBUG_PRINT3 (" %d (to %p)", mcnt, p + mcnt); |
4715 | #else | |
4716 | DEBUG_PRINT3 (" %d (to 0x%x)", mcnt, p + mcnt); | |
4717 | #endif | |
4718 | 4709 | |
4719 | 4710 | /* If this on_failure_jump comes right before a group (i.e., |
4720 | 4711 | the original * applied to a group), save the information |
4919 | 4910 | /* Note fall through. */ |
4920 | 4911 | |
4921 | 4912 | unconditional_jump: |
4922 | #ifdef _LIBC | |
4923 | 4913 | DEBUG_PRINT2 ("\n%p: ", p); |
4924 | #else | |
4925 | DEBUG_PRINT2 ("\n0x%x: ", p); | |
4926 | #endif | |
4927 | 4914 | /* Note fall through. */ |
4928 | 4915 | |
4929 | 4916 | /* Unconditionally jump (without popping any failure points). */ |
4931 | 4918 | EXTRACT_NUMBER_AND_INCR (mcnt, p); /* Get the amount to jump. */ |
4932 | 4919 | DEBUG_PRINT2 ("EXECUTING jump %d ", mcnt); |
4933 | 4920 | p += mcnt; /* Do the jump. */ |
4934 | #ifdef _LIBC | |
4935 | 4921 | DEBUG_PRINT2 ("(to %p).\n", p); |
4936 | #else | |
4937 | DEBUG_PRINT2 ("(to 0x%x).\n", p); | |
4938 | #endif | |
4939 | 4922 | break; |
4940 | 4923 | |
4941 | 4924 | |
4984 | 4967 | mcnt--; |
4985 | 4968 | p += 2; |
4986 | 4969 | STORE_NUMBER_AND_INCR (p, mcnt); |
4987 | #ifdef _LIBC | |
4988 | 4970 | DEBUG_PRINT3 (" Setting %p to %d.\n", p - 2, mcnt); |
4989 | #else | |
4990 | DEBUG_PRINT3 (" Setting 0x%x to %d.\n", p - 2, mcnt); | |
4991 | #endif | |
4992 | 4971 | } |
4993 | 4972 | else if (mcnt == 0) |
4994 | 4973 | { |
4995 | #ifdef _LIBC | |
4996 | 4974 | DEBUG_PRINT2 (" Setting two bytes from %p to no_op.\n", p+2); |
4997 | #else | |
4998 | DEBUG_PRINT2 (" Setting two bytes from 0x%x to no_op.\n", p+2); | |
4999 | #endif | |
5000 | 4975 | p[2] = (unsigned char) no_op; |
5001 | 4976 | p[3] = (unsigned char) no_op; |
5002 | 4977 | goto on_failure; |
5012 | 4987 | { |
5013 | 4988 | mcnt--; |
5014 | 4989 | STORE_NUMBER (p + 2, mcnt); |
5015 | #ifdef _LIBC | |
5016 | 4990 | DEBUG_PRINT3 (" Setting %p to %d.\n", p + 2, mcnt); |
5017 | #else | |
5018 | DEBUG_PRINT3 (" Setting 0x%x to %d.\n", p + 2, mcnt); | |
5019 | #endif | |
5020 | 4991 | goto unconditional_jump; |
5021 | 4992 | } |
5022 | 4993 | /* If don't have to jump any more, skip over the rest of command. */ |
5031 | 5002 | EXTRACT_NUMBER_AND_INCR (mcnt, p); |
5032 | 5003 | p1 = p + mcnt; |
5033 | 5004 | EXTRACT_NUMBER_AND_INCR (mcnt, p); |
5034 | #ifdef _LIBC | |
5035 | 5005 | DEBUG_PRINT3 (" Setting %p to %d.\n", p1, mcnt); |
5036 | #else | |
5037 | DEBUG_PRINT3 (" Setting 0x%x to %d.\n", p1, mcnt); | |
5038 | #endif | |
5039 | 5006 | STORE_NUMBER (p1, mcnt); |
5040 | 5007 | break; |
5041 | 5008 | } |
405 | 405 | |
406 | 406 | "Note that EVCDFILE is optional provided the --filename\n" |
407 | 407 | "option is specified. VCD is emitted to stdout.\n\n" |
408 | "Report bugs to <bybell@nc.rr.com>.\n",nam); | |
408 | "Report bugs to <"PACKAGE_BUGREPORT">.\n",nam); | |
409 | 409 | #else |
410 | 410 | printf( |
411 | 411 | "Usage: %s [OPTION]... [EVCDFILE]\n\n" |
414 | 414 | |
415 | 415 | "Note that EVCDFILE is optional provided the --filename\n" |
416 | 416 | "option is specified. VCD is emitted to stdout.\n\n" |
417 | "Report bugs to <bybell@nc.rr.com>.\n",nam); | |
417 | "Report bugs to <"PACKAGE_BUGREPORT">.\n",nam); | |
418 | 418 | #endif |
419 | 419 | |
420 | 420 | exit(0); |
36 | 36 | " -f, --fstname=FILE specify FST input filename\n" |
37 | 37 | " -h, --help display this help then exit\n\n" |
38 | 38 | "VCD is emitted to stdout.\n\n" |
39 | "Report bugs to <bybell@nc.rr.com>.\n",nam); | |
39 | "Report bugs to <"PACKAGE_BUGREPORT">.\n",nam); | |
40 | 40 | #else |
41 | 41 | printf( |
42 | 42 | "Usage: %s [OPTION]... [FSTFILE]\n\n" |
44 | 44 | " -h display this help then exit\n\n" |
45 | 45 | |
46 | 46 | "FST is emitted to stdout.\n\n" |
47 | "Report bugs to <bybell@nc.rr.com>.\n",nam); | |
47 | "Report bugs to <"PACKAGE_BUGREPORT">.\n",nam); | |
48 | 48 | #endif |
49 | 49 | |
50 | 50 | exit(0); |
159 | 159 | " -c, --comprehensive do not stop after first match\n" |
160 | 160 | " -h, --help display this help then exit\n\n" |
161 | 161 | "First occurrence of facnames with times and matching values are emitted to\nstdout. Using -n generates a gtkwave save file.\n\n" |
162 | "Report bugs to <bybell@nc.rr.com>.\n",nam); | |
162 | "Report bugs to <"PACKAGE_BUGREPORT">.\n",nam); | |
163 | 163 | #else |
164 | 164 | printf( |
165 | 165 | "Usage: %s [OPTION]... [VZTFILE]\n\n" |
170 | 170 | " -c do not stop after first match\n" |
171 | 171 | " -h display this help then exit (gtkwave savefile)\n\n" |
172 | 172 | "First occurrence of facnames with times and matching values are emitted to\nstdout. Using -n generates a gtkwave save file.\n\n" |
173 | "Report bugs to <bybell@nc.rr.com>.\n",nam); | |
173 | "Report bugs to <"PACKAGE_BUGREPORT">.\n",nam); | |
174 | 174 | #endif |
175 | 175 | |
176 | 176 | exit(0); |
312 | 312 | " -n, --notruncate do not shorten bitvectors\n" |
313 | 313 | " -h, --help display this help then exit\n\n" |
314 | 314 | "VCD is emitted to stdout.\n\n" |
315 | "Report bugs to <bybell@nc.rr.com>.\n",nam); | |
315 | "Report bugs to <"PACKAGE_BUGREPORT">.\n",nam); | |
316 | 316 | #else |
317 | 317 | printf( |
318 | 318 | "Usage: %s [OPTION]... [LXT2FILE]\n\n" |
322 | 322 | " -h display this help then exit\n\n" |
323 | 323 | |
324 | 324 | "VCD is emitted to stdout.\n\n" |
325 | "Report bugs to <bybell@nc.rr.com>.\n",nam); | |
325 | "Report bugs to <"PACKAGE_BUGREPORT">.\n",nam); | |
326 | 326 | #endif |
327 | 327 | |
328 | 328 | exit(0); |
785 | 785 | |
786 | 786 | "Note that VCDFILE and FSTFILE are optional provided the\n" |
787 | 787 | "--vcdname and --fstname options are specified.\n\n" |
788 | "Report bugs to <bybell@nc.rr.com>.\n",nam); | |
788 | "Report bugs to <"PACKAGE_BUGREPORT">.\n",nam); | |
789 | 789 | #else |
790 | 790 | printf( |
791 | 791 | "Usage: %s [OPTION]... [VCDFILE] [FSTFILE]\n\n" |
797 | 797 | |
798 | 798 | "Note that VCDFILE and FSTFILE are optional provided the\n" |
799 | 799 | "--vcdname and --fstname options are specified.\n\n" |
800 | "Report bugs to <bybell@nc.rr.com>.\n",nam); | |
800 | "Report bugs to <"PACKAGE_BUGREPORT">.\n",nam); | |
801 | 801 | #endif |
802 | 802 | |
803 | 803 | exit(0); |
1867 | 1867 | "VCD files may be compressed with zip or gzip. Note that VCDFILE and LXTFILE\n" |
1868 | 1868 | "are optional provided the --vcdname and --lxtname options are specified.\n" |
1869 | 1869 | "Use \"-\" as a VCD filename to accept uncompressed input from stdin.\n\n" |
1870 | "Report bugs to <bybell@nc.rr.com>.\n",nam); | |
1870 | "Report bugs to <"PACKAGE_BUGREPORT">.\n",nam); | |
1871 | 1871 | #else |
1872 | 1872 | printf( |
1873 | 1873 | "Usage: %s [OPTION]... [VCDFILE] [LXT2FILE]\n\n" |
1883 | 1883 | "VCD files may be compressed with zip or gzip. Note that VCDFILE and LXTFILE\n" |
1884 | 1884 | "are optional provided the --vcdname and --lxtname options are specified.\n" |
1885 | 1885 | "Use \"-\" as a VCD filename to accept uncompressed input from stdin.\n\n" |
1886 | "Report bugs to <bybell@nc.rr.com>.\n",nam); | |
1886 | "Report bugs to <"PACKAGE_BUGREPORT">.\n",nam); | |
1887 | 1887 | #endif |
1888 | 1888 | |
1889 | 1889 | exit(0); |
1869 | 1869 | "VCD files may be compressed with zip or gzip. Note that VCDFILE and VZTFILE\n" |
1870 | 1870 | "are optional provided the --vcdname and --vztname options are specified.\n" |
1871 | 1871 | "Use \"-\" as a VCD filename to accept uncompressed input from stdin.\n\n" |
1872 | "Report bugs to <bybell@nc.rr.com>.\n",nam); | |
1872 | "Report bugs to <"PACKAGE_BUGREPORT">.\n",nam); | |
1873 | 1873 | #else |
1874 | 1874 | printf( |
1875 | 1875 | "Usage: %s [OPTION]... [VCDFILE] [VZTFILE]\n\n" |
1886 | 1886 | "VCD files may be compressed with zip or gzip. Note that VCDFILE and VZTFILE\n" |
1887 | 1887 | "are optional provided the --vcdname and --vztname options are specified.\n" |
1888 | 1888 | "Use \"-\" as a VCD filename to accept uncompressed input from stdin.\n\n" |
1889 | "Report bugs to <bybell@nc.rr.com>.\n",nam); | |
1889 | "Report bugs to <"PACKAGE_BUGREPORT">.\n",nam); | |
1890 | 1890 | #endif |
1891 | 1891 | |
1892 | 1892 | exit(0); |
322 | 322 | " -n, --notruncate do not shorten bitvectors\n" |
323 | 323 | " -h, --help display this help then exit\n\n" |
324 | 324 | "VCD is emitted to stdout.\n\n" |
325 | "Report bugs to <bybell@nc.rr.com>.\n",nam); | |
325 | "Report bugs to <"PACKAGE_BUGREPORT">.\n",nam); | |
326 | 326 | #else |
327 | 327 | printf( |
328 | 328 | "Usage: %s [OPTION]... [VZTFILE]\n\n" |
333 | 333 | " -h display this help then exit\n\n" |
334 | 334 | |
335 | 335 | "VCD is emitted to stdout.\n\n" |
336 | "Report bugs to <bybell@nc.rr.com>.\n",nam); | |
336 | "Report bugs to <"PACKAGE_BUGREPORT">.\n",nam); | |
337 | 337 | #endif |
338 | 338 | |
339 | 339 | exit(0); |
161 | 161 | " -c, --comprehensive do not stop after first match\n" |
162 | 162 | " -h, --help display this help then exit\n\n" |
163 | 163 | "First occurrence of facnames with times and matching values are emitted to\nstdout. Using -n generates a gtkwave save file.\n\n" |
164 | "Report bugs to <bybell@nc.rr.com>.\n",nam); | |
164 | "Report bugs to <"PACKAGE_BUGREPORT">.\n",nam); | |
165 | 165 | #else |
166 | 166 | printf( |
167 | 167 | "Usage: %s [OPTION]... [VZTFILE]\n\n" |
172 | 172 | " -c do not stop after first match\n" |
173 | 173 | " -h display this help then exit (gtkwave savefile)\n\n" |
174 | 174 | "First occurrence of facnames with times and matching values are emitted to\nstdout. Using -n generates a gtkwave save file.\n\n" |
175 | "Report bugs to <bybell@nc.rr.com>.\n",nam); | |
175 | "Report bugs to <"PACKAGE_BUGREPORT">.\n",nam); | |
176 | 176 | #endif |
177 | 177 | |
178 | 178 | exit(0); |
30 | 30 | #include <sys/types.h> |
31 | 31 | #endif |
32 | 32 | |
33 | #if !defined _MSC_VER && !defined OS_X && defined WAVE_USE_GTK2 | |
33 | #if !defined _MSC_VER && defined WAVE_USE_GTK2 | |
34 | 34 | #define WAVE_USE_XID |
35 | 35 | #else |
36 | 36 | #undef WAVE_USE_XID |
37 | 37 | #endif |
38 | ||
39 | 38 | |
40 | 39 | #ifdef HAVE_GETOPT_LONG |
41 | 40 | #include <getopt.h> |
300 | 299 | "Note that DUMPFILE is optional if the --dump or --nocli options are specified.\n" |
301 | 300 | "SAVEFILE and RCFILE are always optional.\n\n" |
302 | 301 | |
303 | "Report bugs to <bybell@nc.rr.com>.\n",nam); | |
302 | "Report bugs to <"PACKAGE_BUGREPORT">.\n",nam); | |
304 | 303 | |
305 | 304 | exit(0); |
306 | 305 | } |
2828 | 2828 | void make_tcl_interpreter(char *argv[]) |
2829 | 2829 | { |
2830 | 2830 | int i; |
2831 | char commandName[256]; | |
2831 | char commandName[32768]; | |
2832 | 2832 | GtkItemFactoryEntry *ife; |
2833 | 2833 | int num_menu_items; |
2834 | 2834 | int n = 0; |
2836 | 2836 | #ifndef WAVE_TCL_STUBIFY |
2837 | 2837 | Tcl_FindExecutable(argv[0]); |
2838 | 2838 | #endif |
2839 | #if (defined(__MACH__) && defined(__APPLE__)) | |
2840 | { | |
2841 | uint32_t size = sizeof(commandName); | |
2842 | if(_NSGetExecutablePath(commandName, &size) == 0) | |
2843 | { | |
2844 | set_globals_interp(commandName, 0); | |
2845 | } | |
2846 | else | |
2847 | { | |
2848 | char *p = calloc_2(1, size+1); | |
2849 | size++; | |
2850 | if(_NSGetExecutablePath(p, &size) == 0) | |
2851 | { | |
2852 | set_globals_interp(p, 0); | |
2853 | } | |
2854 | else | |
2855 | { | |
2856 | fprintf(stderr, "GTKWAVE | Problem with _NSGetExecutablePath, exiting.\n"); | |
2857 | exit(255); | |
2858 | } | |
2859 | free_2(p); | |
2860 | } | |
2861 | } | |
2862 | #else | |
2839 | 2863 | #ifdef WIN32 |
2840 | 2864 | if(!GetModulePathName(NULL, commandName, 256)) |
2841 | 2865 | n = -1 ; |
2849 | 2873 | commandName[n] = '\0' ; |
2850 | 2874 | } |
2851 | 2875 | set_globals_interp(commandName, 0); |
2876 | #endif | |
2852 | 2877 | |
2853 | 2878 | #ifndef WAVE_TCL_STUBIFY |
2854 | 2879 | if (TCL_OK != Tcl_Init(GLOBALS->interp)) |
57 | 57 | # define SHLIB_SUFFIX ".dll" |
58 | 58 | # endif |
59 | 59 | |
60 | #elif defined(XP_MACOSX) /* Mac OS X */ | |
60 | #elif (defined(__MACH__) && defined(__APPLE__)) /* Mac OS X */ | |
61 | 61 | |
62 | 62 | # include <stdio.h> |
63 | # include <Carbon/Carbon.h> | |
63 | /* # include <Carbon/Carbon.h> */ /* Commented out: ajb 25sep11 */ | |
64 | 64 | |
65 | 65 | # if HAVE_UNISTD_H |
66 | 66 | # include <sys/types.h> |
21 | 21 | |
22 | 22 | #include "debug.h" |
23 | 23 | |
24 | #if !defined _MSC_VER && !defined OS_X && defined WAVE_USE_GTK2 | |
24 | #if !defined _MSC_VER && defined WAVE_USE_GTK2 | |
25 | 25 | |
26 | 26 | static int plug_removed(GtkWidget *widget, gpointer data) |
27 | 27 | { |
423 | 423 | fprintf(stderr, "Sorry, this doesn't run under Win32!\n"); |
424 | 424 | #endif |
425 | 425 | |
426 | #ifdef OS_X | |
427 | fprintf(stderr, "Sorry, this doesn't run under OS_X!\n"); | |
428 | #endif | |
429 | ||
430 | 426 | fprintf(stderr, "If you find that this program works on your platform, please report this to the maintainers.\n"); |
431 | 427 | |
432 | 428 | return(255); |