• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1CLANG_LEVEL := ../..
2DIRS :=
3
4include $(CLANG_LEVEL)/Makefile
5
6IntIncludeDir = $(DESTDIR)$(PROJ_internal_prefix)/include
7
8install-local::
9	$(Echo) Installing Clang C API include files
10	$(Verb) $(MKDIR) $(IntIncludeDir)
11	$(Verb) if test -d "$(PROJ_SRC_DIR)" ; then \
12	  cd $(PROJ_SRC_DIR)/.. && \
13	  for  hdr in `find clang-c -type f '!' '(' -name '*~' \
14	      -o -name '.#*' -o -name '*.in' -o -name '*.txt' \
15	      -o -name 'Makefile' -o -name '*.td' ')' -print \
16              | grep -v CVS | grep -v .svn | grep -v .dir` ; do \
17	    instdir=`dirname "$(IntIncludeDir)/$$hdr"` ; \
18	    if test \! -d "$$instdir" ; then \
19	      $(EchoCmd) Making install directory $$instdir ; \
20	      $(MKDIR) $$instdir ;\
21	    fi ; \
22	    $(DataInstall) $$hdr $(IntIncludeDir)/$$hdr ; \
23	  done ; \
24	fi
25ifneq ($(PROJ_SRC_ROOT),$(PROJ_OBJ_ROOT))
26	$(Verb) if test -d "$(PROJ_OBJ_ROOT)/tools/clang/include/clang-c" ; then \
27	  cd $(PROJ_OBJ_ROOT)/tools/clang/include && \
28	  for hdr in `find clang-c -type f '!' '(' -name 'Makefile' ')' -print \
29            | grep -v CVS | grep -v .tmp | grep -v .dir` ; do \
30	    instdir=`dirname "$(IntIncludeDir)/$$hdr"` ; \
31	    if test \! -d "$$instdir" ; then \
32	      $(EchoCmd) Making install directory $$instdir ; \
33	      $(MKDIR) $$instdir ;\
34	    fi ; \
35	    $(DataInstall) $$hdr $(IntIncludeDir)/$$hdr ; \
36	  done ; \
37	fi
38endif
39