public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-commits] gentoo-x86 commit in media-libs/libsfml: ChangeLog metadata.xml libsfml-1.6.ebuild
@ 2011-02-05  5:38 Tim Harder (radhermit)
  0 siblings, 0 replies; only message in thread
From: Tim Harder (radhermit) @ 2011-02-05  5:38 UTC (permalink / raw
  To: gentoo-commits

radhermit    11/02/05 05:38:21

  Added:                ChangeLog metadata.xml libsfml-1.6.ebuild
  Log:
  Initial import for bug #258895. Ebuild by me.
  
  (Portage version: 2.2.0_alpha19/cvs/Linux x86_64)

Revision  Changes    Path
1.1                  media-libs/libsfml/ChangeLog

file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/media-libs/libsfml/ChangeLog?rev=1.1&view=markup
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/media-libs/libsfml/ChangeLog?rev=1.1&content-type=text/plain

Index: ChangeLog
===================================================================
# ChangeLog for media-libs/libsfml
# Copyright 1999-2011 Gentoo Foundation; Distributed under the GPL v2
# $Header: /var/cvsroot/gentoo-x86/media-libs/libsfml/ChangeLog,v 1.1 2011/02/05 05:38:21 radhermit Exp $

*libsfml-1.6 (05 Feb 2011)

  05 Feb 2011; Tim Harder <radhermit@gentoo.org> +libsfml-1.6.ebuild,
  +files/libsfml-1.6-csfml-destdir.patch,
  +files/libsfml-1.6-deps-and-flags.patch, +files/libsfml-1.6-destdir.patch,
  +metadata.xml:
  Initial import for bug #258895. Ebuild by me.




1.1                  media-libs/libsfml/metadata.xml

file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/media-libs/libsfml/metadata.xml?rev=1.1&view=markup
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/media-libs/libsfml/metadata.xml?rev=1.1&content-type=text/plain

Index: metadata.xml
===================================================================
<?xml version = '1.0' encoding = 'UTF-8'?>
<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
<pkgmetadata>
	<herd>games</herd>
	<maintainer>
		<email>radhermit@gentoo.org</email>
		<name>Tim Harder</name>
	</maintainer>
	<longdescription lang="en">
	The Simple and Fast Multimedia Library (SFML) is a portable and easy to use
	multimedia API written in C++. You can see it as a modern, object-oriented
	alternative to SDL. SFML is composed of several packages to suit your needs.
	You can use SFML as a minimal windowing system to interface with OpenGL, or
	as a fully-featured multimedia library for building games or interactive
	programs.
	</longdescription>
	<use>
		<flag name="csfml">Build the C libraries for SFML</flag>
	</use>
</pkgmetadata>



1.1                  media-libs/libsfml/libsfml-1.6.ebuild

file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/media-libs/libsfml/libsfml-1.6.ebuild?rev=1.1&view=markup
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/media-libs/libsfml/libsfml-1.6.ebuild?rev=1.1&content-type=text/plain

Index: libsfml-1.6.ebuild
===================================================================
# Copyright 1999-2011 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/media-libs/libsfml/libsfml-1.6.ebuild,v 1.1 2011/02/05 05:38:21 radhermit Exp $

EAPI=3
PYTHON_DEPEND="python? 2:2.6 3"
PYTHON_MODNAME="PySFML"

inherit eutils multilib toolchain-funcs distutils

MY_P="SFML-${PV}"
DESCRIPTION="Simple and fast multimedia library"
HOMEPAGE="http://sfml.sourceforge.net/"
SRC_URI="mirror://sourceforge/sfml/${MY_P}-sdk-linux-32.tar.gz
	csfml? ( mirror://sourceforge/sfml/${MY_P}-c-sdk-linux-32.tar.gz )
	python? ( mirror://sourceforge/sfml/${MY_P}-python-sdk.zip )"

LICENSE="as-is"
SLOT="0"
KEYWORDS="~amd64 ~x86"
IUSE="csfml debug doc examples python static-libs"

DEPEND="media-libs/freetype:2
	media-libs/glew
	media-libs/libpng
	media-libs/libsndfile
	media-libs/mesa
	media-libs/openal
	sys-libs/zlib
	virtual/jpeg
	x11-libs/libX11
	x11-libs/libXrandr"
RDEPEND="${DEPEND}"

S="${WORKDIR}/${MY_P}"

src_prepare() {
	epatch "${FILESDIR}"/${P}-destdir.patch
	epatch "${FILESDIR}"/${P}-deps-and-flags.patch
	if use csfml ; then
		epatch "${FILESDIR}"/${P}-csfml-destdir.patch
	fi
}

src_compile() {
	local myconf

	if use debug ; then
		myconf="$myconf DEBUGBUILD=yes"
	fi

	emake $myconf CPP=$(tc-getCXX) CC=$(tc-getCC) || die "emake failed"

	if use static-libs ; then
		emake $myconf STATIC=yes CPP=$(tc-getCXX) CC=$(tc-getCC) || die "emake failed"
	fi

	if use csfml ; then
		cd "${S}/CSFML"
		emake CPP=$(tc-getCXX) || die "emake failed"
	fi

	if use python ; then
		cd "${S}/python"
		distutils_src_compile
	fi
}

src_install() {
	emake DESTDIR="${D}" prefix=/usr libdir=/usr/$(get_libdir) install || die "emake install failed"

	if use csfml ; then
		pushd "${S}/CSFML" >/dev/null
		emake DESTDIR="${D}" prefix=/usr libdir=/usr/$(get_libdir) install || die "emake install failed"
		popd >/dev/null
	fi

	if use python ; then
		pushd "${S}/python" >/dev/null
		distutils_src_install
		popd >/dev/null
	fi

	if use static-libs ; then
		dolib.a lib/*.a || die "dolib.a failed"
	fi

	if use doc ; then
		dohtml doc/html/*
		if use csfml ; then
			docinto csfml/html
			dohtml CSFML/doc/html/*
		fi
		if use python ; then
			docinto python/html
			dohtml python/doc/*
		fi
	fi

	if use examples ; then
		for i in ftp opengl pong post-fx qt sockets sound sound_capture voip window wxwidgets X11 ; do
			insinto /usr/share/doc/${PF}/examples/$i
			doins samples/$i/* || die "doins failed"
		done

		if use python ; then
			insinto /usr/share/doc/${PF}/python/examples
			doins -r python/samples/* || die "doins failed"
		fi
	fi
}

pkg_postinst() {
	use python && distutils_pkg_postinst
}

pkg_postrm() {
	use python && distutils_pkg_postrm
}






^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2011-02-05  5:38 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-02-05  5:38 [gentoo-commits] gentoo-x86 commit in media-libs/libsfml: ChangeLog metadata.xml libsfml-1.6.ebuild Tim Harder (radhermit)

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox