update flag for lib