diff options
Diffstat (limited to 'app-text/llpp')
-rw-r--r-- | app-text/llpp/Manifest | 6 | ||||
-rw-r--r-- | app-text/llpp/files/llpp-26b-WM_CLASS.patch | 41 | ||||
-rw-r--r-- | app-text/llpp/llpp-26b.ebuild | 87 | ||||
-rw-r--r-- | app-text/llpp/llpp-26b_p20180114.ebuild | 86 | ||||
-rw-r--r-- | app-text/llpp/metadata.xml | 8 |
5 files changed, 228 insertions, 0 deletions
diff --git a/app-text/llpp/Manifest b/app-text/llpp/Manifest new file mode 100644 index 000000000000..24878bb8ee8c --- /dev/null +++ b/app-text/llpp/Manifest @@ -0,0 +1,6 @@ +AUX llpp-26b-WM_CLASS.patch 860 BLAKE2B adcd60863d72d5328d6918c7904c58f160651a911c9b3f8f891ff884aae54b4327ca4b21fabf95a63025a7d76799a74d47dfb60a2ab55981aabf026be3afc2ca SHA512 42973fa329ab7fc900b1a5e86fee70918c5e78486cfc6fcf4802d9dc3e5a8a902d866a1ad23f3a6febf1dcd2d18f90389369d89024e3e1727a19fce456cf8604 +DIST llpp-26b.tar.gz 169385 BLAKE2B 9a80c22d013af063e3908bda69108ce6a4e0f72efb1c0b930308591d2b8a0f94f7b71a5f1057543e102b95b01440d567e6648d1ed77f1e85728f5ea31718ea28 SHA512 ce7d743d8ec998a93cf272083dc5926ce6a250aee6ac768814f511ecb309ffe94fb0e2561ca1778e1c7fbd5824545477937618c8e66d32fd273f9b5e5e3fd143 +DIST llpp-26b_p20180114.tar.gz 170204 BLAKE2B c7f46491d69350e8e94b444f0be4d7375f5658cccded792ecce2a246c907ae98bcca45d73e3b6c15765bd926d559327491559b5e5eec63bf2645cba84f6ee0d3 SHA512 1bc544f4bae268f573c2c111b69f7129bd3d1c1c8cc635c06f76e12670ad9476b4c2a2776e3959203ab6e53ea8ad1c68be290619298f7ebc1ae8203875f88314 +EBUILD llpp-26b.ebuild 3115 BLAKE2B 03813d97d89259ddb09a0b7fc5f90ce7bfbb99464573aab532f8af232d33432b5a2406b8c455d34d2f2f87d0d6a1c095dd563ea7d419088ed83b1c594c77c9a0 SHA512 f7afd8b79aece96846f5bf5cedf3f4f3a92aa34aa9974f0243729da72f4470a942239af21c6697969b2401f4eb10743d498e425bdaacc0101775cc21cd348196 +EBUILD llpp-26b_p20180114.ebuild 3032 BLAKE2B d6cc8bf1fac0cd932c298d4816221137e47df136283fc752be62886a1111de02803e92230319ccffc1864dbaf81b318c0400a34454a4f1019d8825d76f353e5b SHA512 f4b0da1be74c63c71ae02e1b6dfb7067ead203a9e1203e2c88e1eb4302364205bb92c2e4e841d861124f99781e6bb7214bf5e536dbab51a0e20c178b54afec11 +MISC metadata.xml 237 BLAKE2B f22c3926ba75c18fce7667217807f3710a315b12b1341622c949e7bc0056cd1cb403ea6c66d838675f3cb5dcd53d2fc4ec71425ec3f96aaffb94b70b73e99320 SHA512 ae2360aa6b1b00c67e0acea4935c02b64585b9a15e126fec9d5d99637021c542c0a495e5116205f3da287def46fa5b19cb1a7f3042c12c5f7a78d66d92fcb03f diff --git a/app-text/llpp/files/llpp-26b-WM_CLASS.patch b/app-text/llpp/files/llpp-26b-WM_CLASS.patch new file mode 100644 index 000000000000..e99d9a4e4e5a --- /dev/null +++ b/app-text/llpp/files/llpp-26b-WM_CLASS.patch @@ -0,0 +1,41 @@ +--- llpp-26b/link.c ++++ llpp-26b/link.c +@@ -4392,6 +4392,31 @@ + return caml_copy_string (FZ_VERSION); + } + ++#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; ++ XClassHint hint; ++ ++ dpy = XOpenDisplay (getenv ("DISPLAY")); ++ 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 void ml_init (value csock_v, value params_v) + { + CAMLparam2 (csock_v, params_v); +@@ -4460,5 +4485,6 @@ + errx (1, "pthread_create: %s", strerror (ret)); + } + ++ set_wm_class (); + CAMLreturn0; + } diff --git a/app-text/llpp/llpp-26b.ebuild b/app-text/llpp/llpp-26b.ebuild new file mode 100644 index 000000000000..607103b2b3e5 --- /dev/null +++ b/app-text/llpp/llpp-26b.ebuild @@ -0,0 +1,87 @@ +# Copyright 1999-2018 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=6 + +inherit eutils multilib toolchain-funcs vcs-snapshot + +DESCRIPTION="graphical PDF viewer which aims to superficially resemble less(1)" +HOMEPAGE="http://repo.or.cz/w/llpp.git" +SRC_URI="http://repo.or.cz/llpp.git/snapshot/606ca0f5b7d9c1f031e558c17d66591daa04e3a4.tar.gz -> ${P}.tar.gz" + +LICENSE="GPL-3" +SLOT="0" +KEYWORDS="amd64 ppc x86" +IUSE="+ocamlopt static" + +LIB_DEPEND=">=app-text/mupdf-1.11:0=[static-libs] + <app-text/mupdf-1.12:0=[static-libs] + media-libs/openjpeg:2[static-libs] + media-libs/fontconfig:1.0[static-libs] + media-libs/freetype:2[static-libs] + media-libs/jbig2dec[static-libs] + sys-libs/zlib[static-libs] + virtual/jpeg:0[static-libs] + x11-libs/libX11[static-libs]" +RDEPEND="x11-misc/xsel + !static? ( ${LIB_DEPEND//\[static-libs]} )" +DEPEND="${RDEPEND} + static? ( ${LIB_DEPEND} + app-arch/bzip2[static-libs] + media-libs/libXcm[static-libs] + x11-libs/libXau[static-libs] + x11-libs/libXdmcp[static-libs] + x11-libs/libXmu[static-libs] ) + >=dev-lang/ocaml-4.02[ocamlopt?] + dev-ml/lablgl[glut,ocamlopt?]" + +RESTRICT="!ocamlopt? ( strip )" + +PATCHES=( "${FILESDIR}"/${PN}-26b-WM_CLASS.patch ) + +src_compile() { + local ocaml=$(usex ocamlopt ocamlopt.opt ocamlc.opt) + local cmo=$(usex ocamlopt cmx cmo) + local cma=$(usex ocamlopt cmxa cma) + local ccopt="$(freetype-config --cflags ) -O -include ft2build.h -D_GNU_SOURCE -DUSE_FONTCONFIG -std=c99 -Wextra -Wall -pedantic-errors -Wunused-parameter -Wsign-compare -Wshadow" + if use static ; then + local cclib="" + local slib="" + local spath=( ${EROOT}usr/$(get_libdir) $($(tc-getPKG_CONFIG) --libs-only-L --static mupdf x11 ${egl} | sed 's:-L::g') ) + for slib in $($(tc-getPKG_CONFIG) --libs-only-l --static mupdf x11 ${egl} fontconfig) -ljpeg -ljbig2dec ; do + case ${slib} in + -lm|-ldl|-lpthread) + einfo "${slib}: shared" + cclib+="${slib} " ;; + *) + local ccnew=$(find ${spath} -name "lib${slib/-l}.a") + einfo "${slib}: use ${ccnew}" + cclib+="${ccnew} " ;; + esac + done + else + local cclib="$($(tc-getPKG_CONFIG) --libs mupdf x11 ${egl} fontconfig) -lpthread" + fi + + verbose() { echo "$@" >&2 ; "$@" || die ; } + verbose sh mkhelp.sh KEYS ${PV} > help.ml + verbose printf 'let version ="%s";;\n' ${PV} >> help.ml + verbose ${ocaml} -c -o link.o -ccopt "${ccopt}" link.c + verbose ${ocaml} -c -o keys.${cmo} keys.ml + verbose ${ocaml} -c -o help.${cmo} help.ml + verbose ${ocaml} -c -o utils.${cmo} utils.ml + verbose ${ocaml} -c -o wsi/x11/wsi.cmi wsi/x11/wsi.mli + verbose ${ocaml} -c -o wsi/x11/wsi.${cmo} -I wsi/x11 wsi/x11/wsi.ml + verbose ${ocaml} -c -o parser.${cmo} parser.ml + verbose ${ocaml} -c -o config.${cmo} -I +lablGL -I wsi/x11 config.ml + verbose ${ocaml} -c -o main.${cmo} -I +lablGL -I wsi/x11 main.ml + verbose ${ocaml} $(usex ocamlopt "" -custom) -o llpp -I +lablGL -I wsi/x11 \ + str.${cma} unix.${cma} lablgl.${cma} link.o \ + -cclib "${cclib}" \ + help.${cmo} utils.${cmo} parser.${cmo} wsi.${cmo} config.${cmo} main.${cmo} +} + +src_install() { + dobin ${PN} misc/${PN}ac + dodoc KEYS README Thanks +} diff --git a/app-text/llpp/llpp-26b_p20180114.ebuild b/app-text/llpp/llpp-26b_p20180114.ebuild new file mode 100644 index 000000000000..4c83f9fd324e --- /dev/null +++ b/app-text/llpp/llpp-26b_p20180114.ebuild @@ -0,0 +1,86 @@ +# Copyright 1999-2018 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=6 + +inherit eutils multilib toolchain-funcs vcs-snapshot + +DESCRIPTION="graphical PDF viewer which aims to superficially resemble less(1)" +HOMEPAGE="http://repo.or.cz/w/llpp.git" +SRC_URI="https://distfiles.gentoo.org/distfiles/${P}.tar.gz" + +LICENSE="GPL-3" +SLOT="0" +KEYWORDS="amd64 ~ppc x86" +IUSE="+ocamlopt static" + +LIB_DEPEND=">=app-text/mupdf-1.12.0:0=[static-libs] + media-libs/openjpeg:2[static-libs] + media-libs/fontconfig:1.0[static-libs] + media-libs/freetype:2[static-libs] + media-libs/jbig2dec[static-libs] + sys-libs/zlib[static-libs] + virtual/jpeg:0[static-libs] + x11-libs/libX11[static-libs]" +RDEPEND="x11-misc/xsel + !static? ( ${LIB_DEPEND//\[static-libs]} )" +DEPEND="${RDEPEND} + static? ( ${LIB_DEPEND} + app-arch/bzip2[static-libs] + media-libs/libXcm[static-libs] + x11-libs/libXau[static-libs] + x11-libs/libXdmcp[static-libs] + x11-libs/libXmu[static-libs] ) + >=dev-lang/ocaml-4.02[ocamlopt?] + dev-ml/lablgl[glut,ocamlopt?]" + +RESTRICT="!ocamlopt? ( strip )" + +PATCHES=( "${FILESDIR}"/${PN}-26b-WM_CLASS.patch ) + +src_compile() { + local ocaml=$(usex ocamlopt ocamlopt.opt ocamlc.opt) + local cmo=$(usex ocamlopt cmx cmo) + local cma=$(usex ocamlopt cmxa cma) + local ccopt="$(freetype-config --cflags ) -O -include ft2build.h -D_GNU_SOURCE -DUSE_FONTCONFIG -std=c99 -Wextra -Wall -pedantic-errors -Wunused-parameter -Wsign-compare -Wshadow" + if use static ; then + local cclib="" + local slib="" + local spath=( ${EROOT}usr/$(get_libdir) $($(tc-getPKG_CONFIG) --libs-only-L --static mupdf x11 ${egl} | sed 's:-L::g') ) + for slib in $($(tc-getPKG_CONFIG) --libs-only-l --static mupdf x11 ${egl} fontconfig) -ljpeg -ljbig2dec ; do + case ${slib} in + -lm|-ldl|-lpthread) + einfo "${slib}: shared" + cclib+="${slib} " ;; + *) + local ccnew=$(find ${spath} -name "lib${slib/-l}.a") + einfo "${slib}: use ${ccnew}" + cclib+="${ccnew} " ;; + esac + done + else + local cclib="$($(tc-getPKG_CONFIG) --libs mupdf x11 ${egl} fontconfig) -lpthread" + fi + + verbose() { echo "$@" >&2 ; "$@" || die ; } + verbose sh mkhelp.sh KEYS ${PV} > help.ml + verbose printf 'let version ="%s";;\n' ${PV} >> help.ml + verbose ${ocaml} -c -o link.o -ccopt "${ccopt}" link.c + verbose ${ocaml} -c -o keys.${cmo} keys.ml + verbose ${ocaml} -c -o help.${cmo} help.ml + verbose ${ocaml} -c -o utils.${cmo} utils.ml + verbose ${ocaml} -c -o wsi/x11/wsi.cmi wsi/x11/wsi.mli + verbose ${ocaml} -c -o wsi/x11/wsi.${cmo} -I wsi/x11 wsi/x11/wsi.ml + verbose ${ocaml} -c -o parser.${cmo} parser.ml + verbose ${ocaml} -c -o config.${cmo} -I +lablGL -I wsi/x11 config.ml + verbose ${ocaml} -c -o main.${cmo} -I +lablGL -I wsi/x11 main.ml + verbose ${ocaml} $(usex ocamlopt "" -custom) -o llpp -I +lablGL -I wsi/x11 \ + str.${cma} unix.${cma} lablgl.${cma} link.o \ + -cclib "${cclib}" \ + help.${cmo} utils.${cmo} parser.${cmo} wsi.${cmo} config.${cmo} main.${cmo} +} + +src_install() { + dobin ${PN} misc/${PN}ac + dodoc KEYS README Thanks +} diff --git a/app-text/llpp/metadata.xml b/app-text/llpp/metadata.xml new file mode 100644 index 000000000000..a535b8852829 --- /dev/null +++ b/app-text/llpp/metadata.xml @@ -0,0 +1,8 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> +<maintainer type="person"> +<email>xmw@gentoo.org</email> +<name>Michael Weber</name> +</maintainer> +</pkgmetadata> |