DM6467T开发环境的安装.docx
《DM6467T开发环境的安装.docx》由会员分享,可在线阅读,更多相关《DM6467T开发环境的安装.docx(6页珍藏版)》请在冰豆网上搜索。
![DM6467T开发环境的安装.docx](https://file1.bdocx.com/fileroot1/2023-1/9/65de6bfe-1862-4bb3-82e0-db6223c1bbb7/65de6bfe-1862-4bb3-82e0-db6223c1bbb71.gif)
DM6467T开发环境的安装
DM6467T开发环境的安装
1.虚拟机安装VirtualBox3.2.12
2.ubuntu10.04
3.下载 DVSDK_3_10_003_10_00_19相关文件
▪linux-davinci-staging.tar.gz- containsthekernelsourcetreewiththeTImodifications,alsoknownastheProductSupportPackage(PSP)
▪linuxlibs-####.##-armv5te.tar.gz- containsPSPpre-compiledLinuxlibraries
▪dvsdk_#_##_##_##_Setup.bin- containstheDVSDKitself
▪arago-demo-image-dm####-evm.tar.gz- forrootfilesystem
▪dvsdk_#_#_#_#_overlay_dm6467.tar.gz- forplatform-specificappsanddata
▪cs2dm6467_#_##_##_##_Setup.bin- codecserverforDM6467platform
4.安装步骤
InstallingSoftwareComponents
Thissectionexplainshowtoinstalltherequiredsoftwarecomponentsonthehost.
1.LogintoyourhostLinuxworkstation.
2.Thecommandsinthissectioninstallallcomponentsinthe/home//dvsdkdirectory.Ifyoupreferadifferentlocation,modifythecommandsasnecessary.Openacommandpromptinusermodeandgotothedownloaddirectoryasfollows:
host$mkdir-p/home//dvsdk
host$cd/home//dvsdk
3.Downloadandunpackthetoolchain:
Thelink Getting_CodeSourcery_Toolchain providestheinformationyouneedtodownloadthetoolchain.Youcandownloadthe AdvancedPackages fromthelinkwhichprovidesthelinuxtarball.Theotheroptionswouldbetodownloadthe RecommendedPackages whichprovidesthetoolsinalinuxinstaller.Thesecommandsassumeyouwanttodownloadthetoolchain(AdvancedPackages)andinstallitinthe/opt/arm-2009q1directory. Note:
The"sudo"isnotnecessaryifyouwanttoinstallthetoolchaininsomeotherplace.Thetoolchaincanbeinstalledanywhereinthesystemaslongasthedirectoryhasthenecessarywritepermissions.
host$sudomkdir-p/opt
host$sudotar-xjfarm-2009q1-203-arm-none-linux-gnueabi-i686-pc-linux-gnu.tar.bz2-C/opt
Note:
Pleasenotethat arm-2009q1-203-arm-none-linux-gnueabi.bin isanassumedinstallernamefromtheCodeSourceryif RecommendedPackages isselectedfromthelinkforthelinuxinstaller.Pleaseexecute arm-2009q1-203-arm-none-linux-gnueabi.bin toinstallthetoolchainto/opt/arm-2009q1directoryiflinuxinstallerisconsideredforthetoolchaininsteadofthetarball.
Thesecommandlinetoolsareavailableatnocost.CodeSourceryalsooffersmorefullyfeaturedtoolsforacost.TheSourceryG++Litepackageincludesallofthefollowingcomponents:
▪CodeSourceryDebugSpriteforARM
▪GNUBinaryUtilities(Binutils)
▪GNUCCompiler(GCC)
▪GNUCLibrary(GLIBC)
▪GNUC++Compiler(G++)
▪GNUC++RuntimeLibrary(Libstdc++)
▪GNUDebugServer(GDBServer)
▪GNUDebugger(GDB)
4.UnpackthePSPpre-compiledLinuxlibrariespackageasfollows.Itputsthelibraryheadersinlinuxlibs-####.##-armv5te/includedirectoryandpre-compiledlibrariesinlinuxlibs-####.##-armv5te/libdirectory.
host$tar-xzflinuxlibs-####.##-armv5te.tar.gz-C/home//dvsdk
5.UnpacktheLinuxPSPsource.TheLinuxkernelcanbefoundin/home//dvsdk/git.
host$tar-xzflinux-davinci-staging.tar.gz-C/home//dvsdk
6.InstalltheDVSDKsoftware:
host$chmoda+xdvsdk_#_##_##_##_Setup.bin
host$./dvsdk_#_##_##_##_Setup.bin
Note:
The$(DVSDK_INSTALL_DIR)variableintheinstallerpointstotheDVSDKinstalldirectory,e.g.,$(DVSDK_INSTALL_DIR)issetto /home//dvsdk/dvsdk_#_##_##_##forthissetup.
7.Thecommandmentionedinstep6openstheinstallerwindow.Pleasechoosetheappropriateoptionsandentertherequiredpathstocompletetheinstallation.
8.YoucanchoosetoupdatethepathslaterbyeditingtheRules.makefilepresentin/home//dvsdk/dvsdk_#_##_##_##directory.
9.InstalltheCodecServercs#dm6467_#_##_##_##.bin,forDM6467fromthis link,wheretheDVSDKsoftwareisinstalled(/home//dvsdk/dvsdk_#_##_##_##/cs#dm6467_#_##_##_##:
)aspartofthenextstep
host$chmoda+xcs#dm6467_#_##_##_##_Setup.bin
host$./cs#dm6467_#_##_##_##_Setup.bin
Note:
Youcanuninstallthesecomponentsbyusingtherm-rfcommandonitsdirectory.Youshouldignoretheun-installfilescreatedbytheinstaller.
CreatingaTargetandHostSharedFileSystemandExportingIt
AlthoughtheEVMboard's(thatis,thetarget's)NANDflashcontainsafilesystem,duringdevelopmentitismoreconvenienttohavethetargetboardNFSmountafilesystemonahostLinuxworkstation.Onceyouhavetestedtheapplication,youcanstoreitontheboard'sflashforastandalonedemonstration.
BeforetheEVMcanmountasharedtargetfilesystem,youmustexportthattargetfilesystemonthehostLinuxworkstation.ThesharedfilesystemusesanNFS(NetworkFileSystem)server.Theexportedfilesystemwillcontainthetargetfilesystemandyourexecutables.
The InstallingaNFSServer pageprovidesinformationoninstallingNFSserverinaUbuntumachine.
BootingwithNFSasarootfilesystem
▪The"demo"filesystemforDM6467EVM(arago-demo-image-dm6467t-evm.tar.gz)shouldbeexportedfromtheNFSserveronyourhostLinuxworkstation.Additionallythereareapplicationsanddataforthetargetindvsdk_#_#_#_#_overlay_dm6467.tar.gz.Performthefollowingsteps(Youonlyneedtoperformthesestepsonce)
▪LoginwithauseraccountonthehostLinuxworkstation
▪PerformthefollowingcommandstopreparealocationfortheAragotargetfilesystem.Forexample:
host$cd/home/
host$mkdir-pworkdir/filesys
host$cdworkdir/filesys
▪SwitchusertorootonthehostLinuxworkstation
host$suroot
▪Performthefollowingcommandstocreateacopyofthetargetfilesystemwithpermissionssetforwritingtothesharedareaas.Substituteyouusernamefor.
host$cp-a/arago-demo-image-dm6467t-evm.tar.gz.
host$tarxvfzarago-demo-image-dm6467t-evm.tar.gz
host$cp-a/dvsdk_VERSION_overlay_dm6467.tar.gz.#Ifpresent(for3.10GAandlater).
host$tarxvfzdvsdk_VERSION_overlay_dm6467.tar.gz
host$chmod777-R/home//workdir/filesys
▪Editthe/etc/exportsfileonthehostLinuxworkstation(nottheexportsfileonthetargetfilesystem).Addthefollowinglineforexportingthefilesysdirectory,substitutingyourusernamefor.Usethefullpathfromroot;~maynotworkforexportsonallfilesystems.
/home//workdir/filesys*(rw,no_root_squash,no_all_squash,sync)
NOTE:
Makesureyoudonotaddaspacebetweenthe*andthe(intheabovecommand.
▪Stillasroot,usethefollowingcommandstomaketheNFSserverawareofthechangetoitsconfigurationandtoinvokeanNFSrestart.
host$/usr/sbin/exportfs-av
host$/etc/init.d/nfs-kernel-serverrestart
NOTE:
Useexportfs-ravtore-exportalldirectories.Use/etc/init.d/nfs-kernel-serverstatustoverifythattheNFSstatusisrunning.
▪SetupthebootargsENVvariabletobootwithNFSfilesystem:
Pleasereferto SampleU-BootparametersrequiredfortheDVSDKdemo page.
SettingUptheBuild/DevelopmentEnvironment
Tosetupthedevelopmentandbuildenvironment,followthesesteps:
1.Logintoyour user account(andnotasroot)ontheNFShostsystem.
2.SetyourPATHenvironmentvariablesothatthetoolchainhosttoolsandcrosscompiler(arm-none-linux-gnueabi-gcc)canbefound.Todothis,youshouldopenyour.bashrcfileinatexteditorsuchasviorgeditandaddtheexportcommandlinetothefile,forexamplerunthecommandbelow:
host$gedit/home//.bashrc
3.Next,addtheexportcommandbelowtothe.bashrcfile.Ifyouinstalledinalocationotherthan/opt/arm-2009q1/bin,useyourownlocationinthePATH.
exportPATH="/opt/arm-2009q1/bin:
$PATH"
4.Remembertousethefollowingcommandaftermodifyingyour.bashrcfile.Thesourcecommandessentiallyexecutesthe.bashrcscriptsuchthatthepathyoujustaddedtoitisplacedinyourcurrentenvironmentvariables:
host$source/.bashrc
5.IfyouwanttoverifyyournewPATHvariableyoucanruneitherofthecommandsbelow:
▪ThisprintsjustthePATHvariable:
host$echo$PATH
▪Thisprintsallofthesystem'scurrentenvironmentvariables:
host$printenv
BuildingtheDVSDKSoftwarefortheTarget
YoucanbuildboththeLinuxkernelandDVSDKfromdvsdk_#_##_##_##.Thefollowingstepsassumeyouhaveinstalledallcomponentsdescribedabovein/home//dvsdk.
YouneedtodofollowingonceinthehostmachinetobeabletobuildDVSDK
host$sudoapt-getinstalllibc6-dev
1.Changedirectoryto/home//dvsdk/dvsdk_#_##_##_##
2.ThefollowingstepsarenotrequiredifDVSDKisinstalledthroughthelinuxinstaller.ThebelowstepscanbeusedtoverifytheenvironmentvariablessetintheRules.makefileinthedvsdk_#_##_##_##.directory.
host$geditRules.make
▪SetPLATFORMtomatchyourEVMboardasfollows:
PLATFORM=dm6467
Note:
validoptionsaredm365ordm355ordm6467
▪SetDVSDK_INSTALL_DIRtothetop-levelDVSDKinstallationdirectoryasfollows,notethatbydefault${HOME}referstoyour/home/directory:
DVSDK_INSTALL_DIR=/home//dvsdk/dvsdk_#_##_##_##
▪MakesureLINUXKERNEL_INSTALL_DIRisdefinedasfollowssoitpointstowhereyoucopiedthelinuxkerneltreeintheBuildingaNewLinuxKernel.
LINUXKERNEL_INSTALL_DIR=/home//dvsdk/git
▪MakesureLINUXLIBS_INSTALL_DIRpointstotheextractedPSPpre-compiledLibraries.
LINUXLIBS_INSTALL_DIR=/home//dvsdk/linuxlibs-####.##-armv5te
▪MakesureCSTOOL_DIRpointstotheCodeSourcerytoolsdirectoryasfollows:
CSTOOL_DIR=/opt/arm-2009q1
▪MakesureEXEC_DIRpointstotheoptdirectoryontheNFSexportedfilesystemasfollows:
EXEC_DIR=/home//workdir/filesys/opt/dvsdk/dm####
3.BuildingLinuxkernelimagerequires mkimage tobepresentinthesystem.T