Revert "Changes for linking library. (not finished)"

This reverts commit 1633b57b77856af85cb1e047ec66dc229444211e.