Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

uses wrong path separator for configuration #127

Open
BartVertongen opened this issue Jul 3, 2022 · 2 comments
Open

uses wrong path separator for configuration #127

BartVertongen opened this issue Jul 3, 2022 · 2 comments

Comments

@BartVertongen
Copy link

BartVertongen commented Jul 3, 2022

D:\VertSoft\Cobol\learning\MyTest>cobc -x TestProgram01
configuration error:
/mingw/share/gnu-cobol/config\default.conf: No such file or directory

How can I fix this.
I think if the last separator is changed it will work but how to do it?

I use VSCode on Windows but apparentlythe debugger uses a docker container and that is linux

@GitMensch
Copy link
Contributor

A docker container will only be used if you explicit configure it.
The part that is missing in your setup is that the compiler you use (a MinGW based one) is not built for the path you have it placed in (it rarely isn't), cobc is not relocatable (a feature that looks for the files relative to itself, something that is worked on in GnuCOBOL 4+, currently works in GNU/Linux) and you did not instruct it to use a different path.

So: instruct it to use a different path as you do when using this version of cobc in other setups - either globally set COB_CONFIG_DIR and friends in your Windows environment, or set it before starting vscode (commonly by double-click on set_env.cmd then starting vscodium.exe / code.exe from the opening command prompt) or by creating a minimal cobc.cmd that just contains X:\path\to\set_env.cmd && cobc.exe %* - then point this extension to use this cobc.cmd.

@GitMensch
Copy link
Contributor

Note: if the following is still true:

I get cobc.exe from the installation of OpenCobol IDE on Windows 10

Then it is highly suggested to get a newer GnuCOBOL package (if you want to still use OCIDE then replace it there), you can get it from the same place where the old one distributed with OCIDE on Win32 got it from: https://arnoldtrembley.com/GnuCOBOL.htm

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants