# 使用 Homebrew, dnf, Nix, apt 安装 cctz

查看 cctz 的安装路径、可执行文件、元数据以及面向 AI 代理工作流的安全说明。

## 安装

```sh
sudo av install brew:cctz
```

其他安装命令:

### macOS

- Homebrew (100%):

```sh
brew install cctz
```

  证据: local Homebrew formula metadata

### Linux

- dnf (92%):

```sh
sudo dnf install cctz
```

  证据: Fedora Rawhide package metadata: cctz from https://dl.fedoraproject.org/pub/fedora/linux/development/rawhide/Everything/x86_64/os/repodata/07190dc5ae9f35ae73866675fed6d95fe6e8d9fe22c9d7cdf85862cb2ed24a4c-primary.xml.zst

- Nix (92%):

```sh
nix profile install nixpkgs#cctz
```

  证据: nixpkgs package indexes: pkgs/by-name/cc/cctz/package.nix from https://api.github.com/repos/NixOS/nixpkgs/git/trees/master?recursive=1

- Debian apt (92%):

```sh
sudo apt install libcctz-dev
```

  证据: Debian stable package indexes: libcctz-dev from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz

## 软件包事实

- **软件包键:** brew:cctz
- **软件包管理器:** Homebrew
- **版本:** 2.5
- **来源摘要:** C++ library for translating between absolute and civil times
- **主页:** <https://github.com/google/cctz>
- **仓库:** <https://github.com/google/cctz>
- **已生成:** 2026-08-03T19:37:03+00:00

## 可执行文件

- time_tool (别名)

## 安装行为

- Bottle: 不可用

## 版本和新鲜度

- 页面生成时间: 2026-08-03
- 管理器版本: 2.5
## 项目历史与用法

CCTZ is Google's C++ date, civil-time, and time-zone library for converting between absolute time and human civil time using IANA time-zone data. It is packaged both as a library and, in Homebrew, with the time_tool example executable.

### 项目历史

The official repository was created in 2015. The README says CCTZ contains a Civil-Time Library and a Time-Zone Library that cooperate with C++ <chrono>, giving programmers tools for date, time, and time-zone work.

CCTZ had a v1.0 release in March 2016 and a v2.0 release in April 2016, followed by v2.1 in 2017, v2.2 in 2018, v2.3 in 2019, v2.4 in 2024, and v2.5 in 2025.

### 采用历史

The README documents Bazel as the preferred build system while also supporting Make and CMake. The input package facts list Homebrew, Debian/Ubuntu libcctz-dev, Fedora/DNF, and Nix packages, showing adoption as a reusable C++ library rather than only as an application.

### 使用方式

CCTZ is used by C++ programs that need correct civil-date arithmetic and conversion between time zones and absolute time points. The README points users to cctz/civil_time.h, cctz/time_zone.h, examples, Bazel, CMake, and system-installed IANA zoneinfo data.

### 为什么软件包爱好者会关心

CCTZ is package-nerd significant because time-zone handling is notoriously edge-case heavy, and this library packages a focused C++ solution around IANA data before broad standard-library time-zone support was common in deployed toolchains.

### 时间线

- 2015: Official GitHub repository created.
- 2016: v1.0 and v2.0 releases published.
- 2019: v2.3 release published.
- 2024: v2.4 release published.
- 2025: v2.5 release published.

### Related projects

- The README references C++ <chrono>, the IANA time-zone database, Bazel, GoogleTest, and CMake.
- The README also links older ISO C++ proposals for standardizing civil-time and time-zone libraries.

### 来源

- <https://api.github.com/repos/google/cctz>
- <https://github.com/google/cctz>
- <https://github.com/google/cctz#readme>
- <https://formulae.brew.sh/api/formula/cctz.json>


## 安全说明

library-like package without higher-risk signals.

- **Geiger 风险:** 绿色 / 低
- library-like package without higher-risk signals

## 其他软件包管理器记录

- Debian apt - libcctz-dev - 2.4+dfsg1-2: normalized package name match | Debian stable package indexes: libcctz-dev from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | Library for computing dates, times and time zones, development files | https://github.com/google/cctz
- Debian apt - libcctz-doc - 2.4+dfsg1-2: normalized package name match | Debian stable package indexes: libcctz-doc from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | Library for computing dates, times and time zones, documentation | https://github.com/google/cctz
- Debian apt - libcctz2.4 - 2.4+dfsg1-2: normalized package name match | Debian stable package indexes: libcctz2.4 from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | Library for computing dates, times and time zones, shared library | https://github.com/google/cctz
- Nix - cctz: normalized package name match | nixpkgs package indexes: pkgs/by-name/cc/cctz/package.nix from https://api.github.com/repos/NixOS/nixpkgs/git/trees/master?recursive=1
- Ubuntu apt - libcctz-dev - 2.3+dfsg1-5build1: normalized package name match | Ubuntu 24.04 LTS package indexes: libcctz-dev from https://archive.ubuntu.com/ubuntu/dists/noble/universe/binary-amd64/Packages.gz | Library for computing dates, times and time zones, development files | https://github.com/google/cctz
- Ubuntu apt - libcctz-doc - 2.3+dfsg1-5build1: normalized package name match | Ubuntu 24.04 LTS package indexes: libcctz-doc from https://archive.ubuntu.com/ubuntu/dists/noble/universe/binary-amd64/Packages.gz | Library for computing dates, times and time zones, documentation | https://github.com/google/cctz
- Ubuntu apt - libcctz2 - 2.3+dfsg1-5build1: normalized package name match | Ubuntu 24.04 LTS package indexes: libcctz2 from https://archive.ubuntu.com/ubuntu/dists/noble/universe/binary-amd64/Packages.gz | Library for computing dates, times and time zones, shared library | https://github.com/google/cctz
- dnf - cctz - 2.5-4.fc45: normalized package name match | Fedora Rawhide package metadata: cctz from https://dl.fedoraproject.org/pub/fedora/linux/development/rawhide/Everything/x86_64/os/repodata/07190dc5ae9f35ae73866675fed6d95fe6e8d9fe22c9d7cdf85862cb2ed24a4c-primary.xml.zst | Translating between absolute and civil times using time zone rules | https://github.com/google/cctz
- dnf - cctz-devel - 2.5-4.fc45: normalized package name match | Fedora Rawhide package metadata: cctz-devel from https://dl.fedoraproject.org/pub/fedora/linux/development/rawhide/Everything/x86_64/os/repodata/07190dc5ae9f35ae73866675fed6d95fe6e8d9fe22c9d7cdf85862cb2ed24a4c-primary.xml.zst | Translating between absolute and civil times using time zone rules | https://github.com/google/cctz


## Combined YAML source

View the package source record on GitHub. [combined/cctz.yml](https://github.com/mxcl/pkgdb/blob/main/combined/cctz.yml)


## 来源

- pkg.so package database
- Geiger risk classifier
- curated package history
- pkgdb category and tag curation
- external package-manager database matches
- cross-ecosystem install command graph
