r22484 - gnucash-docs/trunk - gnucash-docs: fix out of tree epub build

Geert Janssens janssens-geert at telenet.be
Fri Nov 2 13:39:04 EDT 2012


On 02-11-12 17:27, Derek Atkins wrote:
> Geert,
>
> Geert Janssens <gjanssens at code.gnucash.org> writes:
>
>> Modified: gnucash-docs/trunk/epub.make
>> ===================================================================
>> --- gnucash-docs/trunk/epub.make	2012-11-01 17:37:17 UTC (rev 22483)
>> +++ gnucash-docs/trunk/epub.make	2012-11-01 17:37:29 UTC (rev 22484)
>> @@ -16,9 +16,9 @@
>>   	$(XSLTPROC) --stringparam base.dir OEBPS/ \
>>   	            --stringparam epub.metainf.dir META-INF/ \
>>   	            --stringparam epub.oebps.dir OEBPS/ \
>> -	            ../../../xsl/1.75.2/epub/docbook.xsl \
>> -	            ../$(docname).xml && \
>> -	cp -L -R ../figures OEBPS/ && \
>> +	            $(top_srcdir)/xsl/1.75.2/epub/docbook.xsl \
>> +	            $(srcdir)/$(docname).xml && \
>> +	cp -L -R $(srcdir)/figures OEBPS/ && \
>>   	zip -X -r ../$(epubfile) mimetype META-INF OEBPS && \
>>   	cd ..) && posthook=''; \
>>   	if test -d "$$EPUB_TMPDIR"; then \
> I suspect this might have been the change that caused the docs build to
> fail.  Here's the actual failure:
>
> Making epub in C
> make[2]: Entering directory `/u1/home/gnucash/gnucash-docs/trunk/guide/C'
> EPUB_TMPDIR=`mktemp -d .epubtmpXXXXXXXX`; \
> posthook='exit 1'; \
> (cd "$EPUB_TMPDIR" && \
> echo "application/epub+zip" > mimetype && \
> /usr/bin/xsltproc --stringparam base.dir OEBPS/ \
>              --stringparam epub.metainf.dir META-INF/ \
>              --stringparam epub.oebps.dir OEBPS/ \
>              ../../xsl/1.75.2/epub/docbook.xsl \
>              ./gnucash-guide.xml && \
> cp -L -R ./figures OEBPS/ && \
> zip -X -r ../gnucash-guide.epub mimetype META-INF OEBPS && \
> cd ..) && posthook=''; \
> if test -d "$EPUB_TMPDIR"; then \
>    rm -v -fr "$EPUB_TMPDIR"; \
> fi; \
> eval "$posthook";
> warning: failed to load external entity "../../xsl/1.75.2/epub/docbook.xsl"
> cannot parse ../../xsl/1.75.2/epub/docbook.xsl
> removed `.epubtmpeiHuJMgA/mimetype'
>
> Maybe change this to use abs_top_srcdir and abs_srcdir?  It looks like
> the issue is the "cd $EPUB_TMPDIR", so it is changing one directory
> deeper, so the relative *srcdir macros are wrong.
>
> -derek
>
I didn't see this error during the out-of-tree build. Probably because 
in that case top_srcdir and srcdir are already absolute paths, while 
during an in-tree build, the two macro's are relative paths. The build 
script creates a new subdirectory and descends into it, so the relative 
paths are off...

Thanks for debugging this. I tested with abs_{top_}srcdir on my out of 
tree build and that works fine as well. I have pushed a fix. Let's see 
if tomorrow's build works fine now.

Geert


More information about the gnucash-devel mailing list