initialize structure and lib