Menu

I can't compile it

Help
2007-10-02
2013-04-23
  • Lorenzo Paulatto

    I am trying to compile v 2.20 unofficial on linux (as v 2.10 tarball has capital names that mess up everything). I get this error:

    gcc -c  -I. -DHAVE_STRING=1 -DHAVE_STDLIB=1 -DHAVE_UNISTD=1 -DHAVE_RAISE=1 -g -ansi bwbasic.c
    bwbasic.c:54: error: initializer element is not constant
    make: *** [bwbasic.o] Error 1

     
    • Paul Edwards

      Paul Edwards - 2008-07-23

      That problem has been fixed in bwbasic 2.30 which can be found at:

      http://gccmvs.sourceforge.net

      Here's the specific patch required:

      C:\devel\bwbasic>cvs diff -c -r release-2_20 bwbasic.c
      Index: bwbasic.c
      ===================================================================
      RCS file: c:\cvsroot/bwbasic/bwbasic.c,v
      retrieving revision 1.1.1.1
      retrieving revision 1.3
      diff -c -r1.1.1.1 -r1.3
      *** bwbasic.c   24 Oct 2006 03:40:17 -0000      1.1.1.1
      --- bwbasic.c   24 Oct 2006 04:41:09 -0000      1.3
      ***************
      *** 51,57 ****
        char *bwb_ebuf;                               /* error buffer */
        static char *read_line;
        int bwb_trace = FALSE;
      ! FILE *errfdevice = stderr;              /* output device for error messages */

        #if HAVE_LONGJUMP
        jmp_buf mark;
      --- 51,57 ----
        char *bwb_ebuf;                               /* error buffer */
        static char *read_line;
        int bwb_trace = FALSE;
      ! FILE *errfdevice;              /* output device for error messages */

        #if HAVE_LONGJUMP
        jmp_buf mark;
      ***************
      *** 133,138 ****
      --- 133,139 ----
           static char end_buf[] = "\0";
        #endif

      +    errfdevice = stderr;
        #if INTENSIVE_DEBUG
           prn_xprintf( stderr, "Memory Allocation Statistics:\n" );
           prn_xprintf( stderr, "----------------------------\n" );

      BFN.  Paul.

       

Log in to post a comment.