Hi!
Ich hab hier noch was für das noad ebuild. Anscheinend kann noad auch mit Imagemagick was anfangen (--with-magick), weshalb eine weitere USE Variable angebracht wäre.
Code
IUSE="ffmpeg imagemagick"
...
DEPEND="media-libs/libmpeg2
ffmpeg? (>=media-video/ffmpeg-0.4.8)
imagemagick? (>=media-gfx/imagemagick-6.2.4.2-r1)
"
...
if use imagemagick; then
myconf="${myconf} --with-magick"
else
myconf="${myconf} --without-magick"
fi
...
src_install() {
exeinto /usr/bin
doexe noad
if use imagemagick; then
doexe markpics
fi
Alles anzeigen
Damit erhält man also das Programm markpics.
Außerdem gibt es noch den Parameter --with-tools:
Code
IUSE="ffmpeg imagemagick noadtools"
...
if use noadtools; then
myconf="${myconf} --with-tools"
else
myconf="${myconf} --without-tools"
fi
...
if use noadtools; then
doexe showindex
fi
Alles anzeigen
Vor dem ./configure sollte man noch configure patchen, damit es die CXXFLAGS in /etc/make.conf übernimmt, und nicht einfach "-O3 -g":
sollte ersetzt werden durch
auch wenn noad auch so unter /usr/bin installiert wird, dann sieht das ganze beim Kompillieren bzgl. der ffmpeg includes schöner aus.
Insgesamt könnte das dann alles so aussehen:
Code
RESTRICT="nomirror"
S=${WORKDIR}/${P}
DESCRIPTION="removes advertisings from vdr recordings"
HOMEPAGE="http://http://www.rgob.com/members/theNoad/"
SRC_URI="http://www.freepgs.com/noad/noad-${PV}.tar.bz2"
KEYWORDS="x86"
SLOT="0"
LICENSE="GPL-2"
IUSE="ffmpeg imagemagick noadtools"
DEPEND="media-libs/libmpeg2
ffmpeg? (>=media-video/ffmpeg-0.4.8)
imagemagick? (>=media-gfx/imagemagick-6.2.4.2-r1)
"
src_unpack() {
unpack ${A}
cd ${S}
}
src_compile() {
local myconf
if use ffmpeg; then
myconf="${myconf} --with-ffmpeg --with-ffmpeginclude=/usr/include/ffmpeg"
else
myconf="${myconf} --without-ffmpeg"
fi
if use imagemagick; then
myconf="${myconf} --with-magick"
else
myconf="${myconf} --without-magick"
fi
if use noadtools; then
myconf="${myconf} --with-tools"
else
myconf="${myconf} --without-tools"
fi
# echo "${myconf}" > ${T}/configure-options
sed -i -e "s:-g -O3:$CXXFLAGS:" configure
./configure --prefix=/usr --with-mpeginclude=/usr/include/mpeg2dec ${myconf}
make || die "noad compile problem"
}
src_install() {
exeinto /usr/bin
doexe noad
if use imagemagick; then
doexe markpics
fi
if use noadtools; then
doexe showindex
fi
dodoc COPYING README INSTALL
# example scripts are installed as dokumentation
dodoc allnewnoad allnoad allnoadnice clearlogos noadifnew stat2html
}
pkg_postinst() {
einfo
einfo "Congratulations, you have just installed noad!"
einfo
}
Alles anzeigen
Cheers
mic