summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatthias Schwarzott <zzam@gentoo.org>2008-05-15 08:49:16 +0000
committerMatthias Schwarzott <zzam@gentoo.org>2008-05-15 08:49:16 +0000
commit000d7f975e8ee582b425c9e76b83be10c2949d00 (patch)
tree7e65f6e0cddf9d20f297ce23f0295ee8545782ed /media-video/projectx
parentStable on ppc64; bug #221063 (diff)
downloadgentoo-2-000d7f975e8ee582b425c9e76b83be10c2949d00.tar.gz
gentoo-2-000d7f975e8ee582b425c9e76b83be10c2949d00.tar.bz2
gentoo-2-000d7f975e8ee582b425c9e76b83be10c2949d00.zip
Add a patch to clean up the stdout of the non-gui version. This makes the output parsable by other software, especially by vdr-burn, solving some strange bugs there.
(Portage version: 2.1.5_rc10)
Diffstat (limited to 'media-video/projectx')
-rw-r--r--media-video/projectx/ChangeLog11
-rw-r--r--media-video/projectx/files/projectx-0.90.4.00-stdout-corrupt.diff12
-rw-r--r--media-video/projectx/projectx-0.90.4.00-r4.ebuild122
3 files changed, 144 insertions, 1 deletions
diff --git a/media-video/projectx/ChangeLog b/media-video/projectx/ChangeLog
index ef91a571ecec..f7d6f3c34288 100644
--- a/media-video/projectx/ChangeLog
+++ b/media-video/projectx/ChangeLog
@@ -1,6 +1,15 @@
# ChangeLog for media-video/projectx
# Copyright 1999-2008 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/media-video/projectx/ChangeLog,v 1.29 2008/04/03 14:50:02 ranger Exp $
+# $Header: /var/cvsroot/gentoo-x86/media-video/projectx/ChangeLog,v 1.30 2008/05/15 08:49:16 zzam Exp $
+
+*projectx-0.90.4.00-r4 (15 May 2008)
+
+ 15 May 2008; Matthias Schwarzott <zzam@gentoo.org>
+ +files/projectx-0.90.4.00-stdout-corrupt.diff,
+ +projectx-0.90.4.00-r4.ebuild:
+ Add a patch to clean up the stdout of the non-gui version. This makes the
+ output parsable by other software, especially by vdr-burn, solving some
+ strange bugs there.
03 Apr 2008; Brent Baude <ranger@gentoo.org> projectx-0.90.4.00-r3.ebuild:
stable ppc, bug 208138
diff --git a/media-video/projectx/files/projectx-0.90.4.00-stdout-corrupt.diff b/media-video/projectx/files/projectx-0.90.4.00-stdout-corrupt.diff
new file mode 100644
index 000000000000..a4a3d105fa9e
--- /dev/null
+++ b/media-video/projectx/files/projectx-0.90.4.00-stdout-corrupt.diff
@@ -0,0 +1,12 @@
+diff -ru ProjectX_Source_0.90.4-orig/src/net/sourceforge/dvb/projectx/common/GuiInterface.java ProjectX_Source_0.90.4/src/net/sourceforge/dvb/projectx/common/GuiInterface.java
+--- ProjectX_Source_0.90.4-orig/src/net/sourceforge/dvb/projectx/common/GuiInterface.java 2008-05-14 18:48:05.833127359 +0200
++++ ProjectX_Source_0.90.4/src/net/sourceforge/dvb/projectx/common/GuiInterface.java 2008-05-14 18:48:39.773120746 +0200
+@@ -188,7 +188,7 @@
+ impl.updateProgressBar(percent);
+
+ else
+- System.out.print("\r" + percent + " %");
++ System.out.print(percent + " %\r");
+ }
+
+ /**
diff --git a/media-video/projectx/projectx-0.90.4.00-r4.ebuild b/media-video/projectx/projectx-0.90.4.00-r4.ebuild
new file mode 100644
index 000000000000..d287d4029422
--- /dev/null
+++ b/media-video/projectx/projectx-0.90.4.00-r4.ebuild
@@ -0,0 +1,122 @@
+# Copyright 1999-2008 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/media-video/projectx/projectx-0.90.4.00-r4.ebuild,v 1.1 2008/05/15 08:49:16 zzam Exp $
+
+inherit eutils toolchain-funcs java-pkg-2 java-ant-2
+
+MY_PN="ProjectX"
+
+# micro-release == 0 ?
+if [ 0${PV##*.} -eq 0 ]; then
+ MY_P="${MY_PN}_Source_${PV%.*}"
+else
+ MY_P="${MY_PN}_Source_${PV}"
+fi
+
+DESCRIPTION="Converts, splits and demuxes DVB and other MPEG recordings"
+HOMEPAGE="http://project-x.sourceforge.net/"
+SRC_URI="mirror://sourceforge/project-x/${MY_PN}_Source_eng_${PV}.zip
+ mirror://sourceforge/project-x/${MY_PN}_LanguagePack_${PV}.zip
+ http://sbriesen.de/gentoo/distfiles/${PN}-patches-${PVR}.tbz2
+ http://sbriesen.de/gentoo/distfiles/${MY_P}-portable.zip"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~ppc ~ppc64 ~x86"
+IUSE="X doc source mmx"
+
+COMMON_DEP="dev-java/commons-net
+ X? ( =dev-java/browserlauncher2-1* )"
+
+RDEPEND=">=virtual/jre-1.4
+ ${COMMON_DEP}"
+
+DEPEND=">=virtual/jdk-1.4
+ ${COMMON_DEP}
+ app-arch/unzip
+ dev-java/ant-core
+ source? ( app-arch/zip )"
+
+S="${WORKDIR}/${MY_P}"
+
+mainclass() {
+ # read Main-Class from MANIFEST.MF
+ sed -n "s/^Main-Class: \([^ ]\+\).*/\1/p" "${S}/MANIFEST.MF"
+}
+
+src_unpack() {
+ unpack ${A}
+ cd "${S}"
+
+ # copy build.xml
+ cp -f "${FILESDIR}/build-${PV%.*}.xml" build.xml
+
+ # patch location of executable
+ sed -i -e "s:^\(Exec=\).*:\1${PN}:g" *.desktop
+
+ # convert CRLF to LF
+ edos2unix *.txt MANIFEST.MF
+
+ # apply subtitle clut patch
+ epatch "${WORKDIR}/${PN}-${PV%.*}-clut.diff"
+
+ # apply subtitle charset patch
+ epatch "${WORKDIR}/${PN}-${PV%.*}-charset.diff"
+
+ # apply BrowserLauncher2 patch
+ use X && epatch "${WORKDIR}/${PN}-${PV%.*}-bl2.diff"
+ rm -rf src/edu
+
+ epatch "${FILESDIR}/${P}-stdout-corrupt.diff"
+
+ # cleanup idctfast patchset
+ rm -f lib/PORTABLE/*.{o,so}
+ rm -f src/net/sourceforge/dvb/projectx/video/IDCT{Ref,Sse}Native.java
+ sed -i -e "s:gcc:\$(CC):g" -e "s: -O2::g" lib/PORTABLE/Makefile
+
+ # merge/remove resources depending on USE="X"
+ if use X; then
+ mv -f htmls resources/
+ else
+ rm -rf src/net/sourceforge/dvb/projectx/gui
+ rm resources/*.gif
+ fi
+
+ # update library packages
+ cd lib
+ rm -f {commons-net,jakarta-oro}*.jar
+ java-pkg_jar-from commons-net
+ use X && java-pkg_jar-from browserlauncher2-1.0
+ java-pkg_ensure-no-bundled-jars
+}
+
+src_compile() {
+ local IDCT="idct-mjpeg" # default IDCT implementation
+ use x86 && use mmx && IDCT="idct-mjpeg-mmx"
+
+ eant build $(use_doc) -Dmanifest.mainclass=$(mainclass)
+
+ cd lib/PORTABLE
+ emake CC=$(tc-getCC) IDCT="${IDCT}" LDFLAGS="${LDFLAGS}" \
+ CPLAT="${CFLAGS} -ffast-math -fPIC" || die "emake failed"
+}
+
+src_install() {
+ java-pkg_dojar dist/${PN}.jar
+ java-pkg_doso lib/PORTABLE/libidctfast.so
+
+ java-pkg_dolauncher ${PN}_nogui --main $(mainclass) \
+ --java_args "-Djava.awt.headless=true"
+
+ if use X; then
+ java-pkg_dolauncher ${PN}_gui --main $(mainclass)
+ dosym ${PN}_gui /usr/bin/${PN}
+ domenu *.desktop
+ else
+ dosym ${PN}_nogui /usr/bin/${PN}
+ fi
+
+ dodoc *.txt
+ use doc && java-pkg_dojavadoc apidocs
+ use source && java-pkg_dosrc src
+}