To get the library life upgrade in Sand Wraith mode, first reach the point where the Dahaka breaks through the wall. Then, climb up onto the rafters and to find a broken pillar on the Dahaka's right side. Drop down onto the pillar and you will be in front of the Dahaka. As long as you do not touch the Dahaka he will not hurt you. Now, you simply jump right across the gap in the floor and you should cling onto the next ledge which the Dahaka prevented you from. Proceed upwards and across to the balcony ledges. On your way back, be careful. It may appear that the Dahaka has disappeared but in reality he is still there so do not try to walk in through the hole but go back up onto the rafters and continue on like normal. Leaving this path and going out the normal library exit may cause glitches.