Is it possible to install postgresql-9.5-postgis-2.3 (Postgres 9.5, Postgis 2.3) on Ubuntu 16.04 Server without installing x11-common?

After I installed Postgresql 9.5, I attempted to install postgresql-9.5-postgis-2.3. This stated that I needed to install a large stack of dependencies including: x11, libgl, libpulse, libqt and others.

This is pretty crazy in my opinion as a simple sudo apt-get install postgresql-9.5-postgis-2.3 results in an additional 590 MB install.

  • 1
    can you tell us why you need exactly this combination?
    – pLumo
    Jul 24 '18 at 11:27
  • I agree with RoVo I can't find anything to even substantiate this problem, and I'm looking at the packages themselves. Nov 26 '18 at 23:16

If the package developer says his/her package depends on "x11, libgl, libpulse, libqt and others", believe him/her.

How would one use postgis without X11?

  • 3
    Why should one 'just believe' a package author if a database extension tries to install a whole windowing system? There is no obvious reason why those dependencies are needed. It even tries to install mysql-common. What?!?! Installing a Postgres extension installs mysql? This at least needs some clarification.
    – Xatoo
    Jul 24 '18 at 11:21
  • use apt-get source postgresql-9.5-postgis-2.3 and you can figure out yourself.
    – waltinator
    Jul 24 '18 at 22:02

PostGIS is a PostgreSQL spatial extension that provides new geometry types and spatial functions on these types. Functionally, I can't see why it would require libqt, or other GUI libraries, except for auxiliary programs perhaps. (Are you sure these dependencies are not from other things like qgis?)

I don't have 16.04 now, but installing on a fresh 18.04 does not seem to require libqt, and the following did not report anything:

sudo apt-get install postgresql-10-postgis-2.4 -s | grep libqt

Anyways, if you need PostGIS with minimum dependency on a Ubuntu server, you can build from source. It is not very difficult to install/build GEOS and several dependent libraries and then PostGIS itself. See e.g. the instructions here.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.