You are on page 1of 15

GMTSAR

INSTALLATION TUTORIAL

on ubuntu 12.04
ForprocessingALOSPALSARdata

Luhur Bayuaji

20120821(ver.1) Suggestion,questionorotherinquiriesrelatedtothisGMTSARinstallationtutorial PleasesendittoLuhurbayuaji@gmail.com


1

Terminal
Mostlytheinstallationprocessisperformedontheterminal. Toopentheterminal,presswindowssignbutton andtypeterminal thenclickonterminalicon. Commandcanbetypedintheterminalandpressentertoexecuteit.
Thisisterminal

OSbitversion
TheknowledgeaboutyourOperatingSystem(OS)bitversion isneededforcompilingprocess.Theprocesstofindoutthis informationisverysimple.Typethiscommandbelowin terminal uname m(thenhitenter) Iftheresponseis i686ori386,youhavea32bitversionof Linux. Iftheresponseis x86_64,youhavea64bitversionof Linux.

Guidance
InstallCshell Installgfortan InstallGoogleearth InstallGMT(GenericMappingTools) InstallGMTSAR

Guidance
InstallCshell Installgfortan InstallGoogleearth InstallGMT(GenericMappingTools) InstallGMTSAR

InstallCshell
Purpose: Ubuntuworksonbashshellbydefault.GMTSARscript developedonCshellscriptinglanguage.Cshellshouldbe installedintoUbuntutomakeitrun. Typethecommandbelowontheterminalthenpressenter toinstallCshell sudo aptgetinstalltcsh Fortesting,typetcsh intheterminal,thenthecommand promptshouldchangeintoCshellcommandprompt.
Inordertogobackintobashshellthen typeexitintheCshellcommandprompt

Guidance
InstallCshell Installgfortan InstallGoogleearth InstallGMT(GenericMappingTools) InstallGMTSAR

Installgfortran
Purpose: Gfortran isacompilerforFORTRANlanguage.GMTsoftware needsittocompilethesourcecode. Typethecommandbelowontheterminalthenpressenter
sudo aptgetinstallgfortran gfortranmultilib

Fortesting,typegfortran intheterminal,thenerrorno inputfilemessagewillcomeout

Guidance
InstallCshell Installgfortan InstallGoogleearth InstallGMT(GenericMappingTools) InstallGMTSAR

InstallGoogleEarth
Purpose: GoogleEarthwillbeusedtodisplaytheGMTSARresultinKML format.Itisoptional,butitisrecommended.
Installationneedseveralstepsasfollow Downloadinstallationfilebyusingcommandbelow
wget http://dl.google.com/dl/earth/client/current/googleearthstable_current_i386.deb

Installthegoogle earthbytypingcommandbelow.Iferrormessage appearduringtheprocess,justignoreitandrunthenextcommand. sudo dpkg i googleearthstable_current_i386.deb Installalldependencyprograms sudo aptgetinstallf Fortesting,typegoogleearth intheterminal,thengoogle earth programwillrun.

10

Guidance
InstallCshell Installgfortan InstallGoogleearth InstallGMT(GenericMappingTools) InstallGMTSAR

11

InstallGMT
Purpose: GenericMappingToolsistheimportantsoftwarethatrequiredby GMTSAR.Theinstallationneedseveralstepsincludingdownloadand settingthepath.Wewillcreatenewdirectory(folder)calledAPPS. Fromnowon,APPSwillbecomeinstallationdirectoryforGMT, GMTSARandotherneededsoftware. CreatenewAPPSfolder,usingthiscommandbelow mkdir APPS EnterAPSSfolder,usingthiscommandbelow(donotforgettodoit) cdAPPS

12

InstallGMT2
OpentheGMTsiteinthewebaddressbelow http://gmt.soest.hawaii.edu/ Clickthedownload linkintheleftframeofthewebsite

13

InstallGMT3
ClickonINSTALLFORMlink

Rightclickonthelinkinstall_gmt.sh andsaveintoAPPSfolder

14

InstallGMT4
Scrolldown.InpartB.SupportLibrarySetup,selectPleasegetandinstall thelatestnetCDF 3.6.x

Scrolldown.Inpart11.Completetheoperation,giveacheck onDeleteall archivesuponsuccessfulinstallation,thenclickonGETPARAMETESbutton

15

InstallGMT5
SavetheparametersfileintoAPPSfolderbyrightclickontheparameters frame.ForMozillaFirefoxuser,belowisthemenutosaveparametersfile. TheGMT4param.txt filewillbecreatedinAPPSfolder.

16

InstallGMT6
Runthescriptfromterminal,usingthecommandbelow sh install_gmt.sh GMT4param.txt AftertheGMTinstallationcompletetheresultwillbelooklikethis. Save thisinformationcarefullyorcopypasteintotexteditor.Wewillneedit duringGMTSARinstallationlateron.

17

InstallGMT7
Payattentiontothefollowingresult,thenwewilldosomesetup

Addthepathsettingtofile.bashrc (Bashshellsetupfile) bedifferentinyourcase. cd~ Pleaseinputthecorrect one,basedonprevious pico .bashrc result(InstallGMT6step) addthesecommandsinthelastlineinside.bashrc exportNETCDFHOME=/home/gmt/APPS/netcdf3.6.3 exportPATH=/home/gmt/APPS/GMT4.5.8/bin:$PATH pressCTRL+XthentypeY (tosavethechanges)
18

Theunderlinedwordcould

InstallGMT8
Payattentiontothefollowingresult,thenwewilldosomesetup

Addthepathsettingtofile.tcshrc (Cshellsetupfile) bedifferentinyourcase. cd~ Pleaseinputthecorrect one,basedonprevious pico .tcshrc result(InstallGMT6step) addthesecommandsinthelastlineinside.tcshrc setenv NETCDFHOME/home/gmt/APPS/netcdf3.6.3 setpath=(/home/gmt/APPS/GMT4.5.8/bin$path) pressCTRL+X thentypeY (tosavethechanges)
19

Theunderlinedwordcould

InstallGMT9
EntertoCshellbytypingcommandtcsh intheterminal,thentest thepathbyrunningthegrdinfo programfromGMT.Ifitsucceed, thenthefollowingoutputshouldcomeout.

20

10

Guidance
InstallCshell Installgfortan InstallGoogleearth InstallGMT(GenericMappingTools) InstallGMTSAR

21

InstallGMTSAR
Purpose: PreviouslyweinstallalltheprogramthatneededforGMTSARtorun properly.Fromnowon,GMTSARinstallationtutorialwillbepresented. GMTSARwillbeinstalledinsideAPPSfolder.Makesurethesetwo conditionsarefulfilled:
1. 2. GotoCshellusingtcsh command GotoAPPSfolderbyusingcdAPPScommand(ifyouareinhomefolder)

TheGMTSARonlyworkinginCshell

22

11

InstallGMTSAR2
DownloadGMTSARsourcecodeusingthiscommand wget http://topex.ucsd.edu/gmtsar/tar/GMTSAR.tar itwilldownloadGMTSAR.tar fileinsideAPPSfolder. CreateGMTSARfolderinsideAPPSfolder mkdir GMTSAR ExtractGMTSAR.tar (sourcecode)intoGMTSARfolder tarxvf GMTSAR.tar CGMTSAR ItwillextracttheGMTSAR.tar intoGMTSARfolderinsideAPPSfolder.

23

InstallGMTSAR3
EntertoGMTSARfolder cdGMTSAR Openfilegmtsar_config file pico gmtsar_config Modifythegmtsar_config Modificationsinstructionsareavailableinthenextpage.

24

12

InstallGMTSAR4
Pleasepayattentiontotheparametersbelow.Youshouldmodifyto yourneeds.

Fornumber2)setthecompilerswitchtomatchthewayGMTwascompiled. IfyourOperatingSystem(OS)is64bit,justleaveit IfyourOSis32bit,switchthecommentmark #setenv M64m64O3 setenv M64m32O3


25

InstallGMTSAR5

Fornumber3)setthepathtoGMT,NETCDF,andGMTSAR
Youshouldmodifyalltheparameterintothecorrectpath. SomeoftheinformationcanbetakenfromGMTinstallationprocess. Thisistheexampleforthistutorial

setenv GMTHOME/home/gmt/APPS/GMT4.5.8 setenv NETCDFHOME/home/gmt/APPS/netcdf3.6.3 setenv GMTSARHOME/home/gmt/APPS/GMTSAR


26

13

InstallGMTSAR6

Fornumber5)Settheccfft1droutineforyourcomputer UncommenttheA.nospecialfft codeisavailable part


cd$GMTSAR/lib_src rm cfft1d.c ln scfft1d_codes/cfft1d_fftpack.ccfft1d.c cd../..
27

InstallGMTSAR7

Fornumber5)Settheccfft1droutineforyourcomputer PutcommentmarktheB.Optionalformacusingveclib part


#rm f$GMTSAR/lib_src/cfft1d.c #ln s$GMTSAR/lib_src/cfft1d_codes/cfft1d_veclib.c$GMTSAR/lib_src/cfft1d.c #setenv VEC"frameworkveclib"
28

14

InstallGMTSAR8
Savethemodification pressCTRL+XthentypeY(tosavethechanges) Sourcegmtsar_config (toapplyallthesettingingmtsar_config) sourcegmtsar_config CompiletheGMTSARsourcecode make Testtheresultbydoingcommand(resultshouldbeasintheimage) align.csh esarp

29

INSTALLATION FINISHED CONGRATULATION


YoucanusetheGMTSARnow!!

30

15

You might also like