If you keep taking the same medicine for a long time, your body builds up a resistance to it.
この場合、次のような言い方ができますよ。
ーIf you keep taking the same medicine for a long time, your body builds up a resistance to it.
「ずっと同じ薬を飲み続けていると、体に耐性がつく」
「耐性がつく」は to build up a resistance と言えます。
ご参考まで!