changed for static lib support