|
@ -8,7 +8,7 @@ |
|
|
include $(TOPDIR)/rules.mk |
|
|
include $(TOPDIR)/rules.mk |
|
|
|
|
|
|
|
|
PKG_NAME:=postgresql |
|
|
PKG_NAME:=postgresql |
|
|
PKG_VERSION:=9.0.17 |
|
|
|
|
|
|
|
|
PKG_VERSION:=9.4.4 |
|
|
PKG_RELEASE:=1 |
|
|
PKG_RELEASE:=1 |
|
|
PKG_MAINTAINER:=Jo-Philipp Wich <jow@openwrt.org> |
|
|
PKG_MAINTAINER:=Jo-Philipp Wich <jow@openwrt.org> |
|
|
PKG_LICENSE:=PostgreSQL |
|
|
PKG_LICENSE:=PostgreSQL |
|
@ -18,10 +18,11 @@ PKG_SOURCE_URL:=\ |
|
|
http://ftp9.us.postgresql.org/pub/mirrors/postgresql/source/v$(PKG_VERSION) \
|
|
|
http://ftp9.us.postgresql.org/pub/mirrors/postgresql/source/v$(PKG_VERSION) \
|
|
|
http://ftp.be.postgresql.org/postgresql/source/v$(PKG_VERSION) \
|
|
|
http://ftp.be.postgresql.org/postgresql/source/v$(PKG_VERSION) \
|
|
|
ftp://ftp-archives.postgresql.org/pub/source/v$(PKG_VERSION) |
|
|
ftp://ftp-archives.postgresql.org/pub/source/v$(PKG_VERSION) |
|
|
PKG_MD5SUM:=46bf3ef3761c091fb0d2e25012c1709e |
|
|
|
|
|
|
|
|
PKG_MD5SUM:=1fe952c44ed26d7e6a335cf991a9c1c6 |
|
|
PKG_BUILD_PARALLEL:=1 |
|
|
PKG_BUILD_PARALLEL:=1 |
|
|
PKG_USE_MIPS16:=0 |
|
|
PKG_USE_MIPS16:=0 |
|
|
PKG_FIXUP:=autoreconf |
|
|
PKG_FIXUP:=autoreconf |
|
|
|
|
|
PKG_MACRO_PATHS:=config |
|
|
|
|
|
|
|
|
include $(INCLUDE_DIR)/package.mk |
|
|
include $(INCLUDE_DIR)/package.mk |
|
|
|
|
|
|
|
@ -58,6 +59,7 @@ define Package/pgsql-server |
|
|
TITLE:=PostgreSQL databases Server |
|
|
TITLE:=PostgreSQL databases Server |
|
|
URL:=http://www.postgresql.org/ |
|
|
URL:=http://www.postgresql.org/ |
|
|
SUBMENU:=database |
|
|
SUBMENU:=database |
|
|
|
|
|
USERID:=postgres=5432:postgres=5432 |
|
|
endef |
|
|
endef |
|
|
|
|
|
|
|
|
define Package/pgsql-server/description |
|
|
define Package/pgsql-server/description |
|
@ -85,17 +87,15 @@ define Build/Configure |
|
|
--enable-static \
|
|
|
--enable-static \
|
|
|
--disable-integer-datetimes \
|
|
|
--disable-integer-datetimes \
|
|
|
--disable-rpath \
|
|
|
--disable-rpath \
|
|
|
--without-java \
|
|
|
|
|
|
--without-krb4 \
|
|
|
|
|
|
--without-krb5 \
|
|
|
|
|
|
|
|
|
--without-bonjour \
|
|
|
|
|
|
--without-gssapi \
|
|
|
|
|
|
--without-ldap \
|
|
|
--without-openssl \
|
|
|
--without-openssl \
|
|
|
--without-pam \
|
|
|
--without-pam \
|
|
|
--without-perl \
|
|
|
--without-perl \
|
|
|
--without-python \
|
|
|
--without-python \
|
|
|
--without-readline \
|
|
|
--without-readline \
|
|
|
--without-rendezvous \
|
|
|
|
|
|
--without-tcl \
|
|
|
--without-tcl \
|
|
|
--without-tk \
|
|
|
|
|
|
--with-zlib="yes" \
|
|
|
--with-zlib="yes" \
|
|
|
--enable-depend \
|
|
|
--enable-depend \
|
|
|
--with-system-timezone=/tmp \
|
|
|
--with-system-timezone=/tmp \
|
|
@ -141,16 +141,14 @@ define Build/Configure |
|
|
--enable-static \
|
|
|
--enable-static \
|
|
|
--disable-integer-datetimes \
|
|
|
--disable-integer-datetimes \
|
|
|
--disable-rpath \
|
|
|
--disable-rpath \
|
|
|
--without-java \
|
|
|
|
|
|
--without-krb4 \
|
|
|
|
|
|
--without-krb5 \
|
|
|
|
|
|
|
|
|
--without-bonjour \
|
|
|
|
|
|
--without-gssapi \
|
|
|
|
|
|
--without-ldap \
|
|
|
--without-openssl \
|
|
|
--without-openssl \
|
|
|
--without-pam \
|
|
|
--without-pam \
|
|
|
--without-perl \
|
|
|
--without-perl \
|
|
|
--without-python \
|
|
|
--without-python \
|
|
|
--without-rendezvous \
|
|
|
|
|
|
--without-tcl \
|
|
|
--without-tcl \
|
|
|
--without-tk \
|
|
|
|
|
|
--with-zlib="yes" \
|
|
|
--with-zlib="yes" \
|
|
|
--enable-depend \
|
|
|
--enable-depend \
|
|
|
$(if $(CONFIG_TARGET_avr32),--disable-spinlocks) \
|
|
|
$(if $(CONFIG_TARGET_avr32),--disable-spinlocks) \
|
|
@ -207,32 +205,6 @@ define Package/pgsql-server/conffiles |
|
|
/etc/config/postgresql |
|
|
/etc/config/postgresql |
|
|
endef |
|
|
endef |
|
|
|
|
|
|
|
|
define Package/pgsql-server/postinst |
|
|
|
|
|
#!/bin/sh
|
|
|
|
|
|
grep -q '^postgres:' /etc/passwd && exit 0 |
|
|
|
|
|
group=$$(grep '^postgres:' /etc/group | cut -f3 -d:) |
|
|
|
|
|
if [ -z "$${group}" ] ; then |
|
|
|
|
|
group=1000 |
|
|
|
|
|
tst=$$(cat /etc/group | grep ":$${group}:") |
|
|
|
|
|
while [ -n "$${tst}" ] ; do |
|
|
|
|
|
group=$$(($${group}+1)) |
|
|
|
|
|
tst=$$(cat /etc/group | grep ":$${group}:") |
|
|
|
|
|
done |
|
|
|
|
|
echo "postgres:x:$${group}:" >>/etc/group |
|
|
|
|
|
fi |
|
|
|
|
|
|
|
|
|
|
|
user=$$(cat /etc/passwd | grep "^postgres:") |
|
|
|
|
|
if [ -z "$${user}" ] ; then |
|
|
|
|
|
num="$${group}" |
|
|
|
|
|
tst=$$(cat /etc/passwd | grep ":.*:$${num}:") |
|
|
|
|
|
while [ -n "$${tst}" ] ; do |
|
|
|
|
|
num=$$(($${num}+1)) |
|
|
|
|
|
tst=$$(cat /etc/passwd | grep ":.*:$${num}:") |
|
|
|
|
|
done |
|
|
|
|
|
echo "postgres:*:$${num}:$${group}:PostgreSQL administrator:/tmp:/bin/ash" >>/etc/passwd |
|
|
|
|
|
fi |
|
|
|
|
|
endef |
|
|
|
|
|
|
|
|
|
|
|
define Build/InstallDev |
|
|
define Build/InstallDev |
|
|
$(INSTALL_DIR) $(1)/usr/bin |
|
|
$(INSTALL_DIR) $(1)/usr/bin |
|
|
$(INSTALL_BIN) $(PKG_BUILD_DIR)/src/bin/pg_config/pg_config.host $(1)/usr/bin/pg_config |
|
|
$(INSTALL_BIN) $(PKG_BUILD_DIR)/src/bin/pg_config/pg_config.host $(1)/usr/bin/pg_config |
|
@ -242,6 +214,7 @@ define Build/InstallDev |
|
|
$(CP) $(PKG_INSTALL_DIR)/usr/include/pg_config.h $(1)/usr/include/ |
|
|
$(CP) $(PKG_INSTALL_DIR)/usr/include/pg_config.h $(1)/usr/include/ |
|
|
$(CP) $(PKG_INSTALL_DIR)/usr/include/pg_config_manual.h $(1)/usr/include/ |
|
|
$(CP) $(PKG_INSTALL_DIR)/usr/include/pg_config_manual.h $(1)/usr/include/ |
|
|
$(CP) $(PKG_INSTALL_DIR)/usr/include/postgres_ext.h $(1)/usr/include/ |
|
|
$(CP) $(PKG_INSTALL_DIR)/usr/include/postgres_ext.h $(1)/usr/include/ |
|
|
|
|
|
$(CP) $(PKG_INSTALL_DIR)/usr/include/pg_config_ext.h $(1)/usr/include/ |
|
|
$(CP) $(PKG_INSTALL_DIR)/usr/include/postgresql $(1)/usr/include/ |
|
|
$(CP) $(PKG_INSTALL_DIR)/usr/include/postgresql $(1)/usr/include/ |
|
|
$(INSTALL_DIR) $(1)/usr/lib |
|
|
$(INSTALL_DIR) $(1)/usr/lib |
|
|
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libpq.{a,so*} $(1)/usr/lib/ |
|
|
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libpq.{a,so*} $(1)/usr/lib/ |
|
|