codec engine代码阅读四---CE_DIR/examples/ti/sdo/ce/examles/codecs/videnc_copy(转)

http://www.usr.cc/thread-52035-1-1.html

主要讲解CE_DIR/examples/ti/sdo/ce/examles/codecs文件夹:提供实现IVIDENC接口的视频编码器


codec engine代码阅读四---CE_DIR/examples/ti/sdo/ce/examles/codecs/videnc_copy下的文件:
当完成编辑上一篇code engine代码阅读三 所涉及的两个文件之后就可以编译程序了.
需要编译的程序主要涉及CE_INSTALL_DIR/examples/ti/sdo/ce/examples下面的四个文件夹,分别为apps,codecs,extensions,servers这四个文件夹分别为编解码算法,扩展,编解码服务器和应用程序.
首先编解码算法和扩展是编解码服务器和应用程序编译的前提条件,要先一步编译.应用程序通过服务器提供的接口来调用codecs下面的算法.
我们先从codecs中某一个算法videnc_copy下手:

ls lib package.bld package.xs videnc_copy_ti.h VIDENC_COPY.xdc makefile package.xdc videnc_copy.c videnc_copy_ti_priv.h VIDENC_COPY.xs

其中lib是文件夹,编译生成的库文件会放到lib下面,而未编译之前lib是空的.从哪里开始看呢?
由于我们是用make命令编译的,所以我们先来看makefile文件:

# include the files that defines XDC package, paths and build rules //要包含定义XDC包,路径和创建规则的文件. EXAMPLES_ROOTDIR := $(CURDIR)/../../../../../.. //示例代码根目录位置. include $(EXAMPLES_ROOTDIR)/xdcpaths.mak //包含路径相关的文件,这里面是我们填的所有工具和包的路径. # [CE] add the examples directory itself to the list of paths to packages//把示例代码文件夹本身填加到XDC_PATH中. XDC_PATH := $(EXAMPLES_ROOTDIR);$(XDC_PATH) include $(EXAMPLES_ROOTDIR)/buildutils/xdcrules.mak //包含创建规则文件xdcrules.mak # # @(#) ti.sdo.ce.examples.codecs.videnc_copy; 1, 0, 0,188; 4-21-2009 18:17:11; /db/atree/library/trees/ce/ce-m06x/src/ #

可见这个makefile文件告诉我们一些文具在那里,一些路径在哪里,而真正怎么创建却要看CE根目录下的buildutils/xdcrules.mak.

# # ======== xdcrules.mak ======== # definition of XDC rules //定义XDC规则 # # If not set in the environment, set XDCOPTIONS to verbose (the 'v' option)//如果环境变量没设XDCOPTIONS,设为v, //这个选项的意思是打印调试消息. XDCOPTIONS ?= v # This command actually performs the build. //这个命令实际是执行创建(编译) # Note that the "-PD ." says "build the package in this directory ("-P ."), # and all of the packages it depends on ("-D"). //下面的-PD的选项意思是创建当前文件夹下的代码,及所依赖的代码. //下面是实际的编译命令,make all和make都执行下面的语句: all: %:: //语句意思是,执行XDC_INSTALL_DIR下的xdc ,传数参数是XDCPATH="$(XDC_PATH)" XDCOPTIONS=$(XDCOPTIONS) $@ -PD $(XDC_INSTALL_DIR)/xdc XDCPATH="$(XDC_PATH)" \ XDCOPTIONS=$(XDCOPTIONS) $@ -PD .

make时,实际上只是完成了一些变量的设定,然后就调用xdc工具了,我们得知道xdc工具的工作过程.
xdc工具包括:

j@j-desktop:/home/pheobe/davinci/xdctools_3_10_05_61$ ls bin examples package uninstall bioscfg gmake packages vers config.jar include package.xdc xdc docs jre tconf xdctools_3_10_05_61_release_notes.html eclipse libcdb.so tconfini.tcf xs etc libncdb.so tconf.x86U xs.x86U




OK,我承认,上次我知识不足,写到这里写不下去了,又回头看了些东西,如果大家要接着往下看,恐怕得读一下:
XDC工具使用示例
http://www.usr.cc/thread-52037-1-1.html

重新清理思路:一楼的内容是正确的,一楼说到,makefile里就是要调用xdc来编译。xdc怎么干活,看完上面链接的内容大家也都了解了。

/*! * ======== package.xdc ======== * Simple Codec Engine compatible video "encoder". *简易与CE兼容的视频编码器 * This codec illustrates the simplest integration into the Codec从一楼可以知道,make时,实际上只是完成了一些变量的设定,然后就调用xdc工具了,我们得知道xdc工具的工作过程. xdc工具包括: [code]j@j-desktop:/home/pheobe/davinci/xdctools_3_10_05_61$ ls bin examples package uninstall bioscfg gmake packages vers config.jar include package.xdc xdc docs jre tconf xdctools_3_10_05_61_release_notes.html eclipse libcdb.so tconfini.tcf xs etc libncdb.so tconf.x86U xs.x86U

这时我们可以查看它的 release notes :
Introduction
介绍

RTSC / XDC (eXpanDed C) is a standard for reusable software components, optimized for real-time embedded systems. RTSC components have hardware-neutral formal interfaces, are configurable offline to optimize memory and performance, and support custom automation in the development environment via a scripting language.
RTSC/XDC(eXpanDed C)是一个标准的可重用软件组件(这里显然是把xdc称为eXpanDed C的简写,而其它的文档则视为Express DSP Component的缩写),它为实时嵌入式系统进程了优化. RTSC组件有硬件中立正规接口,可以离线进行配置以优化内存和性能,另外,它还支持通过脚本语言自定义的开发环境自己化.

XDCtools 3.10.05.61 is the General Availability release of XDCtools 3.10.05. It includes the following sets of packages:
XDC包括下列的包:
Core (xdc.*) - the xdc and xs command line utilities for building packages and execting scripts, together with the packages that implement the XDC standard;
核心模块(xdc.*)--xdc和xs命令行工具,用于构建包和执行脚本.
User tools (xdc.tools.*) - command-line and graphical utilities for working with packages and repositories;
用户工具(xdc.tools.*)--命令行和图形界面工具,用于包和库相关的工作.
Targets (*.targets.*) - definitions for using various TI and third-party compiler tool chains;
目标(*.targets.*)--各种TI和第三个编译工具的定义
Platforms (*.platforms.*) - definitions for linking and running code on various TI and third-party board-level hardware and simulator products.
平台(*.platforms.*)--各种TI和第三方板级硬件及仿真器上的代码的链接和执行所需的定义.




下面我们应该看的是 package.xdc和 package.bld,因为它们定义了这个包:
/*!
*  ======== package.xdc ========
*  Simple Codec Engine compatible video "encoder".
*简易与CE兼容的视频编码器
*  This codec illustrates the simplest integration into the Codec
*  Engine.  Only three files are required to integrate into the Codec Engine:
* 这个编解码器描述了CE的最简单集成,它只需三个文件用于集成.
*  @p(dlist)
*      -  `package.xdc`
*          This file is required to declare a name for this package and to
*          list all codec interfaces available.
* 这个文件用于声明包的名字和列出可用的接口.
*      - `VIDENC_COPY.xdc`

*          This file specifies a codec (named VIDENC_COPY) that is
*          provided by this package.
*这个文件指定了这个包所提供的编解码器,名字为VIDENC_COPY.
*      -  `VIDENC_COPY.xs`
*          This file implements the functions required by the ICodec
*          interface; these functions enable the codec to describe its
*          non-functional requirements such as stack size.
* 这个文件实现了ICodec接口中的函数的实现,这个函数描述的是一些非功能性的需求,如栈大小等.
*  All other files in this package are simply the implementation of the codec
*  as specified by xDM.  Thus, integration into the Codec Engine requires
*  no change to the codecs sources.
*所有其他文件用于实现xDM.
*/
package ti.sdo.ce.examples.codecs.videnc_copy [1, 0, 0] {
    module VIDENC_COPY;
}
本文件实际上就是声明了一个包,包里有一个模块叫VIDENC_COPY,描述这个模块的文件是名为VIDENC的.c .xdc .xs文件.

再看 package.bld :

var Build = xdc.useModule('xdc.bld.BuildEnvironment');  //客户程序需要的模块.
var Pkg = xdc.useModule('xdc.bld.PackageContents'); //客户程序需要的模块.

/* when constructing a release, release everything */
Pkg.attrs.exportAll = true;

// Uncomment this to build debug binaries
//Pkg.attrs.profile = "debug";

/*
* Create an array containing the files to include in this package.  Note
* that the extension is added by XDC, so it need not be explicitly specified.
var SRCS = ["videnc_copy"];/ /这个包会编译成一个库,编译进这个库的文件在这里列出,扩展中的无需列出.
for (var i = 0; i < Build.targets.length; i++) 
{    
        var targ = Build.targets;// 枚举所有的targets,如果是C64P或C674则有DMA3,可以优化,编译优化版本videnc_copy_dma.    
        if (targ.name == "C64P" || targ.name == "C674") 
        {            
                Pkg.addLibrary("lib/videnc_copy_dma", targ, {copts: "-DUSE_ACPY3 ",}).addObjects(SRCS);
        }
         //否则编译普便版本
        Pkg.addLibrary("lib/videnc_copy", targ).addObjects(SRCS);
}

所以包里的主文件就是 videnc_copy.c :

/* * ======== videnc_copy.c ======== * Video Encoder "copy" algorithm. * * This file contains an implementation of the deprecated IVIDENC interface * as defined by xDM 0.9. */ #include <xdc/std.h> #include <string.h> #include <ti/xdais/dm/ividenc.h> #include <ti/sdo/ce/trace/gt.h> #include "videnc_copy_ti.h" #include "videnc_copy_ti_priv.h"

这里只列了头文件,videnc_copy.c的头文件里没有package/internal/videnc_copy.xdc.h的字样,但是我们看到有VIDENC_COPY.XDC这个文件了,没找到真正包含它的地方.
然后我们看 Video_COPY.XDC 吧:
/*!
*  ======== VIDENC_COPY ========
*  VIDENC_COPY codec specification
* VIDENC_COPY编解码器说明手册
*  This file specifies information necessary to integrate with the Codec
*  Engine.
* 本文件特别说明了与CE集成所必需的信息。
*  By inheriting ti.sdo.ce.video.IVIDENC, VIDENC_COPY declares that it "is
*  a" video encoder algorithm.  This allows the codec engine to automatically
*  supply simple stubs and skeletons for transparent execution of DSP
*  codecs by the GPP.
*  通过继承ti.sdo.ce.video.IVIDENC,VIDENC_COPY声明它自己为一个视频编码算法。
* 这使得CE可以自动提供一个stub们和skeleton们,以实现GPP调用DSP的算法.

*  In addition to declaring the type of the VIDENC_COPY algorithm, we declare the
*  external symbol required by xDAIS that identifies the algorithms
*  implementation functions.
*除了声明算法类型,还声明了xDAIS需求实现的一些函数的外部符号.
*/
metaonly module VIDENC_COPY inherits ti.sdo.ce.video.IVIDENC
{
    override readonly config String ialgFxns = "VIDENCCOPY_TI_VIDENCCOPY";/ /ialgFxns函数表名字.
    override readonly config String idma3Fxns = "VIDENCCOPY_TI_IDMA3";// DMA3接口的名字,useDMA为true才有用.
    config Bool useDMA = false;// 用于支持某些芯片的DMA优化算法.
}
也就是说这里声明了两个String和个Bool型常量,给C语言及其他语言用,这个文件主要用来配置这三个常量的值.

下面接着看 videnc_copy.c 的代码,我把函数体内的内容去掉,只留一个声明,我们还看框架:
IVIDENC_Fxns VIDENCCOPY_TI_VIDENCCOPY = { 
{IALGFXNS},
VIDENCCOPY_TI_process,
VIDENCCOPY_TI_control,
};   //这里是填充IVIDENC_Fxns框架.

IALG_Fxns VIDENCCOPY_TI_IALG = { /* module_vendor_interface */
IALGFXNS
}; //这里是填充IALG_Fxns框架


// ======== dmaChangeChannels ========
Void VIDENCCOPY_TI_dmaChangeChannels()
// ======== dmaGetChannelCnt ========
Uns VIDENCCOPY_TI_dmaGetChannelCnt(Void)
//  ======== dmaGetChannels ========
Uns VIDENCCOPY_TI_dmaGetChannels()
// ======== maInit ========
Int VIDENCCOPY_TI_dmaInit()
这一部分是实现IDMA3_Fxns框架


IDMA3_Fxns VIDENCCOPY_TI_IDMA3 = { /* module_vendor_interface */
&VIDENCCOPY_TI_IALG, /* IALG functions */
VIDENCCOPY_TI_dmaChangeChannels, /* ChangeChannels */
VIDENCCOPY_TI_dmaGetChannelCnt, /* GetChannelCnt */
VIDENCCOPY_TI_dmaGetChannels, /* GetChannels */
VIDENCCOPY_TI_dmaInit /* initialize logical channels */
} ;//这里填充IDMA3_Fxns框架


//======== activate ========
VIDENCCOPY_TI_activate(IALG_Handle handle)
// ======== deactivate ========
VIDENCCOPY_TI_deactivate()
// ======== alloc ========
Int VIDENCCOPY_TI_alloc()
// ======== free ========
Int VIDENCCOPY_TI_free()
// ======== initObj ========
Int VIDENCCOPY_TI_initObj()
// ======== process ========
XDAS_Int32 VIDENCCOPY_TI_process()
// ======== control ========
VIDENCCOPY_TI_control()

这里是IVIDENC_Fxns框架的实现

最后看一下 videnc_copy.xs :





*  ======== VIDENC_COPY.xs ========
*  This file implements the functions specified in the ti.sdo.ce.ICodec
*  interface.  These functions enable the configuration tool to validate
*  user supplied configuration parameters (e.g., stack size for the
*  thread running this codec).
* 这个文件实现了ti.sdo.ce.ICodec接口的函数,这些函数使配置功具可以验明用户提供的配置参数.
*如栈大小等.
*/

var verbose = false;   /* set to true to enable verbose output during config */


function  getStackSize (prog)
{
    return (1024);
}

/*
*  ========  getDaramScratchSize  ========
*/
function getDaramScratchSize(prog)
{
    return (0);
}

/*
*  ========  getSaramScratchSize  ========
*/
function getSaramScratchSize(prog)
{
  return (1024);
}

行文到这里,videnc_copy的代码就看得差不了,现在总结一下:
package.xdc声明了包了名字为videnc_copy,并且告拆xdc工具,包内有一个模块,名为VIDENC_COPY, 它里面就这一句话:

package ti.sdo.ce.examples.codecs.videnc_copy [1, 0, 0] { module VIDENC_COPY; }

VIDENC_COPY这个名字指示xdc工具去看VIDENC_COPY.xdc文件,VIDENC_COPY.xdc声明了这个模块,并且告诉xdc工具,说我这个模块是继承了IVIDENC接口。

metaonly module VIDENC_COPY inherits ti.sdo.ce.video.IVIDENC { override readonly config String ialgFxns = "VIDENCCOPY_TI_VIDENCCOPY"; override readonly config String idma3Fxns = "VIDENCCOPY_TI_IDMA3"; config Bool useDMA = false; }

这里体现出来xdc有点类似于c语言头文件的作用,它一直在声明一些东西,说明了包和模块的结构。

说它相当于头文件,实际上在XDC工具使用示例中第六课的内容也讲了,videnc_copy.c中的函数定义也可以放在VIDENC_COPY.xdc中的,但也可以放在.h文件中,这个代码就是放在.h文件中的,可见videnc_copy_ti_priv.h中的代码。

另一方面是package.bld文件,这个文件说明了程序怎么编译,需要哪些依赖模块,编译哪些C语言文件,生成的什么可执行文件或库。简化一点就是下面的代码:
var Build = xdc.useModule('xdc.bld.BuildEnvironment'); //需要这些模块
var Pkg = xdc.useModule('xdc.bld.PackageContents');
var SRCS = ["videnc_copy"];
Pkg.addLibrary("lib/videnc_copy", targ).addObjects(SRCS); //编译videnc_copy.c文件,用它来生成lib/videnc_copy库


第三类文件是.xs文件,一个是package.xs,即包的.xs文件,另一个模块的.xs文件 VIDENC_COPY.xs,他们里面都是些函数。用于向配置工具提供一些用户配置参数。如package.xs里有两个函数是一个是getlibs函 数,根据情况会返回lib/videnc_copy.a64P ,lib/videnc_copy_dma.a64P等字符串值,即返回库文件的名字,它在xdc生成包之后调用,用以生成与目标芯片相关的链接命令脚 本,而另一个函数则是close,这个函数在xdc生成包的最后阶段调用,将一些配置参数复位。
模块相关的.xs文件是VIDENC_COPY.xs文件,它里面是一些堆栈设置的函数,一般都是直接return一个数值,或是打印一些信息。


读到这里我们似乎也有了一些印象,xdc编译时似乎要先打包(其中打包的结尾要调用close,然后生成链接脚。

下面我们编译一下,看看都做了些什么:
ti/sdo/ce/examples/codecs/videnc_copy$ make
/home/pheobe/davinci/xdctools_3_10_05_61/xdc XDCPATH="/home/pheobe/davinci/dvsdk_2_00_00_22/codec_engine_2_23_01/examples/ti/sdo/ce/examples/codecs/videnc_copy/../../../../../..;/home/pheobe/davinci/dvsdk_2_00_00_22/local_power_manager_1_23_01/packages;/home/pheobe/davinci/dvsdk_2_00_00_22/codec_engine_2_23_01/packages;/home/pheobe/davinci/dvsdk_2_00_00_22/xdais_6_23/packages;/home/pheobe/davinci/dvsdk_2_00_00_22/dsplink-1_61_03-prebuilt/packages;/home/pheobe/davinci/dvsdk_2_00_00_22/linuxutils_2_23_01/packages;/home/pheobe/davinci/dvsdk_2_00_00_22/framework_components_2_23_01/packages;/home/pheobe/davinci/dvsdk_2_00_00_22/biosutils_1_01_00/packages;/home/pheobe/davinci/bios_5_33_03/packages" \
                XDCOPTIONS=v all -PD .
making all: Thu Nov 3 11:12:45 EDT 2011 ...
上面这段是翻译了makefile里面的话,传换成了完整的好长的xdc命令。
======== .interfaces [/home/pheobe/davinci/dvsdk_2_00_00_22/codec_engine_2_23_01/examples/ti/sdo/ce/examples/codecs/videnc_copy] ========
#
# making package.mak (because of package.bld) ...//这里是根据package.bld生成package.mak文件
package.mak也是供make命令用的,用来编译的,你可以去看看里面是什么,大致意思是利用当前文件夹的文件和生成的pakage文件夹下的文件来编译目标代码

/ home/pheobe/davinci/xdctools_3_10_05_61/tconf  -//调用tconf
Dxdc.path="/home/pheobe/davinci/dvsdk_2_00_00_22/codec_engine_2_23_01/examples/ti/sdo/ce/examples/codecs/videnc_copy/../../../../../..;/home/pheobe/davinci/dvsdk_2_00_00_22/local_power_manager_1_23_01/packages;/home/pheobe/davinci/dvsdk_2_00_00_22/codec_engine_2_23_01/packages;/home/pheobe/davinci/dvsdk_2_00_00_22/xdais_6_23/packages;/home/pheobe/davinci/dvsdk_2_00_00_22/dsplink-1_61_03-prebuilt/packages;/home/pheobe/davinci/dvsdk_2_00_00_22/linuxutils_2_23_01/packages;/home/pheobe/davinci/dvsdk_2_00_00_22/framework_components_2_23_01/packages;/home/pheobe/davinci/dvsdk_2_00_00_22/biosutils_1_01_00/packages;/home/pheobe/davinci/bios_5_33_03/packages;/home/pheobe/davinci/xdctools_3_10_05_61/packages;../../../../../.." -Dxdc.root=/home/pheobe/davinci/xdctools_3_10_05_61 -Dxdc.hostOS=Linux -Dconfig.importPath=".;/home/pheobe/davinci/dvsdk_2_00_00_22/codec_engine_2_23_01/examples/ti/sdo/ce/examples/codecs/videnc_copy/../../../../../..;/home/pheobe/davinci/dvsdk_2_00_00_22/local_power_manager_1_23_01/packages;/home/pheobe/davinci/dvsdk_2_00_00_22/codec_engine_2_23_01/packages;/home/pheobe/davinci/dvsdk_2_00_00_22/xdais_6_23/packages;/home/pheobe/davinci/dvsdk_2_00_00_22/dsplink-1_61_03-prebuilt/packages;/home/pheobe/davinci/dvsdk_2_00_00_22/linuxutils_2_23_01/packages;/home/pheobe/davinci/dvsdk_2_00_00_22/framework_components_2_23_01/packages;/home/pheobe/davinci/dvsdk_2_00_00_22/biosutils_1_01_00/packages;/home/pheobe/davinci/bios_5_33_03/packages;/home/pheobe/davinci/xdctools_3_10_05_61/packages;../../../../../..;/home/pheobe/davinci/xdctools_3_10_05_61;/home/pheobe/davinci/xdctools_3_10_05_61/etc" -Dxdc.bld.targets="" -DTOOLS=   /home/pheobe/davinci/xdctools_3_10_05_61/packages/xdc/bld/bld.js /home/pheobe/davinci/dvsdk_2_00_00_22/codec_engine_2_23_01/examples/ti/sdo/ce/examples/codecs/videnc_copy/../../../../../../config.bld package.bld package.mak 
config.bld: Running the version from Codec Engine Examples.
config.bld: loading user build configuration file   /home/pheobe/davinci/dvsdk_2_00_00_22/codec_engine_2_23_01/examples/user.bld   //加载这个用户脚本文件.
building for target C64P ...  //为DSP创建
building for target GCArmv5T ...//为ARM创建

#
# generating interfaces for package ti.sdo.ce.examples.codecs.videnc_copy (because package/package.xdc.inc is older than package.xdc) ... //生成vienc_copy接口
/home/pheobe/davinci/xdctools_3_10_05_61/xs
 -Dxdc.path="/home/pheobe/davinci/dvsdk_2_00_00_22/codec_engine_2_23_01/examples/ti/sdo/ce/examples/codecs/videnc_copy/../../../../../..;/home/pheobe/davinci/dvsdk_2_00_00_22/local_power_manager_1_23_01/packages;/home/pheobe/davinci/dvsdk_2_00_00_22/codec_engine_2_23_01/packages;/home/pheobe/davinci/dvsdk_2_00_00_22/xdais_6_23/packages;/home/pheobe/davinci/dvsdk_2_00_00_22/dsplink-1_61_03-prebuilt/packages;/home/pheobe/davinci/dvsdk_2_00_00_22/linuxutils_2_23_01/packages;/home/pheobe/davinci/dvsdk_2_00_00_22/framework_components_2_23_01/packages;/home/pheobe/davinci/dvsdk_2_00_00_22/biosutils_1_01_00/packages;/home/pheobe/davinci/bios_5_33_03/packages;/home/pheobe/davinci/xdctools_3_10_05_61/packages;../../../../../.." -Dxdc.root=/home/pheobe/davinci/xdctools_3_10_05_61 -Dxdc.hostOS=Linux -Dconfig.importPath=".;/home/pheobe/davinci/dvsdk_2_00_00_22/codec_engine_2_23_01/examples/ti/sdo/ce/examples/codecs/videnc_copy/../../../../../..;/home/pheobe/davinci/dvsdk_2_00_00_22/local_power_manager_1_23_01/packages;/home/pheobe/davinci/dvsdk_2_00_00_22/codec_engine_2_23_01/packages;/home/pheobe/davinci/dvsdk_2_00_00_22/xdais_6_23/packages;/home/pheobe/davinci/dvsdk_2_00_00_22/dsplink-1_61_03-prebuilt/packages;/home/pheobe/davinci/dvsdk_2_00_00_22/linuxutils_2_23_01/packages;/home/pheobe/davinci/dvsdk_2_00_00_22/framework_components_2_23_01/packages;/home/pheobe/davinci/dvsdk_2_00_00_22/biosutils_1_01_00/packages;/home/pheobe/davinci/bios_5_33_03/packages;/home/pheobe/davinci/xdctools_3_10_05_61/packages;../../../../../..;/home/pheobe/davinci/xdctools_3_10_05_61;/home/pheobe/davinci/xdctools_3_10_05_61/etc" -Dxdc.bld.targets="" -DTOOLS=  -f xdc/services/intern/cmd/build.xs  -m package/package.xdc.dep -i package/package.xdc.inc package.xdc
    translating VIDENC_COPY
.interfaces files complete: Thu Nov 3 11:12:50 EDT 2011. //接口文件搞定
======== .libraries [/home/pheobe/davinci/dvsdk_2_00_00_22/codec_engine_2_23_01/examples/ti/sdo/ce/examples/codecs/videnc_copy] ========
rm -f package/lib/lib/videnc_copy/package/package_ti.sdo.ce.examples.codecs.videnc_copy.ov5T
#
# clv5T package/package_ti.sdo.ce.examples.codecs.videnc_copy.c ...
/usr/local/montavista/pro/devkit/arm/v5t_le/bin/ arm_v5t_le-gcc开始编译了 -c -MD -MF package/lib/lib/videnc_copy/package/package_ti.sdo.ce.examples.codecs.videnc_copy.ov5T.dep -x c  -fPIC -Wunused -Wall -fno-strict-aliasing  -march=armv5t -Dfar=  -Dxdc_target_name__=GCArmv5T -Dxdc_target_types__=gnu/targets/arm/std.h -Dxdc_bld__profile_release -Dxdc_bld__vers_1_0_4_2_0 -O2  -I. -I/home/pheobe/davinci/dvsdk_2_00_00_22/codec_engine_2_23_01/examples/ti/sdo/ce/examples/codecs/videnc_copy/../../../../../.. -I/home/pheobe/davinci/dvsdk_2_00_00_22/local_power_manager_1_23_01/packages -I/home/pheobe/davinci/dvsdk_2_00_00_22/codec_engine_2_23_01/packages -I/home/pheobe/davinci/dvsdk_2_00_00_22/xdais_6_23/packages -I/home/pheobe/davinci/dvsdk_2_00_00_22/dsplink-1_61_03-prebuilt/packages -I/home/pheobe/davinci/dvsdk_2_00_00_22/linuxutils_2_23_01/packages -I/home/pheobe/davinci/dvsdk_2_00_00_22/framework_components_2_23_01/packages -I/home/pheobe/davinci/dvsdk_2_00_00_22/biosutils_1_01_00/packages -I/home/pheobe/davinci/bios_5_33_03/packages -I/home/pheobe/davinci/xdctools_3_10_05_61/packages -I../../../../../..  -o package/lib/lib/videnc_copy/package/package_ti.sdo.ce.examples.codecs.videnc_copy.ov5T package/package_ti.sdo.ce.examples.codecs.videnc_copy.c
rm -f package/lib/lib/videnc_copy/videnc_copy.ov5T
#
# clv5T videnc_copy.c ...
/usr/local/montavista/pro/devkit/arm/v5t_le/bin /arm_v5t_le-gcc -c -MD -MF package/lib/lib/videnc_copy/videnc_copy.ov5T.dep -x c  -fPIC -Wunused -Wall -fno-strict-aliasing  -march=armv5t -Dfar=  -Dxdc_target_name__=GCArmv5T -Dxdc_target_types__=gnu/targets/arm/std.h -Dxdc_bld__profile_release -Dxdc_bld__vers_1_0_4_2_0 -O2  -I. -I/home/pheobe/davinci/dvsdk_2_00_00_22/codec_engine_2_23_01/examples/ti/sdo/ce/examples/codecs/videnc_copy/../../../../../.. -I/home/pheobe/davinci/dvsdk_2_00_00_22/local_power_manager_1_23_01/packages -I/home/pheobe/davinci/dvsdk_2_00_00_22/codec_engine_2_23_01/packages -I/home/pheobe/davinci/dvsdk_2_00_00_22/xdais_6_23/packages -I/home/pheobe/davinci/dvsdk_2_00_00_22/dsplink-1_61_03-prebuilt/packages -I/home/pheobe/davinci/dvsdk_2_00_00_22/linuxutils_2_23_01/packages -I/home/pheobe/davinci/dvsdk_2_00_00_22/framework_components_2_23_01/packages -I/home/pheobe/davinci/dvsdk_2_00_00_22/biosutils_1_01_00/packages -I/home/pheobe/davinci/bios_5_33_03/packages -I/home/pheobe/davinci/xdctools_3_10_05_61/packages -I../../../../../..  -o package/lib/lib/videnc_copy/videnc_copy.ov5T videnc_copy.c
rm -f lib/videnc_copy.av5T类似的句子是删除临时文件
#
# archiving package/lib/lib/videnc_copy/package/package_ti.sdo.ce.examples.codecs.videnc_copy.ov5T package/lib/lib/videnc_copy/videnc_copy.ov5T into lib/videnc_copy.av5T ...
/usr/local/montavista/pro/devkit/arm/v5t_le/armv5tl-montavista-linux-gnueabi/bin/ar  cr lib/videnc_copy.av5T   package/lib/lib/videnc_copy/package/package_ti.sdo.ce.examples.codecs.videnc_copy.ov5T package/lib/lib/videnc_copy/videnc_copy.ov5T 
rm -f package/lib/lib/videnc_copy/package/package_ti.sdo.ce.examples.codecs.videnc_copy.o64P
#
# cl64P package/package_ti.sdo.ce.examples.codecs.videnc_copy.c ...
/home/pheobe/davinci/cg6x_6_0_21_1/bin/cl6x -c这是为DSP编译 -qq -pdsw225 -pden -pds=195  -mv64p -eo.o64P -ea.s64P  -Dxdc_target_name__=C64P -Dxdc_target_types__=ti/targets/std.h -Dxdc_bld__profile_release -Dxdc_bld__vers_1_0_6_0_21 -O2  -I. -I/home/pheobe/davinci/dvsdk_2_00_00_22/codec_engine_2_23_01/examples/ti/sdo/ce/examples/codecs/videnc_copy/../../../../../.. -I/home/pheobe/davinci/dvsdk_2_00_00_22/local_power_manager_1_23_01/packages -I/home/pheobe/davinci/dvsdk_2_00_00_22/codec_engine_2_23_01/packages -I/home/pheobe/davinci/dvsdk_2_00_00_22/xdais_6_23/packages -I/home/pheobe/davinci/dvsdk_2_00_00_22/dsplink-1_61_03-prebuilt/packages -I/home/pheobe/davinci/dvsdk_2_00_00_22/linuxutils_2_23_01/packages -I/home/pheobe/davinci/dvsdk_2_00_00_22/framework_components_2_23_01/packages -I/home/pheobe/davinci/dvsdk_2_00_00_22/biosutils_1_01_00/packages -I/home/pheobe/davinci/bios_5_33_03/packages -I/home/pheobe/davinci/xdctools_3_10_05_61/packages -I../../../../../.. -I/home/pheobe/davinci/cg6x_6_0_21_1/include -fs=./package/lib/lib/videnc_copy/package -fr=./package/lib/lib/videnc_copy/package -fc package/package_ti.sdo.ce.examples.codecs.videnc_copy.c
/home/pheobe/davinci/xdctools_3_10_05_61/bin/mkdep -a package/lib/lib/videnc_copy/package/package_ti.sdo.ce.examples.codecs.videnc_copy.o64P.dep -p package/lib/lib/videnc_copy/package -s o64P package/package_ti.sdo.ce.examples.codecs.videnc_copy.c -C   -qq -pdsw225 -pden -pds=195  -mv64p -eo.o64P -ea.s64P  -Dxdc_target_name__=C64P -Dxdc_target_types__=ti/targets/std.h -Dxdc_bld__profile_release -Dxdc_bld__vers_1_0_6_0_21 -O2  -I. -I/home/pheobe/davinci/dvsdk_2_00_00_22/codec_engine_2_23_01/examples/ti/sdo/ce/examples/codecs/videnc_copy/../../../../../.. -I/home/pheobe/davinci/dvsdk_2_00_00_22/local_power_manager_1_23_01/packages -I/home/pheobe/davinci/dvsdk_2_00_00_22/codec_engine_2_23_01/packages -I/home/pheobe/davinci/dvsdk_2_00_00_22/xdais_6_23/packages -I/home/pheobe/davinci/dvsdk_2_00_00_22/dsplink-1_61_03-prebuilt/packages -I/home/pheobe/davinci/dvsdk_2_00_00_22/linuxutils_2_23_01/packages -I/home/pheobe/davinci/dvsdk_2_00_00_22/framework_components_2_23_01/packages -I/home/pheobe/davinci/dvsdk_2_00_00_22/biosutils_1_01_00/packages -I/home/pheobe/davinci/bios_5_33_03/packages -I/home/pheobe/davinci/xdctools_3_10_05_61/packages -I../../../../../.. -I/home/pheobe/davinci/cg6x_6_0_21_1/include -fs=./package/lib/lib/videnc_copy/package -fr=./package/lib/lib/videnc_copy/package
rm -f package/lib/lib/videnc_copy/videnc_copy.o64P
#
# cl64P videnc_copy.c ...
/home/pheobe/davinci/cg6x_6_0_21_1/bin/cl6x -c  -qq -pdsw225 -pden -pds=195  -mv64p -eo.o64P -ea.s64P  -Dxdc_target_name__=C64P -Dxdc_target_types__=ti/targets/std.h -Dxdc_bld__profile_release -Dxdc_bld__vers_1_0_6_0_21 -O2  -I. -I/home/pheobe/davinci/dvsdk_2_00_00_22/codec_engine_2_23_01/examples/ti/sdo/ce/examples/codecs/videnc_copy/../../../../../.. -I/home/pheobe/davinci/dvsdk_2_00_00_22/local_power_manager_1_23_01/packages -I/home/pheobe/davinci/dvsdk_2_00_00_22/codec_engine_2_23_01/packages -I/home/pheobe/davinci/dvsdk_2_00_00_22/xdais_6_23/packages -I/home/pheobe/davinci/dvsdk_2_00_00_22/dsplink-1_61_03-prebuilt/packages -I/home/pheobe/davinci/dvsdk_2_00_00_22/linuxutils_2_23_01/packages -I/home/pheobe/davinci/dvsdk_2_00_00_22/framework_components_2_23_01/packages -I/home/pheobe/davinci/dvsdk_2_00_00_22/biosutils_1_01_00/packages -I/home/pheobe/davinci/bios_5_33_03/packages -I/home/pheobe/davinci/xdctools_3_10_05_61/packages -I../../../../../.. -I/home/pheobe/davinci/cg6x_6_0_21_1/include -fs=./package/lib/lib/videnc_copy -fr=./package/lib/lib/videnc_copy -fc videnc_copy.c
/home/pheobe/davinci/xdctools_3_10_05_61/bin/mkdep -a package/lib/lib/videnc_copy/videnc_copy.o64P.dep -p package/lib/lib/videnc_copy -s o64P videnc_copy.c -C   -qq -pdsw225 -pden -pds=195  -mv64p -eo.o64P -ea.s64P  -Dxdc_target_name__=C64P -Dxdc_target_types__=ti/targets/std.h -Dxdc_bld__profile_release -Dxdc_bld__vers_1_0_6_0_21 -O2  -I. -I/home/pheobe/davinci/dvsdk_2_00_00_22/codec_engine_2_23_01/examples/ti/sdo/ce/examples/codecs/videnc_copy/../../../../../.. -I/home/pheobe/davinci/dvsdk_2_00_00_22/local_power_manager_1_23_01/packages -I/home/pheobe/davinci/dvsdk_2_00_00_22/codec_engine_2_23_01/packages -I/home/pheobe/davinci/dvsdk_2_00_00_22/xdais_6_23/packages -I/home/pheobe/davinci/dvsdk_2_00_00_22/dsplink-1_61_03-prebuilt/packages -I/home/pheobe/davinci/dvsdk_2_00_00_22/linuxutils_2_23_01/packages -I/home/pheobe/davinci/dvsdk_2_00_00_22/framework_components_2_23_01/packages -I/home/pheobe/davinci/dvsdk_2_00_00_22/biosutils_1_01_00/packages -I/home/pheobe/davinci/bios_5_33_03/packages -I/home/pheobe/davinci/xdctools_3_10_05_61/packages -I../../../../../.. -I/home/pheobe/davinci/cg6x_6_0_21_1/include -fs=./package/lib/lib/videnc_copy -fr=./package/lib/lib/videnc_copy
rm -f lib/videnc_copy.a64P
# 归档
# archiving package/lib/lib/videnc_copy/package/package_ti.sdo.ce.examples.codecs.videnc_copy.o64P package/lib/lib/videnc_copy/videnc_copy.o64P into lib/videnc_copy.a64P ...
/home/pheobe/davinci/cg6x_6_0_21_1/bin/ar6x  rq lib/videnc_copy.a64P   package/lib/lib/videnc_copy/package/package_ti.sdo.ce.examples.codecs.videnc_copy.o64P package/lib/lib/videnc_copy/videnc_copy.o64P 
rm -f package/lib/lib/videnc_copy_dma/package/package_ti.sdo.ce.examples.codecs.videnc_copy.o64P
#
# cl64P package/package_ti.sdo.ce.examples.codecs.videnc_copy.c ...
/home/pheobe/davinci/cg6x_6_0_21_1/bin/cl6x -c  -qq -pdsw225 -pden -pds=195  -mv64p -eo.o64P -ea.s64P  -Dxdc_target_name__=C64P -Dxdc_target_types__=ti/targets/std.h -Dxdc_bld__profile_release -Dxdc_bld__vers_1_0_6_0_21 -O2 -DUSE_ACPY3   -I. -I/home/pheobe/davinci/dvsdk_2_00_00_22/codec_engine_2_23_01/examples/ti/sdo/ce/examples/codecs/videnc_copy/../../../../../.. -I/home/pheobe/davinci/dvsdk_2_00_00_22/local_power_manager_1_23_01/packages -I/home/pheobe/davinci/dvsdk_2_00_00_22/codec_engine_2_23_01/packages -I/home/pheobe/davinci/dvsdk_2_00_00_22/xdais_6_23/packages -I/home/pheobe/davinci/dvsdk_2_00_00_22/dsplink-1_61_03-prebuilt/packages -I/home/pheobe/davinci/dvsdk_2_00_00_22/linuxutils_2_23_01/packages -I/home/pheobe/davinci/dvsdk_2_00_00_22/framework_components_2_23_01/packages -I/home/pheobe/davinci/dvsdk_2_00_00_22/biosutils_1_01_00/packages -I/home/pheobe/davinci/bios_5_33_03/packages -I/home/pheobe/davinci/xdctools_3_10_05_61/packages -I../../../../../.. -I/home/pheobe/davinci/cg6x_6_0_21_1/include -fs=./package/lib/lib/videnc_copy_dma/package -fr=./package/lib/lib/videnc_copy_dma/package -fc package/package_ti.sdo.ce.examples.codecs.videnc_copy.c
/home/pheobe/davinci/xdctools_3_10_05_61/bin/mkdep -a package/lib/lib/videnc_copy_dma/package/package_ti.sdo.ce.examples.codecs.videnc_copy.o64P.dep -p package/lib/lib/videnc_copy_dma/package -s o64P package/package_ti.sdo.ce.examples.codecs.videnc_copy.c -C   -qq -pdsw225 -pden -pds=195  -mv64p -eo.o64P -ea.s64P  -Dxdc_target_name__=C64P -Dxdc_target_types__=ti/targets/std.h -Dxdc_bld__profile_release -Dxdc_bld__vers_1_0_6_0_21 -O2 -DUSE_ACPY3   -I. -I/home/pheobe/davinci/dvsdk_2_00_00_22/codec_engine_2_23_01/examples/ti/sdo/ce/examples/codecs/videnc_copy/../../../../../.. -I/home/pheobe/davinci/dvsdk_2_00_00_22/local_power_manager_1_23_01/packages -I/home/pheobe/davinci/dvsdk_2_00_00_22/codec_engine_2_23_01/packages -I/home/pheobe/davinci/dvsdk_2_00_00_22/xdais_6_23/packages -I/home/pheobe/davinci/dvsdk_2_00_00_22/dsplink-1_61_03-prebuilt/packages -I/home/pheobe/davinci/dvsdk_2_00_00_22/linuxutils_2_23_01/packages -I/home/pheobe/davinci/dvsdk_2_00_00_22/framework_components_2_23_01/packages -I/home/pheobe/davinci/dvsdk_2_00_00_22/biosutils_1_01_00/packages -I/home/pheobe/davinci/bios_5_33_03/packages -I/home/pheobe/davinci/xdctools_3_10_05_61/packages -I../../../../../.. -I/home/pheobe/davinci/cg6x_6_0_21_1/include -fs=./package/lib/lib/videnc_copy_dma/package -fr=./package/lib/lib/videnc_copy_dma/package
rm -f package/lib/lib/videnc_copy_dma/videnc_copy.o64P
#
# cl64P videnc_copy.c ...
/home/pheobe/davinci/cg6x_6_0_21_1/bin/cl6x -c  -qq -pdsw225 -pden -pds=195  -mv64p -eo.o64P -ea.s64P  -Dxdc_target_name__=C64P -Dxdc_target_types__=ti/targets/std.h -Dxdc_bld__profile_release -Dxdc_bld__vers_1_0_6_0_21 -O2 -DUSE_ACPY3   -I. -I/home/pheobe/davinci/dvsdk_2_00_00_22/codec_engine_2_23_01/examples/ti/sdo/ce/examples/codecs/videnc_copy/../../../../../.. -I/home/pheobe/davinci/dvsdk_2_00_00_22/local_power_manager_1_23_01/packages -I/home/pheobe/davinci/dvsdk_2_00_00_22/codec_engine_2_23_01/packages -I/home/pheobe/davinci/dvsdk_2_00_00_22/xdais_6_23/packages -I/home/pheobe/davinci/dvsdk_2_00_00_22/dsplink-1_61_03-prebuilt/packages -I/home/pheobe/davinci/dvsdk_2_00_00_22/linuxutils_2_23_01/packages -I/home/pheobe/davinci/dvsdk_2_00_00_22/framework_components_2_23_01/packages -I/home/pheobe/davinci/dvsdk_2_00_00_22/biosutils_1_01_00/packages -I/home/pheobe/davinci/bios_5_33_03/packages -I/home/pheobe/davinci/xdctools_3_10_05_61/packages -I../../../../../.. -I/home/pheobe/davinci/cg6x_6_0_21_1/include -fs=./package/lib/lib/videnc_copy_dma -fr=./package/lib/lib/videnc_copy_dma -fc videnc_copy.c
/home/pheobe/davinci/xdctools_3_10_05_61/bin/mkdep -a package/lib/lib/videnc_copy_dma/videnc_copy.o64P.dep -p package/lib/lib/videnc_copy_dma -s o64P videnc_copy.c -C   -qq -pdsw225 -pden -pds=195  -mv64p -eo.o64P -ea.s64P  -Dxdc_target_name__=C64P -Dxdc_target_types__=ti/targets/std.h -Dxdc_bld__profile_release -Dxdc_bld__vers_1_0_6_0_21 -O2 -DUSE_ACPY3   -I. -I/home/pheobe/davinci/dvsdk_2_00_00_22/codec_engine_2_23_01/examples/ti/sdo/ce/examples/codecs/videnc_copy/../../../../../.. -I/home/pheobe/davinci/dvsdk_2_00_00_22/local_power_manager_1_23_01/packages -I/home/pheobe/davinci/dvsdk_2_00_00_22/codec_engine_2_23_01/packages -I/home/pheobe/davinci/dvsdk_2_00_00_22/xdais_6_23/packages -I/home/pheobe/davinci/dvsdk_2_00_00_22/dsplink-1_61_03-prebuilt/packages -I/home/pheobe/davinci/dvsdk_2_00_00_22/linuxutils_2_23_01/packages -I/home/pheobe/davinci/dvsdk_2_00_00_22/framework_components_2_23_01/packages -I/home/pheobe/davinci/dvsdk_2_00_00_22/biosutils_1_01_00/packages -I/home/pheobe/davinci/bios_5_33_03/packages -I/home/pheobe/davinci/xdctools_3_10_05_61/packages -I../../../../../.. -I/home/pheobe/davinci/cg6x_6_0_21_1/include -fs=./package/lib/lib/videnc_copy_dma -fr=./package/lib/lib/videnc_copy_dma
rm -f lib/videnc_copy_dma.a64P
#
# archiving package/lib/lib/videnc_copy_dma/package/package_ti.sdo.ce.examples.codecs.videnc_copy.o64P package/lib/lib/videnc_copy_dma/videnc_copy.o64P into lib/videnc_copy_dma.a64P ...
/home/pheobe/davinci/cg6x_6_0_21_1/bin/ar6x  rq lib/ videnc_copy_dma.a64P   package/lib/lib/videnc_copy_dma/package/package_ti.sdo.ce.examples.codecs.videnc_copy.o64P package/lib/lib/videnc_copy_dma/videnc_copy.o64P 
.libraries files complete: Thu Nov 3 11:12:52 EDT 2011.
======== .dlls [/home/pheobe/davinci/dvsdk_2_00_00_22/codec_engine_2_23_01/examples/ti/sdo/ce/examples/codecs/videnc_copy] ========
.dlls files complete: Thu Nov 3 11:12:52 EDT 2011.
======== .executables [/home/pheobe/davinci/dvsdk_2_00_00_22/codec_engine_2_23_01/examples/ti/sdo/ce/examples/codecs/videnc_copy] ========
.executables files complete: Thu Nov 3 11:12:52 EDT 2011.
======== all [/home/pheobe/davinci/dvsdk_2_00_00_22/codec_engine_2_23_01/examples/ti/sdo/ce/examples/codecs/videnc_copy] ========
#
# all files complete.
all files complete: Thu Nov 3 11:12:52 EDT 2011.

你可能感兴趣的:(codec engine代码阅读四---CE_DIR/examples/ti/sdo/ce/examles/codecs/videnc_copy(转))