aboutsummaryrefslogtreecommitdiffstats
path: root/meta-oe/recipes-support/postgresql
diff options
context:
space:
mode:
authorChong.Lu@windriver.com <Chong.Lu@windriver.com>2014-04-22 15:07:26 +0800
committerMartin Jansa <Martin.Jansa@gmail.com>2014-05-03 20:45:02 +0200
commit8f4fa26870da97c7aaa8460890a4c7f45d1b687c (patch)
treea29b67cd7e821f51607676eab2983d2551020057 /meta-oe/recipes-support/postgresql
parentee8a6c23712aa5f267b881e62f1cda3812f56bde (diff)
downloadmeta-openembedded-contrib-8f4fa26870da97c7aaa8460890a4c7f45d1b687c.tar.gz
postgresql: split out some lib files into seperate packages
1. Split out libecpg-compat-dev, libecpg-staticdev, libecpg-doc, libpq-staticdev, libpgtypes-staticdev and libpgtypes-dev into seperate packages. 2. Multilib builds set the package name (PN) to both foo and lib32-foo breaking build.use BPN instead to get the Base package name. Signed-off-by: Chong Lu <Chong.Lu@windriver.com> Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
Diffstat (limited to 'meta-oe/recipes-support/postgresql')
-rw-r--r--meta-oe/recipes-support/postgresql/postgresql.inc92
1 files changed, 67 insertions, 25 deletions
diff --git a/meta-oe/recipes-support/postgresql/postgresql.inc b/meta-oe/recipes-support/postgresql/postgresql.inc
index db425e765a..2c5bbf739f 100644
--- a/meta-oe/recipes-support/postgresql/postgresql.inc
+++ b/meta-oe/recipes-support/postgresql/postgresql.inc
@@ -63,28 +63,48 @@ INITSCRIPT_NAME = "${BPN}-server"
INITSCRIPT_PARAMS = "start 64 . stop 36 0 1 2 3 4 5 6 ."
do_install_append() {
- # install dirs and server init
- install -d ${D}${sysconfdir}/init.d
- install -m 0755 ${WORKDIR}/${BPN}.init \
- ${D}${sysconfdir}/init.d/${BPN}-server
- sed -i -e "s/^PGVERSION=.*$/PGVERSION=${PV}/g" \
- ${D}${sysconfdir}/init.d/${BPN}-server
- install -d -m 700 ${D}${localstatedir}/lib/${BPN}/data
- install -d -m 700 ${D}${localstatedir}/lib/${BPN}/backups
- install -m 644 ${WORKDIR}/${BPN}-bashprofile \
- ${D}${localstatedir}/lib/${BPN}/.bash_profile
- chown -R postgres:postgres ${D}${localstatedir}/lib/${BPN}
- # multiple server config directory
- install -d -m 700 ${D}${sysconfdir}/default/${BPN}
+ # install COPYRIGHT README HISTORY
+ install -d -m 0755 ${D}${docdir}/${BPN}
+ for i in ${S}/{COPYRIGHT,README,HISTORY} ${S}/doc/{KNOWN_BUGS,MISSING_FEATURES,README*,bug.template}; do
+ [ -f $i ] && install $i ${D}${docdir}/${BPN}
+ done
+
+ # install dirs and server init
+ install -d ${D}${sysconfdir}/init.d
+ install -m 0755 ${WORKDIR}/${BPN}.init ${D}${sysconfdir}/init.d/${BPN}-server
+ sed -i -e "s/^PGVERSION=.*$/PGVERSION=${PV}/g" ${D}${sysconfdir}/init.d/${BPN}-server
+ install -d -m 700 ${D}${localstatedir}/lib/${BPN}/data
+ install -d -m 700 ${D}${localstatedir}/lib/${BPN}/backups
+ install -m 644 ${WORKDIR}/${BPN}-bashprofile ${D}${localstatedir}/lib/${BPN}/.bash_profile
+ chown -R postgres:postgres ${D}${localstatedir}/lib/${BPN}
+ # multiple server config directory
+ install -d -m 700 ${D}${sysconfdir}/default/${BPN}
}
SSTATE_SCAN_FILES += "Makefile.global"
PACKAGES =+ "${PN}-client ${PN}-server-dev ${PN}-timezone \
- libecpg-compat-dbg libecpg-compat \
- libecpg-dbg libecpg libecpg-dev \
- libpq-dbg libpq libpq-dev \
- libpgtypes-dbg libpgtypes "
+ libecpg-compat-dbg libecpg-compat libecpg-compat-dev \
+ libecpg-dbg libecpg libecpg-dev libecpg-staticdev libecpg-doc \
+ libpq-dbg libpq libpq-dev libpq-staticdev \
+ libpgtypes-dbg libpgtypes libpgtypes-staticdev libpgtypes-dev \
+"
+
+FILES_${PN} += "${sysconfdir}/init.d/${BPN}-server \
+ ${localstatedir}/lib/${BPN}/data ${localstatedir}/lib/${BPN}/backups \
+ ${localstatedir}/lib/${BPN}/.bash_profile ${sysconfdir}/default/${BPN} \
+ ${libdir}/${BPN}/dict_snowball.so ${libdir}/${BPN}/plpgsql.so \
+ ${libdir}/${BPN}/euc2004_sjis2004.so \
+ ${libdir}/${BPN}/libpqwalreceiver.so \
+ ${libdir}/${BPN}/*_and_*.so \
+"
+
+FILES_${PN}-dbg += " ${libdir}/${BPN}/.debug/dict_snowball.so \
+ ${libdir}/${BPN}/.debug/plpgsql.so \
+ ${libdir}/${BPN}/.debug/euc2004_sjis2004.so \
+ ${libdir}/${BPN}/.debug/libpqwalreceiver.so \
+ ${libdir}/${BPN}/.debug/*_and_*.so \
+"
FILES_${PN}-client = "${bindir}/clusterdb \
${bindir}/createdb \
@@ -100,32 +120,54 @@ FILES_${PN}-client = "${bindir}/clusterdb \
${bindir}/reindexdb \
${bindir}/vacuumdb \
${bindir}/vacuumlo \
- ${datadir}/${PN}/psqlrc.sample"
+ ${datadir}/${BPN}/psqlrc.sample"
+
+FILES_${PN}-client-doc = "${mandir}/man1/clusterdb.* \
+ ${mandir}/man1/createdb.* ${mandir}/man1/createlang.* \
+ ${mandir}/man1/createuser.* ${mandir}/man1/dropdb.* \
+ ${mandir}/man1/droplang.* ${mandir}/man1/dropuser.* \
+ ${mandir}/man1/pg_dump.* ${mandir}/man1/pg_dumpall.* \
+ ${mandir}/man1/pg_restore.* ${mandir}/man1/psql.* \
+ ${mandir}/man1/reindexdb.* ${mandir}/man1/vacuumdb.* \
+ ${mandir}/man7/* \
+"
+
+FILES_${PN}-doc += "${docdir}/${BPN}/html ${libdir}/${BPN}/tutorial/ \
+ ${mandir}/man1/initdb.* ${mandir}/man1/pg_controldata.* \
+ ${mandir}/man1/pg_ctl.* ${mandir}/man1/pg_resetxlog.* \
+ ${mandir}/man1/postgres.* ${mandir}/man1/postmaster.* \
+"
-FILES_${PN}-doc += "${prefix}/doc/"
-FILES_${PN}-timezone = "${datadir}/${PN}/timezone"
-FILES_${PN}-server-dev = "${includedir}/${PN}/server"
+FILES_${PN}-timezone = "${datadir}/${BPN}/timezone \
+ ${datadir}/${BPN}/timezonesets \
+"
+RDEPENDS_${PN} += "${PN}-timezone"
+FILES_${PN}-server-dev = "${includedir}/${BPN}/server"
FILES_libecpg = "${libdir}/libecpg*${SOLIBS}"
FILES_libecpg-dbg = "${libdir}/.debug/libecpg*"
FILES_libecpg-dev = "${libdir}/libecpg*${SOLIBSDEV} \
${libdir}/libpgtypes*${SOLIBSDEV} \
- ${includedir}/ecpg*.h ${includedir}/${PN}/ecpg*.h \
- ${includedir}/pgtypes*.h ${includedir}/${PN}/informix \
+ ${includedir}/ecpg*.h ${includedir}/${BPN}/ecpg*.h \
+ ${includedir}/pgtypes*.h ${includedir}/${BPN}/informix \
${includedir}/sql3types.h ${includedir}/sqlca.h"
+FILES_libecpg-doc = "${mandir}/man1/ecpg.*"
FILES_libecpg-staticdev = "${libdir}/libecpg*.a"
SECTION_libecpg-staticdev = "devel"
RDEPENDS_libecpg-staticdev = "libecpg-dev (= ${EXTENDPKGV})"
FILES_libpq = "${libdir}/libpq*${SOLIBS}"
-FILES_libpq-dbg = "${libdir}/.debug/libpq* ${libdir}/${PN}/pgxs/src/test/regress/.debug/*"
+FILES_libpq-dbg = "${libdir}/.debug/libpq* ${libdir}/${BPN}/pgxs/src/test/regress/.debug/*"
FILES_libpq-dev = "${libdir}/libpq*${SOLIBSDEV} \
${includedir}"
-FILES_libpq-staticdev = "${libdir}/libpq*.a"
+FILES_libpq-staticdev = "${libdir}/libpq*.a ${libdir}/libpgport.a"
SECTION_libpq-staticdev = "devel"
RDEPENDS_libpq-staticdev = "libpq-dev (= ${EXTENDPKGV})"
FILES_libecpg-compat = "${libdir}/libecpg_compat*${SOLIBS}"
FILES_libecpg-compat-dbg = "${libdir}/.debug/libecpg_compat*"
+FILES_libecpg-compat-dev = "${libdir}/libecpg_compat*${SOLIBS}"
FILES_libpgtypes = "${libdir}/libpgtypes*${SOLIBS}"
FILES_libpgtypes-dbg = "${libdir}/.debug/libpgtypes*"
+FILES_libpgtypes-staticdev = "${libdir}/libpgtypes*.a"
+FILES_libpgtypes-dev = "${libdir}/libpgtypes*${SOLIBS} ${includedir}/pgtypes*.h"