Please note that only base Android OS and basic applications is opensource software.
However most Android devices ship with a substantial amount of proprietary software, such as Google Mobile Services,
which includes applications such as Google Play Store, Google Search, and Google Play Services, a software layer that provides
APIs for the integration with Google-provided services.
These applications must be licensed from Google by device makers, and can only be shipped on devices which meet the requirements.
You should have the manufacturer's license from Google to be able to implement the Google Play service on your platform.
You can contact Google for more details:
https://source.android.com/compatibility/