# 使用 Homebrew, apk, apt, dnf, MacPorts, pacman, zypper 安装 postgis

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

## 安装

```sh
sudo av install brew:postgis
```

其他安装命令:

### macOS

- Homebrew (100%):

```sh
brew install postgis
```

  证据: local Homebrew formula metadata

- MacPorts (94%):

```sh
sudo port install postgis
```

  证据: MacPorts ports tree: databases/postgis/Portfile from https://api.github.com/repos/macports/macports-ports/git/trees/master?recursive=1

### Linux

- apk (92%):

```sh
sudo apk add postgis
```

  证据: Alpine Linux edge package indexes: postgis from https://dl-cdn.alpinelinux.org/alpine/edge/community/x86_64/APKINDEX.tar.gz

- Debian apt (92%):

```sh
sudo apt install postgis
```

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

- dnf (92%):

```sh
sudo dnf install postgis
```

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

- pacman (92%):

```sh
sudo pacman -S postgis
```

  证据: Arch Linux sync databases: postgis from https://geo.mirror.pkgbuild.com/extra/os/x86_64/extra.db.tar.gz

- zypper (92%):

```sh
sudo zypper install postgresql14-postgis
```

  证据: openSUSE Tumbleweed package metadata: postgresql14-postgis from https://download.opensuse.org/tumbleweed/repo/oss/repodata/50b07339cb64c8ed4091bdbabddadc1ff5737b090e478818a195b40d8a3292861a879139b4a3987c31109699fde9fbf4a716367ddf4eef77da75f96e3193d6ed-primary.xml.zst

## 软件包事实

- **软件包键:** brew:postgis
- **软件包管理器:** Homebrew
- **软件包管理器页面:** <https://formulae.brew.sh/formula/postgis>
- **版本:** 3.6.4
- **来源摘要:** Adds support for geographic objects to PostgreSQL
- **主页:** <https://postgis.net/>
- **上游文档:** <https://postgis.net/>
- **许可证:** GPL-2.0-or-later
- **源码归档:** <https://download.osgeo.org/postgis/source/postgis-3.6.4.tar.gz>
- **最后更新:** 2026-08-02T12:51:37+01:00
- **已生成:** 2026-08-04T22:13:35+00:00

## 可执行文件

- create_upgrade.pl (cli)
- pgsql2shp (cli)
- pgtopo_export (cli)
- pgtopo_import (cli)
- postgis (cli)
- postgis_restore (cli)
- profile_intersects.pl (cli)
- raster2pgsql (cli)
- shp2pgsql (cli)
- test_estimation.pl (cli)
- test_geography_estimation.pl (cli)
- test_geography_joinestimation.pl (cli)
- test_joinestimation.pl (cli)
- create_upgrade.pl (别名)
- pgsql2shp (别名)
- pgtopo_export (别名)
- pgtopo_import (别名)
- postgis (别名)
- postgis_restore (别名)
- profile_intersects.pl (别名)
- raster2pgsql (别名)
- shp2pgsql (别名)
- test_estimation.pl (别名)
- test_geography_estimation.pl (别名)
- test_geography_joinestimation.pl (别名)
- test_joinestimation.pl (别名)

## 依赖

- gdal
- geos
- gettext
- icu4c@78
- json-c
- libpq
- libxml2
- pcre2
- proj
- protobuf-c
- sfcgal

## 构建依赖

- pkgconf
- postgresql@17
- postgresql@18

## macOS 提供的库

- perl

## 安装行为

- post-install 钩子: 未定义
- Bottle: 可用 于 arm64_linux, arm64_sequoia, arm64_sonoma, arm64_tahoe, sonoma, x86_64_linux

## 版本和新鲜度

- 页面生成时间: 2026-08-04
- 管理器版本: 3.6.4
- 管理器更新时间: 2026-08-02
- 本地数据: OK
- 上游仓库: https://postgis.net/
- 信息: Release/tag comparison is only available for GitHub repositories.

## 安全说明

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


## 源数据库详情

- **Source Database:** Homebrew formula API
- **Tap:** homebrew/core
- **Full Name:** postgis
- **Version Scheme:** 0
- **Revision:** 0
- **Head Version:** HEAD
- **Bottle Stable Root URL:** <https://ghcr.io/v2/homebrew/core>
- **Deprecated:** no
- **Disabled:** no
- **Keg Only:** no
- **URL Keys:** head, stable

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

- Debian apt - postgis - 3.5.2+dfsg-1: normalized package name match | Debian stable package indexes: postgis from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | Geographic objects support for PostgreSQL | https://postgis.net/
- Debian apt - postgis-doc - 3.5.2+dfsg-1: normalized package name match | Debian stable package indexes: postgis-doc from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | Geographic objects support for PostgreSQL -- documentation | https://postgis.net/
- Debian apt - postgresql-17-postgis-3 - 3.5.2+dfsg-1: normalized package name match | Debian stable package indexes: postgresql-17-postgis-3 from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | Geographic objects support for PostgreSQL 17 | https://postgis.net/
- Debian apt - postgresql-17-postgis-3-scripts - 3.5.2+dfsg-1: normalized package name match | Debian stable package indexes: postgresql-17-postgis-3-scripts from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | Geographic objects support for PostgreSQL 17 -- SQL scripts | https://postgis.net/
- Debian apt - postgresql-postgis - 3.5.2+dfsg-1: normalized package name match | Debian stable package indexes: postgresql-postgis from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | Geographic objects support for PostgreSQL -- Metapackage | https://postgis.net/
- Debian apt - postgresql-postgis-scripts - 3.5.2+dfsg-1: normalized package name match | Debian stable package indexes: postgresql-postgis-scripts from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | Geographic objects support for PostgreSQL -- SQL scripts metapackage | https://postgis.net/
- Ubuntu apt - postgis - 3.4.2+dfsg-1ubuntu3: normalized package name match | Ubuntu 24.04 LTS package indexes: postgis from https://archive.ubuntu.com/ubuntu/dists/noble/universe/binary-amd64/Packages.gz | Geographic objects support for PostgreSQL | https://postgis.net/
- Ubuntu apt - postgis-doc - 3.4.2+dfsg-1ubuntu3: normalized package name match | Ubuntu 24.04 LTS package indexes: postgis-doc from https://archive.ubuntu.com/ubuntu/dists/noble/universe/binary-amd64/Packages.gz | Geographic objects support for PostgreSQL -- documentation | https://postgis.net/
- Ubuntu apt - postgresql-16-postgis-3 - 3.4.2+dfsg-1ubuntu3: normalized package name match | Ubuntu 24.04 LTS package indexes: postgresql-16-postgis-3 from https://archive.ubuntu.com/ubuntu/dists/noble/universe/binary-amd64/Packages.gz | Geographic objects support for PostgreSQL 16 | https://postgis.net/
- Ubuntu apt - postgresql-16-postgis-3-scripts - 3.4.2+dfsg-1ubuntu3: normalized package name match | Ubuntu 24.04 LTS package indexes: postgresql-16-postgis-3-scripts from https://archive.ubuntu.com/ubuntu/dists/noble/universe/binary-amd64/Packages.gz | Geographic objects support for PostgreSQL 16 -- SQL scripts | https://postgis.net/
- Ubuntu apt - postgresql-postgis - 3.4.2+dfsg-1ubuntu3: normalized package name match | Ubuntu 24.04 LTS package indexes: postgresql-postgis from https://archive.ubuntu.com/ubuntu/dists/noble/universe/binary-amd64/Packages.gz | Geographic objects support for PostgreSQL -- Metapackage | https://postgis.net/
- Ubuntu apt - postgresql-postgis-scripts - 3.4.2+dfsg-1ubuntu3: normalized package name match | Ubuntu 24.04 LTS package indexes: postgresql-postgis-scripts from https://archive.ubuntu.com/ubuntu/dists/noble/universe/binary-amd64/Packages.gz | Geographic objects support for PostgreSQL -- SQL scripts metapackage | https://postgis.net/
- apk - postgis - 3.6.3-r0: normalized package name match | Alpine Linux edge package indexes: postgis from https://dl-cdn.alpinelinux.org/alpine/edge/community/x86_64/APKINDEX.tar.gz | spatial database extender for PostgreSQL object-relational database | https://postgis.net/
- apk - postgis-doc - 3.6.3-r0: normalized package name match | Alpine Linux edge package indexes: postgis-doc from https://dl-cdn.alpinelinux.org/alpine/edge/community/x86_64/APKINDEX.tar.gz | spatial database extender for PostgreSQL object-relational database (documentation) | https://postgis.net/
- dnf - postgis - 3.6.4-3.fc45: normalized package name match | Fedora Rawhide package metadata: postgis from https://dl.fedoraproject.org/pub/fedora/linux/development/rawhide/Everything/x86_64/os/repodata/210a2053c8e007daf9ae39c2a21daaed9b2ddd07d63ecffa597050361e73650c-primary.xml.zst | Open-source vector similarity search for Postgres | https://www.postgis.net
- pacman - postgis - 3.6.4-1: normalized package name match | Arch Linux sync databases: postgis from https://geo.mirror.pkgbuild.com/extra/os/x86_64/extra.db.tar.gz | A spatial database extender for PostgreSQL | https://postgis.net/


## 相关链接

- [Terminal utility packages](https://pkg.so/zh-hans/terminal-utilities/) - Matched terminal and command-line workflow metadata.
- [Text processing packages](https://pkg.so/zh-hans/text-processing-tools/) - Matched text, document, or structured-data processing metadata.
- [Networking and protocol packages](https://pkg.so/zh-hans/networking-protocol-tools/) - Matched network, protocol, or remote-service metadata.
- [Database and data packages](https://pkg.so/zh-hans/database-data-tools/) - Matched database, SQL, migration, or data-store metadata.
- [pcre2](https://pkg.so/zh-hans/brew/pcre2/) - Runtime dependency declared by Homebrew.
- [gettext](https://pkg.so/zh-hans/brew/gettext/) - Runtime dependency declared by Homebrew.
- [libxml2](https://pkg.so/zh-hans/brew/libxml2/) - Runtime dependency declared by Homebrew.
- [libpq](https://pkg.so/zh-hans/brew/libpq/) - Runtime dependency declared by Homebrew.
- [gdal](https://pkg.so/zh-hans/brew/gdal/) - Runtime dependency declared by Homebrew.
- [proj](https://pkg.so/zh-hans/brew/proj/) - Runtime dependency declared by Homebrew.
- [pkgconf](https://pkg.so/zh-hans/brew/pkgconf/) - Build dependency declared by Homebrew.
- [postgresql@17](https://pkg.so/zh-hans/brew/postgresql-17/) - Build dependency declared by Homebrew.
- [postgresql@18](https://pkg.so/zh-hans/brew/postgresql-18/) - Build dependency declared by Homebrew.
- [osm2pgrouting](https://pkg.so/zh-hans/brew/osm2pgrouting/) - Popular package that depends on this formula.
- [postgresql@14](https://pkg.so/zh-hans/brew/postgresql-14/) - Shares pkgdb curated category or tags: cli, data, database, postgresql.
- [postgresql@16](https://pkg.so/zh-hans/brew/postgresql-16/) - Shares pkgdb curated category or tags: cli, data, database, postgresql.
- [postgresql@15](https://pkg.so/zh-hans/brew/postgresql-15/) - Shares pkgdb curated category or tags: cli, data, database, postgresql.
- [libgeotiff](https://pkg.so/zh-hans/brew/libgeotiff/) - Shares pkgdb curated category or tags: cli, data, geospatial, gis.
- [lazysql](https://pkg.so/zh-hans/brew/lazysql/) - Shares pkgdb curated category or tags: cli, data, database, postgresql.
- [mapnik](https://pkg.so/zh-hans/brew/mapnik/) - Shares pkgdb curated category or tags: cli, data, geospatial, gis.
- [mapserver](https://pkg.so/zh-hans/brew/mapserver/) - Local package facts share a topical domain. Shared terms: cli, data, gdal, geos, geospatial.

## Combined YAML source

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


## 来源

- pkg.so package database
- Geiger risk classifier
- package-page enrichment
- package version freshness
- pkgdb category and tag curation
- package relationship graph
- external package-manager database matches
- cross-ecosystem install command graph
