Green’s Dictionary of Slang

give a damn v.

also give a dang
[backform. f. not give a damn v.]

[1930s+] to care; usu. in a negative sense, e.g. who gives a damn? or like I give a damn.