Subversion Repositories TruePreview

[/] [trunk/] [headerdoc.make] - Diff between revs 3 and 18

Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | View Log

Rev 3 Rev 18
Line 29... Line 29...
 
 
##
##
# headerdoc.make
# headerdoc.make
# Copyright (c) 2009 Jim Riggs, Christian Serving, L.L.C. All rights reserved.
# Copyright (c) 2009 Jim Riggs, Christian Serving, L.L.C. All rights reserved.
#
#
# @(#) $Id: headerdoc.make 3 2009-06-27 08:07:15Z jhriggs $
# @(#) $Id: headerdoc.make 18 2009-10-09 12:21:32Z jhriggs $
##
##
 
 
SRC_DIR := $(PROJECT_DIR)/Source
SRC_DIR := $(PROJECT_DIR)/Source
HDR_DIR := $(PROJECT_DIR)/headerdoc
HDR_DIR := $(PROJECT_DIR)/headerdoc
TMP_DIR := $(shell mktemp -d -t headerdoc)
TMP_DIR := $(shell mktemp -d -t headerdoc)
 
 
HEADERDOC := headerdoc2html -C -t -u -o $(HDR_DIR)
HEADERDOC := headerdoc2html -C -t -u -o $(HDR_DIR)
GATHERHEADERDOC := gatherheaderdoc $(TMP_DIR)/headerdoc index.html
GATHERHEADERDOC := gatherheaderdoc $(TMP_DIR)/headerdoc index.html
 
 
DOCS := $(patsubst $(SRC_DIR)/%.h,$(HDR_DIR)/%/index.html,$(wildcard $(SRC_DIR)/*.h))
DOCS := $(patsubst $(SRC_DIR)/%.h,$(HDR_DIR)/%_h/index.html,$(wildcard $(SRC_DIR)/*.h))
 
 
$(HDR_DIR)/index.html : $(DOCS)
$(HDR_DIR)/index.html : $(DOCS)
  cp -Rp $(HDR_DIR) $(TMP_DIR)/
  cp -Rp $(HDR_DIR) $(TMP_DIR)/
  find $(TMP_DIR)/headerdoc -type d -name '.svn' -exec rm -rf {} +
  find $(TMP_DIR)/headerdoc -type d -name '.svn' -exec rm -rf {} +
  $(GATHERHEADERDOC)
  $(GATHERHEADERDOC)
  cp -R $(TMP_DIR)/headerdoc/ $(HDR_DIR)/
  cp -R $(TMP_DIR)/headerdoc/ $(HDR_DIR)/
  rm -rf $(TMP_DIR)
  rm -rf $(TMP_DIR)
 
 
$(DOCS) : $(HDR_DIR)/%/index.html : $(SRC_DIR)/%.h
$(DOCS) : $(HDR_DIR)/%_h/index.html : $(SRC_DIR)/%.h
  $(HEADERDOC) $?
  $(HEADERDOC) $?