Generate liblist.a and use it to link to main.