# Copyright 1999-2003 Gentoo Technologies, Inc. # Distributed under the terms of the GNU General Public License v2 # $Header: $ # This ebuild is provided as is and is not going to be supported as has # been made clear by both Gentoo devs and the XFree project. Please read # http://www.xfree86.org/rel33x.html if you wish to use this version of # XFree86 especially the section regarding drivers in the 4.x tree. IUSE="truetype" DESCRIPTION="XFree86 server version 3.3.6 with CVS updates." HOMEPAGE="http://www.xfree86.org/rel33x.html" LICENSE="X11" SLOT="0" BASE_PV="${PV}" MY_SV="${BASE_PV//\.}" SRC_PATH="ftp://ftp.xfree86.org/pub/XFree86/${PV}" EX_VER="0.1" X_UPDATES="http://www.volutin.net/~andrew/GENTOO/XFree86-${PV}-patch-${EX_VER}.tar.bz2" X_FILES="http://www.volutin.net/~andrew/GENTOO/XFree86-${PV}-gentoo-files-${EX_VER}.tar.bz2" TT_FONTS="http://www.ibiblio.org/gentoo/gentoo-sources/truetype.tar.gz" SRC_URI="${SRC_PATH}/source/X${MY_SV}src-1.tgz ${SRC_PATH}/source/X${MY_SV}src-2.tgz ${SRC_PATH}/source/X${MY_SV}src-3.tgz ${SRC_PATH}/source/X${MY_SV}contrib.tgz ${X_UPDATES} ${X_FILES} truetype? ( ${TT_FONTS} )" # This is only until we are sure the ebuild works, really this shouldnt be # commited to cvs until this is out of the ~arch tree on at least x86. KEYWORDS="~x86" PROVIDE="virtual/x11 virtual/opengl" DEPEND=">=sys-libs/ncurses-5.1 >=sys-libs/zlib-1.1.3-r2 sys-devel/flex sys-devel/perl app-text/docbook-sgml-dtd app-text/docbook-sgml-utils" #RDEPEND="${DEPEND}" S="${WORKDIR}/xc" PATCH_DIR="${WORKDIR}/patch" src_unpack() { # Unpack the source and patch files einfo "Unpacking source..." unpack X${MY_SV}src-{1,2,3}.tgz > /dev/null # Unpack the updates and contrib einfo "Unpacking extras..." unpack X${MY_SV}contrib.tgz unpack XFree86-${PV}-patch-${EX_VER}.tar.bz2 unpack XFree86-${PV}-gentoo-files-${EX_VER}.tar.bz2 # Apply the CVS updates einfo "Applying CVS patch updates..." epatch ${PATCH_DIR} # Gentoo specifics cd ${S} cp ${WORKDIR}/files/site.def config/cf/host.def echo "#define DefaultGcc2i386Opt ${CFLAGS}" >> config/cf/host.def echo "#define GccWarningOptions -Wno" >> config/cf/host.def echo "#define DefaultCCOptions -ansi" >> config/cf/host.def } src_compile() { emake World || die "Failed in make World" } src_install() { emake install DESTDIR=${D} || die "Failed installing to ${D}" emake install.man DESTDIR=${D} || die "Failed installing man pages" # Remove the hardcode of our CFLAGS etc... echo > ${D}/usr/X11R6/lib/X11/config/host.def # Setup fonts einfo "Setting up fonts..." insinto /usr/X11R6/lib/X11 doins ${WORKDIR}/files/XftConfig if use truetype then cd ${D}/usr/X11R6/lib/X11/fonts tar -xz --no-same-owner -f ${DISTDIR}/truetype.tar.gz fi # X libGL symlinks. dosym /usr/X11R6/lib/libGL.so.1.2 /usr/X11R6/lib/libMesaGL.so dosym /usr/X11R6/bin /usr/bin/X11 rm -rf ${D}/usr/lib insinto /etc/env.d doins ${WORKDIR}/files/10xfree insinto /etc/X11/xinit doins ${WORKDIR}/files/xinitrc insinto /etc/X11/xdm doins ${WORKDIR}/files/Xsession insinto /etc/X11/fs newins ${WORKDIR}/files/xfs.config config insinto /etc/pam.d doins ${WORKDIR}/files/xdm exeinto /etc/init.d newexe ${WORKDIR}/files/xdm.start xdm newexe ${WORKDIR}/files/xfs.start xfs }