Magnitude-6.8 quake shakes northern Chile, swaying buildings