pkgname: postgresql pkgver: '18.6' pkgrel: '1' pkgdesc: Advanced object-relational database management system (ORDBMS). url: 'https://www.postgresql.org/docs' arch: x86_64 license: - PostgreSQL depends: - shadow makedepends: - systemd - readline - flex - bison - perl - python - libxml2 - libxslt - openldap - pam - kerberos - icu - docbook-xml - docbook-xsl source: - 'https://repo.paganlinux.eu/sources/pagan-scripts-20260822.tar.gz' - 'https://ftp.postgresql.org/pub/source/v${pkgver}/${pkgname}-${pkgver}.tar.bz2' sha256sums: - 32e0aec88cc56a8afe0b2671debe47d19357792a6ffaffaf6e3db8a021a57072 - SKIP hooks: post-install: "name=postgresql\nversion=18.6\nrelease=1\nINFO=\"\\033[1;36m\"\nNORMAL=\"\\033[0;39m\"\nif [ ! -d srv/pgsql/data\ \ ]; then\n\tinstall -v -dm700 srv/pgsql/data\n\tchown -R postgres:postgres srv/pgsql\n\tprintf \"${INFO} srv/pgsql/data\ \ created ${NORMAL}\\n\"\n\tsu - postgres -c '/usr/bin/initdb -D srv/pgsql/data'\nfi\nif [ ! -d run/postgresql ]; then\n\ \tinstall -v -dm755 run/postgresql\n\tchown -R postgres:postgres run/postgresql\n\tprintf \"${INFO} run/postgresql created\ \ ${NORMAL}\\n\"\nfi\n" pre-install: "name=postgresql\nversion=18.6\nrelease=1\nINFO=\"\\033[1;36m\"\nNORMAL=\"\\033[0;39m\"\nif ! (getent group\ \ postgres > /dev/null); then\n\tprintf \"${INFO}Creating postgres group${NORMAL}\\n\"\n\tgroupadd -g 41 postgres\nfi\n\ if ! (getent passwd postgres > /dev/null); then\n\tprintf \"${INFO}Creating postgres user${NORMAL}\\n\"\n\tuseradd -c\ \ 'PostgreSQL Server' -d /srv/pgsql/data \\\n\t-g postgres -u 41 postgres\nfi\n" build: | groupadd -g 41 postgres useradd -c "PostgreSQL Server" -g postgres -d /srv/pgsql/data \ -u 41 postgres cd ${pkgname}-${pkgver} # prepare sed -i '/DEFAULT_PGSOCKET_DIR/s@/tmp@/run/postgresql@' \ src/include/pg_config_manual.h # configure ./configure --prefix=/usr \ --docdir=/usr/share/doc/${pkgname} \ --enable-thread-safety \ --with-system-tzdata=/usr/share/zoneinfo \ --with-systemd \ --with-pam # build make # install make DESTDIR=${PKGDIR} install #make DESTDIR=${PKGDIR} install-docs # service cd ${SRCDIR}/pagan-scripts-20260822 make DESTDIR=${PKGDIR} install-sysd-postgresql package: | true