diff options
author | Donnie Berkholz <dberkholz@gentoo.org> | 2006-09-05 23:17:09 +0000 |
---|---|---|
committer | Donnie Berkholz <dberkholz@gentoo.org> | 2006-09-05 23:17:09 +0000 |
commit | 4fa418725511b1830a6aaa4df1646f4a30ca4bd9 (patch) | |
tree | 497cab06c036aedd73a685611d86f79a8fb77921 /x11-base | |
parent | Mask =x11-base/xorg-server-1.1.1-r1 for mesa 6.5.1 release. (diff) | |
download | historical-4fa418725511b1830a6aaa4df1646f4a30ca4bd9.tar.gz historical-4fa418725511b1830a6aaa4df1646f4a30ca4bd9.tar.bz2 historical-4fa418725511b1830a6aaa4df1646f4a30ca4bd9.zip |
Bump. (#145797) Add patches for AIGLX+compiz. (#146197) Fix resolution switching with ctrl-alt-+/-. Install libxf86config + headers for pyxf86config, and extramodes and vesamodes for system-config-display. Do correct bash substitution for nvidia kdrive server. This uses a mesa snapshot in anticipation of the 6.5.1 release. Some changes will need to happen to get it back to using a standard Mesa release tarball.
Package-Manager: portage-2.1.1_rc1-r1
Diffstat (limited to 'x11-base')
-rw-r--r-- | x11-base/xorg-server/ChangeLog | 17 | ||||
-rw-r--r-- | x11-base/xorg-server/Manifest | 48 | ||||
-rw-r--r-- | x11-base/xorg-server/files/01-no-move-damage.patch | 33 | ||||
-rw-r--r-- | x11-base/xorg-server/files/02-dont-backfill-bg-none.patch | 21 | ||||
-rw-r--r-- | x11-base/xorg-server/files/03-tfp-damage.patch | 211 | ||||
-rw-r--r-- | x11-base/xorg-server/files/04-mesa-copy-sub-buffer.patch | 361 | ||||
-rw-r--r-- | x11-base/xorg-server/files/05-offscreen-pixmaps.patch | 55 | ||||
-rw-r--r-- | x11-base/xorg-server/files/06-aiglx-happy-vt-switch.patch | 241 | ||||
-rw-r--r-- | x11-base/xorg-server/files/1.1.1-fix-xrandr-zoom-keys.patch | 186 | ||||
-rw-r--r-- | x11-base/xorg-server/files/digest-xorg-server-1.1.1-r1 | 6 | ||||
-rw-r--r-- | x11-base/xorg-server/files/xorg-server-1.1.1-install-libxf86config-headers.patch | 19 | ||||
-rw-r--r-- | x11-base/xorg-server/xorg-server-1.1.1-r1.ebuild | 507 |
12 files changed, 1700 insertions, 5 deletions
diff --git a/x11-base/xorg-server/ChangeLog b/x11-base/xorg-server/ChangeLog index 8078b81a043c..4248d4c39aed 100644 --- a/x11-base/xorg-server/ChangeLog +++ b/x11-base/xorg-server/ChangeLog @@ -1,6 +1,21 @@ # ChangeLog for x11-base/xorg-server # Copyright 1999-2006 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/x11-base/xorg-server/ChangeLog,v 1.162 2006/09/03 14:48:35 joshuabaergen Exp $ +# $Header: /var/cvsroot/gentoo-x86/x11-base/xorg-server/ChangeLog,v 1.163 2006/09/05 23:17:08 dberkholz Exp $ + +*xorg-server-1.1.1-r1 (05 Sep 2006) + + 05 Sep 2006; Donnie Berkholz <dberkholz@gentoo.org>; + +files/01-no-move-damage.patch, +files/02-dont-backfill-bg-none.patch, + +files/03-tfp-damage.patch, +files/04-mesa-copy-sub-buffer.patch, + +files/05-offscreen-pixmaps.patch, +files/06-aiglx-happy-vt-switch.patch, + +files/xorg-server-1.1.1-install-libxf86config-headers.patch, + +files/1.1.1-fix-xrandr-zoom-keys.patch, +xorg-server-1.1.1-r1.ebuild: + Bump. (#145797) Add patches for AIGLX+compiz. (#146197) Fix resolution + switching with ctrl-alt-+/-. Install libxf86config + headers for + pyxf86config, and extramodes and vesamodes for system-config-display. Do + correct bash substitution for nvidia kdrive server. This uses a mesa + snapshot in anticipation of the 6.5.1 release. Some changes will need to + happen to get it back to using a standard Mesa release tarball. 03 Sep 2006; Joshua Baergen <joshuabaergen@gentoo.org> xorg-server-1.1.0-r1.ebuild, xorg-server-1.1.1.ebuild: diff --git a/x11-base/xorg-server/Manifest b/x11-base/xorg-server/Manifest index 728cd49e7cbe..cbabbc53e3ff 100644 --- a/x11-base/xorg-server/Manifest +++ b/x11-base/xorg-server/Manifest @@ -1,3 +1,27 @@ +AUX 01-no-move-damage.patch 1149 RMD160 f40d73e020376e1b9603dfa5ceb2fd0b48b45e31 SHA1 b8adef394d05a8769627d71b8da302f7fc3622d5 SHA256 9396f282e3d62927e86c4aa38b0d6245b83ca8e2ea48624f22c3c6d35751d997 +MD5 0faff1bfae0c6378fae5d2875fb3972c files/01-no-move-damage.patch 1149 +RMD160 f40d73e020376e1b9603dfa5ceb2fd0b48b45e31 files/01-no-move-damage.patch 1149 +SHA256 9396f282e3d62927e86c4aa38b0d6245b83ca8e2ea48624f22c3c6d35751d997 files/01-no-move-damage.patch 1149 +AUX 02-dont-backfill-bg-none.patch 581 RMD160 b38e5b7c945434e6b60748a5f853d7eb773f3427 SHA1 862c2435249d475dd7fdd229449a89b8e2f2207b SHA256 fe5e71b9b5cb7ea4b484e76015bf364e7e1e307c1d35ed3497dc30c9b75dc7ea +MD5 016e4e9f4bf2296ac756b476ff2c0495 files/02-dont-backfill-bg-none.patch 581 +RMD160 b38e5b7c945434e6b60748a5f853d7eb773f3427 files/02-dont-backfill-bg-none.patch 581 +SHA256 fe5e71b9b5cb7ea4b484e76015bf364e7e1e307c1d35ed3497dc30c9b75dc7ea files/02-dont-backfill-bg-none.patch 581 +AUX 03-tfp-damage.patch 5982 RMD160 7b044a9d151bdd573c80b93b7249888184fad782 SHA1 30c64426cb9db4e1fbabbd8bb8af92b3f7ed682d SHA256 dcc6fe0f6d4031b345e8f3a5a0f5bfbbf43db9ce972fb4ca7b58961fb178da59 +MD5 5994755d0cda4a71d78529f34bf798c7 files/03-tfp-damage.patch 5982 +RMD160 7b044a9d151bdd573c80b93b7249888184fad782 files/03-tfp-damage.patch 5982 +SHA256 dcc6fe0f6d4031b345e8f3a5a0f5bfbbf43db9ce972fb4ca7b58961fb178da59 files/03-tfp-damage.patch 5982 +AUX 04-mesa-copy-sub-buffer.patch 11609 RMD160 d525afd68510bed628742c28d29eec7c47e0592b SHA1 c9a654962fa930b3cced371ba9737f140c46612e SHA256 daeef79d8bd3ae91f2906f7fa62f15892307bfb5f1650ef832bd490a2d6606f5 +MD5 406413344cfe615626dc73f02c1baf5c files/04-mesa-copy-sub-buffer.patch 11609 +RMD160 d525afd68510bed628742c28d29eec7c47e0592b files/04-mesa-copy-sub-buffer.patch 11609 +SHA256 daeef79d8bd3ae91f2906f7fa62f15892307bfb5f1650ef832bd490a2d6606f5 files/04-mesa-copy-sub-buffer.patch 11609 +AUX 05-offscreen-pixmaps.patch 1548 RMD160 e0f87c88379861340524847a57bf72119256a610 SHA1 c57a9aafec35b8158098751028a76a2979379625 SHA256 73be09f2f3756021bd6261fc05733eb39084c2190e7ca107bfa01c7d447a34a6 +MD5 8cae706ff61477f510f9f14b3d64fea9 files/05-offscreen-pixmaps.patch 1548 +RMD160 e0f87c88379861340524847a57bf72119256a610 files/05-offscreen-pixmaps.patch 1548 +SHA256 73be09f2f3756021bd6261fc05733eb39084c2190e7ca107bfa01c7d447a34a6 files/05-offscreen-pixmaps.patch 1548 +AUX 06-aiglx-happy-vt-switch.patch 6043 RMD160 fce467afaa3988b511b9796af164f36172bf6b7b SHA1 ad8eaa9c48699501145a15cc22b98e88a2c4a0f2 SHA256 112f1cccc0f3e1af1d76109e845c0e89462b6e95c2fd1cc80ca9370806a617dc +MD5 e9248d96ffd078829f56f3d8075a5304 files/06-aiglx-happy-vt-switch.patch 6043 +RMD160 fce467afaa3988b511b9796af164f36172bf6b7b files/06-aiglx-happy-vt-switch.patch 6043 +SHA256 112f1cccc0f3e1af1d76109e845c0e89462b6e95c2fd1cc80ca9370806a617dc files/06-aiglx-happy-vt-switch.patch 6043 AUX 1.0.2-Xprint-xprintdir.patch 563 RMD160 559a4330ffe34a232e7e60dc9350925801beeb9b SHA1 3565e1fc60e062d0e176e69be00afedf4b08bd0a SHA256 eec3e9eab8fa9ba6f84bd76c0048ffb48f39749f7355bd4d7d1c8423cb34fae1 MD5 177828cd6b8ab3ce98f95bf2363d2036 files/1.0.2-Xprint-xprintdir.patch 563 RMD160 559a4330ffe34a232e7e60dc9350925801beeb9b files/1.0.2-Xprint-xprintdir.patch 563 @@ -22,6 +46,10 @@ AUX 1.0.99.901-Xprint-xprintdir.patch 447 RMD160 7728ad1173bb6e8fcb73ddcfc3ef29f MD5 e4ab51b8df81d9a3be044112dff3736f files/1.0.99.901-Xprint-xprintdir.patch 447 RMD160 7728ad1173bb6e8fcb73ddcfc3ef29f93cdde4f3 files/1.0.99.901-Xprint-xprintdir.patch 447 SHA256 4dcd1bcebfccf0b51956ea6f30bae2f0f9b7b1f62e215d16b63ef19b7433d955 files/1.0.99.901-Xprint-xprintdir.patch 447 +AUX 1.1.1-fix-xrandr-zoom-keys.patch 6332 RMD160 cec1b86e0a6ea88e1e65543046fd1b91ab112b04 SHA1 ebaea3bdff2564d898fe0f1bcacdafcbcfe4b9f6 SHA256 b7bb87d2170f2dd369a8b3a496dae0e93792419ccc7c78449e9affc8f07650ac +MD5 919801a6a806a9cf93777ee8bb4367bc files/1.1.1-fix-xrandr-zoom-keys.patch 6332 +RMD160 cec1b86e0a6ea88e1e65543046fd1b91ab112b04 files/1.1.1-fix-xrandr-zoom-keys.patch 6332 +SHA256 b7bb87d2170f2dd369a8b3a496dae0e93792419ccc7c78449e9affc8f07650ac files/1.1.1-fix-xrandr-zoom-keys.patch 6332 AUX 1.1.1-remove-altix.patch 16742 RMD160 1191f336728e336ee47e403e8038ffa3f4468870 SHA1 02bbc40bc4e8d80a208f172351ad5c95679c3acc SHA256 a74066ead6963d0d155dc107138b2ddab12f322f12c4c292ac9f38f388f63f85 MD5 d8e257c7497286562b6e44920ea0d65e files/1.1.1-remove-altix.patch 16742 RMD160 1191f336728e336ee47e403e8038ffa3f4468870 files/1.1.1-remove-altix.patch 16742 @@ -66,11 +94,16 @@ AUX xorg-server-1.1.0-setuid.diff 3373 RMD160 5d9c1e6696ed5eaa9de9425633c0bfee49 MD5 d806558d64462780cbd1512ab6dc4dd7 files/xorg-server-1.1.0-setuid.diff 3373 RMD160 5d9c1e6696ed5eaa9de9425633c0bfee493e6973 files/xorg-server-1.1.0-setuid.diff 3373 SHA256 af678fea5e624eb20a232b3db1a0f168085b780d8e627739fd8d088f033c2fd9 files/xorg-server-1.1.0-setuid.diff 3373 +AUX xorg-server-1.1.1-install-libxf86config-headers.patch 422 RMD160 297df8f5478195a8e0c0589436c9dad457c91539 SHA1 435f5d3c410a7e17b31c27c44a1f36145db626ea SHA256 85de5a76afb5a6c6ab0ac0d0f7d7decad99035cbbc04362e69a1627f04d86269 +MD5 f17556037156af0294c22e094172d1f6 files/xorg-server-1.1.1-install-libxf86config-headers.patch 422 +RMD160 297df8f5478195a8e0c0589436c9dad457c91539 files/xorg-server-1.1.1-install-libxf86config-headers.patch 422 +SHA256 85de5a76afb5a6c6ab0ac0d0f7d7decad99035cbbc04362e69a1627f04d86269 files/xorg-server-1.1.1-install-libxf86config-headers.patch 422 AUX xprint.init 598 RMD160 85de6a023912d8ac40cba4f32b5559655e0e281e SHA1 1590a29e11f813bb1353b4cc815708e97bfbb96b SHA256 9474c19d125d9534b93c038cba7c4bdc7c45bf3ed51279ff2e130fe031a15c13 MD5 9bf4e36931c99f405aa6766ff5614e51 files/xprint.init 598 RMD160 85de6a023912d8ac40cba4f32b5559655e0e281e files/xprint.init 598 SHA256 9474c19d125d9534b93c038cba7c4bdc7c45bf3ed51279ff2e130fe031a15c13 files/xprint.init 598 DIST 1.0.2-overlay-window.patch.bz2 6388 RMD160 f1223f88da72461585ff72e5cc3c0e15cd9a1306 SHA1 1e7e66ca37b0a08df754d060db03a1d5ccf7bc42 SHA256 99653c8f59a3d3dd2bd6979e4a52cfb81a32dd3d8bead0bd06274bad57823a67 +DIST Mesa-20060831.tar.bz2 5531569 RMD160 654eea5f311cd77ee46ded89208a0d8ae697facc SHA1 9423d8e9351b2112bd855706bbc588d284004297 SHA256 f6e18eaadf6a0b1c7f926be7e15829c115ca277b2720f5644cfc1bb93db00a49 DIST MesaLib-6.4.2.tar.bz2 2913009 RMD160 6bf1afc0d3bd3f5e3b5c1a019838f40603446509 SHA1 4f042bdf38c9eb62e04660bd18566e7ca50d8640 SHA256 bc84da436f9d92485dfa1c6670689c6807950a8372637c9952f689a1e1f9aa86 DIST MesaLib-6.5.tar.bz2 3062363 RMD160 6006bfdfed8a2425059c31ee699b5aca4d5f57cd SHA1 a77368901b0731b662d0858aef2c405a7ddf6014 SHA256 dcacf4c18af89b57e66dc7ba39e24c3b74ff6f83b8745bcc1390170a4190eebd DIST xorg-server-1.0.2.tar.bz2 6006486 RMD160 ee47746009fa7c36e692bf4bae629ccd1bd0d4b4 SHA1 b2257e984c5111093ca80f1f63a7a9befa20b6c0 SHA256 b30c57271d147c1f45ba7f15fcc7e7917b61c6dfb97d514e25c7bc91ddd970ba @@ -84,14 +117,18 @@ EBUILD xorg-server-1.1.0-r1.ebuild 24629 RMD160 6c55cc1b8e07d70e760850b46c5ca9ae MD5 9e62bcf6311908c6b51cf2baa18aae22 xorg-server-1.1.0-r1.ebuild 24629 RMD160 6c55cc1b8e07d70e760850b46c5ca9aec5735e24 xorg-server-1.1.0-r1.ebuild 24629 SHA256 6f7b6bd4e15aeca418623b365fae285ce17b5485931cd615142157d67b13fb76 xorg-server-1.1.0-r1.ebuild 24629 +EBUILD xorg-server-1.1.1-r1.ebuild 16323 RMD160 3a107311477e8be794ea7be79df59ea32e905010 SHA1 f35d9783b378b9049b9581724761df625dc99d93 SHA256 f34618d95571ea822061122f3fad3a89d9f741114c58d6f901c73d8ff25648c3 +MD5 2f239fcb54f4662ac0a04f38bbcd3e1c xorg-server-1.1.1-r1.ebuild 16323 +RMD160 3a107311477e8be794ea7be79df59ea32e905010 xorg-server-1.1.1-r1.ebuild 16323 +SHA256 f34618d95571ea822061122f3fad3a89d9f741114c58d6f901c73d8ff25648c3 xorg-server-1.1.1-r1.ebuild 16323 EBUILD xorg-server-1.1.1.ebuild 15697 RMD160 d9f04723d983a55ff7a0ce90c67f1af7fd83bc8e SHA1 202cd14869936b610c7d0c0e8ee8e49dc3459c1e SHA256 bf4fa6b3db19aba2936fb3393ecd21940ee97d2e1fd3c1ae6cdb939507cfcbb8 MD5 be367a0cc0c71e5b88c181687f8642ca xorg-server-1.1.1.ebuild 15697 RMD160 d9f04723d983a55ff7a0ce90c67f1af7fd83bc8e xorg-server-1.1.1.ebuild 15697 SHA256 bf4fa6b3db19aba2936fb3393ecd21940ee97d2e1fd3c1ae6cdb939507cfcbb8 xorg-server-1.1.1.ebuild 15697 -MISC ChangeLog 33060 RMD160 7ac021bb51fa4fd005f10cc18f7c306ce91855d3 SHA1 1501cd6d6a28a0a83049f1ffe5bb215309b4a504 SHA256 0a06006a9531cf3e92a142e914ce0859ac60f727c642f15ede2e46b5e965f1a3 -MD5 58801bfca0e7d39994745f1460ed7185 ChangeLog 33060 -RMD160 7ac021bb51fa4fd005f10cc18f7c306ce91855d3 ChangeLog 33060 -SHA256 0a06006a9531cf3e92a142e914ce0859ac60f727c642f15ede2e46b5e965f1a3 ChangeLog 33060 +MISC ChangeLog 33930 RMD160 0223bffef474425936fbc5710f3e53482db8201c SHA1 0ea1ece541ee537420889842becf9e15c18dd3b8 SHA256 a25ccc0de7817fca2edb4a8de3f0bf468a4fda17e8df651385cf700bf53d6c2f +MD5 9b96664df258343622cc7122979da236 ChangeLog 33930 +RMD160 0223bffef474425936fbc5710f3e53482db8201c ChangeLog 33930 +SHA256 a25ccc0de7817fca2edb4a8de3f0bf468a4fda17e8df651385cf700bf53d6c2f ChangeLog 33930 MISC metadata.xml 156 RMD160 c1274bdccf57603d580de0075ba07a35b7509560 SHA1 6f78f604e3d079d39189b40aaaa1ddb06182ad91 SHA256 5101ab0d4cc8c7125eea733c44e86962769bd77acaf53b69223b9cadcdd29055 MD5 a37bab73e2f24b213932c30997d3d360 metadata.xml 156 RMD160 c1274bdccf57603d580de0075ba07a35b7509560 metadata.xml 156 @@ -105,3 +142,6 @@ SHA256 356da215b18f2bbfa4e1509d15d26e56ba0372f28390d3c1903375f6c2f7abae files/di MD5 5bbe7de7ebbf30c9991b3fd800b1f219 files/digest-xorg-server-1.1.1 500 RMD160 0a5b1d758ab4077ac728b7ec6cc7f06fb49ce273 files/digest-xorg-server-1.1.1 500 SHA256 1bea059c9ffe1dee3634293efe79b0a429d52ca18eda558e2e7b9e0605b0504a files/digest-xorg-server-1.1.1 500 +MD5 eb8e67f136490bed406e3165659ef5af files/digest-xorg-server-1.1.1-r1 506 +RMD160 9f95844e26f01da5416239f15198b9a7beca3331 files/digest-xorg-server-1.1.1-r1 506 +SHA256 5a6f6ddae8ea1a903c9573aa852b59a8a011afabd9dc5b8f44b677c7db8f990d files/digest-xorg-server-1.1.1-r1 506 diff --git a/x11-base/xorg-server/files/01-no-move-damage.patch b/x11-base/xorg-server/files/01-no-move-damage.patch new file mode 100644 index 000000000000..4278043ba262 --- /dev/null +++ b/x11-base/xorg-server/files/01-no-move-damage.patch @@ -0,0 +1,33 @@ +Disable damage notifications on move for manually redirected windows. +The automatic compositor needs damage notification on move, but a +compositing manager doesn't. + +--- ./composite/compwindow.c.spiffiffity 2006-03-29 12:51:53.000000000 -0500 ++++ ./composite/compwindow.c 2006-04-13 23:18:42.000000000 -0400 +@@ -571,12 +571,15 @@ + } + else + { ++ CompWindowPtr cw = GetCompWindow (pWin); ++ + ptOldOrg.x -= dx; + ptOldOrg.y -= dy; + REGION_TRANSLATE (prgnSrc, prgnSrc, + pWin->drawable.x - ptOldOrg.x, + pWin->drawable.y - ptOldOrg.y); +- DamageDamageRegion (&pWin->drawable, prgnSrc); ++ if (pWin->redirectDraw && cw->update == CompositeRedirectAutomatic) ++ DamageDamageRegion (&pWin->drawable, prgnSrc); + } + cs->CopyWindow = pScreen->CopyWindow; + pScreen->CopyWindow = compCopyWindow; +@@ -655,7 +658,8 @@ + /* + * Report that as damaged so it will be redrawn + */ +- DamageDamageRegion (&pWin->drawable, &damage); ++ if (cw->update == CompositeRedirectAutomatic) ++ DamageDamageRegion (&pWin->drawable, &damage); + REGION_UNINIT (pScreen, &damage); + /* + * Save the new border clip region diff --git a/x11-base/xorg-server/files/02-dont-backfill-bg-none.patch b/x11-base/xorg-server/files/02-dont-backfill-bg-none.patch new file mode 100644 index 000000000000..9a5cacdea09a --- /dev/null +++ b/x11-base/xorg-server/files/02-dont-backfill-bg-none.patch @@ -0,0 +1,21 @@ +Disable backfilling of windows created with bg=none, which otherwise +would force a framebuffer readback. + +--- ./composite/compalloc.c.spiffiffity 2006-03-13 16:59:55.000000000 -0500 ++++ ./composite/compalloc.c 2006-04-12 16:37:50.000000000 -0400 +@@ -478,6 +478,7 @@ + * Copy bits from the parent into the new pixmap so that it will + * have "reasonable" contents in case for background None areas. + */ ++#if 0 + if (pGC) + { + XID val = IncludeInferiors; +@@ -492,6 +493,7 @@ + w, h, 0, 0); + FreeScratchGC (pGC); + } ++#endif + return pPixmap; + } + diff --git a/x11-base/xorg-server/files/03-tfp-damage.patch b/x11-base/xorg-server/files/03-tfp-damage.patch new file mode 100644 index 000000000000..942d44e3dc1e --- /dev/null +++ b/x11-base/xorg-server/files/03-tfp-damage.patch @@ -0,0 +1,211 @@ +--- ./GL/glx/glxdrawable.h.tfp-damage 2006-03-11 19:11:33.000000000 -0500 ++++ ./GL/glx/glxdrawable.h 2006-06-20 20:33:53.000000000 -0400 +@@ -41,6 +41,8 @@ + ** + */ + ++#include <damage.h> ++ + typedef struct { + + DrawablePtr pDraw; +@@ -49,7 +51,7 @@ + ScreenPtr pScreen; + Bool idExists; + int refcnt; +- ++ DamagePtr pDamage; + } __GLXpixmap; + + struct __GLXdrawable { +--- ./GL/glx/glxcmds.c.tfp-damage 2006-05-09 13:44:26.000000000 -0400 ++++ ./GL/glx/glxcmds.c 2006-06-20 20:33:53.000000000 -0400 +@@ -1271,6 +1271,7 @@ + pGlxPixmap->pGlxScreen = pGlxScreen; + pGlxPixmap->pScreen = pScreen; + pGlxPixmap->idExists = True; ++ pGlxPixmap->pDamage = NULL; + pGlxPixmap->refcnt = 0; + + pGlxPixmap->modes = modes; +--- ./GL/glx/glxdri.c.tfp-damage 2006-04-02 21:25:21.000000000 -0400 ++++ ./GL/glx/glxdri.c 2006-06-21 00:39:40.000000000 -0400 +@@ -296,24 +296,18 @@ + } + + static void +-glxFillAlphaChannel (PixmapPtr pixmap) ++glxFillAlphaChannel (PixmapPtr pixmap, int x, int y, int width, int height) + { +- int i, j; +- CARD32 *pixels = (CARD32 *)pixmap->devPrivate.ptr; ++ int i; ++ CARD32 *p, *end, *pixels = (CARD32 *)pixmap->devPrivate.ptr; + CARD32 rowstride = pixmap->devKind / 4; +- CARD32 x, y; +- +- x = pixmap->drawable.x; +- y = pixmap->drawable.y; + +- for (i = y; i < pixmap->drawable.height + y; ++i) ++ for (i = y; i < y + height; i++) + { +- for (j = x; j < pixmap->drawable.width + x; ++j) +- { +- int index = i * rowstride + j; +- +- pixels[index] |= 0xFF000000; +- } ++ p = &pixels[i * rowstride + x]; ++ end = p + width; ++ while (p < end) ++ *p++ |= 0xFF000000; + } + } + +@@ -326,7 +320,6 @@ + * - No fbconfig handling for TEXTURE_TARGET + * - No fbconfig exposure of Y inversion state + * - No GenerateMipmapEXT support (due to no FBO support) +- * - No damage tracking between binds + * - No support for anything but 16bpp and 32bpp-sparse pixmaps + */ + +@@ -335,38 +328,97 @@ + int buffer, + __GLXpixmap *glxPixmap) + { ++ RegionPtr pRegion; + PixmapPtr pixmap; + int bpp; +- Bool npot; ++ GLenum target, format, type; + + pixmap = (PixmapPtr) glxPixmap->pDraw; +- bpp = pixmap->drawable.depth >= 24 ? 4 : 2; /* XXX 24bpp packed, 8, etc */ +- ++ if (!glxPixmap->pDamage) { ++ glxPixmap->pDamage = DamageCreate(NULL, NULL, DamageReportNone, ++ TRUE, glxPixmap->pScreen, NULL); ++ if (!glxPixmap->pDamage) ++ return BadAlloc; ++ ++ DamageRegister ((DrawablePtr) pixmap, glxPixmap->pDamage); ++ pRegion = NULL; ++ } else { ++ pRegion = DamageRegion(glxPixmap->pDamage); ++ if (REGION_NIL(pRegion)) ++ return Success; ++ } ++ ++ /* XXX 24bpp packed, 8, etc */ ++ if (pixmap->drawable.depth >= 24) { ++ bpp = 4; ++ format = GL_BGRA; ++ type = GL_UNSIGNED_BYTE; ++ } else { ++ bpp = 2; ++ format = GL_RGB; ++ type = GL_UNSIGNED_SHORT_5_6_5; ++ } ++ ++ target = GL_TEXTURE_RECTANGLE_ARB; ++ + CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_ROW_LENGTH, +- pixmap->devKind / bpp) ); +- CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_SKIP_ROWS, +- pixmap->drawable.y) ); +- CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_SKIP_PIXELS, +- pixmap->drawable.x) ); +- +- if (pixmap->drawable.depth == 24) +- glxFillAlphaChannel(pixmap); +- +- npot = !(glxCountBits(pixmap->drawable.width) == 1 && +- glxCountBits(pixmap->drawable.height) == 1) /* || +- strstr(CALL_GetString(GL_EXTENSIONS, +- "GL_ARB_texture_non_power_of_two")) */ ; +- +- CALL_TexImage2D( GET_DISPATCH(), +- ( npot ? GL_TEXTURE_RECTANGLE_ARB : GL_TEXTURE_2D, +- 0, +- bpp == 4 ? 4 : 3, +- pixmap->drawable.width, +- pixmap->drawable.height, +- 0, +- bpp == 4 ? GL_BGRA : GL_RGB, +- bpp == 4 ? GL_UNSIGNED_BYTE : GL_UNSIGNED_SHORT_5_6_5, +- pixmap->devPrivate.ptr ) ); ++ pixmap->devKind / bpp) ); ++ if (pRegion == NULL) ++ { ++ if (pixmap->drawable.depth == 24) ++ glxFillAlphaChannel(pixmap, ++ pixmap->drawable.x, ++ pixmap->drawable.y, ++ pixmap->drawable.width, ++ pixmap->drawable.height); ++ ++ CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_SKIP_PIXELS, ++ pixmap->drawable.x) ); ++ CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_SKIP_ROWS, ++ pixmap->drawable.y) ); ++ ++ CALL_TexImage2D( GET_DISPATCH(), ++ (target, ++ 0, ++ bpp == 4 ? 4 : 3, ++ pixmap->drawable.width, ++ pixmap->drawable.height, ++ 0, ++ format, ++ type, ++ pixmap->devPrivate.ptr) ); ++ } else { ++ int i, numRects; ++ BoxPtr p; ++ ++ numRects = REGION_NUM_RECTS (pRegion); ++ p = REGION_RECTS (pRegion); ++ for (i = 0; i < numRects; i++) ++ { ++ if (pixmap->drawable.depth == 24) ++ glxFillAlphaChannel(pixmap, ++ pixmap->drawable.x + p[i].x1, ++ pixmap->drawable.y + p[i].y1, ++ p[i].x2 - p[i].x1, ++ p[i].y2 - p[i].y1); ++ ++ CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_SKIP_PIXELS, ++ pixmap->drawable.x + p[i].x1) ); ++ CALL_PixelStorei( GET_DISPATCH(), (GL_UNPACK_SKIP_ROWS, ++ pixmap->drawable.y + p[i].y1) ); ++ ++ CALL_TexSubImage2D( GET_DISPATCH(), ++ (target, ++ 0, ++ p[i].x1, p[i].y1, ++ p[i].x2 - p[i].x1, p[i].y2 - p[i].y1, ++ format, ++ type, ++ pixmap->devPrivate.ptr) ); ++ } ++ } ++ ++ DamageEmpty(glxPixmap->pDamage); + + return Success; + } +--- ./GL/glx/glxext.c.tfp-damage 2006-03-16 20:47:25.000000000 -0500 ++++ ./GL/glx/glxext.c 2006-06-20 20:33:53.000000000 -0400 +@@ -141,6 +141,10 @@ + + pGlxPixmap->idExists = False; + if (!pGlxPixmap->refcnt) { ++ if (pGlxPixmap->pDamage) { ++ DamageUnregister (pGlxPixmap->pDraw, pGlxPixmap->pDamage); ++ DamageDestroy(pGlxPixmap->pDamage); ++ } + /* + ** The DestroyPixmap routine should decrement the refcount and free + ** only if it's zero. diff --git a/x11-base/xorg-server/files/04-mesa-copy-sub-buffer.patch b/x11-base/xorg-server/files/04-mesa-copy-sub-buffer.patch new file mode 100644 index 000000000000..2b62daddb451 --- /dev/null +++ b/x11-base/xorg-server/files/04-mesa-copy-sub-buffer.patch @@ -0,0 +1,361 @@ +--- ./GL/glx/glxdrawable.h.mesa-copy-sub-buffer 2006-07-06 21:40:41.000000000 -0400 ++++ ./GL/glx/glxdrawable.h 2006-07-06 21:56:33.000000000 -0400 +@@ -58,6 +58,8 @@ + void (*destroy)(__GLXdrawable *private); + GLboolean (*resize)(__GLXdrawable *private); + GLboolean (*swapBuffers)(__GLXdrawable *); ++ void (*copySubBuffer)(__GLXdrawable *drawable, ++ int x, int y, int w, int h); + + /* + ** list of drawable private structs +--- ./GL/glx/glxcmds.c.mesa-copy-sub-buffer 2006-07-06 21:40:41.000000000 -0400 ++++ ./GL/glx/glxcmds.c 2006-07-06 22:30:01.000000000 -0400 +@@ -1331,21 +1331,14 @@ + + /*****************************************************************************/ + +-/* +-** NOTE: There is no portable implementation for swap buffers as of +-** this time that is of value. Consequently, this code must be +-** implemented by somebody other than SGI. +-*/ +-int __glXSwapBuffers(__GLXclientState *cl, GLbyte *pc) ++static __GLXdrawable * ++SyncContextGetDrawable (__GLXclientState *cl, GLXContextTag tag, ++ XID drawId, int *status) + { + ClientPtr client = cl->client; + DrawablePtr pDraw; +- xGLXSwapBuffersReq *req = (xGLXSwapBuffersReq *) pc; +- GLXContextTag tag = req->contextTag; +- XID drawId = req->drawable; + __GLXpixmap *pGlxPixmap; + __GLXcontext *glxc = NULL; +- int error; + + /* + ** Check that the GLX drawable is valid. +@@ -1361,11 +1354,11 @@ + ** Drawable is an X pixmap, which is not allowed. + */ + client->errorValue = drawId; +- return __glXBadDrawable; ++ *status = __glXBadDrawable; ++ return NULL; + } + } else { +- pGlxPixmap = (__GLXpixmap *) LookupIDByType(drawId, +- __glXPixmapRes); ++ pGlxPixmap = (__GLXpixmap *) LookupIDByType(drawId, __glXPixmapRes); + if (pGlxPixmap) { + /* + ** Drawable is a GLX pixmap. +@@ -1375,21 +1368,23 @@ + ** Drawable is neither a X window nor a GLX pixmap. + */ + client->errorValue = drawId; +- return __glXBadDrawable; ++ *status = __glXBadDrawable; ++ return NULL; + } + } + + if (tag) { + glxc = __glXLookupContextByTag(cl, tag); + if (!glxc) { +- return __glXBadContextTag; ++ *status = __glXBadContextTag; ++ return NULL; + } + /* + ** The calling thread is swapping its current drawable. In this case, + ** glxSwapBuffers is in both GL and X streams, in terms of + ** sequentiality. + */ +- if (__glXForceCurrent(cl, tag, &error)) { ++ if (__glXForceCurrent(cl, tag, status)) { + /* + ** Do whatever is needed to make sure that all preceding requests + ** in both streams are completed before the swap is executed. +@@ -1397,33 +1392,53 @@ + CALL_Finish( GET_DISPATCH(), () ); + __GLX_NOTE_FLUSHED_CMDS(glxc); + } else { +- return error; ++ return NULL; + } + } + ++ *status = Success; + if (pDraw) { +- __GLXdrawable *glxPriv; ++ __GLXdrawable *glxPriv; + + if (glxc) { + glxPriv = __glXGetDrawable(glxc, pDraw, drawId); + if (glxPriv == NULL) { +- return __glXBadDrawable; ++ *status = __glXBadDrawable; ++ return NULL; + } + } + else { + glxPriv = __glXFindDrawable(drawId); + if (glxPriv == NULL) { + /* This is a window we've never seen before, do nothing */ +- return Success; ++ return NULL; + } + } + +- if ((*glxPriv->swapBuffers)(glxPriv) == GL_FALSE) { +- return __glXBadDrawable; +- } ++ return glxPriv; + } + +- return Success; ++ return NULL; ++} ++ ++/* ++** NOTE: There is no portable implementation for swap buffers as of ++** this time that is of value. Consequently, this code must be ++** implemented by somebody other than SGI. ++*/ ++int __glXSwapBuffers(__GLXclientState *cl, GLbyte *pc) ++{ ++ xGLXSwapBuffersReq *req = (xGLXSwapBuffersReq *) pc; ++ GLXContextTag tag = req->contextTag; ++ __GLXdrawable *glxPriv; ++ int status; ++ ++ glxPriv = SyncContextGetDrawable (cl, tag, req->drawable, &status); ++ if (glxPriv && (*glxPriv->swapBuffers)(glxPriv) == GL_FALSE) { ++ return __glXBadDrawable; ++ } ++ ++ return status; + } + + +@@ -1544,6 +1559,30 @@ + pGlxPixmap); + } + ++int __glXCopySubBufferMESA(__GLXclientState *cl, GLbyte *pc) ++{ ++ xGLXVendorPrivateReq *req = (xGLXVendorPrivateReq *) pc; ++ GLXContextTag tag = req->contextTag; ++ __GLXdrawable *glxPriv; ++ GLXDrawable drawId; ++ int x, y, width, height; ++ int status; ++ ++ pc += __GLX_VENDPRIV_HDR_SIZE; ++ ++ drawId = *((CARD32 *) (pc)); ++ x = *((INT32 *) (pc + 4)); ++ y = *((INT32 *) (pc + 8)); ++ width = *((INT32 *) (pc + 12)); ++ height = *((INT32 *) (pc + 16)); ++ ++ glxPriv = SyncContextGetDrawable (cl, tag, drawId, &status); ++ if (glxPriv) ++ (*glxPriv->copySubBuffer)(glxPriv, x, y, width, height); ++ ++ return status; ++} ++ + /* + ** Get drawable attributes + */ +@@ -2173,7 +2212,9 @@ + case X_GLXvop_BindTexImageEXT: + return __glXBindTexImageEXT(cl, pc); + case X_GLXvop_ReleaseTexImageEXT: +- return __glXReleaseTexImageEXT(cl, pc); ++ return __glXReleaseTexImageEXT(cl, pc); ++ case X_GLXvop_CopySubBufferMESA: ++ return __glXCopySubBufferMESA(cl, pc); + } + #endif + +--- ./GL/glx/glxdri.c.mesa-copy-sub-buffer 2006-07-06 21:40:41.000000000 -0400 ++++ ./GL/glx/glxdri.c 2006-07-06 21:59:38.000000000 -0400 +@@ -112,12 +112,28 @@ + * months ago. :( + * 20050727 - Gut all the old interfaces. This breaks compatability with + * any DRI driver built to any previous version. ++ * 20060314 - Added support for GLX_MESA_copy_sub_buffer. + */ ++ + #define INTERNAL_VERSION 20050727 + + static const char CREATE_NEW_SCREEN_FUNC[] = + "__driCreateNewScreen_" STRINGIFY (INTERNAL_VERSION); + ++/* The DRI driver entry point version wasn't bumped when the ++ * copySubBuffer functionality was added to the DRI drivers, but the ++ * functionality is still conditional on the value of the ++ * internal_api_version passed to __driCreateNewScreen. However, the ++ * screen constructor doesn't fail for a DRI driver that's older than ++ * the passed in version number, so there's no way we can know for ++ * sure that we can actually use the copySubBuffer functionality. But ++ * since the earliest (and at this point only) released mesa version ++ * (6.5) that uses the 20050727 entry point does have copySubBuffer, ++ * we'll just settle for that. We still have to pass in a higher to ++ * the screen constructor to enable the functionality. ++ */ ++#define COPY_SUB_BUFFER_INTERNAL_VERSION 20060314 ++ + static void + __glXDRIleaveServer(void) + { +@@ -177,6 +193,27 @@ + return TRUE; + } + ++static void ++__glXDRIdrawableCopySubBuffer(__GLXdrawable *basePrivate, ++ int x, int y, int w, int h) ++{ ++ __GLXDRIdrawable *private = (__GLXDRIdrawable *) basePrivate; ++ __GLXDRIscreen *screen; ++ ++ /* FIXME: We're jumping through hoops here to get the DRIdrawable ++ * which the dri driver tries to keep to it self... cf. FIXME in ++ * createDrawable. */ ++ ++ screen = (__GLXDRIscreen *) __glXgetActiveScreen(private->base.pDraw->pScreen->myNum); ++ private->driDrawable = (screen->driScreen.getDrawable)(NULL, ++ private->base.drawId, ++ screen->driScreen.private); ++ ++ (*private->driDrawable->copySubBuffer)(NULL, ++ private->driDrawable->private, ++ x, y, w, h); ++} ++ + static __GLXdrawable * + __glXDRIcontextCreateDrawable(__GLXcontext *context, + DrawablePtr pDraw, +@@ -195,10 +232,11 @@ + return NULL; + } + +- private->base.destroy = __glXDRIdrawableDestroy; +- private->base.resize = __glXDRIdrawableResize; +- private->base.swapBuffers = __glXDRIdrawableSwapBuffers; +- ++ private->base.destroy = __glXDRIdrawableDestroy; ++ private->base.resize = __glXDRIdrawableResize; ++ private->base.swapBuffers = __glXDRIdrawableSwapBuffers; ++ private->base.copySubBuffer = __glXDRIdrawableCopySubBuffer; ++ + #if 0 + /* FIXME: It would only be natural that we called + * driScreen->createNewDrawable here but the DRI drivers manage +@@ -218,7 +256,6 @@ + return &private->base; + } + +- + static void + __glXDRIcontextDestroy(__GLXcontext *baseContext) + { +@@ -770,7 +807,7 @@ + __DRIframebuffer framebuffer; + int fd = -1; + int status; +- int api_ver = INTERNAL_VERSION; ++ int api_ver = COPY_SUB_BUFFER_INTERNAL_VERSION; + drm_magic_t magic; + drmVersionPtr version; + char *driverName; +--- ./GL/glx/g_disptab.h.mesa-copy-sub-buffer 2006-03-11 19:11:33.000000000 -0500 ++++ ./GL/glx/g_disptab.h 2006-07-06 21:56:33.000000000 -0400 +@@ -48,6 +48,7 @@ + extern int __glXSwapBuffers(__GLXclientState*, GLbyte*); + extern int __glXBindTexImageEXT(__GLXclientState *cl, GLbyte *pc); + extern int __glXReleaseTexImageEXT(__GLXclientState *cl, GLbyte *pc); ++extern int __glXCopySubBufferMESA(__GLXclientState *cl, GLbyte *pc); + extern int __glXGetDrawableAttributesSGIX(__GLXclientState *cl, GLbyte *pc); + extern int __glXUseXFont(__GLXclientState*, GLbyte*); + extern int __glXCreateGLXPixmap(__GLXclientState*, GLbyte*); +@@ -76,6 +77,7 @@ + extern int __glXSwapSwapBuffers(__GLXclientState*, GLbyte*); + extern int __glXSwapBindTexImageEXT(__GLXclientState *cl, GLbyte *pc); + extern int __glXSwapReleaseTexImageEXT(__GLXclientState *cl, GLbyte *pc); ++extern int __glXSwapReleaseTexImageEXT(__GLXclientState *cl, GLbyte *pc); + extern int __glXSwapGetDrawableAttributesSGIX(__GLXclientState *cl, GLbyte *pc); + extern int __glXSwapUseXFont(__GLXclientState*, GLbyte*); + extern int __glXSwapCreateGLXPixmap(__GLXclientState*, GLbyte*); +@@ -105,4 +107,11 @@ + extern __GLXdispatchSingleProcPtr __glXSingleTable[__GLX_SINGLE_TABLE_SIZE]; + extern __GLXdispatchRenderProcPtr __glXSwapRenderTable[__GLX_RENDER_TABLE_SIZE]; + extern __GLXdispatchSingleProcPtr __glXSwapSingleTable[__GLX_SINGLE_TABLE_SIZE]; ++ ++/* Copied from mesa src/glx/x11/glxcmds.c ++ * ++ * Apparently there's no standardized opcode for this extension. ++ */ ++#define X_GLXvop_CopySubBufferMESA 5154 /* temporary */ ++ + #endif /* _GLX_g_disptab_h_ */ +--- ./GL/glx/glxscreens.c.mesa-copy-sub-buffer 2006-03-20 15:10:29.000000000 -0500 ++++ ./GL/glx/glxscreens.c 2006-07-06 21:56:33.000000000 -0400 +@@ -139,6 +139,7 @@ + "GLX_SGIX_swap_barrier " + #endif + "GLX_SGIX_fbconfig " ++ "GLX_MESA_copy_sub_buffer " + ; + + __GLXscreen **__glXActiveScreens; +--- ./GL/glx/glxcmdsswap.c.mesa-copy-sub-buffer 2006-04-02 22:09:15.000000000 -0400 ++++ ./GL/glx/glxcmdsswap.c 2006-07-06 21:56:33.000000000 -0400 +@@ -432,6 +432,31 @@ + return __glXReleaseTexImageEXT(cl, (GLbyte *)pc); + } + ++int __glXSwapCopySubBufferMESA(__GLXclientState *cl, GLbyte *pc) ++{ ++ xGLXVendorPrivateReq *req = (xGLXVendorPrivateReq *) pc; ++ GLXDrawable *drawId; ++ int *buffer; ++ ++ (void) drawId; ++ (void) buffer; ++ ++ __GLX_DECLARE_SWAP_VARIABLES; ++ ++ pc += __GLX_VENDPRIV_HDR_SIZE; ++ ++ __GLX_SWAP_SHORT(&req->length); ++ __GLX_SWAP_INT(&req->contextTag); ++ __GLX_SWAP_INT(pc); ++ __GLX_SWAP_INT(pc + 4); ++ __GLX_SWAP_INT(pc + 8); ++ __GLX_SWAP_INT(pc + 12); ++ __GLX_SWAP_INT(pc + 16); ++ ++ return __glXCopySubBufferMESA(cl, pc); ++ ++} ++ + int __glXSwapGetDrawableAttributesSGIX(__GLXclientState *cl, GLbyte *pc) + { + xGLXVendorPrivateWithReplyReq *req = (xGLXVendorPrivateWithReplyReq *)pc; +@@ -899,7 +924,9 @@ + case X_GLXvop_BindTexImageEXT: + return __glXSwapBindTexImageEXT(cl, pc); + case X_GLXvop_ReleaseTexImageEXT: +- return __glXSwapReleaseTexImageEXT(cl, pc); ++ return __glXSwapReleaseTexImageEXT(cl, pc); ++ case X_GLXvop_CopySubBufferMESA: ++ return __glXSwapCopySubBufferMESA(cl, pc); + } + #endif + diff --git a/x11-base/xorg-server/files/05-offscreen-pixmaps.patch b/x11-base/xorg-server/files/05-offscreen-pixmaps.patch new file mode 100644 index 000000000000..3841b043bab4 --- /dev/null +++ b/x11-base/xorg-server/files/05-offscreen-pixmaps.patch @@ -0,0 +1,55 @@ +--- ./hw/xfree86/xaa/xaaInit.c.offscreen-pixmaps 2006-07-05 14:31:42.000000000 -0400 ++++ ./hw/xfree86/xaa/xaaInit.c 2006-08-30 16:47:29.000000000 -0400 +@@ -98,6 +98,30 @@ + xfree(infoRec); + } + ++void ++XAAEvictPixmaps(void) ++{ ++ XAAScreenPtr pScreenPriv; ++ XAAInfoRecPtr infoRec; ++ ScreenPtr pScreen; ++ int i; ++ ++ xf86MsgVerb(X_INFO, 3, "XAA: Evicting pixmaps\n"); ++ ++ for (i = 0; i < screenInfo.numScreens; i++) { ++ pScreen = screenInfo.screens[i]; ++ infoRec = GET_XAAINFORECPTR_FROM_SCREEN(pScreen); ++ ++ pScreenPriv = pScreen->devPrivates[XAAScreenIndex].ptr; ++ infoRec = pScreenPriv->AccelInfoRec; ++ ++ infoRec->offscreenDepths = 0; ++ infoRec->Flags &= ~OFFSCREEN_PIXMAPS; ++ ++ XAAMoveOutOffscreenPixmaps(pScreen); ++ XAAInvalidatePixmapCache(pScreen); ++ } ++} + + Bool + XAAInit(ScreenPtr pScreen, XAAInfoRecPtr infoRec) +--- ./GL/glx/glxdri.c.offscreen-pixmaps 2006-08-30 16:46:45.000000000 -0400 ++++ ./GL/glx/glxdri.c 2006-08-30 16:45:52.000000000 -0400 +@@ -367,6 +367,19 @@ + int bpp; + GLenum target, format, type; + ++ /* When the GLX_EXT_texture_from_pixmap is used, as it's ++ * implemented here, we want to pull pixmap out of video memory ++ * and into host memory. */ ++ { ++ extern void XAAEvictPixmaps(void); ++ static int evictedPixmaps; ++ ++ if (!evictedPixmaps) { ++ XAAEvictPixmaps(); ++ evictedPixmaps = TRUE; ++ } ++ } ++ + pixmap = (PixmapPtr) glxPixmap->pDraw; + if (!glxPixmap->pDamage) { + glxPixmap->pDamage = DamageCreate(NULL, NULL, DamageReportNone, diff --git a/x11-base/xorg-server/files/06-aiglx-happy-vt-switch.patch b/x11-base/xorg-server/files/06-aiglx-happy-vt-switch.patch new file mode 100644 index 000000000000..314f1f087b23 --- /dev/null +++ b/x11-base/xorg-server/files/06-aiglx-happy-vt-switch.patch @@ -0,0 +1,241 @@ +diff --git a/GL/glx/glxdri.c b/GL/glx/glxdri.c +index cfa9996..77fa4bf 100644 +--- a/GL/glx/glxdri.c ++++ b/GL/glx/glxdri.c +@@ -63,27 +63,30 @@ #include "dispatch.h" + #define STRINGIFY(macro_or_string) STRINGIFY_ARG (macro_or_string) + #define STRINGIFY_ARG(contents) #contents + +-typedef struct __GLXDRIscreen __GLXDRIscreen; +-typedef struct __GLXDRIcontext __GLXDRIcontext; ++typedef struct __GLXDRIscreen __GLXDRIscreen; ++typedef struct __GLXDRIcontext __GLXDRIcontext; + typedef struct __GLXDRIdrawable __GLXDRIdrawable; + + struct __GLXDRIscreen { +- __GLXscreen base; ++ __GLXscreen base; + +- __DRIscreen driScreen; +- void *driver; ++ xf86EnterVTProc *enterVT; ++ xf86LeaveVTProc *leaveVT; ++ ++ __DRIscreen driScreen; ++ void *driver; + }; + + struct __GLXDRIcontext { +- __GLXcontext base; ++ __GLXcontext base; + +- __DRIcontext driContext; ++ __DRIcontext driContext; + }; + + struct __GLXDRIdrawable { +- __GLXdrawable base; ++ __GLXdrawable base; + +- __DRIdrawable *driDrawable; ++ __DRIdrawable *driDrawable; + }; + + /* History: +@@ -594,8 +597,7 @@ static __DRIfuncPtr getProcAddress(const + + static __DRIscreen *findScreen(__DRInativeDisplay *dpy, int scrn) + { +- __GLXDRIscreen *screen = +- (__GLXDRIscreen *) __glXgetActiveScreen(scrn); ++ __GLXDRIscreen *screen = (__GLXDRIscreen *) __glXgetActiveScreen(scrn); + + return &screen->driScreen; + } +@@ -789,6 +791,30 @@ static const __DRIinterfaceMethods inter + + static const char dri_driver_path[] = DRI_DRIVER_PATH; + ++static Bool ++glxDRIEnterVT (int index, int flags) ++{ ++ __GLXDRIscreen *screen = (__GLXDRIscreen *) __glXgetActiveScreen(index); ++ ++ LogMessage(X_INFO, "AIGLX: Resuming AIGLX clients after VT switch\n"); ++ ++ glxResumeClients(); ++ ++ return (*screen->enterVT) (index, flags); ++} ++ ++static void ++glxDRILeaveVT (int index, int flags) ++{ ++ __GLXDRIscreen *screen = (__GLXDRIscreen *) __glXgetActiveScreen(index); ++ ++ LogMessage(X_INFO, "AIGLX: Suspending AIGLX clients for VT switch\n"); ++ ++ glxSuspendClients(); ++ ++ return (*screen->leaveVT) (index, flags); ++} ++ + static __GLXscreen * + __glXDRIscreenProbe(ScreenPtr pScreen) + { +@@ -813,6 +839,7 @@ __glXDRIscreenProbe(ScreenPtr pScreen) + void *dev_priv = NULL; + char filename[128]; + Bool isCapable; ++ ScrnInfoPtr pScrn = xf86Screens[pScreen->myNum]; + + if (!xf86LoaderCheckSymbol("DRIQueryDirectRenderingCapable")) { + LogMessage(X_ERROR, "AIGLX: DRI module not loaded\n"); +@@ -983,6 +1010,11 @@ __glXDRIscreenProbe(ScreenPtr pScreen) + + __glXsetEnterLeaveServerFuncs(__glXDRIenterServer, __glXDRIleaveServer); + ++ screen->enterVT = pScrn->EnterVT; ++ pScrn->EnterVT = glxDRIEnterVT; ++ screen->leaveVT = pScrn->LeaveVT; ++ pScrn->LeaveVT = glxDRILeaveVT; ++ + LogMessage(X_INFO, + "AIGLX: Loaded and initialized %s\n", filename); + +diff --git a/GL/glx/glxext.c b/GL/glx/glxext.c +index 8bbb83f..edc257c 100644 +--- a/GL/glx/glxext.c ++++ b/GL/glx/glxext.c +@@ -234,13 +231,11 @@ GLboolean __glXFreeContext(__GLXcontext + * __glXDispatch() or as a callback from the resource manager. In + * the latter case we need to lift the DRI lock manually. */ + +- if (!inDispatch) +- __glXleaveServer(); ++ __glXleaveServer(); + + cx->destroy(cx); + +- if (!inDispatch) +- __glXenterServer(); ++ __glXenterServer(); + + return GL_TRUE; + } +@@ -336,7 +331,7 @@ void GlxExtensionInit(void) + /* + ** Initialize table of client state. There is never a client 0. + */ +- for (i=1; i <= MAXCLIENTS; i++) { ++ for (i = 1; i <= MAXCLIENTS; i++) { + __glXClients[i] = 0; + } + +@@ -407,11 +402,36 @@ __GLXcontext *__glXForceCurrent(__GLXcli + + /************************************************************************/ + +-/* +-** Top level dispatcher; all commands are executed from here down. +-*/ ++static int glxServerLeaveCount; ++static int glxBlockClients; + +-/* I cried when I wrote this. Damn you XAA! */ ++void glxSuspendClients(void) ++{ ++ int i; ++ ++ for (i = 1; i <= MAXCLIENTS; i++) { ++ if (__glXClients[i] == NULL || !__glXClients[i]->inUse) ++ continue; ++ ++ IgnoreClient(__glXClients[i]->client); ++ } ++ ++ glxBlockClients = TRUE; ++} ++ ++void glxResumeClients(void) ++{ ++ int i; ++ ++ glxBlockClients = FALSE; ++ ++ for (i = 1; i <= MAXCLIENTS; i++) { ++ if (__glXClients[i] == NULL || !__glXClients[i]->inUse) ++ continue; ++ ++ AttendClient(__glXClients[i]->client); ++ } ++} + + static void + __glXnopEnterServer(void) +@@ -436,14 +456,19 @@ void __glXsetEnterLeaveServerFuncs(void + + void __glXenterServer(void) + { +- (*__glXenterServerFunc)(); ++ glxServerLeaveCount--; ++ ++ if (glxServerLeaveCount == 0) ++ (*__glXenterServerFunc)(); + } + + void __glXleaveServer(void) + { +- (*__glXleaveServerFunc)(); +-} ++ if (glxServerLeaveCount == 0) ++ (*__glXleaveServerFunc)(); + ++ glxServerLeaveCount++; ++} + + /* + ** Top level dispatcher; all commands are executed from here down. +@@ -496,6 +521,15 @@ static int __glXDispatch(ClientPtr clien + return __glXError(GLXBadLargeRequest); + } + ++ /* If we're currently blocking GLX clients, just put this guy to ++ * sleep, reset the request and return. */ ++ if (glxBlockClients) { ++ ResetCurrentRequest(client); ++ client->sequence--; ++ IgnoreClient(client); ++ return(client->noClientException); ++ } ++ + /* + ** Use the opcode to index into the procedure table. + */ +@@ -506,12 +540,8 @@ static int __glXDispatch(ClientPtr clien + + __glXleaveServer(); + +- inDispatch = True; +- + retval = proc(cl, (GLbyte *) stuff); + +- inDispatch = False; +- + __glXenterServer(); + + return retval; +diff --git a/GL/glx/glxserver.h b/GL/glx/glxserver.h +index 8ece1e2..9eed1bc 100644 +--- a/GL/glx/glxserver.h ++++ b/GL/glx/glxserver.h +@@ -136,6 +136,9 @@ void __glXsetEnterLeaveServerFuncs(void + void __glXenterServer(void); + void __glXleaveServer(void); + ++void glxSuspendClients(void); ++void glxResumeClients(void); ++ + /* + ** State kept per client. + */ diff --git a/x11-base/xorg-server/files/1.1.1-fix-xrandr-zoom-keys.patch b/x11-base/xorg-server/files/1.1.1-fix-xrandr-zoom-keys.patch new file mode 100644 index 000000000000..fc9bd8db0dc8 --- /dev/null +++ b/x11-base/xorg-server/files/1.1.1-fix-xrandr-zoom-keys.patch @@ -0,0 +1,186 @@ +diff --git a/dix/Makefile.am b/dix/Makefile.am +index c9a19f7..414f125 100644 +--- a/dix/Makefile.am ++++ b/dix/Makefile.am +@@ -29,7 +29,8 @@ libdix_la_SOURCES = \ + swaprep.c \ + swapreq.c \ + tables.c \ +- window.c ++ window.c \ ++ strcasecmp.c + + libxpstubs_la_SOURCES = \ + xpstubs.c +diff --git a/hw/xfree86/dixmods/Makefile.am b/hw/xfree86/dixmods/Makefile.am +index d1b806a..9023a0c 100644 +--- a/hw/xfree86/dixmods/Makefile.am ++++ b/hw/xfree86/dixmods/Makefile.am +@@ -95,6 +95,7 @@ libtype1_la_SOURCES = type1mod.c + libdixmods_la_SOURCES = $(top_srcdir)/mi/miinitext.c + + libxorgxkb_la_SOURCES = xkbVT.c xkbPrivate.c xkbKillSrv.c ++libxorgxkb_la_LIBADD = $(top_builddir)/dix/libdix.la + + libxtrap_la_LDFLAGS = -avoid-version + libxtrap_la_LIBADD = $(top_builddir)/XTrap/libxtrap.la +diff --git a/hw/xfree86/dixmods/xkbPrivate.c b/hw/xfree86/dixmods/xkbPrivate.c +index 0479bca..b986432 100644 +--- a/hw/xfree86/dixmods/xkbPrivate.c ++++ b/hw/xfree86/dixmods/xkbPrivate.c +@@ -26,13 +26,13 @@ XkbDDXPrivate(DeviceIntPtr dev,KeyCode k + if (xf86act->type == XkbSA_XFree86Private) { + memcpy(msgbuf, xf86act->data, XkbAnyActionDataSize); + msgbuf[XkbAnyActionDataSize]= '\0'; +- if (strcmp(msgbuf, "-vmode")==0) ++ if (strcasecmp(msgbuf, "-vmode")==0) + xf86ProcessActionEvent(ACTION_PREV_MODE, NULL); +- else if (strcmp(msgbuf, "+vmode")==0) ++ else if (strcasecmp(msgbuf, "+vmode")==0) + xf86ProcessActionEvent(ACTION_NEXT_MODE, NULL); +- else if (strcmp(msgbuf, "ungrab")==0) ++ else if (strcasecmp(msgbuf, "ungrab")==0) + xf86ProcessActionEvent(ACTION_DISABLEGRAB, NULL); +- else if (strcmp(msgbuf, "clsgrb")==0) ++ else if (strcasecmp(msgbuf, "clsgrb")==0) + xf86ProcessActionEvent(ACTION_CLOSECLIENT, NULL); + else + xf86ProcessActionEvent(ACTION_MESSAGE, (void *) msgbuf); +diff --git a/include/dix.h b/include/dix.h +index 0177721..84fc849 100644 +--- a/include/dix.h ++++ b/include/dix.h +@@ -820,4 +820,10 @@ typedef struct { + SelectionCallbackKind kind; + } SelectionInfoRec; + ++/* strcasecmp.c */ ++#if NEED_STRCASECMP ++#define strcasecmp xstrcasecmp ++extern int xstrcasecmp(char *s1, char *s2); ++#endif ++ + #endif /* DIX_H */ +diff --git a/xkb/maprules.c b/xkb/maprules.c +index d4e9829..eff02ad 100644 +--- a/xkb/maprules.c ++++ b/xkb/maprules.c +@@ -62,12 +62,6 @@ #define PR_DEBUG1(s,a) + #define PR_DEBUG2(s,a,b) + #endif + +-#ifdef NEED_STRCASECMP +-extern int _XkbStrCaseCmp(char *s1, char *s2); +-#else +-#define _XkbStrCaseCmp strcasecmp +-#endif +- + /***====================================================================***/ + + #define DFLT_LINE_SIZE 128 +@@ -1092,20 +1086,20 @@ int len,headingtype,extra_ndx = 0; + for ( ; GetInputLine(file,&line,False); line.num_line= 0) { + if (line.line[0]=='!') { + tok = strtok(&(line.line[1]), " \t"); +- if (_XkbStrCaseCmp(tolower(tok),"model") == 0) ++ if (strcasecmp(tok,"model") == 0) + headingtype = HEAD_MODEL; +- else if (_XkbStrCaseCmp(tok,"layout") == 0) ++ else if (strcasecmp(tok,"layout") == 0) + headingtype = HEAD_LAYOUT; +- else if (_XkbStrCaseCmp(tok,"variant") == 0) ++ else if (strcasecmp(tok,"variant") == 0) + headingtype = HEAD_VARIANT; +- else if (_XkbStrCaseCmp(tok,"option") == 0) ++ else if (strcasecmp(tok,"option") == 0) + headingtype = HEAD_OPTION; + else { + int i; + headingtype = HEAD_EXTRA; + extra_ndx= -1; + for (i=0;(i<rules->num_extra)&&(extra_ndx<0);i++) { +- if (!_XkbStrCaseCmp(tok,rules->extra_names[i])) ++ if (!strcasecmp(tok,rules->extra_names[i])) + extra_ndx= i; + } + if (extra_ndx<0) { +diff --git a/xkb/xkbfmisc.c b/xkb/xkbfmisc.c +index 3389ba8..3ed68c2 100644 +--- a/xkb/xkbfmisc.c ++++ b/xkb/xkbfmisc.c +@@ -247,19 +247,3 @@ XkbNameMatchesPattern(char *name,char *p + /* if we get here, the pattern is exhausted (-:just like me:-) */ + return (name[0]=='\0'); + } +- +-#ifdef NEED_STRCASECMP +-_X_HIDDEN int +-_XkbStrCaseCmp(char *str1,char *str2) +-{ +- const u_char *us1 = (const u_char *)str1, *us2 = (const u_char *)str2; +- +- while (tolower(*us1) == tolower(*us2)) { +- if (*us1++ == '\0') +- return (0); +- us2++; +- } +- +- return (tolower(*us1) - tolower(*us2)); +-} +-#endif +diff --git a/dix/strcasecmp.c b/dix/strcasecmp.c +new file mode 100644 +index 0000000..bf3f008 +--- /dev/null ++++ b/dix/strcasecmp.c +@@ -0,0 +1,50 @@ ++/* $Xorg: xkbmisc.c,v 1.4 2000/08/17 19:46:44 cpqbld Exp $ */ ++/************************************************************ ++ Copyright (c) 1995 by Silicon Graphics Computer Systems, Inc. ++ ++ Permission to use, copy, modify, and distribute this ++ software and its documentation for any purpose and without ++ fee is hereby granted, provided that the above copyright ++ notice appear in all copies and that both that copyright ++ notice and this permission notice appear in supporting ++ documentation, and that the name of Silicon Graphics not be ++ used in advertising or publicity pertaining to distribution ++ of the software without specific prior written permission. ++ Silicon Graphics makes no representation about the suitability ++ of this software for any purpose. It is provided "as is" ++ without any express or implied warranty. ++ ++ SILICON GRAPHICS DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS ++ SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY ++ AND FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT SHALL SILICON ++ GRAPHICS BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL ++ DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, ++ DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE ++ OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH ++ THE USE OR PERFORMANCE OF THIS SOFTWARE. ++ ++ ********************************************************/ ++/* $XFree86: xc/lib/xkbfile/xkbmisc.c,v 1.7 2003/07/16 02:31:10 dawes Exp $ */ ++ ++#ifdef HAVE_DIX_CONFIG_H ++#include <dix-config.h> ++#endif ++ ++#include <ctype.h> ++#include "dix.h" ++ ++#ifdef NEED_STRCASECMP ++int ++xstrcasecmp(char *str1,char *str2) ++{ ++ const u_char *us1 = (const u_char *)str1, *us2 = (const u_char *)str2; ++ ++ while (tolower(*us1) == tolower(*us2)) { ++ if (*us1++ == '\0') ++ return (0); ++ us2++; ++ } ++ ++ return (tolower(*us1) - tolower(*us2)); ++} ++#endif diff --git a/x11-base/xorg-server/files/digest-xorg-server-1.1.1-r1 b/x11-base/xorg-server/files/digest-xorg-server-1.1.1-r1 new file mode 100644 index 000000000000..6711eb87a087 --- /dev/null +++ b/x11-base/xorg-server/files/digest-xorg-server-1.1.1-r1 @@ -0,0 +1,6 @@ +MD5 d2c168c410009ef13e4198ae02cdb332 Mesa-20060831.tar.bz2 5531569 +RMD160 654eea5f311cd77ee46ded89208a0d8ae697facc Mesa-20060831.tar.bz2 5531569 +SHA256 f6e18eaadf6a0b1c7f926be7e15829c115ca277b2720f5644cfc1bb93db00a49 Mesa-20060831.tar.bz2 5531569 +MD5 a8ed678677af8ebb2fba5624602f6b2e xorg-server-1.1.1.tar.bz2 6252103 +RMD160 17675c45b1e6ec8ed025f73efcf481c60ff42941 xorg-server-1.1.1.tar.bz2 6252103 +SHA256 9d2df9eaced491dfe14f3ebccb15035ff8f2bc2b12f1124974adea90642dfd6c xorg-server-1.1.1.tar.bz2 6252103 diff --git a/x11-base/xorg-server/files/xorg-server-1.1.1-install-libxf86config-headers.patch b/x11-base/xorg-server/files/xorg-server-1.1.1-install-libxf86config-headers.patch new file mode 100644 index 000000000000..07b5219bf2b4 --- /dev/null +++ b/x11-base/xorg-server/files/xorg-server-1.1.1-install-libxf86config-headers.patch @@ -0,0 +1,19 @@ +diff --git a/hw/xfree86/parser/Makefile.am b/hw/xfree86/parser/Makefile.am +index acda83d..6b9b62a 100644 +--- a/hw/xfree86/parser/Makefile.am ++++ b/hw/xfree86/parser/Makefile.am +@@ -25,10 +25,12 @@ libxf86config_a_SOURCES = \ + + AM_CFLAGS = $(XORG_CFLAGS) + ++sdk_HEADERS = \ ++ xf86Optrec.h \ ++ xf86Parser.h ++ + EXTRA_DIST = \ + Configint.h \ + configProcs.h \ +- xf86Optrec.h \ +- xf86Parser.h \ + xf86tokens.h \ + cpconfig.c diff --git a/x11-base/xorg-server/xorg-server-1.1.1-r1.ebuild b/x11-base/xorg-server/xorg-server-1.1.1-r1.ebuild new file mode 100644 index 000000000000..de3245853148 --- /dev/null +++ b/x11-base/xorg-server/xorg-server-1.1.1-r1.ebuild @@ -0,0 +1,507 @@ +# Copyright 1999-2006 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/x11-base/xorg-server/xorg-server-1.1.1-r1.ebuild,v 1.1 2006/09/05 23:17:08 dberkholz Exp $ + +# Must be before x-modular eclass is inherited +SNAPSHOT="yes" + +inherit x-modular multilib + +OPENGL_DIR="xorg-x11" + +MESA_PN="Mesa" +MESA_PV="20060831" +MESA_P="${MESA_PN}-${MESA_PV}" +MESA_SRC_P="${MESA_PN}-${MESA_PV}" + +PATCHES="${FILESDIR}/01-no-move-damage.patch + ${FILESDIR}/02-dont-backfill-bg-none.patch + ${FILESDIR}/03-tfp-damage.patch + ${FILESDIR}/04-mesa-copy-sub-buffer.patch + ${FILESDIR}/05-offscreen-pixmaps.patch + ${FILESDIR}/06-aiglx-happy-vt-switch.patch + ${FILESDIR}/xorg-x11-server-1.1.1-mesa-6.5.1.patch + ${FILESDIR}/${P}-install-libxf86config-headers.patch + ${FILESDIR}/${PV}-fix-xrandr-zoom-keys.patch" + + +SRC_URI="${SRC_URI} + http://www.schokokeks.org/~hanno/snapshots/${MESA_SRC_P}.tar.bz2 + http://xorg.freedesktop.org/snapshots/individual/xserver/${P}.tar.bz2" +DESCRIPTION="X.Org X servers" +# It's suid and has lazy bindings, so FEATURES="stricter" doesn't work +RESTRICT="stricter" +KEYWORDS="~alpha ~amd64 arm ~hppa ~ia64 mips ppc ppc64 sh sparc ~x86 ~x86-fbsd" +IUSE_INPUT_DEVICES=" + input_devices_acecad + input_devices_aiptek + input_devices_calcomp + input_devices_citron + input_devices_digitaledge + input_devices_dmc + input_devices_dynapro + input_devices_elo2300 + input_devices_elographics + input_devices_evdev + input_devices_fpit + input_devices_hyperpen + input_devices_jamstudio + input_devices_joystick + input_devices_keyboard + input_devices_magellan + input_devices_microtouch + input_devices_mouse + input_devices_mutouch + input_devices_palmax + input_devices_penmount + input_devices_spaceorb + input_devices_summa + input_devices_tek4957 + input_devices_ur98 + input_devices_vmmouse + input_devices_void + + input_devices_synaptics + input_devices_wacom" +IUSE_VIDEO_CARDS=" + video_cards_apm + video_cards_ark + video_cards_chips + video_cards_cirrus + video_cards_cyrix + video_cards_dummy + video_cards_epson + video_cards_fbdev + video_cards_glint + video_cards_i128 + video_cards_i740 + video_cards_i810 + video_cards_impact + video_cards_imstt + video_cards_mach64 + video_cards_mga + video_cards_neomagic + video_cards_newport + video_cards_nsc + video_cards_nv + video_cards_r128 + video_cards_radeon + video_cards_rendition + video_cards_s3 + video_cards_s3virge + video_cards_savage + video_cards_siliconmotion + video_cards_sis + video_cards_sisusb + video_cards_sunbw2 + video_cards_suncg14 + video_cards_suncg3 + video_cards_suncg6 + video_cards_sunffb + video_cards_sunleo + video_cards_suntcx + video_cards_tdfx + video_cards_tga + video_cards_trident + video_cards_tseng + video_cards_v4l + video_cards_vesa + video_cards_vga + video_cards_via + video_cards_vmware + video_cards_voodoo + + video_cards_fglrx + video_cards_nvidia" +IUSE_SERVERS="dmx kdrive xorg" +IUSE="${IUSE_VIDEO_CARDS} + ${IUSE_INPUT_DEVICES} + ${IUSE_SERVERS} + 3dfx + dri ipv6 minimal nptl sdl xprint" +RDEPEND="x11-libs/libXfont + x11-libs/xtrans + x11-libs/libXau + x11-libs/libXext + x11-libs/libX11 + x11-libs/libxkbfile + x11-libs/libXdmcp + x11-libs/libXmu + x11-libs/libXrender + x11-libs/libXi + media-libs/freetype + >=media-libs/mesa-6.5-r2 + media-fonts/font-adobe-75dpi + media-fonts/font-misc-misc + media-fonts/font-cursor-misc + x11-misc/xbitmaps + || ( x11-misc/xkeyboard-config x11-misc/xkbdata ) + x11-apps/iceauth + x11-apps/rgb + x11-apps/xauth + x11-apps/xinit + app-admin/eselect-opengl + x11-libs/libXaw + x11-libs/libXpm + x11-libs/libXxf86misc + x11-libs/libXxf86vm + dmx? ( x11-libs/libdmx ) + !minimal? ( x11-libs/libXtst + x11-libs/libXres ) + >=x11-libs/libxkbui-1.0.2 + x11-libs/liblbxutil + kdrive? ( sdl? ( media-libs/libsdl ) ) + !media-video/nvidia-glx" + # Xres is dmx-dependent, xkbui is xorgcfg-dependent + # Xaw is dmx- and xorgcfg-dependent + # Xpm is dmx- and xorgcfg-dependent, pulls in Xt + # Xxf86misc and Xxf86vm are xorgcfg-dependent + # liblbxutil is lbx- dependent +DEPEND="${RDEPEND} + x11-proto/randrproto + x11-proto/renderproto + >=x11-proto/fixesproto-4 + x11-proto/damageproto + x11-proto/xextproto + x11-proto/xproto + x11-proto/xf86dgaproto + x11-proto/xf86miscproto + x11-proto/xf86rushproto + x11-proto/xf86vidmodeproto + x11-proto/xf86bigfontproto + >=x11-proto/compositeproto-0.3 + x11-proto/recordproto + x11-proto/resourceproto + x11-proto/videoproto + >=x11-proto/scrnsaverproto-1.1.0 + x11-proto/evieext + x11-proto/trapproto + >=x11-proto/xineramaproto-1.1-r1 + x11-proto/fontsproto + >=x11-proto/kbproto-1.0-r1 + x11-proto/inputproto + x11-proto/bigreqsproto + x11-proto/xcmiscproto + >=x11-proto/glproto-1.4.6 + dmx? ( x11-proto/dmxproto ) + dri? ( x11-proto/xf86driproto + >=x11-libs/libdrm-2 ) + xprint? ( x11-proto/printproto + x11-apps/mkfontdir + x11-apps/mkfontscale )" + +# Drivers +PDEPEND=" + xorg? ( + input_devices_acecad? ( >=x11-drivers/xf86-input-acecad-1.1.0 ) + input_devices_aiptek? ( >=x11-drivers/xf86-input-aiptek-1.0.1 ) + input_devices_calcomp? ( >=x11-drivers/xf86-input-calcomp-1.1.0 ) + input_devices_citron? ( >=x11-drivers/xf86-input-citron-2.2.0 ) + input_devices_digitaledge? ( >=x11-drivers/xf86-input-digitaledge-1.1.0 ) + input_devices_dmc? ( >=x11-drivers/xf86-input-dmc-1.1.0 ) + input_devices_dynapro? ( >=x11-drivers/xf86-input-dynapro-1.1.0 ) + input_devices_elo2300? ( >=x11-drivers/xf86-input-elo2300-1.1.0 ) + input_devices_elographics? ( >=x11-drivers/xf86-input-elographics-1.1.0 ) + input_devices_evdev? ( >=x11-drivers/xf86-input-evdev-1.1.1 ) + input_devices_fpit? ( >=x11-drivers/xf86-input-fpit-1.1.0 ) + input_devices_hyperpen? ( >=x11-drivers/xf86-input-hyperpen-1.1.0 ) + input_devices_jamstudio? ( >=x11-drivers/xf86-input-jamstudio-1.1.0 ) + input_devices_joystick? ( >=x11-drivers/xf86-input-joystick-1.1.0 ) + input_devices_keyboard? ( >=x11-drivers/xf86-input-keyboard-1.1.0 ) + input_devices_magellan? ( >=x11-drivers/xf86-input-magellan-1.1.0 ) + input_devices_microtouch? ( >=x11-drivers/xf86-input-microtouch-1.1.0 ) + input_devices_mouse? ( >=x11-drivers/xf86-input-mouse-1.1.0 ) + input_devices_mutouch? ( >=x11-drivers/xf86-input-mutouch-1.1.0 ) + input_devices_palmax? ( >=x11-drivers/xf86-input-palmax-1.1.0 ) + input_devices_penmount? ( >=x11-drivers/xf86-input-penmount-1.1.0 ) + input_devices_spaceorb? ( >=x11-drivers/xf86-input-spaceorb-1.1.0 ) + input_devices_summa? ( >=x11-drivers/xf86-input-summa-1.1.0 ) + input_devices_tek4957? ( >=x11-drivers/xf86-input-tek4957-1.1.0 ) + input_devices_ur98? ( >=x11-drivers/xf86-input-ur98-1.1.0 ) + input_devices_vmmouse? ( >=x11-drivers/xf86-input-vmmouse-12.4.0 ) + input_devices_void? ( >=x11-drivers/xf86-input-void-1.1.0 ) + + input_devices_synaptics? ( x11-drivers/synaptics ) + input_devices_wacom? ( x11-drivers/linuxwacom ) + + video_cards_apm? ( >=x11-drivers/xf86-video-apm-1.1.1 ) + video_cards_ark? ( >=x11-drivers/xf86-video-ark-0.6.0 ) + video_cards_chips? ( >=x11-drivers/xf86-video-chips-1.1.1 ) + video_cards_cirrus? ( >=x11-drivers/xf86-video-cirrus-1.1.0 ) + video_cards_cyrix? ( >=x11-drivers/xf86-video-cyrix-1.1.0 ) + video_cards_dummy? ( >=x11-drivers/xf86-video-dummy-0.2.0 ) + video_cards_fbdev? ( >=x11-drivers/xf86-video-fbdev-0.2.0 ) + video_cards_glint? ( >=x11-drivers/xf86-video-glint-1.1.1 ) + video_cards_i128? ( >=x11-drivers/xf86-video-i128-1.2.0 ) + video_cards_i740? ( >=x11-drivers/xf86-video-i740-1.1.0 ) + video_cards_i810? ( >=x11-drivers/xf86-video-i810-1.6.0 ) + video_cards_impact? ( >=x11-drivers/xf86-video-impact-0.2.0 ) + video_cards_imstt? ( >=x11-drivers/xf86-video-imstt-1.1.0 ) + video_cards_mach64? ( >=x11-drivers/xf86-video-ati-6.6.0 ) + video_cards_mga? ( >=x11-drivers/xf86-video-mga-1.4.1 ) + video_cards_neomagic? ( >=x11-drivers/xf86-video-neomagic-1.1.1 ) + video_cards_newport? ( >=x11-drivers/xf86-video-newport-0.2.0 ) + video_cards_nsc? ( >=x11-drivers/xf86-video-nsc-2.8.1 ) + video_cards_nv? ( >=x11-drivers/xf86-video-nv-1.1.1 ) + video_cards_r128? ( >=x11-drivers/xf86-video-ati-6.6.0 ) + video_cards_radeon? ( >=x11-drivers/xf86-video-ati-6.6.0 ) + video_cards_rendition? ( >=x11-drivers/xf86-video-rendition-4.1.0 ) + video_cards_s3? ( >=x11-drivers/xf86-video-s3-0.4.1 ) + video_cards_s3virge? ( >=x11-drivers/xf86-video-s3virge-1.9.1 ) + video_cards_savage? ( >=x11-drivers/xf86-video-savage-2.1.1 ) + video_cards_siliconmotion? ( >=x11-drivers/xf86-video-siliconmotion-1.4.1 ) + video_cards_sis? ( >=x11-drivers/xf86-video-sis-0.9.1 ) + video_cards_sisusb? ( >=x11-drivers/xf86-video-sisusb-0.8.1 ) + video_cards_sunbw2? ( >=x11-drivers/xf86-video-sunbw2-1.1.0 ) + video_cards_suncg14? ( >=x11-drivers/xf86-video-suncg14-1.1.0 ) + video_cards_suncg3? ( >=x11-drivers/xf86-video-suncg3-1.1.0 ) + video_cards_suncg6? ( >=x11-drivers/xf86-video-suncg6-1.1.0 ) + video_cards_sunffb? ( >=x11-drivers/xf86-video-sunffb-1.1.0 ) + video_cards_sunleo? ( >=x11-drivers/xf86-video-sunleo-1.1.0 ) + video_cards_suntcx? ( >=x11-drivers/xf86-video-suntcx-1.1.0 ) + video_cards_tdfx? ( >=x11-drivers/xf86-video-tdfx-1.2.1 ) + video_cards_tga? ( >=x11-drivers/xf86-video-tga-1.1.0 ) + video_cards_trident? ( >=x11-drivers/xf86-video-trident-1.2.1 ) + video_cards_tseng? ( >=x11-drivers/xf86-video-tseng-1.1.0 ) + video_cards_v4l? ( >=x11-drivers/xf86-video-v4l-0.1.1 ) + video_cards_vesa? ( >=x11-drivers/xf86-video-vesa-1.1.0 ) + video_cards_vga? ( >=x11-drivers/xf86-video-vga-4.1.0 ) + video_cards_via? ( >=x11-drivers/xf86-video-via-0.2.1 ) + video_cards_vmware? ( >=x11-drivers/xf86-video-vmware-10.13.0 ) + video_cards_voodoo? ( >=x11-drivers/xf86-video-voodoo-1.1.0 ) + + video_cards_tdfx? ( 3dfx? ( >=media-libs/glide-v3-3.10 ) ) + video_cards_fglrx? ( >=x11-drivers/ati-drivers-8.27.10 ) + video_cards_nvidia? ( || ( + >=x11-drivers/nvidia-drivers-1.0.8774 + >=x11-drivers/nvidia-legacy-drivers-1.0.7184 + ) + ) + )" +LICENSE="${LICENSE} MIT" + +pkg_setup() { + use minimal || ensure_a_server_is_building + + # Bug #145274 - anything that uses vm86.h is broken on AMD64 + if use kdrive && use amd64 && use video_cards_vesa; then + eerror "kdrive's VESA driver does not build on AMD64 because it uses" + eerror "vm86.h. Please build kdrive without VIDEO_CARDS=\"vesa\"." + die "kdrive's VESA driver does not build on AMD64." + fi + + # localstatedir is used for the log location; we need to override the default + # from ebuild.sh + # sysconfdir is used for the xorg.conf location; same applies + + # --enable-xorg needed because darwin defaults off + # --enable-install-setuid needed because sparcs default off + + # SDL only available in kdrive build + if use kdrive && use sdl; then + conf_opts="${conf_opts} --enable-xsdl" + else + conf_opts="${conf_opts} --disable-xsdl" + fi + + # Only Xorg and Xgl support this, and we won't build Xgl + # until it merges to trunk + if use xorg; then + conf_opts="${conf_opts} --with-mesa-source=${WORKDIR}/Mesa" + fi + + CONFIGURE_OPTIONS=" + $(use_enable ipv6) + $(use_enable dmx) + $(use_enable kdrive) + $(use_enable !minimal xvfb) + $(use_enable !minimal xnest) + $(use_enable !minimal xorgcfg) + $(use_enable !minimal install-libxf86config) + $(use_enable dri) + $(use_enable xorg) + $(use_enable xprint) + $(use_enable nptl glx-tls) + --sysconfdir=/etc/X11 + --localstatedir=/var + --enable-install-setuid + --with-default-font-path=/usr/share/fonts/misc,/usr/share/fonts/75dpi,/usr/share/fonts/100dpi,/usr/share/fonts/TTF,/usr/share/fonts/Type1 + ${conf_opts}" + + local diemsg="You must build xorg-server and mesa with the same nptl USE setting." + if built_with_use media-libs/mesa nptl; then + use nptl || die "${diemsg}" + else + use nptl && die "${diemsg}" + fi + + # (#121394) Causes window corruption + filter-flags -fweb + + # Nothing else provides new enough glxtokens.h + ewarn "Forcing on xorg-x11 for new enough glxtokens.h..." + OLD_IMPLEM="$(eselect opengl show)" + eselect opengl set --impl-headers ${OPENGL_DIR} +} + +src_unpack() { + x-modular_specs_check + x-modular_dri_check + x-modular_unpack_source + x-modular_patch_source + + # https://bugs.freedesktop.org/show_bug.cgi?id=3914 + # Addition of Altix support breaks 64-bit BARs, + # which causes sparc64 lockups with ATI video + # The sparc team will maintain and forward-port this patch. + if use sparc && use video_cards_mach64; then + epatch "${FILESDIR}"/${PV}-remove-altix.patch + fi + + # Set up kdrive servers to build + if use kdrive; then + einfo "Removing unused kdrive drivers ..." + for card in ${IUSE_VIDEO_CARDS}; do + # (bug #136370) Radeon needs fbdev and vesa + if use video_cards_radeon; then + if [[ ${card} = video_cards_fbdev ]] \ + || [[ ${card} = video_cards_vesa ]]; then + continue + fi + fi + + real_card=${card#video_cards_} + + # Differences between VIDEO_CARDS name and kdrive server name + real_card=${real_card/glint/pm2} + real_card=${real_card/radeon/ati} + real_card=${real_card/%nv/nvidia} + real_card=${real_card/siliconmotion/smi} + real_card=${real_card/%sis/sis300} + if ! use ${card}; then + ebegin " ${real_card}" + sed -i \ + -e "s:\b${real_card}\b::g" \ + ${S}/hw/kdrive/Makefile.am \ + || die "sed of ${real_card} failed" + eend + fi + + done + + # smi and via are the only things on line 2. If line 2 ends up blank, + # we need to get rid of the backslash at the end of line 1. + if ! use video_cards_siliconmotion && ! use video_cards_via; then + sed -i \ + -e "s:^\(VESA_SUBDIRS.*\)\\\:\1:g" \ + ${S}/hw/kdrive/Makefile.am + fi + fi + + # Make sure eautoreconf gets run if we need the autoconf/make + # changes. + if [[ ${SNAPSHOT} != "yes" ]]; then + if use kdrive || use xprint; then + eautoreconf + fi + fi + x-modular_reconf_source +} + +src_install() { + x-modular_src_install + + dynamic_libgl_install + + server_based_install + + # Install video mode files for system-config-display + insinto /usr/share/xorg + doins hw/xfree86/common/{extra,vesa}modes \ + || die "couldn't install extra modes" +} + +pkg_postinst() { + switch_opengl_implem + + # Bug #135544 + ewarn "Users of reduced blanking now need:" + ewarn " Option \"ReducedBlanking\"" + ewarn "In the relevant Monitor section(s)." + ewarn "Make sure your reduced blanking modelines are safe!" +} + +pkg_postrm() { + # Get rid of module dir to ensure opengl-update works properly + if ! has_version x11-base/xorg-server; then + if [ -e ${ROOT}/usr/$(get_libdir)/xorg/modules ]; then + rm -rf ${ROOT}/usr/$(get_libdir)/xorg/modules + fi + fi +} + +dynamic_libgl_install() { + # next section is to setup the dynamic libGL stuff + ebegin "Moving GL files for dynamic switching" + dodir /usr/$(get_libdir)/opengl/${OPENGL_DIR}/extensions + local x="" + for x in ${D}/usr/$(get_libdir)/xorg/modules/extensions/libglx*; do + if [ -f ${x} -o -L ${x} ]; then + mv -f ${x} ${D}/usr/$(get_libdir)/opengl/${OPENGL_DIR}/extensions + fi + done + eend 0 +} + +server_based_install() { + use xprint && xprint_src_install + + if ! use xorg; then + rm ${D}/usr/share/man/man1/Xserver.1x \ + ${D}/usr/$(get_libdir)/xserver/SecurityPolicy \ + ${D}/usr/$(get_libdir)/pkgconfig/xorg-server.pc \ + ${D}/usr/share/man/man1/Xserver.1x + fi +} + +switch_opengl_implem() { + # Switch to the xorg implementation. + # Use new opengl-update that will not reset user selected + # OpenGL interface ... + echo +# eselect opengl set --use-old ${OPENGL_DIR} + eselect opengl set ${OLD_IMPLEM} +} + +xprint_src_install() { + # RH-style init script, we provide a wrapper + exeinto /usr/$(get_libdir)/misc + doexe ${S}/Xprint/etc/init.d/xprint + # Patch init script for fonts location + sed -e 's:/lib/X11/fonts/:/share/fonts/:g' \ + -i ${D}/usr/$(get_libdir)/misc/xprint + # Install the wrapper + newinitd ${FILESDIR}/xprint.init xprint + # Install profile scripts + insinto /etc/profile.d + doins ${S}/Xprint/etc/profile.d/xprint* + insinto /etc/X11/xinit/xinitrc.d + newins ${S}/Xprint/etc/Xsession.d/cde_xsessiond_xprint.sh \ + 92xprint-xpserverlist.sh + # Patch profile scripts + sed -e "s:/bin/sh.*get_xpserverlist:/usr/$(get_libdir)/misc/xprint \ + get_xpserverlist:g" -i ${D}/etc/profile.d/xprint* \ + ${D}/etc/X11/xinit/xinitrc.d/92xprint-xpserverlist.sh + # Move profile scripts, we can't touch /etc/profile.d/ in Gentoo + dodoc ${D}/etc/profile.d/xprint* + rm -f ${D}/etc/profile.d/xprint* +} + +ensure_a_server_is_building() { + for server in ${IUSE_SERVERS}; do + use ${server} && return; + done + eerror "You need to specify at least one server to build." + eerror "Valid servers are: ${IUSE_SERVERS}." + die "No servers were specified to build." +} |