About the Book
Build efficient systems software with the Zig programming language by creating UNIX tools, network services, asynchronous applications, and high-performance servers.
Key Features
Build real-world systems software and UNIX programming tools through practical Zig projects
Develop network programming skills through TCP, UDP, HTTP services, concurrent applications, and CLI tools
Master memory management, I/O, and systems-level design with the Zig programming language
Book DescriptionBuild reliable systems software with Zig through a project-driven approach focused on practical engineering challenges. Guided by UNIX systems engineer & bestselling author Mihalis Tsoukalos, you will learn modern systems programming techniques while creating production-ready applications, UNIX tools, & network services.
This book takes you from essential UNIX tooling and build infrastructure to advanced topics such as direct memory access, binary formats, filesystem monitoring, networking, concurrency, asynchronous I/O, & database integration. Through hands-on projects, you will create command-line utilities, TCP and UDP services, HTTP applications, file indexing tools, cache servers, & a domain-specific language interpreter that combines memory management, comptime metaprogramming, parsing, evaluation, & error handling.
Each chapter demonstrates how Zig features solve practical systems programming problems. You will work with memory management, process control, synchronization primitives, event-driven architectures, SQLite integration, protocol design, & performance-focused data structures while learning the reasoning behind key engineering decisions.
By the end of this book, you will be able to build efficient and maintainable systems software in Zig & confidently apply the language to production projects.What you will learn
Build production-ready UNIX command-line tools with Zig
Develop TCP, UDP, and HTTP network services and applications
Apply systems programming techniques to memory, filesystems, and process management
Manage memory and binary data safely and efficiently
Implement multithreading, synchronization, and concurrent systems
Create asynchronous I/O and event-driven network applications
Integrate SQLite into real-world Zig applications
Design and build a domain-specific language using parsing and comptime techniques
Who this book is forSoftware developers, systems programmers, UNIX systems engineers, and backend engineers who already understand Zig fundamentals and want to build production-ready systems software. Familiarity with programming concepts and experience using languages such as C, C++, Rust, Go, or Python will help you get the most from this book.
Table of Contents:
Table of Contents- Building Essential UNIX Tools
- Systems Infrastructure: Builds, Testing, and Distribution
- Direct Memory Access and Binary Formats
- Processing Streams, Buffers, and Data Encoding
- Navigating Directories and Filesystem Events
- Programming the Network Stack
- Managing Threads, Processes, and Signals
- Orchestrating Concurrency and Synchronization
- Implementing Asynchronous I/O
- Building a High-Performance In-Memory Cache Server
- Persisting Structured Data with SQLite3
- Developing a Domain-Specific Language
About the Author :
Mihalis Tsoukalos holds a BSc in Mathematics from the University of Patras and an MSc in IT from University College London (UCL). His previous books, Go Systems Programming and Mastering Go, have become must-reads for UNIX and Linux systems professionals. He works as a UNIX systems engineer and a technical author. He enjoys writing technical articles and has written for Sys Admin, MacTech, C/C++ Users Journal, USENIX ;login:, Linux Journal, Linux User and Developer, Linux Format and Linux Voice. His research interests include time series data mining, time series indexing and databases.