RunCpp is an easy tool to compile and run C++ programs
- Arguments --version and --help
- Check and install dependencies
- Turns on helpful warning messages with -Wall
- Omits all symbol information from the executable file thus making it as small as possible with -s
- Turns off a couple non-standard g++ additions with -pedantic-errors
- Using the most recent revision of the ISO/IEC 14882 standard for the C++ compiler (C++17)
- Argument -o to custom output filename
You need to follow these steps to run it.
$ git clone https://github.com/mateus4k/runcpp.git
$ cd runcpp/
$ sudo chmod u+x runcpp.sh
$ sudo cp runcpp.sh runcpp; sudo mv runcpp /usr/local/bin
This tool need a C/C++ compiler. Run which gcc g++
or command -v gcc g++
to see if you have it installed on your PC.
If that command doesn't output the code below you will need to install it.
/usr/bin/gcc
/usr/bin/g++
- For Debian-based distros, run
sudo apt install gcc g++
. - For Arch-based distros, run
sudo pacman -S gcc g++
. - For RedHat-based distros, run
sudo dnf install gcc gcc-c++
. - For OpenSuse-based distros, run
sudo zypper install gcc g++
To compile any .cpp source code run:
$ runcpp [arguments] <file>
Want to contribute? Great! Please follow the "fork-and-pull" git workflow.
- Fork the repo on GitHub
- Clone the project to your own machine
- Commit changes to your own branch
- Push your work back up to your fork
- Submit a Pull request so that I can review your changes