summaryrefslogtreecommitdiff
blob: 53d5f5981457a64d9649ebc6d572403ef7023489 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
# Copyright 1999-2006 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/x11-base/xorg-x11/xorg-x11-7.0.ebuild,v 1.3 2006/01/05 18:39:24 spyderous Exp $

inherit eutils

DESCRIPTION="An X11 implementation maintained by the X.Org Foundation (meta
package)"
HOMEPAGE="http://xorg.freedesktop.org"

LICENSE="as-is"
SLOT="0"
KEYWORDS="~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~sh ~sparc ~x86"
IUSE="3dfx xprint"

# Collision protect will scream bloody murder if we install over old versions
RDEPEND="!<=x11-base/xorg-x11-6.9"

# Server
RDEPEND="${RDEPEND}
	>=x11-base/xorg-server-1.0.1"

# Common Applications
RDEPEND="${RDEPEND}
	>=x11-apps/mesa-progs-6.4.1
	>=x11-apps/setxkbmap-1.0.1
	>=x11-apps/xauth-1.0.1
	>=x11-apps/xhost-1
	>=x11-apps/xinit-1.0.1
	>=x11-apps/xmodmap-1
	>=x11-apps/xrandr-1.0.1"

# Common Libraries - move these to eclass eventually
RDEPEND="${RDEPEND}
	>=x11-libs/libSM-1
	>=x11-libs/libXcomposite-0.2.2.2
	>=x11-libs/libXcursor-1.1.5.2
	>=x11-libs/libXdamage-1.0.2.2
	>=x11-libs/libXfixes-3.0.1.2
	>=x11-libs/libXv-1.0.1
	>=x11-libs/libXxf86dga-1
	>=x11-libs/libXinerama-1.0.1
	>=x11-libs/libXScrnSaver-1.0.1
	xprint? ( >=x11-libs/libXp-1 )
	3dfx? ( >=media-libs/glide-v3-3.10 )"

# Some fonts
RDEPEND="${RDEPEND}
	>=media-fonts/font-bh-ttf-1
	>=media-fonts/font-adobe-utopia-type1-1.0.1
	>=media-fonts/font-bitstream-type1-1"

# Documentation
RDEPEND="${RDEPEND}
	>=app-doc/xorg-docs-1.0.1"

DEPEND="${RDEPEND}"

src_install() {
	# Make /usr/X11R6 a symlink to ../usr.
	dodir /usr
	dosym ../usr /usr/X11R6
}

pkg_preinst() {
	# Check for /usr/X11R6 -> /usr symlink
	if [[ -e "/usr/X11R6" ]] &&
		[[ $(readlink "/usr/X11R6") != "../usr" ]]; then
			eerror "/usr/X11R6 isn't a symlink to ../usr. Please delete it."
			ewarn "First, save a list of all the packages installing there:"
			ewarn "		equery belongs /usr/X11R6 > usr-x11r6-packages"
			ewarn "This requires gentoolkit to be installed."
			die "/usr/X11R6 is not a symlink to ../usr."
	fi

	# Filter out ModulePath line since it often holds a now-invalid path
	# Bug #112924
	# For RC3 - filter out RgbPath line since it also seems to break things
	XORGCONF="/etc/X11/xorg.conf"
	if [ -e ${XORGCONF} ]; then
		mkdir -p "${IMAGE}/etc/X11"
		sed "/ModulePath/d" ${XORGCONF}	> ${IMAGE}${XORGCONF}
		sed -i "/RgbPath/d" ${IMAGE}${XORGCONF}
	fi
}

pkg_postinst() {
	# I'm not sure why this was added, but we don't inherit x-modular
	# x-modular_pkg_postinst

	echo
	einfo "Please note that the xcursors are in /usr/share/cursors/${PN}."
	einfo "Any custom cursor sets should be placed in that directory."
	echo
	einfo "If you wish to set system-wide default cursors, please create"
	einfo "/usr/local/share/cursors/${PN}/default/index.theme"
	einfo "with content: \"Inherits=theme_name\" so that future"
	einfo "emerges will not overwrite those settings."
	echo
	einfo "Listening on TCP is disabled by default with startx."
	einfo "To enable it, edit /usr/bin/startx."
	echo

	ewarn "Please read the modular X migration guide at"
	ewarn "http://dev.gentoo.org/~spyderous/xorg-x11/migrating_to_modular_x_howto.txt"
	echo
	einfo "If you encounter any non-configuration issues, please file a bug at"
	einfo "http://bugs.gentoo.org/enter_bug.cgi?product=Gentoo%20Linux"
	einfo "and attach /etc/X11/xorg.conf, /var/log/Xorg.0.log and emerge info"
	echo
	einfo "In the future, you will be able to affect which drivers are installed"
	einfo "with the VIDEO_CARDS and INPUT_DEVICES settings."
	echo

	# (#76985)
	einfo "Visit http://www.gentoo.org/doc/en/index.xml?catid=desktop"
	einfo "for more information on configuring X."
	echo

	# Try to get people to read this, pending #11359
	ebeep 5
	epause 10
}