diff options
author | Michael Weber <xmw@gentoo.org> | 2011-10-04 22:46:00 +0000 |
---|---|---|
committer | Michael Weber <xmw@gentoo.org> | 2011-10-04 22:46:00 +0000 |
commit | eb82a98a31d0b87d8040d78cfd68d29f9920906d (patch) | |
tree | a7e0940dd064528c9a5302ecaaf5072b2b6f5628 /app-text/llpp | |
parent | Marked ppc stable for bug #375923. (diff) | |
download | gentoo-2-eb82a98a31d0b87d8040d78cfd68d29f9920906d.tar.gz gentoo-2-eb82a98a31d0b87d8040d78cfd68d29f9920906d.tar.bz2 gentoo-2-eb82a98a31d0b87d8040d78cfd68d29f9920906d.zip |
Version bump to v7 git tag, WM_CLASS patch, fixme ocaml[-ocamlopt]
(Portage version: 2.1.10.11/cvs/Linux x86_64)
Diffstat (limited to 'app-text/llpp')
-rw-r--r-- | app-text/llpp/ChangeLog | 8 | ||||
-rw-r--r-- | app-text/llpp/files/llpp-WM_CLASS.patch | 42 | ||||
-rw-r--r-- | app-text/llpp/llpp-7.ebuild | 62 | ||||
-rw-r--r-- | app-text/llpp/llpp-9999.ebuild | 45 |
4 files changed, 142 insertions, 15 deletions
diff --git a/app-text/llpp/ChangeLog b/app-text/llpp/ChangeLog index a68b0957ddc3..07b45a674acd 100644 --- a/app-text/llpp/ChangeLog +++ b/app-text/llpp/ChangeLog @@ -1,6 +1,12 @@ # ChangeLog for app-text/llpp # Copyright 1999-2011 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/app-text/llpp/ChangeLog,v 1.12 2011/08/24 19:08:01 maekke Exp $ +# $Header: /var/cvsroot/gentoo-x86/app-text/llpp/ChangeLog,v 1.13 2011/10/04 22:46:00 xmw Exp $ + +*llpp-7 (04 Oct 2011) + + 04 Oct 2011; Michael Weber <xmw@gentoo.org> +llpp-7.ebuild, llpp-9999.ebuild, + +files/llpp-WM_CLASS.patch: + Version bump to v7 git tag, WM_CLASS patch, fixme ocaml[-ocamlopt] 24 Aug 2011; Markus Meier <maekke@gentoo.org> llpp-0_p20110504.ebuild: x86 stable, bug #378429 diff --git a/app-text/llpp/files/llpp-WM_CLASS.patch b/app-text/llpp/files/llpp-WM_CLASS.patch new file mode 100644 index 000000000000..ead8310c4099 --- /dev/null +++ b/app-text/llpp/files/llpp-WM_CLASS.patch @@ -0,0 +1,42 @@ +--- llpp-7/link.c ++++ llpp-7/link.c +@@ -1982,6 +1982,32 @@ + CAMLreturn (caml_copy_double (w)); + } + ++#if !defined (_WIN32) && !defined (__APPLE__) ++#undef pixel ++#include <X11/X.h> ++#include <X11/Xlib.h> ++#include <X11/Xutil.h> ++#include <GL/glx.h> ++ ++static void set_wm_class (void) ++{ ++ Display *dpy; ++ Window win; ++ int screen; ++ XClassHint hint; ++ ++ dpy = XOpenDisplay (getenv ("DISPLAY")); ++ screen = DefaultScreen (dpy); ++ hint.res_name = "llpp"; ++ hint.res_class = "llpp"; ++ win = glXGetCurrentDrawable (); ++ XSetClassHint (dpy, win, &hint); ++ XCloseDisplay (dpy); ++} ++#else ++#define set_wm_class() ++#endif ++ + CAMLprim value ml_init (value sock_v, value params_v) + { + CAMLparam2 (sock_v, params_v); +@@ -2044,5 +2070,6 @@ + } + #endif + ++ set_wm_class (); + CAMLreturn (Val_unit); + } diff --git a/app-text/llpp/llpp-7.ebuild b/app-text/llpp/llpp-7.ebuild new file mode 100644 index 000000000000..f93e1cec3bc2 --- /dev/null +++ b/app-text/llpp/llpp-7.ebuild @@ -0,0 +1,62 @@ +# Copyright 1999-2011 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/app-text/llpp/llpp-7.ebuild,v 1.1 2011/10/04 22:46:00 xmw Exp $ + +EAPI=3 + +inherit eutils toolchain-funcs + +DESCRIPTION="a graphical PDF viewer which aims to superficially resemble less(1)" +HOMEPAGE="http://repo.or.cz/w/llpp.git" +SRC_URI="mirror://gentoo/${P}.tar.gz" +#SRC_URI="http://repo.or.cz/w/llpp.git/snapshot/dabcf41a34eb6ebb1a539f8369c8fec15f94db1c.tar.gz -> ${P}.tar.gz" + +LICENSE="GPL-3" +SLOT="0" +KEYWORDS="~amd64 ~x86" +IUSE="vanilla" + +RDEPEND=">=app-text/mupdf-0.8.165 + dev-ml/lablgl[glut] + dev-lang/ocaml[ocamlopt] + media-libs/jbig2dec + media-libs/openjpeg + x11-misc/xsel" +DEPEND="${RDEPEND}" + +S=${WORKDIR}/${PN} + +src_prepare() { + use vanilla || epatch "${FILESDIR}"/${PN}-WM_CLASS.patch +} + +src_compile() { + ocaml str.cma keystoml.ml KEYS > help.ml || die + printf 'let version ="%s";;\n' ${PV} >> help.ml || die + + local myccopt="$(freetype-config --cflags) -O -include ft2build.h -D_GNU_SOURCE" + local mycclib="-lmupdf -lfitz -lz -ljpeg -lopenjpeg -ljbig2dec -lfreetype" + #if use ocamlopt ; then + myccopt="${myccopt} -lpthread" + ocamlopt -c -o link.o -ccopt "${myccopt}" link.c || die + ocamlopt -c -o help.cmx help.ml || die + ocamlopt -c -o parser.cmx parser.ml || die + ocamlopt -c -o main.cmx -I +lablGL main.ml || die + ocamlopt -o llpp -I +lablGL \ + str.cmxa unix.cmxa lablgl.cmxa lablglut.cmxa link.o \ + -cclib "${mycclib}" help.cmx parser.cmx main.cmx || die + #else + # ocamlc -c -o link.o -ccopt "${myccopt}" link.c || die + # ocamlc -c -o help.cmo help.ml || die + # ocamlc -c -o parser.cmo parser.ml || die + # ocamlc -c -o main.cmo -I +lablGL main.ml || die + # ocamlc -custom -o llpp -I +lablGL \ + # str.cma unix.cma lablgl.cma lablglut.cma link.o \ + # -cclib "${mycclib}" help.cmo parser.cmo main.cmo || die + #fi +} + +src_install() { + dobin ${PN} || die + dodoc KEYS README Thanks fixme || die +} diff --git a/app-text/llpp/llpp-9999.ebuild b/app-text/llpp/llpp-9999.ebuild index a69637b8d58f..33a2a2af7dac 100644 --- a/app-text/llpp/llpp-9999.ebuild +++ b/app-text/llpp/llpp-9999.ebuild @@ -1,6 +1,6 @@ # Copyright 1999-2011 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/app-text/llpp/llpp-9999.ebuild,v 1.7 2011/08/09 19:19:37 xmw Exp $ +# $Header: /var/cvsroot/gentoo-x86/app-text/llpp/llpp-9999.ebuild,v 1.8 2011/10/04 22:46:00 xmw Exp $ EAPI=3 @@ -15,30 +15,47 @@ SRC_URI="" LICENSE="GPL-3" SLOT="0" KEYWORDS="" -IUSE="" +IUSE="vanilla" RDEPEND=">=app-text/mupdf-0.8.165 dev-ml/lablgl[glut] + dev-lang/ocaml[ocamlopt] media-libs/jbig2dec media-libs/openjpeg x11-misc/xsel" DEPEND="${RDEPEND}" +src_prepare() { + use vanilla || epatch "${FILESDIR}"/${PN}-WM_CLASS.patch +} + src_compile() { - ocaml keystoml.ml KEYS > help.ml || die - echo "let version =\"$(git describe --tags)\";;" >> help.ml - ocamlopt -c -o link.o -ccopt -O link.c || die - ocamlopt -c -o help.cmx help.ml || die - ocamlopt -c -o parser.cmx parser.ml || die - ocamlopt -c -o main.cmx -I +lablGL main.ml || die - - ocamlopt -o llpp \ - -I +lablGL str.cmxa unix.cmxa lablgl.cmxa lablglut.cmxa link.o \ - -cclib "-lmupdf -lfitz -lz -ljpeg -lopenjpeg -ljbig2dec -lfreetype -lpthread" \ - help.cmx parser.cmx main.cmx || die + ocaml str.cma keystoml.ml KEYS > help.ml || die + printf 'let version ="%s";;\n' $(git describe --tags --dirty) >> help.ml || die + + local myccopt="$(freetype-config --cflags) -O -include ft2build.h -D_GNU_SOURCE" + local mycclib="-lmupdf -lfitz -lz -ljpeg -lopenjpeg -ljbig2dec -lfreetype" + #if use ocamlopt ; then + myccopt="${myccopt} -lpthread" + ocamlopt -c -o link.o -ccopt "${myccopt}" link.c || die + ocamlopt -c -o help.cmx help.ml || die + ocamlopt -c -o parser.cmx parser.ml || die + ocamlopt -c -o main.cmx -I +lablGL main.ml || die + ocamlopt -o llpp -I +lablGL \ + str.cmxa unix.cmxa lablgl.cmxa lablglut.cmxa link.o \ + -cclib "${mycclib}" help.cmx parser.cmx main.cmx || die + #else + # ocamlc -c -o link.o -ccopt "${myccopt}" link.c || die + # ocamlc -c -o help.cmo help.ml || die + # ocamlc -c -o parser.cmo parser.ml || die + # ocamlc -c -o main.cmo -I +lablGL main.ml || die + # ocamlc -custom -o llpp -I +lablGL \ + # str.cma unix.cma lablgl.cma lablglut.cma link.o \ + # -cclib "${mycclib}" help.cmo parser.cmo main.cmo || die + #fi } src_install() { dobin ${PN} || die - dodoc KEYS Thanks fixme || die + dodoc KEYS README Thanks fixme || die } |