Files
godot-angle-static/scripts/angle_android_codegen.go
Roman Lavrov 9f7b6babe1 Add minimal setup for Go codegen in Android.bp.
Based on Cody's http://ag/19603310.

Only adds libEGL_angle_codegen to libEGL_angle and is a no-op.

Tested in an aosp checkout. Hopefully this doesn't cause merge conflicts
with internal master as all diffs are close to the top of the file.

Android.bp diff: https://paste.googleplex.com/6626641357832192

Bug: b/242929755
Change-Id: I6d7ac9f3dd502074c41838bd1aa10075a8c99145
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/3876890
Commit-Queue: Roman Lavrov <romanl@google.com>
Reviewed-by: Cody Northrop <cnorthrop@google.com>
Reviewed-by: Geoff Lang <geofflang@chromium.org>
2022-09-07 16:40:44 +00:00

41 lines
1.0 KiB
Go

//
// Copyright 2022 The ANGLE Project Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
//
package angle_android_codegen
import (
"android/soong/android"
"android/soong/cc"
)
func init() {
android.RegisterModuleType(
"angle_android_codegen", angle_android_codegen_DefaultsFactory)
}
// Values passed in from Android.bp
type angle_android_codegen_Properties struct {
}
func angle_android_codegen_Defaults(g *angle_android_codegen_Properties) func(ctx android.LoadHookContext) {
return func(ctx android.LoadHookContext) {
// Structure to write out new values
type props struct {
}
p := &props{}
ctx.AppendProperties(p)
}
}
func angle_android_codegen_DefaultsFactory() android.Module {
module := cc.DefaultsFactory()
props := &angle_android_codegen_Properties{}
module.AddProperties(props)
android.AddLoadHook(module, angle_android_codegen_Defaults(props))
return module
}