Automate setup of CMake projects
Project description
Summary:
Automate setup of CMake projects for large C & C++ projects
- Automatically indexes .c, .h, .cpp, .hpp files and creates entries in CMakeLists.txt
- Automatically generates CMakeLists.txt for subdirectories and create library entries in CMakeLists.txt
Sample Usage:
Steps:
- Create a python script that will import AutoCMake
- In this file define
- The project name and version
- Directories and paths to include and exclude
- Compiler flags
- Build directory
import os
from auto_cmake_exe import AutoCMakeExe
# Configuration
cmake_config = dict()
cmake_config['proj_name'] = 'proj_name'
cmake_config['proj_dir'] = os.path.abspath(os.path.join(os.getcwd(), os.pardir))
cmake_config['version'] = '0.01'
cmake_config['cmake_version'] = '3.15'
cmake_config['exclude_folders'] = ['excluded-folder-1', 'excluded-folder-2']
# Generate CMake
cme = AutoCMakeExe(**cmake_config)
cme.run()
- Run the script to generate all the CMakeLists.txt files
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
auto_cmake-2024.3.7.tar.gz
(7.4 kB
view hashes)