
Discover the enduring power of GNU Make as a portable build tool. Build, run, and manage projects from simple Makefile to a multi-file C project with targets and dependencies.
Create your first makefile to compile hello.c with gcc -o hello and run it via a run target. Make runs the first target by default and requires a tab.
Explore targets and dependencies in makefiles, including the all target that builds and runs, and learn how at signs and the dash s flag control output and dependencies on hello.c.
Explore makefile variables to control builds, override compilers like GCC, Clang, or G++, set output names and C flags, use default and target-specific values, and apply simple environment-driven customization.
Refine your Makefile skills by using variables as target names and dependencies, creating aliases, and understanding make's timestamp checks to keep outputs up to date.
Use pattern rules, wildcards, and built-in functions in makefiles to automate multi-file c builds, creating object files from all sources and linking an executable.
Use the .phony directive to declare targets that are not files, preventing make from treating them as up to date when a file with the same name exists.
Define variables and use ifdef, ifndef, and conditional tests to tailor builds in makefiles. Detect the system with uname -s and switch between debug and production flags for cross-platform builds.
Concludes with a solid makefile and minimal duplication, showing make, GCC, and Clang workflows; explains this suits hobby projects and many jobs, while embedded or cross-system needs may differ.
Stop typing long compile, test, lint, and deploy commands over and over. Let GNU Make do the thinking for you.
In this fast crash course, you’ll learn how to use GNU Make and Makefiles as a lightweight, powerful task runner and build automation tool. Great for developers, Linux users, and sysadmins.
Whether you're tired of repeating gcc flags, manually running linters, rebuilding Docker images, or scripting repetitive workflows in Bash, Make gives you dependency tracking, conditional execution, and one-command simplicity without learning a heavy new build system.
You’ll build a clean, professional Makefile from scratch starting with a simple "hello world" Makefile, then scaling to:
Multi-file projects with automatic compilation
Variables, overrides, and automatic variables ($@, $<, $^)
Pattern rules & wildcards for dozens of files
Phony targets (.PHONY) for reliable clean/test/lint
Conditionals for debug/release modes and cross-OS compatibility
Debugging tips, best practices, and common pitfalls
Real integrations: Git hooks, Docker builds, test/lint runners
Everything is demonstrated live in the terminal
By the end you’ll have:
The confidence to automate builds
Time saved every single day in the terminal
No prior Make experience required, just basic terminal comfort.
Meet Your Instructor
Hi, I’m Martijn, terminal enthusiast and creator of several Udemy courses on Linux productivity tools.
I live in the terminal every day. Building, scripting, deploying, and automating workflow on Linux. My teaching style is hands-on and demo-driven: you watch real workflows, follow along, and leave each lecture with something you can use immediately.
I keep courses short, focused, and fluff-free. Because your time is valuable and terminal mastery should be fast.
If you want practical skills that make you faster in the shell every day, you’re in the right place.
Let’s automate the boring stuff with Make!