diff options
author | Andrew Ross <aross@gentoo.org> | 2007-05-03 05:31:14 +0000 |
---|---|---|
committer | Andrew Ross <aross@gentoo.org> | 2007-05-03 05:31:14 +0000 |
commit | 061a9b8b7cac146163467230759392144783e527 (patch) | |
tree | 7660ee88315e290653844fe8dc481246c9373a66 /dev-db/postgresql | |
parent | Tweak @SYNC@ fix some more #176522. (diff) | |
download | historical-061a9b8b7cac146163467230759392144783e527.tar.gz historical-061a9b8b7cac146163467230759392144783e527.tar.bz2 historical-061a9b8b7cac146163467230759392144783e527.zip |
Version bump from 7.4.16 to 7.4.17 for bug #175791 (CVE-2007-2138 privilege escalation in SECURITY DEFINER functions).
Package-Manager: portage-2.1.2.2
Diffstat (limited to 'dev-db/postgresql')
-rw-r--r-- | dev-db/postgresql/ChangeLog | 9 | ||||
-rw-r--r-- | dev-db/postgresql/Manifest | 23 | ||||
-rw-r--r-- | dev-db/postgresql/files/digest-postgresql-7.4.17 | 12 | ||||
-rw-r--r-- | dev-db/postgresql/files/postgresql-7.4.17-hppa-testandset.patch | 50 | ||||
-rw-r--r-- | dev-db/postgresql/postgresql-7.4.17.ebuild | 275 |
5 files changed, 364 insertions, 5 deletions
diff --git a/dev-db/postgresql/ChangeLog b/dev-db/postgresql/ChangeLog index 52c97fc2b1f5..7e2cba75b3a7 100644 --- a/dev-db/postgresql/ChangeLog +++ b/dev-db/postgresql/ChangeLog @@ -1,6 +1,13 @@ # ChangeLog for dev-db/postgresql # Copyright 2002-2007 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/dev-db/postgresql/ChangeLog,v 1.335 2007/05/03 04:41:52 aross Exp $ +# $Header: /var/cvsroot/gentoo-x86/dev-db/postgresql/ChangeLog,v 1.336 2007/05/03 05:31:14 aross Exp $ + +*postgresql-7.4.17 (03 May 2007) + + 03 May 2007; Andrew Ross <aross@gentoo.org> + +files/postgresql-7.4.17-hppa-testandset.patch, +postgresql-7.4.17.ebuild: + Version bump from 7.4.16 to 7.4.17 for bug #175791 (CVE-2007-2138 privilege + escalation in SECURITY DEFINER functions). *postgresql-7.3.19 (03 May 2007) diff --git a/dev-db/postgresql/Manifest b/dev-db/postgresql/Manifest index 2f3e76476aee..0575dcadd626 100644 --- a/dev-db/postgresql/Manifest +++ b/dev-db/postgresql/Manifest @@ -70,6 +70,10 @@ AUX postgresql-7.4.16-hppa-testandset.patch 1394 RMD160 8f65f37b7e6cf251c4ab1342 MD5 2bf25091efb109eaf759b63e39b08716 files/postgresql-7.4.16-hppa-testandset.patch 1394 RMD160 8f65f37b7e6cf251c4ab134227570ee9974915a8 files/postgresql-7.4.16-hppa-testandset.patch 1394 SHA256 226f17c6064f53be2908325153b64e5f3b7d3e2275b7bd0f1abac27404b4678e files/postgresql-7.4.16-hppa-testandset.patch 1394 +AUX postgresql-7.4.17-hppa-testandset.patch 1394 RMD160 8f65f37b7e6cf251c4ab134227570ee9974915a8 SHA1 359a4b598aa419d5ae92d746d13abd4a6e05a0cf SHA256 226f17c6064f53be2908325153b64e5f3b7d3e2275b7bd0f1abac27404b4678e +MD5 2bf25091efb109eaf759b63e39b08716 files/postgresql-7.4.17-hppa-testandset.patch 1394 +RMD160 8f65f37b7e6cf251c4ab134227570ee9974915a8 files/postgresql-7.4.17-hppa-testandset.patch 1394 +SHA256 226f17c6064f53be2908325153b64e5f3b7d3e2275b7bd0f1abac27404b4678e files/postgresql-7.4.17-hppa-testandset.patch 1394 AUX postgresql-8.0-gentoo.patch 1200 RMD160 0bba8152556896c6bcdb7086d0f6b5dd5b4e8112 SHA1 64544332f2be6cae6c33b630feab224627d10681 SHA256 24c8b74a1b68de000003a4dff9768679fce76561182db1ffaa6723d161bf94bd MD5 290d9cac9f228e7479e316b68aadfd7c files/postgresql-8.0-gentoo.patch 1200 RMD160 0bba8152556896c6bcdb7086d0f6b5dd5b4e8112 files/postgresql-8.0-gentoo.patch 1200 @@ -207,6 +211,7 @@ DIST postgresql-base-7.3.19.tar.bz2 5691127 RMD160 802bbba70d1368097a74de6b67589 DIST postgresql-base-7.4.13.tar.bz2 6576973 RMD160 5f90ed85fdceb06fe15e324620e931140e3617ef SHA1 cb326a788833e805a54a80d87aeeb6fa00fb7b1e SHA256 2e2fa6b1cf3fc7a66a58762acfb64ce42d358e0dd799a467316e937d3a116cf7 DIST postgresql-base-7.4.14.tar.bz2 6575201 RMD160 c5b8ecd20ad2783c3f254f0e7402aab9ad722d0a SHA1 b737a35070bf13f478e8bca346a32243b9599b89 SHA256 5a34fcd56d2d8eebcd2728e5971c0d39d2971dc25e49d88bfeb84d69b5e8ebc9 DIST postgresql-base-7.4.16.tar.bz2 6586435 RMD160 8536d5f6f26a101240c64084e6adeb260efef891 SHA1 d3f36c6ace31d3725828aa9d86f4c08f266e33e3 SHA256 d8e7df2f06f248e66023452fa9cf565640b93ae43433dade7515f54e643f5c21 +DIST postgresql-base-7.4.17.tar.bz2 6609512 RMD160 cd5aed1fb45cc42e12cca0cd31174b6726dae97b SHA1 2e413d570ed657f941ca77b1ac00ef1eeecddbcc SHA256 f1b7ff754ccb43d4a3a62a9124b1c8ac215e48e5549e620bfcde59124c6f1bc5 DIST postgresql-base-8.0.12.tar.bz2 7846737 RMD160 e359f574020ef73a1f8f03ebffdc157114b1a454 SHA1 f43277c0463233f7deec434374a3799c372107b6 SHA256 2aec1d7129794fb29546e76bb0594f0c8ee6e37e8a155b201c15504af0740628 DIST postgresql-base-8.0.13.tar.bz2 7848290 RMD160 de34ef01b76d777e9b22bcd16dd29328a11d35cf SHA1 aaee4e481644645f3ba66dd7a66377ef3b22cd9c SHA256 5627ad76e6a6c8eb85c1debe5fce2c12b42611434dabe0fd5763b8a72c7ac49d DIST postgresql-base-8.0.8.tar.bz2 7823046 RMD160 2c60dc22f714bc0182051a94c3c1f513b30f574e SHA1 a5e5147497f0c2b548762d232d297b48d6e97d02 SHA256 906d86f2477309b9c2531d12fe720761fdffd73243a83ae31892bd7a0a618183 @@ -221,6 +226,7 @@ DIST postgresql-docs-7.3.19.tar.bz2 2365906 RMD160 acad805217a5b16badc5ea1c5f88e DIST postgresql-docs-7.4.13.tar.bz2 2426721 RMD160 4500c150a1638279394bf6f6882682f019ddf8ae SHA1 60c145ec822fca74cab03f3e11918df22752f899 SHA256 31d91342f23dc842839ee9f5b7475582a2e232c6831c6d514c3a414ed28ebdf8 DIST postgresql-docs-7.4.14.tar.bz2 2427724 RMD160 dd67ae2c4552986ced80d1ba52df50a5ae63db9b SHA1 47296643429237d81a0565aac819ded106cca36b SHA256 6739dcb6876e1f76933f88feae0b7d0a5e528e9677dac4175e3223ef379ed789 DIST postgresql-docs-7.4.16.tar.bz2 2429657 RMD160 f6b50b3b7c1c5bad00b9a33694eef46634bd95f1 SHA1 4b49280188e269d87579004795c7063b58797cbc SHA256 7478f43e5071756434526259895f16ffeffa4c8a11dbd9af2df34250a7f463be +DIST postgresql-docs-7.4.17.tar.bz2 2434028 RMD160 a7470801732f7458c4a6dec6b441b151a2963d88 SHA1 fbb8f744151e0a81c2047b40211a694d62c09bd8 SHA256 855b08821fa06cce280d63c1c57a1a51cc02eee1af0a53ba9a550cc3e66c2696 DIST postgresql-docs-8.0.12.tar.bz2 2266536 RMD160 7716e772348a21b98dcf78d670464b4a0e7fe832 SHA1 be869e88a1abfc7e577335ff0ad90b7040df5ab9 SHA256 04d233b68be2f4549a8a470166e7f6f175c5165722763c515e7230de0efa63d3 DIST postgresql-docs-8.0.13.tar.bz2 2271196 RMD160 fdb9775d082da9c10aebb9394d84c55cfea3f4d7 SHA1 b9d23b6c70fc3dc365a397d8eef3bd38b9ea1820 SHA256 a703a22b11288eb20b5c4f28e34cfeeed11c730cebf51671049ad37ace5e204d DIST postgresql-docs-8.0.8.tar.bz2 2260219 RMD160 e3dbde03b553000d5a263a93713c434e88dd4fe1 SHA1 2f845d6740c7ed88d0b9240b274a75d479658f7c SHA256 60a93ee5b2b80f517696328d85f4db24791cb1099d89a0adc375ee740201dc54 @@ -235,6 +241,7 @@ DIST postgresql-opt-7.3.19.tar.bz2 342076 RMD160 7ee1dea5c906d88ba3384ea805368a9 DIST postgresql-opt-7.4.13.tar.bz2 333860 RMD160 9fd1caacd6d842a473725450a0973173f68ae7b8 SHA1 79455e60f074a488ab3abafd10bfce4c63b33293 SHA256 8139a7161b2a55eba304b027896f0bfc81523dd41f7d1df222274b7a55e5aeab DIST postgresql-opt-7.4.14.tar.bz2 333417 RMD160 a6279f5b9d52f72ce786bc468c114befb5a1f29a SHA1 becc575260128261dc7f8ed46f166f54f48b8732 SHA256 e670d22812c50512807edd692d867e2b62c6b79f9d7b84cad56ef038cc12475d DIST postgresql-opt-7.4.16.tar.bz2 333683 RMD160 fec0e9b68c4868f4e2b85c002103089fbdbedf6f SHA1 657fe7c4ae1ba3020de4594117a1ab5db45f61bc SHA256 13a3063570c27ecc8ae163c86439b3c0b95d21bd55cac2506b105a486d410469 +DIST postgresql-opt-7.4.17.tar.bz2 333513 RMD160 55b7d1c9900f590d778c915d586d8cafd14dc633 SHA1 d2ac133dd0eb3a8faf2e5cbaa275ed575391b658 SHA256 8ff6ca8f726ce39d873d495273c31ceb3d647d75a85a7940b38d38ae7b2eff3e DIST postgresql-opt-8.0.12.tar.bz2 134790 RMD160 be0d57de5000296bfd5b64685f4d4ef81edea347 SHA1 bd26e2cce6ea7b486e29bc983ee76cfb0551f32b SHA256 ceaf90195860694487918032c19e0a11f991d74c77838cac2ea827d6c85f54da DIST postgresql-opt-8.0.13.tar.bz2 134769 RMD160 f3fb741c5dcff23045a58baf57f4386099e3c563 SHA1 ccdc23eb12b19c6d88633125b9e0c2feeda5f93e SHA256 9f63fc12ede1a605934cdc462ff45c0e924288284f411ae38dec1c5b6e87ce25 DIST postgresql-opt-8.0.8.tar.bz2 134600 RMD160 352f07aa25d0dcf1d2e3502f5cec7295c40bc3d5 SHA1 081d0b8d755a49395001b46ca0585c4e2b5ecf4f SHA256 427e82253b068b35e47235a1b78c521c89a9774b80dcc2433946f86220a34926 @@ -247,6 +254,7 @@ DIST postgresql-test-7.3.18.tar.bz2 891032 RMD160 f18fa7025a37bf85936ba78f5cdbb4 DIST postgresql-test-7.3.19.tar.bz2 891109 RMD160 4f5ee0f9c4dd86b6ee54a818e25e929c2fc2334f SHA1 7d40accb365cc41091a6fd62d08e2e8d57121678 SHA256 8df80f3fb5f61d61fe6348e037c614b3c0f2114ae5c8a7f3050b5fadde517ba3 DIST postgresql-test-7.4.14.tar.bz2 902074 RMD160 c6e1f57c77815b5395882cd482ef8bc952adabbf SHA1 3b15dbebe4232f66a253ff03729ee4ec3ffbd877 SHA256 39c87c0227f8c757d29141bb8c24e2a95d3a06d9bc459667fdee4d0028d6d12d DIST postgresql-test-7.4.16.tar.bz2 901854 RMD160 37a1ca493bd35534636dd82c1dd2468c4e37cf6c SHA1 565cfcfce7aae3e09ed1ecf0d7bc573ec0d31f96 SHA256 851d5de0f66e3a13a57acffc50f15288a2d367160902e08d0bd1a0deb72b0f39 +DIST postgresql-test-7.4.17.tar.bz2 902524 RMD160 5d2580ac74e01a65d9c00bc7a2900630e2c5720d SHA1 abd0a33ad4e7d7c94b0762913c4bee9762a8b345 SHA256 0486999f89b38996c15a91a66638f40718d5fb702ac592f4f2a22e9377b6b6bf DIST postgresql-test-8.0.12.tar.bz2 931028 RMD160 e8527c571f727c14eedc8551cce75f6565d516af SHA1 31046252ff7e9cfde68e14f623d054342c9150ad SHA256 54da2084d7ac970155836b5cf1d278b357df8a67d2a5af101f3390f866de18ac DIST postgresql-test-8.0.13.tar.bz2 932945 RMD160 d1a1c5e05337d82fb1fc2a7249e98ce8df375978 SHA1 07924ea198ce2654b65ecce6cd05025f24b62b86 SHA256 ea7e45aa8d9d8f127704e659575a0e860fd53abdaefa7c0f256f246c283ff1cf DIST postgresql-test-8.0.9.tar.bz2 931363 RMD160 ae38c2225daff32449ebe6b483096f2f35aa8067 SHA1 1a32090f302542daa92558a3f78129cd39782b98 SHA256 f2b81b3cf7ade17a748fa84570c295817d82fd05b53d2e0fb9d9e922b0c613ea @@ -281,6 +289,10 @@ EBUILD postgresql-7.4.16.ebuild 9606 RMD160 413e019c55da5bc7bf07b53ef71e9a5b8ccc MD5 4a123ad0aecbeef33d64c8ea413c31ed postgresql-7.4.16.ebuild 9606 RMD160 413e019c55da5bc7bf07b53ef71e9a5b8ccc12a6 postgresql-7.4.16.ebuild 9606 SHA256 9bbb3205fa544fbcf362074ba7f795b3470d03e2ff2d47e279b10ad9e24482f9 postgresql-7.4.16.ebuild 9606 +EBUILD postgresql-7.4.17.ebuild 9832 RMD160 268dffa6e732b97f7490bd6cac4f394361ebc46a SHA1 b11813ec6646b2fa1a4997b0f955e4a39ab7fcc1 SHA256 20f66d10f2dc4086eb5eeff14a00baf8b2c06e5a405b348ee05619752dce59be +MD5 acce95a000e9d3037b31bcd82a11bc10 postgresql-7.4.17.ebuild 9832 +RMD160 268dffa6e732b97f7490bd6cac4f394361ebc46a postgresql-7.4.17.ebuild 9832 +SHA256 20f66d10f2dc4086eb5eeff14a00baf8b2c06e5a405b348ee05619752dce59be postgresql-7.4.17.ebuild 9832 EBUILD postgresql-8.0.12.ebuild 9581 RMD160 f7a40d5f7878bfb7cc36416597c0907a9cf14617 SHA1 5a621fea04b54bc51b9001fa52a321a3c6eb7990 SHA256 2e5d0799f4cf7af516c0d7782b13d95d8f8abf939f543231ab1373f64159eb30 MD5 83799f7417ffc5a903cd20c27b17c673 postgresql-8.0.12.ebuild 9581 RMD160 f7a40d5f7878bfb7cc36416597c0907a9cf14617 postgresql-8.0.12.ebuild 9581 @@ -309,10 +321,10 @@ EBUILD postgresql-8.2.4-r1.ebuild 8378 RMD160 3b85064651af77c027aafde014d22d624d MD5 d1e75740d203ed4a5f55aa5c2a363a30 postgresql-8.2.4-r1.ebuild 8378 RMD160 3b85064651af77c027aafde014d22d624df222ee postgresql-8.2.4-r1.ebuild 8378 SHA256 30b8f49a2d4ea8f03478fc85c8db3732dc03adb9b01fe76b9df4495fa2163938 postgresql-8.2.4-r1.ebuild 8378 -MISC ChangeLog 70715 RMD160 b6d08601cc80933300e76e3aed7463df6012869f SHA1 043bdc850999e9c2d97687757fa9be1833cbe43d SHA256 b08fda87451d5fa33e5e3ea0310c60b08f5c4493ea1685741f8698da2d9b472e -MD5 5d308cf59aae1738d7dce59832c3aebb ChangeLog 70715 -RMD160 b6d08601cc80933300e76e3aed7463df6012869f ChangeLog 70715 -SHA256 b08fda87451d5fa33e5e3ea0310c60b08f5c4493ea1685741f8698da2d9b472e ChangeLog 70715 +MISC ChangeLog 70996 RMD160 6b2e1a7c74696684f8051901c65809c63cd07bf2 SHA1 beb3dda411fc308aa22f69d689cdbc5918da8c62 SHA256 e1f9ff072d2597540d99f13a028405e911785271f0d18a3528006f89521f18b6 +MD5 fe5fc0fa70503a0a35df8ed3361db827 ChangeLog 70996 +RMD160 6b2e1a7c74696684f8051901c65809c63cd07bf2 ChangeLog 70996 +SHA256 e1f9ff072d2597540d99f13a028405e911785271f0d18a3528006f89521f18b6 ChangeLog 70996 MISC metadata.xml 164 RMD160 becfe652663bd65719dd11fa6ffb588b3d5b4ecc SHA1 f67b7ac1c5e6e65ef5a19a589d4759c84918f86c SHA256 7e8e8126bc8701c4a42c7dfed8bb755ac6040fe3d0e3f994d888f8b2b4fa7d8b MD5 6fe52df942ef15801d56449cd8299604 metadata.xml 164 RMD160 becfe652663bd65719dd11fa6ffb588b3d5b4ecc metadata.xml 164 @@ -338,6 +350,9 @@ SHA256 6910f88a5fc143d08c6ee0f6746833c586e8bb42b29d9ba7b8efa3ad53376414 files/di MD5 9584d4741603568a5f6c52c0f33433b1 files/digest-postgresql-7.4.16 1087 RMD160 c51a91a6ca5c01ade5a3505289c80e475bb11fff files/digest-postgresql-7.4.16 1087 SHA256 cdcf54028993acd7d4c1f8d31f2ebc3d095193c516fbdc99aa8638fe49499ea7 files/digest-postgresql-7.4.16 1087 +MD5 561024989ce7be36fa4474211ae7b7c2 files/digest-postgresql-7.4.17 1087 +RMD160 811b466e6e54693166ac405d7c0dbb750728f6e0 files/digest-postgresql-7.4.17 1087 +SHA256 e1b60261487e99d6101290910dc22449e743c54e17c404c3f995bfca6940ea41 files/digest-postgresql-7.4.17 1087 MD5 f86efabfb6164185a3240e1320b6585f files/digest-postgresql-8.0.12 1087 RMD160 22e7de689c6b143166a109916c2f3028b7831f7b files/digest-postgresql-8.0.12 1087 SHA256 f114d4173578e4e0304d60e40ad8d406e984bc7a9235a7b7a7d749b0ef2bb47c files/digest-postgresql-8.0.12 1087 diff --git a/dev-db/postgresql/files/digest-postgresql-7.4.17 b/dev-db/postgresql/files/digest-postgresql-7.4.17 new file mode 100644 index 000000000000..d0643a9588ab --- /dev/null +++ b/dev-db/postgresql/files/digest-postgresql-7.4.17 @@ -0,0 +1,12 @@ +MD5 c513ae755abd4fb011378351be9e1ba0 postgresql-base-7.4.17.tar.bz2 6609512 +RMD160 cd5aed1fb45cc42e12cca0cd31174b6726dae97b postgresql-base-7.4.17.tar.bz2 6609512 +SHA256 f1b7ff754ccb43d4a3a62a9124b1c8ac215e48e5549e620bfcde59124c6f1bc5 postgresql-base-7.4.17.tar.bz2 6609512 +MD5 e9a33e70add61f6a1018870c88dbf0ea postgresql-docs-7.4.17.tar.bz2 2434028 +RMD160 a7470801732f7458c4a6dec6b441b151a2963d88 postgresql-docs-7.4.17.tar.bz2 2434028 +SHA256 855b08821fa06cce280d63c1c57a1a51cc02eee1af0a53ba9a550cc3e66c2696 postgresql-docs-7.4.17.tar.bz2 2434028 +MD5 43a87be48f3e43c5fce957af000bff60 postgresql-opt-7.4.17.tar.bz2 333513 +RMD160 55b7d1c9900f590d778c915d586d8cafd14dc633 postgresql-opt-7.4.17.tar.bz2 333513 +SHA256 8ff6ca8f726ce39d873d495273c31ceb3d647d75a85a7940b38d38ae7b2eff3e postgresql-opt-7.4.17.tar.bz2 333513 +MD5 493b0b142f0ca6fb52dbdfc5c32e0c5b postgresql-test-7.4.17.tar.bz2 902524 +RMD160 5d2580ac74e01a65d9c00bc7a2900630e2c5720d postgresql-test-7.4.17.tar.bz2 902524 +SHA256 0486999f89b38996c15a91a66638f40718d5fb702ac592f4f2a22e9377b6b6bf postgresql-test-7.4.17.tar.bz2 902524 diff --git a/dev-db/postgresql/files/postgresql-7.4.17-hppa-testandset.patch b/dev-db/postgresql/files/postgresql-7.4.17-hppa-testandset.patch new file mode 100644 index 000000000000..d5f916d455eb --- /dev/null +++ b/dev-db/postgresql/files/postgresql-7.4.17-hppa-testandset.patch @@ -0,0 +1,50 @@ +--- postgresql-7.4.12.orig/src/include/port/linux.h 2003-10-26 01:41:10.000000000 +0000 ++++ postgresql-7.4.12/src/include/port/linux.h 2004-01-09 20:22:50.000000000 +0000 +@@ -3,6 +3,11 @@ + + #define HAS_TEST_AND_SET + ++#elif defined(__hppa__) ++typedef struct { int sema[4]; } slock_t; ++ ++#define HAS_TEST_AND_SET ++ + #elif defined(__sparc__) + typedef unsigned char slock_t; + +--- postgresql-7.4.12.orig/src/include/storage/s_lock.h 2003-11-04 09:43:56.000000000 +0000 ++++ postgresql-7.4.12/src/include/storage/s_lock.h 2004-01-09 20:12:15.000000000 +0000 +@@ -112,6 +112,33 @@ + + #endif /* __i386__ || __x86_64__ */ + ++#if defined(__hppa__) || defined(__hppa) ++#define TAS(lock) tas(lock) ++ ++#define __ldcw(a) ({ \ ++ unsigned int __ret; \ ++ __asm__ __volatile__("ldcw 0(%2),%0" \ ++ : "=r" (__ret), "=m" (*(a)) : "r" (a)); \ ++ __ret; \ ++}) ++ ++#define __PA_LDCW_ALIGNMENT 16 ++#define __ldcw_align(a) ({ \ ++ volatile unsigned int __ret = (unsigned int) a; \ ++ if ((__ret & ~(__PA_LDCW_ALIGNMENT - 1)) < (unsigned int) a) \ ++ __ret = (__ret & ~(__PA_LDCW_ALIGNMENT - 1)) + __PA_LDCW_ALIGNMENT; \ ++ (unsigned int *) __ret; \ ++}) ++ ++static __inline__ int ++tas(volatile slock_t *lock) ++{ ++ volatile unsigned int *a = __ldcw_align (lock); ++ return (__ldcw(a) == 0); ++} ++ ++#endif /* __hppa__ || __hppa */ ++ + + /* Intel Itanium */ + #if defined(__ia64__) || defined(__ia64) diff --git a/dev-db/postgresql/postgresql-7.4.17.ebuild b/dev-db/postgresql/postgresql-7.4.17.ebuild new file mode 100644 index 000000000000..68af9c64a1f0 --- /dev/null +++ b/dev-db/postgresql/postgresql-7.4.17.ebuild @@ -0,0 +1,275 @@ +# Copyright 1999-2007 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/dev-db/postgresql/postgresql-7.4.17.ebuild,v 1.1 2007/05/03 05:31:14 aross Exp $ + +inherit eutils gnuconfig flag-o-matic multilib toolchain-funcs versionator + +KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86" + +DESCRIPTION="Sophisticated and powerful Object-Relational DBMS." +HOMEPAGE="http://www.postgresql.org/" +SRC_URI="mirror://postgresql/source/v${PV}/${PN}-base-${PV}.tar.bz2 + mirror://postgresql/source/v${PV}/${PN}-opt-${PV}.tar.bz2 + doc? ( mirror://postgresql/source/v${PV}/${PN}-docs-${PV}.tar.bz2 ) + test? ( mirror://postgresql/source/v${PV}/${PN}-test-${PV}.tar.bz2 )" +LICENSE="POSTGRESQL" +SLOT="0" +IUSE="doc kerberos nls pam perl pg-intdatetime python readline selinux ssl tcl test xml zlib" + +RDEPEND="~dev-db/libpq-${PV} + >=sys-libs/ncurses-5.2 + kerberos? ( virtual/krb5 ) + pam? ( virtual/pam ) + perl? ( >=dev-lang/perl-5.6.1-r2 ) + python? ( >=dev-lang/python-2.2 dev-python/egenix-mx-base ) + readline? ( >=sys-libs/readline-4.1 ) + selinux? ( sec-policy/selinux-postgresql ) + ssl? ( >=dev-libs/openssl-0.9.6-r1 ) + tcl? ( >=dev-lang/tcl-8 ) + xml? ( dev-libs/libxml2 dev-libs/libxslt ) + zlib? ( >=sys-libs/zlib-1.1.3 )" +DEPEND="${RDEPEND} + sys-devel/autoconf + >=sys-devel/bison-1.875 + nls? ( sys-devel/gettext ) + xml? ( dev-util/pkgconfig )" + +PG_DIR="/var/lib/postgresql" +[[ -z "${PG_MAX_CONNECTIONS}" ]] && PG_MAX_CONNECTIONS="512" + +cluster_exists() { + [[ -f "${PG_DIR}/data/PG_VERSION" ]] && return 0 + return 1 +} + +pkg_setup() { + if hasq pg-hier ${USE} ; then + ewarn "Warning: pg-hier USE-flag detected:" + ewarn "The hier-patch has been dropped for this version and the pg-hier USE-flag is therefore deprecated." + ewarn "If you really used the 'hier' patch in your database with the 'CONNECT BY' statement," + ewarn "you should stop now and reconsider. You will be able to reuse your data, but not" + ewarn "any VIEWS or QUERIES based on that statement." + ewarn "Please disable the pg-hier USE-flag!" + ebeep 3 + if cluster_exists ; then + eerror "There is already a database in '${PG_DIR}/data' and you have the pg-hier USE-flag set." + eerror "Please read the message above first. If you decide that the warnings there don't" + eerror "apply to your situation, dump the database using pg_dump and move the '${PG_DIR}/data'" + eerror "away. Then restart the merge. After that create a new database cluster and use pg_restore to" + eerror "re-import the previously dumped data." + eerror "Moving '${PG_DIR}/data' temporarely away or just disable the 'pg-hier' USE-flag won't work." + die "Can't update this database." + fi + fi + if cluster_exists ; then + local cluster_version=$(cat "${PG_DIR}/data/PG_VERSION") + if [[ ${cluster_version} != $(get_version_component_range 1-2) ]] ; then + eerror "There is a database in '${PG_DIR}/data' from PostgreSQL version ${cluster_version}." + eerror "PostgreSQL doesn't support upgrades between major versions, you have to use pg_dump" + eerror "to dump your existing database. Then move your '${PG_DIR}/data' directory away and" + eerror "restart the merge. After that create a new database cluster and use pg_restore to" + eerror "re-import the previously dumped data." + die "Can't update this database." + fi + fi + + enewgroup postgres 70 + enewuser postgres 70 /bin/bash /var/lib postgres +} + +src_unpack() { + unpack ${A} + cd "${S}" + + # libpq is provided separately as dev-db/libpq + sed -i -e 's/^DIRS := libpq ecpg/DIRS := ecpg/' src/interfaces/Makefile + sed -i -e '/\W\+\$.MAKE. -C include \$/d' src/Makefile + sed -i -e '/^\W\+psql scripts pg_config pg_controldata/ s/pg_config //' src/bin/Makefile + + epatch "${FILESDIR}/${P}-hppa-testandset.patch" + + # Prepare package for future tests + if use test ; then + # We need to run the tests as a non-root user, portage seems the most fitting here, + # so if userpriv is enabled, we use it directly. If userpriv is disabled, well, we + # don't support that in this version of PostgreSQL ... :) + mkdir -p "${S}/src/test/regress/tmp_check" + chown portage "${S}/src/test/regress/tmp_check" + einfo "Tests will be run as user portage." + fi +} + +src_compile() { + filter-flags -ffast-math -feliminate-dwarf2-dups + + # Correctly support the XML stuff + if use xml ; then + CFLAGS="${CFLAGS} $(pkg-config --cflags libxml-2.0)" + LIBS="${LIBS} $(pkg-config --libs libxml-2.0)" + fi + + # Detect mips systems properly + gnuconfig_update + + cd "${S}" + + ./configure --prefix=/usr \ + --includedir=/usr/include/postgresql/pgsql \ + --sysconfdir=/etc/postgresql \ + --mandir=/usr/share/man \ + --host=${CHOST} \ + --docdir=/usr/share/doc/${PF} \ + --libdir=/usr/$(get_libdir) \ + --enable-depend \ + $(use_with kerberos krb5) \ + $(use_enable nls ) \ + $(use_with pam) \ + $(use_with perl) \ + $(use_enable pg-intdatetime integer-datetimes ) \ + $(use_with python) \ + $(use_with readline) \ + $(use_with ssl openssl) \ + $(use_with tcl) \ + --without-tk \ + $(use_with zlib) \ + || die "configure failed" + + emake -j1 LD="$(tc-getLD) $(get_abi_LDFLAGS)" || die "main emake failed" + + cd "${S}/contrib" + emake -j1 LD="$(tc-getLD) $(get_abi_LDFLAGS)" || die "contrib emake failed" + + if use xml ; then + cd "${S}/contrib/xml" + emake -j1 LD="$(tc-getLD) $(get_abi_LDFLAGS)" || die "contrib/xml emake failed" + fi +} + +src_install() { + if use perl ; then + mv -f "${S}/src/pl/plperl/GNUmakefile" "${S}/src/pl/plperl/GNUmakefile_orig" + sed -e "s:\$(DESTDIR)\$(plperl_installdir):\$(plperl_installdir):" \ + "${S}/src/pl/plperl/GNUmakefile_orig" > "${S}/src/pl/plperl/GNUmakefile" + fi + + cd "${S}" + emake -j1 DESTDIR="${D}" LIBDIR="${D}/usr/$(get_libdir)" install || die "main emake install failed" + + cd "${S}/contrib" + emake -j1 DESTDIR="${D}" LIBDIR="${D}/usr/$(get_libdir)" install || die "contrib emake install failed" + + if use xml ; then + cd "${S}/contrib/xml" + emake -j1 DESTDIR="${D}" LIBDIR="${D}/usr/$(get_libdir)" install || die "contrib/xml emake install failed" + fi + + cd "${S}" + dodoc README HISTORY + dodoc contrib/adddepend/* + + cd "${S}/doc" + dodoc FAQ* README.* TODO bug.template + + if use doc ; then + cd "${S}/doc" + docinto FAQ_html + dodoc src/FAQ/* + docinto sgml + dodoc src/sgml/*.{sgml,dsl} + docinto sgml/ref + dodoc src/sgml/ref/*.sgml + docinto TODO.detail + dodoc TODO.detail/* + fi + + newinitd "${FILESDIR}/postgresql.init-${PV%.*}" postgresql || die "Inserting init.d-file failed" + newconfd "${FILESDIR}/postgresql.conf-${PV%.*}" postgresql || die "Inserting conf.d-file failed" + + newinitd "${FILESDIR}/pg_autovacuum.init-${PV%.*}" pg_autovacuum || die "Inserting pg_autovacuum init.d-file failed" + newconfd "${FILESDIR}/pg_autovacuum.conf-${PV%.*}" pg_autovacuum || die "Inserting pg_autovacuum conf.d-file failed" + dosed "s:___DOCDIR___:/usr/share/doc/${PF}:" /etc/init.d/pg_autovacuum +} + +pkg_postinst() { + elog "Execute the following command to setup the initial database environment:" + elog + elog "emerge --config =${PF}" + elog + elog "If you need a global psqlrc-file, you can place it in '${ROOT%/}/etc/postgresql/'." +} + +pkg_config() { + einfo "Creating the data directory ..." + mkdir -p "${PG_DIR}/data" + chown -Rf postgres:postgres "${PG_DIR}" + chmod 0700 "${PG_DIR}/data" + + einfo "Initializing the database ..." + if [[ -f "${PG_DIR}/data/PG_VERSION" ]] ; then + eerror "PostgreSQL ${PV} cannot upgrade your existing databases." + eerror "You must remove your entire database directory to continue." + eerror "(database directory = ${PG_DIR})." + die "Remove your database directory to continue" + else + if use kernel_linux ; then + local SEM=`sysctl -n kernel.sem | cut -f-3` + local SEMMNI=`sysctl -n kernel.sem | cut -f4` + local SEMMNI_MIN=`expr \( ${PG_MAX_CONNECTIONS} + 15 \) / 16` + local SHMMAX=`sysctl -n kernel.shmmax` + local SHMMAX_MIN=`expr 500000 + 30600 \* ${PG_MAX_CONNECTIONS}` + + if [ ${SEMMNI} -lt ${SEMMNI_MIN} ] ; then + eerror "The current value of SEMMNI is too low" + eerror "for PostgreSQL to run ${PG_MAX_CONNECTIONS} connections!" + eerror "Temporary setting this value to ${SEMMNI_MIN} while creating the initial database." + echo ${SEM} ${SEMMNI_MIN} > /proc/sys/kernel/sem + fi + + su postgres -c "/usr/bin/initdb --pgdata ${PG_DIR}/data" + + if [ ! `sysctl -n kernel.sem | cut -f4` -eq ${SEMMNI} ] ; then + echo ${SEM} ${SEMMNI} > /proc/sys/kernel/sem + ewarn "Restoring the SEMMNI value to the previous value." + ewarn "Please edit the last value of kernel.sem in /etc/sysctl.conf" + ewarn "and set it to at least ${SEMMNI_MIN}:" + ewarn + ewarn " kernel.sem = ${SEM} ${SEMMNI_MIN}" + ewarn + fi + + if [ ${SHMMAX} -lt ${SHMMAX_MIN} ] ; then + eerror "The current value of SHMMAX is too low for postgresql to run." + eerror "Please edit /etc/sysctl.conf and set this value to at least ${SHMMAX_MIN}:" + eerror + eerror " kernel.shmmax = ${SHMMAX_MIN}" + eerror + fi + else + su postgres -c "/usr/bin/initdb --pgdata ${PG_DIR}/data" + fi + + einfo + einfo "You can use the '${ROOT%/}/etc/init.d/postgresql' script to run PostgreSQL instead of 'pg_ctl'." + einfo + fi +} + +src_test() { + cd "${S}" + + einfo ">>> Test phase [check]: ${CATEGORY}/${PF}" + if hasq userpriv ${FEATURES} ; then + if ! emake -j1 check ; then + hasq test ${FEATURES} && die "Make check failed. See above for details." + hasq test ${FEATURES} || eerror "Make check failed. See above for details." + fi + else + eerror "Tests won't be run if FEATURES=userpriv is disabled!" + fi + + einfo "Yes, there are other tests which could be run." + einfo "... and no, we don't plan to add/support them." + einfo "For now, the main regressions tests will suffice." + einfo "If you think other tests are necessary, please submit a" + einfo "bug including a patch for this ebuild to enable them." +} |