# 使用 Homebrew, apt 安装 osmcoastline

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

## 安装

```sh
sudo av install brew:osmcoastline
```

其他安装命令:

### macOS

- Homebrew (100%):

```sh
brew install osmcoastline
```

  证据: local Homebrew formula metadata

### Linux

- Debian apt (92%):

```sh
sudo apt install osmcoastline
```

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

## 软件包事实

- **软件包键:** brew:osmcoastline
- **软件包管理器:** Homebrew
- **版本:** 2.5.0
- **来源摘要:** Extracts coastline data from OpenStreetMap planet file
- **主页:** <https://osmcode.org/osmcoastline/>
- **仓库:** <https://github.com/osmcode/osmcoastline>
- **最后更新:** 2026-06-25T13:38:00+02:00
- **已生成:** 2026-08-03T19:37:03+00:00

## 可执行文件

- osmcoastline (别名)
- osmcoastline_filter (别名)
- osmcoastline_readmeta (别名)
- osmcoastline_segments (别名)
- osmcoastline_ways (别名)

## 安装行为

- Bottle: 不可用

## 版本和新鲜度

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

osmcoastline extracts OpenStreetMap coastline ways from planet-scale input and assembles them into land and water polygons for renderers and data users. It handles one of OSM's oddest global data problems: editable coastline segments must become valid, usable polygons.

### 项目历史

Jochen Topf announced the work on March 7, 2012, while explaining the long-standing problem of turning `natural=coastline` ways into proper polygons. The same day, the osmcode/osmcoastline GitHub repository was created.

The blog post frames osmcoastline as a rewrite of an older coastcheck-based workflow that had become slow and difficult to maintain. The new implementation used Osmium to scan OSM files, assemble coastline rings, produce error information, and leave room for output options such as land polygons, water polygons, clipping, and splitting.

### 采用历史

OpenStreetMapData's coastline-processing page says OSMCoastline was developed specifically to assemble coastline data, apply fixes where needed, and create the published coastline datasets on that site. It also feeds detected coastline errors onward to Geofabrik's OSM Inspector so mappers can correct source data.

### 使用方式

The man page describes `osmcoastline` as reading an input file, usually a planet file or filtered output, and writing coastline polygons to a Spatialite database. Options control overlap, gap-closing distance, warning behavior, output formats, and projection-specific details.

The repository also ships helper commands such as `osmcoastline_filter`; the README says the filter can reduce a planet file to the nodes and ways needed for coastline assembly, producing a file less than one percent of the original planet size.

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

osmcoastline is a compact example of domain-specific packaging: it depends on OSM parsing, geometry libraries, Spatialite, GDAL, GEOS, zlib, and optional PBF compression details, but exposes a focused CLI for one global map-production job.

### 时间线

- 2012-03-07: Jochen Topf publishes the OSM Coastlines blog post and releases the osmcoastline code.
- The project grows around libosmium, protozero, GDAL, GEOS, SQLite/Spatialite, and PBF support.
- OpenStreetMapData uses OSMCoastline for published coastline processing and error reporting.

### Related projects

- libosmium provides OSM file handling; OpenStreetMapData publishes derived coastline datasets; Geofabrik OSM Inspector surfaces coastline errors; renderers consume the assembled land and water polygons.

### 来源

- <https://api.github.com/repos/osmcode/osmcoastline>
- <https://blog.jochentopf.com/2012-03-07-osm-coastlines.html>
- <https://docs.osmcode.org/osmcoastline/master/osmcoastline.html>
- <https://formulae.brew.sh/formula/osmcoastline>
- <https://github.com/osmcode/osmcoastline>
- <https://osmcode.org/osmcoastline/>
- <https://osmdata.openstreetmap.de/processing/coastline.html>


## 安全说明

没有找到 osmcoastline 的匹配本地密钥处理 manifest。Nucleus 软件包元数据仍在此发布，以便未来覆盖拥有稳定的软件包 URL。


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

- Debian apt - osmcoastline - 2.4.1-1: normalized package name match | Debian stable package indexes: osmcoastline from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | Extract coastline data from OpenStreetMap planet file | https://osmcode.org/osmcoastline/
- Ubuntu apt - osmcoastline - 2.4.0-2build4: normalized package name match | Ubuntu 24.04 LTS package indexes: osmcoastline from https://archive.ubuntu.com/ubuntu/dists/noble/universe/binary-amd64/Packages.gz | Extract coastline data from OpenStreetMap planet file | https://osmcode.org/osmcoastline/


## Combined YAML source

View the package source record on GitHub. [combined/osmcoastline.yml](https://github.com/mxcl/pkgdb/blob/main/combined/osmcoastline.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
