[proaudio] Re: [proaudio] Re: [proaudio] Re: [proaudio] howto write/contribute ebuilds publishedonhttp://proaudio.tuxfamily.org/

[ Thread Index | Date Index | More lists.tuxfamily.org/proaudio Archives ]


kjetil@xxxxxxxxxxxxxxxxxx wrote:


On Sun, 30 Jul 2006, kjetil@xxxxxxxxxxxxxxxxxx wrote:



On Sat, 29 Jul 2006, Frieder Bürzele wrote:

 Hi,

 I wrote a Howto about writing and contributing ebuilds.
 http://proaudio.tuxfamily.org/wiki/index.php?title=Contribute_ebuilds


Great! Attached is an ebuild for Ceres. I had major trouble, but I think
it works now. Hope you'll include it into the proaudio overlay.


Here's one for Mammut as well. I think it works.

------------------------------------------------------------------------

# Copyright 1999-2006 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: $

DESCRIPTION="A program sound effects using one gigantic fft analysis (no windows)."
HOMEPAGE="http://ccrma.stanford.edu/~kjetil/src";
#SRC_URI="http://ccrma.stanford.edu/~kjetil/src/${P}.tar.gz";
SRC_URI="http://171.64.197.141/~kjetil/src/${P}.tar.bz2";

missing
KEYWORDS="x86"
SLOT="0"
IUSE=""

DEPEND=">=media-sound/jack-audio-connection-kit-0.100 >=dev-lang/python-1.5 media-libs/libsndfile =x11-libs/gtk+-1.2* >=dev-libs/libxml-1.8.17 >=media-libs/libsamplerate-0.1.2 >=media-sound/ceres-0.45"

use this

src_unpack(){
   unpack "${A}"
   cd "${S}"
   cd src/packages
   tar xzf sndlib.tar.gz
}

instead

src_compile() {
-----------------begin---------------------------
    cd src
    cd packages
    tar xvzf sndlib.tar.gz
----------------------end----------------------
    cd src/packages/sndlib
    ./configure --with-jack --without-guile
use
         econf  --with-jack --without-guile || die "econf failed"
gcc -I. -O2 headers.c audio.c io.c sound.c xen.c vct.c clm.c sndlib2xen.c clm2xen.c midi.c -c ar rus sndlib.a headers.o audio.o io.o sound.o xen.o vct.o clm.o sndlib2xen.o clm2xen.o midi.o
use
$(tc-getCC) -I. -O2 headers.c audio.c io.c sound.c xen.c vct.c clm.c sndlib2xen.c clm2xen.c midi.c -c ar rus sndlib.a headers.o audio.o io.o sound.o xen.o vct.o clm.o sndlib2xen.o clm2xen.o midi.o

and add: inherit toolchain-funcs
right after the line # $Header: $

(--> tc-getCC is a function which gives you the right current compiler --> this function is from toolchain-funcs.eclass which normally can be found in /usr/portage/eclass)


    cd ../..
    sed -ie 's/-shared/-shared  -ljack -lsamplerate/' Makefile
this sed should be in src_unpack() otherwise comment why it has to be here
    make INSTALLPATH=/usr PYGTK1PATH=/usr/share/ceres || die "make failed"
}

src_install() {
    cd doc
    dodoc mammuthelp.html
    cd ../src
make INSTALLPATH=${D}/usr X11PATH=${D}/usr/X11R6 PYGTK1PATH=/usr/share/ceres install }


I attached the ebuild modified to what I like it to be

please test if it works

Greetz

   Frieder


# Copyright 1999-2006 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: $

inherit toolchain-funcs

RESTRICT="nomirror"  # this is because our packages are not on the gentoo mirrors
DESCRIPTION="A program sound effects using one gigantic fft analysis (no 
windows)."
HOMEPAGE="http://ccrma.stanford.edu/~kjetil/src";
#SRC_URI="http://ccrma.stanford.edu/~kjetil/src/${P}.tar.gz";
SRC_URI="http://171.64.197.141/~kjetil/src/${P}.tar.bz2";

KEYWORDS="x86"
SLOT="0"
IUSE=""

DEPEND=">=media-sound/jack-audio-connection-kit-0.100
	>=dev-lang/python-1.5
	media-libs/libsndfile
	=x11-libs/gtk+-1.2*
	>=dev-libs/libxml-1.8.17
	>=media-libs/libsamplerate-0.1.2
	>=media-sound/ceres-0.45"

src_unpack(){
	unpack "${A}"
	cd "${S}"
	cd src/packages
	tar xzf sndlib.tar.gz
	sed -ie 's/-shared/-shared  -ljack -lsamplerate/' "${S}"/src/Makefile || die "sed failed"
}

src_compile() {
	
	cd src/packages/sndlib

	econf configure --with-jack --without-guile || die "config failed"
	
	$(tc-getCC) -I. -O2 headers.c audio.c io.c sound.c xen.c vct.c clm.c sndlib2xen.c clm2xen.c midi.c -c ar rus sndlib.a headers.o audio.o io.o sound.o xen.o vct.o clm.o sndlib2xen.o clm2xen.o midi.o
	
	cd ../..
	# sed moved to src_unpack don't know if this works
	make INSTALLPATH=/usr PYGTK1PATH=/usr/share/ceres || die "make failed"
}

src_install() {
	cd doc
	dodoc mammuthelp.html
	cd ../src
	make INSTALLPATH=${D}/usr X11PATH=${D}/usr/X11R6 PYGTK1PATH=/usr/share/ceres	install || die "install failed" 
}


Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/