pkg:setup ENV["PG_CONFIG"] = Formula["postgresql"].opt_bin/"pg_config" mkdir "stage" make DESTDIR=${PKG_DEST} install DESTDIR=#{buildpath}/stage lib.install Dir["stage/**/lib/*"] (share/"postgresql/extension").install Dir["stage/**/share/postgresql/extension/*"]