Added Debian install and IPK generation.
authorJianzhongXu <a0869574@ti.com>
Mon, 9 Feb 2015 21:45:17 +0000 (16:45 -0500)
committerJianzhongXu <a0869574@ti.com>
Mon, 9 Feb 2015 21:45:17 +0000 (16:45 -0500)
Makefile [moved from makefile with 62% similarity]
build/tar_files_list.txt
build_linalg.sh

similarity index 62%
rename from makefile
rename to Makefile
index ae34f696c9c3c61bbd53033ae01f4c914b001911..cdb523f9f82b087ed2eb1b98aac25088a8e127ac 100644 (file)
--- a/makefile
+++ b/Makefile
@@ -1,21 +1,28 @@
 
-.PHONY: clean linalg_ARMonly linalg install build
+DESTDIR = "/evmk2h_nfs"
+
+.PHONY: clean ARMonly linalg install build
 
-LINALG_BUILD_DIR    = build
 LINALG_BLIS_DIR     = blis
 LINALG_CBLAS_DIR    = cblas
 LINALG_BLISACC_DIR  = blasblisacc
 
-build: linalg_ARMonly
+prebuild: DSPonly
+build: ARMonly
+linalg: ARMplusDSP
 
-linalg:
+ARMplusDSP:
        cd $(LINALG_CBLAS_DIR); make arch=ARM alllib; make arch=C66 alllib; \
        cd ../$(LINALG_BLIS_DIR); ./configure -p install/c66x c66x; make -j8; make install; \
        ./configure -p install/arm cortex-a15; make -j8; make install; \
        cd ../$(LINALG_BLISACC_DIR); make cross; \
        cd ../$(LINALG_BLIS_DIR)/testsuite; make lib=OpenCLCBLAS -j8
 
-linalg_ARMonly: 
+DSPonly:
+       cd $(LINALG_CBLAS_DIR); make arch=C66 alllib; \
+       cd ../$(LINALG_BLIS_DIR); ./configure -p install/c66x c66x; make -j8; make install
+       
+ARMonly: 
        cd $(LINALG_CBLAS_DIR); make arch=ARM alllib; \
        cd ../$(LINALG_BLIS_DIR); ./configure -p install/arm cortex-a15; make -j8; make install; \
        cd ../$(LINALG_BLISACC_DIR); make cross; \
@@ -28,3 +35,11 @@ clean:
        cd ../$(LINALG_BLISACC_DIR); make clean; \
        cd ../$(LINALG_BLIS_DIR)/testsuite; make clean
 
+install:
+       install -m 755 -d ${DESTDIR}/usr/include
+       install -m 755 -d ${DESTDIR}/usr/lib
+       install -m 755 -d ${DESTDIR}/usr/share/ti/examples/linalg
+       cp $(LINALG_BLISACC_DIR)/lib/libcblas_armplusdsp.a ${DESTDIR}/usr/lib
+       cp $(LINALG_BLIS_DIR)/install/arm/lib/libblis-*-cortex-a15.a /usr/lib/libblis.a
+
+       
\ No newline at end of file
index b79ebe28c782c6ea5dc17895ff870788e9ff553d..3325a8103a48715bb34f2f354d926852b99ab117 100644 (file)
@@ -1,5 +1,5 @@
 make.inc
-makefile
+Makefile
 debian
 blis/build
 blis/CHANGELOG
@@ -17,7 +17,6 @@ blis/mpi_test
 blis/README
 blis/test
 blis/testsuite
-blis/version
 blasblisacc/lib
 blasblisacc/Makefile
 blasblisacc/src
@@ -31,5 +30,3 @@ cblas/Makefile.in
 cblas/README
 cblas/README.TI
 cblas/src
-cblas/testing
-
index 21efb3614be4bad66c1d7d9d2eac763b61c64426..552e3ec6680e467de6df1e80adb4ba430447efcf 100755 (executable)
@@ -31,6 +31,10 @@ cd -
 [ ! -z $LINALG_BASE_DIR ] || { echo "Error: $LINALG_BASE_DIR not set!"; exit 1; }
 [ ! -z $OUTPUT_DIR ] || { echo "Error: $OUTPUT_DIR not set!"; exit 1; }
 
+# two environment variables below need to be set by setup_hpc_env.sh
+#export TI_OCL_INSTALL_DIR=/opt/ti/mcsdk-hpc_03_00_01_04/ti-opencl_0.14.0/
+#export C6X_C_DIR=/home/uda0869574local/ti/c6000_7.6.0/include
+
 cd $MCSDK_HPC_DIR/scripts
 set +e
 . setup_hpc_env.sh -s $TI_INSTALL_DIR:$TI_INSTALL_DIR/linaro -t $TARGET_ROOTDIR
@@ -43,11 +47,19 @@ env
 
 ####################### buidling LINALG  ########################
 cd $LINALG_BASE_DIR
-make linalg
+make prebuild
 echo "Generating Debian package ..."
 LINALG_VER=`cat build/version.txt`
 tar -czf linalg_$LINALG_VER.tar.gz --exclude='*.git' --exclude="*.obj" --exclude="*.o" --files-from=build/tar_files_list.txt
-####################### end of buidling LINALG  ########################
 
 cp -v linalg_$LINALG_VER.tar.gz $OUTPUT_DIR
 
+make build
+
+echo "Generating IPK ..."
+mkdir -pv ./ipk_install
+sudo make install DESTDIR=./ipk_install
+
+$MCSDK_HPC_DIR/mkrel/ipk/create_ipk.sh $MCSDK_HPC_DIR/mkrel/ipk/linalg ./ipk_install
+mv -v *.ipk $OUTPUT_DIR
+