Revert "Revert "fix duplicate LIBRARIES : build fix""

This reverts commit b4650dee42d567603630a14ddb512b02913acea5.