update Makefile for sgd