diff options
author | 2013-06-13 08:56:10 +0000 | |
---|---|---|
committer | 2013-06-13 08:56:10 +0000 | |
commit | 219ff5c403fc188917a3f5629c5da5f11fb18629 (patch) | |
tree | 955d92fe59db649639e4bdb1e4e7993bda0dfa4b /app-text/llpp/llpp-15.ebuild | |
parent | Add ~ppc keyword as dep of llpp (diff) | |
download | gentoo-2-219ff5c403fc188917a3f5629c5da5f11fb18629.tar.gz gentoo-2-219ff5c403fc188917a3f5629c5da5f11fb18629.tar.bz2 gentoo-2-219ff5c403fc188917a3f5629c5da5f11fb18629.zip |
Improve static build
(Portage version: 2.2.0_alpha179/cvs/Linux x86_64, signed Manifest commit with key 62EEF090)
Diffstat (limited to 'app-text/llpp/llpp-15.ebuild')
-rw-r--r-- | app-text/llpp/llpp-15.ebuild | 26 |
1 files changed, 22 insertions, 4 deletions
diff --git a/app-text/llpp/llpp-15.ebuild b/app-text/llpp/llpp-15.ebuild index 8751f3eef362..b001c4f3817e 100644 --- a/app-text/llpp/llpp-15.ebuild +++ b/app-text/llpp/llpp-15.ebuild @@ -1,10 +1,10 @@ # Copyright 1999-2013 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/app-text/llpp/llpp-15.ebuild,v 1.5 2013/06/11 09:00:27 xmw Exp $ +# $Header: /var/cvsroot/gentoo-x86/app-text/llpp/llpp-15.ebuild,v 1.6 2013/06/13 08:56:10 xmw Exp $ EAPI=5 -inherit eutils toolchain-funcs vcs-snapshot +inherit eutils multilib toolchain-funcs vcs-snapshot DESCRIPTION="a graphical PDF viewer which aims to superficially resemble less(1)" HOMEPAGE="http://repo.or.cz/w/llpp.git" @@ -26,7 +26,12 @@ LIB_DEPEND=">=app-text/mupdf-1.2:=[static-libs] RDEPEND="x11-misc/xsel !static? ( ${LIB_DEPEND//\[static-libs]} )" DEPEND="${RDEPEND} - static? ( ${LIB_DEPEND} ) + 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[ocamlopt?] dev-ml/lablgl[glut,ocamlopt?]" @@ -42,7 +47,20 @@ src_compile() { local cma=$(usex ocamlopt cmxa cma) local ccopt="$(freetype-config --cflags ) -O -include ft2build.h -D_GNU_SOURCE" if use static ; then - local cclib="-Wl,-Bstatic $($(tc-getPKG_CONFIG) --libs --static mupdf x11 | sed 's: -l\(m\|pthread\) : :g') -Wl,-Bdynamic -lm -lpthread" + local cclib="" + local slib="" + local spath=( ${EROOT}usr/$(get_libdir) $($(tc-getPKG_CONFIG) --libs-only-L --static mupdf x11 | sed 's:-L::g') ) + for slib in $($(tc-getPKG_CONFIG) --libs-only-l --static mupdf x11) -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)" fi |