]> Gitweb @ Texas Instruments - Open Source Git Repositories - git.TI.com/gitweb - keystone-rtos/rm-lld.git/blob - makefile_armv7
Added cify script and test dts files to yocto install
[keystone-rtos/rm-lld.git] / makefile_armv7
1 #*******************************************************************************
2 #* FILE PURPOSE: Top level makefile for Creating Component Libraries for ARM
3 #* architectures
4 #*******************************************************************************
5 #* FILE NAME: makefile
6 #*
7 #* DESCRIPTION: Defines Compiler tools paths, libraries , Build Options 
8 #*
9 #*
10 #*******************************************************************************
11 #*
12 # (Mandatory) Specify where various tools are installed.
14 # Output for prebuilt generated libraries
15 export ARMV7LIBDIR ?= ./lib
16 export DEVICE ?=k2h
17 export ARMV7OBJDIR ?= ./obj/$(DEVICE)
18 export ARMV7BINDIR ?= ./bin/$(DEVICE)
20 # ROOT Directory
21 export ROOTDIR := ../../..
23 # INCLUDE Directory
24 export INCDIR := ../../..;$(PDK_INSTALL_PATH);$(ROOTDIR)
26 # Common Macros used in make
28 ifndef RM
29 export RM = rm -f
30 endif
32 ifndef CP
33 export CP = cp -p
34 endif
36 export MKDIR = mkdir -p
38 ifndef RMDIR
39 export RMDIR = rm -rf
40 endif
42 ifndef SED
43 export SED = sed
44 endif
46 ifndef MAKE
47 export MAKE = make
48 endif
50 # PHONY Targets
51 .PHONY: all examples clean lib tests install installbin
53 # all rule
54 all: .executables 
55 .executables: lib tests
57 # Libraries
58 lib: .libraries
60 # tests Stub to add tests
61 tests: 
62         @$(MAKE) -f ./test/$(DEVICE)/armv7/linux/build/makefile all
64 # examples Stub to add Examples
65 #examples: 
66 #       @$(MAKE) -f ./example/InfraDmaSC/$(DEVICE)/armv7/linux/build/makefile all
68 # Make rule to create $(ARMV7LIBDIR)/librm.a library
69 .libraries: $(ARMV7LIBDIR)/librm.a
71 $(ARMV7LIBDIR)/librm.a::
72         @$(MAKE) -f ./build/armv7/librm_aearmv7.mk $@
74 # Rule to clean $(ARMV7LIBDIR)/librm.a library
75 clean:
76         @$(MAKE) -f ./build/armv7/librm_aearmv7.mk $@
77         @$(MAKE) -f ./test/$(DEVICE)/armv7/linux/build/makefile $@
78         @$(RMDIR) $(ARMV7OBJDIR)/rm
79         @$(RMDIR) $(ARMV7BINDIR)/rm
80         @$(RM) $(ARMV7LIBDIR)/librm.a
82 installbin:
83         install -d $(INSTALL_BIN_BASE_DIR)
84         install -c -m 755 $(ARMV7BINDIR)/rm/test/rmServer.out    $(INSTALL_BIN_BASE_DIR)/rmServer_$(DEVICE).out
85         install -c -m 755 $(ARMV7BINDIR)/rm/test/rmLinuxClientTest.out    $(INSTALL_BIN_BASE_DIR)/rmLinuxClientTest_$(DEVICE).out
86         install -c -m 755 $(ARMV7BINDIR)/rm/test/rmDspClientTest.out    $(INSTALL_BIN_BASE_DIR)/rmDspClientTest_$(DEVICE).out   
88 install:
89         install -d $(INSTALL_INC_BASE_DIR)/ti/drv/rm/include
90         install -d $(INSTALL_INC_BASE_DIR)/ti/drv/rm/util
91         install -d $(INSTALL_INC_BASE_DIR)/ti/drv/rm/util/libfdt
92         install -d $(INSTALL_INC_BASE_DIR)/ti/drv/rm/device/k2k/
93         install -d $(INSTALL_INC_BASE_DIR)/ti/drv/rm/device/k2h/        
94         install -d $(INSTALL_LIB_BASE_DIR)
95         $(CP) ./*.h                $(INSTALL_INC_BASE_DIR)/ti/drv/rm
96         $(CP) ./include/*.h        $(INSTALL_INC_BASE_DIR)/ti/drv/rm/include
97         $(CP) ./util/*.h        $(INSTALL_INC_BASE_DIR)/ti/drv/rm/util
98         $(CP) ./util/*.sh        $(INSTALL_INC_BASE_DIR)/ti/drv/rm/util 
99         $(CP) ./util/libfdt/*.h $(INSTALL_INC_BASE_DIR)/ti/drv/rm/util/libfdt   
100         $(CP) ./device/k2h/*.c $(INSTALL_INC_BASE_DIR)/ti/drv/rm/device/k2h
101         $(CP) ./device/k2h/*.dtb $(INSTALL_INC_BASE_DIR)/ti/drv/rm/device/k2h
102         $(CP) ./device/k2h/*.dts $(INSTALL_INC_BASE_DIR)/ti/drv/rm/device/k2h           
103         $(CP) ./device/k2k/*.c $(INSTALL_INC_BASE_DIR)/ti/drv/rm/device/k2k     
104         $(CP) ./device/k2k/*.dtb $(INSTALL_INC_BASE_DIR)/ti/drv/rm/device/k2k   
105         $(CP) ./device/k2k/*.dts $(INSTALL_INC_BASE_DIR)/ti/drv/rm/device/k2k   
106         $(CP) ./test/dts_files/*.c $(INSTALL_INC_BASE_DIR)/ti/drv/rm/test/dts_files     
107         $(CP) ./test/dts_files/*.dtb $(INSTALL_INC_BASE_DIR)/ti/drv/rm/test/dts_files   
108         $(CP) ./test/dts_files/*.dts $(INSTALL_INC_BASE_DIR)/ti/drv/rm/test/dts_files           
109         @$(CP) -r $(ARMV7LIBDIR)/*.a         $(INSTALL_LIB_BASE_DIR)
110 # Make rule to create examples Stub
111 examples: