From owner-bug-octave at bevo dot che dot wisc dot edu Mon Oct 30 16:21:05 1995 Subject: Applied patch. Better, but helpq crashes etc... From: Mirsad Todorovac To: bug-octave at che dot utexas dot edu Date: Mon, 30 Oct 1995 23:08:24 +0100 Bug report for Octave 1.1.1 configured for sparc-sun-sunos4.1.1 Description: ----------- Thanks for the pointer to the patch. Now it compiled without many problems, only some suspicious warnings about something used before declared inline ... probably not important. Still, after mistyping command in command line or on breaking output of the pager it crashes unfortunatelly. After reconstructing simbol table I've managed to get some debugging output. It is in Appendix A. Hope it will help. -- Mirsad ---- Actually, I'm interrested to use octave in a collegium called "Modelling and Simulating" and possibly some others on the college where I work, so I hope I'll be capable to fit it into the schedule. Labs start in next (summer) semester, so I hope I could make it work by then. I would try gcc-2.6.3, but I can't seem to find it. Our mirror site doesn't have it anymore. Repeat-By: --------- gzip -cd octave-1.1.1.tar.gz | tar xvf - patch < OCTAVE-GCC-2.7.0-PATCH cd octave-1.1.1 make -k CXXFLAGS="-g -O2 -fno-for-scope" CFLAGS="-g -O2" FFLAGS="-O -g" LDFLAGS=-s ./octave octave:1>help [ screenfull of output ]

SIGPIPE, later SIGSEGV later still: cd src rm octave make -k CXXFLAGS=-g LDFLAGS= Fix: --- Not excluding posibility of trying one. Configuration (please do not edit this section): ----------------------------------------------- uname output: SunOS rasips2 4.1.1 3 sun4c Fortran compiler: g77 FFLAGS: -O F2C: F2CFLAGS: FLIBS: -lf2c -L/usr/local/lib/gcc-lib/sparc-sun-sunos4.1.1/2.7.0 -L/usr/local/lib -lgcc C compiler: gcc CFLAGS: -DHAVE_CONFIG_H -O2 -g C++ compiler: c++ CXXFLAGS: -DHAVE_CONFIG_H -fno-implicit-templates -O2 -g LDFLAGS: -s DEFS: -DOCTAVE_SOURCE=1 -DSEPCHAR=':' -DSEPCHAR_STR=: -DNPSOL_MISSING=1 -DQPSOL_MISSING=1 -DFSQP_MISSING=1 -DHAVE_STRFTIME=1 -DSIZEOF_SHORT=2 -DSIZEOF_INT=4 -DSIZEOF_LONG=4 -DWORDS_BIGENDIAN=1 -DIEEE_BIG_ENDIAN=1 -DHAVE_ALLOCA_H=1 -DHAVE_ALLOCA=1 -DF77_APPEND_UNDERSCORE=1 -DHAVE_ASSERT_H=1 -DHAVE_FLOAT_H=1 -DHAVE_LIMITS_H=1 -DHAVE_MEMORY_H=1 -DHAVE_PWD_H=1 -DHAVE_STDLIB_H=1 -DHAVE_STRING_H=1 -DHAVE_VARARGS_H=1 -DHAVE_UNISTD_H=1 -DHAVE_FLOATINGPOINT_H=1 -DHAVE_SYS_UTSNAME_H=1 -DHAVE_SYS_TIME_H=1 -DHAVE_SYS_FCNTL_H=1 -DHAVE_SYS_TTOLD_H=1 -DHAVE_SYS_RESOURCE_H=1 -DHAVE_DIRENT_H=1 -DTIME_WITH_SYS_TIME=1 -DHAVE_TERMIOS_H=1 -DHAVE_SETVBUF=1 -DHAVE_GETCWD=1 -DHAVE_GETHOSTNAME=1 -DHAVE_BZERO=1 -DHAVE_BCOPY=1 -DHAVE_RINDEX=1 -DHAVE_VFPRINTF=1 -DHAVE_VSPRINTF=1 -DHAVE_STRICMP=1 -DHAVE_STRNICMP=1 -DHAVE_STRCASECMP=1 -DHAVE_STRNCASECMP=1 -DHAVE_ON_EXIT=1 -DHAVE_TEMPNAM=1 -DHAVE_PUTENV=1 -DHAVE_GETTIMEOFDAY=1 -DHAVE_GETRUSAGE=1 -DHAVE_LIBM=1 -DHAVE_FINITE=1 -DHAVE_ISNAN=1 -DHAVE_ISINF=1 -DHAVE_INFINITY=1 -DHAVE_QUIET_NAN=1 -DH Appendix A ---------- > gdb ./octave GDB is free software and you are welcome to distribute copies of it under certain conditions; type "show copying" to see the conditions. There is absolutely no warranty for GDB; type "show warranty" for details. GDB 4.13 (sparc-sun-sunos4.1.1), Copyright 1994 Free Software Foundation, Inc... (gdb) run Starting program: /auto/usr3/s2/export/tmp/tm/gnu/octave-1.1.1/src/./octave Octave, version 1.1.1. Copyright (C) 1992, 1993, 1994, 1995 John W. Eaton. This is free software with ABSOLUTELY NO WARRANTY. For details, type `warranty'. octave:1> help Program received signal SIGPIPE, Broken pipe. 0xf77322d8 in write () (gdb) cont Continuing. broken pipe Program received signal SIGSEGV, Segmentation fault. 0x1b2170 in _IO_proc_close (fp=0x2a0950) at iopopen.c:174 iopopen.c:174: No such file or directory. Current language: auto; currently c (gdb) where #0 0x1b2170 in _IO_proc_close (fp=0x2a0950) at iopopen.c:174 #1 0x1a91bc in procbuf::sys_close (this=0x2a0950) at procbuf.cc:45 #2 0x1abebc in _IO_file_close_it (fp=0x2a0950) at fileops.c:113 #3 0x1a32e4 in filebuf::close (this=0x2a0950) at filebuf.cc:156 #4 0x3d0bc in procstreambase::close (this=0xf7fff088) at /usr/local/lib/g++-include/procbuf.h:36 #5 0x31740 in flush_output_to_pager () at pager.cc:155 #6 0x1d964 in octave_gets () at input.cc:481 #7 0x1dae4 in octave_read (buf=0x289f71 "", max_size=8192) at input.cc:539 #8 0x204b4 in yy_get_next_buffer () at lex.l:810 #9 0x201c0 in yylex () at lex.l:658 #10 0x325b0 in yyparse () at /usr/local/gnu/lib/bison.simple:354 #11 0x2def0 in main (argc=-134219688, argv=0x1ff800) at octave.cc:630 pager.cc: 151 152 pager_stream << message; 153 delete [] message; 154 pager_stream.flush (); 155 pager_stream.close (); 156 157 signal (SIGINT, old_sigint_handler); input.cc: 473 if (interactive || forced_interactive) 474 { 475 char *ps = (promptflag > 0) ? user_pref.ps1 : user_pref.ps2; 476 char *prompt = decode_prompt_string (ps); 477 478 if (interactive) 479 { 480 pipe_handler_error_count = 0; 481 flush_output_to_pager (); 482 } 483 484 maybe_write_to_diary_file (prompt); 485 486 octave_gets_line = gnu_readline (prompt); 487 488 delete [] prompt; 489 } 490 else lex.l:180: 798 { 799 return (void *) realloc (ptr, (unsigned) size); 800 } 801 802 static void 803 yy_flex_free (void *ptr) 804 { 805 free (ptr); 806 } 807 #endif 808 809 // Tell us all what the current buffer is. 810 811 YY_BUFFER_STATE 812 current_buffer (void) 813 { 814 return YY_CURRENT_BUFFER; 815 } 816 817 // Create a new buffer. 818 819 YY_BUFFER_STATE --- End of Appendix A