# Copyright 1999-2003 Gentoo Technologies, Inc. # Distributed under the terms of the GNU General Public License v2 # $Header: $ DESCRIPTION="gtk2 and ncurses-based console frontend to cdrecord and mkisofs" HOMEPAGE="http://cdw.sourceforge.net" SRC_URI="mirror://sourceforge/cdw/${PN}-${PV/_/-}.tar.gz" KEYWORDS="~x86" LICENSE="GPL-2" SLOT="0" IUSE="nls gtk2 oggvorbis mysql encode" MY_P=${PN}-${PV/_/-} S=${WORKDIR}/${MY_P} RDEPEND="virtual/cdrtools" DEPEND="sys-libs/ncurses nls? ( sys-devel/gettext ) gtk2? ( >=x11-libs/gtk+-2 >=dev-libs/glib-2 dev-util/pkgconfig ) oggvorbis? ( media-sound/vorbis-tools ) mysql? ( dev-db/mysql ) encode? ( media-sound/lame )" src_compile() { local myconf use oggvorbis \ && myconf="${myconf} --with-oggenc=/usr/bin/oggenc" \ || myconf="${myconf} `use_with oggvorbis oggenc`" use encode \ && myconf="${myconf} --with-lame=/usr/bin/lame" \ || myconf="${myconf} `use_with encode lame`" econf \ ${myconf} \ `use_enable nls` \ `use_enable gtk2 gui` || die "configure failed" emake -j1 || die "emake failed" } src_install() { einstall || die "einstall failed" dodoc AUTHORS ChangeLog NEWS THANKS \ doc/{KNOWN_BUGS,README*,default.conf} || die "dodoc failed" if has_version 'dev-db/mysql'; then insinto /usr/share/${PN}/ doins doc/cdw.sql fi } pkg_postinst() { einfo "If you have been using ${PN} before, it will please to " einfo "you know that now have gtk2 and mysql (Disk Catalog)" einfo "support!. In order to activate this features you must" einfo "selec 'USE=mysql' or 'USE=gtk2' or both in your make.conf" if has_version 'dev-db/mysql'; then einfo "" einfo "You have chosen by selecting 'USE=mysql' or maybe because" einfo "you have installed before 'dev-db/mysql' to install the Disk" einfo "Catalog support. You will have a new tool called cdwdic." einfo "The directory /usr/share/${PN}/ contains a cdw.sql file." einfo "You must install this to your system for using the" einfo "the Disk Catalog. The installation process is very simple," einfo "you can find the instructions in the gzipped file:" einfo "$ zcat /usr/share/doc/${PF}/README.gz" fi }