Skip to main content

compile c++ program with local g++/mingw compiler.

Project description

cpp_simple_interface

compile and run C++ executable in python with local compiler.

Install

pip install cpp-simple-interface

Usage

import cpp_simple_interface

# create test file
with open("a.cpp", "w") as fp:
    fp.write(
"""
#include <cstdio>
int main() {
    printf("hello world!");
    return 0;
}
""")

# compile test file
suc, msg = cpp_simple_interface.compile_cpp_files(["./a.cpp"], "./a.exe")
if not suc:
    print(msg)

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

cpp_simple_interface-0.0.2.tar.gz (3.8 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

cpp_simple_interface-0.0.2-py3-none-any.whl (5.3 kB view details)

Uploaded Python 3

File details

Details for the file cpp_simple_interface-0.0.2.tar.gz.

File metadata

  • Download URL: cpp_simple_interface-0.0.2.tar.gz
  • Upload date:
  • Size: 3.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.3.2 CPython/3.13.12 Windows/11

File hashes

Hashes for cpp_simple_interface-0.0.2.tar.gz
Algorithm Hash digest
SHA256 c55ce15943cf8b9a88cc61b477eac83a73ee94d4787ab686a7c136a6d86811e5
MD5 50608742fe6d8bf551a0b8afa71d8a48
BLAKE2b-256 ca766252f1fad49d8bbe314dc80ab97919a1e5dcabc580445467a7c120ddffb6

See more details on using hashes here.

File details

Details for the file cpp_simple_interface-0.0.2-py3-none-any.whl.

File metadata

File hashes

Hashes for cpp_simple_interface-0.0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 b2204cbb86645259915a608bdeed1b8fe1b367511dca2bdffbe25473197a0db3
MD5 5a0670028e1298b1c8c3625a665a1034
BLAKE2b-256 a64c6f9cb92dfe2fa21dcd6918ef29275f0bb1f7fcc2618b5748263b26032703

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page