Mercurial > mplayer.hg
diff DOCS/xml/Makefile.inc @ 11893:cf34e63146bf
Move symlinks to a separate target
| author | wight |
|---|---|
| date | Fri, 30 Jan 2004 11:40:54 +0000 |
| parents | b09020364bfb |
| children | e589db41eb34 |
line wrap: on
line diff
--- a/DOCS/xml/Makefile.inc Fri Jan 30 10:36:29 2004 +0000 +++ b/DOCS/xml/Makefile.inc Fri Jan 30 11:40:54 2004 +0000 @@ -35,38 +35,24 @@ html-chunked: $(HTMLDIR)/index.html html-single: $(HTMLFILE) -$(HTMLDIR)/index.html: main.xml $(CHUNK_XSL_DEPS) +$(HTMLDIR)/index.html: main.xml $(CHUNK_XSL_DEPS) $(if $(findstring yes,$(USE_SYMLINKS)),symlinks) ifndef HTMLDIR $(warning $(HTMLDIR)) $(warning Error: HTMLDIR not set!!!) $(warning Typically this means, that you've run make from a subdir of DOCS/xml.) $(error Don't do this!) endif - if test "$(USE_SYMLINKS)" = "yes" ; then \ - for file in ../en/*.xml ; do \ - if ! test -r `basename $$file` ; then \ - ln -s $$file `basename $$file` ; \ - fi ; \ - done ; \ - fi -rm -f $(HTMLDIR)/* ../xmllint.sh $< cp -f $(HTML_STYLESHEET) $(HTMLDIR)/ ../xsltproc.sh $(HTMLDIR)/ $(HTML_CHUNK_XSL) $< -$(HTMLFILE): main.xml $(XSL_DEPS) +$(HTMLFILE): main.xml $(XSL_DEPS) $(if $(findstring yes,$(USE_SYMLINKS)),symlinks) ifndef HTMLFILE $(warning Error: HTMLFILE not set!!!) $(warning Typically this means, that you've run make from a subdir of DOCS/xml.) $(error Don't do this!) endif - if test "$(USE_SYMLINKS)" = "yes" ; then \ - for file in ../en/*.xml ; do \ - if ! test -r `basename $$file` ; then \ - ln -s $$file `basename $$file` ; \ - fi ; \ - done ; \ - fi -rm -f $(HTMLFILE) ../xmllint.sh $< cp -f $(HTML_STYLESHEET) `dirname $(HTMLFILE)` @@ -75,6 +61,14 @@ ../html-chunk.xsl ../html-single.xsl main.xml: cd .. && sh configure +.PHONY: symlinks +symlinks: + for file in ../en/*.xml ; do \ + if ! test -r `basename $$file` ; then \ + ln -s $$file `basename $$file` ; \ + fi; \ + done + distclean: rm -f main.xml if test "$(USE_SYMLINKS)" = "yes" ; then \
