Any ideas what might be sparking? 

This is a new mint 19 system.  The test below is the opam install output and a psql test.  I also tried installing a pinned version from the github repo with the same error.
  

=-=- Gathering sources =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
[postgresql] Archive in cache

=-=- Processing actions -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
[ERROR] The compilation of postgresql failed at "jbuilder build -p postgresql -j 4".

#=== ERROR while installing postgresql.4.4.0 ==================================#
# opam-version 1.2.2
# os           linux
# command      jbuilder build -p postgresql -j 4
# path         /home/caseybasichis/.opam/4.07.0/build/postgresql.4.4.0
# compiler     4.07.0
# exit-code    1
# env-file     /home/caseybasichis/.opam/4.07.0/build/postgresql.4.4.0/postgresql-16795-5f1023.env
# stdout-file  /home/caseybasichis/.opam/4.07.0/build/postgresql.4.4.0/postgresql-16795-5f1023.out
# stderr-file  /home/caseybasichis/.opam/4.07.0/build/postgresql.4.4.0/postgresql-16795-5f1023.err
### stderr ###
# -> stdout:
# [...]
#  | cmxa_magic_number: Caml1999Z023
#  | ast_impl_magic_number: Caml1999M023
#  | ast_intf_magic_number: Caml1999N023
#  | cmxs_magic_number: Caml1999D023
#  | cmt_magic_number: Caml1999T023
# -> stderr:
# Fatal error: exception End_of_file
# Raised at file "src/configurator.ml", line 511, characters 13-22
# Called from file "src/config/discover.ml", line 6, characters 2-1023



=-=- Error report -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
The following actions failed
  ∗  install postgresql 4.4.0
No changes have been performed

=-=- postgresql.4.4.0 troobleshooting -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
=> This package relies on external (system) dependencies that may be missing. `opam depext postgresql.4.4.0' may help
   you find the correct installation for your system.