Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
dev-tex/html2latex-1.1-r1: Can't locate HTML/Latex.pm
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Portage & Programming
View previous topic :: View next topic  
Author Message
krotuss
Tux's lil' helper
Tux's lil' helper


Joined: 01 Aug 2008
Posts: 94

PostPosted: Mon Nov 24, 2014 11:34 pm    Post subject: dev-tex/html2latex-1.1-r1: Can't locate HTML/Latex.pm Reply with quote

When I run html2latex, it terminates with error message:
Code:
Can't locate HTML/Latex.pm in @INC (you may need to install the HTML::Latex module) (@INC contains: /etc/perl /usr/local/lib64/perl5/5.18.2/x86_64-linux /usr/local/lib64/perl5/5.18.2 /usr/lib64/perl5/vendor_perl/5.18.2/x86_64-linux /usr/lib64/perl5/vendor_perl/5.18.2 /usr/local/lib64/perl5 /usr/lib64/perl5/vendor_perl /usr/lib64/perl5/5.18.2/x86_64-linux /usr/lib64/perl5/5.18.2 .) at /usr/bin/html2latex line 81.
BEGIN failed--compilation aborted at /usr/bin/html2latex line 81.

According to http://www.portagefilelist.de/ HTML/Latex.pm was installed by dev-tex/html2latex-1.1-r0 but NOT dev-tex/html2latex-1.1-r1. Currently dev-tex/html2latex-1.1-r1 is the only version in portage.

equery f dev-tex/html2latex:
Code:
 * Searching for html2latex in dev-tex ...
 * Contents of dev-tex/html2latex-1.1-r1:
/usr
/usr/bin
/usr/bin/html2latex
/usr/share
/usr/share/doc
/usr/share/doc/html2latex-1.1-r1
/usr/share/doc/html2latex-1.1-r1/Changes.bz2
/usr/share/doc/html2latex-1.1-r1/README.bz2
/usr/share/doc/html2latex-1.1-r1/TODO.bz2
/usr/share/man
/usr/share/man/man1
/usr/share/man/man1/html2latex.1.bz2


How can I make html2latex work? Is this bug? Thanks.
Back to top
View user's profile Send private message
idiv0
n00b
n00b


Joined: 02 Nov 2014
Posts: 3

PostPosted: Tue Nov 25, 2014 1:08 am    Post subject: Reply with quote

Found an old portage snapshot at ftp://ftp.aarnet.edu.au/pub/gentoo/snapshots/squashfs/gentoo-20140324.sqfs
It contained html2latex-1.1.ebuild and html2latex-1.1-r1.ebuild.

Code:
% diff html2latex-1.1.ebuild html2latex-1.1-r1.ebuild
1c1
< # Copyright 1999-2009 Gentoo Foundation
---
> # Copyright 1999-2013 Gentoo Foundation
3c3
< # $Header: /var/cvsroot/gentoo-x86/dev-tex/html2latex/html2latex-1.1.ebuild,v 1.15 2009/09/06 20:47:06 ranger Exp $
---
> # $Header: /var/cvsroot/gentoo-x86/dev-tex/html2latex/html2latex-1.1-r1.ebuild,v 1.1 2013/08/29 16:17:37 idella4 Exp $
5c5,7
< inherit perl-app
---
> EAPI=5
>
> inherit perl-module
13c15
< KEYWORDS="alpha amd64 hppa ia64 ppc ppc64 sparc x86"
---
> KEYWORDS="~alpha ~amd64 ~hppa ~ia64 ~ppc ~ppc64 ~sparc ~x86"
36a39,40
>    rm unwanted README.win
>    rm $(find "${D}" -name README.win.txt) || die



html2latex-1.1.ebuild:

Code:
# Copyright 1999-2009 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/dev-tex/html2latex/html2latex-1.1.ebuild,v 1.15 2009/09/06 20:47:06 ranger Exp $

inherit perl-app

DESCRIPTION="Perl script to convert HTML files into formatted LaTeX"
HOMEPAGE="http://html2latex.sourceforge.net/"
SRC_URI="mirror://sourceforge/html2latex/${P}.tar.gz"
LICENSE="GPL-2"

SLOT="0"
KEYWORDS="alpha amd64 hppa ia64 ppc ppc64 sparc x86"

IUSE="imagemagick libwww"

DEPEND="dev-perl/HTML-Tree
   dev-perl/XML-Simple
   imagemagick? ( media-gfx/imagemagick )
   libwww? ( dev-perl/libwww-perl )"

src_compile() {
   # HTML::LaTex
   cd HTML
   perl-module_src_prep
   perl-module_src_compile
}

src_install() {
   dobin html2latex
   doman html2latex.1
   dodoc README TODO

   # HTML::LaTex
   cd HTML
   perl-module_src_install
}
Back to top
View user's profile Send private message
krotuss
Tux's lil' helper
Tux's lil' helper


Joined: 01 Aug 2008
Posts: 94

PostPosted: Tue Nov 25, 2014 12:06 pm    Post subject: Reply with quote

I think that I'v found the problem. Default "src_configure" ("perl-module_src_configure") function already calls "perl-module_src_prep" which sets:
Code:
SRC_PREP="yes"

Subsequent "perl-module_src_prep" call from "src_compile" then bails out on:
Code:
[[ ${SRC_PREP} = yes ]] && return 0

Patching html2latex-1.1-r1.ebuild like this works for me:
Code:

--- html2latex-1.1-r1.ebuild
+++ html2latex-1.1-r1_p.ebuild
@@ -21,10 +21,15 @@
        imagemagick? ( media-gfx/imagemagick )
        libwww? ( dev-perl/libwww-perl )"
 
-src_compile() {
+src_configure() {
        # HTML::LaTex
        cd HTML
        perl-module_src_prep
+}
+
+src_compile() {
+       # HTML::LaTex
+       cd HTML
        perl-module_src_compile
 }
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Portage & Programming All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum