optimize package structure