Makefile for docs

Dougie Richardson ddrichardson at btinternet.com
Fri Aug 10 19:06:24 UTC 2007


Hi,

On Wed, 2007-08-08 at 22:19 -0500, Richard A. Johnson wrote:
> On Wednesday 08 August 2007, Ian wrote:
> [snip]
> |  # Add your language file here:
> |  TARGETS = mobileguide.html
> |
> |  XSLTPROC = /usr/bin/xsltproc
> |  XSL = ubuntu.xsl
> |
> |  %.html: %.xml $(XSL)
> |     @$(XSLTPROC) -o $@ $(XSL) $<
> |
> |  all: $(TARGETS)
> |
> |  clean:
> |     @rm -f *.html
> 
> You can get rid of the XSLTPROC line and just do this instead:
> 
> all:
> 	xsltproc --xinclude -o /location/you/want/the/html/to/go $(XSL) \
> 		location/to/html
> 
> For a good example of a Makefile, check out 
> https://docteam.ubuntu.com/repos/trunk/kubuntu/Makefile
> 
> Hope this helps a little.


With bash, variable assignment needs single quotes - i.e. target =
'whatever'

Cheers

Dougie Richardson





More information about the ubuntu-doc mailing list