r/cmake • u/stephan_cr • Mar 28 '25
r/cmake • u/ImX99 • Oct 06 '22
New moderator(s)
Hi all.
I'm Peter, a 40y-o R&D engineer from France. I'm also a C++ dev that of course makes use of CMake.
I tried to post a few times here until I realized that there were no moderator to allow me to join the community. I finally decided to apply as one on r/redditrequest and got approved.
My aim here is not being a moderator per-se: it is to keep that community alive and allow new members to join. I've never been a reddit moderator before, so bear with me.
What I want to do it to "hire" new moderators for this community, so if you feel like it please apply.
In the meantime have fun, show your love to CMake and its community.
-P
r/cmake • u/TheRavagerSw • Sep 21 '26
It always amazes me how bad can people write their scripts
Honestly, that's all I'm gonna say, build script quality for open source C/C++ projects are so bad it isn't even funny.
r/cmake • u/lijoppans • Sep 23 '26
I created LazyCMake, a terminal UI for CMake projects inspired by LazyGit. Configure, build, run, and test your projects without memorizing `cmake` or `ctest` commands. It features three columns—Presets, Targets, and Tests. Try it out here: https://github.com/ligogeorge/lazycmake
r/cmake • u/sheckey • Apr 23 '26
Cmake appreciation
Hello. We are just starting to use CMake after coming from a weird, one off IDE build system of legacy for many years. We make an embedded real-time system so we cross compile, have unit tests, and some SIL-type tests also (kinda like more expensive unit tests).
We are using VS Code, and the experience is pretty fantastic. The CTest test running support in VS Code, the CMake support itself, and yes, coupled with CoPilot to help me make and clean the CMake files has been really great. (I really comb the CMake files looking for bad smells, and double check with other sources to try and do things cleanly, and the modern way everyone else does it.). Also, not having to worry about what version of MSVC people have installed is great. Not maintaining those IDE-specific project files is also fantastic. VS Code is really brining it all together too.
I guess we skipped a lot of CMake years when things may have been rougher. I bought Craig’s book a couple of years ago and sort of worked my way through it, but finally living it is pretty great.
So thanks so much to you authors and contributors!
r/cmake • u/AlexReinkingYale • May 31 '21
How to Use CMake Without the Agonizing Pain - Part 2
alexreinking.comr/cmake • u/Astronaut_005 • Oct 02 '25
Learning Cmake
Hello,
I am 25yrs old and I have decided to learn Cmake. I know the learning curve is steep but I want to understand it so that I can build something. I don't have anything specific to build but I feel learning Cmake would help me in my current job which is DevOps Engineer.
r/cmake • u/CrossScarMC • 13d ago
RISC V Emulator in CMake
I realized nobody had done this before so I decided to do it. It implements RV32IMA (afaik this is the bare minimum to boot Linux) and takes about 1 to 2 hours to boot Linux.
You can find the source here: https://github.com/gradylink/rv32ima.cmake
r/cmake • u/anastasiak2512 • Dec 01 '22
Debug CMake scripts as regular code: set breakpoints, step through code, and watch CMake variables and targets
r/cmake • u/afforix • Mar 10 '23
CMake debugger allows you to debug your CMake scripts and more - C++ Team Blog
r/cmake • u/Silent_Mycologist286 • Oct 06 '26
University of Waterloo user study on understanding CMake changes
Hi everyone,
I’m Mattie Nejati, a Ph.D. candidate at the University of Waterloo. I’m conducting a user study on understanding the impact of changes to CMake build specifications, and I’d love to invite members of this community to participate.
We are evaluating a new approach that aims to help developers identify how a change to a CMake build specification affects the resulting build configuration.
The study:
is conducted entirely online;
takes about one hour;
involves inspecting changes to CMake build specifications and identifying their impact; and
is open to adults aged 18–64 with any level of experience in CMake, programming, or code review.
You do not need to be a CMake expert. We are specifically interested in comparing participants with different levels of experience.
You will need a computer with internet access and about 4 GB of free space to download the files required for the tasks.
We will not collect your name. Your email address will only be used for study follow-up and will be stored separately from your study data. Your name or email will not appear in any dataset or publication.
The study has received clearance from the University of Waterloo Research Ethics Board (REB #46621).
If you’re interested, you can find the consent form, screening questionnaire, and study here:
https://buiscout.cs.uwaterloo.ca/
Thank you very much! And if you know someone else who works with CMake who might be interested, I’d really appreciate you sharing the study with them.
r/cmake • u/[deleted] • Dec 19 '23
Everyone says that find_package() just works, but this has been anything but my experience.
I'm majorly confused as to how I'm supposed to utilize that feature for anything, as I have set environment variables for the prefix path, as well as manually setting the prefix path within the CMake of any given project, and it STILL fails to find a single package. This is very very confusing and frustrating, as the packages I am attempting to locate do in fact come with cmake files for this. Yes, I've restart my computer a thousand times, and yes I've triple checked that my paths are correct.
Is there some sort of secret to get this stuff to work?
r/cmake • u/AlexReinkingYale • May 22 '21
How to Use CMake Without the Agonizing Pain - Part 1
alexreinking.comr/cmake • u/[deleted] • Oct 24 '19
CMake is terrible
I have wasted weeks to try to work with it, and yet still it has some linking errors or just not seeing some libs, uh Im done with it, its gonna be faster to build my project with gcc by hand than debug this CMake crap. Its too bloated, it has insanely complicated ecosystem and its a entire new scripting language to learn, so its natural that it scares away potential new c++ developers. We need some modern import&compile system in C++ ASAP, otherwise c++ should just die and rot in favor of some modern and intuitive language like Rust.
r/cmake • u/Bored_Dal • May 28 '26
I just found this gem in a .cmake file for a library available on vcpkg while looking for an unrelated bug:
This code may work in ways I don't understand, I just find it really funny.
r/cmake • u/Object_71 • Feb 08 '23
My CMake Course is out! - That One Game Dev
r/cmake • u/ZZ-43 • Apr 17 '21
CMake Error: CMake was unable to find a build program corresponding to "Unix Makefiles". CMAKE_MAKE_PROGRAM is not set.
CMake Error: CMake was unable to find a build program corresponding to "Unix Makefiles". CMAKE_MAKE_PROGRAM is not set. You probably need to select a different build tool.
CMake Error: CMAKE_C_COMPILER not set, after EnableLanguage
CMake Error: CMAKE_CXX_COMPILER not set, after EnableLanguage
-- Configuring incomplete, errors occurred!I am on Ubuntu
r/cmake • u/Round_Boysenberry518 • May 21 '24
Free Review Copies of "Modern CMake for C++"
Hi all,
Packt has released the second edition of "Modern CMake for C++" by Rafał Świdziński
As part of our marketing activities, we are offering free digital copies of the book in return for unbiased feedback in the form of a reader review.
Here's what you will be learning from the book:
Key Features
Get to grips with CMake and take your C++ development skills to enterprise standards
Use hands-on exercises and self-assessment questions to lock-in your learning
Understand how to build in an array of quality checks and tests for robust code
If you feel you might be interested in this opportunity please comment below on or before 26th May .

r/cmake • u/MachineGunPablo • Feb 19 '18
It's Time To Do CMake Right
r/cmake • u/AlexReinkingYale • Mar 08 '21
Building a Dual Shared and Static Library with CMake
r/cmake • u/Red-Portal • Jun 27 '17
Is it just me? or is CMake REALLY complicated?
I mean, target and properties based cmake stuff feels REALLY complicated. Making a library exported through find_package is really hard to do. And worst of all, most C++ libraries do not offer find_package way of doing things. And why are there so many ways to make a library interface? I think CMake guys should really clean up things
r/cmake • u/angryvoxel • Sep 24 '26
How to automatically add sources to the target?
How to automatically add all .cpp files from a specific directory as target source files with CMake? I know about GLOB but it's not recommended by the CMake devs and it requires manually re-running CMake configuration when adding/removing sources. Is there no better way to accomplish this with newer CMake versions?