Merge "Convert cpufeatures to Soong"
diff --git a/Android.bp b/Android.bp
index dad4e70..6a583cd 100644
--- a/Android.bp
+++ b/Android.bp
@@ -326,4 +326,4 @@
     sdk_version: "24",
 }
 
-build = ["stl.bp"]
\ No newline at end of file
+build = ["cpufeatures.bp", "stl.bp"]
\ No newline at end of file
diff --git a/Android.mk b/Android.mk
index 30d9093..e03a825 100644
--- a/Android.mk
+++ b/Android.mk
@@ -14,6 +14,4 @@
 # limitations under the License.
 #
 
-LOCAL_PATH:= $(call my-dir)
-
-include $(LOCAL_PATH)/current/sources/android/cpufeatures/Android.mk
+# Intentionally empty to prevent subdir Android.mk loading
diff --git a/cpufeatures.bp b/cpufeatures.bp
new file mode 100644
index 0000000..ff4c41e
--- /dev/null
+++ b/cpufeatures.bp
@@ -0,0 +1,22 @@
+//
+// Copyright (C) 2017 The Android Open Source Project
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+//
+
+cc_library_static {
+    name: "cpufeatures",
+    srcs: ["current/sources/android/cpufeatures/cpu-features.c"],
+    sdk_version: "minimum",
+    export_include_dirs: ["current/sources/android/cpufeatures"],
+}
diff --git a/gen_blueprints.py b/gen_blueprints.py
index bbdd678..83f7e9b 100755
--- a/gen_blueprints.py
+++ b/gen_blueprints.py
@@ -84,7 +84,7 @@
         bpfile.write('\n')
         bpfile.write('\n\n'.join(blueprints))
         bpfile.write('\n\n')
-        bpfile.write('build = ["stl.bp"]')
+        bpfile.write('build = ["cpufeatures.bp", "stl.bp"]')
 
 
 if __name__ == '__main__':