A new semester has begun. I am once again the teaching assistant of the Generic Mapping Tool (GMT) class in NTU, Taiwan. From this week, I will share some class materials to help those who just start to learn GMT.
This week, I’ll share install GMT in Ubuntu on Win10. From last few months, Microsoft has enabled the Linux subsystem on the latest version of Windows 10. We will not need install the dual-OS which costs lots of resources.
The main benefit install the GMT under Linux/Unix-like system is that you can run all the GMT examples. Also many useful programs is pre-installed in Linux like ‘awk’.
Enable the support of Windows Subsystem for Linux
- Open “Control Panel” （控制台）
- Search “optional features”（開啟或關閉 Windows 功能）
- check ” Windows Subsystem for Linux”（適用於Linux的Windows子系統）
- ckick “OK”
You may be ask to reboot after installed the Windows subsystem for Linux.
Install Linux distibutions
- Open “Microsoft Store”
- Search “Ubuntu”
- Click “get” to install
- After installation, launch the ubuntu app.
- It needs some time to install. After few minutes, ubuntu will ask you to set an account name and password. (they are not related to Windows account)
Update the Ubuntu system
- Use the following command to get the update list:
sudo apt update
- Use the following command to upgrade programs:
sudo apt upgrade
Follow the instructions on the screen.
Install Generic Mapping Tools (GMT)
Use the following command to install the GMT program:
sudo apt install gmt gmt-dcw gmt-gshhg ghostscript
To access the Windows files, the Windows drives will be mount under “/mnt” directory. e.g, /mnt/d/example = D:\example
It takes about 400MB to install GMT and ghostscript