Skip to Content
21st Century C, 2nd Edition
book

21st Century C, 2nd Edition

by Ben Klemens
May 2025
Intermediate to advanced
408 pages
5h 55m
Japanese
O'Reilly Media, Inc.
Content preview from 21st Century C, 2nd Edition

第一部 環境

スクリプト言語の塀に囲まれた庭の外の荒野には、C言語の大きな問題点を解決するツールが豊富にあるが、それを探すのは大変だ。しかし、探さなければならない。これらのツールの多くは、苦痛なく書くために絶対に必要なものだ。もしデバッガー(スタンドアロンでもIDE内でも)を使っていないなら、あなたは自分自身に恣意的な苦難を課していることになる。

また、あなたのコードで使われるのを待っている既存のライブラリが豊富にあるので、リンクリストやパーサーなどの基本を再実装して時間を浪費する代わりに、目の前の問題に取り組むことができる。外部ライブラリを使ってプログラミングをコンパイルするのは、できるだけ簡単でなければならない。

以下は第一部の概要である:

第1章では、パッケージ・マネージャーの入手や必要なツールのインストールなど、基本的な環境のセットアップについて説明する。これはすべて、他の場所からライブラリを使用してプログラミングをコンパイルするという、興味深い部分のための背景である。このプロセスはかなり標準化されており、環境変数とレシピの小さなセットを含む。

第2章では、デバッグ、文書化、テストのためのツールを紹介する。なぜなら、デバッグ、文書化、テストをしない限り、コードに意味はないからだ。

第3章はAutotoolsを取り上げる。Autotoolsは、分散用にコードをパッケージ化するシステムである。しかし、この章は遠回りなので、シェルスクリプトやmakefileの書き方についても触れている。

他人ほど人生を複雑にするものはない。そこで第4章では、Gitについて説明する。Gitは、あなたやあなたの共同作業者のハードドライブにある、微妙に異なるバージョンのプロジェクトを追跡し、それらのバージョンをマージするプロセスを可能な限りシンプルにするためのシステムである。

多くの言語がCのインタフェースを宣伝しているため、他の言語は現代のC環境の重要な一部となっている。第5章では、インタフェースの書き方について一般化された注意点を述べ、Pythonを使った拡張例を示す。

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.

Read now

Unlock full access

More than 5,000 organizations count on O’Reilly

AirBnbBlueOriginElectronic ArtsHomeDepotNasdaqRakutenTata Consultancy Services

QuotationMarkO’Reilly covers everything we've got, with content to help us build a world-class technology community, upgrade the capabilities and competencies of our teams, and improve overall team performance as well as their engagement.
Julian F.
Head of Cybersecurity
QuotationMarkI wanted to learn C and C++, but it didn't click for me until I picked up an O'Reilly book. When I went on the O’Reilly platform, I was astonished to find all the books there, plus live events and sandboxes so you could play around with the technology.
Addison B.
Field Engineer
QuotationMarkI’ve been on the O’Reilly platform for more than eight years. I use a couple of learning platforms, but I'm on O'Reilly more than anybody else. When you're there, you start learning. I'm never disappointed.
Amir M.
Data Platform Tech Lead
QuotationMarkI'm always learning. So when I got on to O'Reilly, I was like a kid in a candy store. There are playlists. There are answers. There's on-demand training. It's worth its weight in gold, in terms of what it allows me to do.
Mark W.
Embedded Software Engineer

You might also like

Learn C Programming - Second Edition

Learn C Programming - Second Edition

Jeff Szuhay
Tiny C Projects

Tiny C Projects

Daniel Gookin

Publisher Resources

ISBN: 9798341650848