They mean the same thing. Grammatically, they are different. #2 is better than #1.
#1 is a compound sentence. Really, it is two complete sentences, each having its own subject and verb. The two phrases are linked by "if" acting as a conjunction.
#2 is a single sentence containing a long adverbial clause, "to be able to ... one minute", which modifies the verb "give" by explaining "why I would give".
#2 is superior to #1 because it links the two thoughts together ("giving anything" and the reason "to hold him...") more concisely and effectively and without cumbersome logic.