# Copyright 1999-2006 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 inherit eutils MY_P=${P/_beta5/beta5.1} DESCRIPTION="multi-track hard disk recording software" HOMEPAGE="http://ardour.org/" SRC_URI="http://ardour.org/files/releases/${MY_P}.tar.bz2" RESTRICT="nomirror" LICENSE="GPL-2" SLOT="0" KEYWORDS="~x86 ~amd64 ~ppc" IUSE="altivec coreaudio debug nls osc sse vst" RDEPEND="osc? ( media-libs/liblo ) >=media-libs/liblrdf-0.3.6 >=media-libs/raptor-1.2.0 >=media-sound/jack-audio-connection-kit-0.100.0 >=dev-libs/glib-2.10.3 >=x11-libs/gtk+-2.8.8 >=media-libs/libsamplerate-0.1.1-r1 >=dev-libs/libxml2-2.5.7 >=media-libs/libart_lgpl-2.3.16 >=media-libs/libsndfile-1.0.16 dev-libs/boost gnome-base/libgnomecanvas" DEPEND="${RDEPEND} sys-devel/libtool dev-util/pkgconfig >=dev-util/scons-0.96.1 nls? ( sys-devel/gettext )" S="${WORKDIR}/${MY_P}" src_compile() { # replacing INSTALL_PREFIX with PREFIX in the ardour2 shell script sed -i ${S}/gtk2_ardour/SConscript -e '/my_subst_dict.*INSTALL_PREFIX/s/install_prefix/final_prefix/' || die "error fixing ardour2 shell script (sed: gtk2_ardour/SConscript)" # Required for scons to "see" intermediate install location mkdir -p "${D}" local FPU_OPTIMIZATION=$((use altivec || use sse) && echo 1 || echo 0) local ARDOUR_DEBUG=$(use debug && echo 1 || echo 0) local NLS=$(use nls && echo 1 || echo 0) local COREAUDIO=$(use coreaudio && echo 1 || echo 0) local OSC=$(use osc && echo 1 || echo 0) local VST=$(use vst && echo 1 || echo 0) cd ${S} scons \ DEBUG=${ARDOUR_DEBUG} \ FPU_OPTIMIZATION=${FPU_OPTIMIZATION} \ DESTDIR="${D}" \ NLS=${NLS} \ COREAUDIO=${COREAUDIO} \ LIBLO=${OSC} \ VST=${VST} \ PREFIX=/usr || die "scons make failed" } src_install() { scons install || die "make install failed" dodoc DOCUMENTATION/* } pkg_postinst() { if use sse then einfo "" einfo "Start ardour with the -o argument to use the optimized SSE functions:" einfo "" einfo " ardour -o" einfo "" fi ewarn "---------------- WARNING -------------------" ewarn "" ewarn "Do not use Ardour 2.0 to open the only copy of sessions created with Ardour 0.99." ewarn "Ardour 2.0 saves the session file in a new format that Ardour 0.99 will" ewarn "not understand." ewarn "" ewarn "MAKE BACKUPS OF THE SESSION FILES." ewarn "" ewarn "The simplest way to address this is to make a copy of the session file itself" ewarn "(e.g mysession/mysession.ardour) and make that file unreadable using chmod(1)." ewarn "" ewarn "---------------- WARNING -------------------" ewarn "Note that this is beta software, thus it might crash when you don't expect it." ewarn "Please test the new beta, and report issues to the ardour-dev mailing list and the" ewarn "#ardour IRC channel. Mantis (the issue tracker) can be used, but the ardour project" ewarn "prefer at this time to keep it free of things that are trivial to fix." }