diff options
author | Aaron Swenson <titanofold@gentoo.org> | 2012-04-08 22:12:41 +0000 |
---|---|---|
committer | Aaron Swenson <titanofold@gentoo.org> | 2012-04-08 22:12:41 +0000 |
commit | 8baf71c36d305438b35d437837864c3c84950e1a (patch) | |
tree | dd4b9e2a96164e770b0c258714f5e64a687a588b /dev-db | |
parent | Update patch so that USE=gtk won't fail if sqlite3 is not present. Make the e... (diff) | |
download | historical-8baf71c36d305438b35d437837864c3c84950e1a.tar.gz historical-8baf71c36d305438b35d437837864c3c84950e1a.tar.bz2 historical-8baf71c36d305438b35d437837864c3c84950e1a.zip |
Clean out cruft.
Package-Manager: portage-2.1.10.49/cvs/Linux x86_64
Diffstat (limited to 'dev-db')
-rw-r--r-- | dev-db/postgresql-base/Manifest | 30 | ||||
-rw-r--r-- | dev-db/postgresql-server/ChangeLog | 11 | ||||
-rw-r--r-- | dev-db/postgresql-server/Manifest | 35 | ||||
-rw-r--r-- | dev-db/postgresql-server/postgresql-server-8.3.16.ebuild | 319 | ||||
-rw-r--r-- | dev-db/postgresql-server/postgresql-server-8.3.17-r1.ebuild | 339 | ||||
-rw-r--r-- | dev-db/postgresql-server/postgresql-server-8.3.17.ebuild | 339 | ||||
-rw-r--r-- | dev-db/postgresql-server/postgresql-server-8.4.10-r1.ebuild | 348 | ||||
-rw-r--r-- | dev-db/postgresql-server/postgresql-server-8.4.10.ebuild | 348 | ||||
-rw-r--r-- | dev-db/postgresql-server/postgresql-server-8.4.9.ebuild | 323 | ||||
-rw-r--r-- | dev-db/postgresql-server/postgresql-server-9.0.5.ebuild | 327 | ||||
-rw-r--r-- | dev-db/postgresql-server/postgresql-server-9.0.6-r1.ebuild | 342 | ||||
-rw-r--r-- | dev-db/postgresql-server/postgresql-server-9.0.6.ebuild | 342 | ||||
-rw-r--r-- | dev-db/postgresql-server/postgresql-server-9.1.1.ebuild | 319 | ||||
-rw-r--r-- | dev-db/postgresql-server/postgresql-server-9.1.2-r1.ebuild | 337 | ||||
-rw-r--r-- | dev-db/postgresql-server/postgresql-server-9.1.2-r2.ebuild | 337 |
15 files changed, 20 insertions, 4076 deletions
diff --git a/dev-db/postgresql-base/Manifest b/dev-db/postgresql-base/Manifest index 09cf2042b852..8d171d793c73 100644 --- a/dev-db/postgresql-base/Manifest +++ b/dev-db/postgresql-base/Manifest @@ -1,50 +1,30 @@ -----BEGIN PGP SIGNED MESSAGE----- -Hash: SHA1 +Hash: SHA256 DIST postgresql-8.2.22.tar.bz2 12777172 RMD160 27e31b4a423984080a87cb6dc86ca8773362a131 SHA1 7b5f56b5d3a1e2e9cee6e7a4f0f04866af45cc7d SHA256 88203528326c152ca556bcff986d824737ea1048ba2c6245e24a1b1efd6aeaf7 DIST postgresql-8.2.23.tar.bz2 12976249 RMD160 5a1d45cae1e7a9d9caa8e902608404b281bac7ff SHA1 f51ac2051c4b1c95f5f58bf75bbafc50d2bc359b SHA256 56c2ac7394e8ace9ef98a464d08530b91529fd56978f24b55139d20e3039f2d1 -DIST postgresql-8.3.16.tar.bz2 14348568 RMD160 2e2c677defbb0631529a4b76a3adee006c288617 SHA1 c8bda0f506c03d01054fac6dc2f1291cf7539c7e SHA256 000590e2bdd1a00c8f2d2fa30c1f244826a61ad038a53b63179e902f876a2744 -DIST postgresql-8.3.17.tar.bz2 14549222 RMD160 9ea925c26b185fb9066061ef4e1fca932bbbcbfb SHA1 f47bfb98629fed07e8f5ec61f2c3b84487fb0ad1 SHA256 fb15eeeaabcc753275abddf6e0fc8ad919dad5cb8a9863a6dc98348ed1f30877 DIST postgresql-8.3.18.tar.bz2 14563583 RMD160 d276a468f59b4def821b686b5504a549bd0491c3 SHA1 0d832fc9c7dba5de1716921274ce0ca276418070 SHA256 5db4904a8959f09274e1e0ee7f21c354128d5dbb4e946b78391f6bc4723c3746 -DIST postgresql-8.4.10.tar.bz2 14481565 RMD160 ce5961033fc05b9e862cfef3c164d8faed19ce89 SHA1 31202e47fd2274b3a846d98c961cd7281d1798e8 SHA256 749f83e9d467b07dcd012fdf2b1615c577b410fd219b44a27bb7097bb1b07cfb DIST postgresql-8.4.11.tar.bz2 14502434 RMD160 85b4be0884ca11855eb0dbc1541403e7baf7c0aa SHA1 ce9581b9f03bd884417b988ec317ce2ed06bb15f SHA256 5bbc9ff1d16282b592600d7c6b9cb1a93049d4aa9a961e3c2c8d5fb13b189c8f -DIST postgresql-8.4.9.tar.bz2 14275979 RMD160 469acc1d1358c48334896fb8fa84de1d287183d5 SHA1 7b6bbd72db0f63ea55890427ab6c7a40e7c7ff1b SHA256 1d58cb8d0cb8ae8f61042b2d5aa54135a2d2a0f324d06593870e1242b0e8c38a -DIST postgresql-9.0.5.tar.bz2 14344752 RMD160 c5f4f37808f7e24d91a6c95d41fc89330624e26f SHA1 1c71be5b1a7d519eff33bb60768776f47b44acf3 SHA256 56d8ee809ceeabeae8461ae0a197943460cba5bf8fbe37324e4451cf2eb7d504 -DIST postgresql-9.0.6.tar.bz2 14777282 RMD160 e1794a28e495b861c2f82b325b4e28e71faa58ca SHA1 4a9a7d5579d3683ca1992b2ba116a4356094b3ca SHA256 317d99d2ff9e1de8da0cae107bc06c9fd455b1df0c0fb77b8fbb61fb08276056 DIST postgresql-9.0.7.tar.bz2 14977437 RMD160 80a8c91233462515914aeb5c15cf63b7195da3ef SHA1 c0cf6de3cfa131b36107b3748ae44786ad638e12 SHA256 dabe26d71d8b595f9514da1363dc20c3f4b90b6908026dd06984cac448a6d833 -DIST postgresql-9.1.1.tar.bz2 14884071 RMD160 294c0e04bebcf07fa88fb5d5e5837c99f736edd3 SHA1 4df7b6f6b23acdac5ea198e3623796a2b62fc7a4 SHA256 c794016bcf3fc1f561bc86796c6c9d050e3d8d2d55356515126e048275ae56f2 -DIST postgresql-9.1.2.tar.bz2 15424814 RMD160 2f98f2ff4e6e2b048dce80335fb3c672753114a9 SHA1 7d57b96eb1c764ec234c72b70511a5f7e23fb2b0 SHA256 8d54ff514f5b2754e6e36b008c43d7bbf7daf541da608767cc5bdedb1de5db30 DIST postgresql-9.1.3.tar.bz2 15582454 RMD160 84eb235c090083b78e6a2facf3d7bc534395db8b SHA1 1cf3044415df807c08bb8ad8e40e24e8d375cf34 SHA256 7a79800a624031c1d9bc9cdce73cb40050100ac50a82050cbf7bbbd16ac4d5d5 DIST postgresql-patches-8.2-r1.tbz2 4859 RMD160 864f166e01219b1f8f9ca2732a1d6b9c6de0cf7f SHA1 27977244ef48cb1a232542657d76267faa7e9d3d SHA256 7b9f46ca16d7adf29cfd2a3f57f2b54bbf349b4dbbe679f4e31302376bda51cf DIST postgresql-patches-8.2-r2.tbz2 4850 RMD160 766861791d68b8307e2686b93dd5b09fb775fdb8 SHA1 41c8b8a36d7dd7aa556ca6e2d5a4bb579226e8f7 SHA256 014f68519d25de055dce373924caf681d517ab66c022c01adb9816545e4bab14 -DIST postgresql-patches-8.3-r1.tbz2 5491 RMD160 6a05ec9a9c0dd587cc86e7684a353cb5e3cd7fa3 SHA1 a60e5f813e77f8b1edc9483f62e067b04457fb1d SHA256 522d4563f2e5fa857751091d1344799d8e22846de20c4fb360a7451d746fd176 DIST postgresql-patches-8.3-r2.tbz2 5501 RMD160 ffd2661f5a4832917d4c28b5a231b6467c04146f SHA1 7514b558a7c6f34d7491bd500fd8c74510d9f0d0 SHA256 adae4c048745de04fd44f0408e8ab85aa5cae283cb3ddc2962e0379905cca73f -DIST postgresql-patches-8.4-r1.tbz2 4826 RMD160 4cd4d9e890ef9010c89d88944a75bf6482b18742 SHA1 0ce0eefcc64b506b612b4da9e74fb8127dc514cb SHA256 00b915c2232c0f5c0a4fbcfbc66cff451429d544a2658aec6900858fb4c7224a DIST postgresql-patches-8.4-r2.tbz2 4822 RMD160 cf1ef4d046653c571e9059c6b27dcd5d1b504b26 SHA1 0fb36f6c8d9bb54b1528acd1821f76619f297403 SHA256 9920097ff5243df28788a6f3bdf6cdad38e6c42885f38da84b0f2c8c242954d7 -DIST postgresql-patches-9.0-r2.tbz2 4527 RMD160 781181b32326e0e2dd4e0624b78604cc4c8bf4c7 SHA1 3f3ebbb2ad83a4a8d94ebe05c23d7d753835ac86 SHA256 c7f5e77d16ecc384a8b7802ac2c35ed5b0de68f3dc30cb767a96b49501f8219f DIST postgresql-patches-9.0-r3.tbz2 4503 RMD160 05d4167c3a48a432ab79cb57fee5e4661d229cc6 SHA1 04d4a820415304ddb27078a75669289647192048 SHA256 2d454575423f0e56f23d540fbc865309d0bee3f80e5e05a7e1d793a7e70763cf DIST postgresql-patches-9.1-r1.tbz2 4547 RMD160 2cdd98c1f6075a68ef294ceefc94e46ff1583919 SHA1 0ed2fd26ba51fe945b573accec5970b8cee5eb4c SHA256 50cefff4a6f6e1fd38b99dde4793dc5f153b9691ff5c59fbb2b97864f1f7d727 -DIST postgresql-patches-9.1.tbz2 4563 RMD160 1516ee0d26fffe5e275428d08ba926bad9b45407 SHA1 5ff25d423386b476c60bbccfda93b82bfc5e5cc9 SHA256 be0dc8be6029443c9de31b61002c128447d53f8fb4b05e89b86d900ced647c16 EBUILD postgresql-base-8.2.22.ebuild 3746 RMD160 2557e3bcff305cbd2618c7ca3594673f78e108bb SHA1 99d7d9bd2e4dbb7fc2766788e3f415eeded3814e SHA256 b06f2f4347f3d74e033ae8317f7f30e6910ce971f8747066f94a2c9eadcc959b EBUILD postgresql-base-8.2.23.ebuild 3946 RMD160 52fb36367c0694702b7beeafc62a74c4c9a1b993 SHA1 dd0c865d62b1c1bcd269607fb3f3b2058926eea6 SHA256 d5de324f518b49a199bf31ff0bc071c105384ca2477b00c8f83d3fa629723a14 -EBUILD postgresql-base-8.3.16.ebuild 3861 RMD160 3ca643363231bdf9406def3f69e057396d86188d SHA1 98ec2618b8368562aff15637d7e52b425832a428 SHA256 3c94fbcacc72b79f89f3b5b0918079d67e026c8631ffc71680bda9dc97103227 -EBUILD postgresql-base-8.3.17.ebuild 4050 RMD160 9de90ec36e88880ef69d5e7a75b5393243a562a8 SHA1 b84468f1e32f08da4e7154981b988f1f82d5b42d SHA256 1241758193c776ef0451012c5d02223747aae554466bdd6d71915b6dbf9e99a9 EBUILD postgresql-base-8.3.18.ebuild 4044 RMD160 243dad056530a3f311171f230c7e69b71fa3424c SHA1 108a4fe7c37650c2ec82f84d5505ea62106574ca SHA256 f7215556616143b1d50345c367d03b0448ba377ff31f5dec6faeeae5c1275ee1 -EBUILD postgresql-base-8.4.10.ebuild 4052 RMD160 6a49eff648316384be0b3b1cb91fdcea91288d31 SHA1 e88b47f52f703ce8c1581e08dbf31139f7383cc4 SHA256 b68053c22addb9f000e5676f297a4e25d2868fb7d831aaf53358c561ff1747be EBUILD postgresql-base-8.4.11.ebuild 4046 RMD160 92eda194cb9caf823b63b28bb9762bc499c0ff6d SHA1 af3843b8ecbcf5e1f7af16681326292893ae7861 SHA256 a82b0b96a52a21785571c63739c35bf465efc3a866bdfdcd6e7f861ced12900c -EBUILD postgresql-base-8.4.9.ebuild 3862 RMD160 56ff8e8771fa018a8e635e22670757977a838900 SHA1 74ee39fb1ce9f78ed9c9a6add6a617cd00dbab11 SHA256 661153ec2e72f0a5e6a4ea589c4838596c01cbb9890e74ece898a9ad8b2aa5d0 -EBUILD postgresql-base-9.0.5.ebuild 4016 RMD160 8a129227c2c840a9eb66e79758c07cfa01e30baf SHA1 21d38671a5aea9796d6d215de7d5d86bac6e44b2 SHA256 2228ab7df1e93691507517bf4c5ef10c717233f61df3884bb2b9d494491c7ad1 -EBUILD postgresql-base-9.0.6.ebuild 4205 RMD160 9312b3f9ea039280dc44db67e0d03b6726ffda6e SHA1 46024de8a8bad744d3709b26f927f5a76df6c7e9 SHA256 b478c7298f7ab32bee4f09d033a5dfb98b72e9a89b2afb526406299e53911ed6 EBUILD postgresql-base-9.0.7.ebuild 4199 RMD160 8e4ca7b460d1238abe6cf333354a65ac2bda5944 SHA1 75702928210251a1afd82d565df6a4bcf01ac7c0 SHA256 e60748ca8522d91ce666101253db00e9c6a1d5036310d4d61afb7ddbe07f2d6e -EBUILD postgresql-base-9.1.1.ebuild 4011 RMD160 36b525faac362eb5fdeb49e91ee0a75f3aa49a7d SHA1 8f8afb9036fbabeb30958d474fbbee34f684a905 SHA256 9e9f0b590d5db7e92077e563000610bcc4e207bf0c55ea48adb30cddc818d08f -EBUILD postgresql-base-9.1.2.ebuild 4206 RMD160 e84f28f56f4bf70ccc1f91e4ebd2ba04dec6eceb SHA1 74daa8e6c58f3ce12674093b3a1cd76574c064ea SHA256 7aa9fed228a53984b2508a6dc741bfd705c255107d9d89ab7f0ec96c76eb4b5a EBUILD postgresql-base-9.1.3.ebuild 4200 RMD160 2b2752d42d66756a908db00f0c10236c7e3d3ebc SHA1 a927a12eaf34096a18256f35ef606c656b85601f SHA256 b5c7d82a226fcab756d3bc5784135b908a421494c368ae3abeb1dcf1ff3dbd4a -MISC ChangeLog 47257 RMD160 da1e39d5225b932755aaee30663d9807bd722401 SHA1 0af0ed78f85bcdae4853d4506d2742e31ccd5419 SHA256 c2bf28f36697a6ac78bddbaa59039fa1d25eaaba5c5383f94eaf66977b377f02 +MISC ChangeLog 47608 RMD160 db75f5e082c884ad2bebb12d95ef6203012ceb67 SHA1 016a95807a5c37c2596db901c120a2ac0177b850 SHA256 d76681755b7291c58fd7403998c7e84567bbf2a45a731fe4babab6b0e843cf94 MISC metadata.xml 472 RMD160 fe3dc42a49cd1445788d023578d878c6226c72e0 SHA1 f03eda301fc89bf31cfb64bb6cc2cc4ca33cb632 SHA256 ee20753f4083988318c4c30155901e99a800dc8fb19fd77c80f9947c72abbf4c -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.17 (GNU/Linux) -iEYEARECAAYFAk+BpT4ACgkQuQc30/atMkA5CgCfRjP9D1wm4YsKNqIeAoav/zLH -JZ4An2k1wEXs4oVmSF8ZC1WxOtjOfzyy -=SCY7 +iF4EAREIAAYFAk+CDiYACgkQVxOqA9G7/aCAxQEAmobxvRfmqtnEhJ+SZ8NIq6VA +V1Z5P5LsUdpVKLpfLV8A/3tdwQRIkaYGR+8gZFWBDOrsdBCK+y8MgbfNZ7yGBBMU +=m/Pz -----END PGP SIGNATURE----- diff --git a/dev-db/postgresql-server/ChangeLog b/dev-db/postgresql-server/ChangeLog index 28ae0a6e57e2..b4416d64ea65 100644 --- a/dev-db/postgresql-server/ChangeLog +++ b/dev-db/postgresql-server/ChangeLog @@ -1,6 +1,15 @@ # ChangeLog for dev-db/postgresql-server # Copyright 1999-2012 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/dev-db/postgresql-server/ChangeLog,v 1.182 2012/04/08 14:52:34 armin76 Exp $ +# $Header: /var/cvsroot/gentoo-x86/dev-db/postgresql-server/ChangeLog,v 1.183 2012/04/08 22:12:41 titanofold Exp $ + + 08 Apr 2012; Aaron W. Swenson <titanofold@gentoo.org> + -postgresql-server-8.3.16.ebuild, -postgresql-server-8.3.17.ebuild, + -postgresql-server-8.3.17-r1.ebuild, -postgresql-server-8.4.9.ebuild, + -postgresql-server-8.4.10.ebuild, -postgresql-server-8.4.10-r1.ebuild, + -postgresql-server-9.0.5.ebuild, -postgresql-server-9.0.6.ebuild, + -postgresql-server-9.0.6-r1.ebuild, -postgresql-server-9.1.1.ebuild, + -postgresql-server-9.1.2-r1.ebuild, -postgresql-server-9.1.2-r2.ebuild: + Clean out cruft. 08 Apr 2012; Raúl Porcel <armin76@gentoo.org> postgresql-server-8.3.18.ebuild, postgresql-server-8.4.11.ebuild, diff --git a/dev-db/postgresql-server/Manifest b/dev-db/postgresql-server/Manifest index becf2a23fb4b..b6ccc48cc330 100644 --- a/dev-db/postgresql-server/Manifest +++ b/dev-db/postgresql-server/Manifest @@ -1,59 +1,34 @@ -----BEGIN PGP SIGNED MESSAGE----- -Hash: SHA1 +Hash: SHA256 DIST postgresql-8.2.22.tar.bz2 12777172 RMD160 27e31b4a423984080a87cb6dc86ca8773362a131 SHA1 7b5f56b5d3a1e2e9cee6e7a4f0f04866af45cc7d SHA256 88203528326c152ca556bcff986d824737ea1048ba2c6245e24a1b1efd6aeaf7 DIST postgresql-8.2.23.tar.bz2 12976249 RMD160 5a1d45cae1e7a9d9caa8e902608404b281bac7ff SHA1 f51ac2051c4b1c95f5f58bf75bbafc50d2bc359b SHA256 56c2ac7394e8ace9ef98a464d08530b91529fd56978f24b55139d20e3039f2d1 -DIST postgresql-8.3.16.tar.bz2 14348568 RMD160 2e2c677defbb0631529a4b76a3adee006c288617 SHA1 c8bda0f506c03d01054fac6dc2f1291cf7539c7e SHA256 000590e2bdd1a00c8f2d2fa30c1f244826a61ad038a53b63179e902f876a2744 -DIST postgresql-8.3.17.tar.bz2 14549222 RMD160 9ea925c26b185fb9066061ef4e1fca932bbbcbfb SHA1 f47bfb98629fed07e8f5ec61f2c3b84487fb0ad1 SHA256 fb15eeeaabcc753275abddf6e0fc8ad919dad5cb8a9863a6dc98348ed1f30877 DIST postgresql-8.3.18.tar.bz2 14563583 RMD160 d276a468f59b4def821b686b5504a549bd0491c3 SHA1 0d832fc9c7dba5de1716921274ce0ca276418070 SHA256 5db4904a8959f09274e1e0ee7f21c354128d5dbb4e946b78391f6bc4723c3746 -DIST postgresql-8.4.10.tar.bz2 14481565 RMD160 ce5961033fc05b9e862cfef3c164d8faed19ce89 SHA1 31202e47fd2274b3a846d98c961cd7281d1798e8 SHA256 749f83e9d467b07dcd012fdf2b1615c577b410fd219b44a27bb7097bb1b07cfb DIST postgresql-8.4.11.tar.bz2 14502434 RMD160 85b4be0884ca11855eb0dbc1541403e7baf7c0aa SHA1 ce9581b9f03bd884417b988ec317ce2ed06bb15f SHA256 5bbc9ff1d16282b592600d7c6b9cb1a93049d4aa9a961e3c2c8d5fb13b189c8f -DIST postgresql-8.4.9.tar.bz2 14275979 RMD160 469acc1d1358c48334896fb8fa84de1d287183d5 SHA1 7b6bbd72db0f63ea55890427ab6c7a40e7c7ff1b SHA256 1d58cb8d0cb8ae8f61042b2d5aa54135a2d2a0f324d06593870e1242b0e8c38a -DIST postgresql-9.0.5.tar.bz2 14344752 RMD160 c5f4f37808f7e24d91a6c95d41fc89330624e26f SHA1 1c71be5b1a7d519eff33bb60768776f47b44acf3 SHA256 56d8ee809ceeabeae8461ae0a197943460cba5bf8fbe37324e4451cf2eb7d504 -DIST postgresql-9.0.6.tar.bz2 14777282 RMD160 e1794a28e495b861c2f82b325b4e28e71faa58ca SHA1 4a9a7d5579d3683ca1992b2ba116a4356094b3ca SHA256 317d99d2ff9e1de8da0cae107bc06c9fd455b1df0c0fb77b8fbb61fb08276056 DIST postgresql-9.0.7.tar.bz2 14977437 RMD160 80a8c91233462515914aeb5c15cf63b7195da3ef SHA1 c0cf6de3cfa131b36107b3748ae44786ad638e12 SHA256 dabe26d71d8b595f9514da1363dc20c3f4b90b6908026dd06984cac448a6d833 -DIST postgresql-9.1.1.tar.bz2 14884071 RMD160 294c0e04bebcf07fa88fb5d5e5837c99f736edd3 SHA1 4df7b6f6b23acdac5ea198e3623796a2b62fc7a4 SHA256 c794016bcf3fc1f561bc86796c6c9d050e3d8d2d55356515126e048275ae56f2 -DIST postgresql-9.1.2.tar.bz2 15424814 RMD160 2f98f2ff4e6e2b048dce80335fb3c672753114a9 SHA1 7d57b96eb1c764ec234c72b70511a5f7e23fb2b0 SHA256 8d54ff514f5b2754e6e36b008c43d7bbf7daf541da608767cc5bdedb1de5db30 DIST postgresql-9.1.3.tar.bz2 15582454 RMD160 84eb235c090083b78e6a2facf3d7bc534395db8b SHA1 1cf3044415df807c08bb8ad8e40e24e8d375cf34 SHA256 7a79800a624031c1d9bc9cdce73cb40050100ac50a82050cbf7bbbd16ac4d5d5 DIST postgresql-initscript-1.0.1.tbz2 2635 RMD160 989b89364ff367569c5129dec70c369496a69af1 SHA1 24cfbab756bf2c08e783ecae31c26ca45984de87 SHA256 a85276c431047e0123c988b296869cfa8afbbb6a4721d74fff4b419f608f0293 -DIST postgresql-initscript-1.2.tbz2 2776 RMD160 137a737c928a73886192c822fe31be18e9ee0b85 SHA1 9140008e07c0c71e0fdbc8c2f6d40ab729d094a3 SHA256 19600139714738552e4b6880f6349df27b275814c62954103f20984b607e357f DIST postgresql-initscript-2.0.tbz2 2584 RMD160 437c331ba5d4b9ce85725d9d180aa4edd9f47bf1 SHA1 9a99f91c2955bb3cd4414d9165868307d0450364 SHA256 67e75f134b8c55843e3b3a26c69460eca3f180052a6f4f13603c64fcb40b4fd5 DIST postgresql-initscript-2.1.tbz2 2603 RMD160 033f7189df6132b8bcca378e000bd2b705463b72 SHA1 4125c76d102ea78cb5cebd4a13021930f131ae02 SHA256 42ee83d0bfd1e1733bbc191b065bc70b2b5966f743f692e5133f6c676c8b1c24 DIST postgresql-patches-8.2-r1.tbz2 4859 RMD160 864f166e01219b1f8f9ca2732a1d6b9c6de0cf7f SHA1 27977244ef48cb1a232542657d76267faa7e9d3d SHA256 7b9f46ca16d7adf29cfd2a3f57f2b54bbf349b4dbbe679f4e31302376bda51cf DIST postgresql-patches-8.2-r2.tbz2 4850 RMD160 766861791d68b8307e2686b93dd5b09fb775fdb8 SHA1 41c8b8a36d7dd7aa556ca6e2d5a4bb579226e8f7 SHA256 014f68519d25de055dce373924caf681d517ab66c022c01adb9816545e4bab14 -DIST postgresql-patches-8.3-r1.tbz2 5491 RMD160 6a05ec9a9c0dd587cc86e7684a353cb5e3cd7fa3 SHA1 a60e5f813e77f8b1edc9483f62e067b04457fb1d SHA256 522d4563f2e5fa857751091d1344799d8e22846de20c4fb360a7451d746fd176 DIST postgresql-patches-8.3-r2.tbz2 5501 RMD160 ffd2661f5a4832917d4c28b5a231b6467c04146f SHA1 7514b558a7c6f34d7491bd500fd8c74510d9f0d0 SHA256 adae4c048745de04fd44f0408e8ab85aa5cae283cb3ddc2962e0379905cca73f -DIST postgresql-patches-8.4-r1.tbz2 4826 RMD160 4cd4d9e890ef9010c89d88944a75bf6482b18742 SHA1 0ce0eefcc64b506b612b4da9e74fb8127dc514cb SHA256 00b915c2232c0f5c0a4fbcfbc66cff451429d544a2658aec6900858fb4c7224a DIST postgresql-patches-8.4-r2.tbz2 4822 RMD160 cf1ef4d046653c571e9059c6b27dcd5d1b504b26 SHA1 0fb36f6c8d9bb54b1528acd1821f76619f297403 SHA256 9920097ff5243df28788a6f3bdf6cdad38e6c42885f38da84b0f2c8c242954d7 -DIST postgresql-patches-9.0-r2.tbz2 4527 RMD160 781181b32326e0e2dd4e0624b78604cc4c8bf4c7 SHA1 3f3ebbb2ad83a4a8d94ebe05c23d7d753835ac86 SHA256 c7f5e77d16ecc384a8b7802ac2c35ed5b0de68f3dc30cb767a96b49501f8219f DIST postgresql-patches-9.0-r3.tbz2 4503 RMD160 05d4167c3a48a432ab79cb57fee5e4661d229cc6 SHA1 04d4a820415304ddb27078a75669289647192048 SHA256 2d454575423f0e56f23d540fbc865309d0bee3f80e5e05a7e1d793a7e70763cf DIST postgresql-patches-9.1-r1.tbz2 4547 RMD160 2cdd98c1f6075a68ef294ceefc94e46ff1583919 SHA1 0ed2fd26ba51fe945b573accec5970b8cee5eb4c SHA256 50cefff4a6f6e1fd38b99dde4793dc5f153b9691ff5c59fbb2b97864f1f7d727 -DIST postgresql-patches-9.1.tbz2 4563 RMD160 1516ee0d26fffe5e275428d08ba926bad9b45407 SHA1 5ff25d423386b476c60bbccfda93b82bfc5e5cc9 SHA256 be0dc8be6029443c9de31b61002c128447d53f8fb4b05e89b86d900ced647c16 EBUILD postgresql-server-8.2.22.ebuild 10898 RMD160 ae8248bf59287ef90e6e5b82e03f32f18fa3ac2c SHA1 dec431a578c42d97b7e45e376ad1c681082ed4fa SHA256 a0536da4e12736a755616e56b943a8a71ffc239490e17c56cf93a5a10b5d6a26 EBUILD postgresql-server-8.2.23-r1.ebuild 11469 RMD160 87c9fd803aa29b3cb40c7da1f9561b9ef01194f2 SHA1 0e776abad9ca1b97a970c24519c95845eb3fb53b SHA256 2a98158b23ae6309226b8c93308f7409057aa795445153ee7faeeb337fb2f806 EBUILD postgresql-server-8.2.23.ebuild 11466 RMD160 982fd5ce1203ea05a890b40d729cbfd0c68294df SHA1 92891e9a25e2d30a209d521755cbcd008c5e964b SHA256 012aebbe8222cffc7d7d2dac09539c521a812095f5593dc4773782a5927aa697 -EBUILD postgresql-server-8.3.16.ebuild 11096 RMD160 6ceb5797f12d3d68ffef7ebf5a751da91f6a39c9 SHA1 362c7b5b3fd493e92636cd299149ad9bb4b5c0d3 SHA256 d0080a89ae1f94576ae9918fc6a081d5b0357eb17a0e2f92c371f344735a26ac -EBUILD postgresql-server-8.3.17-r1.ebuild 11528 RMD160 b5405e464daa5c9e99b0ac20cf292988cbfa651c SHA1 34d13f42409e534481223a727db7864041c73f3c SHA256 5c8da749eaa5f5b7bb7426207f0e9ecfb343ea0784636da6c02f852f3482c1a6 -EBUILD postgresql-server-8.3.17.ebuild 11525 RMD160 2d389d13b39a798385c074d3418cadcb4db54a67 SHA1 f4dba3d591cf552392a802801d4544d2e72382b8 SHA256 4ca612f53e4416d2920d97b3afad7e503a3812171da6f177452da5ad3517ccac EBUILD postgresql-server-8.3.18.ebuild 11519 RMD160 5d8df779629196ba5d9deb34836fc49e1fc3638e SHA1 5e160adfe6e9331414477938eeb4d9138ea3953d SHA256 51bb2aa812a4bee3ee6cb8691401bdd6bbc61f92c93e68956b613afdca6c18da -EBUILD postgresql-server-8.4.10-r1.ebuild 11823 RMD160 27b4b02b462e1be6406184a297daf128aee6ac5d SHA1 6cb95521d5bb2f06b95b4053de5366c92bbe00ef SHA256 c3e4f269be99e7b6f692fb63cdac2b2136056e02ff044860b1318732e39cdeeb -EBUILD postgresql-server-8.4.10.ebuild 11820 RMD160 01a1e426cd211bac980e4b4de595f80f1a44f5b1 SHA1 092a3818a8b579a4c166f327597737e16c970814 SHA256 706a11c18b9d7c02a89fc64eee3509f0ade70963f1dad7c62453bae341cccc77 EBUILD postgresql-server-8.4.11.ebuild 11814 RMD160 73ce8dee8838320a87a6bfdae1b77cedc631c62e SHA1 dceb99da6fcb2921e94fb0aeb007f8611ed978eb SHA256 9713a7307b1b71d6cd11e2f7cd219dbbf1bdfc56aa7aa520982425089db56337 -EBUILD postgresql-server-8.4.9.ebuild 11385 RMD160 6ded647d66ef21624c24ecf591cf1bbd2c8e8970 SHA1 376b9bd9c60ff80658f531eb4b3c313a327d2654 SHA256 15a8cde3b9a43b375ab6767b5cef68ac3a33569632a70e1ddd79b3369906766f -EBUILD postgresql-server-9.0.5.ebuild 11297 RMD160 f681ffd3325f6c16d7d1ea7057af9aed541e2143 SHA1 f40ce5f8672ad8dd1ed0d2c08d11e043f5e72b09 SHA256 5e2b0108038b4eb6e963265921c6de8d82eb019e6c3ed6e7669478a8d4b5fa50 -EBUILD postgresql-server-9.0.6-r1.ebuild 11423 RMD160 9eab4372e32d16d73df84526669d980bdd922bfc SHA1 75994a253a9da29a235ed53d1f46e7e04dffd2fe SHA256 7bcb4d5c8eb75b096f9c312a1ed47f4eca4a4e6fb134176f3b7088438fbf5f70 -EBUILD postgresql-server-9.0.6.ebuild 11420 RMD160 1cdf6ab0202254a776fa3b0b1a4622676a769d77 SHA1 21ca20908a64292eafd5a6dc948eb65a7dd0935a SHA256 a9f2aa4f9ebdcd7fa01b793ba3a86e15de9460b001885d339db3fb62425c9a05 EBUILD postgresql-server-9.0.7.ebuild 11414 RMD160 7904dd3db59e37dc69db4e446c39ba887d0ea9b6 SHA1 ecd501afb0d35bd0122fb0ea45741b11f5fa18d7 SHA256 e7246869ab2c10d6e082b876b85394e62abeaa666d4dd17abbf8340fa4fd8e0d -EBUILD postgresql-server-9.1.1.ebuild 10773 RMD160 1fdbb45a444ffee2807ceddcfeb35273978a2f59 SHA1 9aa3d559341445c91c138bf431a55e04fd8180e1 SHA256 59d6863592b7b3cc317b33b63464e91d8a3acd245547bc32ed890f78ad6f81f5 -EBUILD postgresql-server-9.1.2-r1.ebuild 11155 RMD160 7b56807c8a689bd8cf395489a1aa4ae11ed69fae SHA1 3fd70536e1226677da0fe3e907f6007c13d7099f SHA256 4ae4655508a8cd855c474740306ccfd87f58e7d16dfe7f83b9f80ff097ed121a -EBUILD postgresql-server-9.1.2-r2.ebuild 11154 RMD160 b43c8b2d9f54096d2bb4398eec97c5ca5610676f SHA1 b32b271e5acce3c0750192d5e8693c2dcda7308a SHA256 52279d90808dbd62bf78a81df1f2f03b51fe27d453c285b1b75302259ad73ae0 EBUILD postgresql-server-9.1.3.ebuild 11431 RMD160 59a30221b31ad510d66497823fabbf42b90d939e SHA1 fabf79c06c2a5470d71b00013a5d02131b27cd1e SHA256 47cc25b35077a5b3ca3a240efd6a385f93d295e70d073dbdf2f26c91dafdb885 -MISC ChangeLog 55130 RMD160 dce19a06be0e5fc1888e9116262fc27cc843c620 SHA1 5866b53ae0991be41fb71bc969ddfe5873ab3689 SHA256 2851fb6adca5fc99bdbc41773fb9d2bfb74b500f529acc5a5ebca80f462061e8 +MISC ChangeLog 55637 RMD160 0f18a9b1a16b4ca6a2185fcd299d4ac725b90d6e SHA1 6d3d349b25882f67cd942c40c116bc10bb778855 SHA256 774429ad9861b26b05a272441165d872446e04164a1ef7562bf89435b7838375 MISC metadata.xml 420 RMD160 789f5a0ce45d05125098fd7e74a816cf08f4c39b SHA1 d308d7434a37f12cd320f74ed85e1d3ca7dabc75 SHA256 ac37a5084450a782d02510149d030bd0d4a63164f2ffb7bdda3ddf344606ca62 -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.17 (GNU/Linux) -iEYEARECAAYFAk+BpjoACgkQuQc30/atMkD2+ACgsPwxmktb+VASqbtEDsqCJ67D -4YcAnA0f/wzbeOO8c4tr4gHE7KNCWWFz -=110z +iF4EAREIAAYFAk+CDVsACgkQVxOqA9G7/aB+QQD9EOI9QTO0nNLgHA/Rs2wRe5v6 +7bM05F1mzxHoiRa+7rEA+gJfHhCViaJ5Rvypd3oJeBCOcJ4mOVkWbGwqwBW3jgan +=H5Z3 -----END PGP SIGNATURE----- diff --git a/dev-db/postgresql-server/postgresql-server-8.3.16.ebuild b/dev-db/postgresql-server/postgresql-server-8.3.16.ebuild deleted file mode 100644 index 3e24fbd6dfe0..000000000000 --- a/dev-db/postgresql-server/postgresql-server-8.3.16.ebuild +++ /dev/null @@ -1,319 +0,0 @@ -# Copyright 1999-2011 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/dev-db/postgresql-server/postgresql-server-8.3.16.ebuild,v 1.6 2011/10/03 22:33:49 titanofold Exp $ - -EAPI="4" - -WANT_AUTOMAKE="none" -inherit autotools eutils multilib pam prefix versionator - -SLOT="$(get_version_component_range 1-2)" - -KEYWORDS="alpha amd64 arm hppa ia64 ~mips ppc ppc64 s390 sh sparc x86 ~x86-fbsd" - -DESCRIPTION="PostgreSQL server" -HOMEPAGE="http://www.postgresql.org/" -SRC_URI="mirror://postgresql/source/v${PV}/postgresql-${PV}.tar.bz2 - http://dev.gentoo.org/~titanofold/postgresql-patches-${SLOT}-r1.tbz2 - http://dev.gentoo.org/~titanofold/postgresql-initscript-1.2.tbz2" -LICENSE="POSTGRESQL" - -S="${WORKDIR}/postgresql-${PV}" - -LINGUAS="af cs de en es fa fr hr hu it ko nb pl pt_BR ro ru sk sl sv tr zh_CN zh_TW" -IUSE="doc kernel_linux nls pam perl python selinux tcl uuid xml" - -for lingua in ${LINGUAS} ; do - IUSE+=" linguas_${lingua}" -done - -wanted_languages() { - local enable_langs - - for lingua in ${LINGUAS} ; do - use linguas_${lingua} && enable_langs+="${lingua} " - done - - echo -n ${enable_langs} -} - -RDEPEND="~dev-db/postgresql-base-${PV}:${SLOT}[pam?,nls=] - perl? ( >=dev-lang/perl-5.8 ) - selinux? ( sec-policy/selinux-postgresql ) - tcl? ( >=dev-lang/tcl-8 ) - uuid? ( dev-libs/ossp-uuid ) - xml? ( dev-libs/libxml2 dev-libs/libxslt )" - -DEPEND="${RDEPEND} - sys-devel/flex - xml? ( dev-util/pkgconfig )" - -PDEPEND="doc? ( ~dev-db/postgresql-docs-${PV} )" - -pkg_setup() { - enewgroup postgres 70 - enewuser postgres 70 /bin/bash /var/lib/postgresql postgres -} - -src_prepare() { - epatch "${WORKDIR}/autoconf.patch" "${WORKDIR}/bool.patch" \ - "${WORKDIR}/darwin.patch" "${WORKDIR}/pg_ctl-exit-status.patch" \ - "${WORKDIR}/server.patch" "${WORKDIR}/SuperH.patch" - - eprefixify src/include/pg_config_manual.h - - if use test ; then - epatch "${WORKDIR}/regress.patch" - sed -e "s|@SOCKETDIR@|${T}|g" -i src/test/regress/pg_regress{,_main}.c - sed -e "s|/no/such/location|${S}/src/test/regress/tmp_check/no/such/location|g" \ - -i src/test/regress/{input,output}/tablespace.source - else - echo "all install:" > "${S}/src/test/regress/GNUmakefile" - fi - - eautoconf -} - -src_configure() { - # eval is needed to get along with pg_config quotation of space-rich entities. - eval econf "$(${EPREFIX%/}/usr/$(get_libdir)/postgresql-${SLOT}/bin/pg_config --configure)" \ - --with-includes="${EPREFIX%/}/usr/include/postgresql-${SLOT}/" \ - --with-system-tzdata="${EPREFIX%/}/usr/share/zoneinfo" \ - $(use_with perl) \ - $(use_with python) \ - $(use_with tcl) \ - $(use_with xml libxml) \ - $(use_with xml libxslt) \ - $(use_with uuid ossp-uuid) \ - "$(has_version ~dev-db/postgresql-base-${PV}[nls] && use_enable nls nls "$(wanted_languages)")" -} - -src_compile() { - local bd - for bd in . contrib $(use xml && echo contrib/xml2); do - PATH="${EROOT%/}/usr/$(get_libdir)/postgresql-${SLOT}/bin:${PATH}" \ - emake -C $bd -j1 \ - PGXS=$(${EROOT%/}/usr/$(get_libdir)/postgresql-${SLOT}/bin/pg_config --pgxs) \ - PGXS_IN_SERVER=1 PGXS_WITH_SERVER="${S}/src/backend/postgres" \ - NO_PGXS=0 USE_PGXS=1 docdir=${EROOT%/}/usr/share/doc/${PF} - done -} - -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 - - local bd - for bd in . contrib $(use xml && echo contrib/xml2) ; do - PATH="${EROOT%/}/usr/$(get_libdir)/postgresql-${SLOT}/bin:${PATH}" \ - emake install -C $bd -j1 DESTDIR="${D}" \ - PGXS_IN_SERVER=1 PGXS_WITH_SERVER="${S}/src/backend/postgres" \ - PGXS=$(${EROOT%/}/usr/$(get_libdir)/postgresql-${SLOT}/bin/pg_config --pgxs) \ - NO_PGXS=0 USE_PGXS=1 docdir=${EROOT%/}/usr/share/doc/${PF} - done - - rm -r "${ED}/usr/share/postgresql-${SLOT}/man/man7/" "${ED}/usr/share/doc/${PF}/html" - rm "${ED}"/usr/share/postgresql-${SLOT}/man/man1/{clusterdb,create{db,lang,user},drop{db,lang,user},ecpg,pg_{config,dump,dumpall,restore},psql,reindexdb,vacuumdb}.1 - docompress /usr/share/postgresql-${SLOT}/man/man1 - - dodoc README HISTORY doc/{README.*,TODO,bug.template} - - dodir /etc/eselect/postgresql/slots/${SLOT} - echo "postgres_ebuilds=\"\${postgres_ebuilds} ${PF}\"" \ - > "${ED}/etc/eselect/postgresql/slots/${SLOT}/server" - - sed -e "s/@SLOT@/${SLOT}/g" -i "${WORKDIR}"/postgresql.confd - newconfd "${WORKDIR}/postgresql.confd" postgresql-${SLOT} - sed -e "s/@SLOT@/${SLOT}/g" -i "${WORKDIR}"/postgresql.init - newinitd "${WORKDIR}/postgresql.init" postgresql-${SLOT} - - use pam && pamd_mimic system-auth postgresql auth account session - - keepdir /var/run/postgresql - fperms 0770 /var/run/postgresql - use prefix || fowners postgres:postgres /var/run/postgresql -} - -pkg_postinst() { - postgresql-config update - - elog "The Unix-domain socket is located in:" - elog " ${EROOT%/}/var/run/postgresql/" - elog - elog "If you have users and/or services that you would like to utilize the socket," - elog "you must add them to the 'postgres' system group:" - elog " usermod -a -G postgres <user>" - elog - elog "Before initializing the database, you may want to edit PG_INITDB_OPTS so that" - elog "it contains your preferred locale in:" - elog " ${EROOT%/}/etc/conf.d/postgresql-${SLOT}" - elog - elog "Execute the following command to setup the initial database" - elog "environment:" - elog " emerge --config =${CATEGORY}/${PF}" -} - -pkg_postrm() { - postgresql-config update -} - -pkg_config() { - [[ -f ${EROOT%/}/etc/conf.d/postgresql-${SLOT} ]] && source "${EROOT%/}/etc/conf.d/postgresql-${SLOT}" - [[ -z ${PGDATA} ]] && PGDATA="${EROOT%/}/etc/postgresql-${SLOT}/" - [[ -z ${DATA_DIR} ]] && DATA_DIR="${EROOT%/}/var/lib/postgresql/${SLOT}/data" - - # environment.bz2 may not contain the same locale as the current system - # locale. Unset and source from the current system locale. - if [[ -f ${EROOT%/}/etc/env.d/02locale ]] ; then - unset LANG - unset LC_CTYPE - unset LC_NUMERIC - unset LC_TIME - unset LC_COLLATE - unset LC_MONETARY - unset LC_MESSAGES - unset LC_ALL - source ${EROOT%/}/etc/env.d/02locale - [[ -n ${LANG} ]] && export LANG - [[ -n ${LC_CTYPE} ]] && export LC_CTYPE - [[ -n ${LC_NUMERIC} ]] && export LC_NUMERIC - [[ -n ${LC_TIME} ]] && export LC_TIME - [[ -n ${LC_COLLATE} ]] && export LC_COLLATE - [[ -n ${LC_MONETARY} ]] && export LC_MONETARY - [[ -n ${LC_MESSAGES} ]] && export LC_MESSAGES - [[ -n ${LC_ALL} ]] && export LC_ALL - fi - - einfo "You can modify the paths and options passed to initdb by editing:" - einfo " ${EROOT%/}/etc/conf.d/postgresql-${SLOT}" - einfo - einfo "Information on options that can be passed to initdb are found at:" - einfo " http://www.postgresql.org/docs/${SLOT}/static/creating-cluster.html" - einfo " http://www.postgresql.org/docs/${SLOT}/static/app-initdb.html" - einfo - einfo "PG_INITDB_OPTS is currently set to:" - if [[ -z ${PG_INITDB_OPTS} ]] ; then - einfo " (none)" - else - einfo " ${PG_INITDB_OPTS}" - fi - einfo - einfo "Configuration files will be installed to:" - einfo " ${PGDATA}" - einfo - einfo "The database cluster will be created in:" - einfo " ${DATA_DIR}" - einfo - while [[ $correct != "true" ]] ; do - einfo "Are you ready to continue? (y/n)" - read answer - if [[ $answer =~ ^[Yy]([Ee][Ss])?$ ]] ; then - correct="true" - elif [[ $answer =~ ^[Nn]([Oo])?$ ]] ; then - die "Aborting initialization." - else - echo "Answer not recognized." - fi - done - - if [[ -n "$(ls -A ${DATA_DIR} 2> /dev/null)" ]] ; then - eerror "The given directory, '${DATA_DIR}', is not empty." - eerror "Modify DATA_DIR to point to an empty directory." - die "${DATA_DIR} is not empty." - fi - - [[ -z ${PG_MAX_CONNECTIONS} ]] && PG_MAX_CONNECTIONS=128 - einfo "Checking system parameters..." - - if ! use kernel_linux ; then - einfo "Skipped." - einfo "Tests not supported on this OS (yet)." - else - if [[ -z ${SKIP_SYSTEM_TESTS} ]] ; then - einfo "Checking whether your system supports at least ${PG_MAX_CONNECTIONS} connections..." - - local SEMMSL=$(sysctl -n kernel.sem | cut -f1) - local SEMMNS=$(sysctl -n kernel.sem | cut -f2) - local SEMMNI=$(sysctl -n kernel.sem | cut -f4) - local SHMMAX=$(sysctl -n kernel.shmmax) - - local SEMMSL_MIN=17 - local SEMMNS_MIN=$(( ( ${PG_MAX_CONNECTIONS}/16 ) * 17 )) - local SEMMNI_MIN=$(( ( ${PG_MAX_CONNECTIONS}+15 ) / 16 )) - local SHMMAX_MIN=$(( 500000 + ( 30600 * ${PG_MAX_CONNECTIONS} ) )) - - for p in SEMMSL SEMMNS SEMMNI SHMMAX ; do - if [[ $(eval echo \$$p) -lt $(eval echo \$${p}_MIN) ]] ; then - eerror "The value for ${p} $(eval echo \$$p) is below the recommended value $(eval echo \$${p}_MIN)" - eerror "You have now several options:" - eerror " - Change the mentioned system parameter" - eerror " - Lower the number of max connections by setting PG_MAX_CONNECTIONS to a" - eerror " value lower than ${PG_MAX_CONNECTIONS}" - eerror " - Set SKIP_SYSTEM_TESTS in case you want to ignore this test completely" - eerror "More information can be found here:" - eerror " http://www.postgresql.org/docs/${SLOT}/static/kernel-resources.html" - die "System test failed." - fi - done - einfo "Passed." - else - ewarn "SKIP_SYSTEM_TESTS is set, so skipping." - fi - fi - - if [[ ${EUID} == 0 ]] ; then - einfo "Creating the data directory ..." - mkdir -p "${DATA_DIR}" - chown -Rf postgres:postgres "${DATA_DIR}" - chmod 0700 "${DATA_DIR}" - fi - - einfo "Initializing the database ..." - if [[ ${EUID} == 0 ]] ; then - su postgres -c "${EROOT%/}/usr/$(get_libdir)/postgresql-${SLOT}/bin/initdb -D \"${DATA_DIR}\" ${PG_INITDB_OPTS}" - else - "${EROOT%/}"/usr/$(get_libdir)/postgresql-${SLOT}/bin/initdb -U postgres -D "${DATA_DIR}" ${PG_INITDB_OPTS} - fi - mv "${DATA_DIR%/}"/*.conf "${PGDATA}" - - einfo "The autovacuum function, which was in contrib, has been moved to the main" - einfo "PostgreSQL functions starting with 8.1. You can enable it in the clusters" - einfo "postgresql.conf." - einfo - if use prefix ; then - einfo "The location of the configuration files have moved to:" - einfo " ${PGDATA}" - einfo - einfo "To start the server:" - einfo " pg_ctl start -D ${DATA_DIR} -o '-D ${PGDATA} --data-directory=${DATA_DIR}'" - einfo - einfo "To stop:" - einfo " pg_ctl stop -D ${DATA_DIR}" - einfo - einfo "Or move the configuration files back:" - einfo " mv ${PGDATA}*.conf ${DATA_DIR}" - else - einfo "You should use the '${EROOT%/}/etc/init.d/postgresql-${SLOT}' script to run PostgreSQL" - einfo "instead of 'pg_ctl'." - fi -} - -src_test() { - einfo ">>> Test phase [check]: ${CATEGORY}/${PF}" - - if [[ ${UID} != 0 ]] ; then - PATH="${EROOT%/}/usr/$(get_libdir)/postgresql-${SLOT}/bin/:${PATH}" \ - emake check \ - PGXS=$(${EROOT%/}/usr/$(get_libdir)/postgresql-${SLOT}/bin/pg_config --pgxs) \ - NO_PGXS=0 USE_PGXS=1 SLOT=${SLOT} - - einfo "If you think other tests besides the regression tests are necessary, please" - einfo "submit a bug including a patch for this ebuild to enable them." - else - ewarn "Tests cannot be run as root. Skipping." - ewarn "HINT: FEATURES=\"userpriv\"" - fi -} diff --git a/dev-db/postgresql-server/postgresql-server-8.3.17-r1.ebuild b/dev-db/postgresql-server/postgresql-server-8.3.17-r1.ebuild deleted file mode 100644 index 06d4b2d0b642..000000000000 --- a/dev-db/postgresql-server/postgresql-server-8.3.17-r1.ebuild +++ /dev/null @@ -1,339 +0,0 @@ -# Copyright 1999-2012 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/dev-db/postgresql-server/postgresql-server-8.3.17-r1.ebuild,v 1.7 2012/02/19 11:38:48 klausman Exp $ - -EAPI="4" - -WANT_AUTOMAKE="none" -inherit autotools eutils multilib pam prefix versionator - -SLOT="$(get_version_component_range 1-2)" - -KEYWORDS="alpha amd64 arm hppa ~ia64 ~mips ppc ~ppc64 ~s390 ~sh ~sparc x86 ~x86-fbsd" - -DESCRIPTION="PostgreSQL server" -HOMEPAGE="http://www.postgresql.org/" -SRC_URI="mirror://postgresql/source/v${PV}/postgresql-${PV}.tar.bz2 - http://dev.gentoo.org/~titanofold/postgresql-patches-8.3-r2.tbz2 - http://dev.gentoo.org/~titanofold/postgresql-initscript-2.1.tbz2" -LICENSE="POSTGRESQL" - -S="${WORKDIR}/postgresql-${PV}" - -LINGUAS="af cs de en es fa fr hr hu it ko nb pl pt_BR ro ru sk sl sv tr zh_CN zh_TW" -IUSE="doc kernel_linux nls pam perl python selinux tcl uuid xml" - -for lingua in ${LINGUAS} ; do - IUSE+=" linguas_${lingua}" -done - -wanted_languages() { - local enable_langs - - for lingua in ${LINGUAS} ; do - use linguas_${lingua} && enable_langs+="${lingua} " - done - - echo -n ${enable_langs} -} - -RDEPEND="~dev-db/postgresql-base-${PV}:${SLOT}[pam?,nls=] - perl? ( >=dev-lang/perl-5.8 ) - selinux? ( sec-policy/selinux-postgresql ) - tcl? ( >=dev-lang/tcl-8 ) - uuid? ( dev-libs/ossp-uuid ) - xml? ( dev-libs/libxml2 dev-libs/libxslt )" - -DEPEND="${RDEPEND} - sys-devel/flex - xml? ( dev-util/pkgconfig )" - -PDEPEND="doc? ( ~dev-db/postgresql-docs-${PV} )" - -# Support /var/run or /run for the socket directory -[[ ! -d /run ]] && RUNDIR=/var - -pkg_setup() { - enewgroup postgres 70 - enewuser postgres 70 /bin/bash /var/lib/postgresql postgres -} - -src_prepare() { - epatch "${WORKDIR}/autoconf.patch" \ - "${WORKDIR}/bool.patch" \ - "${WORKDIR}/darwin.patch" \ - "${WORKDIR}/pg_ctl-exit-status.patch" \ - "${WORKDIR}/server.patch" \ - "${WORKDIR}/SuperH.patch" - - eprefixify src/include/pg_config_manual.h - - if use test ; then - epatch "${WORKDIR}/regress.patch" - sed -e "s|@SOCKETDIR@|${T}|g" -i src/test/regress/pg_regress{,_main}.c - sed -e "s|/no/such/location|${S}/src/test/regress/tmp_check/no/such/location|g" \ - -i src/test/regress/{input,output}/tablespace.source - else - echo "all install:" > "${S}/src/test/regress/GNUmakefile" - fi - - sed -e "s|@RUNDIR@|${RUNDIR}|g" \ - -i src/include/pg_config_manual.h "${WORKDIR}/postgresql.init" || \ - die "RUNDIR sed failed" - sed -e "s|@SLOT@|${SLOT}|g" \ - -i "${WORKDIR}/postgresql.init" "${WORKDIR}/postgresql.confd" || \ - die "SLOT sed failed" - - eautoconf -} - -src_configure() { - # eval is needed to get along with pg_config quotation of space-rich entities. - eval econf "$(${EPREFIX%/}/usr/$(get_libdir)/postgresql-${SLOT}/bin/pg_config --configure)" \ - --with-includes="${EPREFIX%/}/usr/include/postgresql-${SLOT}/" \ - --with-system-tzdata="${EPREFIX%/}/usr/share/zoneinfo" \ - $(use_with perl) \ - $(use_with python) \ - $(use_with tcl) \ - $(use_with xml libxml) \ - $(use_with xml libxslt) \ - $(use_with uuid ossp-uuid) \ - "$(has_version ~dev-db/postgresql-base-${PV}[nls] && use_enable nls nls "$(wanted_languages)")" -} - -src_compile() { - local bd - for bd in . contrib $(use xml && echo contrib/xml2); do - PATH="${EROOT%/}/usr/$(get_libdir)/postgresql-${SLOT}/bin:${PATH}" \ - emake -C $bd -j1 \ - PGXS=$(${EROOT%/}/usr/$(get_libdir)/postgresql-${SLOT}/bin/pg_config --pgxs) \ - PGXS_IN_SERVER=1 PGXS_WITH_SERVER="${S}/src/backend/postgres" \ - NO_PGXS=0 USE_PGXS=1 docdir=${EROOT%/}/usr/share/doc/${PF} - done -} - -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 - - local bd - for bd in . contrib $(use xml && echo contrib/xml2) ; do - PATH="${EROOT%/}/usr/$(get_libdir)/postgresql-${SLOT}/bin:${PATH}" \ - emake install -C $bd -j1 DESTDIR="${D}" \ - PGXS_IN_SERVER=1 PGXS_WITH_SERVER="${S}/src/backend/postgres" \ - PGXS=$(${EROOT%/}/usr/$(get_libdir)/postgresql-${SLOT}/bin/pg_config --pgxs) \ - NO_PGXS=0 USE_PGXS=1 docdir=${EROOT%/}/usr/share/doc/${PF} - done - - rm -r "${ED}/usr/share/postgresql-${SLOT}/man/man7/" \ - "${ED}/usr/share/doc/${PF}/html" - rm "${ED}"/usr/share/postgresql-${SLOT}/man/man1/{clusterdb,create{db,lang,user},drop{db,lang,user},ecpg,pg_{config,dump,dumpall,restore},psql,reindexdb,vacuumdb}.1 - docompress /usr/share/postgresql-${SLOT}/man/man1 - - dodoc README HISTORY doc/{README.*,TODO,bug.template} - - dodir /etc/eselect/postgresql/slots/${SLOT} - echo "postgres_ebuilds=\"\${postgres_ebuilds} ${PF}\"" \ - > "${ED}/etc/eselect/postgresql/slots/${SLOT}/server" - - newconfd "${WORKDIR}/postgresql.confd" postgresql-${SLOT} - newinitd "${WORKDIR}/postgresql.init" postgresql-${SLOT} - - use pam && pamd_mimic system-auth postgresql auth account session - - if use prefix ; then - keepdir ${RUNDIR}/run/postgresql - fperms 0770 ${RUNDIR}/run/postgresql - fi -} - -pkg_postinst() { - postgresql-config update - - elog "Gentoo specific documentation:" - elog "http://www.gentoo.org/doc/en/postgres-howto.xml" - elog - elog "Official documentation:" - elog "http://www.postgresql.org/docs/${SLOT}/static/index.html" - elog - elog "The default location of the Unix-domain socket is:" - elog " ${EROOT%/}${RUNDIR}/run/postgresql/" - elog - elog "If you have users and/or services that you would like to utilize the" - elog "socket, you must add them to the 'postgres' system group:" - elog " usermod -a -G postgres <user>" - elog - elog "Before initializing the database, you may want to edit PG_INITDB_OPTS" - elog "so that it contains your preferred locale in:" - elog " ${EROOT%/}/etc/conf.d/postgresql-${SLOT}" - elog - elog "Then, execute the following command to setup the initial database" - elog "environment:" - elog " emerge --config =${CATEGORY}/${PF}" -} - -pkg_postrm() { - postgresql-config update -} - -pkg_config() { - [[ -f ${EROOT%/}/etc/conf.d/postgresql-${SLOT} ]] && source "${EROOT%/}/etc/conf.d/postgresql-${SLOT}" - [[ -z ${PGDATA} ]] && PGDATA="${EROOT%/}/etc/postgresql-${SLOT}/" - [[ -z ${DATA_DIR} ]] && DATA_DIR="${EROOT%/}/var/lib/postgresql/${SLOT}/data" - - # environment.bz2 may not contain the same locale as the current system - # locale. Unset and source from the current system locale. - if [[ -f ${EROOT%/}/etc/env.d/02locale ]] ; then - unset LANG - unset LC_CTYPE - unset LC_NUMERIC - unset LC_TIME - unset LC_COLLATE - unset LC_MONETARY - unset LC_MESSAGES - unset LC_ALL - source ${EROOT%/}/etc/env.d/02locale - [[ -n ${LANG} ]] && export LANG - [[ -n ${LC_CTYPE} ]] && export LC_CTYPE - [[ -n ${LC_NUMERIC} ]] && export LC_NUMERIC - [[ -n ${LC_TIME} ]] && export LC_TIME - [[ -n ${LC_COLLATE} ]] && export LC_COLLATE - [[ -n ${LC_MONETARY} ]] && export LC_MONETARY - [[ -n ${LC_MESSAGES} ]] && export LC_MESSAGES - [[ -n ${LC_ALL} ]] && export LC_ALL - fi - - einfo "You can modify the paths and options passed to initdb by editing:" - einfo " ${EROOT%/}/etc/conf.d/postgresql-${SLOT}" - einfo - einfo "Information on options that can be passed to initdb are found at:" - einfo " http://www.postgresql.org/docs/${SLOT}/static/creating-cluster.html" - einfo " http://www.postgresql.org/docs/${SLOT}/static/app-initdb.html" - einfo - einfo "PG_INITDB_OPTS is currently set to:" - if [[ -z ${PG_INITDB_OPTS} ]] ; then - einfo " (none)" - else - einfo " ${PG_INITDB_OPTS}" - fi - einfo - einfo "Configuration files will be installed to:" - einfo " ${PGDATA}" - einfo - einfo "The database cluster will be created in:" - einfo " ${DATA_DIR}" - einfo - while [[ $correct != "true" ]] ; do - einfo "Are you ready to continue? (y/n)" - read answer - if [[ $answer =~ ^[Yy]([Ee][Ss])?$ ]] ; then - correct="true" - elif [[ $answer =~ ^[Nn]([Oo])?$ ]] ; then - die "Aborting initialization." - else - echo "Answer not recognized." - fi - done - - if [[ -n "$(ls -A ${DATA_DIR} 2> /dev/null)" ]] ; then - eerror "The given directory, '${DATA_DIR}', is not empty." - eerror "Modify DATA_DIR to point to an empty directory." - die "${DATA_DIR} is not empty." - fi - - [[ -z ${PG_MAX_CONNECTIONS} ]] && PG_MAX_CONNECTIONS=128 - einfo "Checking system parameters..." - - if ! use kernel_linux ; then - einfo "Skipped." - einfo "Tests not supported on this OS (yet)." - else - if [[ -z ${SKIP_SYSTEM_TESTS} ]] ; then - ebegin "Checking whether your system supports at least ${PG_MAX_CONNECTIONS} connections" - - local SEMMSL=$(sysctl -n kernel.sem | cut -f1) - local SEMMNS=$(sysctl -n kernel.sem | cut -f2) - local SEMMNI=$(sysctl -n kernel.sem | cut -f4) - local SHMMAX=$(sysctl -n kernel.shmmax) - - local SEMMSL_MIN=17 - local SEMMNS_MIN=$(( ( ${PG_MAX_CONNECTIONS}/16 ) * 17 )) - local SEMMNI_MIN=$(( ( ${PG_MAX_CONNECTIONS}+15 ) / 16 )) - local SHMMAX_MIN=$(( 500000 + ( 30600 * ${PG_MAX_CONNECTIONS} ) )) - - for p in SEMMSL SEMMNS SEMMNI SHMMAX ; do - if [[ $(eval echo \$$p) -lt $(eval echo \$${p}_MIN) ]] ; then - eerror "The value for ${p} $(eval echo \$$p) is below the recommended value $(eval echo \$${p}_MIN)" - eerror "You have now several options:" - eerror " - Change the mentioned system parameter" - eerror " - Lower the number of max connections by setting PG_MAX_CONNECTIONS to a" - eerror " value lower than ${PG_MAX_CONNECTIONS}" - eerror " - Set SKIP_SYSTEM_TESTS in case you want to ignore this test completely" - eerror "More information can be found here:" - eerror " http://www.postgresql.org/docs/${SLOT}/static/kernel-resources.html" - die "System test failed." - fi - done - eend - else - ewarn "SKIP_SYSTEM_TESTS is set, so skipping." - fi - fi - - if [[ ${EUID} == 0 ]] ; then - einfo "Creating the data directory ..." - mkdir -p "${DATA_DIR}" - chown -Rf postgres:postgres "${DATA_DIR}" - chmod 0700 "${DATA_DIR}" - fi - - einfo "Initializing the database ..." - if [[ ${EUID} == 0 ]] ; then - su postgres -c "${EROOT%/}/usr/$(get_libdir)/postgresql-${SLOT}/bin/initdb -D \"${DATA_DIR}\" ${PG_INITDB_OPTS}" - else - "${EROOT%/}"/usr/$(get_libdir)/postgresql-${SLOT}/bin/initdb -U postgres -D "${DATA_DIR}" ${PG_INITDB_OPTS} - fi - mv "${DATA_DIR%/}"/*.conf "${PGDATA}" - - einfo "The autovacuum function, which was in contrib, has been moved to the main" - einfo "PostgreSQL functions starting with 8.1. You can enable it in the clusters" - einfo "postgresql.conf." - einfo - if use prefix ; then - einfo "The location of the configuration files have moved to:" - einfo " ${PGDATA}" - einfo - einfo "To start the server:" - einfo " pg_ctl start -D ${DATA_DIR} -o '-D ${PGDATA} --data-directory=${DATA_DIR}'" - einfo - einfo "To stop:" - einfo " pg_ctl stop -D ${DATA_DIR}" - einfo - einfo "Or move the configuration files back:" - einfo " mv ${PGDATA}*.conf ${DATA_DIR}" - else - einfo "You should use the '${EROOT%/}/etc/init.d/postgresql-${SLOT}' script to run PostgreSQL" - einfo "instead of 'pg_ctl'." - fi -} - -src_test() { - einfo ">>> Test phase [check]: ${CATEGORY}/${PF}" - - if [[ ${UID} != 0 ]] ; then - PATH="${EROOT%/}/usr/$(get_libdir)/postgresql-${SLOT}/bin/:${PATH}" \ - emake check \ - PGXS=$(${EROOT%/}/usr/$(get_libdir)/postgresql-${SLOT}/bin/pg_config --pgxs) \ - NO_PGXS=0 USE_PGXS=1 SLOT=${SLOT} - - einfo "If you think other tests besides the regression tests are necessary, please" - einfo "submit a bug including a patch for this ebuild to enable them." - else - ewarn "Tests cannot be run as root. Skipping." - ewarn "HINT: FEATURES=\"userpriv\"" - fi -} diff --git a/dev-db/postgresql-server/postgresql-server-8.3.17.ebuild b/dev-db/postgresql-server/postgresql-server-8.3.17.ebuild deleted file mode 100644 index c33e91c77863..000000000000 --- a/dev-db/postgresql-server/postgresql-server-8.3.17.ebuild +++ /dev/null @@ -1,339 +0,0 @@ -# Copyright 1999-2012 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/dev-db/postgresql-server/postgresql-server-8.3.17.ebuild,v 1.2 2012/01/30 19:51:21 ago Exp $ - -EAPI="4" - -WANT_AUTOMAKE="none" -inherit autotools eutils multilib pam prefix versionator - -SLOT="$(get_version_component_range 1-2)" - -KEYWORDS="~alpha amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~x86-fbsd" - -DESCRIPTION="PostgreSQL server" -HOMEPAGE="http://www.postgresql.org/" -SRC_URI="mirror://postgresql/source/v${PV}/postgresql-${PV}.tar.bz2 - http://dev.gentoo.org/~titanofold/postgresql-patches-8.3-r2.tbz2 - http://dev.gentoo.org/~titanofold/postgresql-initscript-2.0.tbz2" -LICENSE="POSTGRESQL" - -S="${WORKDIR}/postgresql-${PV}" - -LINGUAS="af cs de en es fa fr hr hu it ko nb pl pt_BR ro ru sk sl sv tr zh_CN zh_TW" -IUSE="doc kernel_linux nls pam perl python selinux tcl uuid xml" - -for lingua in ${LINGUAS} ; do - IUSE+=" linguas_${lingua}" -done - -wanted_languages() { - local enable_langs - - for lingua in ${LINGUAS} ; do - use linguas_${lingua} && enable_langs+="${lingua} " - done - - echo -n ${enable_langs} -} - -RDEPEND="~dev-db/postgresql-base-${PV}:${SLOT}[pam?,nls=] - perl? ( >=dev-lang/perl-5.8 ) - selinux? ( sec-policy/selinux-postgresql ) - tcl? ( >=dev-lang/tcl-8 ) - uuid? ( dev-libs/ossp-uuid ) - xml? ( dev-libs/libxml2 dev-libs/libxslt )" - -DEPEND="${RDEPEND} - sys-devel/flex - xml? ( dev-util/pkgconfig )" - -PDEPEND="doc? ( ~dev-db/postgresql-docs-${PV} )" - -# Support /var/run or /run for the socket directory -[[ ! -d /run ]] && RUNDIR=/var - -pkg_setup() { - enewgroup postgres 70 - enewuser postgres 70 /bin/bash /var/lib/postgresql postgres -} - -src_prepare() { - epatch "${WORKDIR}/autoconf.patch" \ - "${WORKDIR}/bool.patch" \ - "${WORKDIR}/darwin.patch" \ - "${WORKDIR}/pg_ctl-exit-status.patch" \ - "${WORKDIR}/server.patch" \ - "${WORKDIR}/SuperH.patch" - - eprefixify src/include/pg_config_manual.h - - if use test ; then - epatch "${WORKDIR}/regress.patch" - sed -e "s|@SOCKETDIR@|${T}|g" -i src/test/regress/pg_regress{,_main}.c - sed -e "s|/no/such/location|${S}/src/test/regress/tmp_check/no/such/location|g" \ - -i src/test/regress/{input,output}/tablespace.source - else - echo "all install:" > "${S}/src/test/regress/GNUmakefile" - fi - - sed -e "s|@RUNDIR@|${RUNDIR}|g" \ - -i src/include/pg_config_manual.h "${WORKDIR}/postgresql.init" || \ - die "RUNDIR sed failed" - sed -e "s|@SLOT@|${SLOT}|g" \ - -i "${WORKDIR}/postgresql.init" "${WORKDIR}/postgresql.confd" || \ - die "SLOT sed failed" - - eautoconf -} - -src_configure() { - # eval is needed to get along with pg_config quotation of space-rich entities. - eval econf "$(${EPREFIX%/}/usr/$(get_libdir)/postgresql-${SLOT}/bin/pg_config --configure)" \ - --with-includes="${EPREFIX%/}/usr/include/postgresql-${SLOT}/" \ - --with-system-tzdata="${EPREFIX%/}/usr/share/zoneinfo" \ - $(use_with perl) \ - $(use_with python) \ - $(use_with tcl) \ - $(use_with xml libxml) \ - $(use_with xml libxslt) \ - $(use_with uuid ossp-uuid) \ - "$(has_version ~dev-db/postgresql-base-${PV}[nls] && use_enable nls nls "$(wanted_languages)")" -} - -src_compile() { - local bd - for bd in . contrib $(use xml && echo contrib/xml2); do - PATH="${EROOT%/}/usr/$(get_libdir)/postgresql-${SLOT}/bin:${PATH}" \ - emake -C $bd -j1 \ - PGXS=$(${EROOT%/}/usr/$(get_libdir)/postgresql-${SLOT}/bin/pg_config --pgxs) \ - PGXS_IN_SERVER=1 PGXS_WITH_SERVER="${S}/src/backend/postgres" \ - NO_PGXS=0 USE_PGXS=1 docdir=${EROOT%/}/usr/share/doc/${PF} - done -} - -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 - - local bd - for bd in . contrib $(use xml && echo contrib/xml2) ; do - PATH="${EROOT%/}/usr/$(get_libdir)/postgresql-${SLOT}/bin:${PATH}" \ - emake install -C $bd -j1 DESTDIR="${D}" \ - PGXS_IN_SERVER=1 PGXS_WITH_SERVER="${S}/src/backend/postgres" \ - PGXS=$(${EROOT%/}/usr/$(get_libdir)/postgresql-${SLOT}/bin/pg_config --pgxs) \ - NO_PGXS=0 USE_PGXS=1 docdir=${EROOT%/}/usr/share/doc/${PF} - done - - rm -r "${ED}/usr/share/postgresql-${SLOT}/man/man7/" \ - "${ED}/usr/share/doc/${PF}/html" - rm "${ED}"/usr/share/postgresql-${SLOT}/man/man1/{clusterdb,create{db,lang,user},drop{db,lang,user},ecpg,pg_{config,dump,dumpall,restore},psql,reindexdb,vacuumdb}.1 - docompress /usr/share/postgresql-${SLOT}/man/man1 - - dodoc README HISTORY doc/{README.*,TODO,bug.template} - - dodir /etc/eselect/postgresql/slots/${SLOT} - echo "postgres_ebuilds=\"\${postgres_ebuilds} ${PF}\"" \ - > "${ED}/etc/eselect/postgresql/slots/${SLOT}/server" - - newconfd "${WORKDIR}/postgresql.confd" postgresql-${SLOT} - newinitd "${WORKDIR}/postgresql.init" postgresql-${SLOT} - - use pam && pamd_mimic system-auth postgresql auth account session - - if use prefix ; then - keepdir ${RUNDIR}/run/postgresql - fperms 0770 ${RUNDIR}/run/postgresql - fi -} - -pkg_postinst() { - postgresql-config update - - elog "Gentoo specific documentation:" - elog "http://www.gentoo.org/doc/en/postgres-howto.xml" - elog - elog "Official documentation:" - elog "http://www.postgresql.org/docs/${SLOT}/static/index.html" - elog - elog "The default location of the Unix-domain socket is:" - elog " ${EROOT%/}${RUNDIR}/run/postgresql/" - elog - elog "If you have users and/or services that you would like to utilize the" - elog "socket, you must add them to the 'postgres' system group:" - elog " usermod -a -G postgres <user>" - elog - elog "Before initializing the database, you may want to edit PG_INITDB_OPTS" - elog "so that it contains your preferred locale in:" - elog " ${EROOT%/}/etc/conf.d/postgresql-${SLOT}" - elog - elog "Then, execute the following command to setup the initial database" - elog "environment:" - elog " emerge --config =${CATEGORY}/${PF}" -} - -pkg_postrm() { - postgresql-config update -} - -pkg_config() { - [[ -f ${EROOT%/}/etc/conf.d/postgresql-${SLOT} ]] && source "${EROOT%/}/etc/conf.d/postgresql-${SLOT}" - [[ -z ${PGDATA} ]] && PGDATA="${EROOT%/}/etc/postgresql-${SLOT}/" - [[ -z ${DATA_DIR} ]] && DATA_DIR="${EROOT%/}/var/lib/postgresql/${SLOT}/data" - - # environment.bz2 may not contain the same locale as the current system - # locale. Unset and source from the current system locale. - if [[ -f ${EROOT%/}/etc/env.d/02locale ]] ; then - unset LANG - unset LC_CTYPE - unset LC_NUMERIC - unset LC_TIME - unset LC_COLLATE - unset LC_MONETARY - unset LC_MESSAGES - unset LC_ALL - source ${EROOT%/}/etc/env.d/02locale - [[ -n ${LANG} ]] && export LANG - [[ -n ${LC_CTYPE} ]] && export LC_CTYPE - [[ -n ${LC_NUMERIC} ]] && export LC_NUMERIC - [[ -n ${LC_TIME} ]] && export LC_TIME - [[ -n ${LC_COLLATE} ]] && export LC_COLLATE - [[ -n ${LC_MONETARY} ]] && export LC_MONETARY - [[ -n ${LC_MESSAGES} ]] && export LC_MESSAGES - [[ -n ${LC_ALL} ]] && export LC_ALL - fi - - einfo "You can modify the paths and options passed to initdb by editing:" - einfo " ${EROOT%/}/etc/conf.d/postgresql-${SLOT}" - einfo - einfo "Information on options that can be passed to initdb are found at:" - einfo " http://www.postgresql.org/docs/${SLOT}/static/creating-cluster.html" - einfo " http://www.postgresql.org/docs/${SLOT}/static/app-initdb.html" - einfo - einfo "PG_INITDB_OPTS is currently set to:" - if [[ -z ${PG_INITDB_OPTS} ]] ; then - einfo " (none)" - else - einfo " ${PG_INITDB_OPTS}" - fi - einfo - einfo "Configuration files will be installed to:" - einfo " ${PGDATA}" - einfo - einfo "The database cluster will be created in:" - einfo " ${DATA_DIR}" - einfo - while [[ $correct != "true" ]] ; do - einfo "Are you ready to continue? (y/n)" - read answer - if [[ $answer =~ ^[Yy]([Ee][Ss])?$ ]] ; then - correct="true" - elif [[ $answer =~ ^[Nn]([Oo])?$ ]] ; then - die "Aborting initialization." - else - echo "Answer not recognized." - fi - done - - if [[ -n "$(ls -A ${DATA_DIR} 2> /dev/null)" ]] ; then - eerror "The given directory, '${DATA_DIR}', is not empty." - eerror "Modify DATA_DIR to point to an empty directory." - die "${DATA_DIR} is not empty." - fi - - [[ -z ${PG_MAX_CONNECTIONS} ]] && PG_MAX_CONNECTIONS=128 - einfo "Checking system parameters..." - - if ! use kernel_linux ; then - einfo "Skipped." - einfo "Tests not supported on this OS (yet)." - else - if [[ -z ${SKIP_SYSTEM_TESTS} ]] ; then - ebegin "Checking whether your system supports at least ${PG_MAX_CONNECTIONS} connections" - - local SEMMSL=$(sysctl -n kernel.sem | cut -f1) - local SEMMNS=$(sysctl -n kernel.sem | cut -f2) - local SEMMNI=$(sysctl -n kernel.sem | cut -f4) - local SHMMAX=$(sysctl -n kernel.shmmax) - - local SEMMSL_MIN=17 - local SEMMNS_MIN=$(( ( ${PG_MAX_CONNECTIONS}/16 ) * 17 )) - local SEMMNI_MIN=$(( ( ${PG_MAX_CONNECTIONS}+15 ) / 16 )) - local SHMMAX_MIN=$(( 500000 + ( 30600 * ${PG_MAX_CONNECTIONS} ) )) - - for p in SEMMSL SEMMNS SEMMNI SHMMAX ; do - if [[ $(eval echo \$$p) -lt $(eval echo \$${p}_MIN) ]] ; then - eerror "The value for ${p} $(eval echo \$$p) is below the recommended value $(eval echo \$${p}_MIN)" - eerror "You have now several options:" - eerror " - Change the mentioned system parameter" - eerror " - Lower the number of max connections by setting PG_MAX_CONNECTIONS to a" - eerror " value lower than ${PG_MAX_CONNECTIONS}" - eerror " - Set SKIP_SYSTEM_TESTS in case you want to ignore this test completely" - eerror "More information can be found here:" - eerror " http://www.postgresql.org/docs/${SLOT}/static/kernel-resources.html" - die "System test failed." - fi - done - eend - else - ewarn "SKIP_SYSTEM_TESTS is set, so skipping." - fi - fi - - if [[ ${EUID} == 0 ]] ; then - einfo "Creating the data directory ..." - mkdir -p "${DATA_DIR}" - chown -Rf postgres:postgres "${DATA_DIR}" - chmod 0700 "${DATA_DIR}" - fi - - einfo "Initializing the database ..." - if [[ ${EUID} == 0 ]] ; then - su postgres -c "${EROOT%/}/usr/$(get_libdir)/postgresql-${SLOT}/bin/initdb -D \"${DATA_DIR}\" ${PG_INITDB_OPTS}" - else - "${EROOT%/}"/usr/$(get_libdir)/postgresql-${SLOT}/bin/initdb -U postgres -D "${DATA_DIR}" ${PG_INITDB_OPTS} - fi - mv "${DATA_DIR%/}"/*.conf "${PGDATA}" - - einfo "The autovacuum function, which was in contrib, has been moved to the main" - einfo "PostgreSQL functions starting with 8.1. You can enable it in the clusters" - einfo "postgresql.conf." - einfo - if use prefix ; then - einfo "The location of the configuration files have moved to:" - einfo " ${PGDATA}" - einfo - einfo "To start the server:" - einfo " pg_ctl start -D ${DATA_DIR} -o '-D ${PGDATA} --data-directory=${DATA_DIR}'" - einfo - einfo "To stop:" - einfo " pg_ctl stop -D ${DATA_DIR}" - einfo - einfo "Or move the configuration files back:" - einfo " mv ${PGDATA}*.conf ${DATA_DIR}" - else - einfo "You should use the '${EROOT%/}/etc/init.d/postgresql-${SLOT}' script to run PostgreSQL" - einfo "instead of 'pg_ctl'." - fi -} - -src_test() { - einfo ">>> Test phase [check]: ${CATEGORY}/${PF}" - - if [[ ${UID} != 0 ]] ; then - PATH="${EROOT%/}/usr/$(get_libdir)/postgresql-${SLOT}/bin/:${PATH}" \ - emake check \ - PGXS=$(${EROOT%/}/usr/$(get_libdir)/postgresql-${SLOT}/bin/pg_config --pgxs) \ - NO_PGXS=0 USE_PGXS=1 SLOT=${SLOT} - - einfo "If you think other tests besides the regression tests are necessary, please" - einfo "submit a bug including a patch for this ebuild to enable them." - else - ewarn "Tests cannot be run as root. Skipping." - ewarn "HINT: FEATURES=\"userpriv\"" - fi -} diff --git a/dev-db/postgresql-server/postgresql-server-8.4.10-r1.ebuild b/dev-db/postgresql-server/postgresql-server-8.4.10-r1.ebuild deleted file mode 100644 index ee19588a7be4..000000000000 --- a/dev-db/postgresql-server/postgresql-server-8.4.10-r1.ebuild +++ /dev/null @@ -1,348 +0,0 @@ -# Copyright 1999-2012 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/dev-db/postgresql-server/postgresql-server-8.4.10-r1.ebuild,v 1.7 2012/02/19 12:11:11 klausman Exp $ - -EAPI="3" -PYTHON_DEPEND="python? 2" - -WANT_AUTOMAKE="none" -inherit autotools eutils multilib pam prefix python versionator - -SLOT="$(get_version_component_range 1-2)" - -KEYWORDS="alpha amd64 arm hppa ~ia64 ~mips ppc ~ppc64 ~s390 ~sh ~sparc x86 ~x86-fbsd" - -DESCRIPTION="PostgreSQL server" -HOMEPAGE="http://www.postgresql.org/" -SRC_URI="mirror://postgresql/source/v${PV}/postgresql-${PV}.tar.bz2 - http://dev.gentoo.org/~titanofold/postgresql-patches-8.4-r2.tbz2 - http://dev.gentoo.org/~titanofold/postgresql-initscript-2.1.tbz2" -LICENSE="POSTGRESQL" - -S="${WORKDIR}/postgresql-${PV}" - -LINGUAS="af cs de en es fa fr hr hu it ko nb pl pt_BR ro ru sk sl sv tr zh_CN zh_TW" -IUSE="doc kernel_linux nls pam perl -pg_legacytimestamp python selinux tcl uuid xml" - -for lingua in ${LINGUAS} ; do - IUSE+=" linguas_${lingua}" -done - -wanted_languages() { - local enable_langs - - for lingua in ${LINGUAS} ; do - use linguas_${lingua} && enable_langs+="${lingua} " - done - - echo -n ${enable_langs} -} - -RDEPEND="~dev-db/postgresql-base-${PV}:${SLOT}[pam?,pg_legacytimestamp=,nls=] - perl? ( >=dev-lang/perl-5.8 ) - selinux? ( sec-policy/selinux-postgresql ) - tcl? ( >=dev-lang/tcl-8 ) - uuid? ( dev-libs/ossp-uuid ) - xml? ( dev-libs/libxml2 dev-libs/libxslt )" - -DEPEND="${RDEPEND} - sys-devel/flex - xml? ( dev-util/pkgconfig )" - -PDEPEND="doc? ( ~dev-db/postgresql-docs-${PV} )" - -# Support /var/run or /run for the socket directory -[[ ! -d /run ]] && RUNDIR=/var - -pkg_setup() { - enewgroup postgres 70 - enewuser postgres 70 /bin/bash /var/lib/postgresql postgres - - use python && python_set_active_version 2 -} - -src_prepare() { - epatch "${WORKDIR}/autoconf.patch" \ - "${WORKDIR}/bool.patch" \ - "${WORKDIR}/darwin.patch" \ - "${WORKDIR}/ldflags.patch" \ - "${WORKDIR}/pg_ctl-exit-status.patch" \ - "${WORKDIR}/server.patch" \ - "${WORKDIR}/SuperH.patch" - - eprefixify src/include/pg_config_manual.h - - if use test ; then - epatch "${WORKDIR}/regress.patch" - sed -e "s|@SOCKETDIR@|${T}|g" -i src/test/regress/pg_regress{,_main}.c - sed -e "s|/no/such/location|${S}/src/test/regress/tmp_check/no/such/location|g" \ - -i src/test/regress/{input,output}/tablespace.source - else - echo "all install:" > "${S}/src/test/regress/GNUmakefile" - fi - - sed -e "s|@RUNDIR@|${RUNDIR}|g" \ - -i src/include/pg_config_manual.h "${WORKDIR}/postgresql.init" || \ - die "RUNDIR sed failed" - sed -e "s|@SLOT@|${SLOT}|g" \ - -i "${WORKDIR}/postgresql.init" "${WORKDIR}/postgresql.confd" || \ - die "SLOT sed failed" - - eautoconf -} - -src_configure() { - # eval is needed to get along with pg_config quotation of space-rich entities. - eval econf "$(${EPREFIX%/}/usr/$(get_libdir)/postgresql-${SLOT}/bin/pg_config --configure)" \ - --with-includes="${EPREFIX%/}/usr/include/postgresql-${SLOT}/" \ - --with-libraries="${EPREFIX%/}/usr/$(get_libdir)/postgresql-${SLOT}/$(get_libdir)" \ - --with-system-tzdata="${EPREFIX%/}/usr/share/zoneinfo" \ - $(use_with perl) \ - $(use_with python) \ - $(use_with tcl) \ - $(use_with xml libxml) \ - $(use_with xml libxslt) \ - $(use_with uuid ossp-uuid) \ - "$(has_version ~dev-db/postgresql-base-${PV}[nls] && use_enable nls nls "$(wanted_languages)")" -} - -src_compile() { - local bd - for bd in . contrib $(use xml && echo contrib/xml2) ; do - PATH="${EROOT%/}/usr/$(get_libdir)/postgresql-${SLOT}/bin:${PATH}" \ - emake -C $bd -j1 || die "emake in $bd failed" - done -} - -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 - - local bd - for bd in . contrib $(use xml && echo contrib/xml2) ; do - PATH="${EROOT%/}/usr/$(get_libdir)/postgresql-${SLOT}/bin:${PATH}" \ - emake install -C $bd -j1 DESTDIR="${D}" \ - || die "emake install in $bd failed" - done - - rm -r "${ED}/usr/share/postgresql-${SLOT}/man/man7/" \ - "${ED}/usr/share/doc/postgresql-${SLOT}/html" - rm "${ED}"/usr/share/postgresql-${SLOT}/man/man1/{clusterdb,create{db,lang,user},drop{db,lang,user},ecpg,pg_{config,dump,dumpall,restore},psql,reindexdb,vacuumdb}.1 - - dodoc README HISTORY doc/{README.*,TODO,bug.template} - - dodir /etc/eselect/postgresql/slots/${SLOT} - echo "postgres_ebuilds=\"\${postgres_ebuilds} ${PF}\"" \ - > "${ED}/etc/eselect/postgresql/slots/${SLOT}/server" - - newconfd "${WORKDIR}"/postgresql.confd postgresql-${SLOT} \ - || die "Inserting conf.d file failed" - - newinitd "${WORKDIR}"/postgresql.init postgresql-${SLOT} \ - || die "Inserting init.d file failed" - - use pam && pamd_mimic system-auth postgresql auth account session - - if use prefix ; then - keepdir ${RUNDIR}/run/postgresql - fperms 0770 ${RUNDIR}/run/postgresql - fi -} - -pkg_postinst() { - postgresql-config update - - elog "The time stamp format is 64 bit integers now. If you upgrade from older" - elog "databases, this may force you to either do a dump and reload of enable" - elog "pg_legacytimestamp until you find time to do so. If the database can't start" - elog "please try enabling pg_legacytimestamp and rebuild." - elog - elog "Gentoo specific documentation:" - elog "http://www.gentoo.org/doc/en/postgres-howto.xml" - elog - elog "Official documentation:" - elog "http://www.postgresql.org/docs/${SLOT}/static/index.html" - elog - elog "The default location of the Unix-domain socket is:" - elog " ${EROOT%/}${RUNDIR}/run/postgresql/" - elog - elog "If you have users and/or services that you would like to utilize the" - elog "socket, you must add them to the 'postgres' system group:" - elog " usermod -a -G postgres <user>" - elog - elog "Before initializing the database, you may want to edit PG_INITDB_OPTS" - elog "so that it contains your preferred locale in:" - elog " ${EROOT%/}/etc/conf.d/postgresql-${SLOT}" - elog - elog "Then, execute the following command to setup the initial database" - elog "environment:" - elog " emerge --config =${CATEGORY}/${PF}" -} - -pkg_postrm() { - postgresql-config update -} - -pkg_config() { - [[ -f ${EROOT%/}/etc/conf.d/postgresql-${SLOT} ]] && source "${EROOT%/}/etc/conf.d/postgresql-${SLOT}" - [[ -z ${PGDATA} ]] && PGDATA="${EROOT%/}/etc/postgresql-${SLOT}/" - [[ -z ${DATA_DIR} ]] && DATA_DIR="${EROOT%/}/var/lib/postgresql/${SLOT}/data" - - # environment.bz2 may not contain the same locale as the current system - # locale. Unset and source from the current system locale. - if [[ -f ${EROOT%/}/etc/env.d/02locale ]] ; then - unset LANG - unset LC_CTYPE - unset LC_NUMERIC - unset LC_TIME - unset LC_COLLATE - unset LC_MONETARY - unset LC_MESSAGES - unset LC_ALL - source "${EROOT%/}/etc/env.d/02locale" - [[ -n ${LANG} ]] && export LANG - [[ -n ${LC_CTYPE} ]] && export LC_CTYPE - [[ -n ${LC_NUMERIC} ]] && export LC_NUMERIC - [[ -n ${LC_TIME} ]] && export LC_TIME - [[ -n ${LC_COLLATE} ]] && export LC_COLLATE - [[ -n ${LC_MONETARY} ]] && export LC_MONETARY - [[ -n ${LC_MESSAGES} ]] && export LC_MESSAGES - [[ -n ${LC_ALL} ]] && export LC_ALL - fi - - einfo "You can modify the paths and options passed to initdb by editing:" - einfo " ${EROOT%/}/etc/conf.d/postgresql-${SLOT}" - einfo - einfo "Information on options that can be passed to initdb are found at:" - einfo " http://www.postgresql.org/docs/${SLOT}/static/creating-cluster.html" - einfo " http://www.postgresql.org/docs/${SLOT}/static/app-initdb.html" - einfo - einfo "PG_INITDB_OPTS is currently set to:" - if [[ -z ${PG_INITDB_OPTS} ]] ; then - einfo " (none)" - else - einfo " ${PG_INITDB_OPTS}" - fi - einfo - einfo "Configuration files will be installed to:" - einfo " ${PGDATA}" - einfo - einfo "The database cluster will be created in:" - einfo " ${DATA_DIR}" - einfo - while [[ $correct != "true" ]] ; do - einfo "Are you ready to continue? (y/n)" - read answer - if [[ $answer =~ ^[Yy]([Ee][Ss])?$ ]] ; then - correct="true" - elif [[ $answer =~ ^[Nn]([Oo])?$ ]] ; then - die "Aborting initialization." - else - echo "Answer not recognized" - fi - done - - if [[ -n "$(ls -A ${DATA_DIR} 2> /dev/null)" ]] ; then - eerror "The given directory, '${DATA_DIR}', is not empty." - eerror "Modify DATA_DIR to point to an empty directory." - die "${DATA_DIR} is not empty." - fi - - [[ -z ${PG_MAX_CONNECTIONS} ]] && PG_MAX_CONNECTIONS=128 - einfo "Checking system parameters..." - - if ! use kernel_linux ; then - einfo "Skipped." - einfo " Tests not supported on this OS (yet)" - else - if [[ -z ${SKIP_SYSTEM_TESTS} ]] ; then - einfo "Checking whether your system supports at least ${PG_MAX_CONNECTIONS} connections..." - - local SEMMSL=$(sysctl -n kernel.sem | cut -f1) - local SEMMNS=$(sysctl -n kernel.sem | cut -f2) - local SEMMNI=$(sysctl -n kernel.sem | cut -f4) - local SHMMAX=$(sysctl -n kernel.shmmax) - - local SEMMSL_MIN=17 - local SEMMNS_MIN=$(( ( ${PG_MAX_CONNECTIONS}/16 ) * 17 )) - local SEMMNI_MIN=$(( ( ${PG_MAX_CONNECTIONS}+15 ) / 16 )) - local SHMMAX_MIN=$(( 500000 + ( 30600 * ${PG_MAX_CONNECTIONS} ) )) - - for p in SEMMSL SEMMNS SEMMNI SHMMAX ; do - if [[ $(eval echo \$$p) -lt $(eval echo \$${p}_MIN) ]] ; then - eerror "The value for ${p} $(eval echo \$$p) is below the recommended value $(eval echo \$${p}_MIN)" - eerror "You have now several options:" - eerror " - Change the mentioned system parameter" - eerror " - Lower the number of max.connections by setting PG_MAX_CONNECTIONS to a" - eerror " value lower than ${PG_MAX_CONNECTIONS}" - eerror " - Set SKIP_SYSTEM_TESTS in case you want to ignore this test completely" - eerror "More information can be found here:" - eerror " http://www.postgresql.org/docs/${SLOT}/static/kernel-resources.html" - die "System test failed." - fi - done - einfo "Passed." - else - ewarn "SKIP_SYSTEM_TESTS set, so skipping." - fi - fi - - if [[ ${EUID} == 0 ]] ; then - einfo "Creating the data directory ..." - mkdir -p "${DATA_DIR}" - chown -Rf postgres:postgres "${DATA_DIR}" - chmod 0700 "${DATA_DIR}" - fi - - einfo "Initializing the database ..." - if [[ ${EUID} == 0 ]] ; then - su postgres -c "${EROOT%/}/usr/$(get_libdir)/postgresql-${SLOT}/bin/initdb -D \"${DATA_DIR}\" ${PG_INITDB_OPTS}" - else - "${EROOT%/}"/usr/$(get_libdir)/postgresql-${SLOT}/bin/initdb -U postgres -D "${DATA_DIR}" ${PG_INITDB_OPTS} - fi - mv "${DATA_DIR%/}"/*.conf "${PGDATA}" - - einfo "The autovacuum function, which was in contrib, has been moved to the main" - einfo "PostgreSQL functions starting with 8.1, and starting with 8.4 is now enabled by" - einfo "default. You can disable it in the cluster's:" - einfo " ${PGDATA%/}/postgresql.conf" - einfo - einfo "The PostgreSQL server, by default, will log events to:" - einfo " ${DATA_DIR%/}/postmaster.log" - einfo - if use prefix ; then - einfo "The location of the configuration files have moved to:" - einfo " ${PGDATA}" - einfo - einfo "To start the server:" - einfo " pg_ctl start -D ${DATA_DIR} -o '-D ${PGDATA} --data-directory=${DATA_DIR}'" - einfo - einfo "To stop:" - einfo " pg_ctl stop -D ${DATA_DIR}" - einfo - einfo "Or move the configuration files back:" - einfo " mv ${PGDATA}*.conf ${DATA_DIR}" - else - einfo "You should use the '${EROOT%/}/etc/init.d/postgresql-${SLOT}' script to run PostgreSQL" - einfo "instead of 'pg_ctl'." - fi -} - -src_test() { - einfo ">>> Test phase [check]: ${CATEGORY}/${PF}" - - if [[ ${UID} != 0 ]] ; then - emake check || die "Make check failed. See above for details." - - einfo "If you think other tests besides the regression tests are necessary, please" - einfo "submit a bug including a patch for this ebuild to enable them." - else - ewarn "Tests cannot be run as root. Skipping." - ewarn "HINT: FEATURES=\"userpriv\"" - fi -} diff --git a/dev-db/postgresql-server/postgresql-server-8.4.10.ebuild b/dev-db/postgresql-server/postgresql-server-8.4.10.ebuild deleted file mode 100644 index 87b34de7ea05..000000000000 --- a/dev-db/postgresql-server/postgresql-server-8.4.10.ebuild +++ /dev/null @@ -1,348 +0,0 @@ -# Copyright 1999-2012 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/dev-db/postgresql-server/postgresql-server-8.4.10.ebuild,v 1.2 2012/01/30 19:51:21 ago Exp $ - -EAPI="3" -PYTHON_DEPEND="python? 2" - -WANT_AUTOMAKE="none" -inherit autotools eutils multilib pam prefix python versionator - -SLOT="$(get_version_component_range 1-2)" - -KEYWORDS="~alpha amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~x86-fbsd" - -DESCRIPTION="PostgreSQL server" -HOMEPAGE="http://www.postgresql.org/" -SRC_URI="mirror://postgresql/source/v${PV}/postgresql-${PV}.tar.bz2 - http://dev.gentoo.org/~titanofold/postgresql-patches-8.4-r2.tbz2 - http://dev.gentoo.org/~titanofold/postgresql-initscript-2.0.tbz2" -LICENSE="POSTGRESQL" - -S="${WORKDIR}/postgresql-${PV}" - -LINGUAS="af cs de en es fa fr hr hu it ko nb pl pt_BR ro ru sk sl sv tr zh_CN zh_TW" -IUSE="doc kernel_linux nls pam perl -pg_legacytimestamp python selinux tcl uuid xml" - -for lingua in ${LINGUAS} ; do - IUSE+=" linguas_${lingua}" -done - -wanted_languages() { - local enable_langs - - for lingua in ${LINGUAS} ; do - use linguas_${lingua} && enable_langs+="${lingua} " - done - - echo -n ${enable_langs} -} - -RDEPEND="~dev-db/postgresql-base-${PV}:${SLOT}[pam?,pg_legacytimestamp=,nls=] - perl? ( >=dev-lang/perl-5.8 ) - selinux? ( sec-policy/selinux-postgresql ) - tcl? ( >=dev-lang/tcl-8 ) - uuid? ( dev-libs/ossp-uuid ) - xml? ( dev-libs/libxml2 dev-libs/libxslt )" - -DEPEND="${RDEPEND} - sys-devel/flex - xml? ( dev-util/pkgconfig )" - -PDEPEND="doc? ( ~dev-db/postgresql-docs-${PV} )" - -# Support /var/run or /run for the socket directory -[[ ! -d /run ]] && RUNDIR=/var - -pkg_setup() { - enewgroup postgres 70 - enewuser postgres 70 /bin/bash /var/lib/postgresql postgres - - use python && python_set_active_version 2 -} - -src_prepare() { - epatch "${WORKDIR}/autoconf.patch" \ - "${WORKDIR}/bool.patch" \ - "${WORKDIR}/darwin.patch" \ - "${WORKDIR}/ldflags.patch" \ - "${WORKDIR}/pg_ctl-exit-status.patch" \ - "${WORKDIR}/server.patch" \ - "${WORKDIR}/SuperH.patch" - - eprefixify src/include/pg_config_manual.h - - if use test ; then - epatch "${WORKDIR}/regress.patch" - sed -e "s|@SOCKETDIR@|${T}|g" -i src/test/regress/pg_regress{,_main}.c - sed -e "s|/no/such/location|${S}/src/test/regress/tmp_check/no/such/location|g" \ - -i src/test/regress/{input,output}/tablespace.source - else - echo "all install:" > "${S}/src/test/regress/GNUmakefile" - fi - - sed -e "s|@RUNDIR@|${RUNDIR}|g" \ - -i src/include/pg_config_manual.h "${WORKDIR}/postgresql.init" || \ - die "RUNDIR sed failed" - sed -e "s|@SLOT@|${SLOT}|g" \ - -i "${WORKDIR}/postgresql.init" "${WORKDIR}/postgresql.confd" || \ - die "SLOT sed failed" - - eautoconf -} - -src_configure() { - # eval is needed to get along with pg_config quotation of space-rich entities. - eval econf "$(${EPREFIX%/}/usr/$(get_libdir)/postgresql-${SLOT}/bin/pg_config --configure)" \ - --with-includes="${EPREFIX%/}/usr/include/postgresql-${SLOT}/" \ - --with-libraries="${EPREFIX%/}/usr/$(get_libdir)/postgresql-${SLOT}/$(get_libdir)" \ - --with-system-tzdata="${EPREFIX%/}/usr/share/zoneinfo" \ - $(use_with perl) \ - $(use_with python) \ - $(use_with tcl) \ - $(use_with xml libxml) \ - $(use_with xml libxslt) \ - $(use_with uuid ossp-uuid) \ - "$(has_version ~dev-db/postgresql-base-${PV}[nls] && use_enable nls nls "$(wanted_languages)")" -} - -src_compile() { - local bd - for bd in . contrib $(use xml && echo contrib/xml2) ; do - PATH="${EROOT%/}/usr/$(get_libdir)/postgresql-${SLOT}/bin:${PATH}" \ - emake -C $bd -j1 || die "emake in $bd failed" - done -} - -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 - - local bd - for bd in . contrib $(use xml && echo contrib/xml2) ; do - PATH="${EROOT%/}/usr/$(get_libdir)/postgresql-${SLOT}/bin:${PATH}" \ - emake install -C $bd -j1 DESTDIR="${D}" \ - || die "emake install in $bd failed" - done - - rm -r "${ED}/usr/share/postgresql-${SLOT}/man/man7/" \ - "${ED}/usr/share/doc/postgresql-${SLOT}/html" - rm "${ED}"/usr/share/postgresql-${SLOT}/man/man1/{clusterdb,create{db,lang,user},drop{db,lang,user},ecpg,pg_{config,dump,dumpall,restore},psql,reindexdb,vacuumdb}.1 - - dodoc README HISTORY doc/{README.*,TODO,bug.template} - - dodir /etc/eselect/postgresql/slots/${SLOT} - echo "postgres_ebuilds=\"\${postgres_ebuilds} ${PF}\"" \ - > "${ED}/etc/eselect/postgresql/slots/${SLOT}/server" - - newconfd "${WORKDIR}"/postgresql.confd postgresql-${SLOT} \ - || die "Inserting conf.d file failed" - - newinitd "${WORKDIR}"/postgresql.init postgresql-${SLOT} \ - || die "Inserting init.d file failed" - - use pam && pamd_mimic system-auth postgresql auth account session - - if use prefix ; then - keepdir ${RUNDIR}/run/postgresql - fperms 0770 ${RUNDIR}/run/postgresql - fi -} - -pkg_postinst() { - postgresql-config update - - elog "The time stamp format is 64 bit integers now. If you upgrade from older" - elog "databases, this may force you to either do a dump and reload of enable" - elog "pg_legacytimestamp until you find time to do so. If the database can't start" - elog "please try enabling pg_legacytimestamp and rebuild." - elog - elog "Gentoo specific documentation:" - elog "http://www.gentoo.org/doc/en/postgres-howto.xml" - elog - elog "Official documentation:" - elog "http://www.postgresql.org/docs/${SLOT}/static/index.html" - elog - elog "The default location of the Unix-domain socket is:" - elog " ${EROOT%/}${RUNDIR}/run/postgresql/" - elog - elog "If you have users and/or services that you would like to utilize the" - elog "socket, you must add them to the 'postgres' system group:" - elog " usermod -a -G postgres <user>" - elog - elog "Before initializing the database, you may want to edit PG_INITDB_OPTS" - elog "so that it contains your preferred locale in:" - elog " ${EROOT%/}/etc/conf.d/postgresql-${SLOT}" - elog - elog "Then, execute the following command to setup the initial database" - elog "environment:" - elog " emerge --config =${CATEGORY}/${PF}" -} - -pkg_postrm() { - postgresql-config update -} - -pkg_config() { - [[ -f ${EROOT%/}/etc/conf.d/postgresql-${SLOT} ]] && source "${EROOT%/}/etc/conf.d/postgresql-${SLOT}" - [[ -z ${PGDATA} ]] && PGDATA="${EROOT%/}/etc/postgresql-${SLOT}/" - [[ -z ${DATA_DIR} ]] && DATA_DIR="${EROOT%/}/var/lib/postgresql/${SLOT}/data" - - # environment.bz2 may not contain the same locale as the current system - # locale. Unset and source from the current system locale. - if [[ -f ${EROOT%/}/etc/env.d/02locale ]] ; then - unset LANG - unset LC_CTYPE - unset LC_NUMERIC - unset LC_TIME - unset LC_COLLATE - unset LC_MONETARY - unset LC_MESSAGES - unset LC_ALL - source "${EROOT%/}/etc/env.d/02locale" - [[ -n ${LANG} ]] && export LANG - [[ -n ${LC_CTYPE} ]] && export LC_CTYPE - [[ -n ${LC_NUMERIC} ]] && export LC_NUMERIC - [[ -n ${LC_TIME} ]] && export LC_TIME - [[ -n ${LC_COLLATE} ]] && export LC_COLLATE - [[ -n ${LC_MONETARY} ]] && export LC_MONETARY - [[ -n ${LC_MESSAGES} ]] && export LC_MESSAGES - [[ -n ${LC_ALL} ]] && export LC_ALL - fi - - einfo "You can modify the paths and options passed to initdb by editing:" - einfo " ${EROOT%/}/etc/conf.d/postgresql-${SLOT}" - einfo - einfo "Information on options that can be passed to initdb are found at:" - einfo " http://www.postgresql.org/docs/${SLOT}/static/creating-cluster.html" - einfo " http://www.postgresql.org/docs/${SLOT}/static/app-initdb.html" - einfo - einfo "PG_INITDB_OPTS is currently set to:" - if [[ -z ${PG_INITDB_OPTS} ]] ; then - einfo " (none)" - else - einfo " ${PG_INITDB_OPTS}" - fi - einfo - einfo "Configuration files will be installed to:" - einfo " ${PGDATA}" - einfo - einfo "The database cluster will be created in:" - einfo " ${DATA_DIR}" - einfo - while [[ $correct != "true" ]] ; do - einfo "Are you ready to continue? (y/n)" - read answer - if [[ $answer =~ ^[Yy]([Ee][Ss])?$ ]] ; then - correct="true" - elif [[ $answer =~ ^[Nn]([Oo])?$ ]] ; then - die "Aborting initialization." - else - echo "Answer not recognized" - fi - done - - if [[ -n "$(ls -A ${DATA_DIR} 2> /dev/null)" ]] ; then - eerror "The given directory, '${DATA_DIR}', is not empty." - eerror "Modify DATA_DIR to point to an empty directory." - die "${DATA_DIR} is not empty." - fi - - [[ -z ${PG_MAX_CONNECTIONS} ]] && PG_MAX_CONNECTIONS=128 - einfo "Checking system parameters..." - - if ! use kernel_linux ; then - einfo "Skipped." - einfo " Tests not supported on this OS (yet)" - else - if [[ -z ${SKIP_SYSTEM_TESTS} ]] ; then - einfo "Checking whether your system supports at least ${PG_MAX_CONNECTIONS} connections..." - - local SEMMSL=$(sysctl -n kernel.sem | cut -f1) - local SEMMNS=$(sysctl -n kernel.sem | cut -f2) - local SEMMNI=$(sysctl -n kernel.sem | cut -f4) - local SHMMAX=$(sysctl -n kernel.shmmax) - - local SEMMSL_MIN=17 - local SEMMNS_MIN=$(( ( ${PG_MAX_CONNECTIONS}/16 ) * 17 )) - local SEMMNI_MIN=$(( ( ${PG_MAX_CONNECTIONS}+15 ) / 16 )) - local SHMMAX_MIN=$(( 500000 + ( 30600 * ${PG_MAX_CONNECTIONS} ) )) - - for p in SEMMSL SEMMNS SEMMNI SHMMAX ; do - if [[ $(eval echo \$$p) -lt $(eval echo \$${p}_MIN) ]] ; then - eerror "The value for ${p} $(eval echo \$$p) is below the recommended value $(eval echo \$${p}_MIN)" - eerror "You have now several options:" - eerror " - Change the mentioned system parameter" - eerror " - Lower the number of max.connections by setting PG_MAX_CONNECTIONS to a" - eerror " value lower than ${PG_MAX_CONNECTIONS}" - eerror " - Set SKIP_SYSTEM_TESTS in case you want to ignore this test completely" - eerror "More information can be found here:" - eerror " http://www.postgresql.org/docs/${SLOT}/static/kernel-resources.html" - die "System test failed." - fi - done - einfo "Passed." - else - ewarn "SKIP_SYSTEM_TESTS set, so skipping." - fi - fi - - if [[ ${EUID} == 0 ]] ; then - einfo "Creating the data directory ..." - mkdir -p "${DATA_DIR}" - chown -Rf postgres:postgres "${DATA_DIR}" - chmod 0700 "${DATA_DIR}" - fi - - einfo "Initializing the database ..." - if [[ ${EUID} == 0 ]] ; then - su postgres -c "${EROOT%/}/usr/$(get_libdir)/postgresql-${SLOT}/bin/initdb -D \"${DATA_DIR}\" ${PG_INITDB_OPTS}" - else - "${EROOT%/}"/usr/$(get_libdir)/postgresql-${SLOT}/bin/initdb -U postgres -D "${DATA_DIR}" ${PG_INITDB_OPTS} - fi - mv "${DATA_DIR%/}"/*.conf "${PGDATA}" - - einfo "The autovacuum function, which was in contrib, has been moved to the main" - einfo "PostgreSQL functions starting with 8.1, and starting with 8.4 is now enabled by" - einfo "default. You can disable it in the cluster's:" - einfo " ${PGDATA%/}/postgresql.conf" - einfo - einfo "The PostgreSQL server, by default, will log events to:" - einfo " ${DATA_DIR%/}/postmaster.log" - einfo - if use prefix ; then - einfo "The location of the configuration files have moved to:" - einfo " ${PGDATA}" - einfo - einfo "To start the server:" - einfo " pg_ctl start -D ${DATA_DIR} -o '-D ${PGDATA} --data-directory=${DATA_DIR}'" - einfo - einfo "To stop:" - einfo " pg_ctl stop -D ${DATA_DIR}" - einfo - einfo "Or move the configuration files back:" - einfo " mv ${PGDATA}*.conf ${DATA_DIR}" - else - einfo "You should use the '${EROOT%/}/etc/init.d/postgresql-${SLOT}' script to run PostgreSQL" - einfo "instead of 'pg_ctl'." - fi -} - -src_test() { - einfo ">>> Test phase [check]: ${CATEGORY}/${PF}" - - if [[ ${UID} != 0 ]] ; then - emake check || die "Make check failed. See above for details." - - einfo "If you think other tests besides the regression tests are necessary, please" - einfo "submit a bug including a patch for this ebuild to enable them." - else - ewarn "Tests cannot be run as root. Skipping." - ewarn "HINT: FEATURES=\"userpriv\"" - fi -} diff --git a/dev-db/postgresql-server/postgresql-server-8.4.9.ebuild b/dev-db/postgresql-server/postgresql-server-8.4.9.ebuild deleted file mode 100644 index b29eea8e8ecb..000000000000 --- a/dev-db/postgresql-server/postgresql-server-8.4.9.ebuild +++ /dev/null @@ -1,323 +0,0 @@ -# Copyright 1999-2011 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/dev-db/postgresql-server/postgresql-server-8.4.9.ebuild,v 1.6 2011/10/01 20:19:20 hwoarang Exp $ - -EAPI="3" -PYTHON_DEPEND="python? 2" - -WANT_AUTOMAKE="none" -inherit autotools eutils multilib pam prefix python versionator - -SLOT="$(get_version_component_range 1-2)" - -KEYWORDS="alpha amd64 arm hppa ia64 ~mips ppc ppc64 s390 sh sparc x86 ~x86-fbsd" - -DESCRIPTION="PostgreSQL server" -HOMEPAGE="http://www.postgresql.org/" -SRC_URI="mirror://postgresql/source/v${PV}/postgresql-${PV}.tar.bz2 - http://dev.gentoo.org/~titanofold/postgresql-patches-${SLOT}-r1.tbz2 - http://dev.gentoo.org/~titanofold/postgresql-initscript-1.2.tbz2" -LICENSE="POSTGRESQL" - -S="${WORKDIR}/postgresql-${PV}" - -LINGUAS="af cs de en es fa fr hr hu it ko nb pl pt_BR ro ru sk sl sv tr zh_CN zh_TW" -IUSE="doc kernel_linux nls pam perl -pg_legacytimestamp python selinux tcl uuid xml" - -for lingua in ${LINGUAS} ; do - IUSE+=" linguas_${lingua}" -done - -wanted_languages() { - local enable_langs - - for lingua in ${LINGUAS} ; do - use linguas_${lingua} && enable_langs+="${lingua} " - done - - echo -n ${enable_langs} -} - -RDEPEND="~dev-db/postgresql-base-${PV}:${SLOT}[pam?,pg_legacytimestamp=,nls=] - perl? ( >=dev-lang/perl-5.8 ) - selinux? ( sec-policy/selinux-postgresql ) - tcl? ( >=dev-lang/tcl-8 ) - uuid? ( dev-libs/ossp-uuid ) - xml? ( dev-libs/libxml2 dev-libs/libxslt )" - -DEPEND="${RDEPEND} - sys-devel/flex - xml? ( dev-util/pkgconfig )" - -PDEPEND="doc? ( ~dev-db/postgresql-docs-${PV} )" - -pkg_setup() { - enewgroup postgres 70 - enewuser postgres 70 /bin/bash /var/lib/postgresql postgres - - use python && python_set_active_version 2 -} - -src_prepare() { - epatch "${WORKDIR}/autoconf.patch" "${WORKDIR}/bool.patch" \ - "${WORKDIR}/darwin.patch" "${WORKDIR}/ldflags.patch" \ - "${WORKDIR}/pg_ctl-exit-status.patch" "${WORKDIR}/server.patch" \ - "${WORKDIR}/SuperH.patch" - - eprefixify src/include/pg_config_manual.h - - if use test ; then - epatch "${WORKDIR}/regress.patch" - sed -e "s|@SOCKETDIR@|${T}|g" -i src/test/regress/pg_regress{,_main}.c - sed -e "s|/no/such/location|${S}/src/test/regress/tmp_check/no/such/location|g" \ - -i src/test/regress/{input,output}/tablespace.source - else - echo "all install:" > "${S}/src/test/regress/GNUmakefile" - fi - - eautoconf -} - -src_configure() { - # eval is needed to get along with pg_config quotation of space-rich entities. - eval econf "$(${EPREFIX%/}/usr/$(get_libdir)/postgresql-${SLOT}/bin/pg_config --configure)" \ - --with-includes="${EPREFIX%/}/usr/include/postgresql-${SLOT}/" \ - --with-libraries="${EPREFIX%/}/usr/$(get_libdir)/postgresql-${SLOT}/$(get_libdir)" \ - --with-system-tzdata="${EPREFIX%/}/usr/share/zoneinfo" \ - $(use_with perl) \ - $(use_with python) \ - $(use_with tcl) \ - $(use_with xml libxml) \ - $(use_with xml libxslt) \ - $(use_with uuid ossp-uuid) \ - "$(has_version ~dev-db/postgresql-base-${PV}[nls] && use_enable nls nls "$(wanted_languages)")" -} - -src_compile() { - local bd - for bd in . contrib $(use xml && echo contrib/xml2) ; do - PATH="${EROOT%/}/usr/$(get_libdir)/postgresql-${SLOT}/bin:${PATH}" \ - emake -C $bd -j1 || die "emake in $bd failed" - done -} - -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 - - local bd - for bd in . contrib $(use xml && echo contrib/xml2) ; do - PATH="${EROOT%/}/usr/$(get_libdir)/postgresql-${SLOT}/bin:${PATH}" \ - emake install -C $bd -j1 DESTDIR="${D}" || die "emake install in $bd failed" - done - - rm -r "${ED}/usr/share/postgresql-${SLOT}/man/man7/" "${ED}/usr/share/doc/postgresql-${SLOT}/html" - rm "${ED}"/usr/share/postgresql-${SLOT}/man/man1/{clusterdb,create{db,lang,user},drop{db,lang,user},ecpg,pg_{config,dump,dumpall,restore},psql,reindexdb,vacuumdb}.1 - - dodoc README HISTORY doc/{README.*,TODO,bug.template} - - dodir /etc/eselect/postgresql/slots/${SLOT} - echo "postgres_ebuilds=\"\${postgres_ebuilds} ${PF}\"" \ - > "${ED}/etc/eselect/postgresql/slots/${SLOT}/server" - - sed -e "s/@SLOT@/${SLOT}/g" -i "${WORKDIR}"/postgresql.confd - newconfd "${WORKDIR}"/postgresql.confd postgresql-${SLOT} || die "Inserting conf.d file failed" - sed -e "s/@SLOT@/${SLOT}/g" -i "${WORKDIR}"/postgresql.init - newinitd "${WORKDIR}"/postgresql.init postgresql-${SLOT} || die "Inserting init.d file failed" - - use pam && pamd_mimic system-auth postgresql auth account session - - keepdir /var/run/postgresql - fperms 0770 /var/run/postgresql - use prefix || fowners postgres:postgres /var/run/postgresql -} - -pkg_postinst() { - postgresql-config update - - elog "The time stamp format is 64 bit integers now. If you upgrade from older" - elog "databases, this may force you to either do a dump and reload of enable" - elog "pg_legacytimestamp until you find time to do so. If the database can't start" - elog "please try enabling pg_legacytimestamp and rebuild." - elog - elog "The Unix-domain socket is located in:" - elog " ${EROOT%/}/var/run/postgresql/" - elog - elog "If you have users and/or services that you would like to utilize the socket," - elog "you must add them to the 'postgres' system group:" - elog " usermod -a -G postgres <user>" - elog - elog "Before initializing the database, you may want to edit PG_INITDB_OPTS so that" - elog "it contains your preferred locale and character encoding in:" - elog " ${EROOT%/}/etc/conf.d/postgresql-${SLOT}" - elog - elog "Then, execute the following command to setup the initial database" - elog "environment:" - elog " emerge --config =${CATEGORY}/${PF}" -} - -pkg_postrm() { - postgresql-config update -} - -pkg_config() { - [[ -f ${EROOT%/}/etc/conf.d/postgresql-${SLOT} ]] && source "${EROOT%/}/etc/conf.d/postgresql-${SLOT}" - [[ -z ${PGDATA} ]] && PGDATA="${EROOT%/}/etc/postgresql-${SLOT}/" - [[ -z ${DATA_DIR} ]] && DATA_DIR="${EROOT%/}/var/lib/postgresql/${SLOT}/data" - - # environment.bz2 may not contain the same locale as the current system - # locale. Unset and source from the current system locale. - if [[ -f ${EROOT%/}/etc/env.d/02locale ]] ; then - unset LANG - unset LC_CTYPE - unset LC_NUMERIC - unset LC_TIME - unset LC_COLLATE - unset LC_MONETARY - unset LC_MESSAGES - unset LC_ALL - source "${EROOT%/}/etc/env.d/02locale" - [[ -n ${LANG} ]] && export LANG - [[ -n ${LC_CTYPE} ]] && export LC_CTYPE - [[ -n ${LC_NUMERIC} ]] && export LC_NUMERIC - [[ -n ${LC_TIME} ]] && export LC_TIME - [[ -n ${LC_COLLATE} ]] && export LC_COLLATE - [[ -n ${LC_MONETARY} ]] && export LC_MONETARY - [[ -n ${LC_MESSAGES} ]] && export LC_MESSAGES - [[ -n ${LC_ALL} ]] && export LC_ALL - fi - - einfo "You can modify the paths and options passed to initdb by editing:" - einfo " ${EROOT%/}/etc/conf.d/postgresql-${SLOT}" - einfo - einfo "Information on options that can be passed to initdb are found at:" - einfo " http://www.postgresql.org/docs/${SLOT}/static/creating-cluster.html" - einfo " http://www.postgresql.org/docs/${SLOT}/static/app-initdb.html" - einfo - einfo "PG_INITDB_OPTS is currently set to:" - if [[ -z ${PG_INITDB_OPTS} ]] ; then - einfo " (none)" - else - einfo " ${PG_INITDB_OPTS}" - fi - einfo - einfo "Configuration files will be installed to:" - einfo " ${PGDATA}" - einfo - einfo "The database cluster will be created in:" - einfo " ${DATA_DIR}" - einfo - while [[ $correct != "true" ]] ; do - einfo "Are you ready to continue? (y/n)" - read answer - if [[ $answer =~ ^[Yy]([Ee][Ss])?$ ]] ; then - correct="true" - elif [[ $answer =~ ^[Nn]([Oo])?$ ]] ; then - die "Aborting initialization." - else - echo "Answer not recognized" - fi - done - - if [[ -n "$(ls -A ${DATA_DIR} 2> /dev/null)" ]] ; then - eerror "The given directory, '${DATA_DIR}', is not empty." - eerror "Modify DATA_DIR to point to an empty directory." - die "${DATA_DIR} is not empty." - fi - - [[ -z ${PG_MAX_CONNECTIONS} ]] && PG_MAX_CONNECTIONS=128 - einfo "Checking system parameters..." - - if ! use kernel_linux ; then - einfo "Skipped." - einfo " Tests not supported on this OS (yet)" - else - if [[ -z ${SKIP_SYSTEM_TESTS} ]] ; then - einfo "Checking whether your system supports at least ${PG_MAX_CONNECTIONS} connections..." - - local SEMMSL=$(sysctl -n kernel.sem | cut -f1) - local SEMMNS=$(sysctl -n kernel.sem | cut -f2) - local SEMMNI=$(sysctl -n kernel.sem | cut -f4) - local SHMMAX=$(sysctl -n kernel.shmmax) - - local SEMMSL_MIN=17 - local SEMMNS_MIN=$(( ( ${PG_MAX_CONNECTIONS}/16 ) * 17 )) - local SEMMNI_MIN=$(( ( ${PG_MAX_CONNECTIONS}+15 ) / 16 )) - local SHMMAX_MIN=$(( 500000 + ( 30600 * ${PG_MAX_CONNECTIONS} ) )) - - for p in SEMMSL SEMMNS SEMMNI SHMMAX ; do - if [[ $(eval echo \$$p) -lt $(eval echo \$${p}_MIN) ]] ; then - eerror "The value for ${p} $(eval echo \$$p) is below the recommended value $(eval echo \$${p}_MIN)" - eerror "You have now several options:" - eerror " - Change the mentioned system parameter" - eerror " - Lower the number of max.connections by setting PG_MAX_CONNECTIONS to a" - eerror " value lower than ${PG_MAX_CONNECTIONS}" - eerror " - Set SKIP_SYSTEM_TESTS in case you want to ignore this test completely" - eerror "More information can be found here:" - eerror " http://www.postgresql.org/docs/${SLOT}/static/kernel-resources.html" - die "System test failed." - fi - done - einfo "Passed." - else - ewarn "SKIP_SYSTEM_TESTS set, so skipping." - fi - fi - - if [[ ${EUID} == 0 ]] ; then - einfo "Creating the data directory ..." - mkdir -p "${DATA_DIR}" - chown -Rf postgres:postgres "${DATA_DIR}" - chmod 0700 "${DATA_DIR}" - fi - - einfo "Initializing the database ..." - if [[ ${EUID} == 0 ]] ; then - su postgres -c "${EROOT%/}/usr/$(get_libdir)/postgresql-${SLOT}/bin/initdb -D \"${DATA_DIR}\" ${PG_INITDB_OPTS}" - else - "${EROOT%/}"/usr/$(get_libdir)/postgresql-${SLOT}/bin/initdb -U postgres -D "${DATA_DIR}" ${PG_INITDB_OPTS} - fi - mv "${DATA_DIR%/}"/*.conf "${PGDATA}" - - einfo "The autovacuum function, which was in contrib, has been moved to the main" - einfo "PostgreSQL functions starting with 8.1, and starting with 8.4 is now enabled by" - einfo "default. You can disable it in the cluster's:" - einfo " ${PGDATA%/}/postgresql.conf" - einfo - einfo "The PostgreSQL server, by default, will log events to:" - einfo " ${DATA_DIR%/}/postmaster.log" - einfo - if use prefix ; then - einfo "The location of the configuration files have moved to:" - einfo " ${PGDATA}" - einfo - einfo "To start the server:" - einfo " pg_ctl start -D ${DATA_DIR} -o '-D ${PGDATA} --data-directory=${DATA_DIR}'" - einfo - einfo "To stop:" - einfo " pg_ctl stop -D ${DATA_DIR}" - einfo - einfo "Or move the configuration files back:" - einfo " mv ${PGDATA}*.conf ${DATA_DIR}" - else - einfo "You should use the '${EROOT%/}/etc/init.d/postgresql-${SLOT}' script to run PostgreSQL" - einfo "instead of 'pg_ctl'." - fi -} - -src_test() { - einfo ">>> Test phase [check]: ${CATEGORY}/${PF}" - - if [[ ${UID} != 0 ]] ; then - emake check || die "Make check failed. See above for details." - - einfo "If you think other tests besides the regression tests are necessary, please" - einfo "submit a bug including a patch for this ebuild to enable them." - else - ewarn "Tests cannot be run as root. Skipping." - ewarn "HINT: FEATURES=\"userpriv\"" - fi -} diff --git a/dev-db/postgresql-server/postgresql-server-9.0.5.ebuild b/dev-db/postgresql-server/postgresql-server-9.0.5.ebuild deleted file mode 100644 index c817a14e1a20..000000000000 --- a/dev-db/postgresql-server/postgresql-server-9.0.5.ebuild +++ /dev/null @@ -1,327 +0,0 @@ -# Copyright 1999-2011 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/dev-db/postgresql-server/postgresql-server-9.0.5.ebuild,v 1.6 2011/10/01 20:19:20 hwoarang Exp $ - -EAPI="3" -PYTHON_DEPEND="python? 2" - -WANT_AUTOMAKE="none" -inherit autotools eutils multilib pam prefix python versionator - -SLOT="$(get_version_component_range 1-2)" - -KEYWORDS="alpha amd64 arm hppa ia64 ~mips ppc ppc64 s390 sh sparc x86 ~x86-fbsd ~ppc-macos ~x86-solaris" - -DESCRIPTION="PostgreSQL server" -HOMEPAGE="http://www.postgresql.org/" -SRC_URI="mirror://postgresql/source/v${PV}/postgresql-${PV}.tar.bz2 - http://dev.gentoo.org/~titanofold/postgresql-patches-${SLOT}-r2.tbz2 - http://dev.gentoo.org/~titanofold/postgresql-initscript-1.2.tbz2" -LICENSE="POSTGRESQL" - -S="${WORKDIR}/postgresql-${PV}" - -LINGUAS="af cs de en es fa fr hr hu it ko nb pl pt_BR ro ru sk sl sv tr zh_CN zh_TW" -IUSE="doc kernel_linux nls pam perl -pg_legacytimestamp python selinux tcl uuid xml" - -for lingua in ${LINGUAS}; do - IUSE+=" linguas_${lingua}" -done - -wanted_languages() { - local enable_langs - - for lingua in ${LINGUAS} ; do - use linguas_${lingua} && enable_langs+="${lingua} " - done - - echo -n ${enable_langs} -} - -RDEPEND="~dev-db/postgresql-base-${PV}:${SLOT}[pam?,pg_legacytimestamp=,nls=] - perl? ( >=dev-lang/perl-5.8 ) - selinux? ( sec-policy/selinux-postgresql ) - tcl? ( >=dev-lang/tcl-8 ) - uuid? ( dev-libs/ossp-uuid ) - xml? ( dev-libs/libxml2 dev-libs/libxslt )" - -DEPEND="${RDEPEND} - sys-devel/flex - xml? ( dev-util/pkgconfig )" - -PDEPEND="doc? ( ~dev-db/postgresql-docs-${PV} )" - -pkg_setup() { - enewgroup postgres 70 - enewuser postgres 70 /bin/bash /var/lib/postgresql postgres - - use python && python_set_active_version 2 -} - -src_prepare() { - epatch "${WORKDIR}/autoconf.patch" "${WORKDIR}/bool.patch" \ - "${WORKDIR}/pg_ctl-exit-status.patch" "${WORKDIR}/server.patch" - - eprefixify src/include/pg_config_manual.h - - if use test ; then - epatch "${WORKDIR}/regress.patch" - sed -e "s|@SOCKETDIR@|${T}|g" -i src/test/regress/pg_regress{,_main}.c - sed -e "s|/no/such/location|${S}/src/test/regress/tmp_check/no/such/location|g" \ - -i src/test/regress/{input,output}/tablespace.source - else - echo "all install:" > "${S}/src/test/regress/GNUmakefile" - fi - - eautoconf -} - -src_configure() { - # eval is needed to get along with pg_config quotation of space-rich entities. - eval econf "$(${EPREFIX%/}/usr/$(get_libdir)/postgresql-${SLOT}/bin/pg_config --configure)" \ - --with-includes="${EPREFIX%/}/usr/include/postgresql-${SLOT}/" \ - --with-libraries="${EPREFIX%/}/usr/$(get_libdir)/postgresql-${SLOT}/$(get_libdir)" \ - --with-system-tzdata="${EPREFIX%/}/usr/share/zoneinfo" \ - $(use_with perl) \ - $(use_with python) \ - $(use_with tcl) \ - $(use_with xml libxml) \ - $(use_with xml libxslt) \ - $(use_with uuid ossp-uuid) \ - "$(use_enable nls nls "$(wanted_languages)")" -} - -src_compile() { - local bd - for bd in . contrib $(use xml && echo contrib/xml2); do - PATH="${EROOT%/}/usr/$(get_libdir)/postgresql-${SLOT}/bin:${PATH}" \ - emake -C $bd -j1 || die "emake in $bd failed" - done -} - -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 - - local bd - for bd in . contrib $(use xml && echo contrib/xml2) ; do - PATH="${EROOT%/}/usr/$(get_libdir)/postgresql-${SLOT}/bin:${PATH}" \ - emake install -C $bd -j1 DESTDIR="${D}" || die "emake install in $bd failed" - done - - dodir /usr/share/postgresql-${SLOT}/man/man1/ - cp "${S}"/doc/src/sgml/man1/{initdb,pg_controldata,pg_ctl,pg_resetxlog,post{gres,master}}.1 \ - "${ED}"/usr/share/postgresql-${SLOT}/man/man1/ || die - - dodoc README HISTORY doc/{README.*,TODO,bug.template} - - dodir /etc/eselect/postgresql/slots/${SLOT} - echo "postgres_ebuilds=\"\${postgres_ebuilds} ${PF}\"" \ - > "${ED}/etc/eselect/postgresql/slots/${SLOT}/server" - - sed -e "s/@SLOT@/${SLOT}/g" -i "${WORKDIR}/postgresql.confd" - newconfd "${WORKDIR}/postgresql.confd" postgresql-${SLOT} || die "Inserting conf.d file failed" - sed -e "s/@SLOT@/${SLOT}/g" -i "${WORKDIR}/postgresql.init" - newinitd "${WORKDIR}/postgresql.init" postgresql-${SLOT} || die "Inserting init.d file failed" - - use pam && pamd_mimic system-auth postgresql auth account session - - keepdir /var/run/postgresql - fperms 0770 /var/run/postgresql - use prefix || fowners postgres:postgres /var/run/postgresql -} - -pkg_postinst() { - postgresql-config update - - elog "The time stamp format is 64 bit integers now. If you upgrade from older" - elog "databases, this may force you to either do a dump and reload or enable" - elog "pg_legacytimestamp until you find time to do so. If the database cannot start" - elog "please try enabling pg_legacytimestamp and rebuild." - elog - elog "The Unix-domain socket is located in:" - elog " ${EROOT%/}/var/run/postgresql/" - elog - elog "If you have users and/or services that you would like to utilize the socket," - elog "you must add them to the 'postgres' system group:" - elog " usermod -a -G postgres <user>" - elog - elog "Before initializing the database, you may want to edit PG_INITDB_OPTS so that" - elog "it contains your preferred locale in:" - elog " ${EROOT%/}/etc/conf.d/postgresql-${SLOT}" - elog - elog "Then, execute the following command to setup the initial database" - elog "environment:" - elog " emerge --config =${CATEGORY}/${PF}" -} - -pkg_postrm() { - postgresql-config update -} - -pkg_config() { - [[ -f ${EROOT%/}/etc/conf.d/postgresql-${SLOT} ]] && source "${EROOT%/}/etc/conf.d/postgresql-${SLOT}" - [[ -z ${PGDATA} ]] && PGDATA="${EROOT%/}/etc/postgresql-${SLOT}/" - [[ -z ${DATA_DIR} ]] && DATA_DIR="${EROOT%/}/var/lib/postgresql/${SLOT}/data" - - # environment.bz2 may not contain the same locale as the current system - # locale. Unset and source from the current system locale. - if [[ -f ${EROOT%/}/etc/env.d/02locale ]] ; then - unset LANG - unset LC_CTYPE - unset LC_NUMERIC - unset LC_TIME - unset LC_COLLATE - unset LC_MONETARY - unset LC_MESSAGES - unset LC_ALL - source "${EROOT%/}/etc/env.d/02locale" - [[ -n ${LANG} ]] && export LANG - [[ -n ${LC_CTYPE} ]] && export LC_CTYPE - [[ -n ${LC_NUMERIC} ]] && export LC_NUMERIC - [[ -n ${LC_TIME} ]] && export LC_TIME - [[ -n ${LC_COLLATE} ]] && export LC_COLLATE - [[ -n ${LC_MONETARY} ]] && export LC_MONETARY - [[ -n ${LC_MESSAGES} ]] && export LC_MESSAGES - [[ -n ${LC_ALL} ]] && export LC_ALL - fi - - einfo "You can modify the paths and options passed to initdb by editing:" - einfo " ${EROOT%/}/etc/conf.d/postgresql-${SLOT}" - einfo - einfo "Information on options that can be passed to initdb are found at:" - einfo " http://www.postgresql.org/docs/${SLOT}/static/creating-cluster.html" - einfo " http://www.postgresql.org/docs/${SLOT}/static/app-initdb.html" - einfo - einfo "PG_INITDB_OPTS is currently set to:" - if [[ -z "${PG_INITDB_OPTS}" ]] ; then - einfo " (none)" - else - einfo " ${PG_INITDB_OPTS}" - fi - einfo - einfo "Configuration files will be installed to:" - einfo " ${PGDATA}" - einfo - einfo "The database cluster will be created in:" - einfo " ${DATA_DIR}" - einfo - while [[ $correct != "true" ]] ; do - einfo "Are you ready to continue? (y/n)" - read answer - if [[ $answer =~ ^[Yy]([Ee][Ss])?$ ]] ; then - correct="true" - elif [[ $answer =~ ^[Nn]([Oo])?$ ]] ; then - die "Aborting initialization." - else - echo "Answer not recognized" - fi - done - - if [[ -n "$(ls -A ${DATA_DIR} 2> /dev/null)" ]] ; then - eerror "The given directory, '${DATA_DIR}', is not empty." - eerror "Modify DATA_DIR to point to an empty directory." - die "${DATA_DIR} is not empty." - fi - - [[ -z ${PG_MAX_CONNECTIONS} ]] && PG_MAX_CONNECTIONS=128 - einfo "Checking system parameters..." - - if ! use kernel_linux ; then - einfo "Skipped." - einfo " Tests not supported on this OS (yet)" - else - if [[ -z ${SKIP_SYSTEM_TESTS} ]] ; then - einfo "Checking whether your system supports at least ${PG_MAX_CONNECTIONS} connections..." - - local SEMMSL=$(sysctl -n kernel.sem | cut -f1) - local SEMMNS=$(sysctl -n kernel.sem | cut -f2) - local SEMMNI=$(sysctl -n kernel.sem | cut -f4) - local SHMMAX=$(sysctl -n kernel.shmmax) - - local SEMMSL_MIN=17 - local SEMMNS_MIN=$(( ( ${PG_MAX_CONNECTIONS}/16 ) * 17 )) - local SEMMNI_MIN=$(( ( ${PG_MAX_CONNECTIONS}+15 ) / 16 )) - local SHMMAX_MIN=$(( 500000 + ( 30600 * ${PG_MAX_CONNECTIONS} ) )) - - for p in SEMMSL SEMMNS SEMMNI SHMMAX ; do - if [[ $(eval echo \$$p) -lt $(eval echo \$${p}_MIN) ]] ; then - eerror "The value for ${p} $(eval echo \$$p) is below the recommended value $(eval echo \$${p}_MIN)" - eerror "You have now several options:" - eerror " - Change the mentioned system parameter" - eerror " - Lower the number of max connections by setting PG_MAX_CONNECTIONS to a" - eerror " value lower than ${PG_MAX_CONNECTIONS}" - eerror " - Set SKIP_SYSTEM_TESTS in case you want to ignore this test completely" - eerror "More information can be found here:" - eerror " http://www.postgresql.org/docs/${SLOT}/static/kernel-resources.html" - die "System test failed." - fi - done - einfo "Passed." - else - ewarn "SKIP_SYSTEM_TESTS set, so skipping." - fi - fi - - if [[ ${EUID} == 0 ]] ; then - einfo "Creating the data directory ..." - mkdir -p "${DATA_DIR}" - chown -Rf postgres:postgres "${DATA_DIR}" - chmod 0700 "${DATA_DIR}" - fi - - einfo "Initializing the database ..." - - if [[ ${EUID} == 0 ]] ; then - su postgres \ - -c "${EROOT%/}/usr/$(get_libdir)/postgresql-${SLOT}/bin/initdb -D '${DATA_DIR}' -L '${EROOT%/}/usr/share/postgresql-${SLOT}/' ${PG_INITDB_OPTS}" - else - "${EROOT%/}"/usr/$(get_libdir)/postgresql-${SLOT}/bin/initdb \ - -U postgres -D "${DATA_DIR}" \ - -L "${EROOT%/}/usr/share/postgresql-${SLOT}/" ${PG_INITDB_OPTS} - fi - - mv "${DATA_DIR%/}"/*.conf "${PGDATA}" - - einfo "The autovacuum function, which was in contrib, has been moved to the main" - einfo "PostgreSQL functions starting with 8.1, and starting with 8.4 is now enabled" - einfo "by default. You can disable it in the cluster's:" - einfo " ${PGDATA%/}/postgresql.conf" - einfo - einfo "The PostgreSQL server, by default, will log events to:" - einfo " ${DATA_DIR%/}/postmaster.log" - einfo - if use prefix ; then - einfo "The location of the configuration files have moved to:" - einfo " ${PGDATA}" - einfo - einfo "To start the server:" - einfo " pg_ctl start -D ${DATA_DIR} -o '-D ${PGDATA} --data-directory=${DATA_DIR}'" - einfo - einfo "To stop:" - einfo " pg_ctl stop -D ${DATA_DIR}" - einfo - einfo "Or move the configuration files back:" - einfo " mv ${PGDATA}*.conf ${DATA_DIR}" - else - einfo "You should use the '${EROOT%/}/etc/init.d/postgresql-${SLOT}' script to run PostgreSQL" - einfo "instead of 'pg_ctl'." - fi -} - -src_test() { - einfo ">>> Test phase [check]: ${CATEGORY}/${PF}" - - if [[ ${UID} != 0 ]] ; then - emake check || die "Make check failed. See above for details." - - einfo "If you think other tests besides the regression tests are necessary, please" - einfo "submit a bug including a patch for this ebuild to enable them." - else - ewarn "Tests cannot be run as root. Skipping." - ewarn "HINT: FEATURES=\"userpriv\"" - fi -} diff --git a/dev-db/postgresql-server/postgresql-server-9.0.6-r1.ebuild b/dev-db/postgresql-server/postgresql-server-9.0.6-r1.ebuild deleted file mode 100644 index e42eb5f3bbe9..000000000000 --- a/dev-db/postgresql-server/postgresql-server-9.0.6-r1.ebuild +++ /dev/null @@ -1,342 +0,0 @@ -# Copyright 1999-2012 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/dev-db/postgresql-server/postgresql-server-9.0.6-r1.ebuild,v 1.7 2012/02/19 12:44:40 klausman Exp $ - -EAPI="3" -PYTHON_DEPEND="python? 2" - -WANT_AUTOMAKE="none" -inherit autotools eutils multilib pam prefix python versionator - -SLOT="$(get_version_component_range 1-2)" - -KEYWORDS="alpha amd64 arm hppa ~ia64 ~mips ppc ~ppc64 ~s390 ~sh ~sparc x86 ~x86-fbsd ~ppc-macos ~x86-solaris" - -DESCRIPTION="PostgreSQL server" -HOMEPAGE="http://www.postgresql.org/" -SRC_URI="mirror://postgresql/source/v${PV}/postgresql-${PV}.tar.bz2 - http://dev.gentoo.org/~titanofold/postgresql-patches-9.0-r3.tbz2 - http://dev.gentoo.org/~titanofold/postgresql-initscript-2.1.tbz2" -LICENSE="POSTGRESQL" - -S="${WORKDIR}/postgresql-${PV}" - -LINGUAS="af cs de en es fa fr hr hu it ko nb pl pt_BR ro ru sk sl sv tr zh_CN zh_TW" -IUSE="doc kernel_linux nls pam perl -pg_legacytimestamp python selinux tcl uuid xml" - -for lingua in ${LINGUAS}; do - IUSE+=" linguas_${lingua}" -done - -wanted_languages() { - local enable_langs - - for lingua in ${LINGUAS} ; do - use linguas_${lingua} && enable_langs+="${lingua} " - done - - echo -n ${enable_langs} -} - -RDEPEND="~dev-db/postgresql-base-${PV}:${SLOT}[pam?,pg_legacytimestamp=,nls=] - perl? ( >=dev-lang/perl-5.8 ) - selinux? ( sec-policy/selinux-postgresql ) - tcl? ( >=dev-lang/tcl-8 ) - uuid? ( dev-libs/ossp-uuid ) - xml? ( dev-libs/libxml2 dev-libs/libxslt )" - -DEPEND="${RDEPEND} - sys-devel/flex - xml? ( dev-util/pkgconfig )" - -PDEPEND="doc? ( ~dev-db/postgresql-docs-${PV} )" - -# Support /var/run or /run for the socket directory -[[ ! -d /run ]] && RUNDIR=/var - -pkg_setup() { - enewgroup postgres 70 - enewuser postgres 70 /bin/bash /var/lib/postgresql postgres - - use python && python_set_active_version 2 -} - -src_prepare() { - epatch "${WORKDIR}/autoconf.patch" \ - "${WORKDIR}/bool.patch" \ - "${WORKDIR}/pg_ctl-exit-status.patch" \ - "${WORKDIR}/server.patch" - - eprefixify src/include/pg_config_manual.h - - if use test ; then - epatch "${WORKDIR}/regress.patch" - sed -e "s|@SOCKETDIR@|${T}|g" -i src/test/regress/pg_regress{,_main}.c - sed -e "s|/no/such/location|${S}/src/test/regress/tmp_check/no/such/location|g" \ - -i src/test/regress/{input,output}/tablespace.source - else - echo "all install:" > "${S}/src/test/regress/GNUmakefile" - fi - - sed -e "s|@RUNDIR@|${RUNDIR}|g" \ - -i src/include/pg_config_manual.h "${WORKDIR}/postgresql.init" || \ - die "RUNDIR sed failed" - sed -e "s|@SLOT@|${SLOT}|g" \ - -i "${WORKDIR}/postgresql.init" "${WORKDIR}/postgresql.confd" || \ - die "SLOT sed failed" - - eautoconf -} - -src_configure() { - # eval is needed to get along with pg_config quotation of space-rich entities. - eval econf "$(${EPREFIX%/}/usr/$(get_libdir)/postgresql-${SLOT}/bin/pg_config --configure)" \ - --with-includes="${EPREFIX%/}/usr/include/postgresql-${SLOT}/" \ - --with-libraries="${EPREFIX%/}/usr/$(get_libdir)/postgresql-${SLOT}/$(get_libdir)" \ - --with-system-tzdata="${EPREFIX%/}/usr/share/zoneinfo" \ - $(use_with perl) \ - $(use_with python) \ - $(use_with tcl) \ - $(use_with xml libxml) \ - $(use_with xml libxslt) \ - $(use_with uuid ossp-uuid) \ - "$(use_enable nls nls "$(wanted_languages)")" -} - -src_compile() { - local bd - for bd in . contrib $(use xml && echo contrib/xml2); do - PATH="${EROOT%/}/usr/$(get_libdir)/postgresql-${SLOT}/bin:${PATH}" \ - emake -C $bd -j1 || die "emake in $bd failed" - done -} - -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 - - local bd - for bd in . contrib $(use xml && echo contrib/xml2) ; do - PATH="${EROOT%/}/usr/$(get_libdir)/postgresql-${SLOT}/bin:${PATH}" \ - emake install -C $bd -j1 DESTDIR="${D}" || die "emake install in $bd failed" - done - - dodir /usr/share/postgresql-${SLOT}/man/man1/ - cp "${S}"/doc/src/sgml/man1/{initdb,pg_controldata,pg_ctl,pg_resetxlog,post{gres,master}}.1 \ - "${ED}"/usr/share/postgresql-${SLOT}/man/man1/ || die - - dodoc README HISTORY doc/{README.*,TODO,bug.template} - - dodir /etc/eselect/postgresql/slots/${SLOT} - echo "postgres_ebuilds=\"\${postgres_ebuilds} ${PF}\"" \ - > "${ED}/etc/eselect/postgresql/slots/${SLOT}/server" - - newconfd "${WORKDIR}/postgresql.confd" postgresql-${SLOT} \ - || die "Inserting conf.d file failed" - - newinitd "${WORKDIR}/postgresql.init" postgresql-${SLOT} \ - || die "Inserting init.d file failed" - - use pam && pamd_mimic system-auth postgresql auth account session - - if use prefix ; then - keepdir ${RUNDIR}/run/postgresql - fperms 0770 ${RUNDIR}/run/postgresql - fi -} - -pkg_postinst() { - postgresql-config update - - elog "Gentoo specific documentation:" - elog "http://www.gentoo.org/doc/en/postgres-howto.xml" - elog - elog "Official documentation:" - elog "http://www.postgresql.org/docs/${SLOT}/static/index.html" - elog - elog "The default location of the Unix-domain socket is:" - elog " ${EROOT%/}${RUNDIR}/run/postgresql/" - elog - elog "If you have users and/or services that you would like to utilize the" - elog "socket, you must add them to the 'postgres' system group:" - elog " usermod -a -G postgres <user>" - elog - elog "Before initializing the database, you may want to edit PG_INITDB_OPTS" - elog "so that it contains your preferred locale in:" - elog " ${EROOT%/}/etc/conf.d/postgresql-${SLOT}" - elog - elog "Then, execute the following command to setup the initial database" - elog "environment:" - elog " emerge --config =${CATEGORY}/${PF}" -} - -pkg_postrm() { - postgresql-config update -} - -pkg_config() { - [[ -f ${EROOT%/}/etc/conf.d/postgresql-${SLOT} ]] && source "${EROOT%/}/etc/conf.d/postgresql-${SLOT}" - [[ -z ${PGDATA} ]] && PGDATA="${EROOT%/}/etc/postgresql-${SLOT}/" - [[ -z ${DATA_DIR} ]] && DATA_DIR="${EROOT%/}/var/lib/postgresql/${SLOT}/data" - - # environment.bz2 may not contain the same locale as the current system - # locale. Unset and source from the current system locale. - if [[ -f ${EROOT%/}/etc/env.d/02locale ]] ; then - unset LANG - unset LC_CTYPE - unset LC_NUMERIC - unset LC_TIME - unset LC_COLLATE - unset LC_MONETARY - unset LC_MESSAGES - unset LC_ALL - source "${EROOT%/}/etc/env.d/02locale" - [[ -n ${LANG} ]] && export LANG - [[ -n ${LC_CTYPE} ]] && export LC_CTYPE - [[ -n ${LC_NUMERIC} ]] && export LC_NUMERIC - [[ -n ${LC_TIME} ]] && export LC_TIME - [[ -n ${LC_COLLATE} ]] && export LC_COLLATE - [[ -n ${LC_MONETARY} ]] && export LC_MONETARY - [[ -n ${LC_MESSAGES} ]] && export LC_MESSAGES - [[ -n ${LC_ALL} ]] && export LC_ALL - fi - - einfo "You can modify the paths and options passed to initdb by editing:" - einfo " ${EROOT%/}/etc/conf.d/postgresql-${SLOT}" - einfo - einfo "Information on options that can be passed to initdb are found at:" - einfo " http://www.postgresql.org/docs/${SLOT}/static/creating-cluster.html" - einfo " http://www.postgresql.org/docs/${SLOT}/static/app-initdb.html" - einfo - einfo "PG_INITDB_OPTS is currently set to:" - if [[ -z "${PG_INITDB_OPTS}" ]] ; then - einfo " (none)" - else - einfo " ${PG_INITDB_OPTS}" - fi - einfo - einfo "Configuration files will be installed to:" - einfo " ${PGDATA}" - einfo - einfo "The database cluster will be created in:" - einfo " ${DATA_DIR}" - einfo - while [[ $correct != "true" ]] ; do - einfo "Are you ready to continue? (y/n)" - read answer - if [[ $answer =~ ^[Yy]([Ee][Ss])?$ ]] ; then - correct="true" - elif [[ $answer =~ ^[Nn]([Oo])?$ ]] ; then - die "Aborting initialization." - else - echo "Answer not recognized" - fi - done - - if [[ -n "$(ls -A ${DATA_DIR} 2> /dev/null)" ]] ; then - eerror "The given directory, '${DATA_DIR}', is not empty." - eerror "Modify DATA_DIR to point to an empty directory." - die "${DATA_DIR} is not empty." - fi - - [[ -z ${PG_MAX_CONNECTIONS} ]] && PG_MAX_CONNECTIONS=128 - einfo "Checking system parameters..." - - if ! use kernel_linux ; then - einfo "Skipped." - einfo " Tests not supported on this OS (yet)" - else - if [[ -z ${SKIP_SYSTEM_TESTS} ]] ; then - einfo "Checking whether your system supports at least ${PG_MAX_CONNECTIONS} connections..." - - local SEMMSL=$(sysctl -n kernel.sem | cut -f1) - local SEMMNS=$(sysctl -n kernel.sem | cut -f2) - local SEMMNI=$(sysctl -n kernel.sem | cut -f4) - local SHMMAX=$(sysctl -n kernel.shmmax) - - local SEMMSL_MIN=17 - local SEMMNS_MIN=$(( ( ${PG_MAX_CONNECTIONS}/16 ) * 17 )) - local SEMMNI_MIN=$(( ( ${PG_MAX_CONNECTIONS}+15 ) / 16 )) - local SHMMAX_MIN=$(( 500000 + ( 30600 * ${PG_MAX_CONNECTIONS} ) )) - - for p in SEMMSL SEMMNS SEMMNI SHMMAX ; do - if [[ $(eval echo \$$p) -lt $(eval echo \$${p}_MIN) ]] ; then - eerror "The value for ${p} $(eval echo \$$p) is below the recommended value $(eval echo \$${p}_MIN)" - eerror "You have now several options:" - eerror " - Change the mentioned system parameter" - eerror " - Lower the number of max connections by setting PG_MAX_CONNECTIONS to a" - eerror " value lower than ${PG_MAX_CONNECTIONS}" - eerror " - Set SKIP_SYSTEM_TESTS in case you want to ignore this test completely" - eerror "More information can be found here:" - eerror " http://www.postgresql.org/docs/${SLOT}/static/kernel-resources.html" - die "System test failed." - fi - done - einfo "Passed." - else - ewarn "SKIP_SYSTEM_TESTS set, so skipping." - fi - fi - - if [[ ${EUID} == 0 ]] ; then - einfo "Creating the data directory ..." - mkdir -p "${DATA_DIR}" - chown -Rf postgres:postgres "${DATA_DIR}" - chmod 0700 "${DATA_DIR}" - fi - - einfo "Initializing the database ..." - - if [[ ${EUID} == 0 ]] ; then - su postgres \ - -c "${EROOT%/}/usr/$(get_libdir)/postgresql-${SLOT}/bin/initdb -D '${DATA_DIR}' -L '${EROOT%/}/usr/share/postgresql-${SLOT}/' ${PG_INITDB_OPTS}" - else - "${EROOT%/}"/usr/$(get_libdir)/postgresql-${SLOT}/bin/initdb \ - -U postgres -D "${DATA_DIR}" \ - -L "${EROOT%/}/usr/share/postgresql-${SLOT}/" ${PG_INITDB_OPTS} - fi - - mv "${DATA_DIR%/}"/*.conf "${PGDATA}" - - einfo "The autovacuum function, which was in contrib, has been moved to the main" - einfo "PostgreSQL functions starting with 8.1, and starting with 8.4 is now enabled" - einfo "by default. You can disable it in the cluster's:" - einfo " ${PGDATA%/}/postgresql.conf" - einfo - einfo "The PostgreSQL server, by default, will log events to:" - einfo " ${DATA_DIR%/}/postmaster.log" - einfo - if use prefix ; then - einfo "The location of the configuration files have moved to:" - einfo " ${PGDATA}" - einfo - einfo "To start the server:" - einfo " pg_ctl start -D ${DATA_DIR} -o '-D ${PGDATA} --data-directory=${DATA_DIR}'" - einfo - einfo "To stop:" - einfo " pg_ctl stop -D ${DATA_DIR}" - einfo - einfo "Or move the configuration files back:" - einfo " mv ${PGDATA}*.conf ${DATA_DIR}" - else - einfo "You should use the '${EROOT%/}/etc/init.d/postgresql-${SLOT}' script to run PostgreSQL" - einfo "instead of 'pg_ctl'." - fi -} - -src_test() { - einfo ">>> Test phase [check]: ${CATEGORY}/${PF}" - - if [[ ${UID} != 0 ]] ; then - emake check || die "Make check failed. See above for details." - - einfo "If you think other tests besides the regression tests are necessary, please" - einfo "submit a bug including a patch for this ebuild to enable them." - else - ewarn "Tests cannot be run as root. Skipping." - ewarn "HINT: FEATURES=\"userpriv\"" - fi -} diff --git a/dev-db/postgresql-server/postgresql-server-9.0.6.ebuild b/dev-db/postgresql-server/postgresql-server-9.0.6.ebuild deleted file mode 100644 index 89fe61adc40b..000000000000 --- a/dev-db/postgresql-server/postgresql-server-9.0.6.ebuild +++ /dev/null @@ -1,342 +0,0 @@ -# Copyright 1999-2012 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/dev-db/postgresql-server/postgresql-server-9.0.6.ebuild,v 1.2 2012/01/30 19:51:21 ago Exp $ - -EAPI="3" -PYTHON_DEPEND="python? 2" - -WANT_AUTOMAKE="none" -inherit autotools eutils multilib pam prefix python versionator - -SLOT="$(get_version_component_range 1-2)" - -KEYWORDS="~alpha amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~x86-fbsd ~ppc-macos ~x86-solaris" - -DESCRIPTION="PostgreSQL server" -HOMEPAGE="http://www.postgresql.org/" -SRC_URI="mirror://postgresql/source/v${PV}/postgresql-${PV}.tar.bz2 - http://dev.gentoo.org/~titanofold/postgresql-patches-9.0-r3.tbz2 - http://dev.gentoo.org/~titanofold/postgresql-initscript-2.0.tbz2" -LICENSE="POSTGRESQL" - -S="${WORKDIR}/postgresql-${PV}" - -LINGUAS="af cs de en es fa fr hr hu it ko nb pl pt_BR ro ru sk sl sv tr zh_CN zh_TW" -IUSE="doc kernel_linux nls pam perl -pg_legacytimestamp python selinux tcl uuid xml" - -for lingua in ${LINGUAS}; do - IUSE+=" linguas_${lingua}" -done - -wanted_languages() { - local enable_langs - - for lingua in ${LINGUAS} ; do - use linguas_${lingua} && enable_langs+="${lingua} " - done - - echo -n ${enable_langs} -} - -RDEPEND="~dev-db/postgresql-base-${PV}:${SLOT}[pam?,pg_legacytimestamp=,nls=] - perl? ( >=dev-lang/perl-5.8 ) - selinux? ( sec-policy/selinux-postgresql ) - tcl? ( >=dev-lang/tcl-8 ) - uuid? ( dev-libs/ossp-uuid ) - xml? ( dev-libs/libxml2 dev-libs/libxslt )" - -DEPEND="${RDEPEND} - sys-devel/flex - xml? ( dev-util/pkgconfig )" - -PDEPEND="doc? ( ~dev-db/postgresql-docs-${PV} )" - -# Support /var/run or /run for the socket directory -[[ ! -d /run ]] && RUNDIR=/var - -pkg_setup() { - enewgroup postgres 70 - enewuser postgres 70 /bin/bash /var/lib/postgresql postgres - - use python && python_set_active_version 2 -} - -src_prepare() { - epatch "${WORKDIR}/autoconf.patch" \ - "${WORKDIR}/bool.patch" \ - "${WORKDIR}/pg_ctl-exit-status.patch" \ - "${WORKDIR}/server.patch" - - eprefixify src/include/pg_config_manual.h - - if use test ; then - epatch "${WORKDIR}/regress.patch" - sed -e "s|@SOCKETDIR@|${T}|g" -i src/test/regress/pg_regress{,_main}.c - sed -e "s|/no/such/location|${S}/src/test/regress/tmp_check/no/such/location|g" \ - -i src/test/regress/{input,output}/tablespace.source - else - echo "all install:" > "${S}/src/test/regress/GNUmakefile" - fi - - sed -e "s|@RUNDIR@|${RUNDIR}|g" \ - -i src/include/pg_config_manual.h "${WORKDIR}/postgresql.init" || \ - die "RUNDIR sed failed" - sed -e "s|@SLOT@|${SLOT}|g" \ - -i "${WORKDIR}/postgresql.init" "${WORKDIR}/postgresql.confd" || \ - die "SLOT sed failed" - - eautoconf -} - -src_configure() { - # eval is needed to get along with pg_config quotation of space-rich entities. - eval econf "$(${EPREFIX%/}/usr/$(get_libdir)/postgresql-${SLOT}/bin/pg_config --configure)" \ - --with-includes="${EPREFIX%/}/usr/include/postgresql-${SLOT}/" \ - --with-libraries="${EPREFIX%/}/usr/$(get_libdir)/postgresql-${SLOT}/$(get_libdir)" \ - --with-system-tzdata="${EPREFIX%/}/usr/share/zoneinfo" \ - $(use_with perl) \ - $(use_with python) \ - $(use_with tcl) \ - $(use_with xml libxml) \ - $(use_with xml libxslt) \ - $(use_with uuid ossp-uuid) \ - "$(use_enable nls nls "$(wanted_languages)")" -} - -src_compile() { - local bd - for bd in . contrib $(use xml && echo contrib/xml2); do - PATH="${EROOT%/}/usr/$(get_libdir)/postgresql-${SLOT}/bin:${PATH}" \ - emake -C $bd -j1 || die "emake in $bd failed" - done -} - -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 - - local bd - for bd in . contrib $(use xml && echo contrib/xml2) ; do - PATH="${EROOT%/}/usr/$(get_libdir)/postgresql-${SLOT}/bin:${PATH}" \ - emake install -C $bd -j1 DESTDIR="${D}" || die "emake install in $bd failed" - done - - dodir /usr/share/postgresql-${SLOT}/man/man1/ - cp "${S}"/doc/src/sgml/man1/{initdb,pg_controldata,pg_ctl,pg_resetxlog,post{gres,master}}.1 \ - "${ED}"/usr/share/postgresql-${SLOT}/man/man1/ || die - - dodoc README HISTORY doc/{README.*,TODO,bug.template} - - dodir /etc/eselect/postgresql/slots/${SLOT} - echo "postgres_ebuilds=\"\${postgres_ebuilds} ${PF}\"" \ - > "${ED}/etc/eselect/postgresql/slots/${SLOT}/server" - - newconfd "${WORKDIR}/postgresql.confd" postgresql-${SLOT} \ - || die "Inserting conf.d file failed" - - newinitd "${WORKDIR}/postgresql.init" postgresql-${SLOT} \ - || die "Inserting init.d file failed" - - use pam && pamd_mimic system-auth postgresql auth account session - - if use prefix ; then - keepdir ${RUNDIR}/run/postgresql - fperms 0770 ${RUNDIR}/run/postgresql - fi -} - -pkg_postinst() { - postgresql-config update - - elog "Gentoo specific documentation:" - elog "http://www.gentoo.org/doc/en/postgres-howto.xml" - elog - elog "Official documentation:" - elog "http://www.postgresql.org/docs/${SLOT}/static/index.html" - elog - elog "The default location of the Unix-domain socket is:" - elog " ${EROOT%/}${RUNDIR}/run/postgresql/" - elog - elog "If you have users and/or services that you would like to utilize the" - elog "socket, you must add them to the 'postgres' system group:" - elog " usermod -a -G postgres <user>" - elog - elog "Before initializing the database, you may want to edit PG_INITDB_OPTS" - elog "so that it contains your preferred locale in:" - elog " ${EROOT%/}/etc/conf.d/postgresql-${SLOT}" - elog - elog "Then, execute the following command to setup the initial database" - elog "environment:" - elog " emerge --config =${CATEGORY}/${PF}" -} - -pkg_postrm() { - postgresql-config update -} - -pkg_config() { - [[ -f ${EROOT%/}/etc/conf.d/postgresql-${SLOT} ]] && source "${EROOT%/}/etc/conf.d/postgresql-${SLOT}" - [[ -z ${PGDATA} ]] && PGDATA="${EROOT%/}/etc/postgresql-${SLOT}/" - [[ -z ${DATA_DIR} ]] && DATA_DIR="${EROOT%/}/var/lib/postgresql/${SLOT}/data" - - # environment.bz2 may not contain the same locale as the current system - # locale. Unset and source from the current system locale. - if [[ -f ${EROOT%/}/etc/env.d/02locale ]] ; then - unset LANG - unset LC_CTYPE - unset LC_NUMERIC - unset LC_TIME - unset LC_COLLATE - unset LC_MONETARY - unset LC_MESSAGES - unset LC_ALL - source "${EROOT%/}/etc/env.d/02locale" - [[ -n ${LANG} ]] && export LANG - [[ -n ${LC_CTYPE} ]] && export LC_CTYPE - [[ -n ${LC_NUMERIC} ]] && export LC_NUMERIC - [[ -n ${LC_TIME} ]] && export LC_TIME - [[ -n ${LC_COLLATE} ]] && export LC_COLLATE - [[ -n ${LC_MONETARY} ]] && export LC_MONETARY - [[ -n ${LC_MESSAGES} ]] && export LC_MESSAGES - [[ -n ${LC_ALL} ]] && export LC_ALL - fi - - einfo "You can modify the paths and options passed to initdb by editing:" - einfo " ${EROOT%/}/etc/conf.d/postgresql-${SLOT}" - einfo - einfo "Information on options that can be passed to initdb are found at:" - einfo " http://www.postgresql.org/docs/${SLOT}/static/creating-cluster.html" - einfo " http://www.postgresql.org/docs/${SLOT}/static/app-initdb.html" - einfo - einfo "PG_INITDB_OPTS is currently set to:" - if [[ -z "${PG_INITDB_OPTS}" ]] ; then - einfo " (none)" - else - einfo " ${PG_INITDB_OPTS}" - fi - einfo - einfo "Configuration files will be installed to:" - einfo " ${PGDATA}" - einfo - einfo "The database cluster will be created in:" - einfo " ${DATA_DIR}" - einfo - while [[ $correct != "true" ]] ; do - einfo "Are you ready to continue? (y/n)" - read answer - if [[ $answer =~ ^[Yy]([Ee][Ss])?$ ]] ; then - correct="true" - elif [[ $answer =~ ^[Nn]([Oo])?$ ]] ; then - die "Aborting initialization." - else - echo "Answer not recognized" - fi - done - - if [[ -n "$(ls -A ${DATA_DIR} 2> /dev/null)" ]] ; then - eerror "The given directory, '${DATA_DIR}', is not empty." - eerror "Modify DATA_DIR to point to an empty directory." - die "${DATA_DIR} is not empty." - fi - - [[ -z ${PG_MAX_CONNECTIONS} ]] && PG_MAX_CONNECTIONS=128 - einfo "Checking system parameters..." - - if ! use kernel_linux ; then - einfo "Skipped." - einfo " Tests not supported on this OS (yet)" - else - if [[ -z ${SKIP_SYSTEM_TESTS} ]] ; then - einfo "Checking whether your system supports at least ${PG_MAX_CONNECTIONS} connections..." - - local SEMMSL=$(sysctl -n kernel.sem | cut -f1) - local SEMMNS=$(sysctl -n kernel.sem | cut -f2) - local SEMMNI=$(sysctl -n kernel.sem | cut -f4) - local SHMMAX=$(sysctl -n kernel.shmmax) - - local SEMMSL_MIN=17 - local SEMMNS_MIN=$(( ( ${PG_MAX_CONNECTIONS}/16 ) * 17 )) - local SEMMNI_MIN=$(( ( ${PG_MAX_CONNECTIONS}+15 ) / 16 )) - local SHMMAX_MIN=$(( 500000 + ( 30600 * ${PG_MAX_CONNECTIONS} ) )) - - for p in SEMMSL SEMMNS SEMMNI SHMMAX ; do - if [[ $(eval echo \$$p) -lt $(eval echo \$${p}_MIN) ]] ; then - eerror "The value for ${p} $(eval echo \$$p) is below the recommended value $(eval echo \$${p}_MIN)" - eerror "You have now several options:" - eerror " - Change the mentioned system parameter" - eerror " - Lower the number of max connections by setting PG_MAX_CONNECTIONS to a" - eerror " value lower than ${PG_MAX_CONNECTIONS}" - eerror " - Set SKIP_SYSTEM_TESTS in case you want to ignore this test completely" - eerror "More information can be found here:" - eerror " http://www.postgresql.org/docs/${SLOT}/static/kernel-resources.html" - die "System test failed." - fi - done - einfo "Passed." - else - ewarn "SKIP_SYSTEM_TESTS set, so skipping." - fi - fi - - if [[ ${EUID} == 0 ]] ; then - einfo "Creating the data directory ..." - mkdir -p "${DATA_DIR}" - chown -Rf postgres:postgres "${DATA_DIR}" - chmod 0700 "${DATA_DIR}" - fi - - einfo "Initializing the database ..." - - if [[ ${EUID} == 0 ]] ; then - su postgres \ - -c "${EROOT%/}/usr/$(get_libdir)/postgresql-${SLOT}/bin/initdb -D '${DATA_DIR}' -L '${EROOT%/}/usr/share/postgresql-${SLOT}/' ${PG_INITDB_OPTS}" - else - "${EROOT%/}"/usr/$(get_libdir)/postgresql-${SLOT}/bin/initdb \ - -U postgres -D "${DATA_DIR}" \ - -L "${EROOT%/}/usr/share/postgresql-${SLOT}/" ${PG_INITDB_OPTS} - fi - - mv "${DATA_DIR%/}"/*.conf "${PGDATA}" - - einfo "The autovacuum function, which was in contrib, has been moved to the main" - einfo "PostgreSQL functions starting with 8.1, and starting with 8.4 is now enabled" - einfo "by default. You can disable it in the cluster's:" - einfo " ${PGDATA%/}/postgresql.conf" - einfo - einfo "The PostgreSQL server, by default, will log events to:" - einfo " ${DATA_DIR%/}/postmaster.log" - einfo - if use prefix ; then - einfo "The location of the configuration files have moved to:" - einfo " ${PGDATA}" - einfo - einfo "To start the server:" - einfo " pg_ctl start -D ${DATA_DIR} -o '-D ${PGDATA} --data-directory=${DATA_DIR}'" - einfo - einfo "To stop:" - einfo " pg_ctl stop -D ${DATA_DIR}" - einfo - einfo "Or move the configuration files back:" - einfo " mv ${PGDATA}*.conf ${DATA_DIR}" - else - einfo "You should use the '${EROOT%/}/etc/init.d/postgresql-${SLOT}' script to run PostgreSQL" - einfo "instead of 'pg_ctl'." - fi -} - -src_test() { - einfo ">>> Test phase [check]: ${CATEGORY}/${PF}" - - if [[ ${UID} != 0 ]] ; then - emake check || die "Make check failed. See above for details." - - einfo "If you think other tests besides the regression tests are necessary, please" - einfo "submit a bug including a patch for this ebuild to enable them." - else - ewarn "Tests cannot be run as root. Skipping." - ewarn "HINT: FEATURES=\"userpriv\"" - fi -} diff --git a/dev-db/postgresql-server/postgresql-server-9.1.1.ebuild b/dev-db/postgresql-server/postgresql-server-9.1.1.ebuild deleted file mode 100644 index 04e1fa6be8a7..000000000000 --- a/dev-db/postgresql-server/postgresql-server-9.1.1.ebuild +++ /dev/null @@ -1,319 +0,0 @@ -# Copyright 1999-2011 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/dev-db/postgresql-server/postgresql-server-9.1.1.ebuild,v 1.6 2011/12/17 18:06:48 armin76 Exp $ - -EAPI="3" -PYTHON_DEPEND="python? 2" - -WANT_AUTOMAKE="none" -inherit autotools eutils flag-o-matic multilib pam prefix python versionator - -KEYWORDS="alpha amd64 arm hppa ia64 ~mips ~ppc ~ppc64 s390 sh sparc x86 ~x86-fbsd ~ppc-macos ~x86-solaris" - -SLOT="$(get_version_component_range 1-2)" -S="${WORKDIR}/postgresql-${PV}" - -DESCRIPTION="PostgreSQL server" -HOMEPAGE="http://www.postgresql.org/" -SRC_URI="mirror://postgresql/source/v${PV}/postgresql-${PV}.tar.bz2 - http://dev.gentoo.org/~titanofold/postgresql-patches-${SLOT}.tbz2 - http://dev.gentoo.org/~titanofold/postgresql-initscript-1.2.tbz2" -LICENSE="POSTGRESQL" - -LINGUAS="af cs de en es fa fr hr hu it ko nb pl pt_BR ro ru sk sl sv tr zh_CN zh_TW" -IUSE="doc kernel_linux nls pam perl -pg_legacytimestamp python selinux tcl uuid xml" - -for lingua in ${LINGUAS}; do - IUSE+=" linguas_${lingua}" -done - -wanted_languages() { - local enable_langs - - for lingua in ${LINGUAS} ; do - use linguas_${lingua} && enable_langs+="${lingua} " - done - - echo -n ${enable_langs} -} - -RDEPEND="~dev-db/postgresql-base-${PV}:${SLOT}[pam?,pg_legacytimestamp=,nls=] - perl? ( >=dev-lang/perl-5.8 ) - selinux? ( sec-policy/selinux-postgresql ) - tcl? ( >=dev-lang/tcl-8 ) - uuid? ( dev-libs/ossp-uuid ) - xml? ( dev-libs/libxml2 dev-libs/libxslt )" -DEPEND="${RDEPEND} - sys-devel/flex - xml? ( dev-util/pkgconfig )" -PDEPEND="doc? ( ~dev-db/postgresql-docs-${PV} )" - -pkg_setup() { - enewgroup postgres 70 - enewuser postgres 70 /bin/bash /var/lib/postgresql postgres - - use python && python_set_active_version 2 -} - -src_prepare() { - epatch "${WORKDIR}/autoconf.patch" "${WORKDIR}/bool.patch" \ - "${WORKDIR}/pg_ctl-exit-status.patch" "${WORKDIR}/server.patch" - - eprefixify src/include/pg_config_manual.h - - if use test ; then - epatch "${WORKDIR}/regress.patch" - sed -e "s|@SOCKETDIR@|${T}|g" -i src/test/regress/pg_regress{,_main}.c - sed -e "s|/no/such/location|${S}/src/test/regress/tmp_check/no/such/location|g" -i src/test/regress/{input,output}/tablespace.source - else - echo "all install:" > "${S}/src/test/regress/GNUmakefile" - fi - - eautoconf - -# use perl && epatch "${WORKDIR}/perl-ExtUtils-ParseXS.patch" -} - -src_configure() { - case ${CHOST} in - *-darwin*|*-solaris*) - use nls && append-libs intl - ;; - esac - - local PO="${EPREFIX%/}" - - # eval is needed to get along with pg_config quotation of space-rich entities. - eval econf "$(${PO}/usr/$(get_libdir)/postgresql-${SLOT}/bin/pg_config --configure)" \ - $(use_with perl) \ - $(use_with python) \ - $(use_with tcl) \ - $(use_with xml libxml) \ - $(use_with xml libxslt) \ - $(use_with uuid ossp-uuid) \ - --with-system-tzdata="${PO}/usr/share/zoneinfo" \ - --with-includes="${PO}/usr/include/postgresql-${SLOT}/" \ - --with-libraries="${PO}/usr/$(get_libdir)/postgresql-${SLOT}/$(get_libdir)" \ - "$(use_enable nls nls "$(wanted_languages)")" -} - -src_compile() { - local bd - for bd in . contrib $(use xml && echo contrib/xml2); do - PATH="${EROOT%/}/usr/$(get_libdir)/postgresql-${SLOT}/bin:${PATH}" \ - emake -C $bd || die "emake in $bd failed" - done -} - -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 - - local bd - for bd in . contrib $(use xml && echo contrib/xml2) ; do - PATH="${EROOT%/}/usr/$(get_libdir)/postgresql-${SLOT}/bin:${PATH}" \ - emake install -C $bd DESTDIR="${D}" || die "emake install in $bd failed" - done - - dodoc README HISTORY doc/{TODO,bug.template} - - dodir /etc/eselect/postgresql/slots/${SLOT} - echo "postgres_ebuilds=\"\${postgres_ebuilds} ${PF}\"" > \ - "${ED}/etc/eselect/postgresql/slots/${SLOT}/server" - - sed -e "s/@SLOT@/${SLOT}/g" -i "${WORKDIR}"/postgresql.confd - newconfd "${WORKDIR}/postgresql.confd" postgresql-${SLOT} || die "Inserting conf failed" - sed -e "s/@SLOT@/${SLOT}/g" -i "${WORKDIR}"/postgresql.init - newinitd "${WORKDIR}/postgresql.init" postgresql-${SLOT} || die "Inserting conf failed" - - use pam && pamd_mimic system-auth postgresql auth account session - - keepdir /var/run/postgresql - fperms 0770 /var/run/postgresql - use prefix || fowners postgres:postgres /var/run/postgresql -} - -pkg_postinst() { - postgresql-config update - - elog "The Unix-domain socket is located in:" - elog " ${EROOT%/}/var/run/postgresql/" - elog - elog "If you have users and/or services that you would like to utilize the socket," - elog "you must add them to the 'postgres' system group:" - elog " usermod -a -G postgres <user>" - elog - elog "Before initializing the database, you may want to edit PG_INITDB_OPTS so that" - elog "it contains your preferred locale in:" - elog " ${EROOT%/}/etc/conf.d/postgresql-${SLOT}" - elog - elog "Then, execute the following command to setup the initial database" - elog "environment:" - elog " emerge --config =${CATEGORY}/${PF}" -} - -pkg_postrm() { - postgresql-config update -} - -pkg_config() { - [[ -f "${EROOT%/}/etc/conf.d/postgresql-${SLOT}" ]] && source "${EROOT%/}/etc/conf.d/postgresql-${SLOT}" - [[ -z "${PGDATA}" ]] && PGDATA="${EROOT%/}/etc/postgresql-${SLOT}/" - [[ -z "${DATA_DIR}" ]] && DATA_DIR="${EROOT%/}/var/lib/postgresql/${SLOT}/data" - - # environment.bz2 may not contain the same locale as the current system - # locale. Unset and source from the current system locale. - if [ -f "${EROOT%/}/etc/env.d/02locale" ]; then - unset LANG - unset LC_CTYPE - unset LC_NUMERIC - unset LC_TIME - unset LC_COLLATE - unset LC_MONETARY - unset LC_MESSAGES - unset LC_ALL - source "${EROOT%/}/etc/env.d/02locale" - [ -n "${LANG}" ] && export LANG - [ -n "${LC_CTYPE}" ] && export LC_CTYPE - [ -n "${LC_NUMERIC}" ] && export LC_NUMERIC - [ -n "${LC_TIME}" ] && export LC_TIME - [ -n "${LC_COLLATE}" ] && export LC_COLLATE - [ -n "${LC_MONETARY}" ] && export LC_MONETARY - [ -n "${LC_MESSAGES}" ] && export LC_MESSAGES - [ -n "${LC_ALL}" ] && export LC_ALL - fi - - einfo "You can modify the paths and options passed to initdb by editing:" - einfo " ${EROOT%/}/etc/conf.d/postgresql-${SLOT}" - einfo - einfo "Information on options that can be passed to initdb are found at:" - einfo " http://www.postgresql.org/docs/${SLOT}/static/creating-cluster.html" - einfo " http://www.postgresql.org/docs/${SLOT}/static/app-initdb.html" - einfo - einfo "PG_INITDB_OPTS is currently set to:" - if [[ -z "${PG_INITDB_OPTS}" ]] ; then - einfo " (none)" - else - einfo " ${PG_INITDB_OPTS}" - fi - einfo - einfo "Configuration files will be installed to:" - einfo " ${PGDATA}" - einfo - einfo "The database cluster will be created in:" - einfo " ${DATA_DIR}" - einfo - while [ "$correct" != "true" ] ; do - einfo "Are you ready to continue? (y/n)" - read answer - if [[ $answer =~ ^[Yy]([Ee][Ss])?$ ]] ; then - correct="true" - elif [[ $answer =~ ^[Nn]([Oo])?$ ]] ; then - die "Aborting initialization." - else - echo "Answer not recognized" - fi - done - - if [ -n "$(ls -A ${DATA_DIR} 2> /dev/null)" ] ; then - eerror "The given directory, '${DATA_DIR}', is not empty." - eerror "Modify DATA_DIR to point to an empty directory." - die "${DATA_DIR} is not empty." - fi - - [ -z "${PG_MAX_CONNECTIONS}" ] && PG_MAX_CONNECTIONS="128" - einfo "Checking system parameters..." - - if ! use kernel_linux ; then - einfo "Skipped." - einfo " Tests not supported on this OS (yet)" - else - if [ -z ${SKIP_SYSTEM_TESTS} ] ; then - einfo "Checking whether your system supports at least ${PG_MAX_CONNECTIONS} connections..." - - local SEMMSL=$(sysctl -n kernel.sem | cut -f1) - local SEMMNS=$(sysctl -n kernel.sem | cut -f2) - local SEMMNI=$(sysctl -n kernel.sem | cut -f4) - local SHMMAX=$(sysctl -n kernel.shmmax) - - local SEMMSL_MIN=17 - local SEMMNS_MIN=$(( ( ${PG_MAX_CONNECTIONS}/16 ) * 17 )) - local SEMMNI_MIN=$(( ( ${PG_MAX_CONNECTIONS}+15 ) / 16 )) - local SHMMAX_MIN=$(( 500000 + ( 30600 * ${PG_MAX_CONNECTIONS} ) )) - - for p in SEMMSL SEMMNS SEMMNI SHMMAX ; do - if [ $(eval echo \$$p) -lt $(eval echo \$${p}_MIN) ] ; then - eerror "The value for ${p} $(eval echo \$$p) is below the recommended value $(eval echo \$${p}_MIN)" - eerror "You have now several options:" - eerror " - Change the mentioned system parameter" - eerror " - Lower the number of max.connections by setting PG_MAX_CONNECTIONS to a" - eerror " value lower than ${PG_MAX_CONNECTIONS}" - eerror " - Set SKIP_SYSTEM_TESTS in case you want to ignore this test completely" - eerror "More information can be found here:" - eerror " http://www.postgresql.org/docs/${SLOT}/static/kernel-resources.html" - die "System test failed." - fi - done - einfo "Passed." - else - ewarn "SKIP_SYSTEM_TESTS set, so skipping." - fi - fi - - einfo "Creating the data directory ..." - if [[ ${EUID} == 0 ]] ; then - mkdir -p "${DATA_DIR}" - chown -Rf postgres:postgres "${DATA_DIR}" - chmod 0700 "${DATA_DIR}" - fi - - einfo "Initializing the database ..." - - if [[ ${EUID} == 0 ]] ; then - su postgres -c "${EROOT%/}/usr/$(get_libdir)/postgresql-${SLOT}/bin/initdb -D \"${DATA_DIR}\" ${PG_INITDB_OPTS}" - else - "${EROOT%/}"/usr/$(get_libdir)/postgresql-${SLOT}/bin/initdb -U postgres -D "${DATA_DIR}" ${PG_INITDB_OPTS} - fi - - mv "${DATA_DIR%/}"/*.conf "${PGDATA}" - - einfo "The autovacuum function, which was in contrib, has been moved to the main" - einfo "PostgreSQL functions starting with 8.1, and starting with 8.4 is now enabled" - einfo "by default. You can disable it in the cluster's:" - einfo " ${PGDATA%/}/postgresql.conf" - einfo - einfo "The PostgreSQL server, by default, will log events to:" - einfo " ${DATA_DIR%/}/postmaster.log" - einfo - if use prefix ; then - einfo "The location of the configuration files have moved to:" - einfo " ${PGDATA}" - einfo "To start the server:" - einfo " pg_ctl start -D ${DATA_DIR} -o '-D ${PGDATA} --data-directory=${DATA_DIR}'" - einfo "To stop:" - einfo " pg_ctl stop -D ${DATA_DIR}" - einfo - einfo "Or move the configuration files back:" - einfo "mv ${PGDATA}*.conf ${DATA_DIR}" - else - einfo "You should use the '${EROOT%/}/etc/init.d/postgresql-${SLOT}' script to run PostgreSQL" - einfo "instead of 'pg_ctl'." - fi -} - -src_test() { - einfo ">>> Test phase [check]: ${CATEGORY}/${PF}" - - if [ ${UID} -ne 0 ] ; then - emake -j1 check || die "Make check failed. See above for details." - - einfo "If you think other tests besides the regression tests are necessary, please" - einfo "submit a bug including a patch for this ebuild to enable them." - else - ewarn "Tests cannot be run as root. Skipping." - ewarn "HINT: FEATURES=\"userpriv\"" - fi -} diff --git a/dev-db/postgresql-server/postgresql-server-9.1.2-r1.ebuild b/dev-db/postgresql-server/postgresql-server-9.1.2-r1.ebuild deleted file mode 100644 index f45b0124927f..000000000000 --- a/dev-db/postgresql-server/postgresql-server-9.1.2-r1.ebuild +++ /dev/null @@ -1,337 +0,0 @@ -# Copyright 1999-2012 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/dev-db/postgresql-server/postgresql-server-9.1.2-r1.ebuild,v 1.3 2012/02/02 20:30:53 ranger Exp $ - -EAPI="3" -PYTHON_DEPEND="python? 2" - -WANT_AUTOMAKE="none" -inherit autotools eutils flag-o-matic multilib pam prefix python versionator - -KEYWORDS="~alpha amd64 ~arm ~hppa ~ia64 ~mips ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~x86-fbsd ~ppc-macos ~x86-solaris" - -SLOT="$(get_version_component_range 1-2)" -S="${WORKDIR}/postgresql-${PV}" - -DESCRIPTION="PostgreSQL server" -HOMEPAGE="http://www.postgresql.org/" -SRC_URI="mirror://postgresql/source/v${PV}/postgresql-${PV}.tar.bz2 - http://dev.gentoo.org/~titanofold/postgresql-patches-9.1-r1.tbz2 - http://dev.gentoo.org/~titanofold/postgresql-initscript-2.0.tbz2" -LICENSE="POSTGRESQL" - -LINGUAS="af cs de en es fa fr hr hu it ko nb pl pt_BR ro ru sk sl sv tr zh_CN zh_TW" -IUSE="doc kernel_linux nls pam perl -pg_legacytimestamp python selinux tcl uuid xml" - -for lingua in ${LINGUAS}; do - IUSE+=" linguas_${lingua}" -done - -wanted_languages() { - local enable_langs - - for lingua in ${LINGUAS} ; do - use linguas_${lingua} && enable_langs+="${lingua} " - done - - echo -n ${enable_langs} -} - -RDEPEND="~dev-db/postgresql-base-${PV}:${SLOT}[pam?,pg_legacytimestamp=,nls=] - perl? ( >=dev-lang/perl-5.8 ) - selinux? ( sec-policy/selinux-postgresql ) - tcl? ( >=dev-lang/tcl-8 ) - uuid? ( dev-libs/ossp-uuid ) - xml? ( dev-libs/libxml2 dev-libs/libxslt )" -DEPEND="${RDEPEND} - sys-devel/flex - xml? ( dev-util/pkgconfig )" -PDEPEND="doc? ( ~dev-db/postgresql-docs-${PV} )" - -# Support /var/run or /run for the socket directory -[[ ! -d /run ]] && RUNDIR=/var - -pkg_setup() { - enewgroup postgres 70 - enewuser postgres 70 /bin/bash /var/lib/postgresql postgres - - use python && python_set_active_version 2 -} - -src_prepare() { - epatch "${WORKDIR}/autoconf.patch" \ - "${WORKDIR}/bool.patch" \ - "${WORKDIR}/pg_ctl-exit-status.patch" \ - "${WORKDIR}/server.patch" - - eprefixify src/include/pg_config_manual.h - - if use test ; then - epatch "${WORKDIR}/regress.patch" - sed -e "s|@SOCKETDIR@|${T}|g" -i src/test/regress/pg_regress{,_main}.c - sed -e "s|/no/such/location|${S}/src/test/regress/tmp_check/no/such/location|g" \ - -i src/test/regress/{input,output}/tablespace.source - else - echo "all install:" > "${S}/src/test/regress/GNUmakefile" - fi - - sed -e "s|@RUNDIR@|${RUNDIR}|g" \ - -i src/include/pg_config_manual.h "${WORKDIR}/postgresql.init" || \ - die "RUNDIR sed failed" - sed -e "s|@SLOT@|${SLOT}|g" \ - -i "${WORKDIR}/postgresql.init" "${WORKDIR}/postgresql.confd" || \ - die "SLOT sed failed" - - eautoconf -} - -src_configure() { - case ${CHOST} in - *-darwin*|*-solaris*) - use nls && append-libs intl - ;; - esac - - local PO="${EPREFIX%/}" - - # eval is needed to get along with pg_config quotation of space-rich entities. - eval econf "$(${PO}/usr/$(get_libdir)/postgresql-${SLOT}/bin/pg_config --configure)" \ - $(use_with perl) \ - $(use_with python) \ - $(use_with tcl) \ - $(use_with xml libxml) \ - $(use_with xml libxslt) \ - $(use_with uuid ossp-uuid) \ - --with-system-tzdata="${PO}/usr/share/zoneinfo" \ - --with-includes="${PO}/usr/include/postgresql-${SLOT}/" \ - --with-libraries="${PO}/usr/$(get_libdir)/postgresql-${SLOT}/$(get_libdir)" \ - "$(use_enable nls nls "$(wanted_languages)")" -} - -src_compile() { - local bd - for bd in . contrib $(use xml && echo contrib/xml2); do - PATH="${EROOT%/}/usr/$(get_libdir)/postgresql-${SLOT}/bin:${PATH}" \ - emake -C $bd || die "emake in $bd failed" - done -} - -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 - - local bd - for bd in . contrib $(use xml && echo contrib/xml2) ; do - PATH="${EROOT%/}/usr/$(get_libdir)/postgresql-${SLOT}/bin:${PATH}" \ - emake install -C $bd DESTDIR="${D}" || die "emake install in $bd failed" - done - - dodoc README HISTORY doc/{TODO,bug.template} - - dodir /etc/eselect/postgresql/slots/${SLOT} - echo "postgres_ebuilds=\"\${postgres_ebuilds} ${PF}\"" > \ - "${ED}/etc/eselect/postgresql/slots/${SLOT}/server" - - newconfd "${WORKDIR}/postgresql.confd" postgresql-${SLOT} || \ - die "Inserting conf failed" - newinitd "${WORKDIR}/postgresql.init" postgresql-${SLOT} || \ - die "Inserting conf failed" - - use pam && pamd_mimic system-auth postgresql auth account session - - if use prefix ; then - keepdir ${RUNDIR}/run/postgresql - fperms 0770 ${RUNDIR}/run/postgresql - fi -} - -pkg_postinst() { - postgresql-config update - - elog "Gentoo specific documentation:" - elog "http://www.gentoo.org/doc/en/postgres-howto.xml" - elog - elog "Official documentation:" - elog "http://www.postgresql.org/docs/${SLOT}/static/index.html" - elog - elog "The default location of the Unix-domain socket is:" - elog " ${EROOT%/}${RUNDIR}/run/postgresql/" - elog - elog "If you have users and/or services that you would like to utilize the" - elog "socket, you must add them to the 'postgres' system group:" - elog " usermod -a -G postgres <user>" - elog - elog "Before initializing the database, you may want to edit PG_INITDB_OPTS" - elog "so that it contains your preferred locale in:" - elog " ${EROOT%/}/etc/conf.d/postgresql-${SLOT}" - elog - elog "Then, execute the following command to setup the initial database" - elog "environment:" - elog " emerge --config =${CATEGORY}/${PF}" -} - -pkg_postrm() { - postgresql-config update -} - -pkg_config() { - [[ -f "${EROOT%/}/etc/conf.d/postgresql-${SLOT}" ]] && source "${EROOT%/}/etc/conf.d/postgresql-${SLOT}" - [[ -z "${PGDATA}" ]] && PGDATA="${EROOT%/}/etc/postgresql-${SLOT}/" - [[ -z "${DATA_DIR}" ]] && DATA_DIR="${EROOT%/}/var/lib/postgresql/${SLOT}/data" - - # environment.bz2 may not contain the same locale as the current system - # locale. Unset and source from the current system locale. - if [ -f "${EROOT%/}/etc/env.d/02locale" ]; then - unset LANG - unset LC_CTYPE - unset LC_NUMERIC - unset LC_TIME - unset LC_COLLATE - unset LC_MONETARY - unset LC_MESSAGES - unset LC_ALL - source "${EROOT%/}/etc/env.d/02locale" - [ -n "${LANG}" ] && export LANG - [ -n "${LC_CTYPE}" ] && export LC_CTYPE - [ -n "${LC_NUMERIC}" ] && export LC_NUMERIC - [ -n "${LC_TIME}" ] && export LC_TIME - [ -n "${LC_COLLATE}" ] && export LC_COLLATE - [ -n "${LC_MONETARY}" ] && export LC_MONETARY - [ -n "${LC_MESSAGES}" ] && export LC_MESSAGES - [ -n "${LC_ALL}" ] && export LC_ALL - fi - - einfo "You can modify the paths and options passed to initdb by editing:" - einfo " ${EROOT%/}/etc/conf.d/postgresql-${SLOT}" - einfo - einfo "Information on options that can be passed to initdb are found at:" - einfo " http://www.postgresql.org/docs/${SLOT}/static/creating-cluster.html" - einfo " http://www.postgresql.org/docs/${SLOT}/static/app-initdb.html" - einfo - einfo "PG_INITDB_OPTS is currently set to:" - if [[ -z "${PG_INITDB_OPTS}" ]] ; then - einfo " (none)" - else - einfo " ${PG_INITDB_OPTS}" - fi - einfo - einfo "Configuration files will be installed to:" - einfo " ${PGDATA}" - einfo - einfo "The database cluster will be created in:" - einfo " ${DATA_DIR}" - einfo - while [ "$correct" != "true" ] ; do - einfo "Are you ready to continue? (y/n)" - read answer - if [[ $answer =~ ^[Yy]([Ee][Ss])?$ ]] ; then - correct="true" - elif [[ $answer =~ ^[Nn]([Oo])?$ ]] ; then - die "Aborting initialization." - else - echo "Answer not recognized" - fi - done - - if [ -n "$(ls -A ${DATA_DIR} 2> /dev/null)" ] ; then - eerror "The given directory, '${DATA_DIR}', is not empty." - eerror "Modify DATA_DIR to point to an empty directory." - die "${DATA_DIR} is not empty." - fi - - [ -z "${PG_MAX_CONNECTIONS}" ] && PG_MAX_CONNECTIONS="128" - einfo "Checking system parameters..." - - if ! use kernel_linux ; then - einfo "Skipped." - einfo " Tests not supported on this OS (yet)" - else - if [ -z ${SKIP_SYSTEM_TESTS} ] ; then - einfo "Checking whether your system supports at least ${PG_MAX_CONNECTIONS} connections..." - - local SEMMSL=$(sysctl -n kernel.sem | cut -f1) - local SEMMNS=$(sysctl -n kernel.sem | cut -f2) - local SEMMNI=$(sysctl -n kernel.sem | cut -f4) - local SHMMAX=$(sysctl -n kernel.shmmax) - - local SEMMSL_MIN=17 - local SEMMNS_MIN=$(( ( ${PG_MAX_CONNECTIONS}/16 ) * 17 )) - local SEMMNI_MIN=$(( ( ${PG_MAX_CONNECTIONS}+15 ) / 16 )) - local SHMMAX_MIN=$(( 500000 + ( 30600 * ${PG_MAX_CONNECTIONS} ) )) - - for p in SEMMSL SEMMNS SEMMNI SHMMAX ; do - if [ $(eval echo \$$p) -lt $(eval echo \$${p}_MIN) ] ; then - eerror "The value for ${p} $(eval echo \$$p) is below the recommended value $(eval echo \$${p}_MIN)" - eerror "You have now several options:" - eerror " - Change the mentioned system parameter" - eerror " - Lower the number of max.connections by setting PG_MAX_CONNECTIONS to a" - eerror " value lower than ${PG_MAX_CONNECTIONS}" - eerror " - Set SKIP_SYSTEM_TESTS in case you want to ignore this test completely" - eerror "More information can be found here:" - eerror " http://www.postgresql.org/docs/${SLOT}/static/kernel-resources.html" - die "System test failed." - fi - done - einfo "Passed." - else - ewarn "SKIP_SYSTEM_TESTS set, so skipping." - fi - fi - - einfo "Creating the data directory ..." - if [[ ${EUID} == 0 ]] ; then - mkdir -p "${DATA_DIR}" - chown -Rf postgres:postgres "${DATA_DIR}" - chmod 0700 "${DATA_DIR}" - fi - - einfo "Initializing the database ..." - - if [[ ${EUID} == 0 ]] ; then - su postgres -c "${EROOT%/}/usr/$(get_libdir)/postgresql-${SLOT}/bin/initdb -D \"${DATA_DIR}\" ${PG_INITDB_OPTS}" - else - "${EROOT%/}"/usr/$(get_libdir)/postgresql-${SLOT}/bin/initdb -U postgres -D "${DATA_DIR}" ${PG_INITDB_OPTS} - fi - - mv "${DATA_DIR%/}"/*.conf "${PGDATA}" - - einfo "The autovacuum function, which was in contrib, has been moved to the main" - einfo "PostgreSQL functions starting with 8.1, and starting with 8.4 is now enabled" - einfo "by default. You can disable it in the cluster's:" - einfo " ${PGDATA%/}/postgresql.conf" - einfo - einfo "The PostgreSQL server, by default, will log events to:" - einfo " ${DATA_DIR%/}/postmaster.log" - einfo - if use prefix ; then - einfo "The location of the configuration files have moved to:" - einfo " ${PGDATA}" - einfo "To start the server:" - einfo " pg_ctl start -D ${DATA_DIR} -o '-D ${PGDATA} --data-directory=${DATA_DIR}'" - einfo "To stop:" - einfo " pg_ctl stop -D ${DATA_DIR}" - einfo - einfo "Or move the configuration files back:" - einfo "mv ${PGDATA}*.conf ${DATA_DIR}" - else - einfo "You should use the '${EROOT%/}/etc/init.d/postgresql-${SLOT}' script to run PostgreSQL" - einfo "instead of 'pg_ctl'." - fi -} - -src_test() { - einfo ">>> Test phase [check]: ${CATEGORY}/${PF}" - - if [ ${UID} -ne 0 ] ; then - emake -j1 check || die "Make check failed. See above for details." - - einfo "If you think other tests besides the regression tests are necessary, please" - einfo "submit a bug including a patch for this ebuild to enable them." - else - ewarn "Tests cannot be run as root. Skipping." - ewarn "HINT: FEATURES=\"userpriv\"" - fi -} diff --git a/dev-db/postgresql-server/postgresql-server-9.1.2-r2.ebuild b/dev-db/postgresql-server/postgresql-server-9.1.2-r2.ebuild deleted file mode 100644 index 0ad87e2ac8f3..000000000000 --- a/dev-db/postgresql-server/postgresql-server-9.1.2-r2.ebuild +++ /dev/null @@ -1,337 +0,0 @@ -# Copyright 1999-2012 Gentoo Foundation -# Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/dev-db/postgresql-server/postgresql-server-9.1.2-r2.ebuild,v 1.6 2012/02/19 13:25:25 klausman Exp $ - -EAPI="3" -PYTHON_DEPEND="python? 2" - -WANT_AUTOMAKE="none" -inherit autotools eutils flag-o-matic multilib pam prefix python versionator - -KEYWORDS="alpha amd64 arm hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc x86 ~x86-fbsd ~ppc-macos ~x86-solaris" - -SLOT="$(get_version_component_range 1-2)" -S="${WORKDIR}/postgresql-${PV}" - -DESCRIPTION="PostgreSQL server" -HOMEPAGE="http://www.postgresql.org/" -SRC_URI="mirror://postgresql/source/v${PV}/postgresql-${PV}.tar.bz2 - http://dev.gentoo.org/~titanofold/postgresql-patches-9.1-r1.tbz2 - http://dev.gentoo.org/~titanofold/postgresql-initscript-2.1.tbz2" -LICENSE="POSTGRESQL" - -LINGUAS="af cs de en es fa fr hr hu it ko nb pl pt_BR ro ru sk sl sv tr zh_CN zh_TW" -IUSE="doc kernel_linux nls pam perl -pg_legacytimestamp python selinux tcl uuid xml" - -for lingua in ${LINGUAS}; do - IUSE+=" linguas_${lingua}" -done - -wanted_languages() { - local enable_langs - - for lingua in ${LINGUAS} ; do - use linguas_${lingua} && enable_langs+="${lingua} " - done - - echo -n ${enable_langs} -} - -RDEPEND="~dev-db/postgresql-base-${PV}:${SLOT}[pam?,pg_legacytimestamp=,nls=] - perl? ( >=dev-lang/perl-5.8 ) - selinux? ( sec-policy/selinux-postgresql ) - tcl? ( >=dev-lang/tcl-8 ) - uuid? ( dev-libs/ossp-uuid ) - xml? ( dev-libs/libxml2 dev-libs/libxslt )" -DEPEND="${RDEPEND} - sys-devel/flex - xml? ( dev-util/pkgconfig )" -PDEPEND="doc? ( ~dev-db/postgresql-docs-${PV} )" - -# Support /var/run or /run for the socket directory -[[ ! -d /run ]] && RUNDIR=/var - -pkg_setup() { - enewgroup postgres 70 - enewuser postgres 70 /bin/bash /var/lib/postgresql postgres - - use python && python_set_active_version 2 -} - -src_prepare() { - epatch "${WORKDIR}/autoconf.patch" \ - "${WORKDIR}/bool.patch" \ - "${WORKDIR}/pg_ctl-exit-status.patch" \ - "${WORKDIR}/server.patch" - - eprefixify src/include/pg_config_manual.h - - if use test ; then - epatch "${WORKDIR}/regress.patch" - sed -e "s|@SOCKETDIR@|${T}|g" -i src/test/regress/pg_regress{,_main}.c - sed -e "s|/no/such/location|${S}/src/test/regress/tmp_check/no/such/location|g" \ - -i src/test/regress/{input,output}/tablespace.source - else - echo "all install:" > "${S}/src/test/regress/GNUmakefile" - fi - - sed -e "s|@RUNDIR@|${RUNDIR}|g" \ - -i src/include/pg_config_manual.h "${WORKDIR}/postgresql.init" || \ - die "RUNDIR sed failed" - sed -e "s|@SLOT@|${SLOT}|g" \ - -i "${WORKDIR}/postgresql.init" "${WORKDIR}/postgresql.confd" || \ - die "SLOT sed failed" - - eautoconf -} - -src_configure() { - case ${CHOST} in - *-darwin*|*-solaris*) - use nls && append-libs intl - ;; - esac - - local PO="${EPREFIX%/}" - - # eval is needed to get along with pg_config quotation of space-rich entities. - eval econf "$(${PO}/usr/$(get_libdir)/postgresql-${SLOT}/bin/pg_config --configure)" \ - $(use_with perl) \ - $(use_with python) \ - $(use_with tcl) \ - $(use_with xml libxml) \ - $(use_with xml libxslt) \ - $(use_with uuid ossp-uuid) \ - --with-system-tzdata="${PO}/usr/share/zoneinfo" \ - --with-includes="${PO}/usr/include/postgresql-${SLOT}/" \ - --with-libraries="${PO}/usr/$(get_libdir)/postgresql-${SLOT}/$(get_libdir)" \ - "$(use_enable nls nls "$(wanted_languages)")" -} - -src_compile() { - local bd - for bd in . contrib $(use xml && echo contrib/xml2); do - PATH="${EROOT%/}/usr/$(get_libdir)/postgresql-${SLOT}/bin:${PATH}" \ - emake -C $bd || die "emake in $bd failed" - done -} - -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 - - local bd - for bd in . contrib $(use xml && echo contrib/xml2) ; do - PATH="${EROOT%/}/usr/$(get_libdir)/postgresql-${SLOT}/bin:${PATH}" \ - emake install -C $bd DESTDIR="${D}" || die "emake install in $bd failed" - done - - dodoc README HISTORY doc/{TODO,bug.template} - - dodir /etc/eselect/postgresql/slots/${SLOT} - echo "postgres_ebuilds=\"\${postgres_ebuilds} ${PF}\"" > \ - "${ED}/etc/eselect/postgresql/slots/${SLOT}/server" - - newconfd "${WORKDIR}/postgresql.confd" postgresql-${SLOT} || \ - die "Inserting conf failed" - newinitd "${WORKDIR}/postgresql.init" postgresql-${SLOT} || \ - die "Inserting conf failed" - - use pam && pamd_mimic system-auth postgresql auth account session - - if use prefix ; then - keepdir ${RUNDIR}/run/postgresql - fperms 0770 ${RUNDIR}/run/postgresql - fi -} - -pkg_postinst() { - postgresql-config update - - elog "Gentoo specific documentation:" - elog "http://www.gentoo.org/doc/en/postgres-howto.xml" - elog - elog "Official documentation:" - elog "http://www.postgresql.org/docs/${SLOT}/static/index.html" - elog - elog "The default location of the Unix-domain socket is:" - elog " ${EROOT%/}${RUNDIR}/run/postgresql/" - elog - elog "If you have users and/or services that you would like to utilize the" - elog "socket, you must add them to the 'postgres' system group:" - elog " usermod -a -G postgres <user>" - elog - elog "Before initializing the database, you may want to edit PG_INITDB_OPTS" - elog "so that it contains your preferred locale in:" - elog " ${EROOT%/}/etc/conf.d/postgresql-${SLOT}" - elog - elog "Then, execute the following command to setup the initial database" - elog "environment:" - elog " emerge --config =${CATEGORY}/${PF}" -} - -pkg_postrm() { - postgresql-config update -} - -pkg_config() { - [[ -f "${EROOT%/}/etc/conf.d/postgresql-${SLOT}" ]] && source "${EROOT%/}/etc/conf.d/postgresql-${SLOT}" - [[ -z "${PGDATA}" ]] && PGDATA="${EROOT%/}/etc/postgresql-${SLOT}/" - [[ -z "${DATA_DIR}" ]] && DATA_DIR="${EROOT%/}/var/lib/postgresql/${SLOT}/data" - - # environment.bz2 may not contain the same locale as the current system - # locale. Unset and source from the current system locale. - if [ -f "${EROOT%/}/etc/env.d/02locale" ]; then - unset LANG - unset LC_CTYPE - unset LC_NUMERIC - unset LC_TIME - unset LC_COLLATE - unset LC_MONETARY - unset LC_MESSAGES - unset LC_ALL - source "${EROOT%/}/etc/env.d/02locale" - [ -n "${LANG}" ] && export LANG - [ -n "${LC_CTYPE}" ] && export LC_CTYPE - [ -n "${LC_NUMERIC}" ] && export LC_NUMERIC - [ -n "${LC_TIME}" ] && export LC_TIME - [ -n "${LC_COLLATE}" ] && export LC_COLLATE - [ -n "${LC_MONETARY}" ] && export LC_MONETARY - [ -n "${LC_MESSAGES}" ] && export LC_MESSAGES - [ -n "${LC_ALL}" ] && export LC_ALL - fi - - einfo "You can modify the paths and options passed to initdb by editing:" - einfo " ${EROOT%/}/etc/conf.d/postgresql-${SLOT}" - einfo - einfo "Information on options that can be passed to initdb are found at:" - einfo " http://www.postgresql.org/docs/${SLOT}/static/creating-cluster.html" - einfo " http://www.postgresql.org/docs/${SLOT}/static/app-initdb.html" - einfo - einfo "PG_INITDB_OPTS is currently set to:" - if [[ -z "${PG_INITDB_OPTS}" ]] ; then - einfo " (none)" - else - einfo " ${PG_INITDB_OPTS}" - fi - einfo - einfo "Configuration files will be installed to:" - einfo " ${PGDATA}" - einfo - einfo "The database cluster will be created in:" - einfo " ${DATA_DIR}" - einfo - while [ "$correct" != "true" ] ; do - einfo "Are you ready to continue? (y/n)" - read answer - if [[ $answer =~ ^[Yy]([Ee][Ss])?$ ]] ; then - correct="true" - elif [[ $answer =~ ^[Nn]([Oo])?$ ]] ; then - die "Aborting initialization." - else - echo "Answer not recognized" - fi - done - - if [ -n "$(ls -A ${DATA_DIR} 2> /dev/null)" ] ; then - eerror "The given directory, '${DATA_DIR}', is not empty." - eerror "Modify DATA_DIR to point to an empty directory." - die "${DATA_DIR} is not empty." - fi - - [ -z "${PG_MAX_CONNECTIONS}" ] && PG_MAX_CONNECTIONS="128" - einfo "Checking system parameters..." - - if ! use kernel_linux ; then - einfo "Skipped." - einfo " Tests not supported on this OS (yet)" - else - if [ -z ${SKIP_SYSTEM_TESTS} ] ; then - einfo "Checking whether your system supports at least ${PG_MAX_CONNECTIONS} connections..." - - local SEMMSL=$(sysctl -n kernel.sem | cut -f1) - local SEMMNS=$(sysctl -n kernel.sem | cut -f2) - local SEMMNI=$(sysctl -n kernel.sem | cut -f4) - local SHMMAX=$(sysctl -n kernel.shmmax) - - local SEMMSL_MIN=17 - local SEMMNS_MIN=$(( ( ${PG_MAX_CONNECTIONS}/16 ) * 17 )) - local SEMMNI_MIN=$(( ( ${PG_MAX_CONNECTIONS}+15 ) / 16 )) - local SHMMAX_MIN=$(( 500000 + ( 30600 * ${PG_MAX_CONNECTIONS} ) )) - - for p in SEMMSL SEMMNS SEMMNI SHMMAX ; do - if [ $(eval echo \$$p) -lt $(eval echo \$${p}_MIN) ] ; then - eerror "The value for ${p} $(eval echo \$$p) is below the recommended value $(eval echo \$${p}_MIN)" - eerror "You have now several options:" - eerror " - Change the mentioned system parameter" - eerror " - Lower the number of max.connections by setting PG_MAX_CONNECTIONS to a" - eerror " value lower than ${PG_MAX_CONNECTIONS}" - eerror " - Set SKIP_SYSTEM_TESTS in case you want to ignore this test completely" - eerror "More information can be found here:" - eerror " http://www.postgresql.org/docs/${SLOT}/static/kernel-resources.html" - die "System test failed." - fi - done - einfo "Passed." - else - ewarn "SKIP_SYSTEM_TESTS set, so skipping." - fi - fi - - einfo "Creating the data directory ..." - if [[ ${EUID} == 0 ]] ; then - mkdir -p "${DATA_DIR}" - chown -Rf postgres:postgres "${DATA_DIR}" - chmod 0700 "${DATA_DIR}" - fi - - einfo "Initializing the database ..." - - if [[ ${EUID} == 0 ]] ; then - su postgres -c "${EROOT%/}/usr/$(get_libdir)/postgresql-${SLOT}/bin/initdb -D \"${DATA_DIR}\" ${PG_INITDB_OPTS}" - else - "${EROOT%/}"/usr/$(get_libdir)/postgresql-${SLOT}/bin/initdb -U postgres -D "${DATA_DIR}" ${PG_INITDB_OPTS} - fi - - mv "${DATA_DIR%/}"/*.conf "${PGDATA}" - - einfo "The autovacuum function, which was in contrib, has been moved to the main" - einfo "PostgreSQL functions starting with 8.1, and starting with 8.4 is now enabled" - einfo "by default. You can disable it in the cluster's:" - einfo " ${PGDATA%/}/postgresql.conf" - einfo - einfo "The PostgreSQL server, by default, will log events to:" - einfo " ${DATA_DIR%/}/postmaster.log" - einfo - if use prefix ; then - einfo "The location of the configuration files have moved to:" - einfo " ${PGDATA}" - einfo "To start the server:" - einfo " pg_ctl start -D ${DATA_DIR} -o '-D ${PGDATA} --data-directory=${DATA_DIR}'" - einfo "To stop:" - einfo " pg_ctl stop -D ${DATA_DIR}" - einfo - einfo "Or move the configuration files back:" - einfo "mv ${PGDATA}*.conf ${DATA_DIR}" - else - einfo "You should use the '${EROOT%/}/etc/init.d/postgresql-${SLOT}' script to run PostgreSQL" - einfo "instead of 'pg_ctl'." - fi -} - -src_test() { - einfo ">>> Test phase [check]: ${CATEGORY}/${PF}" - - if [ ${UID} -ne 0 ] ; then - emake -j1 check || die "Make check failed. See above for details." - - einfo "If you think other tests besides the regression tests are necessary, please" - einfo "submit a bug including a patch for this ebuild to enable them." - else - ewarn "Tests cannot be run as root. Skipping." - ewarn "HINT: FEATURES=\"userpriv\"" - fi -} |