Menu

rm/cobol compile errors

2023-02-14
2024-01-22
<< < 1 2 3 4 5 > >> (Page 3 of 5)
  • Vincent (Bryan) Coen

    Have you downloaded the full gnucobol programmers guide ?

    If not, go to :
    https://gnucobol.sourceforge.io/guides.html

    and under
    GnuCOBOL Documentation
    Start Here with Gary's Guide, Updated by Vincent Coen

    select the Programmers Guide as A4 or Letter forma

    Back to your question if you used :
    cobc -x progname.cbl etc

    Then you do ./progname - for Linux

    or Windows progname.exe

    cobcrun is if you built the program as cobc -m prognam.cbl etc and I do not recommend the later method as it is not needed and includes an extra step or program.

    There again I build my main programs i.e, the one with the Menu as -x and all modules that it calls as cobc -m

    If you are totally happy with the program/modules i.e., no bugs then you can compile them together as cobc -x progname.cbl prog2.cbl prog3.cbl etc plus any -L or -I params needed.
    In this instance, all programs/modules will be as progname

    There are many other ways of doing this - see the manual under chapters 10, 11 and 12.

     
  • julius turner

    julius turner - 2023-03-07

    Simon: asked the followinfg,
    Just to recheck: is this any different when you use the current nightly MinGW binaries?

    Simon, I don't have clue.

     
  • julius turner

    julius turner - 2023-03-12

    Simon I installed the link and re-compiled the program I got a million and 1 errors.
    If you compile the program I send to you you will see the errors.
    The program jctprwwp.cbl worked under version 7 of RMcobol.
    how do you want me to handle it from here? Your thoughts are deeply needed.

     
  • julius turner

    julius turner - 2023-03-12

    C:\GnuCOBOL>
    C:\GnuCOBOL>C:\GnuCOBOL>ZZCRTNF.CPY:588: warning: IF statement not terminated by END-IF [-Wterminator]
    'C:\GnuCOBOL' is not recognized as an internal or external command,
    Simon this is a sample 0f the output from the compile

    C:\GnuCOBOL>The filename, directory name, or volume label syntax is incorrect.
    'The' is not recognized as an internal or external command,
    operable program or batch file.
    C:\GnuCOBOL>The filename, directory name, or volume label syntax is incorrect.
    'The' is not recognized as an internal or external command,
    operable program or batch file.

    C:\GnuCOBOL>
    C:\GnuCOBOL>C:\GnuCOBOL>ZZCRTNF.CPY:640: warning: IF statement not terminated by END-IF [-Wterminator]
    'C:\GnuCOBOL' is not recognized as an internal or external command,
    operable program or batch file.

    C:\GnuCOBOL>The filename, directory name, or volume label syntax is incorrect.
    'The' is not recognized as an internal or external command,
    operable program or batch file.

    C:\GnuCOBOL>
    C:\GnuCOBOL>C:\GnuCOBOL>ZZCRTNF.CPY:641: warning: IF statement not terminated by END-IF [-Wterminator]
    'C:\GnuCOBOL' is not recognized as an internal or external command,
    operable program or batch file.

     
  • julius turner

    julius turner - 2023-03-12

    Simon I just re-compiled the program about 5 min ago and i
    got the following:

    c:\GnuCOBOL>cobc -std=rm-strict -x -Wextra jctprwwp.cbl
    'cobc' is not recognized as an internal or external command,
    operable program or batch file.

     
    • Simon Sobisch

      Simon Sobisch - 2023-03-13

      You need to call the contained set_env.cmd to set the specific GnuCOBOL environment up (or start by double-clicking that file).

       
  • julius turner

    julius turner - 2023-03-13

    Simon could you show me how that is done or what doc I need to read

     
  • julius turner

    julius turner - 2023-03-14

    Simon, with the help of my son, we did what
    we though you wanted done
    the doc depicts our results

     
    • Simon Sobisch

      Simon Sobisch - 2023-03-15

      ok, the first one shows the result from double-clicking or otherwise executing set_env.bat - from a 3.1.2 release.
      The second one should look identical, just with the newer version, no?

      From within this opened command prompt you can then check your compile with cobc -std=rm-strict -x -Wextra jctprwwp.cbl.

       
    • Arnold Trembley

      Arnold Trembley - 2023-03-16

      I am confused. That happens a lot...

      If GnuCOBOL 3.1.2 is installed in C:\GnuCOBOL, then GnuCOBOL 3.2 Dev is installed INSIDE the GC 3.1.2 folder at "C:\GnuCOBOL\gnucobol-3.2-dev-MinGW-binaries (debug)" which is an invalid path because MinGW does not support blanks within Windows PATHs.

      That suggests to me that set_env.cmd won't be able to update the PATH variable with a correct link to "C:\GnuCOBOL\gnucobol-3.2-dev-MinGW-binaries (debug)\bin". If that is the case, then CMD.EXE will not be able to find the \bin folder containing cobc.exe in order to compile.

      Would it be possible to start over by installing GnuCOBOL 3.2 into a different folder, for example as "C:\GC32" ? I think then set_env.cmd would work and compiles would work.

      Also, there are newer versions of MinGW GC 3.2 binaries to download, for example:

      https://www.arnoldtrembley.com/GC32-BDB-rc2-rename-7z-to-exe.7z

      I hope that helps!

      Kind regards,

       
  • julius turner

    julius turner - 2023-03-15

    Simon I'm bit lost is it something I can do to keep this puppy going
    to exe and get a clean compile and test the program?

     
  • julius turner

    julius turner - 2023-03-25

    Simon sorry it took so long but I needed my son's help and today was his only time.
    we followed your request and the attached file depict the results.
    the attached file does include all the output which appears to be a repeat of listing

     
    • Mickey White

      Mickey White - 2023-03-27

      Julius, you may want to use Simon's user name to insure he looks at your response.
      @sf-mensch

       
  • Simon Sobisch

    Simon Sobisch - 2023-03-28

    So we've found another change in config/rm-strict.conf to make - set indirect-redefines to yes - or, as a workaround compile with -findirect-redefines to pass the single error given in the output.

    ... or not, because this was found already 2023-02-21.

    Note: you can mark any console output with the cursor (also multiple pages), then do just right click, copy, then paste anywhere as text. This way you don't need to copy + paste multiple images and if you post text here, then people reading along can easily answer.

     

    Last edit: Simon Sobisch 2023-03-28
  • julius turner

    julius turner - 2023-04-19

    Vincent, I downloaded the manual that has 750 pages

     
    • Vincent (Bryan) Coen

      Sounds about right for A4.

       
  • julius turner

    julius turner - 2023-04-19

    Sorry Simon, I did not mean to stray away from the discussion board.
    I compiled jctprwwp.cbl without errors or warnings. I can't find how to execute the program
    please help

     
    • DaveR

      DaveR - 2023-04-19

      If you complied with cobc -std=rm-strict -x -Wextra jctprwwp.cbl then there should be a file jctprwwp.exe so just typejctprwwpat the command prompt and hit enter.

      -x tells cobc to create an executable file.

      DaveR

       
  • julius turner

    julius turner - 2023-04-24

    thanks Dave for for the tip sorry it took so long to respond i have been ill I feel okay now.

     
  • julius turner

    julius turner - 2023-04-24

    Simon, Dave the program compiled with cobc -x jctprwwp and I exe it by typing in
    the cmd prompt jctprwwp The program displayed a screen depicting month day year track from to
    when data is entered in those fields the cursor should move from field to field allowing me to enter data in those fields please help what can we do?

     
  • julius turner

    julius turner - 2023-04-25

    Set_env.cmd screenshot

     
  • julius turner

    julius turner - 2023-04-25

    when I exe jctprwwp a screen is displayed see above

    fo1 month _ _ _ f02 day _ _ _ fo3 year _ - - and so on
    when I enter eg, APR -n the month field the cursor should auto to the next field
    egDAY it does not

    I am converting this program from RM cobol to gnucobol

    any suggestion all help is needed

     
<< < 1 2 3 4 5 > >> (Page 3 of 5)

Anonymous
Anonymous

Add attachments
Cancel