C and Spin library