summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRobin H. Johnson <robbat2@gentoo.org>2015-08-08 13:49:04 -0700
committerRobin H. Johnson <robbat2@gentoo.org>2015-08-08 17:38:18 -0700
commit56bd759df1d0c750a065b8c845e93d5dfa6b549d (patch)
tree3f91093cdb475e565ae857f1c5a7fd339e2d781e /media-libs/svgalib/svgalib-1.9.25-r4.ebuild
downloadgentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.tar.gz
gentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.tar.bz2
gentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.zip
proj/gentoo: Initial commit
This commit represents a new era for Gentoo: Storing the gentoo-x86 tree in Git, as converted from CVS. This commit is the start of the NEW history. Any historical data is intended to be grafted onto this point. Creation process: 1. Take final CVS checkout snapshot 2. Remove ALL ChangeLog* files 3. Transform all Manifests to thin 4. Remove empty Manifests 5. Convert all stale $Header$/$Id$ CVS keywords to non-expanded Git $Id$ 5.1. Do not touch files with -kb/-ko keyword flags. Signed-off-by: Robin H. Johnson <robbat2@gentoo.org> X-Thanks: Alec Warner <antarus@gentoo.org> - did the GSoC 2006 migration tests X-Thanks: Robin H. Johnson <robbat2@gentoo.org> - infra guy, herding this project X-Thanks: Nguyen Thai Ngoc Duy <pclouds@gentoo.org> - Former Gentoo developer, wrote Git features for the migration X-Thanks: Brian Harring <ferringb@gentoo.org> - wrote much python to improve cvs2svn X-Thanks: Rich Freeman <rich0@gentoo.org> - validation scripts X-Thanks: Patrick Lauer <patrick@gentoo.org> - Gentoo dev, running new 2014 work in migration X-Thanks: Michał Górny <mgorny@gentoo.org> - scripts, QA, nagging X-Thanks: All of other Gentoo developers - many ideas and lots of paint on the bikeshed
Diffstat (limited to 'media-libs/svgalib/svgalib-1.9.25-r4.ebuild')
-rw-r--r--media-libs/svgalib/svgalib-1.9.25-r4.ebuild129
1 files changed, 129 insertions, 0 deletions
diff --git a/media-libs/svgalib/svgalib-1.9.25-r4.ebuild b/media-libs/svgalib/svgalib-1.9.25-r4.ebuild
new file mode 100644
index 000000000000..2f7f0b82733f
--- /dev/null
+++ b/media-libs/svgalib/svgalib-1.9.25-r4.ebuild
@@ -0,0 +1,129 @@
+# Copyright 1999-2012 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI="4"
+
+inherit eutils flag-o-matic toolchain-funcs linux-mod
+
+DESCRIPTION="A library for running svga graphics on the console"
+HOMEPAGE="http://www.svgalib.org/"
+SRC_URI="http://www.arava.co.il/matan/${PN}/${P}.tar.gz"
+
+LICENSE="BSD"
+SLOT="0"
+KEYWORDS="-* x86"
+IUSE="build +kernel-helper"
+
+DEPEND=""
+RDEPEND=""
+
+MODULE_NAMES="svgalib_helper(misc:${S}/kernel/svgalib_helper)"
+BUILD_TARGETS="default"
+
+pkg_setup() {
+ linux-mod_pkg_setup
+ BUILD_PARAMS="KDIR=${KV_OUT_DIR}"
+}
+
+src_prepare() {
+ epatch "${FILESDIR}"/${PN}-1.9.25-linux2.6.patch
+ epatch "${FILESDIR}"/${PN}-1.9.19-pic.patch #51698
+ epatch "${FILESDIR}"/${PN}-1.9.25-build.patch
+ epatch "${FILESDIR}"/${PN}-1.9.25-linux2.6.28.patch
+ epatch "${FILESDIR}"/${PN}-1.9.25-glibc210.patch #274305
+ epatch "${FILESDIR}"/${PN}-1.9.25-linux2.6.36-r1.patch
+ epatch "${FILESDIR}"/${PN}-1.9.25-segfault.patch
+ epatch "${FILESDIR}"/${PN}-1.9.25-build2.patch
+ epatch "${FILESDIR}"/${PN}-1.9.25-qa.patch
+ epatch "${FILESDIR}"/${PN}-1.9.25-kernel3.4.patch
+ sed -i -e '/linux\/smp_lock.h/d' kernel/svgalib_helper/main.c || die
+}
+
+src_compile() {
+ use kernel-helper || export NO_HELPER=y
+
+ export CC=$(tc-getCC)
+
+ # First build static
+ emake OPTIMIZE="${CFLAGS}" static || die "Failed to build static libraries!"
+ # Then build shared ...
+ emake OPTIMIZE="${CFLAGS}" shared || die "Failed to build shared libraries!"
+ # Missing in some cases ...
+ ln -s libvga.so.${PV} sharedlib/libvga.so
+ # Build lrmi and tools ...
+ emake OPTIMIZE="${CFLAGS}" LDFLAGS+=" -L../sharedlib" \
+ textutils lrmi utils \
+ || die "Failed to build libraries and utils!"
+ # Build the gl stuff tpp
+ emake OPTIMIZE="${CFLAGS}" -C gl || die "Failed to build gl!"
+ emake OPTIMIZE="${CFLAGS}" -C gl libvgagl.so.${PV} \
+ || die "Failed to build libvgagl.so.${PV}!"
+ # Missing in some cases ...
+ ln -s libvgagl.so.${PV} sharedlib/libvgagl.so
+ emake OPTIMIZE="${CFLAGS}" -C src libvga.so.${PV} \
+ || die "Failed to build libvga.so.${PV}!"
+ cp -pPR src/libvga.so.${PV} sharedlib/
+ # Build threeDKit ...
+ emake OPTIMIZE="${CFLAGS}" LDFLAGS+=" -L../sharedlib" \
+ -C threeDKit lib3dkit.a || die "Failed to build threeDKit!"
+ # Build demo's ...
+ emake OPTIMIZE="${CFLAGS} -I../gl" LDFLAGS+=" -L../sharedlib" \
+ demoprogs || die "Failed to build demoprogs!"
+
+ ! use build && use kernel-helper && linux-mod_src_compile
+}
+
+src_install() {
+ local x=
+
+ dodir /etc/svgalib /usr/{include,lib,bin,share/man}
+
+ emake \
+ TOPDIR="${D}" OPTIMIZE="${CFLAGS}" INSTALLMODULE="" \
+ install || die "Failed to install svgalib!"
+ ! use build && use kernel-helper && linux-mod_src_install
+
+ insinto /usr/include
+ doins gl/vgagl.h
+ dolib.a staticlib/libvga.a || die "dolib.a libvga"
+ dolib.a gl/libvgagl.a || die "dolib.a libvgagl"
+ dolib.a threeDKit/lib3dkit.a
+ dolib.so gl/libvgagl.so.${PV} || die "dolib.so libvgagl.so"
+ local abiver=$(sed -n '/^MAJOR_VER.*=/{s:.*=[ ]*::;p}' Makefile.cfg)
+ for x in lib3dkit libvga libvgagl ; do
+ dosym ${x}.so.${PV} /usr/lib/${x}.so
+ dosym ${x}.so.${PV} /usr/lib/${x}.so.${abiver}
+ done
+
+ insinto /usr/include
+ doins src/vga.h gl/vgagl.h src/mouse/vgamouse.h src/joystick/vgajoystick.h
+ doins src/keyboard/vgakeyboard.h kernel/svgalib_helper/svgalib_helper.h
+
+ insinto /lib/udev/rules.d
+ newins "${FILESDIR}"/svgalib.udev.rules.d.2 30-svgalib.rules
+
+ exeinto /usr/lib/svgalib/demos
+ for x in "${S}"/demos/* ; do
+ [[ -x ${x} ]] && doexe ${x}
+ done
+
+ cd "${S}"/threeDKit
+ exeinto /usr/lib/svgalib/threeDKit
+ local THREED_PROGS="plane wrapdemo"
+ doexe ${THREED_PROGS}
+
+ cd "${S}"
+ dodoc 0-README
+ cd "${S}"/doc
+ dodoc CHANGES DESIGN TODO
+ docinto txt
+ dodoc Driver-programming-HOWTO add_driver svgalib.lsm \
+ README.{joystick,keymap,multi-monitor,patching,vesa}
+ # avoid installation of a broken symlink
+ newdoc ../lrmi-0.6m/README README.lrmi
+}
+
+pkg_postinst() {
+ ! use build && use kernel-helper && linux-mod_pkg_postinst
+}