/[gentoo-x86]/x11-base/xorg-server/xorg-server-1.7.7-r1.ebuild
Gentoo

Contents of /x11-base/xorg-server/xorg-server-1.7.7-r1.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.7 - (hide annotations) (download)
Mon Sep 20 17:36:10 2010 UTC (4 years, 3 months ago) by armin76
Branch: MAIN
Changes since 1.6: +2 -2 lines
ia64/sh/sparc stable wrt #330593
(Portage version: 2.1.8.3/cvs/Linux ia64)

1 scarabeus 1.1 # Copyright 1999-2010 Gentoo Foundation
2     # Distributed under the terms of the GNU General Public License v2
3 armin76 1.7 # $Header: /var/cvsroot/gentoo-x86/x11-base/xorg-server/xorg-server-1.7.7-r1.ebuild,v 1.6 2010/09/05 11:59:11 remi Exp $
4 scarabeus 1.1
5     EAPI="2"
6    
7     # Must be before x-modular eclass is inherited
8     SNAPSHOT="yes"
9    
10     inherit x-modular multilib versionator
11    
12     EGIT_REPO_URI="git://anongit.freedesktop.org/git/xorg/xserver"
13    
14     OPENGL_DIR="xorg-x11"
15    
16     SRC_URI="${SRC_URI}
17     http://dev.gentoo.org/~scarabeus/${P}-patches-01.tar.bz2
18     "
19     DESCRIPTION="X.Org X servers"
20 armin76 1.7 KEYWORDS="~alpha amd64 arm ~hppa ia64 ~mips ~ppc ~ppc64 sh sparc x86 ~x86-fbsd"
21 scarabeus 1.1
22     IUSE_SERVERS="dmx kdrive xorg"
23     IUSE="${IUSE_SERVERS} tslib hal ipv6 minimal nptl sdl"
24     RDEPEND="hal? ( sys-apps/hal )
25     tslib? ( >=x11-libs/tslib-1.0 x11-proto/xcalibrateproto )
26     dev-libs/openssl
27     >=x11-libs/libXfont-1.3.3
28     >=x11-libs/xtrans-1.2.2
29     >=x11-libs/libXau-1.0.4
30     >=x11-libs/libxkbfile-1.0.4
31     >=x11-libs/libXdmcp-1.0.2
32     >=x11-libs/libpciaccess-0.10.3
33     >=x11-libs/pixman-0.15.20
34     media-libs/freetype
35     >=x11-misc/xbitmaps-1.0.1
36     >=x11-misc/xkeyboard-config-1.4
37     x11-apps/xkbcomp
38     >=x11-apps/iceauth-1.0.2
39     >=x11-apps/rgb-1.0.3
40     >=x11-apps/xauth-1.0.3
41     <=x11-apps/xinit-1.2.1
42     >=app-admin/eselect-opengl-1.0.8
43     dmx? (
44     x11-libs/libXt
45     >=x11-libs/libdmx-1.0.99.1
46     >=x11-libs/libX11-1.1.5
47     >=x11-libs/libXaw-1.0.4
48     >=x11-libs/libXext-1.0.5
49     >=x11-libs/libXfixes-4.0.3
50     >=x11-libs/libXi-1.2.99.1
51     >=x11-libs/libXmu-1.0.3
52     >=x11-libs/libXtst-1.0.3
53     )
54     !minimal? (
55     >=x11-libs/libX11-1.1.5
56     >=x11-libs/libXext-1.0.5
57     >=x11-libs/libXres-1.0.3
58     >=media-libs/mesa-7.4[nptl=]
59     )
60     >=x11-libs/libxkbui-1.0.2
61     kdrive? (
62     >=x11-libs/libXext-1.0.5
63 remi 1.6 x11-libs/libXv
64     sdl? ( media-libs/libsdl )
65     )"
66 scarabeus 1.1 # Xres is dmx-dependent
67     # Xaw is dmx-dependent
68     # Xpm is dmx-dependent, pulls in Xt
69     # xkbcomp is launched at startup but not checked by ./configure
70    
71     ## Deps that don't have a version in configure.ac but do here:
72     # x11-proto/resourceproto
73     # x11-proto/fontsproto
74     # x11-libs/libXau
75     # x11-libs/libXfont
76     # x11-libs/libXdmcp
77     # x11-libs/libXext
78     # x11-libs/libX11
79     # x11-libs/libXrender
80     # x11-libs/libXmu
81     # x11-libs/libXfixes
82     # x11-libs/libXtst
83     # x11-proto/xineramaproto
84     # x11-proto/dmxproto
85     ## Deps that are larger here than in configure.ac
86     # x11-libs/libpciaccess-0.8.0
87     #
88    
89     DEPEND="${RDEPEND}
90     !!net-dialup/dtrace
91     sys-devel/flex
92     >=x11-proto/randrproto-1.2.99.3
93     >=x11-proto/renderproto-0.11
94     >=x11-proto/fixesproto-4.1
95     >=x11-proto/damageproto-1.1
96     >=x11-proto/xextproto-7.0.99.3
97     >=x11-proto/xproto-7.0.13
98     >=x11-proto/xf86dgaproto-2.0.99.1
99     >=x11-proto/xf86rushproto-1.1.2
100     >=x11-proto/xf86vidmodeproto-2.2.99.1
101     >=x11-proto/compositeproto-0.4
102     >=x11-proto/recordproto-1.13.99.1
103     >=x11-proto/resourceproto-1.0.2
104     >=x11-proto/videoproto-2.2.2
105     >=x11-proto/scrnsaverproto-1.1
106     >=x11-proto/trapproto-3.4.3
107     >=x11-proto/xineramaproto-1.1.3
108     >=x11-proto/fontsproto-2.0.2
109     >=x11-proto/kbproto-1.0.3
110     >=x11-proto/inputproto-1.9.99.902
111     >=x11-proto/bigreqsproto-1.1.0
112     >=x11-proto/xcmiscproto-1.2.0
113     >=x11-proto/glproto-1.4.9
114     dmx? ( >=x11-proto/dmxproto-2.2.99.1 )
115     !minimal? (
116     >=x11-proto/xf86driproto-2.1.0
117     >=x11-proto/dri2proto-2.1
118     >=x11-libs/libdrm-2.3.0
119     )"
120    
121     PDEPEND="xorg? ( >=x11-base/xorg-drivers-$(get_version_component_range 1-2) )"
122    
123     EPATCH_FORCE="yes"
124     EPATCH_SUFFIX="patch"
125    
126     # These have been sent upstream
127     UPSTREAMED_PATCHES=(
128     "${WORKDIR}/patches/"
129     # Fix for bug #304067
130     "${FILESDIR}/1.7.5.902-fix-tslib-1.0-check.patch"
131 chithanh 1.2 "${FILESDIR}"/${PN}-1.8-nouveau-default.patch
132 scarabeus 1.1 )
133    
134     PATCHES=(
135     "${UPSTREAMED_PATCHES[@]}"
136     )
137    
138     pkg_setup() {
139     use minimal || ensure_a_server_is_building
140    
141     # SDL only available in kdrive build
142     if use kdrive && use sdl; then
143     conf_opts="${conf_opts} --enable-xsdl"
144     else
145     conf_opts="${conf_opts} --disable-xsdl"
146     fi
147    
148     # localstatedir is used for the log location; we need to override the default
149     # from ebuild.sh
150     # sysconfdir is used for the xorg.conf location; same applies
151     # --enable-install-setuid needed because sparcs default off
152     CONFIGURE_OPTIONS="
153     $(use_enable ipv6)
154     $(use_enable dmx)
155     $(use_enable kdrive)
156     $(use_enable tslib)
157     $(use_enable tslib xcalibrate)
158     $(use_enable !minimal xvfb)
159     $(use_enable !minimal xnest)
160     $(use_enable !minimal record)
161     $(use_enable !minimal xfree86-utils)
162     $(use_enable !minimal install-libxf86config)
163     $(use_enable !minimal dri)
164     $(use_enable !minimal dri2)
165     $(use_enable !minimal glx)
166     $(use_enable xorg)
167     $(use_enable nptl glx-tls)
168     $(use_enable hal config-hal)
169     --sysconfdir=/etc/X11
170     --localstatedir=/var
171     --enable-install-setuid
172     --with-fontdir=/usr/share/fonts
173     --with-xkb-output=/var/lib/xkb
174     --without-dtrace
175     ${conf_opts}"
176    
177     # (#121394) Causes window corruption
178     filter-flags -fweb
179    
180     # Incompatible with GCC 3.x SSP on x86, bug #244352
181     if use x86 ; then
182     if [[ $(gcc-major-version) -lt 4 ]]; then
183     filter-flags -fstack-protector
184     fi
185     fi
186    
187     # Incompatible with GCC 3.x CPP, bug #314615
188     if [[ $(gcc-major-version) -lt 4 ]]; then
189     ewarn "GCC 3.x C preprocessor may cause build failures. Use GCC 4.x"
190     ewarn "or set CPP=cpp-4.3.4 (replace with the actual installed version)"
191     fi
192    
193     OLD_IMPLEM="$(eselect opengl show)"
194     eselect opengl set ${OPENGL_DIR}
195     }
196    
197     src_install() {
198     x-modular_src_install
199    
200     dynamic_libgl_install
201    
202     server_based_install
203    
204     if ! use minimal && use xorg; then
205     # Install xorg.conf.example (see bugs #151421 and #151670)
206     insinto /etc/X11
207     doins hw/xfree86/xorg.conf.example \
208     || die "couldn't install xorg.conf.example"
209     fi
210     }
211    
212     pkg_postinst() {
213     switch_opengl_implem
214    
215     echo
216     ewarn "You must rebuild all drivers if upgrading from xorg-server 1.6"
217     ewarn "or earlier, because the ABI changed. If you cannot start X because"
218     ewarn "of module version mismatch errors, this is your problem."
219    
220     echo
221     ewarn "You can generate a list of all installed packages in the x11-drivers"
222     ewarn "category using this command:"
223     ewarn "emerge portage-utils; qlist -I -C x11-drivers/"
224    
225     ebeep 5
226     epause 10
227     }
228    
229     pkg_postrm() {
230     # Get rid of module dir to ensure opengl-update works properly
231     if ! has_version x11-base/xorg-server; then
232     if [[ -e ${ROOT}/usr/$(get_libdir)/xorg/modules ]]; then
233     rm -rf "${ROOT}"/usr/$(get_libdir)/xorg/modules
234     fi
235     fi
236     }
237    
238     dynamic_libgl_install() {
239     # next section is to setup the dynamic libGL stuff
240     ebegin "Moving GL files for dynamic switching"
241     dodir /usr/$(get_libdir)/opengl/${OPENGL_DIR}/extensions
242     local x=""
243     for x in "${D}"/usr/$(get_libdir)/xorg/modules/extensions/lib{glx,dri,dri2}*; do
244     if [ -f ${x} -o -L ${x} ]; then
245     mv -f ${x} "${D}"/usr/$(get_libdir)/opengl/${OPENGL_DIR}/extensions
246     fi
247     done
248     eend 0
249     }
250    
251     server_based_install() {
252     if ! use xorg; then
253     rm "${D}"/usr/share/man/man1/Xserver.1x \
254     "${D}"/usr/$(get_libdir)/xserver/SecurityPolicy \
255     "${D}"/usr/$(get_libdir)/pkgconfig/xorg-server.pc \
256     "${D}"/usr/share/man/man1/Xserver.1x
257     fi
258     }
259    
260     switch_opengl_implem() {
261     # Switch to the xorg implementation.
262     # Use new opengl-update that will not reset user selected
263     # OpenGL interface ...
264     echo
265     eselect opengl set ${OLD_IMPLEM}
266     }
267    
268     ensure_a_server_is_building() {
269     for server in ${IUSE_SERVERS}; do
270     use ${server} && return;
271     done
272     eerror "You need to specify at least one server to build."
273     eerror "Valid servers are: ${IUSE_SERVERS}."
274     die "No servers were specified to build."
275     }

  ViewVC Help
Powered by ViewVC 1.1.20