Improve creating lib dirs