Bug 90199 - AVRDUDE Fails Emerge with Texi2Html 1.76
Bug#: 90199 Product:  Gentoo Linux Version: unspecified Platform: AMD64
OS/Version: Linux Status: RESOLVED Severity: normal Priority: P5
Resolution: FIXED Assigned To: dev-embedded@gentoo.org Reported By: jason@qhacks.com
Component: Development
URL: 
Summary: AVRDUDE Fails Emerge with Texi2Html 1.76
Keywords:  
Status Whiteboard: 
Opened: 2005-04-23 23:40 0000
Description:   Opened: 2005-04-23 23:40 0000
When emerging avrdude, using texi2html version 1.76 i reach an error during
make
"unknown command `@hfill` (left as is)"
"unknown command `@vfill` (left as is)" and texi2html fails to generate the
html files
using texi2html v1.64 however works fine.

------- Comment #1 From Lukas Sandström 2005-05-08 08:39:58 0000 -------
The problem is that texi2html creates a new directory called avrdude when
called with 
texi2html -split node avrdude.texi 
in the doc directory. Most likley this is a new behavior, which is why the bug
occurs. Also note that it isn't texi2html that fails, but 
mv *.html avrdude-html
since all the html-files are in the sub-directory avrdude.

A patch is attached that fixes doc/Makefile.am and doc/Makefile.in to look for
the avrdude subdirectory as well as *.html files i ./ so it should work for
both new and old versions of texi2html. I'll send it to the avrdude developers,
but if it goes into portage now it should fix the problem until the next
version of avrdude is released.

------- Comment #2 From Lukas Sandström 2005-05-08 08:41:29 0000 -------
Created an attachment (id=58357) [details]
A patch thhat fixes the Makefiles to look for the directory that newer versions
of texi2html creates.

------- Comment #3 From Lukas Sandström 2005-05-09 11:57:37 0000 -------
This bug should propably be reassigned to bug-wranglers@gentoo.org or
dev-embedded@gentoo.org

------- Comment #4 From Daniel Black 2005-05-23 03:56:20 0000 -------
Related to http://savannah.nongnu.org/patch/?func=detailitem&item_id=3091?   
   
make[1]: Leaving directory   
`/var/tmp/portage/avrdude-4.4.0-r1/work/avrdude-4.4.0'   
>>> Test phase [enabled]: dev-embedded/avrdude-4.4.0-r1   
>>> Test phase [check]: dev-embedded/avrdude-4.4.0-r1   
Making check in doc   
make[1]: Entering directory   
`/var/tmp/portage/avrdude-4.4.0-r1/work/avrdude-4.4.0/doc'   
texi2html -split_node ./avrdude.texi   
** Unknown command `@hfill' (left as is)   
** Unknown command `@vfill' (left as is)   
if [ -e ./avrdude.html ]; then \   
 mkdir -p avrdude-html; \   
 mv *.html avrdude-html ; \   
else \   
 mv avrdude avrdude-html; \   
fi;   
make[1]: Leaving directory   
`/var/tmp/portage/avrdude-4.4.0-r1/work/avrdude-4.4.0/doc'   
make[1]: Entering directory   
`/var/tmp/portage/avrdude-4.4.0-r1/work/avrdude-4.4.0'   
make[1]: Nothing to be done for `check-am'.   
make[1]: Leaving directory   
`/var/tmp/portage/avrdude-4.4.0-r1/work/avrdude-4.4.0'   
   
I still get the following with the patch:   
   
>>> Install avrdude-4.4.0-r1 into /var/tmp/portage/avrdude-4.4.0-r1/image/   
category dev-embedded   
Making install in doc   
make[1]: Entering directory   
`/var/tmp/portage/avrdude-4.4.0-r1/work/avrdude-4.4.0/doc'   
texi2html -split_node ./avrdude.texi   
** Unknown command `@hfill' (left as is)   
** Unknown command `@vfill' (left as is)   
if [ -e ./avrdude.html ]; then \   
 mkdir -p avrdude-html; \   
 mv *.html avrdude-html ; \   
else \   
 mv avrdude avrdude-html; \   
fi;   
mv: cannot overwrite directory `avrdude-html/avrdude'   
make[1]: *** [html] Error 1   
make[1]: Leaving directory   
`/var/tmp/portage/avrdude-4.4.0-r1/work/avrdude-4.4.0/doc'   
make: *** [install-recursive] Error 1   
   
  
bash-2.05b$ emerge -pv texi2html  
  
These are the packages that I would merge, in order:  
  
Calculating dependencies ...done!  
[ebuild   R   ] app-text/texi2html-1.76  0 kB  
  
Total size of downloads: 0 kB  
bash-2.05b$ emerge info  
Portage 2.0.51.22-r1 (default-linux/x86/2005.0, gcc-3.3.5,  
glibc-2.3.4.20041102-r1, 2.6.11-hardened-r1 i686)  
=================================================================  
System uname: 2.6.11-hardened-r1 i686 AMD Athlon(tm) XP 1900+  
Gentoo Base System version 1.4.16  
distcc 2.16 i686-pc-linux-gnu (protocols 1 and 2) (default port 3632)  
[disabled]  
ccache version 2.3 [disabled]  
dev-lang/python:     2.3.5  
sys-apps/sandbox:    1.2.8  
sys-devel/autoconf:  2.13, 2.59-r6  
sys-devel/automake:  1.4_p6, 1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.5  
sys-devel/binutils:  2.16  
sys-devel/libtool:   1.5.16  
virtual/os-headers:  2.6.8.1-r2  
  
   

------- Comment #5 From Lukas Sandström 2005-05-24 15:22:57 0000 -------
The problem with the original path is that make doesn't detect that texi2html
already has been ran, so it runs it again for the install-phase, causing mv to
fail when the avrdude-html dir already exists.

The new version of the patch fixes this by simply rm -rf'ing the dir before any
mv is attempted.

This patch should work, I installed avrdude using the portage ebuild and this
patch by:

ebuild <ebuild> unpack
cd <tmp-dir> ; patch -p1 < <patch-file>
ebuild <ebuild> compile
ebuild <ebuild> install
ebuild <ebuild> qmerge

It appears to work nicely. 
Please add ~amd64 to avrdude and mark #91905 resolved while you're at it.

------- Comment #6 From Lukas Sandström 2005-05-24 15:24:18 0000 -------
Created an attachment (id=59745) [details]
A better patch, one that works...

------- Comment #7 From Daniel Black 2005-05-24 21:10:39 0000 -------
Thanks Lukas.   
 
Sorry I haven't got an amd64 to confirm this on however you've done the right 
thing with bug 91905. 
 
amd64 donations gratefully accepted:-)