COBOL-to-Java Interactive Transpiler (Study Project)
This repository is part of an academic study project.
Its primary goal is to design and implement an interactive transpiler that translates COBOL code into Java, while allowing user-guided customization and integration of modern design patterns.
Requirements
Before using the provided commands, ensure you have the following installed on your system:
- Docker
Used to build LaTeX documents inside a containerized environment. - Make
Used to execute the predefined commands in theMakefile.
Usage
The repository includes a Makefile with predefined commands.
To list all available commands, run:
make help
To build the pdf documents (thesis or exposé) from latex, run:
make build-thesis
make build-expose
You can also run COBOL programs using:
make run-cobol
This will run the hello world program. If you want to run your own COBOL programs, place them inside the data/cobol-files/ directory. You can then execute them by specifying the filename as a parameter:
make run-cobol FILE=your_program.cbl
Linux-specific notes
On Linux, in order to run Docker commands via the Makefile without sudo, your current user must be a member of the docker group. Otherwise, you will encounter "permission denied" errors.
To add your current user to the Docker group and activate the group immediately, run:
sudo usermod -aG docker $(whoami) && newgrp docker
Windows-specific notes
- On Windows, you may need to adjust the shell used by Make, especially if you are running PowerShell.
- It is recommended to use Git Bash as the shell for full compatibility.
- You may also need to adjust the
DIRECTORYvariable in.envif Docker requires a Windows-style path (e.g.,C:/Users/...).
Setting shell and directory
You can set the shell and project directory with Make targets:
make set-shell LOCAL_SHELL="C:/Program Files/Git/usr/bin/bash.exe" LOCAL_SHELLFLAGS="--login -i -c"
make set-directory LOCAL_DIRECTORY="C:/users/admin/project"
set-shellupdatesSHELLandSHELLFLAGSin.env.set-directoryupdatesDIRECTORYin.env.
Checking variables
You can check which variables Make is using:
make check-variables
Manual .env setup
If nothing works yet, you can manually create or edit .env in the project root:
SHELL=C:/Program Files/Git/usr/bin/bash.exe
SHELLFLAGS=--login -i -c
DIRECTORY=C:/users/admin/project
Project Structure
. ├── paper/ LaTeX sources for thesis and exposé ├── implementation/ Source code of the interactive COBOL-to-Java transpiler ├── data/ Sample Cobol code └── final/ Finalized documents for submission (thesis, exposé, reports)